Skip to content

0.2.86->0.2.87 introduces a coredump in wasm-opt that continues to latest released version #4123

@gilescope

Description

@gilescope

Describe the Bug

On an arm based m3 mac (and in docker as amd86), versions above 0.2.86 lead to a core dump in wasm-opt.

Smoking PR is likely this one: #3463

Steps to Reproduce

At least the code is open source to reproduce this one:

  1. git clone https://github.com/gilescope/dotsamaworld.git
  2. git checkout aaa62e360b641c0ebac4ccfac3de60b69be664fc
  3. bump wasm-bindgen to > 0.2.86 in Cargo.toml
  4. trunk build --release ( https://trunkrs.dev/ )
  5. See error:
2024-09-21T19:50:57.044057Z  INFO calling wasm-opt
2024-09-21T19:50:58.448578Z ERROR ❌ error
error from build pipeline

Caused by:
    0: HTML build pipeline failed (2 errors), showing first
    1: error from asset pipeline
    2: wasm-opt call to executable '/Users/gilescope/.cargo/bin/wasm-opt' with args: '["--output=/Users/gilescope/git/dotsamaworld/target/wasm-opt/release/app-25b623b3922d6169_bg.wasm", "-Oz", "/Users/gilescope/git/dotsamaworld/dist/.stage/app-25b623b3922d6169_bg.wasm"]' returned a bad status: signal: 11 (SIGSEGV)
Error: error from build pipeline

Expected Behavior

should compile cleanly and optimise wasm cleanly.

Actual Behavior

segmentation fault  /Users/gilescope/.cargo/bin/wasm-opt  -Oz

Additional Context

wasm-opt version 116 (version_116) (same for versions back to 105 that I could easily try)

If >=0.2.87 is using a newer version of wasm-opt then it could well be something in the c/c++ of wasm opt project where the problem is rather than here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions