Skip to content

Commit 2904de8

Browse files
committed
Limit new tests to proper compiler compatibility
1 parent d52a5df commit 2904de8

File tree

2 files changed

+38
-25
lines changed

2 files changed

+38
-25
lines changed

CMakeLists.txt

Lines changed: 31 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -644,8 +644,27 @@ if(opencoarrays_aware_compiler)
644644
add_caf_test(async_comp_alloc_2 2 async_comp_alloc_2)
645645
add_caf_test(comp_allocated_1 2 comp_allocated_1)
646646
add_caf_test(comp_allocated_2 2 comp_allocated_2)
647-
add_caf_test(get_with_vector_index 4 get_with_vector_index)
648-
add_caf_test(send_with_vector_index 2 send_with_vector_index)
647+
endif()
648+
649+
650+
if (gfortran_compiler)
651+
if((NOT CMAKE_Fortran_COMPILER_VERSION VERSION_LESS 7.0.0) OR (CAF_RUN_DEVELOPER_TESTS OR $ENV{OPENCOARRAYS_DEVELOPER}))
652+
add_caf_test(send_convert_nums 2 send_convert_nums)
653+
add_caf_test(sendget_convert_nums 3 sendget_convert_nums)
654+
add_caf_test(sendget_convert_char_array 3 sendget_convert_char_array)
655+
656+
elseif((NOT CMAKE_Fortran_COMPILER_VERSION VERSION_LESS 7.3.0) OR (CAF_RUN_DEVELOPER_TESTS OR $ENV{OPENCOARRAYS_DEVELOPER}))
657+
add_caf_test(send_with_vector_index 2 send_with_vector_index)
658+
add_caf_test(send_convert_char_array 2 send_convert_char_array)
659+
else()#if((CAF_RUN_DEVELOPER_TESTS OR $ENV{OPENCOARRAYS_DEVELOPER}))
660+
message( AUTHOR_WARNING "The following tests may be skipped due to GFortran < 7.3.0 or < 7.0.0 lack of compatibility:
661+
sendget_convert_nums.f90 (>= 7.0.0)
662+
sendget_convert_char_array.f90 (>= 7.0.0)
663+
send_convert_nums.f90 (>= 7.0.0)
664+
send_convert_char_array.f90 (>= 7.3.0)
665+
send_with_vector_index.f90 (>= 7.3.0)"
666+
)
667+
endif()
649668
endif()
650669

651670
# Pure get tests
@@ -659,15 +678,11 @@ if(opencoarrays_aware_compiler)
659678

660679
# Pure send tests
661680
add_caf_test(send_array 2 send_array)
662-
add_caf_test(send_convert_char_array 2 send_convert_char_array)
663681

664682
# Pure sendget tests
665-
add_caf_test(sendget_convert_char_array 3 sendget_convert_char_array)
666683
add_caf_test(strided_sendget 3 strided_sendget)
667-
if (gfortran_compiler AND (NOT CMAKE_Fortran_COMPILER_VERSION VERSION_LESS 7.3.0))
668-
add_caf_test(sendget_convert_nums 3 sendget_convert_nums)
669-
add_caf_test(send_convert_nums 2 send_convert_nums)
670-
endif()
684+
add_caf_test(get_with_vector_index 4 get_with_vector_index)
685+
671686

672687
add_caf_test(co_sum 4 co_sum_test)
673688
add_caf_test(co_broadcast 4 co_broadcast_test)
@@ -690,7 +705,7 @@ if(opencoarrays_aware_compiler)
690705
# Integration tests verifying the use of libcaf_mpi in applications
691706
add_caf_test(hello_multiverse 2 hello_multiverse)
692707
add_caf_test(coarray_burgers_pde 2 coarray_burgers_pde)
693-
# add_caf_test(co_heat 2 co_heat)
708+
add_caf_test(co_heat 2 co_heat)
694709
add_caf_test(asynchronous_hello_world 3 asynchronous_hello_world)
695710

696711
# Regression tests based on reported issues
@@ -703,10 +718,14 @@ if(opencoarrays_aware_compiler)
703718
endif()
704719

705720
# Open GCC 7 regressions
706-
if ((CAF_RUN_DEVELOPER_TESTS OR $ENV{OPENCOARRAYS_DEVELOPER}) OR (gfortran_compiler AND (CMAKE_Fortran_COMPILER_VERSION VERSION_LESS 7.0.0)))
721+
if ((CAF_RUN_DEVELOPER_TESTS OR $ENV{OPENCOARRAYS_DEVELOPER}) OR
722+
(gfortran_compiler AND (
723+
(CMAKE_Fortran_COMPILER_VERSION VERSION_LESS 7.0.0) OR
724+
(NOT CMAKE_Fortran_COMPILER_VERSION VERSION_LESS 7.3.0)
725+
)))
707726
add_caf_test(convert-before-put 3 convert-before-put)
708-
add_caf_test(put-alloc-comp 2 issue-422-send)
709-
add_caf_test(get-put-alloc-comp 3 issue-422-send-get)
727+
add_caf_test(put-allocatable-coarray-comp 2 issue-422-send)
728+
add_caf_test(get-put-allocatable-comp 3 issue-422-send-get)
710729
endif()
711730

712731
add_caf_test(allocatable_p2p_event_post 4 allocatable_p2p_event_post)

src/tests/unit/send-get/CMakeLists.txt

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -14,24 +14,18 @@ caf_compile_executable(get_with_vector_index get_with_vector_index.f90)
1414

1515
## Pure send() tests
1616
caf_compile_executable(send_array send_array_test.f90)
17-
caf_compile_executable(send_convert_char_array send_convert_char_array.f90)
17+
if(NOT CMAKE_Fortran_COMPILER_VERSION VERSION_LESS 7.0.0)
18+
caf_compile_executable(send_convert_nums send_convert_nums.f90)
19+
endif()
1820
caf_compile_executable(send_with_vector_index send_with_vector_index.f90)
1921

2022
# Pure sendget() tests
2123
caf_compile_executable(sendget_convert_char_array sendget_convert_char_array.f90)
24+
if(NOT CMAKE_Fortran_COMPILER_VERSION VERSION_LESS 7.0.0)
25+
caf_compile_executable(sendget_convert_nums sendget_convert_nums.f90)
26+
endif()
27+
caf_compile_executable(send_convert_char_array send_convert_char_array.f90)
2228
#caf_compile_executable(sendget_with_vector_index sendget_with_vector_index.f90)
2329
caf_compile_executable(strided_sendget strided_sendget.f90)
2430
set_target_properties(build_strided_sendget
2531
PROPERTIES MIN_IMAGES 3)
26-
27-
if (gfortran_compiler AND (NOT CMAKE_Fortran_COMPILER_VERSION VERSION_LESS 7.3.0))
28-
caf_compile_executable(sendget_convert_nums sendget_convert_nums.f90)
29-
caf_compile_executable(send_convert_nums send_convert_nums.f90)
30-
elseif((CAF_RUN_DEVELOPER_TESTS OR $ENV{OPENCOARRAYS_DEVELOPER}))
31-
message( AUTHOR_WARNING
32-
"Skipping building the following tests due to GFortran < 7.3.0 lack of compatibility:
33-
sendget_convert_nums.f90"
34-
)
35-
36-
endif()
37-

0 commit comments

Comments
 (0)