Skip to content

testsuite driver stuck infinitely when testing the wasm backend with normal speed

When testing the wasm backend with normal speed, the testsuite driver process is stuck infinitely with 100% CPU occupation rate after all test cases are run.

export CROSS_EMULATOR=${CROSS_EMULATOR:-"/workspace/.ghc-wasm/wasm-run/bin/wasmtime.sh"}
hadrian/build \
  --no-color \
  --no-progress \
  --no-time \
  --flavour=perf \
  --docs=none \
  -j \
  test \
  --summary-junit=junit.xml \
  --summary=summary.txt \
  --test-speed=normal \
  --skip-perf

@bgamari suggests it may be an interpreter livelock. Though it's stuck even if the driver is executed by pypy3, so maybe the multi-threading logic in the driver is broken in a certain way that's somehow triggered by the wasm backend.

It seems to me that rewriting a small part of the driver that deals with concurrency may be sufficient to make things more robust and workaround this bug.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information