New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 730091 link

Starred by 0 users

Issue metadata

Status: WontFix
Owner:
Closed: Sep 27
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 3
Type: Bug



Sign in to add a comment

Potential memory leak with RecordUserAction

Project Member Reported by etienneb@chromium.org, Jun 6 2017

Issue description

I ran a long-running test that was navigating to a restricted set of web pages for a whole day. The browser process was kept alive the whole time. Memory dumps using memory-infra are taken at the beginning and at the end of the experiment.

About 8k objects are remaining between start and end of the experiment and are potentially leaked for every following stackframes.

Is it possible UMA is not flushing them when not enabled?


      "operator new",
      "google::protobuf::Arena::Create<metrics::UserActionEventProto>",
      "google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<metrics::UserActionEventProto>::TypeHandler>",
      "metrics::MetricsLog::RecordUserAction",
      "metrics::MetricsService::OnUserAction",
      "base::RecordComputedAction",
      "base::RecordAction",
      "chrome::UMABrowsingActivityObserver::Observe",
      "content::NotificationServiceImpl::Notify",
      "content::NavigationControllerImpl::NotifyNavigationEntryCommitted",
      "content::NavigationControllerImpl::RendererDidNavigate",
      "content::NavigatorImpl::DidNavigate",
      "content::RenderFrameHostImpl::OnDidCommitProvisionalLoad",
      "content::RenderFrameHostImpl::OnMessageReceived",
      "content::RenderProcessHostImpl::OnMessageReceived",
      "IPC::ChannelProxy::Context::OnDispatchMessage",
      "base::debug::TaskAnnotator::RunTask",
      "base::MessageLoop::RunTask",
      "base::MessageLoop::DoWork",
      "base::MessagePumpForUI::DoRunLoop",
      "base::MessagePumpWin::Run",
      "base::RunLoop::Run",
      "ChromeBrowserMainParts::MainMessageLoopRun",
      "content::BrowserMainLoop::RunMainMessageLoopParts",
      "content::BrowserMainRunnerImpl::Run",
      "content::BrowserMain",
      "content::RunNamedProcessTypeMain",
      "content::ContentMainRunnerImpl::Run",
      "service_manager::Main",
      "content::ContentMain",
      "ChromeMain",
      "MainDllLoader::Launch",
      "wWinMain",
      "__scrt_common_main_seh",
      "BaseThreadInitThunk",
      "RtlUserThreadStart",
      "[Thread: CrBrowserMain]"



      "operator new",
      "google::protobuf::Arena::Create<metrics::UserActionEventProto>",
      "google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<metrics::UserActionEventProto>::TypeHandler>",
      "metrics::MetricsLog::RecordUserAction",
      "metrics::MetricsService::OnUserAction",
      "base::RecordComputedAction",
      "base::RecordAction",
      "metrics::StabilityMetricsHelper::LogLoadStarted",
      "ChromeStabilityMetricsProvider::Observe",
      "content::NotificationServiceImpl::Notify",
      "content::WebContentsImpl::LoadingStateChanged",
      "content::WebContentsImpl::DidStartLoading",
      "content::FrameTreeNode::DidStartLoading",
      "content::RenderFrameHostImpl::OnDidStartLoading",
      "IPC::MessageT<FrameHostMsg_DidStartLoading_Meta,std::tuple<bool>,void>::Dispatch<content::RenderFrameHostImpl,content::RenderFrameHostImpl,void,void (__cdecl content::RenderFrameHostImpl::*)(bool) __ptr64>",
      "content::RenderFrameHostImpl::OnMessageReceived",
      "content::RenderProcessHostImpl::OnMessageReceived",
      "IPC::ChannelProxy::Context::OnDispatchMessage",
      "base::debug::TaskAnnotator::RunTask",
      "base::MessageLoop::RunTask",
      "base::MessageLoop::DoWork",
      "base::MessagePumpForUI::DoRunLoop",
      "base::MessagePumpWin::Run",
      "base::RunLoop::Run",
      "ChromeBrowserMainParts::MainMessageLoopRun",
      "content::BrowserMainLoop::RunMainMessageLoopParts",
      "content::BrowserMainRunnerImpl::Run",
      "content::BrowserMain",
      "content::RunNamedProcessTypeMain",
      "content::ContentMainRunnerImpl::Run",
      "service_manager::Main",
      "content::ContentMain",
      "ChromeMain",
      "MainDllLoader::Launch",
      "wWinMain",
      "__scrt_common_main_seh",
      "BaseThreadInitThunk",
      "RtlUserThreadStart",
      "[Thread: CrBrowserMain]"


      "operator new",
      "google::protobuf::Arena::Create<metrics::UserActionEventProto>",
      "google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<metrics::UserActionEventProto>::TypeHandler>",
      "metrics::MetricsLog::RecordUserAction",
      "metrics::MetricsService::OnUserAction",
      "base::RecordComputedAction",
      "base::RecordAction",
      "metrics::StabilityMetricsHelper::LogLoadStarted",
      "ChromeStabilityMetricsProvider::Observe",
      "content::NotificationServiceImpl::Notify",
      "content::WebContentsImpl::LoadingStateChanged",
      "content::WebContentsImpl::DidStartLoading",
      "content::FrameTreeNode::DidStartLoading",
      "content::RenderFrameHostImpl::OnDidStartLoading",
      "content::RenderFrameHostImpl::Navigate",
      "content::NavigatorImpl::NavigateToEntry",
      "content::NavigatorImpl::NavigateToPendingEntry",
      "content::NavigationControllerImpl::NavigateToPendingEntryInternal",
      "content::NavigationControllerImpl::NavigateToPendingEntry",
      "content::NavigationControllerImpl::LoadEntry",
      "content::NavigationControllerImpl::LoadURLWithParams",
      "content::NavigationControllerImpl::LoadURL",
      "content::protocol::PageHandler::Navigate",
      "content::protocol::Page::DispatcherImpl::navigate",
      "content::protocol::ServiceWorker::DispatcherImpl::dispatch",
      "content::protocol::UberDispatcher::dispatch",
      "content::DevToolsSession::Dispatch",
      "content::RenderFrameDevToolsAgentHost::DispatchProtocolMessage",
      "content::DevToolsHttpHandler::OnWebSocketMessage",
      "base::internal::InvokeHelper<1,void>::MakeItSo<void (__cdecl ui::ClientGpuMemoryBufferManager::*const & __ptr64)(gfx::GenericSharedMemoryId,gpu::SyncToken const & __ptr64) __ptr64,base::WeakPtr<ui::ClientGpuMemoryBufferManager> const & __ptr64,gfx::GenericSharedMemoryId const & __ptr64,gpu::SyncToken const & __ptr64>",
      "base::debug::TaskAnnotator::RunTask",
      "base::MessageLoop::RunTask",
      "base::MessageLoop::DoWork",
      "base::MessagePumpForUI::DoRunLoop",
      "base::MessagePumpWin::Run",
      "base::RunLoop::Run",
      "ChromeBrowserMainParts::MainMessageLoopRun",
      "content::BrowserMainLoop::RunMainMessageLoopParts",
      "content::BrowserMainRunnerImpl::Run",
      "content::BrowserMain",
      "content::RunNamedProcessTypeMain",
      "<truncated>",
      "[Thread: CrBrowserMain]"


      "operator new",
      "google::protobuf::Arena::Create<metrics::UserActionEventProto>",
      "google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<metrics::UserActionEventProto>::TypeHandler>",
      "metrics::MetricsLog::RecordUserAction",
      "metrics::MetricsService::OnUserAction",
      "base::RecordComputedAction",
      "base::RecordAction",
      "metrics::StabilityMetricsHelper::LogLoadStarted",
      "ChromeStabilityMetricsProvider::Observe",
      "content::NotificationServiceImpl::Notify",
      "content::WebContentsImpl::LoadingStateChanged",
      "content::WebContentsImpl::DidStartLoading",
      "content::FrameTreeNode::DidStartLoading",
      "content::RenderFrameHostImpl::OnDidStartLoading",
      "content::RenderFrameHostImpl::Navigate",
      "content::NavigatorImpl::NavigateToEntry",
      "content::NavigatorImpl::NavigateToPendingEntry",
      "content::NavigationControllerImpl::NavigateToPendingEntryInternal",
      "content::NavigationControllerImpl::NavigateToPendingEntry",
      "content::NavigationControllerImpl::LoadEntry",
      "content::NavigationControllerImpl::LoadURLWithParams",
      "`anonymous namespace'::LoadURLInContents",
      "chrome::Navigate",
      "ChromeDevToolsManagerDelegate::CreateNewTarget",
      "content::DevToolsHttpHandler::OnJsonRequest",
      "base::internal::InvokeHelper<1,void>::MakeItSo<void (__cdecl ui::ClientGpuMemoryBufferManager::*const & __ptr64)(gfx::GenericSharedMemoryId,gpu::SyncToken const & __ptr64) __ptr64,base::WeakPtr<ui::ClientGpuMemoryBufferManager> const & __ptr64,gfx::GenericSharedMemoryId const & __ptr64,gpu::SyncToken const & __ptr64>",
      "base::debug::TaskAnnotator::RunTask",
      "base::MessageLoop::RunTask",
      "base::MessageLoop::DoWork",
      "base::MessagePumpForUI::DoRunLoop",
      "base::MessagePumpWin::Run",
      "base::RunLoop::Run",
      "ChromeBrowserMainParts::MainMessageLoopRun",
      "content::BrowserMainLoop::RunMainMessageLoopParts",
      "content::BrowserMainRunnerImpl::Run",
      "content::BrowserMain",
      "content::RunNamedProcessTypeMain",
      "content::ContentMainRunnerImpl::Run",
      "service_manager::Main",
      "content::ContentMain",
      "ChromeMain",
      "<truncated>",
      "[Thread: CrBrowserMain]"


      "operator new",
      "google::protobuf::Arena::Create<metrics::UserActionEventProto>",
      "google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<metrics::UserActionEventProto>::TypeHandler>",
      "metrics::MetricsLog::RecordUserAction",
      "metrics::MetricsService::OnUserAction",
      "base::RecordComputedAction",
      "base::RecordAction",
      "Browser::ActiveTabChanged",
      "TabStripModel::NotifyIfActiveTabChanged",
      "TabStripModel::NotifyIfActiveOrSelectionChanged",
      "TabStripModel::SetSelection",
      "TabStripModel::InsertWebContentsAt",
      "TabStripModel::AddWebContents",
      "chrome::Navigate",
      "ChromeDevToolsManagerDelegate::CreateNewTarget",
      "content::DevToolsHttpHandler::OnJsonRequest",
      "base::internal::InvokeHelper<1,void>::MakeItSo<void (__cdecl ui::ClientGpuMemoryBufferManager::*const & __ptr64)(gfx::GenericSharedMemoryId,gpu::SyncToken const & __ptr64) __ptr64,base::WeakPtr<ui::ClientGpuMemoryBufferManager> const & __ptr64,gfx::GenericSharedMemoryId const & __ptr64,gpu::SyncToken const & __ptr64>",
      "base::debug::TaskAnnotator::RunTask",
      "base::MessageLoop::RunTask",
      "base::MessageLoop::DoWork",
      "base::MessagePumpForUI::DoRunLoop",
      "base::MessagePumpWin::Run",
      "base::RunLoop::Run",
      "ChromeBrowserMainParts::MainMessageLoopRun",
      "content::BrowserMainLoop::RunMainMessageLoopParts",
      "content::BrowserMainRunnerImpl::Run",
      "content::BrowserMain",
      "content::RunNamedProcessTypeMain",
      "content::ContentMainRunnerImpl::Run",
      "service_manager::Main",
      "content::ContentMain",
      "ChromeMain",
      "MainDllLoader::Launch",
      "wWinMain",
      "__scrt_common_main_seh",
      "BaseThreadInitThunk",
      "RtlUserThreadStart",
      "[Thread: CrBrowserMain]"


      "operator new",
      "google::protobuf::Arena::Create<metrics::UserActionEventProto>",
      "google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<metrics::UserActionEventProto>::TypeHandler>",
      "metrics::MetricsLog::RecordUserAction",
      "metrics::MetricsService::OnUserAction",
      "base::RecordComputedAction",
      "base::RecordAction",
      "Browser::ActiveTabChanged",
      "TabStripModel::NotifyIfActiveTabChanged",
      "TabStripModel::DetachWebContentsAt",
      "content::WebContentsImpl::~WebContentsImpl",
      "content::WebContentsImpl::`scalar deleting destructor'",
      "TabStripModel::InternalCloseTab",
      "TabStripModel::InternalCloseTabs",
      "TabStripModel::CloseWebContentsAt",
      "chrome::CloseWebContents",
      "Browser::CloseContents",
      "content::WebContentsImpl::Close",
      "IPC::MessageT<ViewHostMsg_ClosePage_ACK_Meta,std::tuple<>,void>::Dispatch<content::RenderViewHostImpl,content::RenderViewHostImpl,void,void (__cdecl content::RenderViewHostImpl::*)(void) __ptr64>",
      "content::RenderViewHostImpl::OnMessageReceived",
      "content::RenderWidgetHostImpl::OnMessageReceived",
      "content::RenderProcessHostImpl::OnMessageReceived",
      "IPC::ChannelProxy::Context::OnDispatchMessage",
      "base::debug::TaskAnnotator::RunTask",
      "base::MessageLoop::RunTask",
      "base::MessageLoop::DoWork",
      "base::MessagePumpForUI::DoRunLoop",
      "base::MessagePumpWin::Run",
      "base::RunLoop::Run",
      "ChromeBrowserMainParts::MainMessageLoopRun",
      "content::BrowserMainLoop::RunMainMessageLoopParts",
      "content::BrowserMainRunnerImpl::Run",
      "content::BrowserMain",
      "content::RunNamedProcessTypeMain",
      "content::ContentMainRunnerImpl::Run",
      "service_manager::Main",
      "content::ContentMain",
      "ChromeMain",
      "MainDllLoader::Launch",
      "wWinMain",
      "__scrt_common_main_seh",
      "<truncated>",
      "[Thread: CrBrowserMain]"


      "operator new",
      "google::protobuf::Arena::Create<metrics::UserActionEventProto>",
      "google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<metrics::UserActionEventProto>::TypeHandler>",
      "metrics::MetricsLog::RecordUserAction",
      "metrics::MetricsService::OnUserAction",
      "base::RecordComputedAction",
      "IPC::MessageT<ViewHostMsg_UserMetricsRecordAction_Meta,std::tuple<std::basic_string<char,std::char_traits<char>,std::allocator<char> > >,void>::Dispatch<content::RenderProcessHostImpl,content::RenderProcessHostImpl,void,void (__cdecl content::RenderProcessHostImpl::*)(std::basic_string<char,std::char_traits<char>,std::allocator<char> > const & __ptr64) __ptr64>",
      "content::RenderProcessHostImpl::OnMessageReceived",
      "IPC::ChannelProxy::Context::OnDispatchMessage",
      "base::debug::TaskAnnotator::RunTask",
      "base::MessageLoop::RunTask",
      "base::MessageLoop::DoWork",
      "base::MessagePumpForUI::DoRunLoop",
      "base::MessagePumpWin::Run",
      "base::RunLoop::Run",
      "ChromeBrowserMainParts::MainMessageLoopRun",
      "content::BrowserMainLoop::RunMainMessageLoopParts",
      "content::BrowserMainRunnerImpl::Run",
      "content::BrowserMain",
      "content::RunNamedProcessTypeMain",
      "content::ContentMainRunnerImpl::Run",
      "service_manager::Main",
      "content::ContentMain",
      "ChromeMain",
      "MainDllLoader::Launch",
      "wWinMain",
      "__scrt_common_main_seh",
      "BaseThreadInitThunk",
      "RtlUserThreadStart",
      "[Thread: CrBrowserMain]"
 
Cc: -alexis@chromium.org etienneb@chromium.org
Components: Internals>Metrics
Labels: OS-All
Cc: rkaplow@chromium.org
Some questions for you:

Is UMA enabled in the Chrome version you were testing? Was it periodically sending reports up?

The way it's supposed to work is if UMA is not enabled, then metrics service shouldn't be listening for user actions to begin with - so the above stack traces shouldn't be possible (i.e. RecordComputedAction() wouldn't then call into MetricsService).

And if UMA is enabled, then periodically, there should be an UMA log cut, with the actions added to the protobuf serialized to a string and then the protobuf object being destructed. So only the ones that haven't been sent yet should be in the proto.

That's how it's supposed to work. Of course, there could be a bug with the above. For example, perhaps we're not properly destroying the protobuf objects that we serialize.

Can you clarify my earlier questions?
This test was executed with telemetry. So, I'm guessing UMA if not activated into the dummy user profile.

> so the above stack traces shouldn't be possible

This is why I was wondering what is really happening.

> Can you clarify my earlier questions?

Feel free to pass by my desk to see the repro.
Here are the document with all the steps used to repro:
  https://docs.google.com/a/google.com/document/d/1ULZRYBElYmBDGswF3f4yYpl77SD9sa0RgFNfl1FueWU/edit?usp=sharing

The results are outdated as we fixed the mojo leaks.
I'm in MTV this week.

Telemetry and UMA are separate.

If you go to settings, under advanced, is "Automatically send usage statistics and crash reports to Google" present and checked? It should be present if this is an official Google Chrome build. If you're on corp, it will also be auto-checked.
Cc: hamelphi@chromium.org
It's a chromium build.
Not a branded build.
Owner: asvitk...@chromium.org
Status: Assigned (was: Untriaged)
Interesting, then UMA should be off.

I'll take a look at this tomorrow.
So here's how metrics service works:

in EnableRecording(), we register for getting user action calls:

  base::RemoveActionCallback(action_callback_);
  action_callback_ = base::Bind(&MetricsService::OnUserAction,
                                base::Unretained(this));
  base::AddActionCallback(action_callback_);

In DisableRecording(), we unregister:
  base::RemoveActionCallback(action_callback_);

So, the first question is why in a Chromium build we're actually registering to get actions - as Chromium shouldn't have metrics recording enabled.

In a normal build, with UMA enabled, we should also be eventually closing the log and all the associated memory would be freed. This would be done via  MetricsLogManager::FinishCurrentLog().
I tried with my own Chromium build and didn't see MetricsService::OnUserAction() get called. So I can't repro what you're seeing.

It's very surprising to me that that gets hit in a Chromium build for you. Is it possible you're starting it with a user data dir that has been previously filled in by a Google Chrome build that had UMA enabled?

If not, I'm not sure how to go forward here beside inspecting your local set up in person (which would have to wait for next week when I'm in town - or I guess someone else from the team could take a look like Rob or Jesse.)
> Is it possible you're starting it with a user data dir that has been previously filled in by a Google Chrome build that had UMA enabled?

Yes. This is possible. I'm gonna check which profile telemetry is using. I was expecting a empty profile, but this may not be the case.
I assume it's a clean profile. See the options from tools\perf\run_benchmark.py


 Browser options:
    --profile-type=PROFILE_TYPE
                        The user profile to use. A clean profile is used by
                        default. Supported values: clean, default,
                        typical_user, power_user
    --profile-dir=PROFILE_DIR
                        Profile directory to launch the browser with. A clean
                        profile is used by default
Do you have access to the Local State file in the user data dir? If so, can you send it to me, I'd like to see if the settings in there indicate to enable metrics reporting.
I put a breakpoint, and it seems to use this folder:
  C:\Users\<user>\AppData\Local\Chromium\User Data\Default

which is probably not a clean profile.

I'm running the same test with an explicit profile folder.
OK - so that likely explains part of the mystery.

That doesn't mean the issue is necessarily solved. If it is being started in a mode where UMA is enabled, then it should be sending up logs which should cause us to clear this data periodically. So either that's not working (e.g. maybe some of that functionality is gated being GOOGLE_CHROME) or there's something else at play.

I guess there's a separate issue that you can start a Chromium build that will send UMA metrics but not show you the UI for that checkbox - if it's pointed at a user data dir with the setting set. Probably something we should make impossible.
I was still able to repro these week. The top stackframe is: 17108 objects

      "malloc",
      "operator new",
      "google::protobuf::Arena::Create<metrics::UserActionEventProto>",
      "google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<metrics::UserActionEventProto>::TypeHandler>",
      "metrics::MetricsLog::RecordUserAction",
      "metrics::MetricsService::OnUserAction",
      "base::RecordComputedAction",
      "base::RecordAction",
      "chrome::UMABrowsingActivityObserver::Observe",
      "content::NotificationServiceImpl::Notify",
      "content::NavigationControllerImpl::NotifyNavigationEntryCommitted",
      "content::NavigationControllerImpl::RendererDidNavigate",
      "content::NavigatorImpl::DidNavigate",
      "content::RenderFrameHostImpl::OnDidCommitProvisionalLoad",
      "content::RenderFrameHostImpl::OnMessageReceived",
      "content::RenderProcessHostImpl::OnMessageReceived",
      "IPC::ChannelProxy::Context::OnDispatchMessage",
      "base::debug::TaskAnnotator::RunTask",
      "base::MessageLoop::RunTask",
      "base::MessageLoop::DoWork",
      "base::MessagePumpForUI::DoRunLoop",
      "base::MessagePumpWin::Run",
      "base::RunLoop::Run",
      "ChromeBrowserMainParts::MainMessageLoopRun",
      "content::BrowserMainLoop::RunMainMessageLoopParts",
      "content::BrowserMainRunnerImpl::Run",
      "content::BrowserMain",
      "content::RunNamedProcessTypeMain",
      "content::ContentMainRunnerImpl::Run",
      "service_manager::Main",
      "content::ContentMain",
      "ChromeMain",
      "MainDllLoader::Launch",
      "wWinMain",
      "__scrt_common_main_seh",
      "BaseThreadInitThunk",
      "RtlUserThreadStart",
      "[Thread: CrBrowserMain]"
Okay, I think I figured out what's going.

We have this function:

bool ChromeMetricsServicesManagerClient::OnlyDoMetricsRecording() {
  const base::CommandLine* cmdline = base::CommandLine::ForCurrentProcess();
  return cmdline->HasSwitch(switches::kMetricsRecordingOnly) ||
         cmdline->HasSwitch(switches::kEnableBenchmarking);
}

Which looks at --enable-benchmarking, which I believe telemetry uses.

This is used in void MetricsServicesManager::UpdateRunningServices():

  if (client_->OnlyDoMetricsRecording()) {
    metrics->StartRecordingForTests();
    GetRapporServiceImpl()->Update(true, false);
    return;
  }

So it causes metrics service to be in this special "StartRecordingForTests" mode.

Which does:

  test_mode_active_ = true;
  EnableRecording();
  DisableReporting();

test_mode_active_ causes StartSchedulerIfNecessary() to be a no-op but also EnableRecording() is called, which registers the MetricsService::OnUserAction() callback.

So this explain the behavior.

This means this likely doesn't affect real users. However, we should still fix this to reduce the extra memory leaks in telemetry mode.

My first question is what's the point of having --enable-benchmarking enabling this special mode of metrics service? Maybe we can just remove it.
Project Member

Comment 19 by bugdroid1@chromium.org, Jun 14 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/de445d97963c2efe33e244fa60678173a6a3c2c8

commit de445d97963c2efe33e244fa60678173a6a3c2c8
Author: asvitkine <asvitkine@chromium.org>
Date: Wed Jun 14 21:37:58 2017

Make --enable-benchmarking not affect metrics recording.

Previously, it would cause metrics to be in a special mode
where metrics are recorded but never reported, which caused
unbounded accumulation of data, such as user actions, in the
UMA protos. This test-only mode didn't seem necessary, so
removing it.

This also allowed a bunch of simplification, by removing a
client interface and its implementation, moving a switch to the
metrics component and removing some ios versions of the code.

BUG= 730091 

Review-Url: https://codereview.chromium.org/2933953002
Cr-Commit-Position: refs/heads/master@{#479511}

[modify] https://crrev.com/de445d97963c2efe33e244fa60678173a6a3c2c8/chrome/browser/metrics/chrome_metrics_services_manager_client.cc
[modify] https://crrev.com/de445d97963c2efe33e244fa60678173a6a3c2c8/chrome/browser/metrics/chrome_metrics_services_manager_client.h
[modify] https://crrev.com/de445d97963c2efe33e244fa60678173a6a3c2c8/chrome/browser/metrics/metrics_service_browsertest.cc
[modify] https://crrev.com/de445d97963c2efe33e244fa60678173a6a3c2c8/chrome/common/chrome_switches.cc
[modify] https://crrev.com/de445d97963c2efe33e244fa60678173a6a3c2c8/chrome/common/chrome_switches.h
[modify] https://crrev.com/de445d97963c2efe33e244fa60678173a6a3c2c8/components/metrics/metrics_switches.cc
[modify] https://crrev.com/de445d97963c2efe33e244fa60678173a6a3c2c8/components/metrics/metrics_switches.h
[modify] https://crrev.com/de445d97963c2efe33e244fa60678173a6a3c2c8/components/metrics_services_manager/metrics_services_manager.cc
[modify] https://crrev.com/de445d97963c2efe33e244fa60678173a6a3c2c8/components/metrics_services_manager/metrics_services_manager_client.h
[modify] https://crrev.com/de445d97963c2efe33e244fa60678173a6a3c2c8/ios/chrome/browser/chrome_switches.cc
[modify] https://crrev.com/de445d97963c2efe33e244fa60678173a6a3c2c8/ios/chrome/browser/chrome_switches.h
[modify] https://crrev.com/de445d97963c2efe33e244fa60678173a6a3c2c8/ios/chrome/browser/metrics/ios_chrome_metrics_services_manager_client.h
[modify] https://crrev.com/de445d97963c2efe33e244fa60678173a6a3c2c8/ios/chrome/browser/metrics/ios_chrome_metrics_services_manager_client.mm

Status: Fixed (was: Assigned)
Fixed. Please mark as verified when you've confirmed you're no longer seeing these leaks with the above CL.
I'm gonna re-run the test this week-end.
Thanks!
I just give a try with this version:

  product-version: "Chrome/61.0.3135.4",
  revision: "8366065c0da06984379f2d39bc85c1067d70d3dd-refs/branch-heads/3135@{#8}",


See the attached stackframes.
bug1.png
32.4 KB View Download
bug2.png
33.7 KB View Download
bug3.png
40.2 KB View Download
Status: Available (was: Fixed)
The previous version was Canary.

Your commit is on
  refs/heads/master@{#479511}
The canary branch is
  refs/heads/master@{#48032}

Which means your change was part of canary.
I ran it over ToT and it is still present.
bug1.png
62.2 KB View Download
Okay, so we're back to the question of "what's turning on UMA"? And even if UMA is on, why aren't these being cleared periodically as a result of log cuts?

https://codereview.chromium.org/2933953002 should have fixed one scenario where they were being turned on (via --enable-benchmarking). But clearly that didn't help here.

So first question is how EnableRecording() is getting called. I made a CL that should help us debug this locally here: https://codereview.chromium.org/2936733002/
If you can build with that and paste the output of chrome://histograms/UMA.Dbg it should help us understand what's happening.
Ping.
(To ask etienneb@ for an update on what happened when patching in the changelist provided in comment #25.)
Status: Assigned (was: Available)
Cc: -hamelphi@chromium.org
Components: -Internals>Metrics Internals>Metrics>UMA
Owner: etienneb@chromium.org
etienneb: Can you provide an update here? Are we still seeing this? If not, we should close.
That's too old.

Let close it. If the bug is still present, it will shows up on our dashboard.
I do not see any tracking of this bug, neither fix.
Status: WontFix (was: Assigned)

Sign in to add a comment