Unbreak compilation on MIPS after EmitCallIC removal.

Note: It has only been verified that compilation is OK, nothing more... ;-)
Review URL: http://codereview.chromium.org/7273097

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8493 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 8a3d8b41
...@@ -796,7 +796,7 @@ void FullCodeGenerator::EmitDeclaration(Variable* variable, ...@@ -796,7 +796,7 @@ void FullCodeGenerator::EmitDeclaration(Variable* variable,
Handle<Code> ic = is_strict_mode() Handle<Code> ic = is_strict_mode()
? isolate()->builtins()->KeyedStoreIC_Initialize_Strict() ? isolate()->builtins()->KeyedStoreIC_Initialize_Strict()
: isolate()->builtins()->KeyedStoreIC_Initialize(); : isolate()->builtins()->KeyedStoreIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET, AstNode::kNoNumber); __ CallWithAstId(ic);
// Value in v0 is ignored (declarations are statements). // Value in v0 is ignored (declarations are statements).
} }
} }
...@@ -871,7 +871,7 @@ void FullCodeGenerator::VisitSwitchStatement(SwitchStatement* stmt) { ...@@ -871,7 +871,7 @@ void FullCodeGenerator::VisitSwitchStatement(SwitchStatement* stmt) {
// Record position before stub call for type feedback. // Record position before stub call for type feedback.
SetSourcePosition(clause->position()); SetSourcePosition(clause->position());
Handle<Code> ic = CompareIC::GetUninitialized(Token::EQ_STRICT); Handle<Code> ic = CompareIC::GetUninitialized(Token::EQ_STRICT);
EmitCallIC(ic, RelocInfo::CODE_TARGET, clause->CompareId()); __ CallWithAstId(ic, RelocInfo::CODE_TARGET, clause->CompareId());
patch_site.EmitPatchInfo(); patch_site.EmitPatchInfo();
__ Branch(&next_test, ne, v0, Operand(zero_reg)); __ Branch(&next_test, ne, v0, Operand(zero_reg));
...@@ -1171,7 +1171,7 @@ void FullCodeGenerator::EmitLoadGlobalSlotCheckExtensions( ...@@ -1171,7 +1171,7 @@ void FullCodeGenerator::EmitLoadGlobalSlotCheckExtensions(
? RelocInfo::CODE_TARGET ? RelocInfo::CODE_TARGET
: RelocInfo::CODE_TARGET_CONTEXT; : RelocInfo::CODE_TARGET_CONTEXT;
Handle<Code> ic = isolate()->builtins()->LoadIC_Initialize(); Handle<Code> ic = isolate()->builtins()->LoadIC_Initialize();
EmitCallIC(ic, mode, AstNode::kNoNumber); __ CallWithAstId(ic, mode);
} }
...@@ -1251,7 +1251,7 @@ void FullCodeGenerator::EmitDynamicLoadFromSlotFastCase( ...@@ -1251,7 +1251,7 @@ void FullCodeGenerator::EmitDynamicLoadFromSlotFastCase(
__ li(a0, Operand(key_literal->handle())); __ li(a0, Operand(key_literal->handle()));
Handle<Code> ic = Handle<Code> ic =
isolate()->builtins()->KeyedLoadIC_Initialize(); isolate()->builtins()->KeyedLoadIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET, GetPropertyId(property)); __ CallWithAstId(ic, RelocInfo::CODE_TARGET, GetPropertyId(property));
__ Branch(done); __ Branch(done);
} }
} }
...@@ -1273,7 +1273,7 @@ void FullCodeGenerator::EmitVariableLoad(Variable* var) { ...@@ -1273,7 +1273,7 @@ void FullCodeGenerator::EmitVariableLoad(Variable* var) {
__ lw(a0, GlobalObjectOperand()); __ lw(a0, GlobalObjectOperand());
__ li(a2, Operand(var->name())); __ li(a2, Operand(var->name()));
Handle<Code> ic = isolate()->builtins()->LoadIC_Initialize(); Handle<Code> ic = isolate()->builtins()->LoadIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET_CONTEXT, AstNode::kNoNumber); __ CallWithAstId(ic, RelocInfo::CODE_TARGET_CONTEXT);
context()->Plug(v0); context()->Plug(v0);
} else if (slot->type() == Slot::LOOKUP) { } else if (slot->type() == Slot::LOOKUP) {
...@@ -1419,7 +1419,7 @@ void FullCodeGenerator::VisitObjectLiteral(ObjectLiteral* expr) { ...@@ -1419,7 +1419,7 @@ void FullCodeGenerator::VisitObjectLiteral(ObjectLiteral* expr) {
Handle<Code> ic = is_strict_mode() Handle<Code> ic = is_strict_mode()
? isolate()->builtins()->StoreIC_Initialize_Strict() ? isolate()->builtins()->StoreIC_Initialize_Strict()
: isolate()->builtins()->StoreIC_Initialize(); : isolate()->builtins()->StoreIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET, key->id()); __ CallWithAstId(ic, RelocInfo::CODE_TARGET, key->id());
PrepareForBailoutForId(key->id(), NO_REGISTERS); PrepareForBailoutForId(key->id(), NO_REGISTERS);
} else { } else {
VisitForEffect(value); VisitForEffect(value);
...@@ -1663,7 +1663,7 @@ void FullCodeGenerator::EmitNamedPropertyLoad(Property* prop) { ...@@ -1663,7 +1663,7 @@ void FullCodeGenerator::EmitNamedPropertyLoad(Property* prop) {
__ li(a2, Operand(key->handle())); __ li(a2, Operand(key->handle()));
// Call load IC. It has arguments receiver and property name a0 and a2. // Call load IC. It has arguments receiver and property name a0 and a2.
Handle<Code> ic = isolate()->builtins()->LoadIC_Initialize(); Handle<Code> ic = isolate()->builtins()->LoadIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET, GetPropertyId(prop)); __ CallWithAstId(ic, RelocInfo::CODE_TARGET, GetPropertyId(prop));
} }
...@@ -1672,7 +1672,7 @@ void FullCodeGenerator::EmitKeyedPropertyLoad(Property* prop) { ...@@ -1672,7 +1672,7 @@ void FullCodeGenerator::EmitKeyedPropertyLoad(Property* prop) {
__ mov(a0, result_register()); __ mov(a0, result_register());
// Call keyed load IC. It has arguments key and receiver in a0 and a1. // Call keyed load IC. It has arguments key and receiver in a0 and a1.
Handle<Code> ic = isolate()->builtins()->KeyedLoadIC_Initialize(); Handle<Code> ic = isolate()->builtins()->KeyedLoadIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET, GetPropertyId(prop)); __ CallWithAstId(ic, RelocInfo::CODE_TARGET, GetPropertyId(prop));
} }
...@@ -1700,7 +1700,7 @@ void FullCodeGenerator::EmitInlineSmiBinaryOp(BinaryOperation* expr, ...@@ -1700,7 +1700,7 @@ void FullCodeGenerator::EmitInlineSmiBinaryOp(BinaryOperation* expr,
__ bind(&stub_call); __ bind(&stub_call);
BinaryOpStub stub(op, mode); BinaryOpStub stub(op, mode);
EmitCallIC(stub.GetCode(), RelocInfo::CODE_TARGET, expr->id()); __ CallWithAstId(stub.GetCode(), RelocInfo::CODE_TARGET, expr->id());
patch_site.EmitPatchInfo(); patch_site.EmitPatchInfo();
__ jmp(&done); __ jmp(&done);
...@@ -1783,7 +1783,7 @@ void FullCodeGenerator::EmitBinaryOp(BinaryOperation* expr, ...@@ -1783,7 +1783,7 @@ void FullCodeGenerator::EmitBinaryOp(BinaryOperation* expr,
__ pop(a1); __ pop(a1);
BinaryOpStub stub(op, mode); BinaryOpStub stub(op, mode);
JumpPatchSite patch_site(masm_); // unbound, signals no inlined smi code. JumpPatchSite patch_site(masm_); // unbound, signals no inlined smi code.
EmitCallIC(stub.GetCode(), RelocInfo::CODE_TARGET, expr->id()); __ CallWithAstId(stub.GetCode(), RelocInfo::CODE_TARGET, expr->id());
patch_site.EmitPatchInfo(); patch_site.EmitPatchInfo();
context()->Plug(v0); context()->Plug(v0);
} }
...@@ -1824,7 +1824,7 @@ void FullCodeGenerator::EmitAssignment(Expression* expr, int bailout_ast_id) { ...@@ -1824,7 +1824,7 @@ void FullCodeGenerator::EmitAssignment(Expression* expr, int bailout_ast_id) {
Handle<Code> ic = is_strict_mode() Handle<Code> ic = is_strict_mode()
? isolate()->builtins()->StoreIC_Initialize_Strict() ? isolate()->builtins()->StoreIC_Initialize_Strict()
: isolate()->builtins()->StoreIC_Initialize(); : isolate()->builtins()->StoreIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET, AstNode::kNoNumber); __ CallWithAstId(ic);
break; break;
} }
case KEYED_PROPERTY: { case KEYED_PROPERTY: {
...@@ -1837,7 +1837,7 @@ void FullCodeGenerator::EmitAssignment(Expression* expr, int bailout_ast_id) { ...@@ -1837,7 +1837,7 @@ void FullCodeGenerator::EmitAssignment(Expression* expr, int bailout_ast_id) {
Handle<Code> ic = is_strict_mode() Handle<Code> ic = is_strict_mode()
? isolate()->builtins()->KeyedStoreIC_Initialize_Strict() ? isolate()->builtins()->KeyedStoreIC_Initialize_Strict()
: isolate()->builtins()->KeyedStoreIC_Initialize(); : isolate()->builtins()->KeyedStoreIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET, AstNode::kNoNumber); __ CallWithAstId(ic);
break; break;
} }
} }
...@@ -1862,7 +1862,7 @@ void FullCodeGenerator::EmitVariableAssignment(Variable* var, ...@@ -1862,7 +1862,7 @@ void FullCodeGenerator::EmitVariableAssignment(Variable* var,
Handle<Code> ic = is_strict_mode() Handle<Code> ic = is_strict_mode()
? isolate()->builtins()->StoreIC_Initialize_Strict() ? isolate()->builtins()->StoreIC_Initialize_Strict()
: isolate()->builtins()->StoreIC_Initialize(); : isolate()->builtins()->StoreIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET_CONTEXT, AstNode::kNoNumber); __ CallWithAstId(ic, RelocInfo::CODE_TARGET_CONTEXT);
} else if (op == Token::INIT_CONST) { } else if (op == Token::INIT_CONST) {
// Like var declarations, const declarations are hoisted to function // Like var declarations, const declarations are hoisted to function
...@@ -1960,7 +1960,7 @@ void FullCodeGenerator::EmitNamedPropertyAssignment(Assignment* expr) { ...@@ -1960,7 +1960,7 @@ void FullCodeGenerator::EmitNamedPropertyAssignment(Assignment* expr) {
Handle<Code> ic = is_strict_mode() Handle<Code> ic = is_strict_mode()
? isolate()->builtins()->StoreIC_Initialize_Strict() ? isolate()->builtins()->StoreIC_Initialize_Strict()
: isolate()->builtins()->StoreIC_Initialize(); : isolate()->builtins()->StoreIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET, expr->id()); __ CallWithAstId(ic, RelocInfo::CODE_TARGET, expr->id());
// If the assignment ends an initialization block, revert to fast case. // If the assignment ends an initialization block, revert to fast case.
if (expr->ends_initialization_block()) { if (expr->ends_initialization_block()) {
...@@ -2012,7 +2012,7 @@ void FullCodeGenerator::EmitKeyedPropertyAssignment(Assignment* expr) { ...@@ -2012,7 +2012,7 @@ void FullCodeGenerator::EmitKeyedPropertyAssignment(Assignment* expr) {
Handle<Code> ic = is_strict_mode() Handle<Code> ic = is_strict_mode()
? isolate()->builtins()->KeyedStoreIC_Initialize_Strict() ? isolate()->builtins()->KeyedStoreIC_Initialize_Strict()
: isolate()->builtins()->KeyedStoreIC_Initialize(); : isolate()->builtins()->KeyedStoreIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET, expr->id()); __ CallWithAstId(ic, RelocInfo::CODE_TARGET, expr->id());
// If the assignment ends an initialization block, revert to fast case. // If the assignment ends an initialization block, revert to fast case.
if (expr->ends_initialization_block()) { if (expr->ends_initialization_block()) {
...@@ -2065,7 +2065,7 @@ void FullCodeGenerator::EmitCallWithIC(Call* expr, ...@@ -2065,7 +2065,7 @@ void FullCodeGenerator::EmitCallWithIC(Call* expr,
InLoopFlag in_loop = (loop_depth() > 0) ? IN_LOOP : NOT_IN_LOOP; InLoopFlag in_loop = (loop_depth() > 0) ? IN_LOOP : NOT_IN_LOOP;
Handle<Code> ic = Handle<Code> ic =
isolate()->stub_cache()->ComputeCallInitialize(arg_count, in_loop, mode); isolate()->stub_cache()->ComputeCallInitialize(arg_count, in_loop, mode);
EmitCallIC(ic, mode, expr->id()); __ CallWithAstId(ic, mode, expr->id());
RecordJSReturnSite(expr); RecordJSReturnSite(expr);
// Restore context register. // Restore context register.
__ lw(cp, MemOperand(fp, StandardFrameConstants::kContextOffset)); __ lw(cp, MemOperand(fp, StandardFrameConstants::kContextOffset));
...@@ -2099,7 +2099,7 @@ void FullCodeGenerator::EmitKeyedCallWithIC(Call* expr, ...@@ -2099,7 +2099,7 @@ void FullCodeGenerator::EmitKeyedCallWithIC(Call* expr,
Handle<Code> ic = Handle<Code> ic =
isolate()->stub_cache()->ComputeKeyedCallInitialize(arg_count, in_loop); isolate()->stub_cache()->ComputeKeyedCallInitialize(arg_count, in_loop);
__ lw(a2, MemOperand(sp, (arg_count + 1) * kPointerSize)); // Key. __ lw(a2, MemOperand(sp, (arg_count + 1) * kPointerSize)); // Key.
EmitCallIC(ic, RelocInfo::CODE_TARGET, expr->id()); __ CallWithAstId(ic, RelocInfo::CODE_TARGET, expr->id());
RecordJSReturnSite(expr); RecordJSReturnSite(expr);
// Restore context register. // Restore context register.
__ lw(cp, MemOperand(fp, StandardFrameConstants::kContextOffset)); __ lw(cp, MemOperand(fp, StandardFrameConstants::kContextOffset));
...@@ -2280,7 +2280,7 @@ void FullCodeGenerator::VisitCall(Call* expr) { ...@@ -2280,7 +2280,7 @@ void FullCodeGenerator::VisitCall(Call* expr) {
} else { } else {
// Call to a keyed property. // Call to a keyed property.
// For a synthetic property use keyed load IC followed by function call, // For a synthetic property use keyed load IC followed by function call,
// for a regular property use keyed EmitCallIC. // for a regular property use EmitKeyedCallWithIC.
if (prop->is_synthetic()) { if (prop->is_synthetic()) {
// Do not visit the object and key subexpressions (they are shared // Do not visit the object and key subexpressions (they are shared
// by all occurrences of the same rewritten parameter). // by all occurrences of the same rewritten parameter).
...@@ -2298,7 +2298,7 @@ void FullCodeGenerator::VisitCall(Call* expr) { ...@@ -2298,7 +2298,7 @@ void FullCodeGenerator::VisitCall(Call* expr) {
SetSourcePosition(prop->position()); SetSourcePosition(prop->position());
Handle<Code> ic = isolate()->builtins()->KeyedLoadIC_Initialize(); Handle<Code> ic = isolate()->builtins()->KeyedLoadIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET, GetPropertyId(prop)); __ CallWithAstId(ic, RelocInfo::CODE_TARGET, GetPropertyId(prop));
__ lw(a1, GlobalObjectOperand()); __ lw(a1, GlobalObjectOperand());
__ lw(a1, FieldMemOperand(a1, GlobalObject::kGlobalReceiverOffset)); __ lw(a1, FieldMemOperand(a1, GlobalObject::kGlobalReceiverOffset));
__ Push(v0, a1); // Function, receiver. __ Push(v0, a1); // Function, receiver.
...@@ -3628,7 +3628,7 @@ void FullCodeGenerator::VisitCallRuntime(CallRuntime* expr) { ...@@ -3628,7 +3628,7 @@ void FullCodeGenerator::VisitCallRuntime(CallRuntime* expr) {
isolate()->stub_cache()->ComputeCallInitialize(arg_count, isolate()->stub_cache()->ComputeCallInitialize(arg_count,
NOT_IN_LOOP, NOT_IN_LOOP,
mode); mode);
EmitCallIC(ic, mode, expr->id()); __ CallWithAstId(ic, mode, expr->id());
// Restore context register. // Restore context register.
__ lw(cp, MemOperand(fp, StandardFrameConstants::kContextOffset)); __ lw(cp, MemOperand(fp, StandardFrameConstants::kContextOffset));
} else { } else {
...@@ -3771,7 +3771,7 @@ void FullCodeGenerator::EmitUnaryOperation(UnaryOperation* expr, ...@@ -3771,7 +3771,7 @@ void FullCodeGenerator::EmitUnaryOperation(UnaryOperation* expr,
VisitForAccumulatorValue(expr->expression()); VisitForAccumulatorValue(expr->expression());
SetSourcePosition(expr->position()); SetSourcePosition(expr->position());
__ mov(a0, result_register()); __ mov(a0, result_register());
EmitCallIC(stub.GetCode(), RelocInfo::CODE_TARGET, expr->id()); __ CallWithAstId(stub.GetCode(), RelocInfo::CODE_TARGET, expr->id());
context()->Plug(v0); context()->Plug(v0);
} }
...@@ -3882,7 +3882,7 @@ void FullCodeGenerator::VisitCountOperation(CountOperation* expr) { ...@@ -3882,7 +3882,7 @@ void FullCodeGenerator::VisitCountOperation(CountOperation* expr) {
SetSourcePosition(expr->position()); SetSourcePosition(expr->position());
BinaryOpStub stub(Token::ADD, NO_OVERWRITE); BinaryOpStub stub(Token::ADD, NO_OVERWRITE);
EmitCallIC(stub.GetCode(), RelocInfo::CODE_TARGET, expr->CountId()); __ CallWithAstId(stub.GetCode(), RelocInfo::CODE_TARGET, expr->CountId());
patch_site.EmitPatchInfo(); patch_site.EmitPatchInfo();
__ bind(&done); __ bind(&done);
...@@ -3915,7 +3915,7 @@ void FullCodeGenerator::VisitCountOperation(CountOperation* expr) { ...@@ -3915,7 +3915,7 @@ void FullCodeGenerator::VisitCountOperation(CountOperation* expr) {
Handle<Code> ic = is_strict_mode() Handle<Code> ic = is_strict_mode()
? isolate()->builtins()->StoreIC_Initialize_Strict() ? isolate()->builtins()->StoreIC_Initialize_Strict()
: isolate()->builtins()->StoreIC_Initialize(); : isolate()->builtins()->StoreIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET, expr->id()); __ CallWithAstId(ic, RelocInfo::CODE_TARGET, expr->id());
PrepareForBailoutForId(expr->AssignmentId(), TOS_REG); PrepareForBailoutForId(expr->AssignmentId(), TOS_REG);
if (expr->is_postfix()) { if (expr->is_postfix()) {
if (!context()->IsEffect()) { if (!context()->IsEffect()) {
...@@ -3933,7 +3933,7 @@ void FullCodeGenerator::VisitCountOperation(CountOperation* expr) { ...@@ -3933,7 +3933,7 @@ void FullCodeGenerator::VisitCountOperation(CountOperation* expr) {
Handle<Code> ic = is_strict_mode() Handle<Code> ic = is_strict_mode()
? isolate()->builtins()->KeyedStoreIC_Initialize_Strict() ? isolate()->builtins()->KeyedStoreIC_Initialize_Strict()
: isolate()->builtins()->KeyedStoreIC_Initialize(); : isolate()->builtins()->KeyedStoreIC_Initialize();
EmitCallIC(ic, RelocInfo::CODE_TARGET, expr->id()); __ CallWithAstId(ic, RelocInfo::CODE_TARGET, expr->id());
PrepareForBailoutForId(expr->AssignmentId(), TOS_REG); PrepareForBailoutForId(expr->AssignmentId(), TOS_REG);
if (expr->is_postfix()) { if (expr->is_postfix()) {
if (!context()->IsEffect()) { if (!context()->IsEffect()) {
...@@ -3957,7 +3957,7 @@ void FullCodeGenerator::VisitForTypeofValue(Expression* expr) { ...@@ -3957,7 +3957,7 @@ void FullCodeGenerator::VisitForTypeofValue(Expression* expr) {
Handle<Code> ic = isolate()->builtins()->LoadIC_Initialize(); Handle<Code> ic = isolate()->builtins()->LoadIC_Initialize();
// Use a regular load, not a contextual load, to avoid a reference // Use a regular load, not a contextual load, to avoid a reference
// error. // error.
EmitCallIC(ic, RelocInfo::CODE_TARGET, AstNode::kNoNumber); __ CallWithAstId(ic);
PrepareForBailout(expr, TOS_REG); PrepareForBailout(expr, TOS_REG);
context()->Plug(v0); context()->Plug(v0);
} else if (proxy != NULL && } else if (proxy != NULL &&
...@@ -4154,7 +4154,7 @@ void FullCodeGenerator::VisitCompareOperation(CompareOperation* expr) { ...@@ -4154,7 +4154,7 @@ void FullCodeGenerator::VisitCompareOperation(CompareOperation* expr) {
// Record position and call the compare IC. // Record position and call the compare IC.
SetSourcePosition(expr->position()); SetSourcePosition(expr->position());
Handle<Code> ic = CompareIC::GetUninitialized(op); Handle<Code> ic = CompareIC::GetUninitialized(op);
EmitCallIC(ic, RelocInfo::CODE_TARGET, expr->id()); __ CallWithAstId(ic, RelocInfo::CODE_TARGET, expr->id());
patch_site.EmitPatchInfo(); patch_site.EmitPatchInfo();
PrepareForBailoutBeforeSplit(TOS_REG, true, if_true, if_false); PrepareForBailoutBeforeSplit(TOS_REG, true, if_true, if_false);
Split(cc, v0, Operand(zero_reg), if_true, if_false, fall_through); Split(cc, v0, Operand(zero_reg), if_true, if_false, fall_through);
...@@ -4214,20 +4214,6 @@ Register FullCodeGenerator::context_register() { ...@@ -4214,20 +4214,6 @@ Register FullCodeGenerator::context_register() {
} }
void FullCodeGenerator::EmitCallIC(Handle<Code> ic,
RelocInfo::Mode mode,
unsigned ast_id) {
ASSERT(mode == RelocInfo::CODE_TARGET ||
mode == RelocInfo::CODE_TARGET_CONTEXT);
if (ast_id == kNoASTId || mode == RelocInfo::CODE_TARGET_CONTEXT) {
__ Call(ic, mode);
} else {
ASSERT(mode == RelocInfo::CODE_TARGET);
__ CallWithAstId(ic, RelocInfo::CODE_TARGET_WITH_ID, ast_id);
}
}
void FullCodeGenerator::StoreToFrameField(int frame_offset, Register value) { void FullCodeGenerator::StoreToFrameField(int frame_offset, Register value) {
ASSERT_EQ(POINTER_SIZE_ALIGN(frame_offset), frame_offset); ASSERT_EQ(POINTER_SIZE_ALIGN(frame_offset), frame_offset);
__ sw(value, MemOperand(fp, frame_offset)); __ sw(value, MemOperand(fp, frame_offset));
......
...@@ -2088,10 +2088,12 @@ void MacroAssembler::CallWithAstId(Handle<Code> code, ...@@ -2088,10 +2088,12 @@ void MacroAssembler::CallWithAstId(Handle<Code> code,
Condition cond, Condition cond,
Register r1, Register r1,
const Operand& r2) { const Operand& r2) {
ASSERT(rmode == RelocInfo::CODE_TARGET_WITH_ID); ASSERT(RelocInfo::IsCodeTarget(rmode));
ASSERT(ast_id != kNoASTId); if (rmode == RelocInfo::CODE_TARGET && ast_id != kNoASTId) {
ASSERT(ast_id_for_reloc_info_ == kNoASTId); ASSERT(ast_id_for_reloc_info_ == kNoASTId);
ast_id_for_reloc_info_ = ast_id; ast_id_for_reloc_info_ = ast_id;
rmode = RelocInfo::CODE_TARGET_WITH_ID;
}
Call(reinterpret_cast<intptr_t>(code.location()), rmode, cond, r1, r2); Call(reinterpret_cast<intptr_t>(code.location()), rmode, cond, r1, r2);
} }
......
...@@ -181,8 +181,8 @@ DECLARE_NOTARGET_PROTOTYPE(Ret) ...@@ -181,8 +181,8 @@ DECLARE_NOTARGET_PROTOTYPE(Ret)
#undef DECLARE_BRANCH_PROTOTYPES #undef DECLARE_BRANCH_PROTOTYPES
void CallWithAstId(Handle<Code> code, void CallWithAstId(Handle<Code> code,
RelocInfo::Mode rmode, RelocInfo::Mode rmode = RelocInfo::CODE_TARGET,
unsigned ast_id, unsigned ast_id = kNoASTId,
Condition cond = al, Condition cond = al,
Register r1 = zero_reg, Register r1 = zero_reg,
const Operand& r2 = Operand(zero_reg)); const Operand& r2 = Operand(zero_reg));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment