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

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

Issue 2194793005: [heap] No leakage of store-buffer.h outside of heap. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 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/heap.cc ('k') | no next file » | 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_HEAP_INL_H_ 5 #ifndef V8_HEAP_HEAP_INL_H_
6 #define V8_HEAP_HEAP_INL_H_ 6 #define V8_HEAP_HEAP_INL_H_
7 7
8 #include <cmath> 8 #include <cmath>
9 9
10 #include "src/base/platform/platform.h" 10 #include "src/base/platform/platform.h"
(...skipping 425 matching lines...) Expand 10 before | Expand all | Expand 10 after
436 if (InNewSpace(array)) return; 436 if (InNewSpace(array)) return;
437 Page* page = Page::FromAddress(reinterpret_cast<Address>(array)); 437 Page* page = Page::FromAddress(reinterpret_cast<Address>(array));
438 for (int i = 0; i < length; i++) { 438 for (int i = 0; i < length; i++) {
439 if (!InNewSpace(array->get(offset + i))) continue; 439 if (!InNewSpace(array->get(offset + i))) continue;
440 RememberedSet<OLD_TO_NEW>::Insert( 440 RememberedSet<OLD_TO_NEW>::Insert(
441 page, 441 page,
442 reinterpret_cast<Address>(array->RawFieldOfElementAt(offset + i))); 442 reinterpret_cast<Address>(array->RawFieldOfElementAt(offset + i)));
443 } 443 }
444 } 444 }
445 445
446 Address* Heap::store_buffer_top_address() {
447 return store_buffer()->top_address();
448 }
446 449
447 bool Heap::AllowedToBeMigrated(HeapObject* obj, AllocationSpace dst) { 450 bool Heap::AllowedToBeMigrated(HeapObject* obj, AllocationSpace dst) {
448 // Object migration is governed by the following rules: 451 // Object migration is governed by the following rules:
449 // 452 //
450 // 1) Objects in new-space can be migrated to the old space 453 // 1) Objects in new-space can be migrated to the old space
451 // that matches their target space or they stay in new-space. 454 // that matches their target space or they stay in new-space.
452 // 2) Objects in old-space stay in the same space when migrating. 455 // 2) Objects in old-space stay in the same space when migrating.
453 // 3) Fillers (two or more words) can migrate due to left-trimming of 456 // 3) Fillers (two or more words) can migrate due to left-trimming of
454 // fixed arrays in new-space or old space. 457 // fixed arrays in new-space or old space.
455 // 4) Fillers (one word) can never migrate, they are skipped by 458 // 4) Fillers (one word) can never migrate, they are skipped by
(...skipping 325 matching lines...) Expand 10 before | Expand all | Expand 10 after
781 784
782 void VerifySmisVisitor::VisitPointers(Object** start, Object** end) { 785 void VerifySmisVisitor::VisitPointers(Object** start, Object** end) {
783 for (Object** current = start; current < end; current++) { 786 for (Object** current = start; current < end; current++) {
784 CHECK((*current)->IsSmi()); 787 CHECK((*current)->IsSmi());
785 } 788 }
786 } 789 }
787 } // namespace internal 790 } // namespace internal
788 } // namespace v8 791 } // namespace v8
789 792
790 #endif // V8_HEAP_HEAP_INL_H_ 793 #endif // V8_HEAP_HEAP_INL_H_
OLDNEW
« no previous file with comments | « src/heap/heap.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698