Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1588)

Unified Diff: base/process/process_metrics_linux.cc

Issue 19064002: Split ProcessHandle and its related routines into base/process/process_handle.h. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Ready for review Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/process/process_metrics_ios.cc ('k') | base/process/process_metrics_posix.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/process/process_metrics_linux.cc
diff --git a/base/process/process_metrics_linux.cc b/base/process/process_metrics_linux.cc
index 849fbe023fa973a51891d838b6983cbdba5d6eac..21e5a5dcebecbfc8c2e0eba5b4707a08eecffd21 100644
--- a/base/process/process_metrics_linux.cc
+++ b/base/process/process_metrics_linux.cc
@@ -496,4 +496,11 @@ bool GetSystemMemoryInfo(SystemMemoryInfoKB* meminfo) {
return true;
}
+const char kProcSelfExe[] = "/proc/self/exe";
+
+int GetNumberOfThreads(ProcessHandle process) {
+ return internal::ReadProcStatsAndGetFieldAsInt(process,
+ internal::VM_NUMTHREADS);
+}
+
} // namespace base
« no previous file with comments | « base/process/process_metrics_ios.cc ('k') | base/process/process_metrics_posix.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698