| Index: src/arm64/builtins-arm64.cc
|
| diff --git a/src/arm64/builtins-arm64.cc b/src/arm64/builtins-arm64.cc
|
| index 06e1016252ee6d96d6e648119aa08b36dc63ec37..9ecdeab7870664b7eb48494dfd0120c5dcf583e8 100644
|
| --- a/src/arm64/builtins-arm64.cc
|
| +++ b/src/arm64/builtins-arm64.cc
|
| @@ -1746,6 +1746,9 @@ void Builtins::Generate_OnStackReplacement(MacroAssembler* masm) {
|
| void Builtins::Generate_DatePrototype_GetField(MacroAssembler* masm,
|
| int field_index) {
|
| // ----------- S t a t e -------------
|
| + // -- x0 : number of arguments
|
| + // -- x1 : function
|
| + // -- cp : context
|
| // -- lr : return address
|
| // -- jssp[0] : receiver
|
| // -----------------------------------
|
| @@ -1754,9 +1757,10 @@ void Builtins::Generate_DatePrototype_GetField(MacroAssembler* masm,
|
| // 1. Pop receiver into x0 and check that it's actually a JSDate object.
|
| Label receiver_not_date;
|
| {
|
| + __ Move(x4, x0); // Store argc for builtin frame construction.
|
| __ Pop(x0);
|
| __ JumpIfSmi(x0, &receiver_not_date);
|
| - __ JumpIfNotObjectType(x0, x1, x2, JS_DATE_TYPE, &receiver_not_date);
|
| + __ JumpIfNotObjectType(x0, x2, x3, JS_DATE_TYPE, &receiver_not_date);
|
| }
|
|
|
| // 2. Load the specified date field, falling back to the runtime as necessary.
|
| @@ -1784,7 +1788,14 @@ void Builtins::Generate_DatePrototype_GetField(MacroAssembler* masm,
|
|
|
| // 3. Raise a TypeError if the receiver is not a date.
|
| __ Bind(&receiver_not_date);
|
| - __ TailCallRuntime(Runtime::kThrowNotDateError);
|
| + {
|
| + FrameScope scope(masm, StackFrame::MANUAL);
|
| + __ Push(x0, lr, fp);
|
| + __ Move(fp, jssp);
|
| + __ SmiTag(x4);
|
| + __ Push(cp, x1, x4);
|
| + __ CallRuntime(Runtime::kThrowNotDateError);
|
| + }
|
| }
|
|
|
| // static
|
|
|