PPC/s390: [builtins] Always pass target and new target to C++ builtins
Port f5b83dec4e
Original commit message:
As a first step towards showing builtin frames in stack traces, we will now
push target and new target unconditionally.
Since the various specializations of BuiltinArguments are made redundant by
this change, we can remove them and all related code.
R=jgruber@chromium.org, joransiu@ca.ibm.com, jyan@ca.ibm.com, michael_dawson@ca.ibm.com, mbrandy@us.ibm.com
BUG=
LOG=N
Review-Url: https://codereview.chromium.org/2079073003
Cr-Commit-Position: refs/heads/master@{#37075}
This commit is contained in:
parent
c4d2b19137
commit
57733bdd78
@ -17,8 +17,7 @@ namespace internal {
|
||||
#define __ ACCESS_MASM(masm)
|
||||
|
||||
|
||||
void Builtins::Generate_Adaptor(MacroAssembler* masm, CFunctionId id,
|
||||
BuiltinExtraArguments extra_args) {
|
||||
void Builtins::Generate_Adaptor(MacroAssembler* masm, CFunctionId id) {
|
||||
// ----------- S t a t e -------------
|
||||
// -- r3 : number of arguments excluding receiver
|
||||
// -- r4 : target
|
||||
@ -37,24 +36,8 @@ void Builtins::Generate_Adaptor(MacroAssembler* masm, CFunctionId id,
|
||||
__ LoadP(cp, FieldMemOperand(r4, JSFunction::kContextOffset));
|
||||
|
||||
// Insert extra arguments.
|
||||
int num_extra_args = 0;
|
||||
switch (extra_args) {
|
||||
case BuiltinExtraArguments::kTarget:
|
||||
__ Push(r4);
|
||||
++num_extra_args;
|
||||
break;
|
||||
case BuiltinExtraArguments::kNewTarget:
|
||||
__ Push(r6);
|
||||
++num_extra_args;
|
||||
break;
|
||||
case BuiltinExtraArguments::kTargetAndNewTarget:
|
||||
__ Push(r4, r6);
|
||||
num_extra_args += 2;
|
||||
break;
|
||||
case BuiltinExtraArguments::kNone:
|
||||
break;
|
||||
}
|
||||
|
||||
const int num_extra_args = 2;
|
||||
__ Push(r4, r6);
|
||||
// JumpToExternalReference expects r3 to contain the number of arguments
|
||||
// including the receiver and the extra arguments.
|
||||
__ addi(r3, r3, Operand(num_extra_args + 1));
|
||||
|
@ -15,8 +15,7 @@ namespace internal {
|
||||
|
||||
#define __ ACCESS_MASM(masm)
|
||||
|
||||
void Builtins::Generate_Adaptor(MacroAssembler* masm, CFunctionId id,
|
||||
BuiltinExtraArguments extra_args) {
|
||||
void Builtins::Generate_Adaptor(MacroAssembler* masm, CFunctionId id) {
|
||||
// ----------- S t a t e -------------
|
||||
// -- r2 : number of arguments excluding receiver
|
||||
// -- r3 : target
|
||||
@ -35,24 +34,8 @@ void Builtins::Generate_Adaptor(MacroAssembler* masm, CFunctionId id,
|
||||
__ LoadP(cp, FieldMemOperand(r3, JSFunction::kContextOffset));
|
||||
|
||||
// Insert extra arguments.
|
||||
int num_extra_args = 0;
|
||||
switch (extra_args) {
|
||||
case BuiltinExtraArguments::kTarget:
|
||||
__ Push(r3);
|
||||
++num_extra_args;
|
||||
break;
|
||||
case BuiltinExtraArguments::kNewTarget:
|
||||
__ Push(r5);
|
||||
++num_extra_args;
|
||||
break;
|
||||
case BuiltinExtraArguments::kTargetAndNewTarget:
|
||||
__ Push(r3, r5);
|
||||
num_extra_args += 2;
|
||||
break;
|
||||
case BuiltinExtraArguments::kNone:
|
||||
break;
|
||||
}
|
||||
|
||||
const int num_extra_args = 2;
|
||||
__ Push(r3, r5);
|
||||
// JumpToExternalReference expects r2 to contain the number of arguments
|
||||
// including the receiver and the extra arguments.
|
||||
__ AddP(r2, r2, Operand(num_extra_args + 1));
|
||||
|
Loading…
Reference in New Issue
Block a user