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

Unified Diff: src/heap/mark-compact.h

Issue 2440683002: [heap] Move typed slot filtering logic into sweeper. (Closed)
Patch Set: fix test Created 4 years, 2 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 | « src/heap/incremental-marking.cc ('k') | src/heap/mark-compact.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap/mark-compact.h
diff --git a/src/heap/mark-compact.h b/src/heap/mark-compact.h
index 19d72fc7d5e280456f6b1453bacb9634617a770d..67568a96e346f761d1897b57eac904b5122a3d5e 100644
--- a/src/heap/mark-compact.h
+++ b/src/heap/mark-compact.h
@@ -288,6 +288,11 @@ class MarkCompactCollector {
enum FreeListRebuildingMode { REBUILD_FREE_LIST, IGNORE_FREE_LIST };
enum FreeSpaceTreatmentMode { IGNORE_FREE_SPACE, ZAP_FREE_SPACE };
+ enum ClearOldToNewSlotsMode {
+ DO_NOT_CLEAR,
+ CLEAR_REGULAR_SLOTS,
+ CLEAR_TYPED_SLOTS
+ };
typedef std::deque<Page*> SweepingList;
typedef List<Page*> SweptList;
@@ -326,6 +331,8 @@ class MarkCompactCollector {
private:
static const int kAllocationSpaces = LAST_PAGED_SPACE + 1;
+ static ClearOldToNewSlotsMode GetClearOldToNewSlotsMode(Page* p);
+
template <typename Callback>
void ForAllSweepingSpaces(Callback callback) {
for (int i = 0; i < kAllocationSpaces; i++) {
@@ -478,16 +485,6 @@ class MarkCompactCollector {
void InitializeMarkingDeque();
- // The following two methods can just be called after marking, when the
- // whole transitive closure is known. They must be called before sweeping
- // when mark bits are still intact.
- bool IsSlotInBlackObject(MemoryChunk* p, Address slot);
- HeapObject* FindBlackObjectBySlotSlow(Address slot);
-
- // Removes all the slots in the slot buffers that are within the given
- // address range.
- void RemoveObjectSlots(Address start_slot, Address end_slot);
-
Sweeper& sweeper() { return sweeper_; }
private:
« 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