Skip to content

Commit 3fa5421

Browse files
authored
Merge branch 'E3SM-Project/bartgol/eamxx/valg-fixes' (PR #6841)
Fixes valgrind tests failures in eamxx standalone tests.
2 parents d782204 + 4f33953 commit 3fa5421

File tree

3 files changed

+14
-3
lines changed

3 files changed

+14
-3
lines changed

components/eamxx/scripts/test_factory.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,7 @@ def __init__(self, tas):
156156
"Release build where tests run through valgrind",
157157
[("CMAKE_BUILD_TYPE", "RelWithDebInfo"),
158158
("EKAT_ENABLE_VALGRIND", "True"),
159+
("SCREAM_PACK_SIZE", "1"),
159160
("SCREAM_TEST_MAX_THREADS", "2")],
160161
uses_baselines=False,
161162
on_by_default=False,

components/eamxx/tests/generic/fail_check/valg_fail.cpp

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,18 @@ namespace scream {
66

77
TEST_CASE("force_valgrind_err")
88
{
9-
bool uninit;
9+
bool* uninit = new bool[1];
1010
int i = 0;
11-
if (uninit) {
11+
if (uninit[0]) {
1212
++i;
1313
}
1414
else {
1515
i += 4;
1616
}
17-
REQUIRE(i < 10);
17+
if (i<4) {
18+
printf("less than four\n");
19+
}
20+
delete uninit;
1821
}
1922

2023
} // empty namespace

components/homme/src/share/namelist_mod.F90

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -426,6 +426,13 @@ subroutine readnl(par)
426426
se_ftype = ftype ! MNL: For non-CAM runs, ftype=0 in control_mod
427427
nsplit = 1
428428
pertlim = 0.0_real_kind
429+
#else
430+
se_partmethod = SFCURVE
431+
se_ne = 0
432+
se_ne_x = 0
433+
se_ne_y = 0
434+
se_lx = 0
435+
se_ly = 0
429436
#endif
430437
sub_case = 1
431438
numnodes = -1

0 commit comments

Comments
 (0)