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

Side by Side Diff: src/ia32/lithium-codegen-ia32.cc

Issue 104203003: Remove unused trigonometric code. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: addressed comment Created 7 years 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/ia32/codegen-ia32.cc ('k') | src/ia32/lithium-ia32.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 4179 matching lines...) Expand 10 before | Expand all | Expand 10 after
4190 XMMRegister input = ToDoubleRegister(instr->value()); 4190 XMMRegister input = ToDoubleRegister(instr->value());
4191 XMMRegister result = ToDoubleRegister(instr->result()); 4191 XMMRegister result = ToDoubleRegister(instr->result());
4192 XMMRegister temp0 = double_scratch0(); 4192 XMMRegister temp0 = double_scratch0();
4193 Register temp1 = ToRegister(instr->temp1()); 4193 Register temp1 = ToRegister(instr->temp1());
4194 Register temp2 = ToRegister(instr->temp2()); 4194 Register temp2 = ToRegister(instr->temp2());
4195 4195
4196 MathExpGenerator::EmitMathExp(masm(), input, result, temp0, temp1, temp2); 4196 MathExpGenerator::EmitMathExp(masm(), input, result, temp0, temp1, temp2);
4197 } 4197 }
4198 4198
4199 4199
4200 void LCodeGen::DoMathTan(LMathTan* instr) {
4201 ASSERT(ToDoubleRegister(instr->result()).is(xmm1));
4202 // Set the context register to a GC-safe fake value. Clobbering it is
4203 // OK because this instruction is marked as a call.
4204 __ Set(esi, Immediate(0));
4205 TranscendentalCacheStub stub(TranscendentalCache::TAN,
4206 TranscendentalCacheStub::UNTAGGED);
4207 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr);
4208 }
4209
4210
4211 void LCodeGen::DoMathCos(LMathCos* instr) {
4212 ASSERT(ToDoubleRegister(instr->result()).is(xmm1));
4213 // Set the context register to a GC-safe fake value. Clobbering it is
4214 // OK because this instruction is marked as a call.
4215 __ Set(esi, Immediate(0));
4216 TranscendentalCacheStub stub(TranscendentalCache::COS,
4217 TranscendentalCacheStub::UNTAGGED);
4218 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr);
4219 }
4220
4221
4222 void LCodeGen::DoMathSin(LMathSin* instr) {
4223 ASSERT(ToDoubleRegister(instr->result()).is(xmm1));
4224 // Set the context register to a GC-safe fake value. Clobbering it is
4225 // OK because this instruction is marked as a call.
4226 __ Set(esi, Immediate(0));
4227 TranscendentalCacheStub stub(TranscendentalCache::SIN,
4228 TranscendentalCacheStub::UNTAGGED);
4229 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr);
4230 }
4231
4232
4233 void LCodeGen::DoInvokeFunction(LInvokeFunction* instr) { 4200 void LCodeGen::DoInvokeFunction(LInvokeFunction* instr) {
4234 ASSERT(ToRegister(instr->context()).is(esi)); 4201 ASSERT(ToRegister(instr->context()).is(esi));
4235 ASSERT(ToRegister(instr->function()).is(edi)); 4202 ASSERT(ToRegister(instr->function()).is(edi));
4236 ASSERT(instr->HasPointerMap()); 4203 ASSERT(instr->HasPointerMap());
4237 4204
4238 Handle<JSFunction> known_function = instr->hydrogen()->known_function(); 4205 Handle<JSFunction> known_function = instr->hydrogen()->known_function();
4239 if (known_function.is_null()) { 4206 if (known_function.is_null()) {
4240 LPointerMap* pointers = instr->pointer_map(); 4207 LPointerMap* pointers = instr->pointer_map();
4241 SafepointGenerator generator( 4208 SafepointGenerator generator(
4242 this, pointers, Safepoint::kLazyDeopt); 4209 this, pointers, Safepoint::kLazyDeopt);
(...skipping 2159 matching lines...) Expand 10 before | Expand all | Expand 10 after
6402 FixedArray::kHeaderSize - kPointerSize)); 6369 FixedArray::kHeaderSize - kPointerSize));
6403 __ bind(&done); 6370 __ bind(&done);
6404 } 6371 }
6405 6372
6406 6373
6407 #undef __ 6374 #undef __
6408 6375
6409 } } // namespace v8::internal 6376 } } // namespace v8::internal
6410 6377
6411 #endif // V8_TARGET_ARCH_IA32 6378 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/ia32/codegen-ia32.cc ('k') | src/ia32/lithium-ia32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698