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

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

Issue 2060743002: [builtins] Introduce proper Float64Log1p operator. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@Math_Log
Patch Set: REBASE Created 4 years, 6 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
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/base/adapters.h" 5 #include "src/base/adapters.h"
6 #include "src/base/bits.h" 6 #include "src/base/bits.h"
7 #include "src/compiler/instruction-selector-impl.h" 7 #include "src/compiler/instruction-selector-impl.h"
8 #include "src/compiler/node-matchers.h" 8 #include "src/compiler/node-matchers.h"
9 #include "src/compiler/node-properties.h" 9 #include "src/compiler/node-properties.h"
10 10
(...skipping 858 matching lines...) Expand 10 before | Expand all | Expand 10 after
869 869
870 void InstructionSelector::VisitFloat32Abs(Node* node) { 870 void InstructionSelector::VisitFloat32Abs(Node* node) {
871 VisitRR(this, kMipsAbsS, node); 871 VisitRR(this, kMipsAbsS, node);
872 } 872 }
873 873
874 874
875 void InstructionSelector::VisitFloat64Abs(Node* node) { 875 void InstructionSelector::VisitFloat64Abs(Node* node) {
876 VisitRR(this, kMipsAbsD, node); 876 VisitRR(this, kMipsAbsD, node);
877 } 877 }
878 878
879 void InstructionSelector::VisitFloat64Log(Node* node) {
880 MipsOperandGenerator g(this);
881 Emit(kIeee754Float64Log, g.DefineAsFixed(node, f0),
882 g.UseFixed(node->InputAt(0), f12))
883 ->MarkAsCall();
884 }
885
886 void InstructionSelector::VisitFloat32Sqrt(Node* node) { 879 void InstructionSelector::VisitFloat32Sqrt(Node* node) {
887 VisitRR(this, kMipsSqrtS, node); 880 VisitRR(this, kMipsSqrtS, node);
888 } 881 }
889 882
890 883
891 void InstructionSelector::VisitFloat64Sqrt(Node* node) { 884 void InstructionSelector::VisitFloat64Sqrt(Node* node) {
892 VisitRR(this, kMipsSqrtD, node); 885 VisitRR(this, kMipsSqrtD, node);
893 } 886 }
894 887
895 888
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
934 927
935 928
936 void InstructionSelector::VisitFloat64RoundTiesEven(Node* node) { 929 void InstructionSelector::VisitFloat64RoundTiesEven(Node* node) {
937 VisitRR(this, kMipsFloat64RoundTiesEven, node); 930 VisitRR(this, kMipsFloat64RoundTiesEven, node);
938 } 931 }
939 932
940 void InstructionSelector::VisitFloat32Neg(Node* node) { UNREACHABLE(); } 933 void InstructionSelector::VisitFloat32Neg(Node* node) { UNREACHABLE(); }
941 934
942 void InstructionSelector::VisitFloat64Neg(Node* node) { UNREACHABLE(); } 935 void InstructionSelector::VisitFloat64Neg(Node* node) { UNREACHABLE(); }
943 936
937 void InstructionSelector::VisitFloat64Ieee754Unop(Node* node,
938 InstructionCode opcode) {
939 MipsOperandGenerator g(this);
940 Emit(opcode, g.DefineAsFixed(node, f0), g.UseFixed(node->InputAt(0), f12))
941 ->MarkAsCall();
942 }
943
944 void InstructionSelector::EmitPrepareArguments( 944 void InstructionSelector::EmitPrepareArguments(
945 ZoneVector<PushParameter>* arguments, const CallDescriptor* descriptor, 945 ZoneVector<PushParameter>* arguments, const CallDescriptor* descriptor,
946 Node* node) { 946 Node* node) {
947 MipsOperandGenerator g(this); 947 MipsOperandGenerator g(this);
948 948
949 // Prepare for C function call. 949 // Prepare for C function call.
950 if (descriptor->IsCFunctionCall()) { 950 if (descriptor->IsCFunctionCall()) {
951 Emit(kArchPrepareCallCFunction | 951 Emit(kArchPrepareCallCFunction |
952 MiscField::encode(static_cast<int>(descriptor->CParameterCount())), 952 MiscField::encode(static_cast<int>(descriptor->CParameterCount())),
953 0, nullptr, 0, nullptr); 953 0, nullptr, 0, nullptr);
(...skipping 613 matching lines...) Expand 10 before | Expand all | Expand 10 after
1567 DCHECK(IsMipsArchVariant(kLoongson) || IsMipsArchVariant(kMips32r1) || 1567 DCHECK(IsMipsArchVariant(kLoongson) || IsMipsArchVariant(kMips32r1) ||
1568 IsMipsArchVariant(kMips32r2)); 1568 IsMipsArchVariant(kMips32r2));
1569 return MachineOperatorBuilder::AlignmentRequirements:: 1569 return MachineOperatorBuilder::AlignmentRequirements::
1570 NoUnalignedAccessSupport(); 1570 NoUnalignedAccessSupport();
1571 } 1571 }
1572 } 1572 }
1573 1573
1574 } // namespace compiler 1574 } // namespace compiler
1575 } // namespace internal 1575 } // namespace internal
1576 } // namespace v8 1576 } // namespace v8
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698