There is currently an issue on WASM targets caused by thread-local storage not being cleaned when a thread is destroyed. Over time this exhausts the memory and causes an OOM. Once privacy-ethereum/mpz#371 is addressed bump the mpz dependency for this to be fixed.