Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1469)

Unified Diff: src/compiler/simplified-lowering.cc

Issue 2703113003: [compiler] Cleanup: Move DCHECK into ChangeToPureOp. (Closed)
Patch Set: Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/simplified-lowering.cc
diff --git a/src/compiler/simplified-lowering.cc b/src/compiler/simplified-lowering.cc
index e6158c0adefd625b69d8d19f6f696d5a06ba8766..57c6781f8ce51107d3254f1cf830b4798a8d33d4 100644
--- a/src/compiler/simplified-lowering.cc
+++ b/src/compiler/simplified-lowering.cc
@@ -170,6 +170,7 @@ void ReplaceEffectControlUses(Node* node, Node* effect, Node* control) {
}
void ChangeToPureOp(Node* node, const Operator* new_op) {
+ DCHECK(new_op->HasProperty(Operator::kPure));
if (node->op()->EffectInputCount() > 0) {
DCHECK_LT(0, node->op()->ControlInputCount());
// Disconnect the node from effect and control chains.
@@ -3382,12 +3383,11 @@ void SimplifiedLowering::DoMin(Node* node, Operator const* op,
void SimplifiedLowering::DoShift(Node* node, Operator const* op,
Type* rhs_type) {
- Node* const rhs = NodeProperties::GetValueInput(node, 1);
if (!rhs_type->Is(type_cache_.kZeroToThirtyOne)) {
+ Node* const rhs = NodeProperties::GetValueInput(node, 1);
node->ReplaceInput(1, graph()->NewNode(machine()->Word32And(), rhs,
jsgraph()->Int32Constant(0x1f)));
}
- DCHECK(op->HasProperty(Operator::kPure));
ChangeToPureOp(node, op);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698