| Index: src/arm/lithium-codegen-arm.cc
|
| diff --git a/src/arm/lithium-codegen-arm.cc b/src/arm/lithium-codegen-arm.cc
|
| index 74fd53dee4ca60525ee7bf343bfbcbb59824693e..02965e3531daed15deba0415c5e16c753fa13ff3 100644
|
| --- a/src/arm/lithium-codegen-arm.cc
|
| +++ b/src/arm/lithium-codegen-arm.cc
|
| @@ -3754,7 +3754,7 @@ void LCodeGen::DoCallConstantFunction(LCallConstantFunction* instr) {
|
| }
|
|
|
|
|
| -void LCodeGen::DoDeferredMathAbsTaggedHeapNumber(LUnaryMathOperation* instr) {
|
| +void LCodeGen::DoDeferredMathAbsTaggedHeapNumber(LMathAbs* instr) {
|
| Register input = ToRegister(instr->value());
|
| Register result = ToRegister(instr->result());
|
| Register scratch = scratch0();
|
| @@ -3820,7 +3820,7 @@ void LCodeGen::DoDeferredMathAbsTaggedHeapNumber(LUnaryMathOperation* instr) {
|
| }
|
|
|
|
|
| -void LCodeGen::EmitIntegerMathAbs(LUnaryMathOperation* instr) {
|
| +void LCodeGen::EmitIntegerMathAbs(LMathAbs* instr) {
|
| Register input = ToRegister(instr->value());
|
| Register result = ToRegister(instr->result());
|
| __ cmp(input, Operand::Zero());
|
| @@ -3834,19 +3834,18 @@ void LCodeGen::EmitIntegerMathAbs(LUnaryMathOperation* instr) {
|
| }
|
|
|
|
|
| -void LCodeGen::DoMathAbs(LUnaryMathOperation* instr) {
|
| +void LCodeGen::DoMathAbs(LMathAbs* instr) {
|
| // Class for deferred case.
|
| class DeferredMathAbsTaggedHeapNumber: public LDeferredCode {
|
| public:
|
| - DeferredMathAbsTaggedHeapNumber(LCodeGen* codegen,
|
| - LUnaryMathOperation* instr)
|
| + DeferredMathAbsTaggedHeapNumber(LCodeGen* codegen, LMathAbs* instr)
|
| : LDeferredCode(codegen), instr_(instr) { }
|
| virtual void Generate() {
|
| codegen()->DoDeferredMathAbsTaggedHeapNumber(instr_);
|
| }
|
| virtual LInstruction* instr() { return instr_; }
|
| private:
|
| - LUnaryMathOperation* instr_;
|
| + LMathAbs* instr_;
|
| };
|
|
|
| Representation r = instr->hydrogen()->value()->representation();
|
| @@ -3870,7 +3869,7 @@ void LCodeGen::DoMathAbs(LUnaryMathOperation* instr) {
|
| }
|
|
|
|
|
| -void LCodeGen::DoMathFloor(LUnaryMathOperation* instr) {
|
| +void LCodeGen::DoMathFloor(LMathFloor* instr) {
|
| DwVfpRegister input = ToDoubleRegister(instr->value());
|
| Register result = ToRegister(instr->result());
|
| Register input_high = scratch0();
|
| @@ -3892,7 +3891,7 @@ void LCodeGen::DoMathFloor(LUnaryMathOperation* instr) {
|
| }
|
|
|
|
|
| -void LCodeGen::DoMathRound(LUnaryMathOperation* instr) {
|
| +void LCodeGen::DoMathRound(LMathRound* instr) {
|
| DwVfpRegister input = ToDoubleRegister(instr->value());
|
| Register result = ToRegister(instr->result());
|
| DwVfpRegister double_scratch1 = ToDoubleRegister(instr->temp());
|
| @@ -3931,14 +3930,14 @@ void LCodeGen::DoMathRound(LUnaryMathOperation* instr) {
|
| }
|
|
|
|
|
| -void LCodeGen::DoMathSqrt(LUnaryMathOperation* instr) {
|
| +void LCodeGen::DoMathSqrt(LMathSqrt* instr) {
|
| DwVfpRegister input = ToDoubleRegister(instr->value());
|
| DwVfpRegister result = ToDoubleRegister(instr->result());
|
| __ vsqrt(result, input);
|
| }
|
|
|
|
|
| -void LCodeGen::DoMathPowHalf(LUnaryMathOperation* instr) {
|
| +void LCodeGen::DoMathPowHalf(LMathPowHalf* instr) {
|
| DwVfpRegister input = ToDoubleRegister(instr->value());
|
| DwVfpRegister result = ToDoubleRegister(instr->result());
|
| DwVfpRegister temp = ToDoubleRegister(instr->temp());
|
| @@ -4083,7 +4082,7 @@ void LCodeGen::DoMathExp(LMathExp* instr) {
|
| }
|
|
|
|
|
| -void LCodeGen::DoMathLog(LUnaryMathOperation* instr) {
|
| +void LCodeGen::DoMathLog(LMathLog* instr) {
|
| ASSERT(ToDoubleRegister(instr->result()).is(d2));
|
| TranscendentalCacheStub stub(TranscendentalCache::LOG,
|
| TranscendentalCacheStub::UNTAGGED);
|
| @@ -4091,7 +4090,7 @@ void LCodeGen::DoMathLog(LUnaryMathOperation* instr) {
|
| }
|
|
|
|
|
| -void LCodeGen::DoMathTan(LUnaryMathOperation* instr) {
|
| +void LCodeGen::DoMathTan(LMathTan* instr) {
|
| ASSERT(ToDoubleRegister(instr->result()).is(d2));
|
| TranscendentalCacheStub stub(TranscendentalCache::TAN,
|
| TranscendentalCacheStub::UNTAGGED);
|
| @@ -4099,7 +4098,7 @@ void LCodeGen::DoMathTan(LUnaryMathOperation* instr) {
|
| }
|
|
|
|
|
| -void LCodeGen::DoMathCos(LUnaryMathOperation* instr) {
|
| +void LCodeGen::DoMathCos(LMathCos* instr) {
|
| ASSERT(ToDoubleRegister(instr->result()).is(d2));
|
| TranscendentalCacheStub stub(TranscendentalCache::COS,
|
| TranscendentalCacheStub::UNTAGGED);
|
| @@ -4107,7 +4106,7 @@ void LCodeGen::DoMathCos(LUnaryMathOperation* instr) {
|
| }
|
|
|
|
|
| -void LCodeGen::DoMathSin(LUnaryMathOperation* instr) {
|
| +void LCodeGen::DoMathSin(LMathSin* instr) {
|
| ASSERT(ToDoubleRegister(instr->result()).is(d2));
|
| TranscendentalCacheStub stub(TranscendentalCache::SIN,
|
| TranscendentalCacheStub::UNTAGGED);
|
| @@ -4115,42 +4114,6 @@ void LCodeGen::DoMathSin(LUnaryMathOperation* instr) {
|
| }
|
|
|
|
|
| -void LCodeGen::DoUnaryMathOperation(LUnaryMathOperation* instr) {
|
| - switch (instr->op()) {
|
| - case kMathAbs:
|
| - DoMathAbs(instr);
|
| - break;
|
| - case kMathFloor:
|
| - DoMathFloor(instr);
|
| - break;
|
| - case kMathRound:
|
| - DoMathRound(instr);
|
| - break;
|
| - case kMathSqrt:
|
| - DoMathSqrt(instr);
|
| - break;
|
| - case kMathPowHalf:
|
| - DoMathPowHalf(instr);
|
| - break;
|
| - case kMathCos:
|
| - DoMathCos(instr);
|
| - break;
|
| - case kMathSin:
|
| - DoMathSin(instr);
|
| - break;
|
| - case kMathTan:
|
| - DoMathTan(instr);
|
| - break;
|
| - case kMathLog:
|
| - DoMathLog(instr);
|
| - break;
|
| - default:
|
| - Abort("Unimplemented type of LUnaryMathOperation.");
|
| - UNREACHABLE();
|
| - }
|
| -}
|
| -
|
| -
|
| void LCodeGen::DoInvokeFunction(LInvokeFunction* instr) {
|
| ASSERT(ToRegister(instr->function()).is(r1));
|
| ASSERT(instr->HasPointerMap());
|
|
|