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 73
73
74
74
- uses : actions/checkout@v4
75
75
76
- - run : ctest -S memcheck.cmake -V -E Fortran_nano_sleep
76
+ - run : ctest -S memcheck.cmake -V -E " Fortran_nano_sleep|string_array"
77
77
78
78
79
79
linux-clang :
Original file line number Diff line number Diff line change @@ -10,17 +10,14 @@ cmake_minimum_required(VERSION 3.19)
10
10
11
11
list (APPEND opts -DCMAKE_BUILD_TYPE=Debug )
12
12
13
- set (CTEST_TEST_TIMEOUT 60 )
14
- # takes effect only if test property TIMEOUT is not set
15
-
16
13
if (NOT DEFINED CTEST_MEMORYCHECK_TYPE )
17
14
set (CTEST_MEMORYCHECK_TYPE "Valgrind" )
18
15
endif ()
19
16
20
17
if (CTEST_MEMORYCHECK_TYPE STREQUAL "Valgrind" )
21
18
# https://www.cprogramming.com/debugging/valgrind.html
22
19
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 )
24
21
set (supp ${CMAKE_CURRENT_LIST_DIR} /valgrind.supp )
25
22
if (EXISTS ${supp} )
26
23
list (APPEND CTEST_MEMORYCHECK_COMMAND_OPTIONS --suppressions=${supp} )
@@ -77,10 +74,7 @@ if(NOT (ret EQUAL 0 AND err EQUAL 0))
77
74
message (FATAL_ERROR "CMake configure failed: ${ret} ${err} " )
78
75
endif ()
79
76
80
- cmake_host_system_information (RESULT Ncpu QUERY NUMBER_OF_PHYSICAL_CORES )
81
-
82
77
ctest_build (
83
- PARALLEL_LEVEL ${Ncpu}
84
78
RETURN_VALUE ret
85
79
CAPTURE_CMAKE_ERROR err
86
80
)
@@ -96,7 +90,6 @@ EXCLUDE_LABEL ${exclude_label}
96
90
RETURN_VALUE ret
97
91
CAPTURE_CMAKE_ERROR err
98
92
DEFECT_COUNT count
99
- PARALLEL_LEVEL ${Ncpu}
100
93
)
101
94
102
95
if (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)
12
12
end subroutine
13
13
end interface
14
14
15
+ valgrind : block
16
+
15
17
character (kind= c_char, len= :), allocatable :: s
16
18
17
19
s = c_char_" Hello World!"
18
20
19
21
call echo_c( s )
20
22
23
+ end block valgrind
24
+
21
25
end program
You can’t perform that action at this time.
0 commit comments