emscripten icon indicating copy to clipboard operation
emscripten copied to clipboard

Running browser.test_wasmfs_opfs_jspi twice causes tack overflow error

Open sbc100 opened this issue 1 year ago • 5 comments

It seems like maybe some state must be left behind and affecting the second run.

sbc100 avatar Apr 09 '24 16:04 sbc100

+/report_result?exception:
Maximum call stack size exceeded / RangeError: Maximum call stack size exceeded    at 
test.wasm.operator_new_impl(unsigned long) (http://localhost:8888/test.wasm:wasm-function[142]:0x68bf)    at 
test.wasm.operator new(unsigned long) (http://localhost:8888/test.wasm:wasm-function[141]:0x68b0)    at
test.wasm.(anonymous namespace)::OPFSBackend::createDirectory(unsigned int) (http://localhost:8888/test.wasm:wasm-function[297]:0x8848)    at
 test.wasm.doMkdir(wasmfs::path::P[..]

sbc100 avatar Apr 09 '24 16:04 sbc100

Is there a command line option to run the test twice or how are you running it twice in one session?

brendandahl avatar Apr 11 '24 20:04 brendandahl

FWIW, I tried just duplicating the two self.btest_exit lines multiple times and it seems to run fine.

brendandahl avatar Apr 11 '24 20:04 brendandahl

Hmm.. I as able to repro the other day, and I've seen in in the CI.. but I'm not sure if it consistent. I'll try again now..

sbc100 avatar Apr 11 '24 20:04 sbc100

I'm seeing this issue on some CI runs. e.g.: https://app.circleci.com/pipelines/github/emscripten-core/emscripten/34717/workflows/01f23013-b724-4ec3-81b3-33a49727d0ab/jobs/775610

======================================================================
FAIL [3.019s]: test_wasmfs_opfs_jspi (test_browser.browser_2gb)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/root/project/test/common.py", line 2080, in run_browser
    self.assertContained(expected, output)
  File "/root/project/test/common.py", line 1410, in assertContained
    additional_info
  File "/usr/lib/python3.6/unittest/case.py", line 670, in fail
    raise self.failureException(msg)
AssertionError: Expected to find '/report_result?exit:0
' in '/report_result?exception:Maximum call stack size exceeded / RangeError: Maximum call stack size exceeded    at http://localhost:8888/test.wasm:wasm-function[108]:0x7059    at http://localhost:8888/test.wasm:wasm-function[44]:0xfd5    at http://localhost:8888/test.wasm:wasm-function[167]:0xdf46    at http://localhost:8888/test.wasm:wasm-function[127]:0xb271    at http://localhost:8888/test.wasm:wasm-function[266]:0x10c39    at http://localhost:8888/test.wasm:wasm-function[197]:0xec9c
', diff:

sbc100 avatar Apr 18 '24 20:04 sbc100