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

Side by Side Diff: src/crankshaft/mips64/lithium-mips64.cc

Issue 2073123002: [builtins] Introduce proper Float64Cos and Float64Sin. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix missing breaks 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
« no previous file with comments | « src/crankshaft/mips64/lithium-mips64.h ('k') | src/crankshaft/x64/lithium-codegen-x64.cc » ('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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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/crankshaft/mips64/lithium-mips64.h" 5 #include "src/crankshaft/mips64/lithium-mips64.h"
6 6
7 #include <sstream> 7 #include <sstream>
8 8
9 #if V8_TARGET_ARCH_MIPS64 9 #if V8_TARGET_ARCH_MIPS64
10 10
(...skipping 1056 matching lines...) Expand 10 before | Expand all | Expand 10 after
1067 case kMathFloor: 1067 case kMathFloor:
1068 return DoMathFloor(instr); 1068 return DoMathFloor(instr);
1069 case kMathRound: 1069 case kMathRound:
1070 return DoMathRound(instr); 1070 return DoMathRound(instr);
1071 case kMathFround: 1071 case kMathFround:
1072 return DoMathFround(instr); 1072 return DoMathFround(instr);
1073 case kMathAbs: 1073 case kMathAbs:
1074 return DoMathAbs(instr); 1074 return DoMathAbs(instr);
1075 case kMathLog: 1075 case kMathLog:
1076 return DoMathLog(instr); 1076 return DoMathLog(instr);
1077 case kMathCos:
1078 return DoMathCos(instr);
1079 case kMathSin:
1080 return DoMathSin(instr);
1077 case kMathExp: 1081 case kMathExp:
1078 return DoMathExp(instr); 1082 return DoMathExp(instr);
1079 case kMathSqrt: 1083 case kMathSqrt:
1080 return DoMathSqrt(instr); 1084 return DoMathSqrt(instr);
1081 case kMathPowHalf: 1085 case kMathPowHalf:
1082 return DoMathPowHalf(instr); 1086 return DoMathPowHalf(instr);
1083 case kMathClz32: 1087 case kMathClz32:
1084 return DoMathClz32(instr); 1088 return DoMathClz32(instr);
1085 default: 1089 default:
1086 UNREACHABLE(); 1090 UNREACHABLE();
1087 return NULL; 1091 return NULL;
1088 } 1092 }
1089 } 1093 }
1090 1094
1091 1095
1092 LInstruction* LChunkBuilder::DoMathLog(HUnaryMathOperation* instr) { 1096 LInstruction* LChunkBuilder::DoMathLog(HUnaryMathOperation* instr) {
1093 DCHECK(instr->representation().IsDouble()); 1097 DCHECK(instr->representation().IsDouble());
1094 DCHECK(instr->value()->representation().IsDouble()); 1098 DCHECK(instr->value()->representation().IsDouble());
1095 LOperand* input = UseFixedDouble(instr->value(), f4); 1099 LOperand* input = UseFixedDouble(instr->value(), f4);
1096 return MarkAsCall(DefineFixedDouble(new(zone()) LMathLog(input), f4), instr); 1100 return MarkAsCall(DefineFixedDouble(new(zone()) LMathLog(input), f4), instr);
1097 } 1101 }
1098 1102
1099 1103
1100 LInstruction* LChunkBuilder::DoMathClz32(HUnaryMathOperation* instr) { 1104 LInstruction* LChunkBuilder::DoMathClz32(HUnaryMathOperation* instr) {
1101 LOperand* input = UseRegisterAtStart(instr->value()); 1105 LOperand* input = UseRegisterAtStart(instr->value());
1102 LMathClz32* result = new(zone()) LMathClz32(input); 1106 LMathClz32* result = new(zone()) LMathClz32(input);
1103 return DefineAsRegister(result); 1107 return DefineAsRegister(result);
1104 } 1108 }
1105 1109
1110 LInstruction* LChunkBuilder::DoMathCos(HUnaryMathOperation* instr) {
1111 DCHECK(instr->representation().IsDouble());
1112 DCHECK(instr->value()->representation().IsDouble());
1113 LOperand* input = UseFixedDouble(instr->value(), f4);
1114 return MarkAsCall(DefineFixedDouble(new (zone()) LMathCos(input), f4), instr);
1115 }
1116
1117 LInstruction* LChunkBuilder::DoMathSin(HUnaryMathOperation* instr) {
1118 DCHECK(instr->representation().IsDouble());
1119 DCHECK(instr->value()->representation().IsDouble());
1120 LOperand* input = UseFixedDouble(instr->value(), f4);
1121 return MarkAsCall(DefineFixedDouble(new (zone()) LMathSin(input), f4), instr);
1122 }
1106 1123
1107 LInstruction* LChunkBuilder::DoMathExp(HUnaryMathOperation* instr) { 1124 LInstruction* LChunkBuilder::DoMathExp(HUnaryMathOperation* instr) {
1108 DCHECK(instr->representation().IsDouble()); 1125 DCHECK(instr->representation().IsDouble());
1109 DCHECK(instr->value()->representation().IsDouble()); 1126 DCHECK(instr->value()->representation().IsDouble());
1110 LOperand* input = UseFixedDouble(instr->value(), f4); 1127 LOperand* input = UseFixedDouble(instr->value(), f4);
1111 return MarkAsCall(DefineFixedDouble(new (zone()) LMathExp(input), f4), instr); 1128 return MarkAsCall(DefineFixedDouble(new (zone()) LMathExp(input), f4), instr);
1112 } 1129 }
1113 1130
1114 1131
1115 LInstruction* LChunkBuilder::DoMathPowHalf(HUnaryMathOperation* instr) { 1132 LInstruction* LChunkBuilder::DoMathPowHalf(HUnaryMathOperation* instr) {
(...skipping 1334 matching lines...) Expand 10 before | Expand all | Expand 10 after
2450 LOperand* index = UseTempRegister(instr->index()); 2467 LOperand* index = UseTempRegister(instr->index());
2451 LLoadFieldByIndex* load = new(zone()) LLoadFieldByIndex(object, index); 2468 LLoadFieldByIndex* load = new(zone()) LLoadFieldByIndex(object, index);
2452 LInstruction* result = DefineSameAsFirst(load); 2469 LInstruction* result = DefineSameAsFirst(load);
2453 return AssignPointerMap(result); 2470 return AssignPointerMap(result);
2454 } 2471 }
2455 2472
2456 } // namespace internal 2473 } // namespace internal
2457 } // namespace v8 2474 } // namespace v8
2458 2475
2459 #endif // V8_TARGET_ARCH_MIPS64 2476 #endif // V8_TARGET_ARCH_MIPS64
OLDNEW
« no previous file with comments | « src/crankshaft/mips64/lithium-mips64.h ('k') | src/crankshaft/x64/lithium-codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698