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

Side by Side Diff: src/mips/lithium-mips.h

Issue 11415192: MIPS: Faster implementation of Math.exp() (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 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/mips/lithium-codegen-mips.cc ('k') | src/mips/lithium-mips.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 // 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 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 V(LoadExternalArrayPointer) \ 124 V(LoadExternalArrayPointer) \
125 V(LoadFunctionPrototype) \ 125 V(LoadFunctionPrototype) \
126 V(LoadGlobalCell) \ 126 V(LoadGlobalCell) \
127 V(LoadGlobalGeneric) \ 127 V(LoadGlobalGeneric) \
128 V(LoadKeyed) \ 128 V(LoadKeyed) \
129 V(LoadKeyedGeneric) \ 129 V(LoadKeyedGeneric) \
130 V(LoadNamedField) \ 130 V(LoadNamedField) \
131 V(LoadNamedFieldPolymorphic) \ 131 V(LoadNamedFieldPolymorphic) \
132 V(LoadNamedGeneric) \ 132 V(LoadNamedGeneric) \
133 V(MapEnumLength) \ 133 V(MapEnumLength) \
134 V(MathExp) \
134 V(MathMinMax) \ 135 V(MathMinMax) \
135 V(ModI) \ 136 V(ModI) \
136 V(MulI) \ 137 V(MulI) \
137 V(NumberTagD) \ 138 V(NumberTagD) \
138 V(NumberTagI) \ 139 V(NumberTagI) \
139 V(NumberTagU) \ 140 V(NumberTagU) \
140 V(NumberUntagD) \ 141 V(NumberUntagD) \
141 V(ObjectLiteral) \ 142 V(ObjectLiteral) \
142 V(OsrEntry) \ 143 V(OsrEntry) \
143 V(OuterContext) \ 144 V(OuterContext) \
(...skipping 490 matching lines...) Expand 10 before | Expand all | Expand 10 after
634 LOperand* temp() { return temps_[0]; } 635 LOperand* temp() { return temps_[0]; }
635 636
636 DECLARE_CONCRETE_INSTRUCTION(UnaryMathOperation, "unary-math-operation") 637 DECLARE_CONCRETE_INSTRUCTION(UnaryMathOperation, "unary-math-operation")
637 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation) 638 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation)
638 639
639 virtual void PrintDataTo(StringStream* stream); 640 virtual void PrintDataTo(StringStream* stream);
640 BuiltinFunctionId op() const { return hydrogen()->op(); } 641 BuiltinFunctionId op() const { return hydrogen()->op(); }
641 }; 642 };
642 643
643 644
645 class LMathExp: public LTemplateInstruction<1, 1, 3> {
646 public:
647 LMathExp(LOperand* value,
648 LOperand* double_temp,
649 LOperand* temp1,
650 LOperand* temp2) {
651 inputs_[0] = value;
652 temps_[0] = temp1;
653 temps_[1] = temp2;
654 temps_[2] = double_temp;
655 ExternalReference::InitializeMathExpData();
656 }
657
658 LOperand* value() { return inputs_[0]; }
659 LOperand* temp1() { return temps_[0]; }
660 LOperand* temp2() { return temps_[1]; }
661 LOperand* double_temp() { return temps_[2]; }
662
663 DECLARE_CONCRETE_INSTRUCTION(MathExp, "math-exp")
664
665 virtual void PrintDataTo(StringStream* stream);
666 };
667
668
644 class LCmpObjectEqAndBranch: public LControlInstruction<2, 0> { 669 class LCmpObjectEqAndBranch: public LControlInstruction<2, 0> {
645 public: 670 public:
646 LCmpObjectEqAndBranch(LOperand* left, LOperand* right) { 671 LCmpObjectEqAndBranch(LOperand* left, LOperand* right) {
647 inputs_[0] = left; 672 inputs_[0] = left;
648 inputs_[1] = right; 673 inputs_[1] = right;
649 } 674 }
650 675
651 LOperand* left() { return inputs_[0]; } 676 LOperand* left() { return inputs_[0]; }
652 LOperand* right() { return inputs_[1]; } 677 LOperand* right() { return inputs_[1]; }
653 678
(...skipping 1848 matching lines...) Expand 10 before | Expand all | Expand 10 after
2502 2527
2503 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); 2528 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder);
2504 }; 2529 };
2505 2530
2506 #undef DECLARE_HYDROGEN_ACCESSOR 2531 #undef DECLARE_HYDROGEN_ACCESSOR
2507 #undef DECLARE_CONCRETE_INSTRUCTION 2532 #undef DECLARE_CONCRETE_INSTRUCTION
2508 2533
2509 } } // namespace v8::internal 2534 } } // namespace v8::internal
2510 2535
2511 #endif // V8_MIPS_LITHIUM_MIPS_H_ 2536 #endif // V8_MIPS_LITHIUM_MIPS_H_
OLDNEW
« no previous file with comments | « src/mips/lithium-codegen-mips.cc ('k') | src/mips/lithium-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698