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

Unified Diff: test/unittests/compiler/graph-reducer-unittest.cc

Issue 1362783004: Revert of [turbofan] Checking of input counts on node creation (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 3 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
Index: test/unittests/compiler/graph-reducer-unittest.cc
diff --git a/test/unittests/compiler/graph-reducer-unittest.cc b/test/unittests/compiler/graph-reducer-unittest.cc
index 599af72983a53bc0068d9b3a4efebeac40aea24a..3ca6052af9fd0253a7a2d69a1a4a420329b35d92 100644
--- a/test/unittests/compiler/graph-reducer-unittest.cc
+++ b/test/unittests/compiler/graph-reducer-unittest.cc
@@ -290,8 +290,7 @@
TEST_F(AdvancedReducerTest, ReplaceWithValue_ValueUse) {
CommonOperatorBuilder common(zone());
Node* node = graph()->NewNode(&kMockOperator);
- Node* start = graph()->NewNode(common.Start(1));
- Node* use_value = graph()->NewNode(common.Return(), node, start, start);
+ Node* use_value = graph()->NewNode(common.Return(), node);
Node* replacement = graph()->NewNode(&kMockOperator);
GraphReducer graph_reducer(zone(), graph(), nullptr);
ReplaceWithValueReducer r(&graph_reducer);
@@ -307,18 +306,16 @@
CommonOperatorBuilder common(zone());
Node* start = graph()->NewNode(common.Start(1));
Node* node = graph()->NewNode(&kMockOpEffect, start);
- Node* use_control = graph()->NewNode(common.Merge(1), start);
- Node* use_effect = graph()->NewNode(common.EffectPhi(1), node, use_control);
+ Node* use_effect = graph()->NewNode(common.EffectPhi(1), node);
Node* replacement = graph()->NewNode(&kMockOperator);
GraphReducer graph_reducer(zone(), graph(), nullptr);
ReplaceWithValueReducer r(&graph_reducer);
r.ReplaceWithValue(node, replacement);
EXPECT_EQ(start, use_effect->InputAt(0));
EXPECT_EQ(0, node->UseCount());
- EXPECT_EQ(3, start->UseCount());
+ EXPECT_EQ(2, start->UseCount());
EXPECT_EQ(0, replacement->UseCount());
- EXPECT_THAT(start->uses(),
- UnorderedElementsAre(use_effect, use_control, node));
+ EXPECT_THAT(start->uses(), UnorderedElementsAre(use_effect, node));
}
« no previous file with comments | « test/cctest/compiler/test-simplified-lowering.cc ('k') | test/unittests/compiler/instruction-selector-unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698