Skip to content
1 change: 1 addition & 0 deletions bin/build_llvm-flang-rt-host-dev.sh
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ ${AOMP_CMAKE} "${AOMP_SET_NINJA_GEN[@]}" $CM_BUILD_TYPE \
-DCMAKE_CXX_COMPILER="$CMAKE_CXX_COMPILER" \
-DFLANG_RT_DEVICE_ARCHITECTURES="$ARCH_LIST" \
-DCMAKE_EXPORT_COMPILE_COMMANDS=ON \
-DFLANG_RT_EMBED_GPU_LLVM_IR=OFF \
"$AOMP_REPOS/llvm-project/runtimes"

$AOMP_NINJA_BIN --version
Expand Down
9 changes: 7 additions & 2 deletions bin/build_project.sh
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ MYCMAKEOPTS=(-DCMAKE_BUILD_TYPE="$BUILD_TYPE"
if [ -f "$AOMP_REPOS/$AOMP_PROJECT_REPO_NAME/openmp/device/CMakeLists.txt" ]; then
MYCMAKEOPTS=("${MYCMAKEOPTS[@]}"
-DLLVM_RUNTIME_TARGETS='default;amdgcn-amd-amdhsa'
-DRUNTIMES_amdgcn-amd-amdhsa_LLVM_ENABLE_RUNTIMES='openmp'
-DRUNTIMES_amdgcn-amd-amdhsa_LLVM_ENABLE_RUNTIMES='compiler-rt;libc;libcxx;libcxxabi;flang-rt;openmp'
-DRUNTIMES_amdgcn-amd-amdhsa_LLVM_ENABLE_PER_TARGET_RUNTIME_DIR=ON)
fi

Expand All @@ -167,7 +167,12 @@ MYCMAKEOPTS=("${MYCMAKEOPTS[@]}"
-DCLANG_ENABLE_AMDCLANG=ON
-DLLVM_ENABLE_RUNTIMES="$LLVM_RUNTIMES"
-DLIBCXX_ENABLE_STATIC=ON
-DLIBCXXABI_ENABLE_STATIC=ON)
-DLIBCXXABI_ENABLE_STATIC=ON
-DLLVM_RUNTIME_TARGETS="default;amdgcn-amd-amdhsa"
-DRUNTIMES_amdgcn-amd-amdhsa_FLANG_RT_LIBC_PROVIDER=llvm
-DRUNTIMES_amdgcn-amd-amdhsa_FLANG_RT_LIBCXX_PROVIDER=llvm
-DRUNTIMES_amdgcn-amd-amdhsa_CACHE_FILES="$AOMP_REPOS/$AOMP_PROJECT_REPO_NAME/libcxx/cmake/caches/AMDGPU.cmake"
)

# Enable Compiler-rt Sanitizer Build
if [ "$AOMP_BUILD_SANITIZER" == 1 ]; then
Expand Down
2 changes: 1 addition & 1 deletion bin/build_supp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,7 @@ function buildfftw(){

function buildcmake(){
_cname="cmake"
_version=3.25.2
_version=4.1.2
_installdir=$AOMP_SUPP_INSTALL/$_cname-$_version
_linkfrom=$AOMP_SUPP/$_cname
_builddir=$AOMP_SUPP_BUILD/$_cname
Expand Down
2 changes: 1 addition & 1 deletion bin/run_genasis_flang_new.sh
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ fi
export LD_LIBRARY_PATH=$AOMP/lib:$AOMPHIP/lib:$OPENMPI_DIR/lib:$LD_LIBRARY_PATH
export FORTRAN_COMPILE="$AOMP/bin/$FLANG -c -fopenmp --offload-arch=$GPU_ID -fPIC -I$OPENMPI_DIR/lib -cpp $OMP_DEFINES -fstack-arrays"
export CC_COMPILE="$AOMP/bin/clang -fPIC"
export FORTDEV_LIBS=${FORTDEV_LIBS:-"-lflang_rt.hostdevice"}
export FORTDEV_LIBS=${FORTDEV_LIBS}
export FORTHOST_LIBS=${FORTHOST_LIBS:-"-lflang_rt.runtime"}
export OTHER_LIBS="-lm -L$AOMP/lib $FORTHOST_LIBS $FORTDEV_LIBS -lomp -lomptarget -z muldefs "
export FORTRAN_LINK="$AOMP/bin/clang $OTHER_LIBS"
Expand Down
2 changes: 1 addition & 1 deletion bin/run_umt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ if [ "$1" == "build_umt" ]; then
-DUMPIRE_ROOT=$AOMP_REPOS_TEST/$UMPIRE_SRC_DIR/install \
-DCAMP_ROOT=$AOMP_REPOS_TEST/$CAMP_SRC_DIR/install \
-DCMAKE_C_COMPILER=$CC -DCMAKE_CXX_COMPILER=$CXX -DCMAKE_Fortran_COMPILER=$FC \
-DCMAKE_FORTRAN_OFFLOAD_LIB=$AOMP/lib/libflang_rt.hostdevice.a \
-DCMAKE_FORTRAN_OFFLOAD_LIB=$FLANG_GPU_LINK_FLAGS \
-DCMAKE_Fortran_LINKER_WRAPPER_FLAG="-Wl," \
-DENABLE_CUDA=OFF \
-DENABLE_OPENMP=ON -DOPENMP_HAS_FORTRAN_INTERFACE=ON \
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/device_aassign/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG ?= flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/device_intrinsics/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)
FLANG ?= flang
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
#-ccc-print-phases
#"-\#\#\#"

Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/flang-315421/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ TESTSRC_ALL = $(TESTSRC_AUX) $(TESTSRC_MAIN)
FLANG ?= flang
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_FLAGS += -DFAIL

include ../Makefile.rules
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/flang-464660-2/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)
FLANG ?= flang
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
OMP_FLAGS += -lflang_rt.hostdevice
OMP_FLAGS += $(FLANG_GPU_LINK_FLAGS)
#-ccc-print-phases
#"-\#\#\#"

Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/flang-523626/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG ?= flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/flang-529628/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG ?= flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/rocm-issue-201/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG ?= flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/target-cmplx4-div/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG = flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
3 changes: 1 addition & 2 deletions test/smoke-fort-dev/target-cmplx8-div/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,9 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG = flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
CFLAGS = -lflang_rt.hostdevice
#-ccc-print-phases
#"-\#\#\#"

Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/tgt-abort-lhostdev/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG ?= flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/tgt-firstprivate/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN)

FLANG ?= flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/tgt-print-hello-lhostdev/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG ?= flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/tgt-print-val-lhostdev/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG ?= flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/tgt-stop-lhostdev/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG ?= flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-dev/tgt-write-lhostdev/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG ?= flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-fails/flang-535320/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG = flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-fails/flang-535416-O0/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG = flang
CFLAGS = -O0 -lflang_rt.hostdevice
CFLAGS = -O0 $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-fails/flang-535416-O2/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG = flang
CFLAGS = -O2 -lflang_rt.hostdevice
CFLAGS = -O2 $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down
2 changes: 1 addition & 1 deletion test/smoke-fort-fails/flang-537499/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ TESTSRC_AUX =
TESTSRC_ALL = $(TESTSRC_MAIN) $(TESTSRC_AUX)

FLANG = flang
CFLAGS = -lflang_rt.hostdevice
CFLAGS = $(FLANG_GPU_LINK_FLAGS)
OMP_BIN = $(AOMP)/bin/$(FLANG)
CC = $(OMP_BIN) $(VERBOSE)
#-ccc-print-phases
Expand Down