[turbofan] Thread feedback through common operator reducer
The common operator reducer was loosing feedback information when replacing DeoptimizeIf/Unless with DeoptimizeUnless/If nodes. Bug: v8:7127 Change-Id: I5d6f253ca9dfec04f4e7c8d1485f0ca668a8db95 Reviewed-on: https://chromium-review.googlesource.com/878781 Reviewed-by: Benedikt Meurer <bmeurer@chromium.org> Commit-Queue: Sigurd Schneider <sigurds@chromium.org> Cr-Commit-Position: refs/heads/master@{#50782}
This commit is contained in:
parent
d2681aa448
commit
7b0e02bc77
@ -104,8 +104,8 @@ Reduction BranchElimination::ReduceDeoptimizeConditional(Node* node) {
|
||||
ReplaceWithValue(node, dead(), effect, control);
|
||||
} else {
|
||||
control = graph()->NewNode(
|
||||
common()->Deoptimize(p.kind(), p.reason(), VectorSlotPair()),
|
||||
frame_state, effect, control);
|
||||
common()->Deoptimize(p.kind(), p.reason(), p.feedback()), frame_state,
|
||||
effect, control);
|
||||
// TODO(bmeurer): This should be on the AdvancedReducer somehow.
|
||||
NodeProperties::MergeControlToEnd(graph(), common(), control);
|
||||
Revisit(graph()->end());
|
||||
|
@ -138,10 +138,10 @@ Reduction CommonOperatorReducer::ReduceDeoptimizeConditional(Node* node) {
|
||||
if (condition->opcode() == IrOpcode::kBooleanNot) {
|
||||
NodeProperties::ReplaceValueInput(node, condition->InputAt(0), 0);
|
||||
NodeProperties::ChangeOp(
|
||||
node, condition_is_true ? common()->DeoptimizeIf(p.kind(), p.reason(),
|
||||
VectorSlotPair())
|
||||
: common()->DeoptimizeUnless(
|
||||
p.kind(), p.reason(), VectorSlotPair()));
|
||||
node,
|
||||
condition_is_true
|
||||
? common()->DeoptimizeIf(p.kind(), p.reason(), p.feedback())
|
||||
: common()->DeoptimizeUnless(p.kind(), p.reason(), p.feedback()));
|
||||
return Changed(node);
|
||||
}
|
||||
Decision const decision = DecideCondition(condition);
|
||||
@ -150,8 +150,8 @@ Reduction CommonOperatorReducer::ReduceDeoptimizeConditional(Node* node) {
|
||||
ReplaceWithValue(node, dead(), effect, control);
|
||||
} else {
|
||||
control = graph()->NewNode(
|
||||
common()->Deoptimize(p.kind(), p.reason(), VectorSlotPair()),
|
||||
frame_state, effect, control);
|
||||
common()->Deoptimize(p.kind(), p.reason(), p.feedback()), frame_state,
|
||||
effect, control);
|
||||
// TODO(bmeurer): This should be on the AdvancedReducer somehow.
|
||||
NodeProperties::MergeControlToEnd(graph(), common(), control);
|
||||
Revisit(graph()->end());
|
||||
|
Loading…
Reference in New Issue
Block a user