Chromium Code Reviews| Index: src/arm/lithium-arm.h |
| diff --git a/src/arm/lithium-arm.h b/src/arm/lithium-arm.h |
| index f98c68f2197bb67e89f9aa5cb78e0be9a988d0c3..5a90f7a2ce4cdd5413e8238df9e13c8112c5b18e 100644 |
| --- a/src/arm/lithium-arm.h |
| +++ b/src/arm/lithium-arm.h |
| @@ -73,6 +73,9 @@ class LCodeGen; |
| V(CheckMap) \ |
| V(CheckPrototypeMaps) \ |
| V(CheckSmi) \ |
| + V(ClampDoubleToUint8) \ |
| + V(ClampIToUint8) \ |
|
Kevin Millikin (Chromium)
2011/05/16 07:06:34
It's strange that there is "Double", "I", and "Tag
|
| + V(ClampTaggedToUint8) \ |
| V(ClassOfTest) \ |
| V(ClassOfTestAndBranch) \ |
| V(CmpID) \ |
| @@ -1927,6 +1930,44 @@ class LCheckNonSmi: public LTemplateInstruction<0, 1, 0> { |
| }; |
| +class LClampDoubleToUint8: public LTemplateInstruction<1, 1, 1> { |
| + public: |
| + explicit LClampDoubleToUint8(LOperand* value, LOperand* temp) { |
|
Kevin Millikin (Chromium)
2011/05/16 07:06:34
No need for explicit here.
|
| + inputs_[0] = value; |
| + temps_[0] = temp; |
| + } |
| + |
| + LOperand* unclamped() { return inputs_[0]; } |
| + |
| + DECLARE_CONCRETE_INSTRUCTION(ClampDoubleToUint8, "clamp-d-to-uint8") |
| +}; |
| + |
| + |
| +class LClampIToUint8: public LTemplateInstruction<1, 1, 0> { |
| + public: |
| + explicit LClampIToUint8(LOperand* value) { |
| + inputs_[0] = value; |
| + } |
| + |
| + LOperand* unclamped() { return inputs_[0]; } |
| + |
| + DECLARE_CONCRETE_INSTRUCTION(ClampIToUint8, "clamp-i-to-uint8") |
| +}; |
| + |
| + |
| +class LClampTaggedToUint8: public LTemplateInstruction<1, 1, 1> { |
| + public: |
| + explicit LClampTaggedToUint8(LOperand* value, LOperand* temp) { |
| + inputs_[0] = value; |
| + temps_[0] = temp; |
| + } |
| + |
| + LOperand* unclamped() { return inputs_[0]; } |
| + |
| + DECLARE_CONCRETE_INSTRUCTION(ClampTaggedToUint8, "clamp-t-to-uint8") |
| +}; |
| + |
| + |
| class LArrayLiteral: public LTemplateInstruction<1, 0, 0> { |
| public: |
| DECLARE_CONCRETE_INSTRUCTION(ArrayLiteral, "array-literal") |