We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 87d2b15 commit e4f307eCopy full SHA for e4f307e
test/test_xcpp_kernel.py
@@ -131,7 +131,7 @@ class XCppTests(jupyter_kernel_test.KernelTests):
131
'mime': 'image/png'
132
}
133
]
134
- code_omp='#include <omp.h>\n#include <iostream>\n#include <clang/Interpreter/CppInterOp.h>\n\nCpp::LoadLibrary("libomp");std::cerr<<"2"<<std::endl;'
+ code_omp='#include <omp.h>\n#include <iostream>\n#include <clang/Interpreter/CppInterOp.h>\n\nCpp::LoadLibrary("libomp");int max_threads = omp_get_max_threads();omp_set_thread_num(max_threads);#pragma omp parallel \n{\nif(omp_get_thread_num()==2) {\n std::cerr<<omp_get_thread_num()<<std::endl;}\n}\n'
135
def test_xcpp_omp(self):
136
self.flush_channels()
137
reply, output_msgs = self.execute_helper(code=self.code_omp,timeout=1)
0 commit comments