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

Side by Side Diff: src/arm/codegen-arm.cc

Issue 509006: Remove complicated Math.sin and Math.cos optimizations that do not buy... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 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/arm/codegen-arm.h ('k') | src/arm/codegen-arm-inl.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 2006-2009 the V8 project authors. All rights reserved. 1 // Copyright 2006-2009 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 3526 matching lines...) Expand 10 before | Expand all | Expand 10 after
3537 3537
3538 void CodeGenerator::GenerateRandomPositiveSmi(ZoneList<Expression*>* args) { 3538 void CodeGenerator::GenerateRandomPositiveSmi(ZoneList<Expression*>* args) {
3539 VirtualFrame::SpilledScope spilled_scope; 3539 VirtualFrame::SpilledScope spilled_scope;
3540 ASSERT(args->length() == 0); 3540 ASSERT(args->length() == 0);
3541 __ Call(ExternalReference::random_positive_smi_function().address(), 3541 __ Call(ExternalReference::random_positive_smi_function().address(),
3542 RelocInfo::RUNTIME_ENTRY); 3542 RelocInfo::RUNTIME_ENTRY);
3543 frame_->EmitPush(r0); 3543 frame_->EmitPush(r0);
3544 } 3544 }
3545 3545
3546 3546
3547 void CodeGenerator::GenerateFastMathOp(MathOp op, ZoneList<Expression*>* args) {
3548 VirtualFrame::SpilledScope spilled_scope;
3549 LoadAndSpill(args->at(0));
3550 switch (op) {
3551 case SIN:
3552 frame_->CallRuntime(Runtime::kMath_sin, 1);
3553 break;
3554 case COS:
3555 frame_->CallRuntime(Runtime::kMath_cos, 1);
3556 break;
3557 }
3558 frame_->EmitPush(r0);
3559 }
3560
3561
3562 void CodeGenerator::GenerateStringAdd(ZoneList<Expression*>* args) { 3547 void CodeGenerator::GenerateStringAdd(ZoneList<Expression*>* args) {
3563 ASSERT_EQ(2, args->length()); 3548 ASSERT_EQ(2, args->length());
3564 3549
3565 Load(args->at(0)); 3550 Load(args->at(0));
3566 Load(args->at(1)); 3551 Load(args->at(1));
3567 3552
3568 frame_->CallRuntime(Runtime::kStringAdd, 2); 3553 frame_->CallRuntime(Runtime::kStringAdd, 2);
3569 frame_->EmitPush(r0); 3554 frame_->EmitPush(r0);
3570 } 3555 }
3571 3556
(...skipping 3010 matching lines...) Expand 10 before | Expand all | Expand 10 after
6582 int CompareStub::MinorKey() { 6567 int CompareStub::MinorKey() {
6583 // Encode the two parameters in a unique 16 bit value. 6568 // Encode the two parameters in a unique 16 bit value.
6584 ASSERT(static_cast<unsigned>(cc_) >> 28 < (1 << 15)); 6569 ASSERT(static_cast<unsigned>(cc_) >> 28 < (1 << 15));
6585 return (static_cast<unsigned>(cc_) >> 27) | (strict_ ? 1 : 0); 6570 return (static_cast<unsigned>(cc_) >> 27) | (strict_ ? 1 : 0);
6586 } 6571 }
6587 6572
6588 6573
6589 #undef __ 6574 #undef __
6590 6575
6591 } } // namespace v8::internal 6576 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm/codegen-arm.h ('k') | src/arm/codegen-arm-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698