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

Unified Diff: src/api.cc

Issue 2621873003: [heap, debugger] Introduce out-of-memory listener for debugger. (Closed)
Patch Set: remove isolate parameter of the callback Created 3 years, 11 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 | « no previous file | src/debug/debug-interface.h » ('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 dc51f3a2330ddbf059384be3fb2ba6ea9ec3bae7..0a178aed90cda7c0463e8bdd2eee907669ec4fc6 100644
--- a/src/api.cc
+++ b/src/api.cc
@@ -8819,7 +8819,6 @@ bool Debug::SetDebugEventListener(Isolate* isolate, EventCallback that,
return true;
}
-
void Debug::DebugBreak(Isolate* isolate) {
reinterpret_cast<i::Isolate*>(isolate)->stack_guard()->RequestDebugBreak();
}
@@ -8987,6 +8986,13 @@ void debug::ChangeBreakOnException(Isolate* isolate, ExceptionBreakState type) {
type != NoBreakOnException);
}
+void debug::SetOutOfMemoryCallback(Isolate* isolate,
+ OutOfMemoryCallback callback, void* data) {
+ i::Isolate* i_isolate = reinterpret_cast<i::Isolate*>(isolate);
+ ENTER_V8(i_isolate);
+ i_isolate->heap()->SetOutOfMemoryCallback(callback, data);
+}
+
void debug::PrepareStep(Isolate* v8_isolate, StepAction action) {
i::Isolate* isolate = reinterpret_cast<i::Isolate*>(v8_isolate);
ENTER_V8(isolate);
« no previous file with comments | « no previous file | src/debug/debug-interface.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698