Revision: 22604
Author: [email protected]
Date: Thu Jul 24 14:41:27 2014 UTC
Log: Add a histogram timer around low memory notifications from API
BUG=397026
[email protected], [email protected]
LOG=n
Review URL: https://codereview.chromium.org/416853002
http://code.google.com/p/v8/source/detail?r=22604
Modified:
/branches/bleeding_edge/src/api.cc
/branches/bleeding_edge/src/counters.h
=======================================
--- /branches/bleeding_edge/src/api.cc Thu Jul 24 08:28:02 2014 UTC
+++ /branches/bleeding_edge/src/api.cc Thu Jul 24 14:41:27 2014 UTC
@@ -5063,7 +5063,11 @@
void v8::V8::LowMemoryNotification() {
i::Isolate* isolate = i::Isolate::Current();
if (isolate == NULL || !isolate->IsInitialized()) return;
- isolate->heap()->CollectAllAvailableGarbage("low memory notification");
+ {
+ i::HistogramTimerScope idle_notification_scope(
+ isolate->counters()->gc_low_memory_notification());
+ isolate->heap()->CollectAllAvailableGarbage("low memory notification");
+ }
}
@@ -6723,7 +6727,11 @@
void v8::Isolate::LowMemoryNotification() {
i::Isolate* isolate = reinterpret_cast<i::Isolate*>(this);
- isolate->heap()->CollectAllAvailableGarbage("low memory notification");
+ {
+ i::HistogramTimerScope idle_notification_scope(
+ isolate->counters()->gc_low_memory_notification());
+ isolate->heap()->CollectAllAvailableGarbage("low memory notification");
+ }
}
=======================================
--- /branches/bleeding_edge/src/counters.h Fri Jul 18 08:25:41 2014 UTC
+++ /branches/bleeding_edge/src/counters.h Thu Jul 24 14:41:27 2014 UTC
@@ -299,6 +299,7 @@
HT(gc_context, V8.GCContext) /* GC context cleanup time */ \
HT(gc_idle_notification, V8.GCIdleNotification) \
HT(gc_incremental_marking, V8.GCIncrementalMarking) \
+ HT(gc_low_memory_notification, V8.GCLowMemoryNotification) \
/* Parsing timers. */ \
HT(parse, V8.Parse) \
HT(parse_lazy, V8.ParseLazy) \
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.