================
@@ -367,6 +368,25 @@ RocmInstallationDetector::RocmInstallationDetector(
if (DetectHIPRuntime)
detectHIPRuntime();
+ if (DetectOpenMPRuntime)
+ detectOpenMPRuntime();
+}
+
+void RocmInstallationDetector::detectOpenMPRuntime() {
+ assert(OpenMPASanRTLPath.empty());
+ // Set OpenMP ASan library directory path for pre-instrumented device
+ // libraries (e.g., libompdevice.a). This path is used when linking with
+ // -fsanitize=address for OpenMP offloading.
+ OpenMPASanRTLPath = llvm::sys::path::parent_path(D.Dir);
+ llvm::sys::path::append(OpenMPASanRTLPath, "lib", "asan");
----------------
ampandey-1995 wrote:
For AMD-ASan any runtime library component under `llvm-project` which is to be
instrumented always have the installation path `*llvm/lib/asan`.
Hi @b-sumner is that correct?
All the AMD-ASan instrumented openmp, offload etc libraries are installed
under path `*llvm/lib/asan` which is to follow a common design and user has to
set up only single path in env var `LD_LIBRARY_PATH`.
https://github.com/llvm/llvm-project/pull/179636
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits