Repository: bytecodealliance/wasm-tools
Pull request #1730 (2024-08-20 21:31:14)

Refactor type checks when popping refs
This commit refactors users of `pop_ref` during validation to be able to pass in an expected type. This removes the need for a few manual `is_subtype` checks and helps centralize type-checking in one location.


Patch:
diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml
index 8458229d..03fbea0c 100644
--- a/.github/workflows/main.yml
+++ b/.github/workflows/main.yml
@@ -85,6 +85,9 @@ jobs:
             rust: default
           - os: ubuntu-latest
             rust: msrv
+            # skip testing crates that require wasmtime since wasmtime has a
+            # more aggressive msrv than wasm-tools
+            flags: --exclude fuzz-stats --exclude wit-component --exclude wasm-mutate-stats
     steps:
     - uses: actions/checkout@v4
       with:
@@ -92,7 +95,7 @@ jobs:
     - uses: bytecodealliance/wasmtime/.github/actions/install-rust@v20.0.0
       with:
         toolchain: ${{ matrix.rust }}
-    - run: cargo test --locked --all
+    - run: cargo test --locked --all ${{ matrix.flags }}
 
   test_extra_features:
     name: Test with extra Cargo features
@@ -260,10 +263,10 @@ jobs:
         submodules: true
     - uses: bytecodealliance/wasmtime/.github/actions/install-rust@v20.0.0
     - run: rustc ci/publish.rs
-    # Make sure the tree is publish-able as-is
-    - run: ./publish verify
     # Make sure we can bump version numbers for the next release
     - run: ./publish bump
+    # Make sure the tree is publish-able as-is
+    - run: ./publish verify
 
   # "Join node" which the merge queue waits on.
   ci-status:
diff --git a/Cargo.lock b/Cargo.lock
index abdab3dd..ff7ac34c 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -19,10 +19,10 @@ dependencies = [
 ]
 
 [[package]]
-name = "adler"
-version = "1.0.2"
+name = "adler2"
+version = "2.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe"
+checksum = "512761e0bb2578dd7380c6baaa0f4ce03e84f95e960231d1dec8bf4d7d6e2627"
 
 [[package]]
 name = "ahash"
@@ -87,7 +87,7 @@ version = "1.1.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "6d36fc52c7f6c869915e99412912f22093507da8d9e942ceaf66fe4b7c14422a"
 dependencies = [
- "windows-sys",
+ "windows-sys 0.52.0",
 ]
 
 [[package]]
@@ -97,7 +97,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "5bf74e1b6e971609db8ca7a9ce79fd5768ab6ae46441c572e46cf596f59e57f8"
 dependencies = [
  "anstyle",
- "windows-sys",
+ "windows-sys 0.52.0",
 ]
 
 [[package]]
@@ -123,9 +123,9 @@ checksum = "9d151e35f61089500b617991b791fc8bfd237ae50cd5950803758a179b41e67a"
 
 [[package]]
 name = "arrayvec"
-version = "0.7.4"
+version = "0.7.6"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711"
+checksum = "7c02d123df017efcdfbd739ef81735b36c5ba83ec3c59c80a9d7ecc718f92e50"
 
 [[package]]
 name = "autocfg"
@@ -156,9 +156,9 @@ dependencies = [
 
 [[package]]
 name = "blake3"
-version = "1.5.3"
+version = "1.5.4"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e9ec96fe9a81b5e365f9db71fe00edc4fe4ca2cc7dcb7861f0603012a7caa210"
+checksum = "d82033247fd8e890df8f740e407ad4d038debb9eb1f40533fffb32e7d17dc6f7"
 dependencies = [
  "arrayref",
  "arrayvec",
@@ -187,12 +187,13 @@ checksum = "37b2a672a2cb129a2e41c10b1224bb368f9f37a2b16b612598138befd7b37eb5"
 
 [[package]]
 name = "cc"
-version = "1.1.6"
+version = "1.1.13"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "2aba8f4e9906c7ce3c73463f62a7f0c65183ada1a2d47e397cc8810827f9694f"
+checksum = "72db2f7947ecee9b03b510377e8bb9077afa27176fdbff55c51027e976fdcc48"
 dependencies = [
  "jobserver",
  "libc",
+ "shlex",
 ]
 
 [[package]]
@@ -230,9 +231,9 @@ dependencies = [
 
 [[package]]
 name = "clap"
-version = "4.5.11"
+version = "4.5.16"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "35723e6a11662c2afb578bcf0b88bf6ea8e21282a953428f240574fcc3a2b5b3"
+checksum = "ed6719fffa43d0d87e5fd8caeab59be1554fb028cd30edc88fc4369b17971019"
 dependencies = [
  "clap_builder",
  "clap_derive",
@@ -240,9 +241,9 @@ dependencies = [
 
 [[package]]
 name = "clap_builder"
-version = "4.5.11"
+version = "4.5.15"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "49eb96cbfa7cfa35017b7cd548c75b14c3118c98b423041d70562665e07fb0fa"
+checksum = "216aec2b177652e3846684cbfe25c9964d18ec45234f0f5da5157b207ed1aab6"
 dependencies = [
  "anstream",
  "anstyle",
@@ -252,18 +253,18 @@ dependencies = [
 
 [[package]]
 name = "clap_complete"
-version = "4.5.11"
+version = "4.5.20"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "c6ae69fbb0833c6fcd5a8d4b8609f108c7ad95fc11e248d853ff2c42a90df26a"
+checksum = "2aedc27e53da9ff495f5da6f4325390e71f46f886022b618303042e8ccf4bcac"
 dependencies = [
  "clap",
 ]
 
 [[package]]
 name = "clap_derive"
-version = "4.5.11"
+version = "4.5.13"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5d029b67f89d30bbb547c89fd5161293c0aec155fc691d7924b64550662db93e"
+checksum = "501d359d5f3dcaf6ecdeee48833ae73ec6e42723a1e52419c79abf9507eec0a0"
 dependencies = [
  "heck 0.5.0",
  "proc-macro2",
@@ -315,27 +316,38 @@ dependencies = [
 
 [[package]]
 name = "cranelift-bforest"
-version = "0.109.0"
+version = "0.111.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "0b6b33d7e757a887989eb18b35712b2a67d96171ec3149d1bfb657b29b7b367c"
+checksum = "b80c3a50b9c4c7e5b5f73c0ed746687774fc9e36ef652b110da8daebf0c6e0e6"
 dependencies = [
  "cranelift-entity",
 ]
 
+[[package]]
+name = "cranelift-bitset"
+version = "0.111.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "38778758c2ca918b05acb2199134e0c561fb577c50574259b26190b6c2d95ded"
+dependencies = [
+ "serde",
+ "serde_derive",
+]
+
 [[package]]
 name = "cranelift-codegen"
-version = "0.109.0"
+version = "0.111.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b9acf15cb22be42d07c3b57d7856329cb228b7315d385346149df2566ad5e4aa"
+checksum = "58258667ad10e468bfc13a8d620f50dfcd4bb35d668123e97defa2549b9ad397"
 dependencies = [
  "bumpalo",
  "cranelift-bforest",
+ "cranelift-bitset",
  "cranelift-codegen-meta",
  "cranelift-codegen-shared",
  "cranelift-control",
  "cranelift-entity",
  "cranelift-isle",
- "gimli 0.28.1",
+ "gimli 0.29.0",
  "hashbrown 0.14.5",
  "log",
  "regalloc2",
@@ -346,43 +358,44 @@ dependencies = [
 
 [[package]]
 name = "cranelift-codegen-meta"
-version = "0.109.0"
+version = "0.111.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e934d301392b73b3f8b0540391fb82465a0f179a3cee7c726482ac4727efcc97"
+checksum = "043f0b702e529dcb07ff92bd7d40e7d5317b5493595172c5eb0983343751ee06"
 dependencies = [
  "cranelift-codegen-shared",
 ]
 
 [[package]]
 name = "cranelift-codegen-shared"
-version = "0.109.0"
+version = "0.111.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "8afb2a2566b3d54b854dfb288b3b187f6d3d17d6f762c92898207eba302931da"
+checksum = "7763578888ab53eca5ce7da141953f828e82c2bfadcffc106d10d1866094ffbb"
 
 [[package]]
 name = "cranelift-control"
-version = "0.109.0"
+version = "0.111.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "0100f33b704cdacd01ad66ff41f8c5030d57cbff078e2a4e49ab1822591299fa"
+checksum = "32db15f08c05df570f11e8ab33cb1ec449a64b37c8a3498377b77650bef33d8b"
 dependencies = [
  "arbitrary",
 ]
 
 [[package]]
 name = "cranelift-entity"
-version = "0.109.0"
+version = "0.111.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a8cfdc315e5d18997093e040a8d234bea1ac1e118a716d3e30f40d449e78207b"
+checksum = "5289cdb399381a27e7bbfa1b42185916007c3d49aeef70b1d01cb4caa8010130"
 dependencies = [
+ "cranelift-bitset",
  "serde",
  "serde_derive",
 ]
 
 [[package]]
 name = "cranelift-frontend"
-version = "0.109.0"
+version = "0.111.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "0f74b84f16af2e982b0c0c72233503d9d55cbfe3865dbe807ca28dc6642a28b5"
+checksum = "31ba8ab24eb9470477e98ddfa3c799a649ac5a0d9a2042868c4c952133c234e8"
 dependencies = [
  "cranelift-codegen",
  "log",
@@ -392,15 +405,15 @@ dependencies = [
 
 [[package]]
 name = "cranelift-isle"
-version = "0.109.0"
+version = "0.111.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "adf306d3dde705fb94bd48082f01d38c4ededc74293a4c007805f610bf08bc6e"
+checksum = "2b72a3c5c166a70426dcb209bdd0bb71a787c1ea76023dc0974fbabca770e8f9"
 
 [[package]]
 name = "cranelift-native"
-version = "0.109.0"
+version = "0.111.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1ea0ebdef7aff4a79bcbc8b6495f31315f16b3bf311152f472eaa8d679352581"
+checksum = "46a42424c956bbc31fc5c2706073df896156c5420ae8fa2a5d48dbc7b295d71b"
 dependencies = [
  "cranelift-codegen",
  "libc",
@@ -409,9 +422,9 @@ dependencies = [
 
 [[package]]
 name = "cranelift-wasm"
-version = "0.109.0"
+version = "0.111.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d549108a1942065cdbac3bb96c2952afa0e1b9a3beff4b08c4308ac72257576d"
+checksum = "49778df4289933d735b93c30a345513e030cf83101de0036e19b760f8aa09f68"
 dependencies = [
  "cranelift-codegen",
  "cranelift-entity",
@@ -419,7 +432,7 @@ dependencies = [
  "itertools 0.12.1",
  "log",
  "smallvec",
- "wasmparser 0.209.1",
+ "wasmparser 0.215.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "wasmtime-types",
 ]
 
@@ -544,6 +557,12 @@ version = "0.4.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "ef1a6892d9eef45c8fa6b9e0086428a2cca8491aca8f787c534a3d6d0bcb3ced"
 
+[[package]]
+name = "embedded-io"
+version = "0.6.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "edd0f118536f44f5ccd48bcb8b111bdc3de888b58c74639dfb034a357d0f206d"
+
 [[package]]
 name = "encoding_rs"
 version = "0.8.34"
@@ -589,7 +608,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba"
 dependencies = [
  "libc",
- "windows-sys",
+ "windows-sys 0.52.0",
 ]
 
 [[package]]
@@ -627,9 +646,9 @@ dependencies = [
 
 [[package]]
 name = "flate2"
-version = "1.0.30"
+version = "1.0.32"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae"
+checksum = "9c0596c1eac1f9e04ed902702e9878208b336edc9d6fddc8a48387349bab3666"
 dependencies = [
  "crc32fast",
  "miniz_oxide",
@@ -666,12 +685,12 @@ dependencies = [
 
 [[package]]
 name = "gimli"
-version = "0.28.1"
+version = "0.29.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4271d37baee1b8c7e4b708028c57d816cf9d2434acb33a549475f78c181f6253"
+checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd"
 dependencies = [
  "fallible-iterator",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "stable_deref_trait",
 ]
 
@@ -682,7 +701,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "e2e1d97fbe9722ba9bbd0c97051c2956e726562b61f86a25a4360398a40edfc9"
 dependencies = [
  "fallible-iterator",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "stable_deref_trait",
 ]
 
@@ -745,6 +764,12 @@ version = "0.3.9"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024"
 
+[[package]]
+name = "hermit-abi"
+version = "0.4.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "fbf6a919d6cf397374f7dfeeea91d974c7c0a7221d0d0f4f20d859d329e53fcc"
+
 [[package]]
 name = "humantime"
 version = "2.1.0"
@@ -783,9 +808,9 @@ dependencies = [
 
 [[package]]
 name = "indexmap"
-version = "2.2.6"
+version = "2.4.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26"
+checksum = "93ead53efc7ea8ed3cfb0c79fc8023fbb782a5432b52830b6518941cebe6505c"
 dependencies = [
  "equivalent",
  "hashbrown 0.14.5",
@@ -809,13 +834,13 @@ dependencies = [
 
 [[package]]
 name = "is-terminal"
-version = "0.4.12"
+version = "0.4.13"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f23ff5ef2b80d608d61efee834934d862cd92461afc0560dedf493e4c033738b"
+checksum = "261f68e344040fbd0edea105bef17c66edf46f984ddb1115b775ce31be948f4b"
 dependencies = [
- "hermit-abi",
+ "hermit-abi 0.4.0",
  "libc",
- "windows-sys",
+ "windows-sys 0.52.0",
 ]
 
 [[package]]
@@ -889,9 +914,9 @@ checksum = "884e2677b40cc8c339eaefcb701c32ef1fd2493d71118dc0ca4b6a736c93bd67"
 
 [[package]]
 name = "libc"
-version = "0.2.155"
+version = "0.2.158"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c"
+checksum = "d8adc4bb1803a324070e64a98ae98f38934d91957a99cfb3a43dcbc01bc56439"
 
 [[package]]
 name = "libfuzzer-sys"
@@ -936,18 +961,18 @@ checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24"
 
 [[package]]
 name = "logos"
-version = "0.14.0"
+version = "0.14.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "161971eb88a0da7ae0c333e1063467c5b5727e7fb6b710b8db4814eade3a42e8"
+checksum = "ff1ceb190eb9bdeecdd8f1ad6a71d6d632a50905948771718741b5461fb01e13"
 dependencies = [
  "logos-derive",
 ]
 
 [[package]]
 name = "logos-codegen"
-version = "0.14.0"
+version = "0.14.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "8e31badd9de5131fdf4921f6473d457e3dd85b11b7f091ceb50e4df7c3eeb12a"
+checksum = "90be66cb7bd40cb5cc2e9cfaf2d1133b04a3d93b72344267715010a466e0915a"
 dependencies = [
  "beef",
  "fnv",
@@ -960,9 +985,9 @@ dependencies = [
 
 [[package]]
 name = "logos-derive"
-version = "0.14.0"
+version = "0.14.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1c2a69b3eb68d5bd595107c9ee58d7e07fe2bb5e360cc85b0f084dedac80de0a"
+checksum = "45154231e8e96586b39494029e58f12f8ffcb5ecf80333a603a13aa205ea8cbd"
 dependencies = [
  "logos-codegen",
 ]
@@ -1000,22 +1025,13 @@ dependencies = [
  "libc",
 ]
 
-[[package]]
-name = "memoffset"
-version = "0.9.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a"
-dependencies = [
- "autocfg",
-]
-
 [[package]]
 name = "miniz_oxide"
-version = "0.7.4"
+version = "0.8.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08"
+checksum = "e2d80299ef12ff69b16a84bb182e3b9df68b5a91574d3d4fa6e41b65deec4df1"
 dependencies = [
- "adler",
+ "adler2",
 ]
 
 [[package]]
@@ -1033,20 +1049,20 @@ version = "1.16.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43"
 dependencies = [
- "hermit-abi",
+ "hermit-abi 0.3.9",
  "libc",
 ]
 
 [[package]]
 name = "object"
-version = "0.36.2"
+version = "0.36.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "3f203fa8daa7bb185f760ae12bd8e097f63d17041dcdcaf675ac54cdf863170e"
+checksum = "27b64972346851a39438c60b341ebc01bba47464ae329e55cf343eb93964efd9"
 dependencies = [
  "crc32fast",
  "flate2",
  "hashbrown 0.14.5",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "memchr",
  "ruzstd",
 ]
@@ -1076,25 +1092,29 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "b4c5cc86750666a3ed20bdaf5ca2a0344f9c67674cae0515bec2da16fbaa47db"
 dependencies = [
  "fixedbitset",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
 ]
 
 [[package]]
 name = "postcard"
-version = "1.0.8"
+version = "1.0.9"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a55c51ee6c0db07e68448e336cf8ea4131a620edefebf9893e759b2d793420f8"
+checksum = "20ee10b999a00ca189ac2cb99f5db1ca71fb7371e3d5f493b879ca95d2a67220"
 dependencies = [
  "cobs",
- "embedded-io",
+ "embedded-io 0.4.0",
+ "embedded-io 0.6.1",
  "serde",
 ]
 
 [[package]]
 name = "ppv-lite86"
-version = "0.2.17"
+version = "0.2.20"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de"
+checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04"
+dependencies = [
+ "zerocopy",
+]
 
 [[package]]
 name = "pretty_assertions"
@@ -1207,9 +1227,9 @@ dependencies = [
 
 [[package]]
 name = "regex"
-version = "1.10.5"
+version = "1.10.6"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f"
+checksum = "4219d74c6b67a3654a9fbebc4b419e22126d13d2f3c4a07ee0cb61ff79a79619"
 dependencies = [
  "aho-corasick",
  "memchr",
@@ -1256,7 +1276,7 @@ dependencies = [
  "errno",
  "libc",
  "linux-raw-sys",
- "windows-sys",
+ "windows-sys 0.52.0",
 ]
 
 [[package]]
@@ -1295,18 +1315,18 @@ dependencies = [
 
 [[package]]
 name = "serde"
-version = "1.0.203"
+version = "1.0.208"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094"
+checksum = "cff085d2cb684faa248efb494c39b68e522822ac0de72ccf08109abde717cfb2"
 dependencies = [
  "serde_derive",
 ]
 
 [[package]]
 name = "serde_derive"
-version = "1.0.203"
+version = "1.0.208"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba"
+checksum = "24008e81ff7613ed8e5ba0cfaf24e2c2f1e5b8a0495711e44fcd4882fca62bcf"
 dependencies = [
  "proc-macro2",
  "quote",
@@ -1315,11 +1335,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.120"
+version = "1.0.125"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4e0d21c9a8cae1235ad58a00c11cb40d4b1e5c784f1ef2c537876ed6ffd8b7c5"
+checksum = "83c8e735a073ccf5be70aa8066aa984eaf2fa000db6c8d0100ae605b366d31ed"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
@@ -1330,13 +1351,19 @@ version = "0.9.34+deprecated"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "6a8b1a1a2ebf674015cc02edccce75287f1a0130d394307b36743c2f5d504b47"
 dependencies = [
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "itoa",
  "ryu",
  "serde",
  "unsafe-libyaml",
 ]
 
+[[package]]
+name = "shlex"
+version = "1.3.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64"
+
 [[package]]
 name = "sized-chunks"
 version = "0.6.5"
@@ -1403,9 +1430,9 @@ checksum = "7c68d531d83ec6c531150584c42a4290911964d5f0d79132b193b67252a23b71"
 
 [[package]]
 name = "syn"
-version = "2.0.72"
+version = "2.0.75"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af"
+checksum = "f6af063034fc1935ede7be0122941bafa9bacb949334d090b77ca98b5817c7d9"
 dependencies = [
  "proc-macro2",
  "quote",
@@ -1414,20 +1441,21 @@ dependencies = [
 
 [[package]]
 name = "target-lexicon"
-version = "0.12.15"
+version = "0.12.16"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4873307b7c257eddcb50c9bedf158eb669578359fb28428bef438fec8e6ba7c2"
+checksum = "61c41af27dd6d1e27b1b16b489db798443478cef1f06a660c96db617ba5de3b1"
 
 [[package]]
 name = "tempfile"
-version = "3.10.1"
+version = "3.12.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1"
+checksum = "04cbcdd0c794ebb0d4cf35e88edd2f7d2c4c3e9a5a6dab322839b321c6a87a64"
 dependencies = [
  "cfg-if",
  "fastrand",
+ "once_cell",
  "rustix",
- "windows-sys",
+ "windows-sys 0.59.0",
 ]
 
 [[package]]
@@ -1514,9 +1542,9 @@ checksum = "0336d538f7abc86d282a4189614dfaa90810dfc2c6f6427eaf88e16311dd225d"
 
 [[package]]
 name = "unicode-xid"
-version = "0.2.4"
+version = "0.2.5"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c"
+checksum = "229730647fbc343e3a80e463c1db7f78f3855d3f3739bee0dda773c9a037c90a"
 
 [[package]]
 name = "unsafe-libyaml"
@@ -1560,7 +1588,7 @@ dependencies = [
  "glob",
  "heck 0.4.1",
  "im-rc",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "log",
  "petgraph",
  "pretty_assertions",
@@ -1575,15 +1603,6 @@ dependencies = [
  "wit-component 0.215.0",
 ]
 
-[[package]]
-name = "wasm-encoder"
-version = "0.209.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "7b4a05336882dae732ce6bd48b7e11fe597293cb72c13da4f35d7d5f8d53b2a7"
-dependencies = [
- "leb128",
-]
-
 [[package]]
 name = "wasm-encoder"
 version = "0.214.0"
@@ -1604,6 +1623,15 @@ dependencies = [
  "wasmparser 0.215.0",
 ]
 
+[[package]]
+name = "wasm-encoder"
+version = "0.215.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "4fb56df3e06b8e6b77e37d2969a50ba51281029a9aeb3855e76b7f49b6418847"
+dependencies = [
+ "leb128",
+]
+
 [[package]]
 name = "wasm-metadata"
 version = "0.214.0"
@@ -1611,7 +1639,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "865c5bff5f7a3781b5f92ea4cfa99bb38267da097441cdb09080de1568ef3075"
 dependencies = [
  "anyhow",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "serde",
  "serde_derive",
  "serde_json",
@@ -1626,7 +1654,7 @@ version = "0.215.0"
 dependencies = [
  "anyhow",
  "clap",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "serde",
  "serde_derive",
  "serde_json",
@@ -1696,7 +1724,7 @@ dependencies = [
  "clap",
  "criterion",
  "flagset",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "leb128",
  "libfuzzer-sys",
  "rand",
@@ -1795,26 +1823,12 @@ name = "wasm-wave"
 version = "0.215.0"
 dependencies = [
  "anyhow",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "logos",
  "thiserror",
  "wit-parser 0.215.0",
 ]
 
-[[package]]
-name = "wasmparser"
-version = "0.209.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "07035cc9a9b41e62d3bb3a3815a66ab87c993c06fe1cf6b2a3f2a18499d937db"
-dependencies = [
- "ahash",
- "bitflags",
- "hashbrown 0.14.5",
- "indexmap 2.2.6",
- "semver",
- "serde",
-]
-
 [[package]]
 name = "wasmparser"
 version = "0.214.0"
@@ -1824,7 +1838,7 @@ dependencies = [
  "ahash",
  "bitflags",
  "hashbrown 0.14.5",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "semver",
 ]
 
@@ -1838,7 +1852,7 @@ dependencies = [
  "criterion",
  "env_logger",
  "hashbrown 0.14.5",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "log",
  "once_cell",
  "rayon",
@@ -1850,13 +1864,17 @@ dependencies = [
 ]
 
 [[package]]
-name = "wasmprinter"
-version = "0.209.1"
+name = "wasmparser"
+version = "0.215.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ceca8ae6eaa8c7c87b33c25c53bdf299f8c2a764aee1179402ff7652ef3a6859"
+checksum = "53fbde0881f24199b81cf49b6ff8f9c145ac8eb1b7fc439adb5c099734f7d90e"
 dependencies = [
- "anyhow",
- "wasmparser 0.209.1",
+ "ahash",
+ "bitflags",
+ "hashbrown 0.14.5",
+ "indexmap 2.4.0",
+ "semver",
+ "serde",
 ]
 
 [[package]]
@@ -1873,25 +1891,36 @@ dependencies = [
  "wat",
 ]
 
+[[package]]
+name = "wasmprinter"
+version = "0.215.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d8e9a325d85053408209b3d2ce5eaddd0dd6864d1cff7a007147ba073157defc"
+dependencies = [
+ "anyhow",
+ "termcolor",
+ "wasmparser 0.215.0 (registry+https://github.com/rust-lang/crates.io-index)",
+]
+
 [[package]]
 name = "wasmtime"
-version = "22.0.0"
+version = "24.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "786d8b5e7a4d54917c5ebe555b9667337e5f93383f49bddaaeec2eba68093b45"
+checksum = "9a5883d64dfc8423c56e3d8df27cffc44db25336aa468e8e0724fddf30a333d7"
 dependencies = [
  "anyhow",
+ "bitflags",
  "bumpalo",
  "cc",
  "cfg-if",
  "encoding_rs",
  "hashbrown 0.14.5",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "libc",
  "libm",
  "log",
  "mach2",
  "memfd",
- "memoffset",
  "object",
  "once_cell",
  "paste",
@@ -1904,7 +1933,7 @@ dependencies = [
  "smallvec",
  "sptr",
  "target-lexicon",
- "wasmparser 0.209.1",
+ "wasmparser 0.215.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "wasmtime-asm-macros",
  "wasmtime-component-macro",
  "wasmtime-component-util",
@@ -1914,23 +1943,23 @@ dependencies = [
  "wasmtime-slab",
  "wasmtime-versioned-export-macros",
  "wasmtime-winch",
- "windows-sys",
+ "windows-sys 0.52.0",
 ]
 
 [[package]]
 name = "wasmtime-asm-macros"
-version = "22.0.0"
+version = "24.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d697d99c341d4a9ffb72f3af7a02124d233eeb59aee010f36d88e97cca553d5e"
+checksum = "1c4dc7e2a379c0dd6be5b55857d14c4b277f43a9c429a9e14403eb61776ae3be"
 dependencies = [
  "cfg-if",
 ]
 
 [[package]]
 name = "wasmtime-component-macro"
-version = "22.0.0"
+version = "24.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b29b462b068e73b5b27fae092a27f47e5937cabf6b26be2779c978698a52feca"
+checksum = "4b07773d1c3dab5f014ec61316ee317aa424033e17e70a63abdf7c3a47e58fcf"
 dependencies = [
  "anyhow",
  "proc-macro2",
@@ -1938,20 +1967,20 @@ dependencies = [
  "syn",
  "wasmtime-component-util",
  "wasmtime-wit-bindgen",
- "wit-parser 0.209.1",
+ "wit-parser 0.215.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "wasmtime-component-util"
-version = "22.0.0"
+version = "24.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f9d2912c53d9054984b380dfbd7579f9c3681b2a73b903a56bd71a1c4f175f1e"
+checksum = "e38d735320f4e83478369ce649ad8fe87c6b893220902e798547a225fc0c5874"
 
 [[package]]
 name = "wasmtime-cranelift"
-version = "22.0.0"
+version = "24.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a3975deafea000457ba84355c7c0fce0372937204f77026510b7b454f28a3a65"
+checksum = "e570d831d0785d93d7d8c722b1eb9a34e0d0c1534317666f65892818358a2da9"
 dependencies = [
  "anyhow",
  "cfg-if",
@@ -1961,75 +1990,78 @@ dependencies = [
  "cranelift-frontend",
  "cranelift-native",
  "cranelift-wasm",
- "gimli 0.28.1",
+ "gimli 0.29.0",
  "log",
  "object",
  "target-lexicon",
  "thiserror",
- "wasmparser 0.209.1",
+ "wasmparser 0.215.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "wasmtime-environ",
  "wasmtime-versioned-export-macros",
 ]
 
 [[package]]
 name = "wasmtime-environ"
-version = "22.0.0"
+version = "24.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f444e900e848b884d8a8a2949b6f5b92af642a3e663ff8fbe78731143a55be61"
+checksum = "c5fe80dfbd81687431a7d4f25929fae1ae96894786d5c96b14ae41164ee97377"
 dependencies = [
  "anyhow",
+ "cranelift-bitset",
  "cranelift-entity",
- "gimli 0.28.1",
- "indexmap 2.2.6",
+ "gimli 0.29.0",
+ "indexmap 2.4.0",
  "log",
  "object",
  "postcard",
+ "semver",
  "serde",
  "serde_derive",
  "target-lexicon",
- "wasm-encoder 0.209.1",
- "wasmparser 0.209.1",
- "wasmprinter 0.209.1",
+ "wasm-encoder 0.215.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "wasmparser 0.215.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "wasmprinter 0.215.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "wasmtime-component-util",
  "wasmtime-types",
 ]
 
 [[package]]
 name = "wasmtime-jit-icache-coherence"
-version = "22.0.0"
+version = "24.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "5afe2f0499542f9a4bcfa1b55bfdda803b6ade4e7c93c6b99e0f39dba44b0a91"
+checksum = "d15de8429db996f0d17a4163a35eccc3f874cbfb50f29c379951ea1bbb39452e"
 dependencies = [
  "anyhow",
  "cfg-if",
  "libc",
- "windows-sys",
+ "windows-sys 0.52.0",
 ]
 
 [[package]]
 name = "wasmtime-slab"
-version = "22.0.0"
+version = "24.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "0a7de1f2bec5bbb35d532e61c85c049dc84ae671df60492f90b954ecf21169e7"
+checksum = "1f68d38fa6b30c5e1fc7d608263062997306f79e577ebd197ddcd6b0f55d87d1"
 
 [[package]]
 name = "wasmtime-types"
-version = "22.0.0"
+version = "24.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "412463e9000e14cf6856be48628d2213c20c153e29ffc22b036980c892ea6964"
+checksum = "6634e7079d9c5cfc81af8610ed59b488cc5b7f9777a2f4c1667a2565c2e45249"
 dependencies = [
+ "anyhow",
  "cranelift-entity",
  "serde",
  "serde_derive",
  "smallvec",
- "wasmparser 0.209.1",
+ "wasmparser 0.215.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "wasmtime-versioned-export-macros"
-version = "22.0.0"
+version = "24.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "de5a9bc4f44ceeb168e9e8e3be4e0b4beb9095b468479663a9e24c667e36826f"
+checksum = "3850e3511d6c7f11a72d571890b0ed5f6204681f7f050b9de2690e7f13123fed"
 dependencies = [
  "proc-macro2",
  "quote",
@@ -2038,16 +2070,16 @@ dependencies = [
 
 [[package]]
 name = "wasmtime-winch"
-version = "22.0.0"
+version = "24.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ed4db238a0241df2d15f79ad17b3a37a27f2ea6cb885894d81b42ae107544466"
+checksum = "2a25199625effa4c13dd790d64bd56884b014c69829431bfe43991c740bd5bc1"
 dependencies = [
  "anyhow",
  "cranelift-codegen",
- "gimli 0.28.1",
+ "gimli 0.29.0",
  "object",
  "target-lexicon",
- "wasmparser 0.209.1",
+ "wasmparser 0.215.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "wasmtime-cranelift",
  "wasmtime-environ",
  "winch-codegen",
@@ -2055,14 +2087,14 @@ dependencies = [
 
 [[package]]
 name = "wasmtime-wit-bindgen"
-version = "22.0.0"
+version = "24.0.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "70dc077306b38288262e5ba01d4b21532a6987416cdc0aedf04bb06c22a68fdc"
+checksum = "3cb331ac7ed1d5ba49cddcdb6b11973752a857148858bb308777d2fc5584121f"
 dependencies = [
  "anyhow",
  "heck 0.4.1",
- "indexmap 2.2.6",
- "wit-parser 0.209.1",
+ "indexmap 2.4.0",
+ "wit-parser 0.215.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -2107,11 +2139,11 @@ checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6"
 
 [[package]]
 name = "winapi-util"
-version = "0.1.8"
+version = "0.1.9"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b"
+checksum = "cf221c93e13a30d793f7645a0e7762c55d169dbb0a49671918a2319d289b10bb"
 dependencies = [
- "windows-sys",
+ "windows-sys 0.59.0",
 ]
 
 [[package]]
@@ -2122,17 +2154,17 @@ checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"
 
 [[package]]
 name = "winch-codegen"
-version = "0.20.0"
+version = "0.22.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "85c6915884e731b2db0d8cf08cb64474cb69221a161675fd3c135f91febc3daa"
+checksum = "073efe897d9ead7fc609874f94580afc831114af5149b6a90ee0a3a39b497fe0"
 dependencies = [
  "anyhow",
  "cranelift-codegen",
- "gimli 0.28.1",
+ "gimli 0.29.0",
  "regalloc2",
  "smallvec",
  "target-lexicon",
- "wasmparser 0.209.1",
+ "wasmparser 0.215.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "wasmtime-cranelift",
  "wasmtime-environ",
 ]
@@ -2146,6 +2178,15 @@ dependencies = [
  "windows-targets",
 ]
 
+[[package]]
+name = "windows-sys"
+version = "0.59.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b"
+dependencies = [
+ "windows-targets",
+]
+
 [[package]]
 name = "windows-targets"
 version = "0.52.6"
@@ -2227,7 +2268,7 @@ checksum = "fd9fd46f0e783bf80f1ab7291f9d442fa5553ff0e96cdb71964bd8859b734b55"
 dependencies = [
  "anyhow",
  "bitflags",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "log",
  "serde",
  "serde_derive",
@@ -2246,7 +2287,7 @@ dependencies = [
  "bitflags",
  "env_logger",
  "glob",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "libtest-mimic",
  "log",
  "pretty_assertions",
@@ -2277,59 +2318,59 @@ dependencies = [
 
 [[package]]
 name = "wit-parser"
-version = "0.209.1"
+version = "0.214.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "3e79b9e3c0b6bb589dec46317e645851e0db2734c44e2be5e251b03ff4a51269"
+checksum = "681d526d6ea42e28f9afe9eae2b50e0b0a627aef8822c75eb04078db84d03e57"
 dependencies = [
  "anyhow",
  "id-arena",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "log",
  "semver",
  "serde",
  "serde_derive",
  "serde_json",
  "unicode-xid",
- "wasmparser 0.209.1",
+ "wasmparser 0.214.0",
 ]
 
 [[package]]
 name = "wit-parser"
-version = "0.214.0"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "681d526d6ea42e28f9afe9eae2b50e0b0a627aef8822c75eb04078db84d03e57"
+version = "0.215.0"
 dependencies = [
  "anyhow",
+ "env_logger",
  "id-arena",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
+ "libtest-mimic",
  "log",
+ "pretty_assertions",
  "semver",
  "serde",
  "serde_derive",
  "serde_json",
  "unicode-xid",
- "wasmparser 0.214.0",
+ "wasmparser 0.215.0",
+ "wat",
+ "wit-parser 0.215.0",
 ]
 
 [[package]]
 name = "wit-parser"
 version = "0.215.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "935a97eaffd57c3b413aa510f8f0b550a4a9fe7d59e79cd8b89a83dcb860321f"
 dependencies = [
  "anyhow",
- "env_logger",
  "id-arena",
- "indexmap 2.2.6",
- "libtest-mimic",
+ "indexmap 2.4.0",
  "log",
- "pretty_assertions",
  "semver",
  "serde",
  "serde_derive",
  "serde_json",
  "unicode-xid",
- "wasmparser 0.215.0",
- "wat",
- "wit-parser 0.215.0",
+ "wasmparser 0.215.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
@@ -2351,7 +2392,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "09cf816019a376a912cafb103677a8d28e3cba86b7671b754281e75f4909e129"
 dependencies = [
  "arbitrary",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "log",
  "semver",
  "wit-component 0.214.0",
@@ -2364,7 +2405,7 @@ version = "0.215.0"
 dependencies = [
  "arbitrary",
  "clap",
- "indexmap 2.2.6",
+ "indexmap 2.4.0",
  "log",
  "semver",
  "wit-component 0.215.0",
@@ -2383,6 +2424,7 @@ version = "0.7.35"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0"
 dependencies = [
+ "byteorder",
  "zerocopy-derive",
 ]
 
diff --git a/Cargo.toml b/Cargo.toml
index 05102856..ccd9bf25 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -82,7 +82,7 @@ rayon = "1.3"
 serde = { version = "1.0.166", default-features = false, features = ['alloc'] }
 serde_derive = "1.0.166"
 serde_json = { version = "1" }
-wasmtime = { version = "22.0.0", default-features = false, features = ['cranelift', 'component-model', 'runtime', 'gc'] }
+wasmtime = { version = "24.0.0", default-features = false, features = ['cranelift', 'component-model', 'runtime', 'gc'] }
 url = "2.0.0"
 pretty_assertions = "1.3.0"
 semver = { version = "1.0.0", default-features = false }
diff --git a/crates/wasmparser/src/features.rs b/crates/wasmparser/src/features.rs
index 3f61ffcc..aa47eee0 100644
--- a/crates/wasmparser/src/features.rs
+++ b/crates/wasmparser/src/features.rs
@@ -126,7 +126,7 @@ define_wasm_features! {
         /// The WebAssembly multi memory proposal.
         pub multi_memory: MULTI_MEMORY(1 << 12) = true;
         /// The WebAssembly exception handling proposal.
-        pub exceptions: EXCEPTIONS(1 << 13) = false;
+        pub exceptions: EXCEPTIONS(1 << 13) = true;
         /// The WebAssembly memory64 proposal.
         pub memory64: MEMORY64(1 << 14) = false;
         /// The WebAssembly extended_const proposal.
@@ -134,11 +134,11 @@ define_wasm_features! {
         /// The WebAssembly component model proposal.
         pub component_model: COMPONENT_MODEL(1 << 16) = true;
         /// The WebAssembly typed function references proposal.
-        pub function_references: FUNCTION_REFERENCES(1 << 17) = false;
+        pub function_references: FUNCTION_REFERENCES(1 << 17) = true;
         /// The WebAssembly memory control proposal.
         pub memory_control: MEMORY_CONTROL(1 << 18) = false;
         /// The WebAssembly gc proposal.
-        pub gc: GC(1 << 19) = false;
+        pub gc: GC(1 << 19) = true;
         /// The WebAssembly [custom-page-sizes
         /// proposal](https://github.com/WebAssembly/custom-page-sizes).
         pub custom_page_sizes: CUSTOM_PAGE_SIZES(1 << 20) = false;
@@ -157,6 +157,23 @@ define_wasm_features! {
         /// Support this feature as long as all leading browsers also support it
         /// https://github.com/WebAssembly/exception-handling/blob/main/proposals/exception-handling/legacy/Exceptions.md
         pub legacy_exceptions: LEGACY_EXCEPTIONS(1 << 25) = false;
+        /// Whether or not gc types are enabled.
+        ///
+        /// This feature does not correspond to any WebAssembly proposal nor
+        /// concept in the specification itself. This is intended to assist
+        /// embedders in disabling support for GC types at validation time. For
+        /// example if an engine wants to support all of WebAssembly except
+        /// a runtime garbage collector it could disable this feature.
+        ///
+        /// This features is enabled by default and is used to gate types such
+        /// as `externref` or `anyref`. Note that the requisite WebAssembly
+        /// proposal must also be enabled for types like `externref`, meaning
+        /// that it requires both `REFERENCE_TYPES` and `GC_TYPE` to be enabled.
+        ///
+        /// Note that the `funcref` and `exnref` types are not gated by this
+        /// feature. Those are expected to not require a full garbage collector
+        /// so are not gated by this.
+        pub gc_types: GC_TYPES(1 << 26) = true;
     }
 }
 
@@ -164,7 +181,7 @@ impl WasmFeatures {
     /// Returns the feature set associated with the 1.0 version of the
     /// WebAssembly specification or the "MVP" feature set.
     pub fn wasm1() -> WasmFeatures {
-        WasmFeatures::FLOATS
+        WasmFeatures::FLOATS | WasmFeatures::GC_TYPES
     }
 
     /// Returns the feature set associated with the 2.0 version of the
diff --git a/crates/wasmparser/src/validator.rs b/crates/wasmparser/src/validator.rs
index 5425fad7..700130e5 100644
--- a/crates/wasmparser/src/validator.rs
+++ b/crates/wasmparser/src/validator.rs
@@ -251,6 +251,12 @@ impl WasmFeatures {
         }
         match r.heap_type() {
             HeapType::Concrete(_) => {
+                // Note that `self.gc_types()` is not checked here because
+                // concrete pointers to function types are allowed. GC types
+                // are disallowed by instead rejecting the definition of
+                // array/struct types and only allowing the definition of
+                // function types.
+
                 // Indexed types require either the function-references or gc
                 // proposal as gc implies function references here.
                 if self.function_references() || self.gc() {
@@ -266,6 +272,13 @@ impl WasmFeatures {
                         "shared reference types require the shared-everything-threads proposal",
                     );
                 }
+
+                // Apply the "gc-types" feature which disallows all heap types
+                // except exnref/funcref.
+                if !self.gc_types() && ty != Func && ty != Exn {
+                    return Err("gc types are disallowed but found type which requires gc");
+                }
+
                 match (ty, r.is_nullable()) {
                     // funcref/externref only require `reference-types`.
                     (Func, true) | (Extern, true) => Ok(()),
diff --git a/crates/wasmparser/src/validator/core.rs b/crates/wasmparser/src/validator/core.rs
index fbcdbcbb..75cb01c5 100644
--- a/crates/wasmparser/src/validator/core.rs
+++ b/crates/wasmparser/src/validator/core.rs
@@ -699,10 +699,16 @@ impl Module {
             }
             CompositeInnerType::Array(t) => {
                 if !features.gc() {
-                    return Err(BinaryReaderError::new(
+                    bail!(
+                        offset,
                         "array indexed types not supported without the gc feature",
+                    );
+                }
+                if !features.gc_types() {
+                    bail!(
                         offset,
-                    ));
+                        "cannot define array types when gc types are disabled",
+                    );
                 }
                 match &t.0.element_type {
                     StorageType::I8 | StorageType::I16 => {
@@ -713,10 +719,16 @@ impl Module {
             }
             CompositeInnerType::Struct(t) => {
                 if !features.gc() {
-                    return Err(BinaryReaderError::new(
+                    bail!(
+                        offset,
                         "struct indexed types not supported without the gc feature",
+                    );
+                }
+                if !features.gc_types() {
+                    bail!(
                         offset,
-                    ));
+                        "cannot define struct types when gc types are disabled",
+                    );
                 }
                 for ft in t.fields.iter() {
                     match &ft.element_type {
diff --git a/crates/wasmparser/src/validator/operators.rs b/crates/wasmparser/src/validator/operators.rs
index df984683..b04e457c 100644
--- a/crates/wasmparser/src/validator/operators.rs
+++ b/crates/wasmparser/src/validator/operators.rs
@@ -23,10 +23,10 @@
 // the various methods here.
 
 use crate::{
-    limits::MAX_WASM_FUNCTION_LOCALS, AbstractHeapType, ArrayType, BinaryReaderError, BlockType,
-    BrTable, Catch, FieldType, FuncType, GlobalType, HeapType, Ieee32, Ieee64, MemArg, RefType,
-    Result, StorageType, StructType, SubType, TableType, TryTable, UnpackedIndex, ValType,
-    VisitOperator, WasmFeatures, WasmModuleResources, V128,
+    limits::MAX_WASM_FUNCTION_LOCALS, AbstractHeapType, BinaryReaderError, BlockType, BrTable,
+    Catch, FieldType, FuncType, GlobalType, HeapType, Ieee32, Ieee64, MemArg, RefType, Result,
+    StorageType, StructType, SubType, TableType, TryTable, UnpackedIndex, ValType, VisitOperator,
+    WasmFeatures, WasmModuleResources, V128,
 };
 use crate::{prelude::*, CompositeInnerType, Ordering};
 use core::ops::{Deref, DerefMut};
@@ -605,8 +605,8 @@ where
     }
 
     /// Pop a reference type from the operand stack.
-    fn pop_ref(&mut self) -> Result<Option<RefType>> {
-        match self.pop_operand(None)? {
+    fn pop_ref(&mut self, expected: Option<RefType>) -> Result<Option<RefType>> {
+        match self.pop_operand(expected.map(|t| t.into()))? {
             MaybeType::Bot | MaybeType::HeapBot => Ok(None),
             MaybeType::Type(ValType::Ref(rt)) => Ok(Some(rt)),
             MaybeType::Type(ty) => bail!(
@@ -626,7 +626,7 @@ where
         &mut self,
         expected: AbstractHeapType,
     ) -> Result<Option<(RefType, bool)>> {
-        let actual = match self.pop_ref()? {
+        let actual = match self.pop_ref(None)? {
             Some(rt) => rt,
             None => return Ok(None),
         };
@@ -881,18 +881,8 @@ where
         let unpacked_index = UnpackedIndex::Module(type_index);
         let mut hty = HeapType::Concrete(unpacked_index);
         self.resources.check_heap_type(&mut hty, self.offset)?;
-        // If `None` is popped then that means a "bottom" type was popped which
-        // is always considered equivalent to the `hty` tag.
-        if let Some(rt) = self.pop_ref()? {
-            let expected = RefType::new(true, hty).expect("hty should be previously validated");
-            let expected = ValType::Ref(expected);
-            if !self.resources.is_subtype(ValType::Ref(rt), expected) {
-                bail!(
-                    self.offset,
-                    "type mismatch: funcref on stack does not match specified type",
-                );
-            }
-        }
+        let expected = RefType::new(true, hty).expect("hty should be previously validated");
+        self.pop_ref(Some(expected))?;
         self.func_type_at(type_index)
     }
 
@@ -1130,51 +1120,31 @@ where
 
     /// Common helper for `ref.test` and `ref.cast` downcasting/checking
     /// instructions. Returns the given `heap_type` as a `ValType`.
-    fn check_downcast(
-        &mut self,
-        nullable: bool,
-        mut heap_type: HeapType,
-        inst_name: &str,
-    ) -> Result<ValType> {
+    fn check_downcast(&mut self, nullable: bool, mut heap_type: HeapType) -> Result<RefType> {
         self.resources
             .check_heap_type(&mut heap_type, self.offset)?;
 
-        let sub_ty = RefType::new(nullable, heap_type)
-            .map(ValType::from)
-            .ok_or_else(|| {
-                BinaryReaderError::new("implementation limit: type index too large", self.offset)
-            })?;
-
-        let sup_ty = self.pop_ref()?.unwrap_or_else(|| {
-            sub_ty
-                .as_reference_type()
-                .expect("we created this as a reference just above")
-        });
-        let sup_ty = RefType::new(true, self.resources.top_type(&sup_ty.heap_type()))
+        let sub_ty = RefType::new(nullable, heap_type).ok_or_else(|| {
+            BinaryReaderError::new("implementation limit: type index too large", self.offset)
+        })?;
+        let sup_ty = RefType::new(true, self.resources.top_type(&heap_type))
             .expect("can't panic with non-concrete heap types");
 
-        if !self.resources.is_subtype(sub_ty, sup_ty.into()) {
-            bail!(
-                self.offset,
-                "{inst_name}'s heap type must be a sub type of the type on the stack: \
-                 {sub_ty} is not a sub type of {sup_ty}"
-            );
-        }
-
+        self.pop_ref(Some(sup_ty))?;
         Ok(sub_ty)
     }
 
     /// Common helper for both nullable and non-nullable variants of `ref.test`
     /// instructions.
     fn check_ref_test(&mut self, nullable: bool, heap_type: HeapType) -> Result<()> {
-        self.check_downcast(nullable, heap_type, "ref.test")?;
+        self.check_downcast(nullable, heap_type)?;
         self.push_operand(ValType::I32)
     }
 
     /// Common helper for both nullable and non-nullable variants of `ref.cast`
     /// instructions.
     fn check_ref_cast(&mut self, nullable: bool, heap_type: HeapType) -> Result<()> {
-        let sub_ty = self.check_downcast(nullable, heap_type, "ref.cast")?;
+        let sub_ty = self.check_downcast(nullable, heap_type)?;
         self.push_operand(sub_ty)
     }
 
@@ -1199,10 +1169,8 @@ where
         struct_type_index: u32,
         field_index: u32,
     ) -> Result<()> {
-        let ty = self
-            .struct_field_at(struct_type_index, field_index)?
-            .element_type;
-        let field_ty = match ty {
+        let field = self.mutable_struct_field_at(struct_type_index, field_index)?;
+        let field_ty = match field.element_type {
             StorageType::Val(ValType::I32) => ValType::I32,
             StorageType::Val(ValType::I64) => ValType::I64,
             _ => bail!(
@@ -1220,8 +1188,8 @@ where
     /// Common helper for checking the types of arrays accessed with atomic RMW
     /// instructions, which only allow `i32` and `i64`.
     fn check_array_atomic_rmw(&mut self, op: &'static str, type_index: u32) -> Result<()> {
-        let ty = self.array_type_at(type_index)?.0.element_type;
-        let elem_ty = match ty {
+        let field = self.mutable_array_type_at(type_index)?;
+        let elem_ty = match field.element_type {
             StorageType::Val(ValType::I32) => ValType::I32,
             StorageType::Val(ValType::I64) => ValType::I64,
             _ => bail!(
@@ -1279,10 +1247,25 @@ where
             })
     }
 
-    fn array_type_at(&self, at: u32) -> Result<&'resources ArrayType> {
+    fn mutable_struct_field_at(
+        &self,
+        struct_type_index: u32,
+        field_index: u32,
+    ) -> Result<FieldType> {
+        let field = self.struct_field_at(struct_type_index, field_index)?;
+        if !field.mutable {
+            bail!(
+                self.offset,
+                "invalid struct modification: struct field is immutable"
+            )
+        }
+        Ok(field)
+    }
+
+    fn array_type_at(&self, at: u32) -> Result<FieldType> {
         let sub_ty = self.sub_type_at(at)?;
         if let CompositeInnerType::Array(array_ty) = &sub_ty.composite_type.inner {
-            Ok(array_ty)
+            Ok(array_ty.0)
         } else {
             bail!(
                 self.offset,
@@ -1291,6 +1274,17 @@ where
         }
     }
 
+    fn mutable_array_type_at(&self, at: u32) -> Result<FieldType> {
+        let field = self.array_type_at(at)?;
+        if !field.mutable {
+            bail!(
+                self.offset,
+                "invalid array modification: array is immutable"
+            )
+        }
+        Ok(field)
+    }
+
     fn func_type_at(&self, at: u32) -> Result<&'resources FuncType> {
         let sub_ty = self.sub_type_at(at)?;
         if let CompositeInnerType::Func(func_ty) = &sub_ty.composite_type.inner {
@@ -2672,7 +2666,7 @@ where
     }
 
     fn visit_ref_as_non_null(&mut self) -> Self::Output {
-        let ty = match self.pop_ref()? {
+        let ty = match self.pop_ref(None)? {
             Some(ty) => MaybeType::Type(ValType::Ref(ty.as_non_null())),
             None => MaybeType::HeapBot,
         };
@@ -2680,7 +2674,7 @@ where
         Ok(())
     }
     fn visit_br_on_null(&mut self, relative_depth: u32) -> Self::Output {
-        let ref_ty = match self.pop_ref()? {
+        let ref_ty = match self.pop_ref(None)? {
             None => MaybeType::HeapBot,
             Some(ty) => MaybeType::Type(ValType::Ref(ty.as_non_null())),
         };
@@ -2691,41 +2685,27 @@ where
         Ok(())
     }
     fn visit_br_on_non_null(&mut self, relative_depth: u32) -> Self::Output {
-        let ty = self.pop_ref()?;
         let (ft, kind) = self.jump(relative_depth)?;
 
         let mut label_types = self.label_types(ft, kind)?;
-        match (label_types.next_back(), ty) {
-            (None, _) => bail!(
+        let expected = match label_types.next_back() {
+            None => bail!(
                 self.offset,
                 "type mismatch: br_on_non_null target has no label types",
             ),
-            (Some(ValType::Ref(_)), None) => {}
-            (Some(rt1 @ ValType::Ref(_)), Some(rt0)) => {
-                // Switch rt0, our popped type, to a non-nullable type and
-                // perform the match because if the branch is taken it's a
-                // non-null value.
-                let ty = rt0.as_non_null();
-                if !self.resources.is_subtype(ty.into(), rt1) {
-                    bail!(
-                        self.offset,
-                        "type mismatch: expected {} but found {}",
-                        ty_to_str(rt0.into()),
-                        ty_to_str(rt1)
-                    )
-                }
-            }
-            (Some(_), _) => bail!(
+            Some(ValType::Ref(ty)) => ty,
+            Some(_) => bail!(
                 self.offset,
                 "type mismatch: br_on_non_null target does not end with heap type",
             ),
-        }
+        };
+        self.pop_ref(Some(expected.nullable()))?;
 
         self.pop_push_label_types(label_types)?;
         Ok(())
     }
     fn visit_ref_is_null(&mut self) -> Self::Output {
-        self.pop_ref()?;
+        self.pop_ref(None)?;
         self.push_operand(ValType::I32)?;
         Ok(())
     }
@@ -3876,7 +3856,7 @@ where
         if field_ty.element_type.is_packed() {
             bail!(
                 self.offset,
-                "can only use struct.get with non-packed storage types"
+                "can only use struct `get` with non-packed storage types"
             )
         }
         self.pop_concrete_ref(true, struct_type_index)?;
@@ -3961,10 +3941,7 @@ where
         Ok(())
     }
     fn visit_struct_set(&mut self, struct_type_index: u32, field_index: u32) -> Self::Output {
-        let field_ty = self.struct_field_at(struct_type_index, field_index)?;
-        if !field_ty.mutable {
-            bail!(self.offset, "invalid struct.set: struct field is immutable")
-        }
+        let field_ty = self.mutable_struct_field_at(struct_type_index, field_index)?;
         self.pop_operand(Some(field_ty.element_type.unpack()))?;
         self.pop_concrete_ref(true, struct_type_index)?;
         Ok(())
@@ -4041,10 +4018,8 @@ where
         struct_type_index: u32,
         field_index: u32,
     ) -> Self::Output {
-        let field_ty = self
-            .struct_field_at(struct_type_index, field_index)?
-            .element_type;
-        let is_valid_type = match field_ty {
+        let field = self.mutable_struct_field_at(struct_type_index, field_index)?;
+        let is_valid_type = match field.element_type {
             StorageType::Val(ValType::I32) | StorageType::Val(ValType::I64) => true,
             StorageType::Val(v) => self
                 .resources
@@ -4057,7 +4032,7 @@ where
                 "invalid type: `struct.atomic.rmw.xchg` only allows `i32`, `i64` and subtypes of `anyref`"
             );
         }
-        let field_ty = field_ty.unpack();
+        let field_ty = field.element_type.unpack();
         self.pop_operand(Some(field_ty))?;
         self.pop_concrete_ref(true, struct_type_index)?;
         self.push_operand(field_ty)?;
@@ -4069,10 +4044,8 @@ where
         struct_type_index: u32,
         field_index: u32,
     ) -> Self::Output {
-        let field_ty = self
-            .struct_field_at(struct_type_index, field_index)?
-            .element_type;
-        let is_valid_type = match field_ty {
+        let field = self.mutable_struct_field_at(struct_type_index, field_index)?;
+        let is_valid_type = match field.element_type {
             StorageType::Val(ValType::I32) | StorageType::Val(ValType::I64) => true,
             StorageType::Val(v) => self
                 .resources
@@ -4085,7 +4058,7 @@ where
                 "invalid type: `struct.atomic.rmw.cmpxchg` only allows `i32`, `i64` and subtypes of `eqref`"
             );
         }
-        let field_ty = field_ty.unpack();
+        let field_ty = field.element_type.unpack();
         self.pop_operand(Some(field_ty))?;
         self.pop_operand(Some(field_ty))?;
         self.pop_concrete_ref(true, struct_type_index)?;
@@ -4095,12 +4068,12 @@ where
     fn visit_array_new(&mut self, type_index: u32) -> Self::Output {
         let array_ty = self.array_type_at(type_index)?;
         self.pop_operand(Some(ValType::I32))?;
-        self.pop_operand(Some(array_ty.0.element_type.unpack()))?;
+        self.pop_operand(Some(array_ty.element_type.unpack()))?;
         self.push_concrete_ref(false, type_index)
     }
     fn visit_array_new_default(&mut self, type_index: u32) -> Self::Output {
         let ty = self.array_type_at(type_index)?;
-        let val_ty = ty.0.element_type.unpack();
+        let val_ty = ty.element_type.unpack();
         if !val_ty.is_defaultable() {
             bail!(
                 self.offset,
@@ -4112,7 +4085,7 @@ where
     }
     fn visit_array_new_fixed(&mut self, type_index: u32, n: u32) -> Self::Output {
         let array_ty = self.array_type_at(type_index)?;
-        let elem_ty = array_ty.0.element_type.unpack();
+        let elem_ty = array_ty.element_type.unpack();
         for _ in 0..n {
             self.pop_operand(Some(elem_ty))?;
         }
@@ -4120,7 +4093,7 @@ where
     }
     fn visit_array_new_data(&mut self, type_index: u32, data_index: u32) -> Self::Output {
         let array_ty = self.array_type_at(type_index)?;
-        let elem_ty = array_ty.0.element_type.unpack();
+        let elem_ty = array_ty.element_type.unpack();
         match elem_ty {
             ValType::I32 | ValType::I64 | ValType::F32 | ValType::F64 | ValType::V128 => {}
             ValType::Ref(_) => bail!(
@@ -4139,7 +4112,7 @@ where
     }
     fn visit_array_new_elem(&mut self, type_index: u32, elem_index: u32) -> Self::Output {
         let array_ty = self.array_type_at(type_index)?;
-        let array_ref_ty = match array_ty.0.element_type.unpack() {
+        let array_ref_ty = match array_ty.element_type.unpack() {
             ValType::Ref(rt) => rt,
             ValType::I32 | ValType::I64 | ValType::F32 | ValType::F64 | ValType::V128 => bail!(
                 self.offset,
@@ -4163,7 +4136,7 @@ where
     }
     fn visit_array_get(&mut self, type_index: u32) -> Self::Output {
         let array_ty = self.array_type_at(type_index)?;
-        let elem_ty = array_ty.0.element_type;
+        let elem_ty = array_ty.element_type;
         if elem_ty.is_packed() {
             bail!(
                 self.offset,
@@ -4177,7 +4150,7 @@ where
     fn visit_array_atomic_get(&mut self, _ordering: Ordering, type_index: u32) -> Self::Output {
         self.visit_array_get(type_index)?;
         // The `atomic` version has some additional type restrictions.
-        let elem_ty = self.array_type_at(type_index)?.0.element_type;
+        let elem_ty = self.array_type_at(type_index)?.element_type;
         let is_valid_type = match elem_ty {
             StorageType::Val(ValType::I32) | StorageType::Val(ValType::I64) => true,
             StorageType::Val(v) => self
@@ -4195,7 +4168,7 @@ where
     }
     fn visit_array_get_s(&mut self, type_index: u32) -> Self::Output {
         let array_ty = self.array_type_at(type_index)?;
-        let elem_ty = array_ty.0.element_type;
+        let elem_ty = array_ty.element_type;
         if !elem_ty.is_packed() {
             bail!(
                 self.offset,
@@ -4210,14 +4183,14 @@ where
         self.visit_array_get_s(type_index)?;
         // This instruction has the same type restrictions as the non-`atomic` version.
         debug_assert!(matches!(
-            self.array_type_at(type_index)?.0.element_type,
+            self.array_type_at(type_index)?.element_type,
             StorageType::I8 | StorageType::I16
         ));
         Ok(())
     }
     fn visit_array_get_u(&mut self, type_index: u32) -> Self::Output {
         let array_ty = self.array_type_at(type_index)?;
-        let elem_ty = array_ty.0.element_type;
+        let elem_ty = array_ty.element_type;
         if !elem_ty.is_packed() {
             bail!(
                 self.offset,
@@ -4232,17 +4205,14 @@ where
         self.visit_array_get_u(type_index)?;
         // This instruction has the same type restrictions as the non-`atomic` version.
         debug_assert!(matches!(
-            self.array_type_at(type_index)?.0.element_type,
+            self.array_type_at(type_index)?.element_type,
             StorageType::I8 | StorageType::I16
         ));
         Ok(())
     }
     fn visit_array_set(&mut self, type_index: u32) -> Self::Output {
-        let array_ty = self.array_type_at(type_index)?;
-        if !array_ty.0.mutable {
-            bail!(self.offset, "invalid array.set: array is immutable")
-        }
-        self.pop_operand(Some(array_ty.0.element_type.unpack()))?;
+        let array_ty = self.mutable_array_type_at(type_index)?;
+        self.pop_operand(Some(array_ty.element_type.unpack()))?;
         self.pop_operand(Some(ValType::I32))?;
         self.pop_concrete_ref(true, type_index)?;
         Ok(())
@@ -4250,7 +4220,7 @@ where
     fn visit_array_atomic_set(&mut self, _ordering: Ordering, type_index: u32) -> Self::Output {
         self.visit_array_set(type_index)?;
         // The `atomic` version has some additional type restrictions.
-        let elem_ty = self.array_type_at(type_index)?.0.element_type;
+        let elem_ty = self.array_type_at(type_index)?.element_type;
         let is_valid_type = match elem_ty {
             StorageType::I8 | StorageType::I16 => true,
             StorageType::Val(ValType::I32) | StorageType::Val(ValType::I64) => true,
@@ -4271,26 +4241,17 @@ where
         self.push_operand(ValType::I32)
     }
     fn visit_array_fill(&mut self, array_type_index: u32) -> Self::Output {
-        let array_ty = self.array_type_at(array_type_index)?;
-        if !array_ty.0.mutable {
-            bail!(self.offset, "invalid array.fill: array is immutable");
-        }
+        let array_ty = self.mutable_array_type_at(array_type_index)?;
         self.pop_operand(Some(ValType::I32))?;
-        self.pop_operand(Some(array_ty.0.element_type.unpack()))?;
+        self.pop_operand(Some(array_ty.element_type.unpack()))?;
         self.pop_operand(Some(ValType::I32))?;
         self.pop_concrete_ref(true, array_type_index)?;
         Ok(())
     }
     fn visit_array_copy(&mut self, type_index_dst: u32, type_index_src: u32) -> Self::Output {
-        let array_ty_dst = self.array_type_at(type_index_dst)?;
-        if !array_ty_dst.0.mutable {
-            bail!(
-                self.offset,
-                "invalid array.copy: destination array is immutable"
-            );
-        }
+        let array_ty_dst = self.mutable_array_type_at(type_index_dst)?;
         let array_ty_src = self.array_type_at(type_index_src)?;
-        match (array_ty_dst.0.element_type, array_ty_src.0.element_type) {
+        match (array_ty_dst.element_type, array_ty_src.element_type) {
             (StorageType::I8, StorageType::I8) => {}
             (StorageType::I8, ty) => bail!(
                 self.offset,
@@ -4328,11 +4289,8 @@ where
         array_type_index: u32,
         array_data_index: u32,
     ) -> Self::Output {
-        let array_ty = self.array_type_at(array_type_index)?;
-        if !array_ty.0.mutable {
-            bail!(self.offset, "invalid array.init_data: array is immutable");
-        }
-        let val_ty = array_ty.0.element_type.unpack();
+        let array_ty = self.mutable_array_type_at(array_type_index)?;
+        let val_ty = array_ty.element_type.unpack();
         match val_ty {
             ValType::I32 | ValType::I64 | ValType::F32 | ValType::F64 | ValType::V128 => {}
             ValType::Ref(_) => bail!(
@@ -4352,11 +4310,8 @@ where
         Ok(())
     }
     fn visit_array_init_elem(&mut self, type_index: u32, elem_index: u32) -> Self::Output {
-        let array_ty = self.array_type_at(type_index)?;
-        if !array_ty.0.mutable {
-            bail!(self.offset, "invalid array.init_data: array is immutable");
-        }
-        let array_ref_ty = match array_ty.0.element_type.unpack() {
+        let array_ty = self.mutable_array_type_at(type_index)?;
+        let array_ref_ty = match array_ty.element_type.unpack() {
             ValType::Ref(rt) => rt,
             ValType::I32 | ValType::I64 | ValType::F32 | ValType::F64 | ValType::V128 => bail!(
                 self.offset,
@@ -4400,8 +4355,8 @@ where
         _ordering: Ordering,
         type_index: u32,
     ) -> Self::Output {
-        let elem_ty = self.array_type_at(type_index)?.0.element_type;
-        let is_valid_type = match elem_ty {
+        let field = self.mutable_array_type_at(type_index)?;
+        let is_valid_type = match field.element_type {
             StorageType::Val(ValType::I32) | StorageType::Val(ValType::I64) => true,
             StorageType::Val(v) => self
                 .resources
@@ -4414,7 +4369,7 @@ where
                 "invalid type: `array.atomic.rmw.xchg` only allows `i32`, `i64` and subtypes of `anyref`"
             );
         }
-        let elem_ty = elem_ty.unpack();
+        let elem_ty = field.element_type.unpack();
         self.pop_operand(Some(elem_ty))?;
         self.pop_operand(Some(ValType::I32))?;
         self.pop_concrete_ref(true, type_index)?;
@@ -4426,8 +4381,8 @@ where
         _ordering: Ordering,
         type_index: u32,
     ) -> Self::Output {
-        let elem_ty = self.array_type_at(type_index)?.0.element_type;
-        let is_valid_type = match elem_ty {
+        let field = self.mutable_array_type_at(type_index)?;
+        let is_valid_type = match field.element_type {
             StorageType::Val(ValType::I32) | StorageType::Val(ValType::I64) => true,
             StorageType::Val(v) => self
                 .resources
@@ -4440,7 +4395,7 @@ where
                 "invalid type: `array.atomic.rmw.cmpxchg` only allows `i32`, `i64` and subtypes of `eqref`"
             );
         }
-        let elem_ty = elem_ty.unpack();
+        let elem_ty = field.element_type.unpack();
         self.pop_operand(Some(elem_ty))?;
         self.pop_operand(Some(elem_ty))?;
         self.pop_operand(Some(ValType::I32))?;


Test patch:
diff --git a/crates/wasm-smith/tests/common/mod.rs b/crates/wasm-smith/tests/common/mod.rs
index 8a238776..332fd0ca 100644
--- a/crates/wasm-smith/tests/common/mod.rs
+++ b/crates/wasm-smith/tests/common/mod.rs
@@ -2,7 +2,7 @@ use wasm_smith::Config;
 use wasmparser::{types::Types, Validator, WasmFeatures};
 
 pub fn parser_features_from_config(config: &Config) -> WasmFeatures {
-    let mut features = WasmFeatures::MUTABLE_GLOBAL | WasmFeatures::FLOATS;
+    let mut features = WasmFeatures::MUTABLE_GLOBAL | WasmFeatures::wasm1();
     features.set(
         WasmFeatures::SATURATING_FLOAT_TO_INT,
         config.saturating_float_to_int_enabled,
diff --git a/crates/wasm-wave/tests/ui/reject-chars.out b/crates/wasm-wave/tests/ui/reject-chars.out
index 6ae4b719..fde86aab 100644
--- a/crates/wasm-wave/tests/ui/reject-chars.out
+++ b/crates/wasm-wave/tests/ui/reject-chars.out
@@ -1,7 +1,7 @@
 // Wrong length
 invalid token at 5..6
 invalid token at 5..9
-invalid token at 5..9
+invalid token at 5..13
 invalid token at 5..6
 // Invalid escapes
 invalid token at 5..6
diff --git a/crates/wit-component/tests/linking.rs b/crates/wit-component/tests/linking.rs
index d610ec4e..fdc020ab 100644
--- a/crates/wit-component/tests/linking.rs
+++ b/crates/wit-component/tests/linking.rs
@@ -202,10 +202,14 @@ fn linking() -> Result<()> {
         let mut store = Store::new(&engine, ());
         let instance = linker.instantiate(&mut store, &Component::new(&engine, &component)?)?;
         let func = instance
-            .exports(&mut store)
-            .instance("test:test/test")
-            .ok_or_else(|| anyhow!("instance `test:test/test` not found"))?
-            .typed_func::<(i32,), (i32,)>("bar")?;
+            .get_export(&mut store, None, "test:test/test")
+            .and_then(|i| instance.get_export(&mut store, Some(&i), "bar"))
+            .and_then(|f| {
+                instance
+                    .get_typed_func::<(i32,), (i32,)>(&mut store, &f)
+                    .ok()
+            })
+            .ok_or_else(|| anyhow!("func `test:test/test/bar` not found"))?;
 
         assert_eq!(65, func.call(&mut store, (7,))?.0);
     }
diff --git a/tests/cli/validate-unknown-features.wat.stderr b/tests/cli/validate-unknown-features.wat.stderr
index 7aed7b2c..3e0ccb84 100644
--- a/tests/cli/validate-unknown-features.wat.stderr
+++ b/tests/cli/validate-unknown-features.wat.stderr
@@ -1,4 +1,4 @@
 error: invalid value 'unknown' for '--features <FEATURES>': unknown feature `unknown`
-Valid features: mutable-global, saturating-float-to-int, sign-extension, reference-types, multi-value, bulk-memory, simd, relaxed-simd, threads, shared-everything-threads, tail-call, floats, multi-memory, exceptions, memory64, extended-const, component-model, function-references, memory-control, gc, custom-page-sizes, component-model-values, component-model-nested-names, component-model-more-flags, component-model-multiple-returns, legacy-exceptions
+Valid features: mutable-global, saturating-float-to-int, sign-extension, reference-types, multi-value, bulk-memory, simd, relaxed-simd, threads, shared-everything-threads, tail-call, floats, multi-memory, exceptions, memory64, extended-const, component-model, function-references, memory-control, gc, custom-page-sizes, component-model-values, component-model-nested-names, component-model-more-flags, component-model-multiple-returns, legacy-exceptions, gc-types
 
 For more information, try '--help'.
diff --git a/tests/local/function-references/bad-call-ref-ty.wast b/tests/local/function-references/bad-call-ref-ty.wast
index 523813b4..0eeb2df3 100644
--- a/tests/local/function-references/bad-call-ref-ty.wast
+++ b/tests/local/function-references/bad-call-ref-ty.wast
@@ -5,7 +5,7 @@
       (call_ref $t (local.get $f))
     )
   )
-  "funcref on stack does not match specified type")
+  "expected (ref null $type), found funcref")
 
 (assert_invalid
   (module
diff --git a/tests/local/gc/br-on-non-null.wast b/tests/local/gc/br-on-non-null.wast
new file mode 100644
index 00000000..e20f9a56
--- /dev/null
+++ b/tests/local/gc/br-on-non-null.wast
@@ -0,0 +1,12 @@
+(assert_invalid
+  (module
+    (func
+      block $l (result anyref)
+        ref.null func
+        br_on_non_null $l
+        unreachable
+      end
+      drop
+    )
+  )
+  "expected anyref, found funcref")
diff --git a/tests/local/missing-features/gc/gc-types-disabled.wast b/tests/local/missing-features/gc/gc-types-disabled.wast
new file mode 100644
index 00000000..3cd59484
--- /dev/null
+++ b/tests/local/missing-features/gc/gc-types-disabled.wast
@@ -0,0 +1,32 @@
+(assert_invalid
+  (module
+    (type (func (result externref)))
+  )
+  "gc types are disallowed")
+
+(assert_invalid
+  (module
+    (type (func (result (ref any))))
+  )
+  "gc types are disallowed")
+
+(module
+  (table 1 funcref)
+)
+
+(module
+  (type $t (func))
+  (table 1 (ref null $t))
+)
+
+(assert_invalid
+  (module
+    (type (array i8))
+  )
+  "cannot define array types")
+
+(assert_invalid
+  (module
+    (type (struct))
+  )
+  "cannot define struct types")
diff --git a/tests/local/shared-everything-threads/arrays.wast b/tests/local/shared-everything-threads/arrays.wast
index aa041f96..b545b445 100644
--- a/tests/local/shared-everything-threads/arrays.wast
+++ b/tests/local/shared-everything-threads/arrays.wast
@@ -138,6 +138,80 @@
   (func (array.init_elem $funcs 0 (ref.null (shared none)) (i32.const 0) (i32.const 0) (i32.const 0)))
 )
 
+;; Check that field-modifying instructions only work on mutable fields.
+(assert_invalid
+  (module
+    (type $a (shared (array (ref (shared any)))))
+    (func (param $a (ref $a)) (param $ar (ref (shared any))) (result (ref (shared any)))
+      (array.atomic.set seq_cst $a (local.get $a) (i32.const 0) (local.get $ar))
+    )
+  )
+  "array is immutable"
+)
+(assert_invalid
+  (module
+    (type $a (shared (array i32)))
+    (func (param $a (ref $a)) (result i32)
+      (array.atomic.rmw.add seq_cst $a (local.get $a) (i32.const 0) (i32.const 1))
+    )
+  )
+  "array is immutable"
+)
+(assert_invalid
+  (module
+    (type $a (shared (array i64)))
+    (func (param $a (ref $a)) (result i64)
+      (array.atomic.rmw.sub seq_cst $a (local.get $a) (i32.const 0) (i64.const 1))
+    )
+  )
+  "array is immutable"
+)
+(assert_invalid
+  (module
+    (type $a (shared (array i32)))
+    (func (param $a (ref $a)) (result i32)
+      (array.atomic.rmw.and acq_rel $a (local.get $a) (i32.const 0) (i32.const 1))
+    )
+  )
+  "array is immutable"
+)
+(assert_invalid
+  (module
+    (type $a (shared (array i64)))
+    (func (param $a (ref $a)) (result i64)
+      (array.atomic.rmw.or acq_rel $a (local.get $a) (i32.const 0) (i64.const 1))
+    )
+  )
+  "array is immutable"
+)
+(assert_invalid
+  (module
+    (type $a (shared (array i32)))
+    (func (param $a (ref $a)) (result i32)
+      (array.atomic.rmw.xor seq_cst $a (local.get $a) (i32.const 0) (i32.const 1))
+    )
+  )
+  "array is immutable"
+)
+(assert_invalid
+  (module
+    (type $a (shared (array (ref (shared any)))))
+    (func (param $a (ref $a)) (param $ar (ref (shared any))) (result (ref (shared any)))
+      (array.atomic.rmw.xchg seq_cst $a (local.get $a) (i32.const 0) (local.get $ar))
+    )
+  )
+  "array is immutable"
+)
+(assert_invalid
+  (module
+    (type $a (shared (array (ref (shared eq)))))
+    (func (param $a (ref $a)) (param $e1 (ref (shared eq))) (param $e2 (ref (shared eq))) (result)
+      (array.atomic.rmw.cmpxchg acq_rel $a (local.get $a) (i32.const 0) (local.get $e1) (local.get $e2))
+    )
+  )
+  "array is immutable"
+)
+
 ;; Exhaustively check `array.atomic.rmw.*` instructions.
 (module (; get, i32, seq_cst ;)
   (type $a (shared (array (mut i32))))
diff --git a/tests/local/shared-everything-threads/structs.wast b/tests/local/shared-everything-threads/structs.wast
index 69274c24..240e1f87 100644
--- a/tests/local/shared-everything-threads/structs.wast
+++ b/tests/local/shared-everything-threads/structs.wast
@@ -99,6 +99,80 @@
   (func (struct.set $i8 0 (ref.null (shared none)) (i32.const 0)))
 )
 
+;; Check that field-modifying instructions only work on mutable fields.
+(assert_invalid
+  (module
+    (type $s (shared (struct (field (ref (shared any))))))
+    (func (param $s (ref $s)) (param $a (ref (shared any))) (result (ref (shared any)))
+      (struct.atomic.set seq_cst $s 0 (local.get $s) (local.get $a))
+    )
+  )
+  "field is immutable"
+)
+(assert_invalid
+  (module
+    (type $s (shared (struct (field i32))))
+    (func (param $s (ref $s)) (result i32)
+      (struct.atomic.rmw.add seq_cst $s 0 (local.get $s) (i32.const 1))
+    )
+  )
+  "field is immutable"
+)
+(assert_invalid
+  (module
+    (type $s (shared (struct (field i64))))
+    (func (param $s (ref $s)) (result i64)
+      (struct.atomic.rmw.sub seq_cst $s 0 (local.get $s) (i64.const 1))
+    )
+  )
+  "field is immutable"
+)
+(assert_invalid
+  (module
+    (type $s (shared (struct (field i32))))
+    (func (param $s (ref $s)) (result i32)
+      (struct.atomic.rmw.and acq_rel $s 0 (local.get $s) (i32.const 1))
+    )
+  )
+  "field is immutable"
+)
+(assert_invalid
+  (module
+    (type $s (shared (struct (field i64))))
+    (func (param $s (ref $s)) (result i64)
+      (struct.atomic.rmw.or acq_rel $s 0 (local.get $s) (i64.const 1))
+    )
+  )
+  "field is immutable"
+)
+(assert_invalid
+  (module
+    (type $s (shared (struct (field i32))))
+    (func (param $s (ref $s)) (result i32)
+      (struct.atomic.rmw.xor seq_cst $s 0 (local.get $s) (i32.const 1))
+    )
+  )
+  "field is immutable"
+)
+(assert_invalid
+  (module
+    (type $s (shared (struct (field (ref (shared any))))))
+    (func (param $s (ref $s)) (param $a (ref (shared any))) (result (ref (shared any)))
+      (struct.atomic.rmw.xchg seq_cst $s 0 (local.get $s) (local.get $a))
+    )
+  )
+  "field is immutable"
+)
+(assert_invalid
+  (module
+    (type $s (shared (struct (field (ref (shared eq))))))
+    (func (param $s (ref $s)) (param $e1 (ref (shared eq))) (param $e2 (ref (shared eq))) (result (ref (shared eq)))
+      (struct.atomic.rmw.cmpxchg acq_rel $s 0 (local.get $s) (local.get $e1) (local.get $e2))
+    )
+  )
+  "field is immutable"
+)
+
 ;; Exhaustively check `struct.atomic.rmw.*` instructions.
 (module
   (type $s (shared (struct
diff --git a/tests/roundtrip.rs b/tests/roundtrip.rs
index b10d56bf..63917769 100644
--- a/tests/roundtrip.rs
+++ b/tests/roundtrip.rs
@@ -598,8 +598,9 @@ impl TestState {
         for part in test.iter().filter_map(|t| t.to_str()) {
             match part {
                 "testsuite" => {
-                    features = WasmFeatures::default();
-                    features.remove(WasmFeatures::COMPONENT_MODEL);
+                    features = WasmFeatures::wasm2();
+                    features |= WasmFeatures::TAIL_CALL;
+                    features |= WasmFeatures::EXTENDED_CONST;
 
                     // NB: when these proposals are merged upstream in the spec
                     // repo then this should be removed. Currently this hasn't
@@ -609,9 +610,11 @@ impl TestState {
                     features.remove(WasmFeatures::THREADS);
                 }
                 "missing-features" => {
-                    features = WasmFeatures::empty() | WasmFeatures::FLOATS;
+                    features =
+                        WasmFeatures::empty() | WasmFeatures::FLOATS | WasmFeatures::GC_TYPES;
                 }
                 "floats-disabled.wast" => features.remove(WasmFeatures::FLOATS),
+                "gc-types-disabled.wast" => features.remove(WasmFeatures::GC_TYPES),
                 "threads" => {
                     features.insert(WasmFeatures::THREADS);
                     features.remove(WasmFeatures::BULK_MEMORY);
diff --git a/tests/snapshots/local/function-references/bad-call-ref-ty.wast.json b/tests/snapshots/local/function-references/bad-call-ref-ty.wast.json
index 820679bc..742b282d 100644
--- a/tests/snapshots/local/function-references/bad-call-ref-ty.wast.json
+++ b/tests/snapshots/local/function-references/bad-call-ref-ty.wast.json
@@ -5,7 +5,7 @@
       "type": "assert_invalid",
       "line": 2,
       "filename": "bad-call-ref-ty.0.wasm",
-      "text": "funcref on stack does not match specified type",
+      "text": "expected (ref null $type), found funcref",
       "module_type": "binary"
     },
     {
diff --git a/tests/snapshots/local/gc/br-on-non-null.wast.json b/tests/snapshots/local/gc/br-on-non-null.wast.json
new file mode 100644
index 00000000..ec81660a
--- /dev/null
+++ b/tests/snapshots/local/gc/br-on-non-null.wast.json
@@ -0,0 +1,12 @@
+{
+  "source_filename": "tests/local/gc/br-on-non-null.wast",
+  "commands": [
+    {
+      "type": "assert_invalid",
+      "line": 2,
+      "filename": "br-on-non-null.0.wasm",
+      "text": "expected anyref, found funcref",
+      "module_type": "binary"
+    }
+  ]
+}
\ No newline at end of file
diff --git a/tests/snapshots/local/missing-features/gc/gc-types-disabled.wast.json b/tests/snapshots/local/missing-features/gc/gc-types-disabled.wast.json
new file mode 100644
index 00000000..3cec0176
--- /dev/null
+++ b/tests/snapshots/local/missing-features/gc/gc-types-disabled.wast.json
@@ -0,0 +1,43 @@
+{
+  "source_filename": "tests/local/missing-features/gc/gc-types-disabled.wast",
+  "commands": [
+    {
+      "type": "assert_invalid",
+      "line": 2,
+      "filename": "gc-types-disabled.0.wasm",
+      "text": "gc types are disallowed",
+      "module_type": "binary"
+    },
+    {
+      "type": "assert_invalid",
+      "line": 8,
+      "filename": "gc-types-disabled.1.wasm",
+      "text": "gc types are disallowed",
+      "module_type": "binary"
+    },
+    {
+      "type": "module",
+      "line": 13,
+      "filename": "gc-types-disabled.2.wasm"
+    },
+    {
+      "type": "module",
+      "line": 17,
+      "filename": "gc-types-disabled.3.wasm"
+    },
+    {
+      "type": "assert_invalid",
+      "line": 23,
+      "filename": "gc-types-disabled.4.wasm",
+      "text": "cannot define array types",
+      "module_type": "binary"
+    },
+    {
+      "type": "assert_invalid",
+      "line": 29,
+      "filename": "gc-types-disabled.5.wasm",
+      "text": "cannot define struct types",
+      "module_type": "binary"
+    }
+  ]
+}
\ No newline at end of file
diff --git a/tests/snapshots/local/missing-features/gc/gc-types-disabled.wast/2.print b/tests/snapshots/local/missing-features/gc/gc-types-disabled.wast/2.print
new file mode 100644
index 00000000..7f62195a
--- /dev/null
+++ b/tests/snapshots/local/missing-features/gc/gc-types-disabled.wast/2.print
@@ -0,0 +1,3 @@
+(module
+  (table (;0;) 1 funcref)
+)
diff --git a/tests/snapshots/local/missing-features/gc/gc-types-disabled.wast/3.print b/tests/snapshots/local/missing-features/gc/gc-types-disabled.wast/3.print
new file mode 100644
index 00000000..7e017d6d
--- /dev/null
+++ b/tests/snapshots/local/missing-features/gc/gc-types-disabled.wast/3.print
@@ -0,0 +1,4 @@
+(module
+  (type $t (;0;) (func))
+  (table (;0;) 1 (ref null $t))
+)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast.json b/tests/snapshots/local/shared-everything-threads/arrays.wast.json
index 59172cb6..fb61bec7 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast.json
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast.json
@@ -62,263 +62,279 @@
       "filename": "arrays.9.wasm"
     },
     {
-      "type": "module",
-      "line": 142,
-      "filename": "arrays.10.wasm"
+      "type": "assert_invalid",
+      "line": 143,
+      "filename": "arrays.10.wasm",
+      "text": "array is immutable",
+      "module_type": "binary"
     },
     {
-      "type": "module",
-      "line": 150,
-      "filename": "arrays.11.wasm"
+      "type": "assert_invalid",
+      "line": 152,
+      "filename": "arrays.11.wasm",
+      "text": "array is immutable",
+      "module_type": "binary"
     },
     {
-      "type": "module",
-      "line": 158,
-      "filename": "arrays.12.wasm"
+      "type": "assert_invalid",
+      "line": 161,
+      "filename": "arrays.12.wasm",
+      "text": "array is immutable",
+      "module_type": "binary"
     },
     {
-      "type": "module",
-      "line": 166,
-      "filename": "arrays.13.wasm"
+      "type": "assert_invalid",
+      "line": 170,
+      "filename": "arrays.13.wasm",
+      "text": "array is immutable",
+      "module_type": "binary"
     },
     {
-      "type": "module",
-      "line": 174,
-      "filename": "arrays.14.wasm"
+      "type": "assert_invalid",
+      "line": 179,
+      "filename": "arrays.14.wasm",
+      "text": "array is immutable",
+      "module_type": "binary"
     },
     {
-      "type": "module",
-      "line": 182,
-      "filename": "arrays.15.wasm"
+      "type": "assert_invalid",
+      "line": 188,
+      "filename": "arrays.15.wasm",
+      "text": "array is immutable",
+      "module_type": "binary"
     },
     {
-      "type": "module",
-      "line": 190,
-      "filename": "arrays.16.wasm"
+      "type": "assert_invalid",
+      "line": 197,
+      "filename": "arrays.16.wasm",
+      "text": "array is immutable",
+      "module_type": "binary"
     },
     {
-      "type": "module",
-      "line": 198,
-      "filename": "arrays.17.wasm"
+      "type": "assert_invalid",
+      "line": 206,
+      "filename": "arrays.17.wasm",
+      "text": "array is immutable",
+      "module_type": "binary"
     },
     {
       "type": "module",
-      "line": 206,
+      "line": 216,
       "filename": "arrays.18.wasm"
     },
     {
       "type": "module",
-      "line": 214,
+      "line": 224,
       "filename": "arrays.19.wasm"
     },
     {
       "type": "module",
-      "line": 222,
+      "line": 232,
       "filename": "arrays.20.wasm"
     },
     {
       "type": "module",
-      "line": 230,
+      "line": 240,
       "filename": "arrays.21.wasm"
     },
     {
       "type": "module",
-      "line": 238,
+      "line": 248,
       "filename": "arrays.22.wasm"
     },
     {
       "type": "module",
-      "line": 246,
+      "line": 256,
       "filename": "arrays.23.wasm"
     },
     {
       "type": "module",
-      "line": 254,
+      "line": 264,
       "filename": "arrays.24.wasm"
     },
     {
       "type": "module",
-      "line": 263,
+      "line": 272,
       "filename": "arrays.25.wasm"
     },
     {
       "type": "module",
-      "line": 272,
+      "line": 280,
       "filename": "arrays.26.wasm"
     },
     {
       "type": "module",
-      "line": 281,
+      "line": 288,
       "filename": "arrays.27.wasm"
     },
     {
       "type": "module",
-      "line": 290,
+      "line": 296,
       "filename": "arrays.28.wasm"
     },
     {
       "type": "module",
-      "line": 299,
+      "line": 304,
       "filename": "arrays.29.wasm"
     },
     {
       "type": "module",
-      "line": 308,
+      "line": 312,
       "filename": "arrays.30.wasm"
     },
     {
       "type": "module",
-      "line": 317,
+      "line": 320,
       "filename": "arrays.31.wasm"
     },
     {
       "type": "module",
-      "line": 326,
+      "line": 328,
       "filename": "arrays.32.wasm"
     },
     {
       "type": "module",
-      "line": 335,
+      "line": 337,
       "filename": "arrays.33.wasm"
     },
     {
       "type": "module",
-      "line": 344,
+      "line": 346,
       "filename": "arrays.34.wasm"
     },
     {
       "type": "module",
-      "line": 353,
+      "line": 355,
       "filename": "arrays.35.wasm"
     },
     {
       "type": "module",
-      "line": 362,
+      "line": 364,
       "filename": "arrays.36.wasm"
     },
     {
       "type": "module",
-      "line": 371,
+      "line": 373,
       "filename": "arrays.37.wasm"
     },
     {
       "type": "module",
-      "line": 380,
+      "line": 382,
       "filename": "arrays.38.wasm"
     },
     {
       "type": "module",
-      "line": 389,
+      "line": 391,
       "filename": "arrays.39.wasm"
     },
     {
       "type": "module",
-      "line": 398,
+      "line": 400,
       "filename": "arrays.40.wasm"
     },
     {
       "type": "module",
-      "line": 407,
+      "line": 409,
       "filename": "arrays.41.wasm"
     },
     {
       "type": "module",
-      "line": 416,
+      "line": 418,
       "filename": "arrays.42.wasm"
     },
     {
       "type": "module",
-      "line": 425,
+      "line": 427,
       "filename": "arrays.43.wasm"
     },
     {
       "type": "module",
-      "line": 434,
+      "line": 436,
       "filename": "arrays.44.wasm"
     },
     {
       "type": "module",
-      "line": 443,
+      "line": 445,
       "filename": "arrays.45.wasm"
     },
     {
       "type": "module",
-      "line": 452,
+      "line": 454,
       "filename": "arrays.46.wasm"
     },
     {
       "type": "module",
-      "line": 461,
+      "line": 463,
       "filename": "arrays.47.wasm"
     },
     {
       "type": "module",
-      "line": 470,
+      "line": 472,
       "filename": "arrays.48.wasm"
     },
     {
       "type": "module",
-      "line": 479,
+      "line": 481,
       "filename": "arrays.49.wasm"
     },
     {
       "type": "module",
-      "line": 488,
+      "line": 490,
       "filename": "arrays.50.wasm"
     },
     {
       "type": "module",
-      "line": 497,
+      "line": 499,
       "filename": "arrays.51.wasm"
     },
     {
       "type": "module",
-      "line": 506,
+      "line": 508,
       "filename": "arrays.52.wasm"
     },
     {
       "type": "module",
-      "line": 515,
+      "line": 517,
       "filename": "arrays.53.wasm"
     },
     {
       "type": "module",
-      "line": 524,
+      "line": 526,
       "filename": "arrays.54.wasm"
     },
     {
       "type": "module",
-      "line": 533,
+      "line": 535,
       "filename": "arrays.55.wasm"
     },
     {
       "type": "module",
-      "line": 542,
+      "line": 544,
       "filename": "arrays.56.wasm"
     },
     {
       "type": "module",
-      "line": 551,
+      "line": 553,
       "filename": "arrays.57.wasm"
     },
     {
       "type": "module",
-      "line": 560,
+      "line": 562,
       "filename": "arrays.58.wasm"
     },
     {
       "type": "module",
-      "line": 569,
+      "line": 571,
       "filename": "arrays.59.wasm"
     },
     {
       "type": "module",
-      "line": 578,
+      "line": 580,
       "filename": "arrays.60.wasm"
     },
     {
       "type": "module",
-      "line": 588,
+      "line": 589,
       "filename": "arrays.61.wasm"
     },
     {
@@ -328,107 +344,147 @@
     },
     {
       "type": "module",
-      "line": 608,
+      "line": 607,
       "filename": "arrays.63.wasm"
     },
     {
       "type": "module",
-      "line": 618,
+      "line": 616,
       "filename": "arrays.64.wasm"
     },
     {
       "type": "module",
-      "line": 628,
+      "line": 625,
       "filename": "arrays.65.wasm"
     },
+    {
+      "type": "module",
+      "line": 634,
+      "filename": "arrays.66.wasm"
+    },
+    {
+      "type": "module",
+      "line": 643,
+      "filename": "arrays.67.wasm"
+    },
+    {
+      "type": "module",
+      "line": 652,
+      "filename": "arrays.68.wasm"
+    },
+    {
+      "type": "module",
+      "line": 662,
+      "filename": "arrays.69.wasm"
+    },
+    {
+      "type": "module",
+      "line": 672,
+      "filename": "arrays.70.wasm"
+    },
+    {
+      "type": "module",
+      "line": 682,
+      "filename": "arrays.71.wasm"
+    },
+    {
+      "type": "module",
+      "line": 692,
+      "filename": "arrays.72.wasm"
+    },
+    {
+      "type": "module",
+      "line": 702,
+      "filename": "arrays.73.wasm"
+    },
     {
       "type": "assert_invalid",
-      "line": 639,
-      "filename": "arrays.66.wasm",
+      "line": 713,
+      "filename": "arrays.74.wasm",
       "text": "packed storage type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 649,
-      "filename": "arrays.67.wasm",
+      "line": 723,
+      "filename": "arrays.75.wasm",
       "text": "non-packed storage type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 659,
-      "filename": "arrays.68.wasm",
+      "line": 733,
+      "filename": "arrays.76.wasm",
       "text": "non-packed storage type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 669,
-      "filename": "arrays.69.wasm",
+      "line": 743,
+      "filename": "arrays.77.wasm",
       "text": "non-packed storage type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 679,
-      "filename": "arrays.70.wasm",
+      "line": 753,
+      "filename": "arrays.78.wasm",
       "text": "non-packed storage type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 689,
-      "filename": "arrays.71.wasm",
+      "line": 763,
+      "filename": "arrays.79.wasm",
       "text": "invalid type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 700,
-      "filename": "arrays.72.wasm",
+      "line": 774,
+      "filename": "arrays.80.wasm",
       "text": "invalid type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 711,
-      "filename": "arrays.73.wasm",
+      "line": 785,
+      "filename": "arrays.81.wasm",
       "text": "invalid type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 722,
-      "filename": "arrays.74.wasm",
+      "line": 796,
+      "filename": "arrays.82.wasm",
       "text": "invalid type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 733,
-      "filename": "arrays.75.wasm",
+      "line": 807,
+      "filename": "arrays.83.wasm",
       "text": "invalid type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 744,
-      "filename": "arrays.76.wasm",
+      "line": 818,
+      "filename": "arrays.84.wasm",
       "text": "invalid type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 755,
-      "filename": "arrays.77.wasm",
+      "line": 829,
+      "filename": "arrays.85.wasm",
       "text": "invalid type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 767,
-      "filename": "arrays.78.wasm",
+      "line": 841,
+      "filename": "arrays.86.wasm",
       "text": "invalid type",
       "module_type": "binary"
     }
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/10.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/10.print
deleted file mode 100644
index f3d308bd..00000000
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/10.print
+++ /dev/null
@@ -1,10 +0,0 @@
-(module
-  (type $a (;0;) (shared(array (mut i32))))
-  (type (;1;) (func (param (ref null $a) i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
-    local.get $x
-    local.get $y
-    array.atomic.get seq_cst $a
-  )
-  (export "array-atomic-get-i32-seq_cst" (func 0))
-)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/11.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/11.print
deleted file mode 100644
index f733e005..00000000
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/11.print
+++ /dev/null
@@ -1,10 +0,0 @@
-(module
-  (type $a (;0;) (shared(array (mut i64))))
-  (type (;1;) (func (param (ref null $a) i32) (result i64)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i64)
-    local.get $x
-    local.get $y
-    array.atomic.get seq_cst $a
-  )
-  (export "array-atomic-get-i64-seq_cst" (func 0))
-)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/12.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/12.print
deleted file mode 100644
index 76dbd3ec..00000000
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/12.print
+++ /dev/null
@@ -1,10 +0,0 @@
-(module
-  (type $a (;0;) (shared(array (mut (ref null (shared any))))))
-  (type (;1;) (func (param (ref null $a) i32) (result (ref null (shared any)))))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result (ref null (shared any)))
-    local.get $x
-    local.get $y
-    array.atomic.get seq_cst $a
-  )
-  (export "array-atomic-get-anyref-seq_cst" (func 0))
-)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/13.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/13.print
deleted file mode 100644
index 5cf56083..00000000
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/13.print
+++ /dev/null
@@ -1,10 +0,0 @@
-(module
-  (type $a (;0;) (shared(array (mut i32))))
-  (type (;1;) (func (param (ref null $a) i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
-    local.get $x
-    local.get $y
-    array.atomic.get acq_rel $a
-  )
-  (export "array-atomic-get-i32-acq_rel" (func 0))
-)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/14.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/14.print
deleted file mode 100644
index b4b3919e..00000000
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/14.print
+++ /dev/null
@@ -1,10 +0,0 @@
-(module
-  (type $a (;0;) (shared(array (mut i64))))
-  (type (;1;) (func (param (ref null $a) i32) (result i64)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i64)
-    local.get $x
-    local.get $y
-    array.atomic.get acq_rel $a
-  )
-  (export "array-atomic-get-i64-acq_rel" (func 0))
-)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/15.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/15.print
deleted file mode 100644
index 189c2ea0..00000000
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/15.print
+++ /dev/null
@@ -1,10 +0,0 @@
-(module
-  (type $a (;0;) (shared(array (mut (ref null (shared any))))))
-  (type (;1;) (func (param (ref null $a) i32) (result (ref null (shared any)))))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result (ref null (shared any)))
-    local.get $x
-    local.get $y
-    array.atomic.get acq_rel $a
-  )
-  (export "array-atomic-get-anyref-acq_rel" (func 0))
-)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/16.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/16.print
deleted file mode 100644
index 00e0b300..00000000
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/16.print
+++ /dev/null
@@ -1,10 +0,0 @@
-(module
-  (type $a (;0;) (shared(array (mut i8))))
-  (type (;1;) (func (param (ref null $a) i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
-    local.get $x
-    local.get $y
-    array.atomic.get_s seq_cst $a
-  )
-  (export "array-atomic-get_s-i8-seq_cst" (func 0))
-)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/17.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/17.print
deleted file mode 100644
index 82d7db16..00000000
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/17.print
+++ /dev/null
@@ -1,10 +0,0 @@
-(module
-  (type $a (;0;) (shared(array (mut i16))))
-  (type (;1;) (func (param (ref null $a) i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
-    local.get $x
-    local.get $y
-    array.atomic.get_s seq_cst $a
-  )
-  (export "array-atomic-get_s-i16-seq_cst" (func 0))
-)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/18.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/18.print
index 0794e778..f3d308bd 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/18.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/18.print
@@ -1,10 +1,10 @@
 (module
-  (type $a (;0;) (shared(array (mut i8))))
+  (type $a (;0;) (shared(array (mut i32))))
   (type (;1;) (func (param (ref null $a) i32) (result i32)))
   (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
     local.get $x
     local.get $y
-    array.atomic.get_s acq_rel $a
+    array.atomic.get seq_cst $a
   )
-  (export "array-atomic-get_s-i8-acq_rel" (func 0))
+  (export "array-atomic-get-i32-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/19.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/19.print
index f7a27cdc..f733e005 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/19.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/19.print
@@ -1,10 +1,10 @@
 (module
-  (type $a (;0;) (shared(array (mut i16))))
-  (type (;1;) (func (param (ref null $a) i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
+  (type $a (;0;) (shared(array (mut i64))))
+  (type (;1;) (func (param (ref null $a) i32) (result i64)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i64)
     local.get $x
     local.get $y
-    array.atomic.get_s acq_rel $a
+    array.atomic.get seq_cst $a
   )
-  (export "array-atomic-get_s-i16-acq_rel" (func 0))
+  (export "array-atomic-get-i64-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/20.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/20.print
index 2ccc5994..76dbd3ec 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/20.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/20.print
@@ -1,10 +1,10 @@
 (module
-  (type $a (;0;) (shared(array (mut i8))))
-  (type (;1;) (func (param (ref null $a) i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
+  (type $a (;0;) (shared(array (mut (ref null (shared any))))))
+  (type (;1;) (func (param (ref null $a) i32) (result (ref null (shared any)))))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result (ref null (shared any)))
     local.get $x
     local.get $y
-    array.atomic.get_u seq_cst $a
+    array.atomic.get seq_cst $a
   )
-  (export "array-atomic-get_u-i8-seq_cst" (func 0))
+  (export "array-atomic-get-anyref-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/21.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/21.print
index 144068c5..5cf56083 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/21.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/21.print
@@ -1,10 +1,10 @@
 (module
-  (type $a (;0;) (shared(array (mut i16))))
+  (type $a (;0;) (shared(array (mut i32))))
   (type (;1;) (func (param (ref null $a) i32) (result i32)))
   (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
     local.get $x
     local.get $y
-    array.atomic.get_u seq_cst $a
+    array.atomic.get acq_rel $a
   )
-  (export "array-atomic-get_u-i16-seq_cst" (func 0))
+  (export "array-atomic-get-i32-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/22.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/22.print
index e5bed640..b4b3919e 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/22.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/22.print
@@ -1,10 +1,10 @@
 (module
-  (type $a (;0;) (shared(array (mut i8))))
-  (type (;1;) (func (param (ref null $a) i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
+  (type $a (;0;) (shared(array (mut i64))))
+  (type (;1;) (func (param (ref null $a) i32) (result i64)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i64)
     local.get $x
     local.get $y
-    array.atomic.get_u acq_rel $a
+    array.atomic.get acq_rel $a
   )
-  (export "array-atomic-get_u-i8-acq_rel" (func 0))
+  (export "array-atomic-get-i64-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/23.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/23.print
index 069d3eb6..189c2ea0 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/23.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/23.print
@@ -1,10 +1,10 @@
 (module
-  (type $a (;0;) (shared(array (mut i16))))
-  (type (;1;) (func (param (ref null $a) i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
+  (type $a (;0;) (shared(array (mut (ref null (shared any))))))
+  (type (;1;) (func (param (ref null $a) i32) (result (ref null (shared any)))))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result (ref null (shared any)))
     local.get $x
     local.get $y
-    array.atomic.get_u acq_rel $a
+    array.atomic.get acq_rel $a
   )
-  (export "array-atomic-get_u-i16-acq_rel" (func 0))
+  (export "array-atomic-get-anyref-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/24.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/24.print
index b1727c32..00e0b300 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/24.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/24.print
@@ -1,11 +1,10 @@
 (module
   (type $a (;0;) (shared(array (mut i8))))
-  (type (;1;) (func (param (ref null $a) i32 i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32)
+  (type (;1;) (func (param (ref null $a) i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
     local.get $x
     local.get $y
-    local.get $z
-    array.atomic.set seq_cst $a
+    array.atomic.get_s seq_cst $a
   )
-  (export "array-atomic-set-i8-seq_cst" (func 0))
+  (export "array-atomic-get_s-i8-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/25.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/25.print
index 95641f94..82d7db16 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/25.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/25.print
@@ -1,11 +1,10 @@
 (module
   (type $a (;0;) (shared(array (mut i16))))
-  (type (;1;) (func (param (ref null $a) i32 i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32)
+  (type (;1;) (func (param (ref null $a) i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
     local.get $x
     local.get $y
-    local.get $z
-    array.atomic.set seq_cst $a
+    array.atomic.get_s seq_cst $a
   )
-  (export "array-atomic-set-i16-seq_cst" (func 0))
+  (export "array-atomic-get_s-i16-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/26.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/26.print
index b8e21b1a..0794e778 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/26.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/26.print
@@ -1,11 +1,10 @@
 (module
-  (type $a (;0;) (shared(array (mut i32))))
-  (type (;1;) (func (param (ref null $a) i32 i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32)
+  (type $a (;0;) (shared(array (mut i8))))
+  (type (;1;) (func (param (ref null $a) i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
     local.get $x
     local.get $y
-    local.get $z
-    array.atomic.set seq_cst $a
+    array.atomic.get_s acq_rel $a
   )
-  (export "array-atomic-set-i32-seq_cst" (func 0))
+  (export "array-atomic-get_s-i8-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/27.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/27.print
index 6e11fb3a..f7a27cdc 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/27.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/27.print
@@ -1,11 +1,10 @@
 (module
-  (type $a (;0;) (shared(array (mut i64))))
-  (type (;1;) (func (param (ref null $a) i32 i64)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64)
+  (type $a (;0;) (shared(array (mut i16))))
+  (type (;1;) (func (param (ref null $a) i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
     local.get $x
     local.get $y
-    local.get $z
-    array.atomic.set seq_cst $a
+    array.atomic.get_s acq_rel $a
   )
-  (export "array-atomic-set-i64-seq_cst" (func 0))
+  (export "array-atomic-get_s-i16-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/28.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/28.print
index db65bed1..2ccc5994 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/28.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/28.print
@@ -1,11 +1,10 @@
 (module
-  (type $a (;0;) (shared(array (mut (ref null (shared any))))))
-  (type (;1;) (func (param (ref null $a) i32 (ref null (shared any)))))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z (ref null (shared any)))
+  (type $a (;0;) (shared(array (mut i8))))
+  (type (;1;) (func (param (ref null $a) i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
     local.get $x
     local.get $y
-    local.get $z
-    array.atomic.set seq_cst $a
+    array.atomic.get_u seq_cst $a
   )
-  (export "array-atomic-set-anyref-seq_cst" (func 0))
+  (export "array-atomic-get_u-i8-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/29.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/29.print
index 941e3f0d..144068c5 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/29.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/29.print
@@ -1,11 +1,10 @@
 (module
-  (type $a (;0;) (shared(array (mut i8))))
-  (type (;1;) (func (param (ref null $a) i32 i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32)
+  (type $a (;0;) (shared(array (mut i16))))
+  (type (;1;) (func (param (ref null $a) i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
     local.get $x
     local.get $y
-    local.get $z
-    array.atomic.set acq_rel $a
+    array.atomic.get_u seq_cst $a
   )
-  (export "array-atomic-set-i8-acq_rel" (func 0))
+  (export "array-atomic-get_u-i16-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/30.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/30.print
index 4e3d7c91..e5bed640 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/30.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/30.print
@@ -1,11 +1,10 @@
 (module
-  (type $a (;0;) (shared(array (mut i16))))
-  (type (;1;) (func (param (ref null $a) i32 i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32)
+  (type $a (;0;) (shared(array (mut i8))))
+  (type (;1;) (func (param (ref null $a) i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
     local.get $x
     local.get $y
-    local.get $z
-    array.atomic.set acq_rel $a
+    array.atomic.get_u acq_rel $a
   )
-  (export "array-atomic-set-i16-acq_rel" (func 0))
+  (export "array-atomic-get_u-i8-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/31.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/31.print
index 17aec3ab..069d3eb6 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/31.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/31.print
@@ -1,11 +1,10 @@
 (module
-  (type $a (;0;) (shared(array (mut i32))))
-  (type (;1;) (func (param (ref null $a) i32 i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32)
+  (type $a (;0;) (shared(array (mut i16))))
+  (type (;1;) (func (param (ref null $a) i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (result i32)
     local.get $x
     local.get $y
-    local.get $z
-    array.atomic.set acq_rel $a
+    array.atomic.get_u acq_rel $a
   )
-  (export "array-atomic-set-i32-acq_rel" (func 0))
+  (export "array-atomic-get_u-i16-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/32.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/32.print
index 43139589..b1727c32 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/32.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/32.print
@@ -1,11 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut i64))))
-  (type (;1;) (func (param (ref null $a) i32 i64)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64)
+  (type $a (;0;) (shared(array (mut i8))))
+  (type (;1;) (func (param (ref null $a) i32 i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32)
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.set acq_rel $a
+    array.atomic.set seq_cst $a
   )
-  (export "array-atomic-set-i64-acq_rel" (func 0))
+  (export "array-atomic-set-i8-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/33.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/33.print
index ed1acbaf..95641f94 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/33.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/33.print
@@ -1,11 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut (ref null (shared any))))))
-  (type (;1;) (func (param (ref null $a) i32 (ref null (shared any)))))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z (ref null (shared any)))
+  (type $a (;0;) (shared(array (mut i16))))
+  (type (;1;) (func (param (ref null $a) i32 i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32)
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.set acq_rel $a
+    array.atomic.set seq_cst $a
   )
-  (export "array-atomic-set-anyref-acq_rel" (func 0))
+  (export "array-atomic-set-i16-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/34.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/34.print
index d230670c..b8e21b1a 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/34.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/34.print
@@ -1,11 +1,11 @@
 (module
   (type $a (;0;) (shared(array (mut i32))))
-  (type (;1;) (func (param (ref null $a) i32 i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (result i32)
+  (type (;1;) (func (param (ref null $a) i32 i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32)
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.add seq_cst $a
+    array.atomic.set seq_cst $a
   )
-  (export "array-atomic-rmw.add-i32-seq_cst" (func 0))
+  (export "array-atomic-set-i32-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/35.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/35.print
index 28ea1094..6e11fb3a 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/35.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/35.print
@@ -1,11 +1,11 @@
 (module
   (type $a (;0;) (shared(array (mut i64))))
-  (type (;1;) (func (param (ref null $a) i32 i64) (result i64)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (result i64)
+  (type (;1;) (func (param (ref null $a) i32 i64)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64)
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.add seq_cst $a
+    array.atomic.set seq_cst $a
   )
-  (export "array-atomic-rmw.add-i64-seq_cst" (func 0))
+  (export "array-atomic-set-i64-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/36.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/36.print
index 8cc27f27..db65bed1 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/36.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/36.print
@@ -1,11 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut i32))))
-  (type (;1;) (func (param (ref null $a) i32 i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (result i32)
+  (type $a (;0;) (shared(array (mut (ref null (shared any))))))
+  (type (;1;) (func (param (ref null $a) i32 (ref null (shared any)))))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z (ref null (shared any)))
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.add acq_rel $a
+    array.atomic.set seq_cst $a
   )
-  (export "array-atomic-rmw.add-i32-acq_rel" (func 0))
+  (export "array-atomic-set-anyref-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/37.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/37.print
index 3be7d18d..941e3f0d 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/37.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/37.print
@@ -1,11 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut i64))))
-  (type (;1;) (func (param (ref null $a) i32 i64) (result i64)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (result i64)
+  (type $a (;0;) (shared(array (mut i8))))
+  (type (;1;) (func (param (ref null $a) i32 i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32)
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.add acq_rel $a
+    array.atomic.set acq_rel $a
   )
-  (export "array-atomic-rmw.add-i64-acq_rel" (func 0))
+  (export "array-atomic-set-i8-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/38.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/38.print
index 36af9d86..4e3d7c91 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/38.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/38.print
@@ -1,11 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut i32))))
-  (type (;1;) (func (param (ref null $a) i32 i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (result i32)
+  (type $a (;0;) (shared(array (mut i16))))
+  (type (;1;) (func (param (ref null $a) i32 i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32)
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.sub seq_cst $a
+    array.atomic.set acq_rel $a
   )
-  (export "array-atomic-rmw.sub-i32-seq_cst" (func 0))
+  (export "array-atomic-set-i16-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/39.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/39.print
index 5bb94f29..17aec3ab 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/39.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/39.print
@@ -1,11 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut i64))))
-  (type (;1;) (func (param (ref null $a) i32 i64) (result i64)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (result i64)
+  (type $a (;0;) (shared(array (mut i32))))
+  (type (;1;) (func (param (ref null $a) i32 i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32)
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.sub seq_cst $a
+    array.atomic.set acq_rel $a
   )
-  (export "array-atomic-rmw.sub-i64-seq_cst" (func 0))
+  (export "array-atomic-set-i32-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/40.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/40.print
index 0b4badbb..43139589 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/40.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/40.print
@@ -1,11 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut i32))))
-  (type (;1;) (func (param (ref null $a) i32 i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (result i32)
+  (type $a (;0;) (shared(array (mut i64))))
+  (type (;1;) (func (param (ref null $a) i32 i64)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64)
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.sub acq_rel $a
+    array.atomic.set acq_rel $a
   )
-  (export "array-atomic-rmw.sub-i32-acq_rel" (func 0))
+  (export "array-atomic-set-i64-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/41.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/41.print
index ba017726..ed1acbaf 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/41.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/41.print
@@ -1,11 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut i64))))
-  (type (;1;) (func (param (ref null $a) i32 i64) (result i64)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (result i64)
+  (type $a (;0;) (shared(array (mut (ref null (shared any))))))
+  (type (;1;) (func (param (ref null $a) i32 (ref null (shared any)))))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z (ref null (shared any)))
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.sub acq_rel $a
+    array.atomic.set acq_rel $a
   )
-  (export "array-atomic-rmw.sub-i64-acq_rel" (func 0))
+  (export "array-atomic-set-anyref-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/42.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/42.print
index 5c610307..d230670c 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/42.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/42.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.and seq_cst $a
+    array.atomic.rmw.add seq_cst $a
   )
-  (export "array-atomic-rmw.and-i32-seq_cst" (func 0))
+  (export "array-atomic-rmw.add-i32-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/43.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/43.print
index 2edfd317..28ea1094 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/43.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/43.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.and seq_cst $a
+    array.atomic.rmw.add seq_cst $a
   )
-  (export "array-atomic-rmw.and-i64-seq_cst" (func 0))
+  (export "array-atomic-rmw.add-i64-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/44.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/44.print
index 9a6e89fc..8cc27f27 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/44.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/44.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.and acq_rel $a
+    array.atomic.rmw.add acq_rel $a
   )
-  (export "array-atomic-rmw.and-i32-acq_rel" (func 0))
+  (export "array-atomic-rmw.add-i32-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/45.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/45.print
index f82346cd..3be7d18d 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/45.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/45.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.and acq_rel $a
+    array.atomic.rmw.add acq_rel $a
   )
-  (export "array-atomic-rmw.and-i64-acq_rel" (func 0))
+  (export "array-atomic-rmw.add-i64-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/46.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/46.print
index 59adfe73..36af9d86 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/46.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/46.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.or seq_cst $a
+    array.atomic.rmw.sub seq_cst $a
   )
-  (export "array-atomic-rmw.or-i32-seq_cst" (func 0))
+  (export "array-atomic-rmw.sub-i32-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/47.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/47.print
index 13dd1118..5bb94f29 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/47.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/47.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.or seq_cst $a
+    array.atomic.rmw.sub seq_cst $a
   )
-  (export "array-atomic-rmw.or-i64-seq_cst" (func 0))
+  (export "array-atomic-rmw.sub-i64-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/48.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/48.print
index ffca25c4..0b4badbb 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/48.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/48.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.or acq_rel $a
+    array.atomic.rmw.sub acq_rel $a
   )
-  (export "array-atomic-rmw.or-i32-acq_rel" (func 0))
+  (export "array-atomic-rmw.sub-i32-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/49.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/49.print
index 94fbc49c..ba017726 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/49.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/49.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.or acq_rel $a
+    array.atomic.rmw.sub acq_rel $a
   )
-  (export "array-atomic-rmw.or-i64-acq_rel" (func 0))
+  (export "array-atomic-rmw.sub-i64-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/50.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/50.print
index 0e6016a7..5c610307 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/50.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/50.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.xor seq_cst $a
+    array.atomic.rmw.and seq_cst $a
   )
-  (export "array-atomic-rmw.xor-i32-seq_cst" (func 0))
+  (export "array-atomic-rmw.and-i32-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/51.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/51.print
index 446233a0..2edfd317 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/51.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/51.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.xor seq_cst $a
+    array.atomic.rmw.and seq_cst $a
   )
-  (export "array-atomic-rmw.xor-i64-seq_cst" (func 0))
+  (export "array-atomic-rmw.and-i64-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/52.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/52.print
index 78670261..9a6e89fc 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/52.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/52.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.xor acq_rel $a
+    array.atomic.rmw.and acq_rel $a
   )
-  (export "array-atomic-rmw.xor-i32-acq_rel" (func 0))
+  (export "array-atomic-rmw.and-i32-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/53.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/53.print
index 1e8eb5b9..f82346cd 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/53.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/53.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.xor acq_rel $a
+    array.atomic.rmw.and acq_rel $a
   )
-  (export "array-atomic-rmw.xor-i64-acq_rel" (func 0))
+  (export "array-atomic-rmw.and-i64-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/54.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/54.print
index 71e2c7a8..59adfe73 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/54.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/54.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.xchg seq_cst $a
+    array.atomic.rmw.or seq_cst $a
   )
-  (export "array-atomic-rmw.xchg-i32-seq_cst" (func 0))
+  (export "array-atomic-rmw.or-i32-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/55.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/55.print
index 1770c968..13dd1118 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/55.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/55.print
@@ -5,7 +5,7 @@
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.xchg seq_cst $a
+    array.atomic.rmw.or seq_cst $a
   )
-  (export "array-atomic-rmw.xchg-i64-seq_cst" (func 0))
+  (export "array-atomic-rmw.or-i64-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/56.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/56.print
index 6ca3ea80..ffca25c4 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/56.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/56.print
@@ -1,11 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut (ref null (shared any))))))
-  (type (;1;) (func (param (ref null $a) i32 (ref null (shared any))) (result (ref null (shared any)))))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z (ref null (shared any))) (result (ref null (shared any)))
+  (type $a (;0;) (shared(array (mut i32))))
+  (type (;1;) (func (param (ref null $a) i32 i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (result i32)
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.xchg seq_cst $a
+    array.atomic.rmw.or acq_rel $a
   )
-  (export "array-atomic-rmw.xchg-anyref-seq_cst" (func 0))
+  (export "array-atomic-rmw.or-i32-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/57.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/57.print
index 2a03171e..94fbc49c 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/57.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/57.print
@@ -1,11 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut i32))))
-  (type (;1;) (func (param (ref null $a) i32 i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (result i32)
+  (type $a (;0;) (shared(array (mut i64))))
+  (type (;1;) (func (param (ref null $a) i32 i64) (result i64)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (result i64)
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.xchg acq_rel $a
+    array.atomic.rmw.or acq_rel $a
   )
-  (export "array-atomic-rmw.xchg-i32-acq_rel" (func 0))
+  (export "array-atomic-rmw.or-i64-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/58.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/58.print
index 61852120..0e6016a7 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/58.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/58.print
@@ -1,11 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut i64))))
-  (type (;1;) (func (param (ref null $a) i32 i64) (result i64)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (result i64)
+  (type $a (;0;) (shared(array (mut i32))))
+  (type (;1;) (func (param (ref null $a) i32 i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (result i32)
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.xchg acq_rel $a
+    array.atomic.rmw.xor seq_cst $a
   )
-  (export "array-atomic-rmw.xchg-i64-acq_rel" (func 0))
+  (export "array-atomic-rmw.xor-i32-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/59.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/59.print
index 2670aba6..446233a0 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/59.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/59.print
@@ -1,11 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut (ref null (shared any))))))
-  (type (;1;) (func (param (ref null $a) i32 (ref null (shared any))) (result (ref null (shared any)))))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z (ref null (shared any))) (result (ref null (shared any)))
+  (type $a (;0;) (shared(array (mut i64))))
+  (type (;1;) (func (param (ref null $a) i32 i64) (result i64)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (result i64)
     local.get $x
     local.get $y
     local.get $z
-    array.atomic.rmw.xchg acq_rel $a
+    array.atomic.rmw.xor seq_cst $a
   )
-  (export "array-atomic-rmw.xchg-anyref-acq_rel" (func 0))
+  (export "array-atomic-rmw.xor-i64-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/60.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/60.print
index 9b4ed0ec..78670261 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/60.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/60.print
@@ -1,12 +1,11 @@
 (module
   (type $a (;0;) (shared(array (mut i32))))
-  (type (;1;) (func (param (ref null $a) i32 i32 i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (param $A i32) (result i32)
+  (type (;1;) (func (param (ref null $a) i32 i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (result i32)
     local.get $x
     local.get $y
     local.get $z
-    local.get $A
-    array.atomic.rmw.cmpxchg seq_cst $a
+    array.atomic.rmw.xor acq_rel $a
   )
-  (export "array-atomic-rmw.cmpxchg-i32-seq_cst" (func 0))
+  (export "array-atomic-rmw.xor-i32-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/61.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/61.print
index f485f7a7..1e8eb5b9 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/61.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/61.print
@@ -1,12 +1,11 @@
 (module
   (type $a (;0;) (shared(array (mut i64))))
-  (type (;1;) (func (param (ref null $a) i32 i64 i64) (result i64)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (param $A i64) (result i64)
+  (type (;1;) (func (param (ref null $a) i32 i64) (result i64)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (result i64)
     local.get $x
     local.get $y
     local.get $z
-    local.get $A
-    array.atomic.rmw.cmpxchg seq_cst $a
+    array.atomic.rmw.xor acq_rel $a
   )
-  (export "array-atomic-rmw.cmpxchg-i64-seq_cst" (func 0))
+  (export "array-atomic-rmw.xor-i64-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/62.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/62.print
index c9be7ed8..71e2c7a8 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/62.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/62.print
@@ -1,12 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut (ref null (shared eq))))))
-  (type (;1;) (func (param (ref null $a) i32 (ref null (shared eq)) (ref null (shared eq))) (result (ref null (shared eq)))))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z (ref null (shared eq))) (param $A (ref null (shared eq))) (result (ref null (shared eq)))
+  (type $a (;0;) (shared(array (mut i32))))
+  (type (;1;) (func (param (ref null $a) i32 i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (result i32)
     local.get $x
     local.get $y
     local.get $z
-    local.get $A
-    array.atomic.rmw.cmpxchg seq_cst $a
+    array.atomic.rmw.xchg seq_cst $a
   )
-  (export "array-atomic-rmw.cmpxchg-eqref-seq_cst" (func 0))
+  (export "array-atomic-rmw.xchg-i32-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/63.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/63.print
index 15e7ca30..1770c968 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/63.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/63.print
@@ -1,12 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut i32))))
-  (type (;1;) (func (param (ref null $a) i32 i32 i32) (result i32)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (param $A i32) (result i32)
+  (type $a (;0;) (shared(array (mut i64))))
+  (type (;1;) (func (param (ref null $a) i32 i64) (result i64)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (result i64)
     local.get $x
     local.get $y
     local.get $z
-    local.get $A
-    array.atomic.rmw.cmpxchg acq_rel $a
+    array.atomic.rmw.xchg seq_cst $a
   )
-  (export "array-atomic-rmw.cmpxchg-i32-acq_rel" (func 0))
+  (export "array-atomic-rmw.xchg-i64-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/64.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/64.print
index 7bce20ed..6ca3ea80 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/64.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/64.print
@@ -1,12 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut i64))))
-  (type (;1;) (func (param (ref null $a) i32 i64 i64) (result i64)))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (param $A i64) (result i64)
+  (type $a (;0;) (shared(array (mut (ref null (shared any))))))
+  (type (;1;) (func (param (ref null $a) i32 (ref null (shared any))) (result (ref null (shared any)))))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z (ref null (shared any))) (result (ref null (shared any)))
     local.get $x
     local.get $y
     local.get $z
-    local.get $A
-    array.atomic.rmw.cmpxchg acq_rel $a
+    array.atomic.rmw.xchg seq_cst $a
   )
-  (export "array-atomic-rmw.cmpxchg-i64-acq_rel" (func 0))
+  (export "array-atomic-rmw.xchg-anyref-seq_cst" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/65.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/65.print
index d6118598..2a03171e 100644
--- a/tests/snapshots/local/shared-everything-threads/arrays.wast/65.print
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/65.print
@@ -1,12 +1,11 @@
 (module
-  (type $a (;0;) (shared(array (mut (ref null (shared eq))))))
-  (type (;1;) (func (param (ref null $a) i32 (ref null (shared eq)) (ref null (shared eq))) (result (ref null (shared eq)))))
-  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z (ref null (shared eq))) (param $A (ref null (shared eq))) (result (ref null (shared eq)))
+  (type $a (;0;) (shared(array (mut i32))))
+  (type (;1;) (func (param (ref null $a) i32 i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (result i32)
     local.get $x
     local.get $y
     local.get $z
-    local.get $A
-    array.atomic.rmw.cmpxchg acq_rel $a
+    array.atomic.rmw.xchg acq_rel $a
   )
-  (export "array-atomic-rmw.cmpxchg-eqref-acq_rel" (func 0))
+  (export "array-atomic-rmw.xchg-i32-acq_rel" (func 0))
 )
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/66.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/66.print
new file mode 100644
index 00000000..61852120
--- /dev/null
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/66.print
@@ -0,0 +1,11 @@
+(module
+  (type $a (;0;) (shared(array (mut i64))))
+  (type (;1;) (func (param (ref null $a) i32 i64) (result i64)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (result i64)
+    local.get $x
+    local.get $y
+    local.get $z
+    array.atomic.rmw.xchg acq_rel $a
+  )
+  (export "array-atomic-rmw.xchg-i64-acq_rel" (func 0))
+)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/67.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/67.print
new file mode 100644
index 00000000..2670aba6
--- /dev/null
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/67.print
@@ -0,0 +1,11 @@
+(module
+  (type $a (;0;) (shared(array (mut (ref null (shared any))))))
+  (type (;1;) (func (param (ref null $a) i32 (ref null (shared any))) (result (ref null (shared any)))))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z (ref null (shared any))) (result (ref null (shared any)))
+    local.get $x
+    local.get $y
+    local.get $z
+    array.atomic.rmw.xchg acq_rel $a
+  )
+  (export "array-atomic-rmw.xchg-anyref-acq_rel" (func 0))
+)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/68.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/68.print
new file mode 100644
index 00000000..9b4ed0ec
--- /dev/null
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/68.print
@@ -0,0 +1,12 @@
+(module
+  (type $a (;0;) (shared(array (mut i32))))
+  (type (;1;) (func (param (ref null $a) i32 i32 i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (param $A i32) (result i32)
+    local.get $x
+    local.get $y
+    local.get $z
+    local.get $A
+    array.atomic.rmw.cmpxchg seq_cst $a
+  )
+  (export "array-atomic-rmw.cmpxchg-i32-seq_cst" (func 0))
+)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/69.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/69.print
new file mode 100644
index 00000000..f485f7a7
--- /dev/null
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/69.print
@@ -0,0 +1,12 @@
+(module
+  (type $a (;0;) (shared(array (mut i64))))
+  (type (;1;) (func (param (ref null $a) i32 i64 i64) (result i64)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (param $A i64) (result i64)
+    local.get $x
+    local.get $y
+    local.get $z
+    local.get $A
+    array.atomic.rmw.cmpxchg seq_cst $a
+  )
+  (export "array-atomic-rmw.cmpxchg-i64-seq_cst" (func 0))
+)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/70.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/70.print
new file mode 100644
index 00000000..c9be7ed8
--- /dev/null
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/70.print
@@ -0,0 +1,12 @@
+(module
+  (type $a (;0;) (shared(array (mut (ref null (shared eq))))))
+  (type (;1;) (func (param (ref null $a) i32 (ref null (shared eq)) (ref null (shared eq))) (result (ref null (shared eq)))))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z (ref null (shared eq))) (param $A (ref null (shared eq))) (result (ref null (shared eq)))
+    local.get $x
+    local.get $y
+    local.get $z
+    local.get $A
+    array.atomic.rmw.cmpxchg seq_cst $a
+  )
+  (export "array-atomic-rmw.cmpxchg-eqref-seq_cst" (func 0))
+)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/71.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/71.print
new file mode 100644
index 00000000..15e7ca30
--- /dev/null
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/71.print
@@ -0,0 +1,12 @@
+(module
+  (type $a (;0;) (shared(array (mut i32))))
+  (type (;1;) (func (param (ref null $a) i32 i32 i32) (result i32)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i32) (param $A i32) (result i32)
+    local.get $x
+    local.get $y
+    local.get $z
+    local.get $A
+    array.atomic.rmw.cmpxchg acq_rel $a
+  )
+  (export "array-atomic-rmw.cmpxchg-i32-acq_rel" (func 0))
+)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/72.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/72.print
new file mode 100644
index 00000000..7bce20ed
--- /dev/null
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/72.print
@@ -0,0 +1,12 @@
+(module
+  (type $a (;0;) (shared(array (mut i64))))
+  (type (;1;) (func (param (ref null $a) i32 i64 i64) (result i64)))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z i64) (param $A i64) (result i64)
+    local.get $x
+    local.get $y
+    local.get $z
+    local.get $A
+    array.atomic.rmw.cmpxchg acq_rel $a
+  )
+  (export "array-atomic-rmw.cmpxchg-i64-acq_rel" (func 0))
+)
diff --git a/tests/snapshots/local/shared-everything-threads/arrays.wast/73.print b/tests/snapshots/local/shared-everything-threads/arrays.wast/73.print
new file mode 100644
index 00000000..d6118598
--- /dev/null
+++ b/tests/snapshots/local/shared-everything-threads/arrays.wast/73.print
@@ -0,0 +1,12 @@
+(module
+  (type $a (;0;) (shared(array (mut (ref null (shared eq))))))
+  (type (;1;) (func (param (ref null $a) i32 (ref null (shared eq)) (ref null (shared eq))) (result (ref null (shared eq)))))
+  (func (;0;) (type 1) (param $x (ref null $a)) (param $y i32) (param $z (ref null (shared eq))) (param $A (ref null (shared eq))) (result (ref null (shared eq)))
+    local.get $x
+    local.get $y
+    local.get $z
+    local.get $A
+    array.atomic.rmw.cmpxchg acq_rel $a
+  )
+  (export "array-atomic-rmw.cmpxchg-eqref-acq_rel" (func 0))
+)
diff --git a/tests/snapshots/local/shared-everything-threads/structs.wast.json b/tests/snapshots/local/shared-everything-threads/structs.wast.json
index 2cc841de..0a68ac7d 100644
--- a/tests/snapshots/local/shared-everything-threads/structs.wast.json
+++ b/tests/snapshots/local/shared-everything-threads/structs.wast.json
@@ -62,98 +62,154 @@
       "filename": "structs.9.wasm"
     },
     {
-      "type": "module",
-      "line": 103,
-      "filename": "structs.10.wasm"
+      "type": "assert_invalid",
+      "line": 104,
+      "filename": "structs.10.wasm",
+      "text": "field is immutable",
+      "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 330,
+      "line": 113,
       "filename": "structs.11.wasm",
-      "text": "non-packed storage type",
+      "text": "field is immutable",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 339,
+      "line": 122,
       "filename": "structs.12.wasm",
-      "text": "non-packed storage types",
+      "text": "field is immutable",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 348,
+      "line": 131,
       "filename": "structs.13.wasm",
-      "text": "non-packed storage types",
+      "text": "field is immutable",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 357,
+      "line": 140,
       "filename": "structs.14.wasm",
-      "text": "non-packed storage types",
+      "text": "field is immutable",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 366,
+      "line": 149,
       "filename": "structs.15.wasm",
-      "text": "non-packed storage types",
+      "text": "field is immutable",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 375,
+      "line": 158,
       "filename": "structs.16.wasm",
-      "text": "invalid type",
+      "text": "field is immutable",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 385,
+      "line": 167,
       "filename": "structs.17.wasm",
+      "text": "field is immutable",
+      "module_type": "binary"
+    },
+    {
+      "type": "module",
+      "line": 177,
+      "filename": "structs.18.wasm"
+    },
+    {
+      "type": "assert_invalid",
+      "line": 404,
+      "filename": "structs.19.wasm",
+      "text": "non-packed storage type",
+      "module_type": "binary"
+    },
+    {
+      "type": "assert_invalid",
+      "line": 413,
+      "filename": "structs.20.wasm",
+      "text": "non-packed storage types",
+      "module_type": "binary"
+    },
+    {
+      "type": "assert_invalid",
+      "line": 422,
+      "filename": "structs.21.wasm",
+      "text": "non-packed storage types",
+      "module_type": "binary"
+    },
+    {
+      "type": "assert_invalid",
+      "line": 431,
+      "filename": "structs.22.wasm",
+      "text": "non-packed storage types",
+      "module_type": "binary"
+    },
+    {
+      "type": "assert_invalid",
+      "line": 440,
+      "filename": "structs.23.wasm",
+      "text": "non-packed storage types",
+      "module_type": "binary"
+    },
+    {
+      "type": "assert_invalid",
+      "line": 449,
+      "filename": "structs.24.wasm",
       "text": "invalid type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 395,
-      "filename": "structs.18.wasm",
+      "line": 459,
+      "filename": "structs.25.wasm",
       "text": "invalid type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 405,
-      "filename": "structs.19.wasm",
+      "line": 469,
+      "filename": "structs.26.wasm",
       "text": "invalid type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 415,
-      "filename": "structs.20.wasm",
+      "line": 479,
+      "filename": "structs.27.wasm",
       "text": "invalid type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 425,
-      "filename": "structs.21.wasm",
+      "line": 489,
+      "filename": "structs.28.wasm",
       "text": "invalid type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 435,
-      "filename": "structs.22.wasm",
+      "line": 499,
+      "filename": "structs.29.wasm",
       "text": "invalid type",
       "module_type": "binary"
     },
     {
       "type": "assert_invalid",
-      "line": 446,
-      "filename": "structs.23.wasm",
+      "line": 509,
+      "filename": "structs.30.wasm",
+      "text": "invalid type",
+      "module_type": "binary"
+    },
+    {
+      "type": "assert_invalid",
+      "line": 520,
+      "filename": "structs.31.wasm",
       "text": "invalid type",
       "module_type": "binary"
     }