summaryrefslogtreecommitdiff
path: root/test/lit/validation/shared-ref-i31.wast
diff options
context:
space:
mode:
authorThomas Lively <tlively@google.com>2024-07-18 14:43:23 -0400
committerGitHub <noreply@github.com>2024-07-18 11:43:23 -0700
commitfd867a3865d079b7f9c8ec1c7fc6d02a4de28b4c (patch)
tree0a26805a992880afdbd64162d31045b6ae998a04 /test/lit/validation/shared-ref-i31.wast
parentb91966f7999175e8b03da9a7a9dcdb07e4749fb1 (diff)
downloadbinaryen-fd867a3865d079b7f9c8ec1c7fc6d02a4de28b4c.tar.gz
binaryen-fd867a3865d079b7f9c8ec1c7fc6d02a4de28b4c.tar.bz2
binaryen-fd867a3865d079b7f9c8ec1c7fc6d02a4de28b4c.zip
[threads] ref.i31_shared requires shared-everything in validation (#6767)
Diffstat (limited to 'test/lit/validation/shared-ref-i31.wast')
-rw-r--r--test/lit/validation/shared-ref-i31.wast12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/lit/validation/shared-ref-i31.wast b/test/lit/validation/shared-ref-i31.wast
new file mode 100644
index 000000000..aaab2f47f
--- /dev/null
+++ b/test/lit/validation/shared-ref-i31.wast
@@ -0,0 +1,12 @@
+;; Test that ref.i31_shared requires shared-everything threads
+
+;; RUN: not wasm-opt %s -all --disable-shared-everything 2>&1 | filecheck %s --check-prefix NO-SHARED
+;; RUN: wasm-opt %s --enable-reference-types --enable-gc --enable-shared-everything -o - -S | filecheck %s --check-prefix SHARED
+
+;; NO-SHARED: ref.i31_shared requires shared-everything [--enable-shared-everything]
+;; SHARED: (ref.i31_shared
+;; SHARED-NEXT: (i32.const 0)
+
+(module
+ (func (drop (ref.i31_shared (i32.const 0))))
+)