mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-08-27 09:48:38 +09:00
Telemetry: Remove stubs and related code
This commit is contained in:
parent
10053448d6
commit
aea50f182f
134 changed files with 68 additions and 3422 deletions
|
|
@ -92,11 +92,6 @@ mozilla::plugins::SetupBridge(uint32_t aPluginId,
|
|||
return true;
|
||||
}
|
||||
PluginModuleChromeParent* chromeParent = static_cast<PluginModuleChromeParent*>(plugin->GetLibrary());
|
||||
/*
|
||||
* We can't accumulate BLOCKED_ON_PLUGIN_MODULE_INIT_MS until here because
|
||||
* its histogram key is not available until *after* NP_Initialize.
|
||||
*/
|
||||
chromeParent->AccumulateModuleInitBlockedTime();
|
||||
*rv = chromeParent->GetRunID(runID);
|
||||
if (NS_FAILED(*rv)) {
|
||||
return true;
|
||||
|
|
@ -335,16 +330,13 @@ PluginModuleContentParent::LoadModule(uint32_t aPluginId,
|
|||
dom::ContentChild* cp = dom::ContentChild::GetSingleton();
|
||||
nsresult rv;
|
||||
uint32_t runID;
|
||||
TimeStamp sendLoadPluginStart = TimeStamp::Now();
|
||||
if (!cp->SendLoadPlugin(aPluginId, &rv, &runID) ||
|
||||
NS_FAILED(rv)) {
|
||||
return nullptr;
|
||||
}
|
||||
TimeStamp sendLoadPluginEnd = TimeStamp::Now();
|
||||
|
||||
PluginModuleContentParent* parent = mapping->GetModule();
|
||||
MOZ_ASSERT(parent);
|
||||
parent->mTimeBlocked += (sendLoadPluginEnd - sendLoadPluginStart);
|
||||
|
||||
if (!mapping->IsChannelOpened()) {
|
||||
// mapping is linked into PluginModuleMapping::sModuleListHead and is
|
||||
|
|
@ -440,7 +432,6 @@ PluginModuleChromeParent::LoadModule(const char* aFilePath, uint32_t aPluginId,
|
|||
aPluginTag->mSupportsAsyncInit));
|
||||
UniquePtr<LaunchCompleteTask> onLaunchedRunnable(new LaunchedTask(parent));
|
||||
parent->mSubprocess->SetCallRunnableImmediately(!parent->mIsStartingAsync);
|
||||
TimeStamp launchStart = TimeStamp::Now();
|
||||
bool launched = parent->mSubprocess->Launch(Move(onLaunchedRunnable),
|
||||
aPluginTag->mSandboxLevel);
|
||||
if (!launched) {
|
||||
|
|
@ -459,8 +450,6 @@ PluginModuleChromeParent::LoadModule(const char* aFilePath, uint32_t aPluginId,
|
|||
return nullptr;
|
||||
}
|
||||
}
|
||||
TimeStamp launchEnd = TimeStamp::Now();
|
||||
parent->mTimeBlocked = (launchEnd - launchStart);
|
||||
return parent.forget();
|
||||
}
|
||||
|
||||
|
|
@ -1758,15 +1747,12 @@ PluginModuleChromeParent::NP_Initialize(NPNetscapeFuncs* bFuncs, NPPluginFuncs*
|
|||
PluginSettings settings;
|
||||
GetSettings(&settings);
|
||||
|
||||
TimeStamp callNpInitStart = TimeStamp::Now();
|
||||
// Asynchronous case
|
||||
if (mIsStartingAsync) {
|
||||
if (!SendAsyncNP_Initialize(settings)) {
|
||||
Close();
|
||||
return NS_ERROR_FAILURE;
|
||||
}
|
||||
TimeStamp callNpInitEnd = TimeStamp::Now();
|
||||
mTimeBlocked += (callNpInitEnd - callNpInitStart);
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
|
@ -1779,8 +1765,6 @@ PluginModuleChromeParent::NP_Initialize(NPNetscapeFuncs* bFuncs, NPPluginFuncs*
|
|||
Close();
|
||||
return NS_ERROR_FAILURE;
|
||||
}
|
||||
TimeStamp callNpInitEnd = TimeStamp::Now();
|
||||
mTimeBlocked += (callNpInitEnd - callNpInitStart);
|
||||
|
||||
RecvNP_InitializeResult(*error);
|
||||
|
||||
|
|
@ -1882,13 +1866,10 @@ PluginModuleChromeParent::NP_Initialize(NPNetscapeFuncs* bFuncs, NPError* error)
|
|||
PluginSettings settings;
|
||||
GetSettings(&settings);
|
||||
|
||||
TimeStamp callNpInitStart = TimeStamp::Now();
|
||||
if (mIsStartingAsync) {
|
||||
if (!SendAsyncNP_Initialize(settings)) {
|
||||
return NS_ERROR_FAILURE;
|
||||
}
|
||||
TimeStamp callNpInitEnd = TimeStamp::Now();
|
||||
mTimeBlocked += (callNpInitEnd - callNpInitStart);
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
|
@ -1896,8 +1877,6 @@ PluginModuleChromeParent::NP_Initialize(NPNetscapeFuncs* bFuncs, NPError* error)
|
|||
Close();
|
||||
return NS_ERROR_FAILURE;
|
||||
}
|
||||
TimeStamp callNpInitEnd = TimeStamp::Now();
|
||||
mTimeBlocked += (callNpInitEnd - callNpInitStart);
|
||||
RecvNP_InitializeResult(*error);
|
||||
return NS_OK;
|
||||
}
|
||||
|
|
@ -2194,14 +2173,6 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
void
|
||||
PluginModuleParent::AccumulateModuleInitBlockedTime()
|
||||
{
|
||||
// XXX: mTimeBlocked can probably go if not used for anything besides
|
||||
// telemetry.
|
||||
mTimeBlocked = TimeDuration();
|
||||
}
|
||||
|
||||
nsresult
|
||||
PluginModuleParent::NPP_NewInternal(NPMIMEType pluginType, NPP instance,
|
||||
uint16_t mode,
|
||||
|
|
@ -2213,13 +2184,6 @@ PluginModuleParent::NPP_NewInternal(NPMIMEType pluginType, NPP instance,
|
|||
if (mPluginName.IsEmpty()) {
|
||||
GetPluginDetails();
|
||||
InitQuirksModes(nsDependentCString(pluginType));
|
||||
/** mTimeBlocked measures the time that the main thread has been blocked
|
||||
* on plugin module initialization. As implemented, this is the sum of
|
||||
* plugin-container launch + toolhelp32 snapshot + NP_Initialize.
|
||||
* We don't accumulate its value until here because the plugin info
|
||||
* for its histogram key is not available until *after* NP_Initialize.
|
||||
*/
|
||||
AccumulateModuleInitBlockedTime();
|
||||
}
|
||||
|
||||
nsCaseInsensitiveUTF8StringArrayComparator comparator;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue