-
Notifications
You must be signed in to change notification settings - Fork 99
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enable Flang-RT for all Flang builders. #333
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1932,8 +1932,8 @@ | |
'builddir': "offload-runtime-openmp-amdgpu", | ||
'factory' : OpenMPBuilder.getOpenMPCMakeBuildFactory( | ||
clean=True, | ||
enable_runtimes=['openmp', 'offload'], | ||
depends_on_projects=['llvm', 'clang', 'flang', 'lld', 'offload', 'openmp'], | ||
enable_runtimes=['openmp', 'offload', 'flang-rt'], | ||
depends_on_projects=['llvm', 'clang', 'flang', 'flang-rt', 'lld', 'offload', 'openmp'], | ||
extraCmakeArgs=[ | ||
"-DCMAKE_BUILD_TYPE=Release", | ||
"-DCLANG_DEFAULT_LINKER=lld", | ||
|
@@ -1952,7 +1952,7 @@ | |
"-DTEST_SUITE_SOLLVEVV_OFFLOADING_CFLAGS=-fopenmp-targets=amdgcn-amd-amdhsa;-Xopenmp-target=amdgcn-amd-amdhsa", | ||
"-DTEST_SUITE_SOLLVEVV_OFFLOADING_LDLAGS=-fopenmp-targets=amdgcn-amd-amdhsa;-Xopenmp-target=amdgcn-amd-amdhsa", | ||
], | ||
add_lit_checks=["check-clang", "check-flang", "check-offload"], | ||
add_lit_checks=["check-clang", "check-flang", "check-flang-rt", "check-offload"], | ||
add_openmp_lit_args=["--time-tests", "--timeout 100"], | ||
)}, | ||
|
||
|
@@ -1997,8 +1997,8 @@ | |
'builddir': "openmp-offload-amdgpu-clang-flang", | ||
'factory' : OpenMPBuilder.getOpenMPCMakeBuildFactory( | ||
clean=True, | ||
enable_runtimes=['compiler-rt', 'openmp', 'offload'], | ||
depends_on_projects=['llvm','clang','lld', 'offload', 'openmp', 'mlir', 'flang', 'compiler-rt'], | ||
enable_runtimes=['compiler-rt', 'openmp', 'offload', 'flang-rt'], | ||
depends_on_projects=['llvm','clang','lld', 'offload', 'openmp', 'mlir', 'flang', 'flang-rt', 'compiler-rt'], | ||
extraCmakeArgs=[ | ||
"-DCMAKE_BUILD_TYPE=Release", | ||
"-DCLANG_DEFAULT_LINKER=lld", | ||
|
@@ -2027,7 +2027,7 @@ | |
"-DTEST_SUITE_SOLLVEVV_OFFLOADING_CFLAGS=-fopenmp-targets=amdgcn-amd-amdhsa;-Xopenmp-target=amdgcn-amd-amdhsa", | ||
"-DTEST_SUITE_SOLLVEVV_OFFLOADING_LDLAGS=-fopenmp-targets=amdgcn-amd-amdhsa;-Xopenmp-target=amdgcn-amd-amdhsa", | ||
], | ||
add_lit_checks=["check-flang", "check-offload"], | ||
add_lit_checks=["check-flang", "check-flang-rt", "check-offload"], | ||
add_openmp_lit_args=["--time-tests", "--timeout 100"], | ||
)}, | ||
|
||
|
@@ -2039,8 +2039,8 @@ | |
'factory' : OpenMPBuilder.getOpenMPCMakeBuildFactory( | ||
clean=True, | ||
test=False, # we have no GPU avail, skip runtime tests | ||
enable_runtimes=['openmp', 'compiler-rt', 'offload'], | ||
depends_on_projects=['llvm','clang', 'flang', 'lld', 'mlir', 'offload', 'openmp', 'compiler-rt'], | ||
enable_runtimes=['openmp', 'compiler-rt', 'offload', 'flang-rt'], | ||
depends_on_projects=['llvm','clang', 'flang', 'flang-rt', 'lld', 'mlir', 'offload', 'openmp', 'compiler-rt'], | ||
extraCmakeArgs=[ | ||
"-DCMAKE_BUILD_TYPE=Release", | ||
"-DCLANG_DEFAULT_LINKER=lld", | ||
|
@@ -2060,7 +2060,7 @@ | |
"-DTEST_SUITE_SOLLVEVV_OFFLOADING_CFLAGS=-fopenmp-targets=amdgcn-amd-amdhsa;-Xopenmp-target=amdgcn-amd-amdhsa", | ||
"-DTEST_SUITE_SOLLVEVV_OFFLOADING_LDLAGS=-fopenmp-targets=amdgcn-amd-amdhsa;-Xopenmp-target=amdgcn-amd-amdhsa", | ||
], | ||
add_lit_checks=["check-clang", "check-flang", "check-llvm", "check-lld", "check-mlir"], | ||
add_lit_checks=["check-clang", "check-flang", "check-flang-rt", "check-llvm", "check-lld", "check-mlir"], | ||
add_openmp_lit_args=["--time-tests", "--timeout 100"], | ||
)}, | ||
|
||
|
@@ -2071,8 +2071,8 @@ | |
'factory' : OpenMPBuilder.getOpenMPCMakeBuildFactory( | ||
clean=True, | ||
test=True, | ||
enable_runtimes=['openmp', 'compiler-rt', 'offload'], | ||
depends_on_projects=['llvm','clang', 'flang', 'lld', 'mlir', 'offload', 'openmp', 'compiler-rt'], | ||
enable_runtimes=['openmp', 'compiler-rt', 'offload', 'flang-rt'], | ||
depends_on_projects=['llvm','clang', 'flang', 'flang-rt', 'lld', 'mlir', 'offload', 'openmp', 'compiler-rt'], | ||
extraCmakeArgs=[ | ||
"-DCMAKE_BUILD_TYPE=Release", | ||
"-DCLANG_DEFAULT_LINKER=lld", | ||
|
@@ -2093,7 +2093,7 @@ | |
"-DTEST_SUITE_SOLLVEVV_OFFLOADING_CFLAGS=-fopenmp-targets=amdgcn-amd-amdhsa;-Xopenmp-target=amdgcn-amd-amdhsa", | ||
"-DTEST_SUITE_SOLLVEVV_OFFLOADING_LDLAGS=-fopenmp-targets=amdgcn-amd-amdhsa;-Xopenmp-target=amdgcn-amd-amdhsa", | ||
], | ||
add_lit_checks=["check-clang", "check-flang", "check-llvm", "check-lld", "check-mlir", "check-offload"], | ||
add_lit_checks=["check-clang", "check-flang", "check-flang-rt", "check-llvm", "check-lld", "check-mlir", "check-offload"], | ||
add_openmp_lit_args=["--time-tests", "--timeout 100", "--xfail=affinity/format/proc_bind.c"], | ||
)}, | ||
|
||
|
@@ -2104,8 +2104,8 @@ | |
'factory' : OpenMPBuilder.getOpenMPCMakeBuildFactory( | ||
clean=True, | ||
test=True, | ||
enable_runtimes=['openmp', 'compiler-rt', 'offload'], | ||
depends_on_projects=['llvm','clang', 'flang', 'lld', 'mlir', 'offload', 'openmp', 'compiler-rt'], | ||
enable_runtimes=['openmp', 'compiler-rt', 'offload', 'flang-rt'], | ||
depends_on_projects=['llvm','clang', 'flang', 'flang-rt', 'lld', 'mlir', 'offload', 'openmp', 'compiler-rt'], | ||
extraCmakeArgs=[ | ||
"-DCMAKE_BUILD_TYPE=Release", | ||
"-DCLANG_DEFAULT_LINKER=lld", | ||
|
@@ -2126,7 +2126,7 @@ | |
"-DTEST_SUITE_SOLLVEVV_OFFLOADING_CFLAGS=-fopenmp-targets=amdgcn-amd-amdhsa;-Xopenmp-target=amdgcn-amd-amdhsa", | ||
"-DTEST_SUITE_SOLLVEVV_OFFLOADING_LDLAGS=-fopenmp-targets=amdgcn-amd-amdhsa;-Xopenmp-target=amdgcn-amd-amdhsa", | ||
], | ||
add_lit_checks=["check-clang", "check-flang", "check-llvm", "check-lld", "check-mlir", "check-offload"], | ||
add_lit_checks=["check-clang", "check-flang", "check-flang-rt", "check-llvm", "check-lld", "check-mlir", "check-offload"], | ||
add_openmp_lit_args=["--time-tests", "--timeout 100", "--xfail=affinity/format/proc_bind.c"], | ||
)}, | ||
|
||
|
@@ -2319,8 +2319,8 @@ | |
'builddir': "flang-aarch64-dylib", | ||
'factory' : UnifiedTreeBuilder.getCmakeWithNinjaBuildFactory( | ||
clean=True, | ||
checks=['check-flang'], | ||
depends_on_projects=['llvm','mlir','clang','flang','openmp'], | ||
checks=['check-flang', 'check-flang-rt'], | ||
depends_on_projects=['llvm','mlir','clang','flang','flang-rt','openmp'], | ||
extra_configure_args=[ | ||
"-DLLVM_TARGETS_TO_BUILD=AArch64", | ||
"-DLLVM_BUILD_LLVM_DYLIB=ON", | ||
|
@@ -2334,8 +2334,8 @@ | |
'builddir': "flang-aarch64-sharedlibs", | ||
'factory' : UnifiedTreeBuilder.getCmakeWithNinjaBuildFactory( | ||
clean=True, | ||
checks=['check-flang'], | ||
depends_on_projects=['llvm','mlir','clang','flang','openmp'], | ||
checks=['check-flang', 'check-flang-rt'], | ||
depends_on_projects=['llvm','mlir','clang','flang','flang-rt','openmp'], | ||
extra_configure_args=[ | ||
"-DLLVM_TARGETS_TO_BUILD=AArch64", | ||
"-DBUILD_SHARED_LIBS=ON", | ||
|
@@ -2367,8 +2367,8 @@ | |
'builddir': "flang-aarch64-debug-reverse-iteration", | ||
'factory' : UnifiedTreeBuilder.getCmakeWithNinjaBuildFactory( | ||
clean=True, | ||
checks=['check-flang'], | ||
depends_on_projects=['llvm','mlir','clang','flang','openmp'], | ||
checks=['check-flang','check-flang-rt'], | ||
depends_on_projects=['llvm','mlir','clang','flang','flang-rt','openmp'], | ||
extra_configure_args=[ | ||
"-DLLVM_TARGETS_TO_BUILD=AArch64", | ||
"-DCMAKE_BUILD_TYPE=Debug", | ||
|
@@ -2383,8 +2383,8 @@ | |
'builddir': "flang-aarch64-libcxx", | ||
'factory' : UnifiedTreeBuilder.getCmakeWithNinjaBuildFactory( | ||
clean=True, | ||
checks=['check-flang'], | ||
depends_on_projects=['llvm','mlir','clang','flang'], | ||
checks=['check-flang','check-flang-rt'], | ||
depends_on_projects=['llvm','mlir','clang','flang','flang-rt'], | ||
extra_configure_args=[ | ||
"-DLLVM_TARGETS_TO_BUILD=AArch64", | ||
"-DLLVM_INSTALL_UTILS=ON", | ||
|
@@ -2403,8 +2403,8 @@ | |
'builddir': "flang-aarch64-release", | ||
'factory' : UnifiedTreeBuilder.getCmakeWithNinjaBuildFactory( | ||
clean=True, | ||
checks=['check-flang'], | ||
depends_on_projects=['llvm','mlir','clang','flang','openmp'], | ||
checks=['check-flang','check-flang-rt'], | ||
depends_on_projects=['llvm','mlir','clang','flang','flang-rt','openmp'], | ||
extra_configure_args=[ | ||
"-DLLVM_TARGETS_TO_BUILD=AArch64", | ||
"-DCMAKE_BUILD_TYPE=Release", | ||
|
@@ -2418,8 +2418,8 @@ | |
'builddir': "flang-aarch64-rel-assert", | ||
'factory' : UnifiedTreeBuilder.getCmakeWithNinjaBuildFactory( | ||
clean=True, | ||
checks=['check-flang'], | ||
depends_on_projects=['llvm','mlir','clang','flang','openmp'], | ||
checks=['check-flang','check-flang-rt'], | ||
depends_on_projects=['llvm','mlir','clang','flang','flang-rt','openmp'], | ||
extra_configure_args=[ | ||
"-DLLVM_TARGETS_TO_BUILD=AArch64", | ||
"-DLLVM_ENABLE_ASSERTIONS=ON", | ||
|
@@ -2434,8 +2434,8 @@ | |
'builddir': "flang-aarch64-latest-gcc", | ||
'factory' : UnifiedTreeBuilder.getCmakeWithNinjaBuildFactory( | ||
clean=True, | ||
checks=['check-flang'], | ||
depends_on_projects=['llvm','mlir','clang','flang','openmp'], | ||
checks=['check-flang','check-flang-rt'], | ||
depends_on_projects=['llvm','mlir','clang','flang','flang-rt','openmp'], | ||
extra_configure_args=[ | ||
"-DLLVM_TARGETS_TO_BUILD=AArch64", | ||
"-DLLVM_INSTALL_UTILS=ON", | ||
|
@@ -2451,7 +2451,7 @@ | |
'workernames' : ["alcf-theta-flang"], | ||
'builddir': "flang-x86_64-knl-linux", | ||
'factory' : UnifiedTreeBuilder.getCmakeWithNinjaBuildFactory( | ||
depends_on_projects=['llvm','mlir','clang','flang'], | ||
depends_on_projects=['llvm','mlir','clang','flang','flang-rt'], | ||
extra_configure_args=[ | ||
"-DLLVM_TARGETS_TO_BUILD=X86", | ||
"-DCMAKE_C_COMPILER=gcc", | ||
|
@@ -2467,8 +2467,8 @@ | |
'builddir': 'ppc64le-flang-rhel-clang-build', | ||
'factory' : UnifiedTreeBuilder.getCmakeWithNinjaBuildFactory( | ||
clean=True, | ||
depends_on_projects=['llvm', 'mlir', 'clang', 'flang','openmp'], | ||
checks=['check-flang'], | ||
depends_on_projects=['llvm', 'mlir', 'clang', 'flang', 'flang-rt', 'openmp'], | ||
checks=['check-flang','check-flang-rt'], | ||
extra_configure_args=[ | ||
'-DLLVM_TARGETS_TO_BUILD=PowerPC', | ||
'-DLLVM_INSTALL_UTILS=ON', | ||
|
@@ -2490,8 +2490,8 @@ | |
'workernames' : ["minipc-ryzen-win"], | ||
'builddir': "flang-x86_64-windows", | ||
'factory' : UnifiedTreeBuilder.getCmakeWithNinjaBuildFactory( | ||
depends_on_projects=['llvm','mlir','clang','flang'], | ||
checks=['check-flang'], | ||
depends_on_projects=['llvm','mlir','clang','flang','flang-rt'], | ||
checks=['check-flang','check-flang-rt'], | ||
install_dir="flang.install", | ||
extra_configure_args=[ | ||
"-DCLANG_ENABLE_STATIC_ANALYZER=OFF", | ||
|
@@ -3118,17 +3118,15 @@ | |
'workernames' : ["as-builder-7"], | ||
'builddir': "flang-runtime-cuda-gcc", | ||
'factory' : UnifiedTreeBuilder.getCmakeWithNinjaBuildFactory( | ||
depends_on_projects=["flang"], | ||
depends_on_projects=["flang","flang-rt"], | ||
clean=True, | ||
checks=[], | ||
src_to_build_dir="flang/runtime", | ||
targets=["FortranRuntime"], | ||
extra_configure_args=[ | ||
"-DCMAKE_BUILD_TYPE=Release", | ||
"-DCMAKE_EXPORT_COMPILE_COMMANDS=ON", | ||
"-DLLVM_ENABLE_ASSERTIONS=ON", | ||
"-DBUILD_SHARED_LIBS=OFF", | ||
"-DFLANG_EXPERIMENTAL_CUDA_RUNTIME=ON", | ||
"-DFLANG_RT_EXPERIMENTAL_OFFLOAD_SUPPORT=CUDA", | ||
"-DCMAKE_CUDA_COMPILER=/usr/local/cuda/bin/nvcc", | ||
"-DCMAKE_CXX_COMPILER=/usr/bin/g++", | ||
"-DCMAKE_C_COMPILER=/usr/bin/gcc", | ||
|
@@ -3138,7 +3136,7 @@ | |
"-DCMAKE_CUDA_COMPILER_LAUNCHER=ccache", | ||
"-DCMAKE_CXX_COMPILER_LAUNCHER=ccache", | ||
"-DCMAKE_C_COMPILER_LAUNCHER=ccache", | ||
util.Interpolate("-DFLANG_LIBCUDACXX_PATH=%(prop:nv_cccl_root_path)s/libcudacxx"), | ||
util.Interpolate("-DFLANG_RT_LIBCUDACXX_PATH=%(prop:nv_cccl_root_path)s/libcudacxx"), | ||
], | ||
env={ | ||
'CCACHE_DIR' : util.Interpolate("%(prop:builddir)s/ccache-db"), | ||
|
@@ -3156,7 +3154,7 @@ | |
stages = [ | ||
dict( | ||
name = "clang", | ||
depends_on_projects = ["llvm", "clang", "clang-tools-extra", "lld", "openmp"], | ||
depends_on_projects = ["llvm", "clang", "clang-tools-extra", "lld", "openmp", "flang"], | ||
enable_runtimes = ["compiler-rt"], | ||
cmake_definitions = { | ||
"LLVM_CCACHE_BUILD" : "ON", | ||
|
@@ -3172,16 +3170,17 @@ | |
), | ||
dict( | ||
name = "flang-runtime", | ||
depends_on_projects = ["flang"], | ||
depends_on_projects = ["flang-rt"], | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. must be a list of the following projects: clang, flang
also should be added |
||
cmake_definitions = { | ||
"CMAKE_BUILD_TYPE" : "Release", | ||
"CMAKE_C_COMPILER" : util.Interpolate("%(prop:builddir)s/install-clang/bin/clang"), | ||
"CMAKE_CXX_COMPILER" : util.Interpolate("%(prop:builddir)s/install-clang/bin/clang++"), | ||
"FLANG_EXPERIMENTAL_OMP_OFFLOAD_BUILD" : "host_device", | ||
"FLANG_OMP_DEVICE_ARCHITECTURES" : "sm_50;sm_60;sm_70;sm_80", | ||
"CMAKE_Fortran_COMPILER" : util.Interpolate("%(prop:builddir)s/install-clang/bin/flang"), | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. got the following warning during the build stage configuring with CMake:
probably was used wrong variable name. |
||
"FLANG_RT_EXPERIMENTAL_OFFLOAD_SUPPORT" : "OpenMP", | ||
"FLANG_RT_DEVICE_ARCHITECTURES" : "sm_50;sm_60;sm_70;sm_80", | ||
}, | ||
targets = ["FortranRuntime"], | ||
src_to_build_dir = "flang/runtime", | ||
targets = ["flang_rt"], | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. must be "flang-rt" instead of "flang_rt"
|
||
src_to_build_dir = "flang-rt", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this line must be removed. There is no |
||
), | ||
], | ||
env = { | ||
|
@@ -3309,7 +3308,7 @@ | |
'builddir': "premerge-monolithic-windows", | ||
'factory' : UnifiedTreeBuilder.getCmakeWithNinjaWithMSVCBuildFactory( | ||
vs="autodetect", | ||
depends_on_projects=["clang-tools-extra", "clang", "flang", "libclc", "lld", "llvm", "mlir", "polly", "pstl"], | ||
depends_on_projects=["clang-tools-extra", "clang", "flang", "flang-rt", "libclc", "lld", "llvm", "mlir", "polly", "pstl"], | ||
checks=["check-all"], | ||
install_pip_requirements = True, | ||
extra_configure_args=[ | ||
|
@@ -3329,7 +3328,7 @@ | |
'workernames': ["premerge-linux-1"], | ||
'builddir': "premerge-monolithic-linux", | ||
'factory': UnifiedTreeBuilder.getCmakeWithNinjaBuildFactory( | ||
depends_on_projects=["bolt", "clang", "clang-tools-extra", "compiler-rt", "flang", "libc", "libclc", "lld", "llvm", "mlir", "polly", "pstl"], | ||
depends_on_projects=["bolt", "clang", "clang-tools-extra", "compiler-rt", "flang", "flang-rt", "libc", "libclc", "lld", "llvm", "mlir", "polly", "pstl"], | ||
install_pip_requirements = True, | ||
extra_configure_args=[ | ||
"-DCMAKE_BUILD_TYPE=Release", | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,6 +12,7 @@ | |
"libcxxabi", | ||
"libunwind", | ||
"openmp", | ||
"flang-rt", | ||
]) | ||
|
||
class LLVMBuildFactory(BuildFactory): | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be a list of the following project: clang, flang
flang-rt
is not a valid project currentlycould be added
enable_runtimes = ["flang-rt"],