Commit 572c231c authored by zhengxing.li's avatar zhengxing.li Committed by Commit bot

X87: [ic] Unify CallIC feedback collection and handling.

  port 308788b3 (r40397)

  original commit message:
  Consistently collect CallIC feedback in fullcodegen and Ignition, even
  for possibly direct eval calls, that were treated specially so far, for
  no apparent reason. With the upcoming SharedFunctionInfo based CallIC
  feedback, we might be able to even inline certain direct eval calls, if
  they manage to hit the eval cache. More importantly, this patch
  simplifies the collection and dealing with CallIC feedback (and as a
  side effect fixes an inconsistency with feedback for super constructor
  calls).

BUG=

Review-Url: https://chromiumcodereview.appspot.com/2429623005
Cr-Commit-Position: refs/heads/master@{#40416}
parent ea511e76
...@@ -2377,11 +2377,13 @@ void FullCodeGenerator::EmitPossiblyEvalCall(Call* expr) { ...@@ -2377,11 +2377,13 @@ void FullCodeGenerator::EmitPossiblyEvalCall(Call* expr) {
PrepareForBailoutForId(expr->EvalId(), BailoutState::NO_REGISTERS); PrepareForBailoutForId(expr->EvalId(), BailoutState::NO_REGISTERS);
SetCallPosition(expr); SetCallPosition(expr);
Handle<Code> code = CodeFactory::CallIC(isolate(), ConvertReceiverMode::kAny,
expr->tail_call_mode())
.code();
__ Move(edx, Immediate(SmiFromSlot(expr->CallFeedbackICSlot())));
__ mov(edi, Operand(esp, (arg_count + 1) * kPointerSize)); __ mov(edi, Operand(esp, (arg_count + 1) * kPointerSize));
__ Set(eax, arg_count); __ Move(eax, Immediate(arg_count));
__ Call(isolate()->builtins()->Call(ConvertReceiverMode::kAny, __ call(code, RelocInfo::CODE_TARGET);
expr->tail_call_mode()),
RelocInfo::CODE_TARGET);
OperandStackDepthDecrement(arg_count + 1); OperandStackDepthDecrement(arg_count + 1);
RecordJSReturnSite(expr); RecordJSReturnSite(expr);
RestoreContext(); RestoreContext();
......
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