From d9e8377d188b2ca0f71185ec3fecb241392184e0 Mon Sep 17 00:00:00 2001 From: Mythri Alle Date: Thu, 14 Jul 2022 09:38:49 +0000 Subject: Reland "Introduce a flag to check if JITed code has instrumentation support" This reverts commit 26aef1213dbdd7ab03688d898cf802c8c8d7e610. Reason for revert: Relanding after a fix. When checking if the caller is deoptimizaeble we should consider the outer caller and not the inlined method that we could be executing currently. Bug: 222479430 Change-Id: I37cbc8f1b34113a36a92c3801db72b16d2b9c81a --- runtime/quick_exception_handler.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'runtime/quick_exception_handler.cc') diff --git a/runtime/quick_exception_handler.cc b/runtime/quick_exception_handler.cc index 40a1c16905..8029c03315 100644 --- a/runtime/quick_exception_handler.cc +++ b/runtime/quick_exception_handler.cc @@ -406,7 +406,8 @@ class DeoptimizeStackVisitor final : public StackVisitor { callee_method_ = method; return true; } else if (!single_frame_deopt_ && - !Runtime::Current()->IsAsyncDeoptimizeable(GetCurrentQuickFramePc())) { + !Runtime::Current()->IsAsyncDeoptimizeable(GetOuterMethod(), + GetCurrentQuickFramePc())) { // We hit some code that's not deoptimizeable. However, Single-frame deoptimization triggered // from compiled code is always allowed since HDeoptimize always saves the full environment. LOG(WARNING) << "Got request to deoptimize un-deoptimizable method " -- cgit v1.2.3-59-g8ed1b