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

Unified Diff: runtime/vm/jit_optimizer.cc

Issue 2894953002: Support inlining of calls where type arguments are passed to generic functions. (Closed)
Patch Set: address review comments Created 3 years, 5 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_test.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/jit_optimizer.cc
diff --git a/runtime/vm/jit_optimizer.cc b/runtime/vm/jit_optimizer.cc
index e0cb503d05b3f095cdc7a7da4d7b3d631cbed161..41c3341e42295e174595e6835f5b78c7806d3a01 100644
--- a/runtime/vm/jit_optimizer.cc
+++ b/runtime/vm/jit_optimizer.cc
@@ -98,10 +98,13 @@ bool JitOptimizer::TryCreateICData(InstanceCallInstr* call) {
return false;
}
+ const intptr_t receiver_index = call->FirstParamIndex();
GrowableArray<intptr_t> class_ids(call->ic_data()->NumArgsTested());
- ASSERT(call->ic_data()->NumArgsTested() <= call->ArgumentCount());
+ ASSERT(call->ic_data()->NumArgsTested() <=
+ call->ArgumentCountWithoutTypeArgs());
for (intptr_t i = 0; i < call->ic_data()->NumArgsTested(); i++) {
- class_ids.Add(call->PushArgumentAt(i)->value()->Type()->ToCid());
+ class_ids.Add(
+ call->PushArgumentAt(receiver_index + i)->value()->Type()->ToCid());
}
const Token::Kind op_kind = call->token_kind();
« no previous file with comments | « runtime/vm/intermediate_language_test.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698