Chromium Code Reviews| Index: src/arm/builtins-arm.cc |
| diff --git a/src/arm/builtins-arm.cc b/src/arm/builtins-arm.cc |
| index 78fbe60a8072fc1e06365c33c8a9d928bfa1dcc8..5868c5e1937db4f7bebc95d55a916e261f472463 100644 |
| --- a/src/arm/builtins-arm.cc |
| +++ b/src/arm/builtins-arm.cc |
| @@ -2699,8 +2699,15 @@ void Builtins::Generate_StringToNumber(MacroAssembler* masm) { |
| __ Ret(); |
| __ bind(&runtime); |
| - __ Push(r0); // Push argument. |
| - __ TailCallRuntime(Runtime::kStringToNumber); |
| + { |
| + FrameScope frame(masm, StackFrame::INTERNAL); |
| + // Push argument. |
| + __ Push(r0); |
| + // We cannot use a tail call here because this builtin can also be called |
| + // from wasm. |
| + __ CallRuntime(Runtime::kToNumber); |
|
Benedikt Meurer
2016/06/21 08:32:48
kStringToNumber here and on all other ports.
ahaas
2016/06/21 08:52:58
done.
|
| + } |
| + __ Ret(); |
| } |
| void Builtins::Generate_ToNumber(MacroAssembler* masm) { |
| @@ -2734,9 +2741,15 @@ void Builtins::Generate_NonNumberToNumber(MacroAssembler* masm) { |
| __ ldr(r0, FieldMemOperand(r0, Oddball::kToNumberOffset)); |
| __ Ret(); |
| __ bind(¬_oddball); |
| - |
| - __ Push(r0); // Push argument. |
| - __ TailCallRuntime(Runtime::kToNumber); |
| + { |
| + FrameScope frame(masm, StackFrame::INTERNAL); |
| + // Push argument. |
| + __ Push(r0); |
| + // We cannot use a tail call here because this builtin can also be called |
| + // from wasm. |
| + __ CallRuntime(Runtime::kToNumber); |
| + } |
| + __ Ret(); |
| } |
| void Builtins::Generate_ArgumentsAdaptorTrampoline(MacroAssembler* masm) { |