[fullcodegen] Don't count CallIC calls as patching ICs.

In fullcodegen we used to count CallICs as patching ICs, and thus the
heuristics are currently off by the number of calls in a code object.

R=mvstanton@chromium.org

Review-Url: https://codereview.chromium.org/2408103002
Cr-Commit-Position: refs/heads/master@{#40163}
This commit is contained in:
bmeurer 2016-10-11 04:24:03 -07:00 committed by Commit bot
parent 9192db2037
commit 001926cdec
6 changed files with 12 additions and 24 deletions

View File

@ -2382,14 +2382,12 @@ void FullCodeGenerator::EmitCall(Call* expr, ConvertReceiverMode mode) {
// not return to this function.
EmitProfilingCounterHandlingForReturnSequence(true);
}
Handle<Code> ic =
Handle<Code> code =
CodeFactory::CallIC(isolate(), arg_count, mode, expr->tail_call_mode())
.code();
__ mov(r3, Operand(SmiFromSlot(expr->CallFeedbackICSlot())));
__ ldr(r1, MemOperand(sp, (arg_count + 1) * kPointerSize));
// Don't assign a type feedback id to the IC, since type feedback is provided
// by the vector above.
CallIC(ic);
__ Call(code, RelocInfo::CODE_TARGET);
OperandStackDepthDecrement(arg_count + 1);
RecordJSReturnSite(expr);

View File

@ -2284,14 +2284,12 @@ void FullCodeGenerator::EmitCall(Call* expr, ConvertReceiverMode mode) {
// not return to this function.
EmitProfilingCounterHandlingForReturnSequence(true);
}
Handle<Code> ic =
Handle<Code> code =
CodeFactory::CallIC(isolate(), arg_count, mode, expr->tail_call_mode())
.code();
__ Mov(x3, SmiFromSlot(expr->CallFeedbackICSlot()));
__ Peek(x1, (arg_count + 1) * kXRegSize);
// Don't assign a type feedback id to the IC, since type feedback is provided
// by the vector above.
CallIC(ic);
__ Call(code, RelocInfo::CODE_TARGET);
OperandStackDepthDecrement(arg_count + 1);
RecordJSReturnSite(expr);

View File

@ -2281,14 +2281,12 @@ void FullCodeGenerator::EmitCall(Call* expr, ConvertReceiverMode mode) {
// not return to this function.
EmitProfilingCounterHandlingForReturnSequence(true);
}
Handle<Code> ic =
Handle<Code> code =
CodeFactory::CallIC(isolate(), arg_count, mode, expr->tail_call_mode())
.code();
__ Move(edx, Immediate(SmiFromSlot(expr->CallFeedbackICSlot())));
__ mov(edi, Operand(esp, (arg_count + 1) * kPointerSize));
// Don't assign a type feedback id to the IC, since type feedback is provided
// by the vector above.
CallIC(ic);
__ call(code, RelocInfo::CODE_TARGET);
OperandStackDepthDecrement(arg_count + 1);
RecordJSReturnSite(expr);

View File

@ -2392,14 +2392,12 @@ void FullCodeGenerator::EmitCall(Call* expr, ConvertReceiverMode mode) {
// not return to this function.
EmitProfilingCounterHandlingForReturnSequence(true);
}
Handle<Code> ic =
Handle<Code> code =
CodeFactory::CallIC(isolate(), arg_count, mode, expr->tail_call_mode())
.code();
__ li(a3, Operand(SmiFromSlot(expr->CallFeedbackICSlot())));
__ lw(a1, MemOperand(sp, (arg_count + 1) * kPointerSize));
// Don't assign a type feedback id to the IC, since type feedback is provided
// by the vector above.
CallIC(ic);
__ Call(code, RelocInfo::CODE_TARGET);
OperandStackDepthDecrement(arg_count + 1);
RecordJSReturnSite(expr);

View File

@ -2391,14 +2391,12 @@ void FullCodeGenerator::EmitCall(Call* expr, ConvertReceiverMode mode) {
// not return to this function.
EmitProfilingCounterHandlingForReturnSequence(true);
}
Handle<Code> ic =
Handle<Code> code =
CodeFactory::CallIC(isolate(), arg_count, mode, expr->tail_call_mode())
.code();
__ li(a3, Operand(SmiFromSlot(expr->CallFeedbackICSlot())));
__ ld(a1, MemOperand(sp, (arg_count + 1) * kPointerSize));
// Don't assign a type feedback id to the IC, since type feedback is provided
// by the vector above.
CallIC(ic);
__ Call(code, RelocInfo::CODE_TARGET);
OperandStackDepthDecrement(arg_count + 1);
RecordJSReturnSite(expr);

View File

@ -2270,14 +2270,12 @@ void FullCodeGenerator::EmitCall(Call* expr, ConvertReceiverMode mode) {
// not return to this function.
EmitProfilingCounterHandlingForReturnSequence(true);
}
Handle<Code> ic =
Handle<Code> code =
CodeFactory::CallIC(isolate(), arg_count, mode, expr->tail_call_mode())
.code();
__ Move(rdx, SmiFromSlot(expr->CallFeedbackICSlot()));
__ movp(rdi, Operand(rsp, (arg_count + 1) * kPointerSize));
// Don't assign a type feedback id to the IC, since type feedback is provided
// by the vector above.
CallIC(ic);
__ call(code, RelocInfo::CODE_TARGET);
OperandStackDepthDecrement(arg_count + 1);
RecordJSReturnSite(expr);