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

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

Issue 8806010: Refactor MathPowHalf on ia32. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: . Created 9 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/lithium-codegen-ia32.cc ('k') | src/ia32/lithium-ia32.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 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
116 V(LoadFunctionPrototype) \ 116 V(LoadFunctionPrototype) \
117 V(LoadGlobalCell) \ 117 V(LoadGlobalCell) \
118 V(LoadGlobalGeneric) \ 118 V(LoadGlobalGeneric) \
119 V(LoadKeyedFastElement) \ 119 V(LoadKeyedFastElement) \
120 V(LoadKeyedFastDoubleElement) \ 120 V(LoadKeyedFastDoubleElement) \
121 V(LoadKeyedGeneric) \ 121 V(LoadKeyedGeneric) \
122 V(LoadKeyedSpecializedArrayElement) \ 122 V(LoadKeyedSpecializedArrayElement) \
123 V(LoadNamedField) \ 123 V(LoadNamedField) \
124 V(LoadNamedFieldPolymorphic) \ 124 V(LoadNamedFieldPolymorphic) \
125 V(LoadNamedGeneric) \ 125 V(LoadNamedGeneric) \
126 V(MathPowHalf) \
126 V(ModI) \ 127 V(ModI) \
127 V(MulI) \ 128 V(MulI) \
128 V(NumberTagD) \ 129 V(NumberTagD) \
129 V(NumberTagI) \ 130 V(NumberTagI) \
130 V(NumberUntagD) \ 131 V(NumberUntagD) \
131 V(ObjectLiteralFast) \ 132 V(ObjectLiteralFast) \
132 V(ObjectLiteralGeneric) \ 133 V(ObjectLiteralGeneric) \
133 V(OsrEntry) \ 134 V(OsrEntry) \
134 V(OuterContext) \ 135 V(OuterContext) \
135 V(Parameter) \ 136 V(Parameter) \
(...skipping 439 matching lines...) Expand 10 before | Expand all | Expand 10 after
575 LOperand* value() { return inputs_[0]; } 576 LOperand* value() { return inputs_[0]; }
576 577
577 DECLARE_CONCRETE_INSTRUCTION(UnaryMathOperation, "unary-math-operation") 578 DECLARE_CONCRETE_INSTRUCTION(UnaryMathOperation, "unary-math-operation")
578 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation) 579 DECLARE_HYDROGEN_ACCESSOR(UnaryMathOperation)
579 580
580 virtual void PrintDataTo(StringStream* stream); 581 virtual void PrintDataTo(StringStream* stream);
581 BuiltinFunctionId op() const { return hydrogen()->op(); } 582 BuiltinFunctionId op() const { return hydrogen()->op(); }
582 }; 583 };
583 584
584 585
586 class LMathPowHalf: public LTemplateInstruction<1, 2, 1> {
587 public:
588 LMathPowHalf(LOperand* context, LOperand* value, LOperand* temp) {
589 inputs_[1] = context;
590 inputs_[0] = value;
591 temps_[0] = temp;
592 }
593
594 LOperand* context() { return inputs_[1]; }
595 LOperand* value() { return inputs_[0]; }
596 LOperand* temp() { return temps_[0]; }
597
598 DECLARE_CONCRETE_INSTRUCTION(MathPowHalf, "math-pow-half")
599
600 virtual void PrintDataTo(StringStream* stream);
601 };
602
603
585 class LCmpObjectEqAndBranch: public LControlInstruction<2, 0> { 604 class LCmpObjectEqAndBranch: public LControlInstruction<2, 0> {
586 public: 605 public:
587 LCmpObjectEqAndBranch(LOperand* left, LOperand* right) { 606 LCmpObjectEqAndBranch(LOperand* left, LOperand* right) {
588 inputs_[0] = left; 607 inputs_[0] = left;
589 inputs_[1] = right; 608 inputs_[1] = right;
590 } 609 }
591 610
592 DECLARE_CONCRETE_INSTRUCTION(CmpObjectEqAndBranch, 611 DECLARE_CONCRETE_INSTRUCTION(CmpObjectEqAndBranch,
593 "cmp-object-eq-and-branch") 612 "cmp-object-eq-and-branch")
594 }; 613 };
(...skipping 1761 matching lines...) Expand 10 before | Expand all | Expand 10 after
2356 2375
2357 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); 2376 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder);
2358 }; 2377 };
2359 2378
2360 #undef DECLARE_HYDROGEN_ACCESSOR 2379 #undef DECLARE_HYDROGEN_ACCESSOR
2361 #undef DECLARE_CONCRETE_INSTRUCTION 2380 #undef DECLARE_CONCRETE_INSTRUCTION
2362 2381
2363 } } // namespace v8::internal 2382 } } // namespace v8::internal
2364 2383
2365 #endif // V8_IA32_LITHIUM_IA32_H_ 2384 #endif // V8_IA32_LITHIUM_IA32_H_
OLDNEW
« no previous file with comments | « src/ia32/lithium-codegen-ia32.cc ('k') | src/ia32/lithium-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698