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

Unified Diff: base/debug/activity_tracker.h

Issue 2583223002: Collect stability data from global and activity scopes (Closed)
Patch Set: Merge Created 3 years, 11 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 | « no previous file | base/debug/activity_tracker.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/debug/activity_tracker.h
diff --git a/base/debug/activity_tracker.h b/base/debug/activity_tracker.h
index 789905e288ae980b241977dae9fb7ac6d285e7ab..62f983b5e87024f2334691db3db543ebfd2d6683 100644
--- a/base/debug/activity_tracker.h
+++ b/base/debug/activity_tracker.h
@@ -132,7 +132,7 @@ extern const ActivityData kNullActivityData;
// A helper class that is used for managing memory allocations within a
// persistent memory allocator. Instances of this class are NOT thread-safe.
// Use from a single thread or protect access with a lock.
-class ActivityTrackerMemoryAllocator {
+class BASE_EXPORT ActivityTrackerMemoryAllocator {
public:
using Reference = PersistentMemoryAllocator::Reference;
@@ -307,6 +307,8 @@ class BASE_EXPORT ActivityUserData {
TypedValue(const TypedValue& other);
~TypedValue();
+ ValueType type() const { return type_; }
+
// These methods return the extracted value in the correct format.
StringPiece Get() const;
StringPiece GetString() const;
@@ -329,10 +331,10 @@ class BASE_EXPORT ActivityUserData {
private:
friend class ActivityUserData;
- ValueType type;
- uint64_t short_value; // Used to hold copy of numbers, etc.
- std::string long_value; // Used to hold copy of raw/string data.
- StringPiece ref_value; // Used to hold reference to external data.
+ ValueType type_;
bcwhite 2017/01/10 18:00:38 Thanks. I think I started this as a struct is why
manzagop (departed) 2017/01/10 18:55:48 Acknowledged.
+ uint64_t short_value_; // Used to hold copy of numbers, etc.
+ std::string long_value_; // Used to hold copy of raw/string data.
+ StringPiece ref_value_; // Used to hold reference to external data.
};
using Snapshot = std::map<std::string, TypedValue>;
@@ -537,6 +539,7 @@ class BASE_EXPORT ThreadActivityTracker {
// An identifier that indicates a specific activity on the stack.
ActivityId activity_id_;
+ private:
DISALLOW_COPY_AND_ASSIGN(ScopedActivity);
};
« no previous file with comments | « no previous file | base/debug/activity_tracker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698