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

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

Issue 5996002: Add untagged double versions of Math.sin and Math.cos. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 10 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-codegen-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 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 3049 matching lines...) Expand 10 before | Expand all | Expand 10 after
3060 VisitForStackValue(args->at(1)); 3060 VisitForStackValue(args->at(1));
3061 3061
3062 StringCompareStub stub; 3062 StringCompareStub stub;
3063 __ CallStub(&stub); 3063 __ CallStub(&stub);
3064 context()->Plug(eax); 3064 context()->Plug(eax);
3065 } 3065 }
3066 3066
3067 3067
3068 void FullCodeGenerator::EmitMathSin(ZoneList<Expression*>* args) { 3068 void FullCodeGenerator::EmitMathSin(ZoneList<Expression*>* args) {
3069 // Load the argument on the stack and call the stub. 3069 // Load the argument on the stack and call the stub.
3070 TranscendentalCacheStub stub(TranscendentalCache::SIN); 3070 TranscendentalCacheStub stub(TranscendentalCache::SIN,
3071 TranscendentalCacheStub::TAGGED);
3071 ASSERT(args->length() == 1); 3072 ASSERT(args->length() == 1);
3072 VisitForStackValue(args->at(0)); 3073 VisitForStackValue(args->at(0));
3073 __ CallStub(&stub); 3074 __ CallStub(&stub);
3074 context()->Plug(eax); 3075 context()->Plug(eax);
3075 } 3076 }
3076 3077
3077 3078
3078 void FullCodeGenerator::EmitMathCos(ZoneList<Expression*>* args) { 3079 void FullCodeGenerator::EmitMathCos(ZoneList<Expression*>* args) {
3079 // Load the argument on the stack and call the stub. 3080 // Load the argument on the stack and call the stub.
3080 TranscendentalCacheStub stub(TranscendentalCache::COS); 3081 TranscendentalCacheStub stub(TranscendentalCache::COS,
3082 TranscendentalCacheStub::TAGGED);
3081 ASSERT(args->length() == 1); 3083 ASSERT(args->length() == 1);
3082 VisitForStackValue(args->at(0)); 3084 VisitForStackValue(args->at(0));
3083 __ CallStub(&stub); 3085 __ CallStub(&stub);
3084 context()->Plug(eax); 3086 context()->Plug(eax);
3085 } 3087 }
3086 3088
3087 3089
3088 void FullCodeGenerator::EmitMathLog(ZoneList<Expression*>* args) { 3090 void FullCodeGenerator::EmitMathLog(ZoneList<Expression*>* args) {
3089 // Load the argument on the stack and call the stub. 3091 // Load the argument on the stack and call the stub.
3090 TranscendentalCacheStub stub(TranscendentalCache::LOG); 3092 TranscendentalCacheStub stub(TranscendentalCache::LOG,
3093 TranscendentalCacheStub::TAGGED);
3091 ASSERT(args->length() == 1); 3094 ASSERT(args->length() == 1);
3092 VisitForStackValue(args->at(0)); 3095 VisitForStackValue(args->at(0));
3093 __ CallStub(&stub); 3096 __ CallStub(&stub);
3094 context()->Plug(eax); 3097 context()->Plug(eax);
3095 } 3098 }
3096 3099
3097 3100
3098 void FullCodeGenerator::EmitMathSqrt(ZoneList<Expression*>* args) { 3101 void FullCodeGenerator::EmitMathSqrt(ZoneList<Expression*>* args) {
3099 // Load the argument on the stack and call the runtime function. 3102 // Load the argument on the stack and call the runtime function.
3100 ASSERT(args->length() == 1); 3103 ASSERT(args->length() == 1);
(...skipping 1156 matching lines...) Expand 10 before | Expand all | Expand 10 after
4257 // And return. 4260 // And return.
4258 __ ret(0); 4261 __ ret(0);
4259 } 4262 }
4260 4263
4261 4264
4262 #undef __ 4265 #undef __
4263 4266
4264 } } // namespace v8::internal 4267 } } // namespace v8::internal
4265 4268
4266 #endif // V8_TARGET_ARCH_IA32 4269 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/ia32/codegen-ia32.cc ('k') | src/ia32/lithium-codegen-ia32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698