wasm bench: make lucet performance significantly better

By default, lucetc generates code with explicit bound checking,
even though the runtime has guard pages.

Elision only happens with --reserved-size=4GiB
This commit is contained in:
Frank Denis 2021-02-24 21:38:53 +01:00
parent d73fd3903f
commit 3d807d9205

View File

@ -51,7 +51,7 @@ if [ -z "$WASI_RUNTIME" ] || [ "$WASI_RUNTIME" = "lucet" ]; then
if command -v lucetc-wasi >/dev/null && command -v lucet-wasi >/dev/null; then
lucetc-wasi \
--target-cpu native \
--reserved-size "${MAX_MEMORY_TESTS}" \
--reserved-size "4GiB" \
--opt-level speed \
"$1" -o "${1}.so" &&
lucet-wasi --dir=.:. --max-heap-size "${MAX_MEMORY_TESTS}" "${1}.so" &&