Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

In I64ToI32Lowering pass, lowerReinterpretFloat64() and lowerReinterpretInt64() are not multithreading, ASAN, STACK_OVERLOW_CHECK or SAFE_HEAP safe

Open
#4,710 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
cpp, wasm
Domain
compilers

Research direction

Start in src/passes/I64ToI32Lowering.cpp around lowerReinterpretFloat64() and lowerReinterpretInt64() at the referenced lines. Trace how the pass handles memory address zero and consider the multithreading, ASAN, STACK_OVERFLOW_CHECK, and SAFE_HEAP assumptions; the work is done when those lowerings are safe in the affected Wasm2JS builds.

Written by the indexing model from the issue text.

Description

In https://github.com/WebAssembly/binaryen/blob/fc00dcc64c337a8128fbf2b5fbdb40bb0aaa861b/src/passes/I64ToI32Lowering.cpp#L548-L584

there are assumptions made that are unsafe for multithreaded Wasm2JS builds. The memory address zero could be trashed by other threads when they are reinterpreted as float64/int64.

Also the Emscripten STACK_OVERFLOW_CHECK, ASAN and SAFE_HEAP checks place a cookie at address 0.

Dominant language
WebAssembly
Stars
8.6k
Forks
885
Avg merge
2d 4h
Merged PRs (30d)
77

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from WebAssembly/binaryen

All issues in WebAssembly/binaryen

Similar issues

More Compilers issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.