diff options
author | Jon Chesterfield <jonathanchesterfield@gmail.com> | 2021-09-09 17:16:41 +0100 |
---|---|---|
committer | Jon Chesterfield <jonathanchesterfield@gmail.com> | 2021-09-09 17:16:41 +0100 |
commit | 2a581710c1942b265b271e230368b1596132f242 (patch) | |
tree | b80f1fd1f8689eaeeee1b3a78671fb16c47043c7 /openmp | |
parent | 4f1c90a6d4dde9e3c6d3c7d76bb187c1c19960d5 (diff) | |
download | llvm-2a581710c1942b265b271e230368b1596132f242.tar.gz |
[openmp] No longer use LIBRARY_PATH to find devicertl
Given D109057, change test runner to use the libomptarget-x-bc-path
argument instead of the LIBRARY_PATH environment variable to find the device
library.
Also drop the use of LIBRARY_PATH environment variable as it is far
too easy to pull in the device library from an unrelated toolchain by accident
with the current setup. No loss in flexibility to developers as the clang
commandline used here is still available.
Reviewed By: jdoerfert, tianshilei1992
Differential Revision: https://reviews.llvm.org/D109061
Diffstat (limited to 'openmp')
-rw-r--r-- | openmp/libomptarget/test/lit.cfg | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/openmp/libomptarget/test/lit.cfg b/openmp/libomptarget/test/lit.cfg index d4f63dd6c6de..3693343969d8 100644 --- a/openmp/libomptarget/test/lit.cfg +++ b/openmp/libomptarget/test/lit.cfg @@ -89,9 +89,10 @@ else: # Unices config.test_flags += " -Wl,-rpath," + config.omp_host_rtl_directory if config.cuda_libdir: config.test_flags += " -Wl,-rpath," + config.cuda_libdir - append_dynamic_library_path('LIBRARY_PATH', config.library_dir, ":") - append_dynamic_library_path('LIBRARY_PATH', \ - config.omp_host_rtl_directory, ":") + if config.libomptarget_current_target.startswith('amdgcn'): + config.test_flags += " --libomptarget-amdgcn-bc-path=" + config.library_dir + if config.libomptarget_current_target.startswith('nvptx'): + config.test_flags += " --libomptarget-nvptx-bc-path=" + config.library_dir # substitutions # - for targets that exist in the system create the actual command. |