Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(709)

Unified Diff: runtime/vm/intermediate_language_x64.cc

Issue 10910003: Only store IC data with instructions that collect type feedback. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/intermediate_language_ia32.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/intermediate_language_x64.cc
===================================================================
--- runtime/vm/intermediate_language_x64.cc (revision 11602)
+++ runtime/vm/intermediate_language_x64.cc (working copy)
@@ -2093,14 +2093,13 @@
void PolymorphicInstanceCallComp::EmitNativeCode(FlowGraphCompiler* compiler) {
Label* deopt = compiler->AddDeoptStub(instance_call()->deopt_id(),
kDeoptPolymorphicInstanceCallTestFail);
- if (!HasICData() || (ic_data()->NumberOfChecks() == 0)) {
+ if (ic_data().NumberOfChecks() == 0) {
__ jmp(deopt);
return;
}
- ASSERT(HasICData());
- ASSERT(ic_data()->num_args_tested() == 1);
+ ASSERT(ic_data().num_args_tested() == 1);
if (!with_checks()) {
- const Function& target = Function::ZoneHandle(ic_data()->GetTargetAt(0));
+ const Function& target = Function::ZoneHandle(ic_data().GetTargetAt(0));
compiler->GenerateStaticCall(instance_call()->deopt_id(),
instance_call()->token_pos(),
target,
@@ -2119,7 +2118,7 @@
__ j(ZERO, &done);
__ LoadClassId(RDI, RAX);
__ Bind(&done);
- compiler->EmitTestAndCall(*ic_data(),
+ compiler->EmitTestAndCall(ic_data(),
RDI, // Class id register.
instance_call()->ArgumentCount(),
instance_call()->argument_names(),
@@ -2151,15 +2150,15 @@
Register temp = locs()->temp(0).reg();
Label* deopt = compiler->AddDeoptStub(deopt_id(),
kDeoptCheckClass);
- ASSERT(ic_data()->GetReceiverClassIdAt(0) != kSmiCid);
+ ASSERT(unary_checks().GetReceiverClassIdAt(0) != kSmiCid);
__ testq(value, Immediate(kSmiTagMask));
__ j(ZERO, deopt);
__ LoadClassId(temp, value);
Label is_ok;
- const intptr_t num_checks = ic_data()->NumberOfChecks();
+ const intptr_t num_checks = unary_checks().NumberOfChecks();
const bool use_near_jump = num_checks < 5;
for (intptr_t i = 0; i < num_checks; i++) {
- __ cmpl(temp, Immediate(ic_data()->GetReceiverClassIdAt(i)));
+ __ cmpl(temp, Immediate(unary_checks().GetReceiverClassIdAt(i)));
if (i == (num_checks - 1)) {
__ j(NOT_EQUAL, deopt);
} else {
« no previous file with comments | « runtime/vm/intermediate_language_ia32.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698