Revert^2 "Add support for calling entry / exit hooks directly from JIT code""
This reverts commit 72be14ed06b76cd0e83392145cec9025ff43d174.
Reason for revert: A reland of
commit 2d4feeb67912d64b9e980e6687794826a5c22f9d with a fix for no-image
tests
Change-Id: I79f719f0d4d9b903db301a1636fde5689da35a29
diff --git a/openjdkjvmti/deopt_manager.cc b/openjdkjvmti/deopt_manager.cc
index bf1b4f0..cf28a71 100644
--- a/openjdkjvmti/deopt_manager.cc
+++ b/openjdkjvmti/deopt_manager.cc
@@ -492,7 +492,12 @@
art::gc::GcCause::kGcCauseDebugger,
art::gc::CollectorType::kCollectorTypeDebugger);
art::ScopedSuspendAll ssa("Instrument thread stack");
- art::Runtime::Current()->GetInstrumentation()->InstrumentThreadStack(target);
+ // Prepare the stack so methods can be deoptimized as and when required.
+ // This by itself doesn't cause any methods to deoptimize but enables
+ // deoptimization on demand.
+ art::Runtime::Current()->GetInstrumentation()->InstrumentThreadStack(
+ target,
+ /* deopt_all_frames= */ false);
}
extern DeoptManager* gDeoptManager;