Skip to content

Commit b7493b6

Browse files
aartbikcommit-bot@chromium.org
authored andcommitted
[vm/inliner] Inline small int convertors.
Rationale: Always inline int convertors that don't do much more than testing and anding. For example, force inline v26 <- StaticCall:66( _toUint8@6027147<0> v4 T{Type: class 'int'?}) T{Type: class 'int'?} to v47 <- Constant(#255) .. CheckSmi:10(v4 T{Type: class 'int'?}) v45 <- BinarySmiOp:10(&, v4 T{_Smi}, v47 T{_Smi}) T{_Smi} #33205 Change-Id: I595d9a64365e16ae244480b5e27f8be23c43d164 Reviewed-on: https://dart-review.googlesource.com/58061 Commit-Queue: Aart Bik <[email protected]> Reviewed-by: Aart Bik <[email protected]> Reviewed-by: Vyacheslav Egorov <[email protected]>
1 parent 6b71414 commit b7493b6

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

runtime/vm/compiler/method_recognizer.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -434,6 +434,14 @@ namespace dart {
434434
V(::, _classRangeCheckNegative, ClassRangeCheckNegated, 0x5acdfb75) \
435435
V(::, _classRangeAssert, ClassRangeAssert, 0x6c77116e) \
436436
V(::, _classIdEqualsAssert, ClassIdEqualsAssert, 0x09e0ae72) \
437+
V(::, _toInt, ConvertMaskedInt, 0x713908fd) \
438+
V(::, _toInt8, ConvertIntToInt8, 0x7484a780) \
439+
V(::, _toUint8, ConvertIntToUint8, 0x0a15b522) \
440+
V(::, _toClampedUint8, ConvertIntToClampedUint8, 0x564b0435) \
441+
V(::, _toInt16, ConvertIntToInt16, 0x0a83fcc6) \
442+
V(::, _toUint16, ConvertIntToUint16, 0x6087d1af) \
443+
V(::, _toInt32, ConvertIntToInt32, 0x62b451b9) \
444+
V(::, _toUint32, ConvertIntToUint32, 0x17a8e085) \
437445
V(Lists, copy, ListsCopy, 0x40e974f6) \
438446
V(_HashVMBase, get:_index, LinkedHashMap_getIndex, 0x02477157) \
439447
V(_HashVMBase, set:_index, LinkedHashMap_setIndex, 0x4fc8d5e0) \

0 commit comments

Comments
 (0)