Chromium Code Reviews| Index: chrome/browser/chrome_browser_field_trials_desktop.cc |
| diff --git a/chrome/browser/chrome_browser_field_trials_desktop.cc b/chrome/browser/chrome_browser_field_trials_desktop.cc |
| index 3970bf2f0b90b873b2ea5497cef6a28e509ec351..a87e9f938374c99c37b833e8eb6bfadb93cd9ccc 100644 |
| --- a/chrome/browser/chrome_browser_field_trials_desktop.cc |
| +++ b/chrome/browser/chrome_browser_field_trials_desktop.cc |
| @@ -7,8 +7,11 @@ |
| #include <string> |
| #include "base/command_line.h" |
| +#include "base/debug/activity_tracker.h" |
| #include "base/metrics/field_trial.h" |
| +#include "base/path_service.h" |
| #include "chrome/browser/prerender/prerender_field_trial.h" |
| +#include "chrome/common/chrome_paths.h" |
| #include "chrome/common/chrome_switches.h" |
| #include "chrome/common/variations/variations_util.h" |
| #include "components/variations/variations_associated_data.h" |
| @@ -46,12 +49,23 @@ void SetupStunProbeTrial() { |
| #endif |
| } |
| +void SetupActivityTracking() { |
|
Alexei Svitkine (slow)
2016/08/04 14:27:05
SetupHangDebugging?
Alexei Svitkine (slow)
2016/08/04 18:16:45
Ping.
bcwhite
2016/08/04 19:15:07
Done.
bcwhite
2016/08/04 19:15:07
Done. Was waiting to resolve other names.
|
| + // Track code activities (such as posting task, blocking on locks, and |
| + // joining threads) that can cause threads to hang. |
| + base::FilePath activity_file; |
| + bool success = base::PathService::Get(chrome::DIR_USER_DATA, &activity_file); |
| + DCHECK(success); |
| + activity_file = activity_file.AppendASCII("HangDebugInfo"); |
| + base::debug::SetupGlobalActivityTrackerFieldTrial(activity_file); |
| +} |
| + |
| } // namespace |
| void SetupDesktopFieldTrials(const base::CommandLine& parsed_command_line) { |
| prerender::ConfigurePrerender(parsed_command_line); |
| SetupLightSpeedTrials(); |
| SetupStunProbeTrial(); |
| + SetupActivityTracking(); |
| } |
| } // namespace chrome |