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

Side by Side Diff: src/heap/mark-compact.h

Issue 2493173003: [heap] Remove unused CompactionMode flag (Closed)
Patch Set: Created 4 years, 1 month 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 | « src/heap/incremental-marking.cc ('k') | src/heap/mark-compact.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_HEAP_MARK_COMPACT_H_ 5 #ifndef V8_HEAP_MARK_COMPACT_H_
6 #define V8_HEAP_MARK_COMPACT_H_ 6 #define V8_HEAP_MARK_COMPACT_H_
7 7
8 #include <deque> 8 #include <deque>
9 9
10 #include "src/base/bits.h" 10 #include "src/base/bits.h"
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after
424 424
425 void AddEvacuationCandidate(Page* p); 425 void AddEvacuationCandidate(Page* p);
426 426
427 // Prepares for GC by resetting relocation info in old and map spaces and 427 // Prepares for GC by resetting relocation info in old and map spaces and
428 // choosing spaces to compact. 428 // choosing spaces to compact.
429 void Prepare(); 429 void Prepare();
430 430
431 // Performs a global garbage collection. 431 // Performs a global garbage collection.
432 void CollectGarbage(); 432 void CollectGarbage();
433 433
434 enum CompactionMode { INCREMENTAL_COMPACTION, NON_INCREMENTAL_COMPACTION }; 434 bool StartCompaction();
435
436 bool StartCompaction(CompactionMode mode);
437 435
438 void AbortCompaction(); 436 void AbortCompaction();
439 437
440 #ifdef DEBUG 438 #ifdef DEBUG
441 // Checks whether performing mark-compact collection. 439 // Checks whether performing mark-compact collection.
442 bool in_use() { return state_ > PREPARE_GC; } 440 bool in_use() { return state_ > PREPARE_GC; }
443 bool are_map_pointers_encoded() { return state_ == UPDATE_POINTERS; } 441 bool are_map_pointers_encoded() { return state_ == UPDATE_POINTERS; }
444 #endif 442 #endif
445 443
446 // Determine type of object and emit deletion log event. 444 // Determine type of object and emit deletion log event.
(...skipping 327 matching lines...) Expand 10 before | Expand all | Expand 10 after
774 772
775 private: 773 private:
776 MarkCompactCollector* collector_; 774 MarkCompactCollector* collector_;
777 }; 775 };
778 776
779 V8_EXPORT_PRIVATE const char* AllocationSpaceName(AllocationSpace space); 777 V8_EXPORT_PRIVATE const char* AllocationSpaceName(AllocationSpace space);
780 } // namespace internal 778 } // namespace internal
781 } // namespace v8 779 } // namespace v8
782 780
783 #endif // V8_HEAP_MARK_COMPACT_H_ 781 #endif // V8_HEAP_MARK_COMPACT_H_
OLDNEW
« no previous file with comments | « src/heap/incremental-marking.cc ('k') | src/heap/mark-compact.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698