Skip to content

Commit 29583da

Browse files
committed
Adding OMPD support
2 parents 99c5089 + 392948b commit 29583da

File tree

446 files changed

+88251
-82745
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

446 files changed

+88251
-82745
lines changed

.arcconfig

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"repository.callsign" : "OMP",
3+
"conduit_uri" : "https://reviews.llvm.org/"
4+
}

.gitignore

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
#==============================================================================#
2+
# This file specifies intentionally untracked files that git should ignore.
3+
# See: http://www.kernel.org/pub/software/scm/git/docs/gitignore.html
4+
#
5+
# This file is intentionally different from the output of `git svn show-ignore`,
6+
# as most of those are useless.
7+
#==============================================================================#
8+
9+
#==============================================================================#
10+
# File extensions to be ignored anywhere in the tree.
11+
#==============================================================================#
12+
# Temp files created by most text editors.
13+
*~
14+
# Merge files created by git.
15+
*.orig
16+
# Byte compiled python modules.
17+
*.pyc
18+
# vim swap files
19+
.*.sw?
20+
.sw?
21+
#OS X specific files.
22+
.DS_store
23+
24+
#==============================================================================#
25+
# Explicit files to ignore (only matches one).
26+
#==============================================================================#
27+
# Various tag programs
28+
tags
29+
/TAGS
30+
/GPATH
31+
/GRTAGS
32+
/GSYMS
33+
/GTAGS
34+
.gitusers
35+
36+
#==============================================================================#
37+
# Directories to ignore (do not add trailing '/'s, they skip symlinks).
38+
#==============================================================================#
39+
runtime/exports
40+
41+
# Nested build directory
42+
/build

CMakeLists.txt

Lines changed: 77 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,81 @@
11
cmake_minimum_required(VERSION 2.8 FATAL_ERROR)
22

3-
set(OPENMP_LLVM_TOOLS_DIR "" CACHE PATH "Path to LLVM tools for testing")
3+
# Add cmake directory to search for custom cmake functions.
4+
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake ${CMAKE_MODULE_PATH})
45

6+
# llvm/runtimes/ will set OPENMP_STANDALONE_BUILD.
7+
if (OPENMP_STANDALONE_BUILD OR "${CMAKE_SOURCE_DIR}" STREQUAL "${CMAKE_CURRENT_SOURCE_DIR}")
8+
set(OPENMP_STANDALONE_BUILD TRUE)
9+
project(openmp C CXX)
10+
11+
# CMAKE_BUILD_TYPE was not set, default to Release.
12+
if (NOT CMAKE_BUILD_TYPE)
13+
set(CMAKE_BUILD_TYPE Release)
14+
endif()
15+
16+
# Group common settings.
17+
set(OPENMP_ENABLE_WERROR FALSE CACHE BOOL
18+
"Enable -Werror flags to turn warnings into errors for supporting compilers.")
19+
set(OPENMP_LIBDIR_SUFFIX "" CACHE STRING
20+
"Suffix of lib installation directory, e.g. 64 => lib64")
21+
22+
# Group test settings.
23+
set(OPENMP_TEST_C_COMPILER ${CMAKE_C_COMPILER} CACHE STRING
24+
"C compiler to use for testing OpenMP runtime libraries.")
25+
set(OPENMP_TEST_CXX_COMPILER ${CMAKE_CXX_COMPILER} CACHE STRING
26+
"C++ compiler to use for testing OpenMP runtime libraries.")
27+
set(OPENMP_LLVM_TOOLS_DIR "" CACHE PATH "Path to LLVM tools for testing.")
28+
else()
29+
set(OPENMP_ENABLE_WERROR ${LLVM_ENABLE_WERROR})
30+
# If building in tree, we honor the same install suffix LLVM uses.
31+
set(OPENMP_LIBDIR_SUFFIX ${LLVM_LIBDIR_SUFFIX})
32+
33+
if (NOT MSVC)
34+
set(OPENMP_TEST_C_COMPILER ${LLVM_RUNTIME_OUTPUT_INTDIR}/clang)
35+
set(OPENMP_TEST_CXX_COMPILER ${LLVM_RUNTIME_OUTPUT_INTDIR}/clang++)
36+
else()
37+
set(OPENMP_TEST_C_COMPILER ${LLVM_RUNTIME_OUTPUT_INTDIR}/clang.exe)
38+
set(OPENMP_TEST_CXX_COMPILER ${LLVM_RUNTIME_OUTPUT_INTDIR}/clang++.exe)
39+
endif()
40+
endif()
41+
42+
# Check and set up common compiler flags.
43+
include(config-ix)
44+
include(HandleOpenMPOptions)
45+
46+
# Set up testing infrastructure.
47+
include(OpenMPTesting)
48+
49+
set(OPENMP_TEST_FLAGS "" CACHE STRING
50+
"Extra compiler flags to send to the test compiler.")
51+
set(OPENMP_TEST_OPENMP_FLAGS ${OPENMP_TEST_COMPILER_OPENMP_FLAGS} CACHE STRING
52+
"OpenMP compiler flag to use for testing OpenMP runtime libraries.")
53+
54+
55+
# Build host runtime library.
556
add_subdirectory(runtime)
57+
58+
59+
set(ENABLE_LIBOMPTARGET ON)
60+
# Currently libomptarget cannot be compiled on Windows or MacOS X.
61+
# Since the device plugins are only supported on Linux anyway,
62+
# there is no point in trying to compile libomptarget on other OSes.
63+
if (APPLE OR WIN32 OR NOT OPENMP_HAVE_STD_CPP11_FLAG)
64+
set(ENABLE_LIBOMPTARGET OFF)
65+
endif()
66+
67+
option(OPENMP_ENABLE_LIBOMPTARGET "Enable building libomptarget for offloading."
68+
${ENABLE_LIBOMPTARGET})
69+
if (OPENMP_ENABLE_LIBOMPTARGET)
70+
# Check that the library can acutally be built.
71+
if (APPLE OR WIN32)
72+
message(FATAL_ERROR "libomptarget cannot be built on Windows and MacOS X!")
73+
elseif (NOT OPENMP_HAVE_STD_CPP11_FLAG)
74+
message(FATAL_ERROR "Host compiler must support C++11 to build libomptarget!")
75+
endif()
76+
77+
add_subdirectory(libomptarget)
78+
endif()
79+
80+
# Now that we have seen all testuites, create the check-openmp target.
81+
construct_check_openmp_target()

CREDITS.txt

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,18 @@ beautification by scripts. The fields are: name (N), email (E), web-address
88
(W), PGP key ID and fingerprint (P), description (D), and snail-mail address
99
(S).
1010

11+
N: Adam Azarchs
12+
W: 10xgenomics.com
13+
D: Bug fix for lock code
14+
1115
N: Carlo Bertolli
1216
W: http://ibm.com
1317
D: IBM contributor to PowerPC support in CMake files and elsewhere.
1418

19+
N: Diego Caballero
20+
E: diego.l.caballero@gmail.com
21+
D: Fork performance improvements
22+
1523
N: Sunita Chandrasekaran
1624
D: Contributor to testsuite from OpenUH
1725

@@ -51,7 +59,3 @@ D: Making build work for FreeBSD.
5159

5260
N: Cheng Wang
5361
D: Contributor to testsuite from OpenUH
54-
55-
N: Diego Caballero
56-
E: diego.l.caballero@gmail.com
57-
D: Fork performance improvements

0 commit comments

Comments
 (0)