Add crash reporter annotations for the GPU process status. (bug 1343650, r=billm)

--HG--
extra : rebase_source : 28e0d023e99f66f518047f1a468c899ff52c590a
This commit is contained in:
David Anderson 2017-04-03 15:11:27 -07:00
Родитель 734b25e05c
Коммит dfbf7fe0d0
1 изменённых файлов: 16 добавлений и 0 удалений

Просмотреть файл

@ -37,6 +37,10 @@
#include "mozilla/dom/VideoDecoderManagerParent.h"
#include "MediaPrefs.h"
#ifdef MOZ_CRASHREPORTER
# include "nsExceptionHandler.h"
#endif
#if defined(MOZ_WIDGET_ANDROID)
#include "mozilla/widget/AndroidUiThread.h"
#include "mozilla/layers/UiCompositorControllerChild.h"
@ -307,6 +311,12 @@ GPUProcessManager::OnProcessLaunchComplete(GPUProcessHost* aHost)
mappings.AppendElement(LayerTreeIdMapping(aLayersId, aProcessId));
});
mGPUChild->SendAddLayerTreeIdMapping(mappings);
#ifdef MOZ_CRASHREPORTER
CrashReporter::AnnotateCrashReport(
NS_LITERAL_CSTRING("GPUProcessStatus"),
NS_LITERAL_CSTRING("Running"));
#endif
}
static bool
@ -530,6 +540,12 @@ GPUProcessManager::DestroyProcess()
#if defined(MOZ_WIDGET_ANDROID)
UiCompositorControllerChild::Shutdown();
#endif // defined(MOZ_WIDGET_ANDROID)
#ifdef MOZ_CRASHREPORTER
CrashReporter::AnnotateCrashReport(
NS_LITERAL_CSTRING("GPUProcessStatus"),
NS_LITERAL_CSTRING("Destroyed"));
#endif
}
RefPtr<CompositorSession>