================ @@ -330,6 +330,23 @@ def getStdFlag(cfg, std): default=f"{shlex.quote(sys.executable)} {shlex.quote(str(Path(__file__).resolve().parent.parent.parent / 'run.py'))}", help="Custom executor to use instead of the configured default.", actions=lambda executor: [AddSubstitution("%{executor}", executor)], + ), + Parameter( + name="openmp_pstl_backend", + choices=[True, False], + type=bool, + default=False, + help="Enable the OpenMP compilation toolchain if the PSTL backend was set to OpenMP.", + actions=lambda enabled: [ + AddCompileFlag("-fopenmp"), + # The linker needs to find the correct version of libomptarget + AddLinkFlag("-Wl,-rpath,%{lib}/../../lib"), + AddLinkFlag("-L%{lib}/../../lib"), + # The preprocessor needs to find the omp.h header + AddFlag("-I %{lib}/../../runtimes/runtimes-bins/openmp/runtime/src"), + # If the OpenMP PSTL backend was enbaled, we wish to run the tests for it ---------------- AntonRydahl wrote:
Hi @jhuber6 and @jdoerfert. @ldionne and I just discussed how to modify the `libc++` test configuration to be able to offload to GPUs. I could not get it to work without appending linking and include paths. Do you think `clang` should automatically look for `libomptarget.so` and `omp.h` in the correct places, or is it really necessary to add the paths? https://github.com/llvm/llvm-project/pull/66968 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits