| OLD | NEW |
| 1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/compiler/int64-lowering.h" | 5 #include "src/compiler/int64-lowering.h" |
| 6 #include "src/compiler/common-operator.h" | 6 #include "src/compiler/common-operator.h" |
| 7 #include "src/compiler/linkage.h" | 7 #include "src/compiler/linkage.h" |
| 8 #include "src/compiler/machine-operator.h" | 8 #include "src/compiler/machine-operator.h" |
| 9 #include "src/compiler/node.h" | 9 #include "src/compiler/node.h" |
| 10 | 10 |
| (...skipping 461 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 472 EXPECT_THAT(graph()->end()->InputAt(1), | 472 EXPECT_THAT(graph()->end()->InputAt(1), |
| 473 IsReturn2(IsInt32Constant(low_word_value(0)), IsInt32Constant(0), | 473 IsReturn2(IsInt32Constant(low_word_value(0)), IsInt32Constant(0), |
| 474 start(), start())); | 474 start(), start())); |
| 475 } | 475 } |
| 476 // kExprF64ReinterpretI64: | 476 // kExprF64ReinterpretI64: |
| 477 // kExprI64ReinterpretF64: | 477 // kExprI64ReinterpretF64: |
| 478 | 478 |
| 479 // kExprI64Clz: | 479 // kExprI64Clz: |
| 480 // kExprI64Ctz: | 480 // kExprI64Ctz: |
| 481 // kExprI64Popcnt: | 481 // kExprI64Popcnt: |
| 482 |
| 483 TEST_F(Int64LoweringTest, Dfs) { |
| 484 Node* common = Int64Constant(value(0)); |
| 485 LowerGraph(graph()->NewNode(machine()->Word64And(), common, |
| 486 graph()->NewNode(machine()->Word64And(), common, |
| 487 Int64Constant(value(1)))), |
| 488 MachineRepresentation::kWord64); |
| 489 |
| 490 EXPECT_THAT( |
| 491 graph()->end()->InputAt(1), |
| 492 IsReturn2(IsWord32And(IsInt32Constant(low_word_value(0)), |
| 493 IsWord32And(IsInt32Constant(low_word_value(0)), |
| 494 IsInt32Constant(low_word_value(1)))), |
| 495 IsWord32And(IsInt32Constant(high_word_value(0)), |
| 496 IsWord32And(IsInt32Constant(high_word_value(0)), |
| 497 IsInt32Constant(high_word_value(1)))), |
| 498 start(), start())); |
| 499 } |
| 482 } // namespace compiler | 500 } // namespace compiler |
| 483 } // namespace internal | 501 } // namespace internal |
| 484 } // namespace v8 | 502 } // namespace v8 |
| OLD | NEW |