diff options
author | Max Graey <maxgraey@gmail.com> | 2020-09-29 22:45:08 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-09-29 12:45:08 -0700 |
commit | 781da4c206c54e92b46358c00d079ada66cef0df (patch) | |
tree | 7a89e955a6ab224c65dd8af498865477c18cfcc2 /test/passes/optimize-instructions_all-features.wast | |
parent | a629dc27bcb8022fad559ecdb2d3138e39183c6b (diff) | |
download | binaryen-781da4c206c54e92b46358c00d079ada66cef0df.tar.gz binaryen-781da4c206c54e92b46358c00d079ada66cef0df.tar.bz2 binaryen-781da4c206c54e92b46358c00d079ada66cef0df.zip |
Add also non-equal with zero simplification for boolean context (#3178)
Diffstat (limited to 'test/passes/optimize-instructions_all-features.wast')
-rw-r--r-- | test/passes/optimize-instructions_all-features.wast | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/test/passes/optimize-instructions_all-features.wast b/test/passes/optimize-instructions_all-features.wast index a89a16c1b..8c2cefb53 100644 --- a/test/passes/optimize-instructions_all-features.wast +++ b/test/passes/optimize-instructions_all-features.wast @@ -3988,7 +3988,15 @@ ) (i32.const 1) )) - ;; i64(bool(expr)) == 1 -> i64(bool(expr)) + ;; i64(bool(expr)) != 0 -> i32(bool(expr)) + (drop (i64.ne + (i64.shr_u + (local.get $y) + (i64.const 63) + ) + (i64.const 0) + )) + ;; i64(bool(expr)) == 1 -> i32(bool(expr)) (drop (i64.eq (i64.and (local.get $y) |