Index: src/debug/debug.cc |
diff --git a/src/debug/debug.cc b/src/debug/debug.cc |
index db2ccf71848065387009d2ff10b62efffbd17da7..d2b12e5f859595abb80c9e8fa8d2e16f08f2ca27 100644 |
--- a/src/debug/debug.cc |
+++ b/src/debug/debug.cc |
@@ -1250,6 +1250,9 @@ bool Debug::PrepareFunctionForBreakPoints(Handle<SharedFunctionInfo> shared) { |
} |
} |
+ // The native context also has a list of OSR'd optimized code. Clear it. |
+ isolate_->ClearOSROptimizedCode(); |
+ |
// Make sure we abort incremental marking. |
isolate_->heap()->CollectAllGarbage(Heap::kMakeHeapIterableMask, |
GarbageCollectionReason::kDebugger); |