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

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

Issue 1281233003: [heap] Avoid overzealous inclusion of heap internal headers. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: 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 | « src/heap/mark-compact.cc ('k') | src/heap/objects-visiting.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_INL_H_ 5 #ifndef V8_HEAP_MARK_COMPACT_INL_H_
6 #define V8_HEAP_MARK_COMPACT_INL_H_ 6 #define V8_HEAP_MARK_COMPACT_INL_H_
7 7
8 #include "src/heap/mark-compact.h" 8 #include "src/heap/mark-compact.h"
9 #include "src/isolate.h" 9 #include "src/isolate.h"
10 10
11 11
12 namespace v8 { 12 namespace v8 {
13 namespace internal { 13 namespace internal {
14 14
15 15
16 MarkBit Marking::MarkBitFrom(Address addr) {
17 MemoryChunk* p = MemoryChunk::FromAddress(addr);
18 return p->markbits()->MarkBitFromIndex(p->AddressToMarkbitIndex(addr));
19 }
20
21
22 void MarkCompactCollector::SetFlags(int flags) { 16 void MarkCompactCollector::SetFlags(int flags) {
23 reduce_memory_footprint_ = ((flags & Heap::kReduceMemoryFootprintMask) != 0); 17 reduce_memory_footprint_ = ((flags & Heap::kReduceMemoryFootprintMask) != 0);
24 abort_incremental_marking_ = 18 abort_incremental_marking_ =
25 ((flags & Heap::kAbortIncrementalMarkingMask) != 0); 19 ((flags & Heap::kAbortIncrementalMarkingMask) != 0);
26 finalize_incremental_marking_ = 20 finalize_incremental_marking_ =
27 ((flags & Heap::kFinalizeIncrementalMarkingMask) != 0); 21 ((flags & Heap::kFinalizeIncrementalMarkingMask) != 0);
28 DCHECK(!finalize_incremental_marking_ || !abort_incremental_marking_); 22 DCHECK(!finalize_incremental_marking_ || !abort_incremental_marking_);
29 } 23 }
30 24
31 25
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 if (!SlotsBuffer::AddTo(&slots_buffer_allocator_, 58 if (!SlotsBuffer::AddTo(&slots_buffer_allocator_,
65 target_page->slots_buffer_address(), slot, mode)) { 59 target_page->slots_buffer_address(), slot, mode)) {
66 EvictPopularEvacuationCandidate(target_page); 60 EvictPopularEvacuationCandidate(target_page);
67 } 61 }
68 } 62 }
69 } 63 }
70 } 64 }
71 } // namespace v8::internal 65 } // namespace v8::internal
72 66
73 #endif // V8_HEAP_MARK_COMPACT_INL_H_ 67 #endif // V8_HEAP_MARK_COMPACT_INL_H_
OLDNEW
« no previous file with comments | « src/heap/mark-compact.cc ('k') | src/heap/objects-visiting.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698