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

Unified Diff: runtime/vm/jit_optimizer.cc

Issue 2897643002: Use Function::ZoneHandle for StaticCallInstr targets (Closed)
Patch Set: Created 3 years, 7 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/aot_optimizer.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 235f5ccfc890a42f544a12fe41fc4d76c400e560..151e187e1e5c7a1399fb2464b7729e493c05247d 100644
--- a/runtime/vm/jit_optimizer.cc
+++ b/runtime/vm/jit_optimizer.cc
@@ -1489,7 +1489,8 @@ void JitOptimizer::VisitInstanceCall(InstanceCallInstr* instr) {
}
if (has_one_target) {
- const Function& target = Function::Handle(Z, unary_checks.GetTargetAt(0));
+ const Function& target =
+ Function::ZoneHandle(Z, unary_checks.GetTargetAt(0));
const RawFunction::Kind function_kind = target.kind();
if (!flow_graph()->InstanceCallNeedsClassCheck(instr, function_kind)) {
StaticCallInstr* call = StaticCallInstr::FromCall(Z, instr, target);
@@ -1516,7 +1517,8 @@ void JitOptimizer::VisitInstanceCall(InstanceCallInstr* instr) {
// array, not the IC array.
AddReceiverCheck(instr);
// Call can still deoptimize, do not detach environment from instr.
- const Function& target = Function::Handle(Z, unary_checks.GetTargetAt(0));
+ const Function& target =
+ Function::ZoneHandle(Z, unary_checks.GetTargetAt(0));
StaticCallInstr* call = StaticCallInstr::FromCall(Z, instr, target);
instr->ReplaceWith(call, current_iterator());
} else {
« no previous file with comments | « runtime/vm/aot_optimizer.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698