|
[turbofan] Optimize certain chains of Branch into a Switch.
This adds a new ControlFlowOptimizer that - for now - recognizes chains
of Branches generated by the SwitchBuilder for a subset of javascript
switches into Switch nodes. Those Switch nodes are then lowered to
either table or lookup switches.
Also rename Case to IfValue (and introduce IfDefault) for consistency.
BUG= v8:3872
LOG=n
Committed: https://crrev.com/acd9c46ca7a0ada723d717f2545fd484c824eaa2
Cr-Commit-Position: refs/heads/master@{#26691}
Total comments: 12
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+1122 lines, -168 lines) |
Patch |
|
M |
BUILD.gn
|
View
|
1
|
1 chunk |
+2 lines, -0 lines |
0 comments
|
Download
|
|
M |
src/compiler/arm/code-generator-arm.cc
|
View
|
1
|
3 chunks |
+31 lines, -14 lines |
0 comments
|
Download
|
|
M |
src/compiler/arm/instruction-selector-arm.cc
|
View
|
|
1 chunk |
+61 lines, -0 lines |
0 comments
|
Download
|
|
M |
src/compiler/arm64/code-generator-arm64.cc
|
View
|
1
|
3 chunks |
+37 lines, -18 lines |
0 comments
|
Download
|
|
M |
src/compiler/arm64/instruction-selector-arm64.cc
|
View
|
|
1 chunk |
+61 lines, -0 lines |
0 comments
|
Download
|
|
M |
src/compiler/code-generator.h
|
View
|
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
|
M |
src/compiler/common-operator.h
|
View
|
1
2
|
2 chunks |
+2 lines, -4 lines |
0 comments
|
Download
|
|
M |
src/compiler/common-operator.cc
|
View
|
1
2
|
4 chunks |
+8 lines, -13 lines |
0 comments
|
Download
|
|
A |
src/compiler/control-flow-optimizer.h
|
View
|
|
1 chunk |
+52 lines, -0 lines |
0 comments
|
Download
|
|
A |
src/compiler/control-flow-optimizer.cc
|
View
|
1
2
3
4
5
|
1 chunk |
+147 lines, -0 lines |
0 comments
|
Download
|
|
M |
src/compiler/ia32/code-generator-ia32.cc
|
View
|
1
|
3 chunks |
+31 lines, -14 lines |
0 comments
|
Download
|
|
M |
src/compiler/ia32/instruction-selector-ia32.cc
|
View
|
|
1 chunk |
+61 lines, -0 lines |
0 comments
|
Download
|
|
M |
src/compiler/instruction-codes.h
|
View
|
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
|
M |
src/compiler/instruction-selector.h
|
View
|
|
1 chunk |
+3 lines, -1 line |
0 comments
|
Download
|
|
M |
src/compiler/instruction-selector.cc
|
View
|
1
2
|
5 chunks |
+30 lines, -24 lines |
0 comments
|
Download
|
|
M |
src/compiler/opcodes.h
|
View
|
1
2
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
|
M |
src/compiler/operator.h
|
View
|
|
2 chunks |
+4 lines, -1 line |
0 comments
|
Download
|
|
M |
src/compiler/operator.cc
|
View
|
|
2 chunks |
+5 lines, -1 line |
0 comments
|
Download
|
|
M |
src/compiler/operator-properties.cc
|
View
|
1
2
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
|
M |
src/compiler/pipeline.cc
|
View
|
1
2
3
4
5
|
3 chunks |
+17 lines, -0 lines |
0 comments
|
Download
|
|
M |
src/compiler/raw-machine-assembler.h
|
View
|
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
|
M |
src/compiler/raw-machine-assembler.cc
|
View
|
1
2
|
1 chunk |
+17 lines, -6 lines |
0 comments
|
Download
|
|
M |
src/compiler/schedule.h
|
View
|
1
2
3
4
5
|
1 chunk |
+3 lines, -0 lines |
0 comments
|
Download
|
|
M |
src/compiler/scheduler.cc
|
View
|
1
2
3
4
5
|
2 chunks |
+10 lines, -4 lines |
0 comments
|
Download
|
|
M |
src/compiler/simplified-lowering.cc
|
View
|
1
2
3
4
|
1 chunk |
+4 lines, -8 lines |
0 comments
|
Download
|
|
M |
src/compiler/verifier.cc
|
View
|
1
2
|
2 chunks |
+29 lines, -10 lines |
0 comments
|
Download
|
|
M |
src/compiler/x64/code-generator-x64.cc
|
View
|
1
|
3 chunks |
+32 lines, -15 lines |
0 comments
|
Download
|
|
M |
src/compiler/x64/instruction-selector-x64.cc
|
View
|
|
2 chunks |
+66 lines, -0 lines |
0 comments
|
Download
|
|
M |
src/flag-definitions.h
|
View
|
1
2
3
4
5
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
|
M |
test/cctest/compiler/test-run-machops.cc
|
View
|
|
2 chunks |
+71 lines, -12 lines |
0 comments
|
Download
|
|
A |
test/mjsunit/asm/switch.js
|
View
|
|
1 chunk |
+120 lines, -0 lines |
0 comments
|
Download
|
|
M |
test/unittests/compiler/common-operator-unittest.cc
|
View
|
1
2
|
3 chunks |
+20 lines, -6 lines |
0 comments
|
Download
|
|
A |
test/unittests/compiler/control-flow-optimizer-unittest.cc
|
View
|
1
2
|
1 chunk |
+70 lines, -0 lines |
0 comments
|
Download
|
|
M |
test/unittests/compiler/graph-unittest.h
|
View
|
1
2
|
1 chunk |
+2 lines, -0 lines |
0 comments
|
Download
|
|
M |
test/unittests/compiler/node-test-utils.h
|
View
|
1
2
|
2 chunks |
+8 lines, -0 lines |
0 comments
|
Download
|
|
M |
test/unittests/compiler/node-test-utils.cc
|
View
|
1
2
|
3 chunks |
+88 lines, -0 lines |
0 comments
|
Download
|
|
M |
test/unittests/compiler/scheduler-unittest.cc
|
View
|
1
2
|
2 chunks |
+16 lines, -12 lines |
0 comments
|
Download
|
|
M |
test/unittests/unittests.gyp
|
View
|
1
2
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
|
M |
tools/gyp/v8.gyp
|
View
|
|
1 chunk |
+2 lines, -0 lines |
0 comments
|
Download
|
Total messages: 10 (2 generated)
|