File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -99,8 +99,6 @@ register_flag_optional(OFFLOAD_APPEND_LINK_FLAG
9999
100100
101101macro (setup )
102- set (CMAKE_CXX_STANDARD 17)
103-
104102 find_package (OpenMP REQUIRED )
105103 register_link_library (OpenMP::OpenMP_CXX )
106104
Original file line number Diff line number Diff line change @@ -50,13 +50,16 @@ run_build() {
5050 -DCMAKE_BUILD_TYPE=Release \
5151 -DCMAKE_VERBOSE_MAKEFILE=ON \
5252 -DMODEL=" $model " $flags & >> " $log "
53+ local model_lower=$( echo " $model " | awk ' {print tolower($0)}' )
54+
5355 local cmake_code=$?
5456
55- " $CMAKE_BIN " --build " $build " --target babelstream - j " $( nproc) " & >> " $log "
57+ " $CMAKE_BIN " --build " $build " -j " $( nproc) " & >> " $log "
5658 local cmake_code=$?
5759 set -e
5860
59- local bin=" ./$build /babelstream"
61+ local bin=" ./$build /$model_lower -stream"
62+ echo " Checking for final executable: $bin "
6063 if [[ -f " $bin " ]]; then
6164 echo " $( tput setaf 2) [PASS!]($model ->$build )$( tput sgr0) : -DMODEL=$model $flags "
6265 # shellcheck disable=SC2002
@@ -119,7 +122,7 @@ build_gcc() {
119122 if [ " $MODEL " = " all" ] || [ " $MODEL " = " OMP" ]; then
120123 # sanity check that it at least runs
121124 echo " Sanity checking GCC OMP build..."
122- " ./$BUILD_DIR /OMP_$name /babelstream " -s 1048576 -n 10
125+ " ./$BUILD_DIR /OMP_$name /omp-stream " -s 1048576 -n 10
123126 fi
124127
125128 # some distributions like Ubuntu bionic implements std par with TBB, so conditionally link it here
Original file line number Diff line number Diff line change @@ -136,5 +136,11 @@ macro(load_model MODEL)
136136 include (${MODEL_FILE} )
137137 list (APPEND IMPL_SOURCES ${IMPL_${MODEL_UPPER} _SOURCES})
138138 list (APPEND IMPL_DEFINITIONS ${IMPL_${MODEL_UPPER} _DEFINITIONS})
139+
140+ string (TOLOWER ${MODEL} MODEL_LOWER)
141+ set (EXE_NAME ${MODEL_LOWER} -stream)
142+
143+ else ()
144+ message (FATAL_ERROR "Unsupported model: ${MODEL} " )
139145 endif ()
140146endmacro ()
You can’t perform that action at this time.
0 commit comments