| Index: src/arm/lithium-codegen-arm.cc
|
| diff --git a/src/arm/lithium-codegen-arm.cc b/src/arm/lithium-codegen-arm.cc
|
| index b9a3a0bfec6eab310f0634f80ba1af81a9e56410..04623c1ddaae5e9671f244a99927d21b2e1dcaa6 100644
|
| --- a/src/arm/lithium-codegen-arm.cc
|
| +++ b/src/arm/lithium-codegen-arm.cc
|
| @@ -2313,7 +2313,11 @@ void LCodeGen::DoBranch(LBranch* instr) {
|
| if (!expected.IsGeneric()) {
|
| // We've seen something for the first time -> deopt.
|
| // This can only happen if we are not generic already.
|
| - DeoptimizeIf(al, instr->environment());
|
| + if (!info()->IsStub()) {
|
| + SoftDeoptimize(instr->environment());
|
| + } else {
|
| + DeoptimizeIf(al, instr->environment());
|
| + }
|
| }
|
| }
|
| }
|
|
|