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

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

Issue 1360603003: [arm64] Implement Float(32|64)(Min|Max) using fcsel. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Remove "Ternary". Created 5 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
« no previous file with comments | « src/compiler/arm64/code-generator-arm64.cc ('k') | src/compiler/machine-operator.h » ('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/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 1351 matching lines...) Expand 10 before | Expand all | Expand 10 after
1362 1362
1363 1363
1364 void InstructionSelector::VisitFloat64Mod(Node* node) { 1364 void InstructionSelector::VisitFloat64Mod(Node* node) {
1365 Arm64OperandGenerator g(this); 1365 Arm64OperandGenerator g(this);
1366 Emit(kArm64Float64Mod, g.DefineAsFixed(node, d0), 1366 Emit(kArm64Float64Mod, g.DefineAsFixed(node, d0),
1367 g.UseFixed(node->InputAt(0), d0), 1367 g.UseFixed(node->InputAt(0), d0),
1368 g.UseFixed(node->InputAt(1), d1))->MarkAsCall(); 1368 g.UseFixed(node->InputAt(1), d1))->MarkAsCall();
1369 } 1369 }
1370 1370
1371 1371
1372 void InstructionSelector::VisitFloat32Max(Node* node) { UNREACHABLE(); } 1372 void InstructionSelector::VisitFloat32Max(Node* node) {
1373 VisitRRR(this, kArm64Float32Max, node);
1374 }
1373 1375
1374 1376
1375 void InstructionSelector::VisitFloat64Max(Node* node) { UNREACHABLE(); } 1377 void InstructionSelector::VisitFloat64Max(Node* node) {
1378 VisitRRR(this, kArm64Float64Max, node);
1379 }
1376 1380
1377 1381
1378 void InstructionSelector::VisitFloat32Min(Node* node) { UNREACHABLE(); } 1382 void InstructionSelector::VisitFloat32Min(Node* node) {
1383 VisitRRR(this, kArm64Float32Min, node);
1384 }
1379 1385
1380 1386
1381 void InstructionSelector::VisitFloat64Min(Node* node) { UNREACHABLE(); } 1387 void InstructionSelector::VisitFloat64Min(Node* node) {
1388 VisitRRR(this, kArm64Float64Min, node);
1389 }
1382 1390
1383 1391
1384 void InstructionSelector::VisitFloat32Abs(Node* node) { 1392 void InstructionSelector::VisitFloat32Abs(Node* node) {
1385 VisitRR(this, kArm64Float32Abs, node); 1393 VisitRR(this, kArm64Float32Abs, node);
1386 } 1394 }
1387 1395
1388 1396
1389 void InstructionSelector::VisitFloat64Abs(Node* node) { 1397 void InstructionSelector::VisitFloat64Abs(Node* node) {
1390 VisitRR(this, kArm64Float64Abs, node); 1398 VisitRR(this, kArm64Float64Abs, node);
1391 } 1399 }
(...skipping 559 matching lines...) Expand 10 before | Expand all | Expand 10 after
1951 return; 1959 return;
1952 } 1960 }
1953 Emit(kArm64Float64InsertHighWord32, g.DefineAsRegister(node), 1961 Emit(kArm64Float64InsertHighWord32, g.DefineAsRegister(node),
1954 g.UseRegister(left), g.UseRegister(right)); 1962 g.UseRegister(left), g.UseRegister(right));
1955 } 1963 }
1956 1964
1957 1965
1958 // static 1966 // static
1959 MachineOperatorBuilder::Flags 1967 MachineOperatorBuilder::Flags
1960 InstructionSelector::SupportedMachineOperatorFlags() { 1968 InstructionSelector::SupportedMachineOperatorFlags() {
1961 return MachineOperatorBuilder::kFloat64RoundDown | 1969 return MachineOperatorBuilder::kFloat32Max |
1970 MachineOperatorBuilder::kFloat32Min |
1971 MachineOperatorBuilder::kFloat64Max |
1972 MachineOperatorBuilder::kFloat64Min |
1973 MachineOperatorBuilder::kFloat64RoundDown |
1962 MachineOperatorBuilder::kFloat64RoundTruncate | 1974 MachineOperatorBuilder::kFloat64RoundTruncate |
1963 MachineOperatorBuilder::kFloat64RoundTiesAway | 1975 MachineOperatorBuilder::kFloat64RoundTiesAway |
1964 MachineOperatorBuilder::kWord32ShiftIsSafe | 1976 MachineOperatorBuilder::kWord32ShiftIsSafe |
1965 MachineOperatorBuilder::kInt32DivIsSafe | 1977 MachineOperatorBuilder::kInt32DivIsSafe |
1966 MachineOperatorBuilder::kUint32DivIsSafe; 1978 MachineOperatorBuilder::kUint32DivIsSafe;
1967 } 1979 }
1968 1980
1969 } // namespace compiler 1981 } // namespace compiler
1970 } // namespace internal 1982 } // namespace internal
1971 } // namespace v8 1983 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/arm64/code-generator-arm64.cc ('k') | src/compiler/machine-operator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698