summaryrefslogtreecommitdiff
path: root/test/lit/passes/merge-blocks-eh.wast
diff options
context:
space:
mode:
authorAlon Zakai <azakai@google.com>2024-10-17 12:49:43 -0700
committerGitHub <noreply@github.com>2024-10-17 12:49:43 -0700
commit6566329fecd36c8cd8e2ab29f89dafde0d2e9304 (patch)
tree87e722eb17ab96e3dfe2ac865b53e6bede8bb61d /test/lit/passes/merge-blocks-eh.wast
parentfd86eadb591576b82b0b564f95952b131979e91a (diff)
downloadbinaryen-6566329fecd36c8cd8e2ab29f89dafde0d2e9304.tar.gz
binaryen-6566329fecd36c8cd8e2ab29f89dafde0d2e9304.tar.bz2
binaryen-6566329fecd36c8cd8e2ab29f89dafde0d2e9304.zip
[EH][GC] Send a non-nullable exnref from TryTable (#7013)
When EH+GC are enabled then wasm has non-nullable types, and the sent exnref should be non-nullable. In BinaryenIR we use the non- nullable type all the time, which we also do for function references and other things; we lower it if GC is not enabled to a nullable type for the binary format (see `WasmBinaryWriter::writeType`, to which comments were added in this PR). That is, this PR makes us handle exnref the same as those other types. A new test verifies that behavior. Various existing tests are updated because ReFinalize will now use the more refined type, so this is an optimization. It is also a bugfix as in #6987 we started to emit the refined form in the fuzzer, and this PR makes us handle it properly in validation and ReFinalization.
Diffstat (limited to 'test/lit/passes/merge-blocks-eh.wast')
-rw-r--r--test/lit/passes/merge-blocks-eh.wast2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/lit/passes/merge-blocks-eh.wast b/test/lit/passes/merge-blocks-eh.wast
index e53f601fd..e56f536f4 100644
--- a/test/lit/passes/merge-blocks-eh.wast
+++ b/test/lit/passes/merge-blocks-eh.wast
@@ -100,7 +100,7 @@
;; CHECK: (func $drop-block-try_catch_multi_partial (type $0)
;; CHECK-NEXT: (tuple.drop 2
- ;; CHECK-NEXT: (block $outer (type $1) (result i32 exnref)
+ ;; CHECK-NEXT: (block $outer (type $2) (result i32 (ref exn))
;; CHECK-NEXT: (block $inner
;; CHECK-NEXT: (try_table (catch_ref $i32 $outer) (catch_all $inner)
;; CHECK-NEXT: (call $import)