-
-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
openmp v18.1.1
- Loading branch information
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
From c553881877d57c30693ede93684851210ea78d30 Mon Sep 17 00:00:00 2001 | ||
From: Alexandre Ganea <[email protected]> | ||
Date: Wed, 31 Jan 2024 13:22:19 -0500 | ||
Subject: [PATCH 1/2] [openmp] On Windows, fix standalone cmake build | ||
|
||
This fixes: https://github.com/llvm/llvm-project/issues/80117 | ||
--- | ||
openmp/cmake/HandleOpenMPOptions.cmake | 8 ++++++++ | ||
1 file changed, 8 insertions(+) | ||
|
||
diff --git a/openmp/cmake/HandleOpenMPOptions.cmake b/openmp/cmake/HandleOpenMPOptions.cmake | ||
index 201aeabbd3df..71346201129b 100644 | ||
--- a/openmp/cmake/HandleOpenMPOptions.cmake | ||
+++ b/openmp/cmake/HandleOpenMPOptions.cmake | ||
@@ -9,6 +9,14 @@ if (NOT COMMAND append_if) | ||
endfunction() | ||
endif() | ||
|
||
+if (NOT COMMAND append) | ||
+ function(append value) | ||
+ foreach(variable ${ARGN}) | ||
+ set(${variable} "${${variable}} ${value}" PARENT_SCOPE) | ||
+ endforeach(variable) | ||
+ endfunction() | ||
+endif() | ||
+ | ||
# MSVC and clang-cl in compatibility mode map -Wall to -Weverything. | ||
# TODO: LLVM adds /W4 instead, check if that works for the OpenMP runtimes. | ||
if (NOT MSVC) |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
From 9fd9c8c26219bf8995321b7786e853d6c51e1dc8 Mon Sep 17 00:00:00 2001 | ||
From: "H. Vetinari" <[email protected]> | ||
Date: Thu, 1 Feb 2024 12:29:07 +0100 | ||
Subject: [PATCH 2/2] link libomp to compiler-rt on osx-arm | ||
|
||
--- | ||
openmp/runtime/src/CMakeLists.txt | 6 ++++++ | ||
1 file changed, 6 insertions(+) | ||
|
||
diff --git a/openmp/runtime/src/CMakeLists.txt b/openmp/runtime/src/CMakeLists.txt | ||
index 619d4f7ba458..11d9c969e381 100644 | ||
--- a/openmp/runtime/src/CMakeLists.txt | ||
+++ b/openmp/runtime/src/CMakeLists.txt | ||
@@ -161,6 +161,12 @@ if(OPENMP_STANDALONE_BUILD OR (NOT OPENMP_ENABLE_LIBOMP_PROFILING)) | ||
add_library(omp ${LIBOMP_LIBRARY_KIND} ${LIBOMP_SOURCE_FILES}) | ||
# Linking command will include libraries in LIBOMP_CONFIGURED_LIBFLAGS | ||
target_link_libraries(omp ${LIBOMP_CONFIGURED_LIBFLAGS} ${LIBOMP_DL_LIBS}) | ||
+ if(APPLE AND CMAKE_SYSTEM_PROCESSOR STREQUAL "arm64") | ||
+ cmake_path(SET CLANG_RT_BUILTINS_LIBRARY | ||
+ NORMALIZE | ||
+ "$ENV{PREFIX}/lib/clang/$ENV{PKG_VERSION_MAJOR}/lib/libclang_rt.builtins_arm64_osx.a") | ||
+ target_link_libraries(omp ${CLANG_RT_BUILTINS_LIBRARY}) | ||
+ endif() | ||
else() | ||
add_llvm_library(omp ${LIBOMP_LIBRARY_KIND} ${LIBOMP_SOURCE_FILES} PARTIAL_SOURCES_INTENDED | ||
LINK_LIBS ${LIBOMP_CONFIGURED_LIBFLAGS} ${LIBOMP_DL_LIBS} |