Stream: git-wasmtime

Topic: wasmtime / issue #10751 Winch internal error: Invalid sta...


view this post on Zulip Wasmtime GitHub notifications bot (May 08 2025 at 15:39):

alexcrichton opened issue #10751:

This module:

(module
  (type (;0;) (func (result i32 i32)))
  (func (;0;) (type 0) (result i32 i32)
    loop (result i32) ;; label = @1
      i32.const 0
      i32.const 1
      i32.const 0
      i32.const 1
      br_if 1
      br_if 0 (;@1;)
      block (result i32) ;; label = @2
        call 0
        drop
        loop (type 0) (result i32 i32) ;; label = @3
          i32.const 0
          i32.const 1
          block (type 0) (result i32 i32) ;; label = @4
            call 0
            i32.const 0
            br_table 0 (;@4;) 4
          end
          drop
          drop
        end
        drop
        drop
      end
      drop
      drop
    end
    i32.const 0
  )
)

yields:

$ cargo run compile -C compiler=winch ./testcase1.wat
    Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.19s
     Running `target/x86_64-unknown-linux-gnu/debug/wasmtime compile -C compiler=winch ./testcase1.wat`
Error: failed to compile: wasm[0]::function[0]

Caused by:
    Compilation error: Winch internal error: Invalid stack pointer offset

Fuzzing indicates this may be a regression from https://github.com/bytecodealliance/wasmtime/pull/10730

view this post on Zulip Wasmtime GitHub notifications bot (May 08 2025 at 15:39):

alexcrichton added the fuzz-bug label to Issue #10751.

view this post on Zulip Wasmtime GitHub notifications bot (May 08 2025 at 15:40):

alexcrichton added the winch label to Issue #10751.

view this post on Zulip Wasmtime GitHub notifications bot (May 08 2025 at 15:41):

github-actions[bot] commented on issue #10751:

Subscribe to Label Action

cc @saulecabrera

<details>
This issue or pull request has been labeled: "winch"

Thus the following users have been cc'd because of the following labels:

To subscribe or unsubscribe from this label, edit the <code>.github/subscribe-to-label.json</code> configuration file.

Learn more.
</details>

view this post on Zulip Wasmtime GitHub notifications bot (May 08 2025 at 15:42):

saulecabrera assigned saulecabrera to issue #10751.

view this post on Zulip Wasmtime GitHub notifications bot (May 15 2025 at 18:19):

saulecabrera commented on issue #10751:

I've opened https://github.com/bytecodealliance/wasmtime/pull/10781 to fix this issue.

view this post on Zulip Wasmtime GitHub notifications bot (May 15 2025 at 22:57):

alexcrichton closed issue #10751:

This module:

(module
  (type (;0;) (func (result i32 i32)))
  (func (;0;) (type 0) (result i32 i32)
    loop (result i32) ;; label = @1
      i32.const 0
      i32.const 1
      i32.const 0
      i32.const 1
      br_if 1
      br_if 0 (;@1;)
      block (result i32) ;; label = @2
        call 0
        drop
        loop (type 0) (result i32 i32) ;; label = @3
          i32.const 0
          i32.const 1
          block (type 0) (result i32 i32) ;; label = @4
            call 0
            i32.const 0
            br_table 0 (;@4;) 4
          end
          drop
          drop
        end
        drop
        drop
      end
      drop
      drop
    end
    i32.const 0
  )
)

yields:

$ cargo run compile -C compiler=winch ./testcase1.wat
    Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.19s
     Running `target/x86_64-unknown-linux-gnu/debug/wasmtime compile -C compiler=winch ./testcase1.wat`
Error: failed to compile: wasm[0]::function[0]

Caused by:
    Compilation error: Winch internal error: Invalid stack pointer offset

Fuzzing indicates this may be a regression from https://github.com/bytecodealliance/wasmtime/pull/10730


Last updated: Dec 06 2025 at 07:03 UTC