Skip to content

Commit 77e3eb0

Browse files
authored
Fix flakiness in test_indirectbr_many. NFC (#19730)
This test, when run without optmizations, uses a lot of memory at runtime. Skip the test in this case. However, in order to get more coverage of wasm64 and wasm64l, add `-O1` which means these OOM'ing tests will now run under wasm64.
1 parent 64d1aba commit 77e3eb0

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

test/test_core.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2531,6 +2531,8 @@ def test_indirectbr(self):
25312531
@no_ubsan('local count too large for VMs')
25322532
@no_wasm2js('extremely deep nesting, hits stack limit on some VMs')
25332533
def test_indirectbr_many(self):
2534+
if not self.is_optimizing():
2535+
self.skipTest('nodejs takes ~1.8GB to compile this if the wasm is not optimized, which can cause OOM on the test runners')
25342536
self.do_core_test('test_indirectbr_many.c')
25352537

25362538
def test_pack(self):
@@ -9823,12 +9825,12 @@ def setUp(self):
98239825
corez = make_run('corez', emcc_args=['-Oz'])
98249826

98259827
# MEMORY64=1
9826-
wasm64 = make_run('wasm64', emcc_args=['-Wno-experimental', '--profiling-funcs'],
9828+
wasm64 = make_run('wasm64', emcc_args=['-O1', '-Wno-experimental', '--profiling-funcs'],
98279829
settings={'MEMORY64': 1}, require_wasm64=True, require_node=True)
98289830
wasm64_v8 = make_run('wasm64_v8', emcc_args=['-Wno-experimental', '--profiling-funcs'],
98299831
settings={'MEMORY64': 1}, require_wasm64=True, require_v8=True)
98309832
# MEMORY64=2, or "lowered"
9831-
wasm64l = make_run('wasm64l', emcc_args=['-Wno-experimental', '--profiling-funcs'],
9833+
wasm64l = make_run('wasm64l', emcc_args=['-O1', '-Wno-experimental', '--profiling-funcs'],
98329834
settings={'MEMORY64': 2},
98339835
node_args=shared.node_bigint_flags())
98349836

0 commit comments

Comments
 (0)