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

Side by Side Diff: Source/platform/heap/ThreadState.h

Issue 1203493004: [tracing] Adding class-wise memory statistics to blink gc memory dumps (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Remove useless check. Created 5 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 unified diff | Download patch
« no previous file with comments | « Source/platform/heap/Heap.cpp ('k') | Source/platform/heap/ThreadState.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 481 matching lines...) Expand 10 before | Expand all | Expand 10 after
492 // Visit local thread stack and trace all pointers conservatively. 492 // Visit local thread stack and trace all pointers conservatively.
493 void visitStack(Visitor*); 493 void visitStack(Visitor*);
494 494
495 // Visit the asan fake stack frame corresponding to a slot on the 495 // Visit the asan fake stack frame corresponding to a slot on the
496 // real machine stack if there is one. 496 // real machine stack if there is one.
497 void visitAsanFakeStackForPointer(Visitor*, Address); 497 void visitAsanFakeStackForPointer(Visitor*, Address);
498 498
499 // Visit all persistents allocated on this thread. 499 // Visit all persistents allocated on this thread.
500 void visitPersistents(Visitor*); 500 void visitPersistents(Visitor*);
501 501
502 struct GCSnapshotInfo {
503 GCSnapshotInfo(size_t numObjectTypes);
504
505 // Map from gcInfoIndex (vector-index) to count/size.
506 Vector<int> liveCount;
507 Vector<int> deadCount;
508 Vector<size_t> liveSize;
509 Vector<size_t> deadSize;
510 };
511
502 #if ENABLE(GC_PROFILING) 512 #if ENABLE(GC_PROFILING)
503 const GCInfo* findGCInfo(Address); 513 const GCInfo* findGCInfo(Address);
504 static const GCInfo* findGCInfoFromAllThreads(Address); 514 static const GCInfo* findGCInfoFromAllThreads(Address);
505 515
506 struct SnapshotInfo { 516 struct SnapshotInfo {
507 ThreadState* state; 517 ThreadState* state;
508 518
509 size_t freeSize; 519 size_t freeSize;
510 size_t pageCount; 520 size_t pageCount;
511 521
(...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after
803 }; 813 };
804 814
805 template<> class ThreadStateFor<AnyThread> { 815 template<> class ThreadStateFor<AnyThread> {
806 public: 816 public:
807 static ThreadState* state() { return ThreadState::current(); } 817 static ThreadState* state() { return ThreadState::current(); }
808 }; 818 };
809 819
810 } // namespace blink 820 } // namespace blink
811 821
812 #endif // ThreadState_h 822 #endif // ThreadState_h
OLDNEW
« no previous file with comments | « Source/platform/heap/Heap.cpp ('k') | Source/platform/heap/ThreadState.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698