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

Unified Diff: content/public/common/gpu_info.h

Issue 10854076: Add GPU memory tab to the task manager. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Clean try errors (remove semicolon, remove unneeded assert that unittests don't follow) Created 8 years, 4 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
Index: content/public/common/gpu_info.h
diff --git a/content/public/common/gpu_info.h b/content/public/common/gpu_info.h
index 5a01e182482e5c410dc554cd0a86ef670e8b4818..b7f3c0804489eb7362b970e930cd8f8a373c8381 100644
--- a/content/public/common/gpu_info.h
+++ b/content/public/common/gpu_info.h
@@ -10,8 +10,10 @@
#include <string>
#include <vector>
+#include <map>
#include "base/basictypes.h"
+#include "base/process.h"
#include "base/time.h"
#include "build/build_config.h"
#include "content/common/content_export.h"
@@ -110,6 +112,27 @@ struct CONTENT_EXPORT GPUInfo {
#endif
};
+struct CONTENT_EXPORT GPUVidmem {
+ GPUVidmem();
+ ~GPUVidmem();
+ struct CONTENT_EXPORT GPUProcessVidmem {
+ GPUProcessVidmem();
+ ~GPUProcessVidmem();
+
+ // The bytes of GPU resources accessible by this process
+ size_t vidmem;
+
+ // Set to true if this process' GPU resource count is inflated because
+ // it is counting other processes' resources (e.g, the GPU process has
+ // duplicate set to true because it is the aggregate of all processes)
+ bool has_duplicates;
+ };
+ typedef std::map<base::ProcessId,GPUProcessVidmem> ProcessMap;
+
+ // A map of processes to their GPU resource consumption
+ ProcessMap process_map;
+};
+
} // namespace content
#endif // CONTENT_PUBLIC_COMMON_GPU_INFO_H_

Powered by Google App Engine
This is Rietveld 408576698