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

Unified Diff: src/api.cc

Issue 2788413004: [inspector] cache stack frame for call sites (Closed)
Patch Set: rebased Created 3 years, 8 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 | « include/v8.h ('k') | src/ast/ast-types.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/api.cc
diff --git a/src/api.cc b/src/api.cc
index 4d7a4658f0618ec79a557f74f212ca2250cfd57e..c8d3c2170bde104eb800ab3a7e46a8734531d38a 100644
--- a/src/api.cc
+++ b/src/api.cc
@@ -8686,7 +8686,6 @@ bool Isolate::IdleNotificationDeadline(double deadline_in_seconds) {
return isolate->heap()->IdleNotification(deadline_in_seconds);
}
-
void Isolate::LowMemoryNotification() {
i::Isolate* isolate = reinterpret_cast<i::Isolate*>(this);
{
@@ -8696,6 +8695,15 @@ void Isolate::LowMemoryNotification() {
isolate->heap()->CollectAllAvailableGarbage(
i::GarbageCollectionReason::kLowMemoryNotification);
}
+ {
+ i::HeapIterator iterator(isolate->heap());
+ i::HeapObject* obj;
+ while ((obj = iterator.next()) != nullptr) {
+ if (obj->IsCode() || obj->IsBytecodeArray()) {
Yang 2017/04/11 13:09:46 IsAbstractCode
kozy 2017/04/12 15:05:17 Done.
+ i::AbstractCode::cast(obj)->DropStackFrameCache();
+ }
+ }
+ }
}
« no previous file with comments | « include/v8.h ('k') | src/ast/ast-types.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698