Index: test/unittests/compiler/simplified-operator-reducer-unittest.cc |
diff --git a/test/unittests/compiler/simplified-operator-reducer-unittest.cc b/test/unittests/compiler/simplified-operator-reducer-unittest.cc |
index eec39abb42b1d7ba8c6c2676266f3f8bc4975d9e..eed25f4b1c6b40657759262a0bc9ff46c5907edd 100644 |
--- a/test/unittests/compiler/simplified-operator-reducer-unittest.cc |
+++ b/test/unittests/compiler/simplified-operator-reducer-unittest.cc |
@@ -150,54 +150,60 @@ |
// ----------------------------------------------------------------------------- |
-// ChangeTaggedToBit |
- |
-TEST_F(SimplifiedOperatorReducerTest, ChangeBitToTaggedWithChangeTaggedToBit) { |
- Node* param0 = Parameter(0); |
- Reduction reduction = Reduce(graph()->NewNode( |
- simplified()->ChangeBitToTagged(), |
- graph()->NewNode(simplified()->ChangeTaggedToBit(), param0))); |
- ASSERT_TRUE(reduction.Changed()); |
- EXPECT_EQ(param0, reduction.replacement()); |
-} |
- |
-TEST_F(SimplifiedOperatorReducerTest, ChangeBitToTaggedWithZeroConstant) { |
+// ChangeBoolToBit |
+ |
+ |
+TEST_F(SimplifiedOperatorReducerTest, ChangeBitToBoolWithChangeBoolToBit) { |
+ Node* param0 = Parameter(0); |
+ Reduction reduction = Reduce(graph()->NewNode( |
+ simplified()->ChangeBitToBool(), |
+ graph()->NewNode(simplified()->ChangeBoolToBit(), param0))); |
+ ASSERT_TRUE(reduction.Changed()); |
+ EXPECT_EQ(param0, reduction.replacement()); |
+} |
+ |
+ |
+TEST_F(SimplifiedOperatorReducerTest, ChangeBitToBoolWithZeroConstant) { |
Reduction reduction = Reduce( |
- graph()->NewNode(simplified()->ChangeBitToTagged(), Int32Constant(0))); |
+ graph()->NewNode(simplified()->ChangeBitToBool(), Int32Constant(0))); |
ASSERT_TRUE(reduction.Changed()); |
EXPECT_THAT(reduction.replacement(), IsFalseConstant()); |
} |
-TEST_F(SimplifiedOperatorReducerTest, ChangeBitToTaggedWithOneConstant) { |
+ |
+TEST_F(SimplifiedOperatorReducerTest, ChangeBitToBoolWithOneConstant) { |
Reduction reduction = Reduce( |
- graph()->NewNode(simplified()->ChangeBitToTagged(), Int32Constant(1))); |
+ graph()->NewNode(simplified()->ChangeBitToBool(), Int32Constant(1))); |
ASSERT_TRUE(reduction.Changed()); |
EXPECT_THAT(reduction.replacement(), IsTrueConstant()); |
} |
// ----------------------------------------------------------------------------- |
-// ChangeTaggedToBit |
- |
-TEST_F(SimplifiedOperatorReducerTest, ChangeTaggedToBitWithFalseConstant) { |
+// ChangeBoolToBit |
+ |
+ |
+TEST_F(SimplifiedOperatorReducerTest, ChangeBoolToBitWithFalseConstant) { |
Reduction reduction = Reduce( |
- graph()->NewNode(simplified()->ChangeTaggedToBit(), FalseConstant())); |
+ graph()->NewNode(simplified()->ChangeBoolToBit(), FalseConstant())); |
ASSERT_TRUE(reduction.Changed()); |
EXPECT_THAT(reduction.replacement(), IsInt32Constant(0)); |
} |
-TEST_F(SimplifiedOperatorReducerTest, ChangeTaggedToBitWithTrueConstant) { |
- Reduction reduction = Reduce( |
- graph()->NewNode(simplified()->ChangeTaggedToBit(), TrueConstant())); |
+ |
+TEST_F(SimplifiedOperatorReducerTest, ChangeBoolToBitWithTrueConstant) { |
+ Reduction reduction = |
+ Reduce(graph()->NewNode(simplified()->ChangeBoolToBit(), TrueConstant())); |
ASSERT_TRUE(reduction.Changed()); |
EXPECT_THAT(reduction.replacement(), IsInt32Constant(1)); |
} |
-TEST_F(SimplifiedOperatorReducerTest, ChangeTaggedToBitWithChangeBitToTagged) { |
- Node* param0 = Parameter(0); |
- Reduction reduction = Reduce(graph()->NewNode( |
- simplified()->ChangeTaggedToBit(), |
- graph()->NewNode(simplified()->ChangeBitToTagged(), param0))); |
+ |
+TEST_F(SimplifiedOperatorReducerTest, ChangeBoolToBitWithChangeBitToBool) { |
+ Node* param0 = Parameter(0); |
+ Reduction reduction = Reduce(graph()->NewNode( |
+ simplified()->ChangeBoolToBit(), |
+ graph()->NewNode(simplified()->ChangeBitToBool(), param0))); |
ASSERT_TRUE(reduction.Changed()); |
EXPECT_EQ(param0, reduction.replacement()); |
} |