Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(tests): update WAT used in tests #249

Merged
merged 1 commit into from
Oct 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion crates/tests/tests/invalid/multi-value-0.wat
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
(func (export "i64.dup") (param i64) (result i64 i64)
;; With this commented out, there's only a single i64 on the stack.
;; get_local 0
get_local 0))
(local.get 0)))
6 changes: 3 additions & 3 deletions crates/tests/tests/invalid/multi-value-1.wat
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
(module
(func (export "i64.dup") (param i64) (result i64 i64)
;; Too many i64s on the stack.
get_local 0
get_local 0
get_local 0))
(local.get 0)
(local.get 0)
(local.get 0)))
6 changes: 3 additions & 3 deletions crates/tests/tests/round_trip/atomic.wat
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,17 @@
(i32.const 0)
(i32.const 1))

(atomic.notify
(memory.atomic.notify
(i32.const 0)
(i32.const 1))

(i32.atomic.wait
(memory.atomic.wait32
(i32.const 0)
(i32.const 1)
(i64.const 2)
)

(i64.atomic.wait
(memory.atomic.wait64
(i32.const 0)
(i64.const 1)
(i64.const 2)
Expand Down
6 changes: 3 additions & 3 deletions crates/tests/tests/round_trip/fac-multi-value.wat
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
(module
;; Iterative factorial without locals.
(func $pick0 (param i64) (result i64 i64)
(get_local 0) (get_local 0)
(local.get 0) (local.get 0)
)
(func $pick1 (param i64 i64) (result i64 i64 i64)
(get_local 0) (get_local 1) (get_local 0)
(local.get 0) (local.get 1) (local.get 0)
)
(func (export "fac-ssa") (param i64) (result i64)
(i64.const 1) (get_local 0)
(i64.const 1) (local.get 0)
(loop $l (param i64 i64) (result i64)
(call $pick1) (call $pick1) (i64.mul)
(call $pick1) (i64.const 1) (i64.sub)
Expand Down
2 changes: 1 addition & 1 deletion crates/tests/tests/round_trip/multi-0.wat
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
(module
(func (export "i64.dup") (param i64) (result i64 i64)
(get_local 0) (get_local 0)))
(local.get 0) (local.get 0)))

(; CHECK-ALL:
(module
Expand Down
6 changes: 3 additions & 3 deletions crates/tests/tests/valid/fac-multi-value.wat
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
(module
;; Iterative factorial without locals.
(func $pick0 (param i64) (result i64 i64)
(get_local 0) (get_local 0)
(local.get 0) (local.get 0)
)
(func $pick1 (param i64 i64) (result i64 i64 i64)
(get_local 0) (get_local 1) (get_local 0)
(local.get 0) (local.get 1) (local.get 0)
)
(func (export "fac-ssa") (param i64) (result i64)
(i64.const 1) (get_local 0)
(i64.const 1) (local.get 0)
(loop $l (param i64 i64) (result i64)
(call $pick1) (call $pick1) (i64.mul)
(call $pick1) (i64.const 1) (i64.sub)
Expand Down
Loading