diff options
| author | 2016-03-17 20:24:29 +0000 | |
|---|---|---|
| committer | 2016-03-17 20:24:30 +0000 | |
| commit | e9e98f12eb5dbe81db90d56c65c8872cabaa855d (patch) | |
| tree | ac547775549ac52c77739b6c6d7f496bf3fa288d /runtime/debugger.cc | |
| parent | 7f3397bec51bdeb7dfe76a17ea9d3279ddf79345 (diff) | |
| parent | f448016e70fa91269d3750384aab1ac98d7896fd (diff) | |
Merge "Do not JIT boot image during native-debugging (keep AOT code instead)."
Diffstat (limited to 'runtime/debugger.cc')
| -rw-r--r-- | runtime/debugger.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/runtime/debugger.cc b/runtime/debugger.cc index bc6589380c..c375bba4c3 100644 --- a/runtime/debugger.cc +++ b/runtime/debugger.cc @@ -622,9 +622,11 @@ void Dbg::GoActive() { } Runtime* runtime = Runtime::Current(); - // Since boot image code is AOT compiled as not debuggable, we need to patch + // Since boot image code may be AOT compiled as not debuggable, we need to patch // entry points of methods in boot image to interpreter bridge. - if (!runtime->GetInstrumentation()->IsForcedInterpretOnly()) { + // However, the performance cost of this is non-negligible during native-debugging due to the + // forced JIT, so we keep the AOT code in that case in exchange for limited native debugging. + if (!runtime->GetInstrumentation()->IsForcedInterpretOnly() && !runtime->IsNativeDebuggable()) { ScopedObjectAccess soa(self); UpdateEntryPointsClassVisitor visitor(runtime->GetInstrumentation()); runtime->GetClassLinker()->VisitClasses(&visitor); |