| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 #include <algorithm> | 5 #include <algorithm> |
| 6 | 6 |
| 7 #include "src/v8.h" | 7 #include "src/v8.h" |
| 8 | 8 |
| 9 #include "src/counters.h" | 9 #include "src/counters.h" |
| 10 #include "src/heap/store-buffer-inl.h" | 10 #include "src/heap/store-buffer-inl.h" |
| (...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 375 } | 375 } |
| 376 } | 376 } |
| 377 } | 377 } |
| 378 old_top_ = new_top; | 378 old_top_ = new_top; |
| 379 ClearFilteringHashSets(); | 379 ClearFilteringHashSets(); |
| 380 | 380 |
| 381 // Don't scan on scavenge dead large objects. | 381 // Don't scan on scavenge dead large objects. |
| 382 LargeObjectIterator it(heap_->lo_space()); | 382 LargeObjectIterator it(heap_->lo_space()); |
| 383 for (HeapObject* object = it.Next(); object != NULL; object = it.Next()) { | 383 for (HeapObject* object = it.Next(); object != NULL; object = it.Next()) { |
| 384 MemoryChunk* chunk = MemoryChunk::FromAddress(object->address()); | 384 MemoryChunk* chunk = MemoryChunk::FromAddress(object->address()); |
| 385 if (chunk->scan_on_scavenge() && !Marking::MarkBitFrom(object).Get()) { | 385 if (chunk->scan_on_scavenge() && |
| 386 Marking::IsWhite(Marking::MarkBitFrom(object))) { |
| 386 chunk->set_scan_on_scavenge(false); | 387 chunk->set_scan_on_scavenge(false); |
| 387 } | 388 } |
| 388 } | 389 } |
| 389 } | 390 } |
| 390 | 391 |
| 391 | 392 |
| 392 void StoreBuffer::VerifyValidStoreBufferEntries() { | 393 void StoreBuffer::VerifyValidStoreBufferEntries() { |
| 393 for (Address* current = old_start_; current < old_top_; current++) { | 394 for (Address* current = old_start_; current < old_top_; current++) { |
| 394 Object** slot = reinterpret_cast<Object**>(*current); | 395 Object** slot = reinterpret_cast<Object**>(*current); |
| 395 Object* object = *slot; | 396 Object* object = *slot; |
| (...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 565 } | 566 } |
| 566 old_buffer_is_sorted_ = false; | 567 old_buffer_is_sorted_ = false; |
| 567 old_buffer_is_filtered_ = false; | 568 old_buffer_is_filtered_ = false; |
| 568 *old_top_++ = reinterpret_cast<Address>(int_addr << kPointerSizeLog2); | 569 *old_top_++ = reinterpret_cast<Address>(int_addr << kPointerSizeLog2); |
| 569 DCHECK(old_top_ <= old_limit_); | 570 DCHECK(old_top_ <= old_limit_); |
| 570 } | 571 } |
| 571 heap_->isolate()->counters()->store_buffer_compactions()->Increment(); | 572 heap_->isolate()->counters()->store_buffer_compactions()->Increment(); |
| 572 } | 573 } |
| 573 } | 574 } |
| 574 } // namespace v8::internal | 575 } // namespace v8::internal |
| OLD | NEW |