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

Side by Side Diff: src/compiler/x64/instruction-selector-x64.cc

Issue 671393002: [x86] Fix register constraints for multiply-high. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Added regression test. Created 6 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/compiler/instruction.h ('k') | test/mjsunit/compiler/regress-register-allocator.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/generic-node-inl.h" 5 #include "src/compiler/generic-node-inl.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 8
9 namespace v8 { 9 namespace v8 {
10 namespace internal { 10 namespace internal {
(...skipping 542 matching lines...) Expand 10 before | Expand all | Expand 10 after
553 553
554 void InstructionSelector::VisitInt64Mul(Node* node) { 554 void InstructionSelector::VisitInt64Mul(Node* node) {
555 if (TryEmitLeaMult(this, node, kX64Lea)) return; 555 if (TryEmitLeaMult(this, node, kX64Lea)) return;
556 VisitMul(this, node, kX64Imul); 556 VisitMul(this, node, kX64Imul);
557 } 557 }
558 558
559 559
560 void InstructionSelector::VisitInt32MulHigh(Node* node) { 560 void InstructionSelector::VisitInt32MulHigh(Node* node) {
561 X64OperandGenerator g(this); 561 X64OperandGenerator g(this);
562 InstructionOperand* temps[] = {g.TempRegister(rax)}; 562 InstructionOperand* temps[] = {g.TempRegister(rax)};
563 size_t temp_count = arraysize(temps);
564 Emit(kX64ImulHigh32, g.DefineAsFixed(node, rdx), 563 Emit(kX64ImulHigh32, g.DefineAsFixed(node, rdx),
565 g.UseFixed(node->InputAt(0), rax), g.UseRegister(node->InputAt(1)), 564 g.UseFixed(node->InputAt(0), rax), g.UseUniqueRegister(node->InputAt(1)),
566 temp_count, temps); 565 arraysize(temps), temps);
567 } 566 }
568 567
569 568
570 static void VisitDiv(InstructionSelector* selector, Node* node, 569 static void VisitDiv(InstructionSelector* selector, Node* node,
571 ArchOpcode opcode) { 570 ArchOpcode opcode) {
572 X64OperandGenerator g(selector); 571 X64OperandGenerator g(selector);
573 InstructionOperand* temps[] = {g.TempRegister(rdx)}; 572 InstructionOperand* temps[] = {g.TempRegister(rdx)};
574 selector->Emit( 573 selector->Emit(
575 opcode, g.DefineAsFixed(node, rax), g.UseFixed(node->InputAt(0), rax), 574 opcode, g.DefineAsFixed(node, rax), g.UseFixed(node->InputAt(0), rax),
576 g.UseUniqueRegister(node->InputAt(1)), arraysize(temps), temps); 575 g.UseUniqueRegister(node->InputAt(1)), arraysize(temps), temps);
(...skipping 528 matching lines...) Expand 10 before | Expand all | Expand 10 after
1105 1104
1106 1105
1107 void InstructionSelector::VisitFloat64LessThanOrEqual(Node* node) { 1106 void InstructionSelector::VisitFloat64LessThanOrEqual(Node* node) {
1108 FlagsContinuation cont(kUnorderedLessThanOrEqual, node); 1107 FlagsContinuation cont(kUnorderedLessThanOrEqual, node);
1109 VisitFloat64Compare(this, node, &cont); 1108 VisitFloat64Compare(this, node, &cont);
1110 } 1109 }
1111 1110
1112 } // namespace compiler 1111 } // namespace compiler
1113 } // namespace internal 1112 } // namespace internal
1114 } // namespace v8 1113 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/instruction.h ('k') | test/mjsunit/compiler/regress-register-allocator.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698