Bug 1194555 - Part 1: Remove RunReportersForThisProcess. r=njn

RunReportersForThisProcess is no longer used and will no longer work once we have async reporters.
This commit is contained in:
Eric Rahm 2015-10-14 16:52:53 -07:00
parent b7fe470d7d
commit 5844d55676
2 changed files with 0 additions and 51 deletions

View File

@ -520,15 +520,6 @@ nsresult RegisterNonJSSizeOfTab(NonJSSizeOfTabFn aSizeOfTabFn);
}
#if defined(MOZ_DMD) && !defined(MOZILLA_XPCOMRT_API)
namespace mozilla {
namespace dmd {
// This runs all the memory reporters in the current process but does nothing
// with the results; i.e. it does the minimal amount of work possible for DMD
// to do its thing. It does nothing with child processes.
void RunReportersForThisProcess();
}
}
#if !defined(MOZ_MEMORY)
#error "MOZ_DMD requires MOZ_MEMORY"
#endif

View File

@ -2500,45 +2500,3 @@ DEFINE_REGISTER_SIZE_OF_TAB(NonJS);
#undef GET_MEMORY_REPORTER_MANAGER
} // namespace mozilla
#if defined(MOZ_DMD)
namespace mozilla {
namespace dmd {
class DoNothingCallback final : public nsIHandleReportCallback
{
public:
NS_DECL_ISUPPORTS
NS_IMETHOD Callback(const nsACString& aProcess, const nsACString& aPath,
int32_t aKind, int32_t aUnits, int64_t aAmount,
const nsACString& aDescription,
nsISupports* aData) override
{
// Do nothing; the reporter has already reported to DMD.
return NS_OK;
}
private:
~DoNothingCallback() {}
};
NS_IMPL_ISUPPORTS(DoNothingCallback, nsIHandleReportCallback)
void
RunReportersForThisProcess()
{
nsCOMPtr<nsIMemoryReporterManager> mgr =
do_GetService("@mozilla.org/memory-reporter-manager;1");
nsRefPtr<DoNothingCallback> doNothing = new DoNothingCallback();
mgr->GetReportsForThisProcess(doNothing, nullptr, /* anonymize = */ false);
}
} // namespace dmd
} // namespace mozilla
#endif // defined(MOZ_DMD)