Skip to content

Reference types crash wasm-opt‘s asyncify pass #3739

@surma

Description

@surma
(module
  (type (;0;) (func))
  (type (;1;) (func (result externref)))
  (import "gl" "createProgram" (func $src/asc/gl/createProgram (type 1)))
  (func $src/asc/lemonsoda/init (type 0)
    call $src/asc/gl/createProgram
    drop
  )
  (export "init" (func $src/asc/lemonsoda/init))
)
$ wat2wasm --enable-reference-types test.wat -o test.wasm
$ wasm-opt --asyncify --enable-reference-types test.wasm -o test2.wasm
invalid type
UNREACHABLE executed at /tmp/binaryen-20210320-71286-1g5tfwr/binaryen-version_100/src/wasm/wasm-type.cpp:488!
[1]    56081 abort      wasm-opt --asyncify --enable-reference-types test.wasm -o test2.wasm

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions