-
Notifications
You must be signed in to change notification settings - Fork 786
[OptimizeForJS] Avoid 64-bit integer storage if it's possible #4083
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
Open
MaxGraey
wants to merge
6
commits into
WebAssembly:main
Choose a base branch
from
MaxGraey:optjs-store-i64-consts
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Fuzzer found this edge case: !
Wasm2JS (before/after) comparison error, expected to have '[fuzz-exec] calling func_48
[fuzz-exec] note result: func_48 => -6996475.0
[fuzz-exec] calling func_48_invoker
[LoggingExternalInterface logging 1719783932]
[fuzz-exec] calling func_49_invoker
[LoggingExternalInterface logging 1719783932]' == '[fuzz-exec] calling func_48
[fuzz-exec] note result: func_48 => -6996475.0
[fuzz-exec] calling func_48_invoker
[LoggingExternalInterface logging 1359052027]
[fuzz-exec] calling func_49_invoker
[LoggingExternalInterface logging 1359052027]', diff:
--- expected
+++ actual
@@ -1,6 +1,6 @@
[fuzz-exec] calling func_48
[fuzz-exec] note result: func_48 => -6996475.0
[fuzz-exec] calling func_48_invoker
-[LoggingExternalInterface logging 1719783932]
+[LoggingExternalInterface logging 1359052027]
[fuzz-exec] calling func_49_invoker
-[LoggingExternalInterface logging 1719783932]
+[LoggingExternalInterface logging 1359052027]
================================================================================ seed: And reduction example looks like this: (module
(type $i32_=>_none (func (param i32)))
(type $none_=>_none (func))
(type $none_=>_i32 (func (result i32)))
(import "fuzzing-support" "log-i32" (func $fimport$0 (param i32)))
(memory $0 16 17)
(export "func_46" (func $291))
(export "func_49_invoker" (func $74))
(func $74
(if
(i64.eqz
(i64.load16_u align=1
(i32.const 4)
)
)
(call $fimport$0
(i32.const -59)
)
)
)
(func $291 (result i32)
(i64.store
(i32.const 4)
(i64.const 126)
)
(i32.const 0)
)
) However |
it seems we should skip subnormals as well sue to non-determinism on some platforms |
Fuzzed: |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
it will lower to one
HEAP64[ptr] = C'
instead two writes toHEAP32
Fix: emscripten-core/emscripten#13365