| 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/base/adapters.h" | 5 #include "src/base/adapters.h" |
| 6 #include "src/compiler/instruction-selector-impl.h" | 6 #include "src/compiler/instruction-selector-impl.h" |
| 7 #include "src/compiler/node-matchers.h" | 7 #include "src/compiler/node-matchers.h" |
| 8 #include "src/compiler/node-properties.h" | 8 #include "src/compiler/node-properties.h" |
| 9 | 9 |
| 10 namespace v8 { | 10 namespace v8 { |
| (...skipping 490 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 501 g.UseFixed(right, ecx)); | 501 g.UseFixed(right, ecx)); |
| 502 } | 502 } |
| 503 } | 503 } |
| 504 | 504 |
| 505 | 505 |
| 506 namespace { | 506 namespace { |
| 507 | 507 |
| 508 void VisitMulHigh(InstructionSelector* selector, Node* node, | 508 void VisitMulHigh(InstructionSelector* selector, Node* node, |
| 509 ArchOpcode opcode) { | 509 ArchOpcode opcode) { |
| 510 IA32OperandGenerator g(selector); | 510 IA32OperandGenerator g(selector); |
| 511 selector->Emit(opcode, g.DefineAsFixed(node, edx), | 511 InstructionOperand temps[] = {g.TempRegister(eax)}; |
| 512 g.UseFixed(node->InputAt(0), eax), | 512 selector->Emit( |
| 513 g.UseUniqueRegister(node->InputAt(1))); | 513 opcode, g.DefineAsFixed(node, edx), g.UseFixed(node->InputAt(0), eax), |
| 514 g.UseUniqueRegister(node->InputAt(1)), arraysize(temps), temps); |
| 514 } | 515 } |
| 515 | 516 |
| 516 | 517 |
| 517 void VisitDiv(InstructionSelector* selector, Node* node, ArchOpcode opcode) { | 518 void VisitDiv(InstructionSelector* selector, Node* node, ArchOpcode opcode) { |
| 518 IA32OperandGenerator g(selector); | 519 IA32OperandGenerator g(selector); |
| 519 InstructionOperand temps[] = {g.TempRegister(edx)}; | 520 InstructionOperand temps[] = {g.TempRegister(edx)}; |
| 520 selector->Emit(opcode, g.DefineAsFixed(node, eax), | 521 selector->Emit(opcode, g.DefineAsFixed(node, eax), |
| 521 g.UseFixed(node->InputAt(0), eax), | 522 g.UseFixed(node->InputAt(0), eax), |
| 522 g.UseUnique(node->InputAt(1)), arraysize(temps), temps); | 523 g.UseUnique(node->InputAt(1)), arraysize(temps), temps); |
| 523 } | 524 } |
| (...skipping 812 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1336 MachineOperatorBuilder::kFloat64RoundTruncate | | 1337 MachineOperatorBuilder::kFloat64RoundTruncate | |
| 1337 MachineOperatorBuilder::kFloat32RoundTiesEven | | 1338 MachineOperatorBuilder::kFloat32RoundTiesEven | |
| 1338 MachineOperatorBuilder::kFloat64RoundTiesEven; | 1339 MachineOperatorBuilder::kFloat64RoundTiesEven; |
| 1339 } | 1340 } |
| 1340 return flags; | 1341 return flags; |
| 1341 } | 1342 } |
| 1342 | 1343 |
| 1343 } // namespace compiler | 1344 } // namespace compiler |
| 1344 } // namespace internal | 1345 } // namespace internal |
| 1345 } // namespace v8 | 1346 } // namespace v8 |
| OLD | NEW |