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

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

Issue 1072963002: PPC: [turbofan] Add new Float32Abs and Float64Abs operators. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 8 months 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
« no previous file with comments | « src/compiler/ppc/instruction-codes-ppc.h ('k') | no next file » | 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/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.h" 7 #include "src/compiler/node-properties.h"
8 8
9 namespace v8 { 9 namespace v8 {
10 namespace internal { 10 namespace internal {
(...skipping 977 matching lines...) Expand 10 before | Expand all | Expand 10 after
988 void InstructionSelector::VisitFloat32Min(Node* node) { 988 void InstructionSelector::VisitFloat32Min(Node* node) {
989 VisitRRR(this, kPPC_MinDouble, node); 989 VisitRRR(this, kPPC_MinDouble, node);
990 } 990 }
991 991
992 992
993 void InstructionSelector::VisitFloat64Min(Node* node) { 993 void InstructionSelector::VisitFloat64Min(Node* node) {
994 VisitRRR(this, kPPC_MinDouble, node); 994 VisitRRR(this, kPPC_MinDouble, node);
995 } 995 }
996 996
997 997
998 void InstructionSelector::VisitFloat32Abs(Node* node) { UNREACHABLE(); } 998 void InstructionSelector::VisitFloat32Abs(Node* node) {
999 VisitRR(this, kPPC_AbsDouble, node);
1000 }
999 1001
1000 1002
1001 void InstructionSelector::VisitFloat64Abs(Node* node) { UNREACHABLE(); } 1003 void InstructionSelector::VisitFloat64Abs(Node* node) {
1004 VisitRR(this, kPPC_AbsDouble, node);
1005 }
1002 1006
1003 1007
1004 void InstructionSelector::VisitFloat32Sqrt(Node* node) { 1008 void InstructionSelector::VisitFloat32Sqrt(Node* node) {
1005 VisitRR(this, kPPC_SqrtDouble, node); 1009 VisitRR(this, kPPC_SqrtDouble, node);
1006 } 1010 }
1007 1011
1008 1012
1009 void InstructionSelector::VisitFloat64Sqrt(Node* node) { 1013 void InstructionSelector::VisitFloat64Sqrt(Node* node) {
1010 VisitRR(this, kPPC_SqrtDouble, node); 1014 VisitRR(this, kPPC_SqrtDouble, node);
1011 } 1015 }
(...skipping 517 matching lines...) Expand 10 before | Expand all | Expand 10 after
1529 return; 1533 return;
1530 } 1534 }
1531 Emit(kPPC_DoubleInsertHighWord32, g.DefineSameAsFirst(node), 1535 Emit(kPPC_DoubleInsertHighWord32, g.DefineSameAsFirst(node),
1532 g.UseRegister(left), g.UseRegister(right)); 1536 g.UseRegister(left), g.UseRegister(right));
1533 } 1537 }
1534 1538
1535 1539
1536 // static 1540 // static
1537 MachineOperatorBuilder::Flags 1541 MachineOperatorBuilder::Flags
1538 InstructionSelector::SupportedMachineOperatorFlags() { 1542 InstructionSelector::SupportedMachineOperatorFlags() {
1539 return MachineOperatorBuilder::kFloat32Max | 1543 return MachineOperatorBuilder::kFloat32Abs |
1544 MachineOperatorBuilder::kFloat32Max |
1540 MachineOperatorBuilder::kFloat32Min | 1545 MachineOperatorBuilder::kFloat32Min |
1546 MachineOperatorBuilder::kFloat64Abs |
1541 MachineOperatorBuilder::kFloat64Max | 1547 MachineOperatorBuilder::kFloat64Max |
1542 MachineOperatorBuilder::kFloat64Min | 1548 MachineOperatorBuilder::kFloat64Min |
1543 MachineOperatorBuilder::kFloat64RoundDown | 1549 MachineOperatorBuilder::kFloat64RoundDown |
1544 MachineOperatorBuilder::kFloat64RoundTruncate | 1550 MachineOperatorBuilder::kFloat64RoundTruncate |
1545 MachineOperatorBuilder::kFloat64RoundTiesAway; 1551 MachineOperatorBuilder::kFloat64RoundTiesAway;
1546 // We omit kWord32ShiftIsSafe as s[rl]w use 0x3f as a mask rather than 0x1f. 1552 // We omit kWord32ShiftIsSafe as s[rl]w use 0x3f as a mask rather than 0x1f.
1547 } 1553 }
1548 1554
1549 } // namespace compiler 1555 } // namespace compiler
1550 } // namespace internal 1556 } // namespace internal
1551 } // namespace v8 1557 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/ppc/instruction-codes-ppc.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698