File tree Expand file tree Collapse file tree 3 files changed +6
-9
lines changed Expand file tree Collapse file tree 3 files changed +6
-9
lines changed Original file line number Diff line number Diff line change 7373
7474 - uses : actions/checkout@v4
7575
76- - run : ctest -S memcheck.cmake -V -E Fortran_nano_sleep
76+ - run : ctest -S memcheck.cmake -V -E " Fortran_nano_sleep|string_array"
7777
7878
7979 linux-clang :
Original file line number Diff line number Diff line change @@ -10,17 +10,14 @@ cmake_minimum_required(VERSION 3.19)
1010
1111list (APPEND opts -DCMAKE_BUILD_TYPE=Debug)
1212
13- set (CTEST_TEST_TIMEOUT 60)
14- # takes effect only if test property TIMEOUT is not set
15-
1613if (NOT DEFINED CTEST_MEMORYCHECK_TYPE)
1714 set (CTEST_MEMORYCHECK_TYPE "Valgrind" )
1815endif ()
1916
2017if (CTEST_MEMORYCHECK_TYPE STREQUAL "Valgrind" )
2118 # https://www.cprogramming.com/debugging/valgrind.html
2219 find_program (CTEST_MEMORYCHECK_COMMAND NAMES valgrind HINTS ${MEMCHECK_ROOT} REQUIRED)
23- set (CTEST_MEMORYCHECK_COMMAND_OPTIONS)
20+ set (CTEST_MEMORYCHECK_COMMAND_OPTIONS --leak-check=full )
2421 set (supp ${CMAKE_CURRENT_LIST_DIR} /valgrind.supp)
2522 if (EXISTS ${supp} )
2623 list (APPEND CTEST_MEMORYCHECK_COMMAND_OPTIONS --suppressions=${supp} )
@@ -77,10 +74,7 @@ if(NOT (ret EQUAL 0 AND err EQUAL 0))
7774 message (FATAL_ERROR "CMake configure failed: ${ret} ${err} " )
7875endif ()
7976
80- cmake_host_system_information (RESULT Ncpu QUERY NUMBER_OF_PHYSICAL_CORES)
81-
8277ctest_build (
83- PARALLEL_LEVEL ${Ncpu}
8478RETURN_VALUE ret
8579CAPTURE_CMAKE_ERROR err
8680)
@@ -96,7 +90,6 @@ EXCLUDE_LABEL ${exclude_label}
9690RETURN_VALUE ret
9791CAPTURE_CMAKE_ERROR err
9892DEFECT_COUNT count
99- PARALLEL_LEVEL ${Ncpu}
10093)
10194
10295if (NOT (ret EQUAL 0 AND err EQUAL 0))
Original file line number Diff line number Diff line change @@ -12,10 +12,14 @@ subroutine echo_c( str ) bind(C)
1212end subroutine
1313end interface
1414
15+ valgrind : block
16+
1517character (kind= c_char, len= :), allocatable :: s
1618
1719s = c_char_" Hello World!"
1820
1921call echo_c( s )
2022
23+ end block valgrind
24+
2125end program
You can’t perform that action at this time.
0 commit comments