Jakob Kummerow
828342dd7f
[ubsan][compiler] Avoid out-of-range casts to IrOpcode::Value
...
An enum-typed value should never have a value outside of that enum's
range.
This patch enforces that in Debug mode, while in Release mode keeping
the previous behavior of returning "UnknownOpcode" as the mnemonic for
illegal IrOpcode values to ease debugging.
Bug: v8:3770
Change-Id: I83a5a356f1fb7a266921940a4495f1d39a1823cd
Reviewed-on: https://chromium-review.googlesource.com/c/1436221
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59102}
2019-01-25 20:55:25 +00:00
bmeurer
a63997599e
[unittests] Reduce compilation overhead of opcodes-unittest.cc.
...
Reduce compilation time (with clang) for opcodes-unittest.cc from
1m38s to roughly 1s by not overusing the macro expansion magic.
TBR=jarin@chromium.org
Review-Url: https://codereview.chromium.org/2331413002
Cr-Commit-Position: refs/heads/master@{#39365}
2016-09-13 05:16:18 +00:00
bmeurer
dcf193f18c
[turbofan] Strength reduction for inline comparisons.
...
Perform strength reduction on machine operators with inline comparisons:
CMP & 1 => CMP
1 & CMP => CMP
CMP << 31 >> 31 => CMP
Also strength reduce the following constructs:
x + (0 - y) => x - y
(0 - y) + x => x - y
R=dcarney@chromium.org
Review URL: https://codereview.chromium.org/951903003
Cr-Commit-Position: refs/heads/master@{#26817}
2015-02-24 12:26:29 +00:00
Ben L. Titzer
396381f944
[turbofan] Rename IrOpcode predicate IsLeafOpcode to IsConstantOpcode.
...
R=mstarzinger@chromium.org
BUG=
Review URL: https://codereview.chromium.org/863513002
Cr-Commit-Position: refs/heads/master@{#26141}
2015-01-19 15:35:16 +00:00
bmeurer
dd6ce12645
[turbofan] Turn IrOpcode::IsXXX() into range checks.
...
TEST=unittests
R=dcarney@chromium.org
Review URL: https://codereview.chromium.org/807573004
Cr-Commit-Position: refs/heads/master@{#26079}
2015-01-15 15:07:39 +00:00
bmeurer
b6c7e11c10
[turbofan] Fix typo in IrOpcode::Mnemonic.
...
TEST=unittests
R=svenpanne@chromium.org
Review URL: https://codereview.chromium.org/843043002
Cr-Commit-Position: refs/heads/master@{#26014}
2015-01-09 14:20:03 +00:00