DescriptionImprove precision of range analysis by allowing it to track ranges across all int typed phis.
Even when range of the integer definition is unknown we can optimistically assign full int64-range to it even though tagged integer definition can contain instance of the Bigint. This is based on the following observation: we only use ranges when working with unboxed arithmetic in the optimized code, but the widest possible unboxed arithmetic is 64-bit (mint) one and corresponding unboxing operations will deoptimize if they get Bigint as an input. This makes it safe to assume that any integer definition fits into 64-bit range *once unboxed*.
Additional small fixes:
- Fix ranges assigned to loads from Int32/Uint32 arrays on 64-bit platform - it was overly conservative;
- Add UnboxUint32 range inference to ensure that range is not lost when it passes through box-unbox pair;
- When canonicalizing Binary/Unary Integer operations ensure that we unwrap UnboxUint32(Constant(C)) -> C.
BUG=
R=fschneider@google.com
Committed: https://code.google.com/p/dart/source/detail?r=41640
Patch Set 1 #
Total comments: 3
Messages
Total messages: 4 (1 generated)
|