Skip to content

Commit

Permalink
rename cmake test in consistant with HPX
Browse files Browse the repository at this point in the history
  • Loading branch information
tianyizhangcs committed Oct 15, 2019
1 parent 8002b7b commit d901eab
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 35 deletions.
4 changes: 2 additions & 2 deletions examples/ompt/CMakeLists.txt
Expand Up @@ -5,6 +5,6 @@

if(HPXMP_WITH_OMPT)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fopenmp")
add_executable(ex_ompt_hello_world hello_world.cpp)
add_executable(ex_ompt_task task_ex.cpp)
add_executable(examples.ompt.hello_world hello_world.cpp)
add_executable(examples.ompt.task task_ex.cpp)
endif()
2 changes: 1 addition & 1 deletion examples/openmp/CMakeLists.txt
Expand Up @@ -5,5 +5,5 @@

if(HPXMP_WITH_OMPT)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fopenmp")
add_executable(ex_hello_world hello_world.cpp)
add_executable(examples.omp.hello_world hello_world.cpp)
endif()
4 changes: 2 additions & 2 deletions tests/ompt/CMakeLists.txt
Expand Up @@ -37,7 +37,7 @@ if(HPXMP_WITH_OMPT)

foreach(test ${tests})
set(sources ${test}.cpp)
add_executable(${test} ${sources})
do_test(${test})
add_executable(tests.omp.${test} ${sources})
do_test(tests.omp.${test})
endforeach()
endif()
4 changes: 2 additions & 2 deletions tests/openmp/regressions/CMakeLists.txt
Expand Up @@ -28,6 +28,6 @@ endmacro(do_test)

foreach(test ${tests})
set(sources ${test}.cpp)
add_executable(${test} ${sources})
do_test(${test})
add_executable(tests.omp.regression.${test} ${sources})
do_test(tests.omp.regression.${test})
endforeach()
33 changes: 5 additions & 28 deletions tests/openmp/unit/CMakeLists.txt
Expand Up @@ -8,6 +8,7 @@ set(tests
app_lu
app_old_fib
app_vla
atomic
barrier
critical
critical_2
Expand All @@ -21,7 +22,6 @@ set(tests
for_static
master
max_threads
omp_atomic
par_for
par_nested
par_single
Expand Down Expand Up @@ -52,45 +52,22 @@ macro(do_test name)
CXX_STANDARD_REQUIRED ON
CXX_EXTENSIONS OFF
)
#maybe make the omp_num_threads configurable later
set_tests_properties(${name} PROPERTIES
ENVIRONMENT "LD_PRELOAD=${PROJECT_BINARY_DIR}/libhpxmp.so;OMP_NUM_THREADS=2"
TIMEOUT 50
)
endmacro(do_test)

macro(do_test_enhanced name)
add_test(${name} ${name})
set_target_properties(${name} PROPERTIES
CXX_STANDARD 11
CXX_STANDARD_REQUIRED ON
CXX_EXTENSIONS OFF
)
#maybe make the omp_num_threads configurable later
set_tests_properties(${name} PROPERTIES
ENVIRONMENT "LD_PRELOAD=${PROJECT_BINARY_DIR}/libhpxmp.so;OMP_NUM_THREADS=2"
TIMEOUT 60
)
endmacro(do_test_enhanced)



foreach(test ${tests})
set(sources ${test}.cpp)
add_executable(${test} ${sources})
do_test(${test})
endforeach()

foreach(test ${tests_enhanced})
set(sources ${test}.cpp)
add_executable(${test} ${sources})
do_test_enhanced(${test})
add_executable(tests.omp.unit.${test} ${sources})
do_test(tests.omp.unit.${test})
endforeach()

if(HPXMP_WITH_OMP_50_ENABLED)
foreach(test ${tests_omp50})
set(sources ${test}.cpp)
add_executable(${test} ${sources})
do_test_enhanced(${test})
add_executable(tests.omp.unit.${test} ${sources})
do_test(tests.omp.unit.${test})
endforeach()
endif()
File renamed without changes.

0 comments on commit d901eab

Please sign in to comment.