diff options
author | Thomas Lively <tlively@google.com> | 2022-12-07 12:41:49 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-12-07 18:41:49 +0000 |
commit | 2590620a32190f98b29c7d9726865aa8082b4023 (patch) | |
tree | 22bb9475aecafe5aeae4977fe1b0edb49053f2e7 /test/lit/passes/simplify-locals-gc.wast | |
parent | 3253df552729e771a31decf0e29a775f888b1e6f (diff) | |
download | binaryen-2590620a32190f98b29c7d9726865aa8082b4023.tar.gz binaryen-2590620a32190f98b29c7d9726865aa8082b4023.tar.bz2 binaryen-2590620a32190f98b29c7d9726865aa8082b4023.zip |
Update tests ahead of transition from `data` to `struct` (#5320)
The upstream WasmGC spec has removed `data` and introduced `struct`. To make the
migration easier, we have been supporting `struct` as an `alias` for `data` and
`structref` as an alias for `dataref`.
Update the tests to prefer the `struct` aliases over `data` for test input to
make the future migration easier. Also update some tests that had stale comments
about ref.null types being updated and remove some tests for instructions like
br_on_data and ref.as_data that do not make sense without a `data` type.
Diffstat (limited to 'test/lit/passes/simplify-locals-gc.wast')
-rw-r--r-- | test/lit/passes/simplify-locals-gc.wast | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/lit/passes/simplify-locals-gc.wast b/test/lit/passes/simplify-locals-gc.wast index 84e20eecb..b71da529c 100644 --- a/test/lit/passes/simplify-locals-gc.wast +++ b/test/lit/passes/simplify-locals-gc.wast @@ -21,11 +21,11 @@ ;; NOMNL: (type $struct-immutable (struct (field i32))) (type $struct-immutable (struct (field i32))) - (type $A (struct_subtype (field (ref null data)) data)) + (type $A (struct_subtype (field (ref null struct)) data)) ;; $B is a subtype of $A, and its field has a more refined type (it is non- ;; nullable). - (type $B (struct_subtype (field (ref data)) $A)) + (type $B (struct_subtype (field (ref struct)) $A)) ;; Writes to heap objects cannot be reordered with reads. ;; CHECK: (func $no-reorder-past-write (type $ref|$struct|_=>_i32) (param $x (ref $struct)) (result i32) @@ -716,7 +716,7 @@ (func $remove-tee-refinalize (param $a (ref null $A)) (param $b (ref null $B)) - (result (ref null data)) + (result (ref null struct)) ;; The local.tee receives a $B and flows out an $A. After we remove it (it is ;; obviously unnecessary), the struct.get will be reading from the more |