SIGBUS and SIGSEGV a when compiling a modified version of php_cgi with cranelift #3470
Labels
🍎 platform-darwin
This issue happens on macOS
bug
Something isn't working
📦 lib-compiler-cranelift
About wasmer-compiler-cranelift
lib-wasix
Issues related to the WASIX toolchain.
priority-medium
Medium priority issue
Milestone
Describe the bug
I am running into segfaults (
SIGSEGV
andSIGBUS
) during the compilation of a particular WebAssembly file.This happens on both debug and release versions of the
wasix
branch (commit d34ce88) on a M1 Mac, although the release binary triggers aSIGSEGV
while the debug binary triggers aSIGBUS
.Steps to reproduce
First, install the
wasmer
CLI from thewasix
branch.Then, extract the
modified.wasm
file from input.zip.Now you can try to run it with
wasmer run
.Running LLDB on the debug binary gave the following backtrace:
The backtrace from the release binary looks to be the same, plus/minus some inlining.
Expected behavior
I would expect the compilation to succeed and then fail to instantiate. Import errors are expected because the binary uses one version of
sock_accept()
, while WASIX provides an implementation with a slightly different signature.The text was updated successfully, but these errors were encountered: