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

Side by Side Diff: src/profile-generator.h

Issue 7945009: Merge experimental/gc branch to the bleeding_edge. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 9 years, 3 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 | Annotate | Revision Log
« no previous file with comments | « src/platform-win32.cc ('k') | src/profile-generator.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2011 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
11 // with the distribution. 11 // with the distribution.
(...skipping 531 matching lines...) Expand 10 before | Expand all | Expand 10 after
543 void add_retained_size(int size) { retained_size_ += size; } 543 void add_retained_size(int size) { retained_size_ += size; }
544 void set_retained_size(int value) { retained_size_ = value; } 544 void set_retained_size(int value) { retained_size_ = value; }
545 int ordered_index() { return ordered_index_; } 545 int ordered_index() { return ordered_index_; }
546 void set_ordered_index(int value) { ordered_index_ = value; } 546 void set_ordered_index(int value) { ordered_index_ = value; }
547 547
548 Vector<HeapGraphEdge> children() { 548 Vector<HeapGraphEdge> children() {
549 return Vector<HeapGraphEdge>(children_arr(), children_count_); } 549 return Vector<HeapGraphEdge>(children_arr(), children_count_); }
550 Vector<HeapGraphEdge*> retainers() { 550 Vector<HeapGraphEdge*> retainers() {
551 return Vector<HeapGraphEdge*>(retainers_arr(), retainers_count_); } 551 return Vector<HeapGraphEdge*>(retainers_arr(), retainers_count_); }
552 HeapEntry* dominator() { return dominator_; } 552 HeapEntry* dominator() { return dominator_; }
553 void set_dominator(HeapEntry* entry) { dominator_ = entry; } 553 void set_dominator(HeapEntry* entry) {
554 ASSERT(entry != NULL);
555 dominator_ = entry;
556 }
554 557
555 void clear_paint() { painted_ = kUnpainted; } 558 void clear_paint() { painted_ = kUnpainted; }
556 bool painted_reachable() { return painted_ == kPainted; } 559 bool painted_reachable() { return painted_ == kPainted; }
557 void paint_reachable() { 560 void paint_reachable() {
558 ASSERT(painted_ == kUnpainted); 561 ASSERT(painted_ == kUnpainted);
559 painted_ = kPainted; 562 painted_ = kPainted;
560 } 563 }
561 bool not_painted_reachable_from_others() { 564 bool not_painted_reachable_from_others() {
562 return painted_ != kPaintedReachableFromOthers; 565 return painted_ != kPaintedReachableFromOthers;
563 } 566 }
(...skipping 346 matching lines...) Expand 10 before | Expand all | Expand 10 after
910 913
911 // An implementation of V8 heap graph extractor. 914 // An implementation of V8 heap graph extractor.
912 class V8HeapExplorer : public HeapEntriesAllocator { 915 class V8HeapExplorer : public HeapEntriesAllocator {
913 public: 916 public:
914 V8HeapExplorer(HeapSnapshot* snapshot, 917 V8HeapExplorer(HeapSnapshot* snapshot,
915 SnapshottingProgressReportingInterface* progress); 918 SnapshottingProgressReportingInterface* progress);
916 virtual ~V8HeapExplorer(); 919 virtual ~V8HeapExplorer();
917 virtual HeapEntry* AllocateEntry( 920 virtual HeapEntry* AllocateEntry(
918 HeapThing ptr, int children_count, int retainers_count); 921 HeapThing ptr, int children_count, int retainers_count);
919 void AddRootEntries(SnapshotFillerInterface* filler); 922 void AddRootEntries(SnapshotFillerInterface* filler);
920 int EstimateObjectsCount(); 923 int EstimateObjectsCount(HeapIterator* iterator);
921 bool IterateAndExtractReferences(SnapshotFillerInterface* filler); 924 bool IterateAndExtractReferences(SnapshotFillerInterface* filler);
922 void TagGlobalObjects(); 925 void TagGlobalObjects();
923 926
924 static String* GetConstructorName(JSObject* object); 927 static String* GetConstructorName(JSObject* object);
925 928
926 static HeapObject* const kInternalRootObject; 929 static HeapObject* const kInternalRootObject;
927 930
928 private: 931 private:
929 HeapEntry* AddEntry( 932 HeapEntry* AddEntry(
930 HeapObject* object, int children_count, int retainers_count); 933 HeapObject* object, int children_count, int retainers_count);
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after
1120 1123
1121 friend class HeapSnapshotJSONSerializerEnumerator; 1124 friend class HeapSnapshotJSONSerializerEnumerator;
1122 friend class HeapSnapshotJSONSerializerIterator; 1125 friend class HeapSnapshotJSONSerializerIterator;
1123 1126
1124 DISALLOW_COPY_AND_ASSIGN(HeapSnapshotJSONSerializer); 1127 DISALLOW_COPY_AND_ASSIGN(HeapSnapshotJSONSerializer);
1125 }; 1128 };
1126 1129
1127 } } // namespace v8::internal 1130 } } // namespace v8::internal
1128 1131
1129 #endif // V8_PROFILE_GENERATOR_H_ 1132 #endif // V8_PROFILE_GENERATOR_H_
OLDNEW
« no previous file with comments | « src/platform-win32.cc ('k') | src/profile-generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698