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

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

Issue 1189963002: [turbofan] Remove ineffective optimization from ControlReducer. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Remove bogus tests. Created 5 years, 6 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 | « src/compiler/control-reducer.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/unittests/compiler/control-reducer-unittest.cc
diff --git a/test/unittests/compiler/control-reducer-unittest.cc b/test/unittests/compiler/control-reducer-unittest.cc
index d99548dd11fa5a808f954b01ebb80af725e1da6a..053ece0a6c78454b792b4a5ccb1b668bce2c175f 100644
--- a/test/unittests/compiler/control-reducer-unittest.cc
+++ b/test/unittests/compiler/control-reducer-unittest.cc
@@ -145,52 +145,6 @@ TEST_F(ControlReducerTest, PhiAsInputToBranch_unknown_true) {
}
-TEST_F(ControlReducerTest, RangeAsInputToBranch_true1) {
- Node* p0 = Parameter(Type::Range(1, 2, zone()), 0);
- Node* branch1 = graph()->NewNode(common()->Branch(), p0, graph()->start());
- Node* if_true1 = graph()->NewNode(common()->IfTrue(), branch1);
- Node* if_false1 = graph()->NewNode(common()->IfFalse(), branch1);
- Node* merge1 = graph()->NewNode(common()->Merge(1), if_true1, if_false1);
- Node* result = graph()->NewNode(common()->Phi(kMachInt32, 2),
- jsgraph()->Int32Constant(11),
- jsgraph()->Int32Constant(44), merge1);
-
- Node* ret =
- graph()->NewNode(common()->Return(), result, graph()->start(), merge1);
- graph()->end()->ReplaceInput(0, ret);
-
- ReduceGraph();
-
- // Diamond should be folded away.
- EXPECT_THAT(
- graph()->end(),
- IsEnd(IsReturn(IsInt32Constant(11), graph()->start(), graph()->start())));
-}
-
-
-TEST_F(ControlReducerTest, RangeAsInputToBranch_true2) {
- Node* p0 = Parameter(Type::Range(-2, -1, zone()), 0);
- Node* branch1 = graph()->NewNode(common()->Branch(), p0, graph()->start());
- Node* if_true1 = graph()->NewNode(common()->IfTrue(), branch1);
- Node* if_false1 = graph()->NewNode(common()->IfFalse(), branch1);
- Node* merge1 = graph()->NewNode(common()->Merge(1), if_true1, if_false1);
- Node* result = graph()->NewNode(common()->Phi(kMachInt32, 2),
- jsgraph()->Int32Constant(11),
- jsgraph()->Int32Constant(44), merge1);
-
- Node* ret =
- graph()->NewNode(common()->Return(), result, graph()->start(), merge1);
- graph()->end()->ReplaceInput(0, ret);
-
- ReduceGraph();
-
- // Diamond should be folded away.
- EXPECT_THAT(
- graph()->end(),
- IsEnd(IsReturn(IsInt32Constant(11), graph()->start(), graph()->start())));
-}
-
-
TEST_F(ControlReducerTest, SelectPhi) {
Node* p0 = Parameter(0);
const MachineType kType = kMachInt32;
« no previous file with comments | « src/compiler/control-reducer.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698