diff options
author | Thomas Lively <tlively@google.com> | 2022-11-17 17:07:21 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-17 17:07:21 -0800 |
commit | 2218b63902cac62e02d9672034fc8d8415945973 (patch) | |
tree | e8d5f4d665cfc40160f32973e62b50f9ad8931ef /test/lit/exec | |
parent | 977d653f9801b3eedc7dd667e4068573e73d2bb5 (diff) | |
download | binaryen-2218b63902cac62e02d9672034fc8d8415945973.tar.gz binaryen-2218b63902cac62e02d9672034fc8d8415945973.tar.bz2 binaryen-2218b63902cac62e02d9672034fc8d8415945973.zip |
Do not compare reference values across executions (#5276)
Since we optimize assuming a closed world, optimizations can change the types
and structure of GC data even in externally-visible ways. Because differences
are expected, the fuzzer already did not compare reference-typed values from
before and after optimizations when running with nominal typing. Update it to
not compare these values under any type system.
Diffstat (limited to 'test/lit/exec')
-rw-r--r-- | test/lit/exec/no-compare-refs.wast | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/test/lit/exec/no-compare-refs.wast b/test/lit/exec/no-compare-refs.wast new file mode 100644 index 000000000..bb9766a31 --- /dev/null +++ b/test/lit/exec/no-compare-refs.wast @@ -0,0 +1,22 @@ +;; NOTE: Assertions have been generated by update_lit_checks.py --output=fuzz-exec and should not be edited. + +;; RUN: wasm-opt %s --hybrid -all --signature-pruning --fuzz-exec -q -o /dev/null 2>&1 | filecheck %s + +(module + (type $f (func (param i32))) + + (func $no-use-param (type $f) (param i32) + (unreachable) + ) + + ;; The type of the reference this function returns will change as a result of + ;; signature pruning. The fuzzer should not complain about this. + ;; CHECK: [fuzz-exec] calling return-ref + ;; CHECK-NEXT: [fuzz-exec] note result: return-ref => funcref + (func "return-ref" (result funcref) + (ref.func $no-use-param) + ) +) +;; CHECK: [fuzz-exec] calling return-ref +;; CHECK-NEXT: [fuzz-exec] note result: return-ref => funcref +;; CHECK-NEXT: [fuzz-exec] comparing return-ref |