Author: jbeich
Date: Thu Dec  5 09:34:30 2013
New Revision: 1430

Log:
let firefox dump about:memory upon a signal

This allows to minimize footprint from about:memory itself in the
stats or to see them in case the UI is unresponsive.

Added:
   trunk/mail/thunderbird/files/patch-bug946560
   trunk/www/firefox-nightly/files/patch-bug946560
   trunk/www/firefox/files/patch-bug946560
   trunk/www/libxul/files/patch-bug946560
   trunk/www/seamonkey/files/patch-bug946560
Modified:
   trunk/Gecko_ChangeLog
   trunk/Gecko_TODO

Modified: trunk/Gecko_ChangeLog
==============================================================================
--- trunk/Gecko_ChangeLog       Thu Dec  5 04:23:42 2013        (r1429)
+++ trunk/Gecko_ChangeLog       Thu Dec  5 09:34:30 2013        (r1430)
@@ -8,6 +8,9 @@
   some flash sites work again; as there's no nspluginwrapper in-between
   the infamous "youtube issue" never occurs
 - install DEBUG with symbols [3] and describe the option better [4]
+- enable dumping about:memory upon kill -65, kill -66 and GC/CC log
+  upon kill -67 to a file under /tmp directory; linux-firefox uses
+  kill -34, kill -35 and kill -36 respectively
 
 PR:    ports/183861 [1], ports/184006 [2], ports/169896 [3]
        ports/184285 [3], ports/184286 [4]

Modified: trunk/Gecko_TODO
==============================================================================
--- trunk/Gecko_TODO    Thu Dec  5 04:23:42 2013        (r1429)
+++ trunk/Gecko_TODO    Thu Dec  5 09:34:30 2013        (r1430)
@@ -1,5 +1,4 @@
 unassigned (upstream):
-- xpcom/base/nsMemoryInfoDumper.cpp
 - resident-unique in xpcom/base/nsMemoryReporterManager.cpp
 - media/webrtc/trunk/webrtc/system_wrappers/source/cpu.cc
 - toolkit/crashreporter

Added: trunk/mail/thunderbird/files/patch-bug946560
==============================================================================
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ trunk/mail/thunderbird/files/patch-bug946560        Thu Dec  5 09:34:30 
2013        (r1430)
@@ -0,0 +1,44 @@
+diff --git xpcom/base/nsMemoryInfoDumper.cpp xpcom/base/nsMemoryInfoDumper.cpp
+index 0b2f78c..d857374 100644
+--- mozilla/xpcom/base/nsMemoryInfoDumper.cpp
++++ mozilla/xpcom/base/nsMemoryInfoDumper.cpp
+@@ -30,7 +30,7 @@
+ #include <unistd.h>
+ #endif
+ 
+-#ifdef XP_LINUX
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+ #include <fcntl.h>
+ #include <sys/types.h>
+ #include <sys/stat.h>
+@@ -109,7 +109,7 @@ private:
+ 
+ } // anonymous namespace
+ 
+-#ifdef XP_LINUX // {
++#if defined(XP_LINUX) || defined(__FreeBSD__) // {
+ namespace {
+ 
+ /*
+@@ -548,7 +548,7 @@ nsMemoryInfoDumper::~nsMemoryInfoDumper(
+ /* static */ void
+ nsMemoryInfoDumper::Initialize()
+ {
+-#ifdef XP_LINUX
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+   SignalPipeWatcher::Create();
+   FifoWatcher::MaybeCreate();
+ #endif
+diff --git xpcom/base/nsMemoryReporterManager.cpp 
xpcom/base/nsMemoryReporterManager.cpp
+index 8c65665..8f6d0e9 100644
+--- mozilla/xpcom/base/nsMemoryReporterManager.cpp
++++ mozilla/xpcom/base/nsMemoryReporterManager.cpp
+@@ -824,7 +824,7 @@ nsMemoryReporterManager::Init()
+     RegisterReporter(new mozilla::dmd::DMDReporter);
+ #endif
+ 
+-#if defined(XP_LINUX)
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+     nsMemoryInfoDumper::Initialize();
+ #endif
+ 

Added: trunk/www/firefox-nightly/files/patch-bug946560
==============================================================================
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ trunk/www/firefox-nightly/files/patch-bug946560     Thu Dec  5 09:34:30 
2013        (r1430)
@@ -0,0 +1,62 @@
+diff --git xpcom/base/nsMemoryInfoDumper.cpp xpcom/base/nsMemoryInfoDumper.cpp
+index 0b2f78c..d857374 100644
+--- xpcom/base/nsMemoryInfoDumper.cpp
++++ xpcom/base/nsMemoryInfoDumper.cpp
+@@ -6,7 +6,7 @@
+ 
+ #include "mozilla/nsMemoryInfoDumper.h"
+ 
+-#ifdef XP_LINUX
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+ #include "mozilla/Preferences.h"
+ #endif
+ #include "mozilla/unused.h"
+@@ -31,7 +31,7 @@
+ #include <unistd.h>
+ #endif
+ 
+-#ifdef XP_LINUX
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+ #include <fcntl.h>
+ #include <sys/types.h>
+ #include <sys/stat.h>
+@@ -110,7 +110,7 @@ private:
+ 
+ } // anonymous namespace
+ 
+-#ifdef XP_LINUX // {
++#if defined(XP_LINUX) || defined(__FreeBSD__) // {
+ namespace {
+ 
+ /*
+@@ -552,7 +552,7 @@ nsMemoryInfoDumper::~nsMemoryInfoDumper()
+ /* static */ void
+ nsMemoryInfoDumper::Initialize()
+ {
+-#ifdef XP_LINUX
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+   SignalPipeWatcher::Create();
+   FifoWatcher::MaybeCreate();
+ #endif
+diff --git xpcom/base/nsMemoryReporterManager.cpp 
xpcom/base/nsMemoryReporterManager.cpp
+index 8c65665..8f6d0e9 100644
+--- xpcom/base/nsMemoryReporterManager.cpp
++++ xpcom/base/nsMemoryReporterManager.cpp
+@@ -17,7 +17,7 @@
+ #include "nsPIDOMWindow.h"
+ #include "nsIObserverService.h"
+ #include "nsIGlobalObject.h"
+-#if defined(XP_LINUX)
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+ #include "nsMemoryInfoDumper.h"
+ #endif
+ #include "mozilla/Attributes.h"
+@@ -900,7 +900,7 @@ nsMemoryReporterManager::Init()
+     RegisterStrongReporter(new mozilla::dmd::DMDReporter());
+ #endif
+ 
+-#if defined(XP_LINUX)
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+     nsMemoryInfoDumper::Initialize();
+ #endif
+ 

Added: trunk/www/firefox/files/patch-bug946560
==============================================================================
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ trunk/www/firefox/files/patch-bug946560     Thu Dec  5 09:34:30 2013        
(r1430)
@@ -0,0 +1,44 @@
+diff --git xpcom/base/nsMemoryInfoDumper.cpp xpcom/base/nsMemoryInfoDumper.cpp
+index 0b2f78c..d857374 100644
+--- xpcom/base/nsMemoryInfoDumper.cpp
++++ xpcom/base/nsMemoryInfoDumper.cpp
+@@ -30,7 +30,7 @@
+ #include <unistd.h>
+ #endif
+ 
+-#ifdef XP_LINUX
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+ #include <fcntl.h>
+ #include <sys/types.h>
+ #include <sys/stat.h>
+@@ -109,7 +109,7 @@ private:
+ 
+ } // anonymous namespace
+ 
+-#ifdef XP_LINUX // {
++#if defined(XP_LINUX) || defined(__FreeBSD__) // {
+ namespace {
+ 
+ /*
+@@ -548,7 +548,7 @@ nsMemoryInfoDumper::~nsMemoryInfoDumper(
+ /* static */ void
+ nsMemoryInfoDumper::Initialize()
+ {
+-#ifdef XP_LINUX
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+   SignalPipeWatcher::Create();
+   FifoWatcher::MaybeCreate();
+ #endif
+diff --git xpcom/base/nsMemoryReporterManager.cpp 
xpcom/base/nsMemoryReporterManager.cpp
+index 8c65665..8f6d0e9 100644
+--- xpcom/base/nsMemoryReporterManager.cpp
++++ xpcom/base/nsMemoryReporterManager.cpp
+@@ -824,7 +824,7 @@ nsMemoryReporterManager::Init()
+     RegisterReporter(new mozilla::dmd::DMDReporter);
+ #endif
+ 
+-#if defined(XP_LINUX)
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+     nsMemoryInfoDumper::Initialize();
+ #endif
+ 

Added: trunk/www/libxul/files/patch-bug946560
==============================================================================
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ trunk/www/libxul/files/patch-bug946560      Thu Dec  5 09:34:30 2013        
(r1430)
@@ -0,0 +1,44 @@
+diff --git xpcom/base/nsMemoryInfoDumper.cpp xpcom/base/nsMemoryInfoDumper.cpp
+index 0b2f78c..d857374 100644
+--- xpcom/base/nsMemoryInfoDumper.cpp
++++ xpcom/base/nsMemoryInfoDumper.cpp
+@@ -30,7 +30,7 @@
+ #include <unistd.h>
+ #endif
+ 
+-#ifdef XP_LINUX
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+ #include <fcntl.h>
+ #include <sys/types.h>
+ #include <sys/stat.h>
+@@ -109,7 +109,7 @@ private:
+ 
+ } // anonymous namespace
+ 
+-#ifdef XP_LINUX // {
++#if defined(XP_LINUX) || defined(__FreeBSD__) // {
+ namespace {
+ 
+ /*
+@@ -548,7 +548,7 @@ nsMemoryInfoDumper::~nsMemoryInfoDumper(
+ /* static */ void
+ nsMemoryInfoDumper::Initialize()
+ {
+-#ifdef XP_LINUX
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+   SignalPipeWatcher::Create();
+   FifoWatcher::MaybeCreate();
+ #endif
+diff --git xpcom/base/nsMemoryReporterManager.cpp 
xpcom/base/nsMemoryReporterManager.cpp
+index 8c65665..8f6d0e9 100644
+--- xpcom/base/nsMemoryReporterManager.cpp
++++ xpcom/base/nsMemoryReporterManager.cpp
+@@ -824,7 +824,7 @@ nsMemoryReporterManager::Init()
+     RegisterReporter(new mozilla::dmd::DMDReporter);
+ #endif
+ 
+-#if defined(XP_LINUX)
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+     nsMemoryInfoDumper::Initialize();
+ #endif
+ 

Added: trunk/www/seamonkey/files/patch-bug946560
==============================================================================
--- /dev/null   00:00:00 1970   (empty, because file is newly added)
+++ trunk/www/seamonkey/files/patch-bug946560   Thu Dec  5 09:34:30 2013        
(r1430)
@@ -0,0 +1,44 @@
+diff --git xpcom/base/nsMemoryInfoDumper.cpp xpcom/base/nsMemoryInfoDumper.cpp
+index 0b2f78c..d857374 100644
+--- mozilla/xpcom/base/nsMemoryInfoDumper.cpp
++++ mozilla/xpcom/base/nsMemoryInfoDumper.cpp
+@@ -30,7 +30,7 @@
+ #include <unistd.h>
+ #endif
+ 
+-#ifdef XP_LINUX
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+ #include <fcntl.h>
+ #include <sys/types.h>
+ #include <sys/stat.h>
+@@ -109,7 +109,7 @@ private:
+ 
+ } // anonymous namespace
+ 
+-#ifdef XP_LINUX // {
++#if defined(XP_LINUX) || defined(__FreeBSD__) // {
+ namespace {
+ 
+ /*
+@@ -548,7 +548,7 @@ nsMemoryInfoDumper::~nsMemoryInfoDumper(
+ /* static */ void
+ nsMemoryInfoDumper::Initialize()
+ {
+-#ifdef XP_LINUX
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+   SignalPipeWatcher::Create();
+   FifoWatcher::MaybeCreate();
+ #endif
+diff --git xpcom/base/nsMemoryReporterManager.cpp 
xpcom/base/nsMemoryReporterManager.cpp
+index 8c65665..8f6d0e9 100644
+--- mozilla/xpcom/base/nsMemoryReporterManager.cpp
++++ mozilla/xpcom/base/nsMemoryReporterManager.cpp
+@@ -824,7 +824,7 @@ nsMemoryReporterManager::Init()
+     RegisterReporter(new mozilla::dmd::DMDReporter);
+ #endif
+ 
+-#if defined(XP_LINUX)
++#if defined(XP_LINUX) || defined(__FreeBSD__)
+     nsMemoryInfoDumper::Initialize();
+ #endif
+ 
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-gecko
To unsubscribe, send any mail to "[email protected]"

Reply via email to