OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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/instruction-selector-impl.h" | 5 #include "src/compiler/instruction-selector-impl.h" |
6 #include "src/compiler/node-matchers.h" | 6 #include "src/compiler/node-matchers.h" |
7 #include "src/compiler/node-properties-inl.h" | 7 #include "src/compiler/node-properties-inl.h" |
8 | 8 |
9 namespace v8 { | 9 namespace v8 { |
10 namespace internal { | 10 namespace internal { |
(...skipping 451 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
462 } | 462 } |
463 Emit(kIA32Imul, g.DefineSameAsFirst(node), g.UseRegister(left), | 463 Emit(kIA32Imul, g.DefineSameAsFirst(node), g.UseRegister(left), |
464 g.Use(right)); | 464 g.Use(right)); |
465 } | 465 } |
466 } | 466 } |
467 | 467 |
468 | 468 |
469 void InstructionSelector::VisitInt32MulHigh(Node* node) { | 469 void InstructionSelector::VisitInt32MulHigh(Node* node) { |
470 IA32OperandGenerator g(this); | 470 IA32OperandGenerator g(this); |
471 InstructionOperand* temps[] = {g.TempRegister(eax)}; | 471 InstructionOperand* temps[] = {g.TempRegister(eax)}; |
472 size_t temp_count = arraysize(temps); | |
473 Emit(kIA32ImulHigh, g.DefineAsFixed(node, edx), | 472 Emit(kIA32ImulHigh, g.DefineAsFixed(node, edx), |
474 g.UseFixed(node->InputAt(0), eax), g.UseRegister(node->InputAt(1)), | 473 g.UseFixed(node->InputAt(0), eax), g.UseUniqueRegister(node->InputAt(1)), |
475 temp_count, temps); | 474 arraysize(temps), temps); |
476 } | 475 } |
477 | 476 |
478 | 477 |
479 static inline void VisitDiv(InstructionSelector* selector, Node* node, | 478 static inline void VisitDiv(InstructionSelector* selector, Node* node, |
480 ArchOpcode opcode) { | 479 ArchOpcode opcode) { |
481 IA32OperandGenerator g(selector); | 480 IA32OperandGenerator g(selector); |
482 InstructionOperand* temps[] = {g.TempRegister(edx)}; | 481 InstructionOperand* temps[] = {g.TempRegister(edx)}; |
483 size_t temp_count = arraysize(temps); | 482 size_t temp_count = arraysize(temps); |
484 selector->Emit(opcode, g.DefineAsFixed(node, eax), | 483 selector->Emit(opcode, g.DefineAsFixed(node, eax), |
485 g.UseFixed(node->InputAt(0), eax), | 484 g.UseFixed(node->InputAt(0), eax), |
(...skipping 388 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
874 | 873 |
875 | 874 |
876 void InstructionSelector::VisitFloat64LessThanOrEqual(Node* node) { | 875 void InstructionSelector::VisitFloat64LessThanOrEqual(Node* node) { |
877 FlagsContinuation cont(kUnorderedLessThanOrEqual, node); | 876 FlagsContinuation cont(kUnorderedLessThanOrEqual, node); |
878 VisitFloat64Compare(this, node, &cont); | 877 VisitFloat64Compare(this, node, &cont); |
879 } | 878 } |
880 | 879 |
881 } // namespace compiler | 880 } // namespace compiler |
882 } // namespace internal | 881 } // namespace internal |
883 } // namespace v8 | 882 } // namespace v8 |
OLD | NEW |