Add Clang guards around usage of openmp config#1050
Conversation
This fixes a gcc issue where clang headers are being brought in by the openmp-config. Additional cleanup: Remove unnecessary options added to COMMON_LINK_LIBS. If the openmp config is not found then OpenMP::OpenMP_CXX will be the fallback for both gcc and clang.
TorreZuk
left a comment
There was a problem hiding this comment.
-- Could NOT find OpenMP (missing: OpenMP_DIR)
-- Found OpenMP_CXX: -fopenmp=libomp (found version "5.1")
-- Found OpenMP_Fortran: -fopenmp (found version "4.5")
-- Found OpenMP: TRUE (found version "5.1")
-- CLIENT COMMON_DEFINES: HIPBLAS_BFLOAT16_CLASS;ROCM_USE_FLOAT16;HIPBLAS_NO_DEPRECATED_WARNINGS
-- CLIENT COMMON CXX_OPTIONS:
-- CLIENT COMMON LINK: OpenMP::OpenMP_CXX;Threads::Threads
and I see it link against libomp140.x86_64.dll so presume this works if linux pipelines pass with older mainline and you did gcc and clang test with latest clang OMP config?
With the new openmp-config.cmake present:Clang: hipblas-bench link shows: /opt/rocm/llvm/lib/libomp.so GCC: hipblas-bench link shows: /usr/lib/gcc/x86_64-linux-gnu/11/libgomp.so Simulated older ROCm building newer hipBLAS by removing openmp config:Clang: hipblas-bench link shows: /opt/rocm-7.0.0/lib/llvm/lib/libomp.so GCC: hipblas-bench link shows /usr/lib/gcc/x86_64-linux-gnu/11/libgomp.so |
|
Okay with my windows testing passed I think this should be fine to merge |
This fixes a gcc issue where clang headers are being brought in by the openmp-config. Additional cleanup: Remove unnecessary options added to COMMON_LINK_LIBS. If the openmp config is not found then OpenMP::OpenMP_CXX will be the fallback for both gcc and clang. (cherry picked from commit 4639103)
This fixes a gcc issue where clang headers are being brought in by the openmp-config. Additional cleanup: Remove unnecessary options added to COMMON_LINK_LIBS. If the openmp config is not found then OpenMP::OpenMP_CXX will be the fallback for both gcc and clang. (cherry picked from commit 4639103)
This fixes a gcc issue where clang headers are being brought in by the openmp-config. Additional cleanup: Remove unnecessary options added to COMMON_LINK_LIBS. If the openmp config is not found then OpenMP::OpenMP_CXX will be the fallback for both gcc and clang.
[hipBLAS] Add Clang guards around usage of openmp config (#1050) (#832) This fixes a gcc issue where clang headers are being brought in by the openmp-config. Additional cleanup: Remove unnecessary options added to COMMON_LINK_LIBS. If the openmp config is not found then OpenMP::OpenMP_CXX will be the fallback for both gcc and clang. [ROCm/hipBLAS commit: 4639103] This patch is dependent on the Ubuntu 24.04 docker file being updated to use AOCL 4.2 instead of 4.0. Co-authored-by: Torre Zuk <42548444+TorreZuk@users.noreply.github.com>
This fixes a gcc issue where clang headers are being brought in by the openmp-config. Additional cleanup: Remove unnecessary options added to COMMON_LINK_LIBS. If the openmp config is not found then OpenMP::OpenMP_CXX will be the fallback for both gcc and clang. [ROCm/hipBLAS commit: 4639103]
This fixes a gcc issue where clang headers are being brought in by the openmp-config.
Additional cleanup:
Remove unnecessary options added to COMMON_LINK_LIBS. If the openmp config is not found then OpenMP::OpenMP_CXX will be the fallback for both gcc and clang.