| Index: src/heap/spaces-inl.h
|
| diff --git a/src/heap/spaces-inl.h b/src/heap/spaces-inl.h
|
| index aefab10cd1bc5fc7de9643c4b1c55ff4a027f1ba..2079a80a0b00f0130aea154d0e873f7d5dbfcce1 100644
|
| --- a/src/heap/spaces-inl.h
|
| +++ b/src/heap/spaces-inl.h
|
| @@ -471,18 +471,20 @@ AllocationResult PagedSpace::AllocateRawAligned(int size_in_bytes,
|
| object = free_list_.Allocate(allocation_size);
|
| if (object == NULL) {
|
| object = SlowAllocateRaw(allocation_size);
|
| - if (object != NULL && heap()->incremental_marking()->black_allocation()) {
|
| + }
|
| + if (object != NULL) {
|
| + if (heap()->incremental_marking()->black_allocation()) {
|
| Address start = object->address();
|
| - Address end = object->address() + size_in_bytes;
|
| + Address end = object->address() + allocation_size;
|
| Page::FromAllocationAreaAddress(start)->CreateBlackArea(start, end);
|
| }
|
| - }
|
| - if (object != NULL && filler_size != 0) {
|
| - object = heap()->AlignWithFiller(object, size_in_bytes, allocation_size,
|
| - alignment);
|
| - // Filler objects are initialized, so mark only the aligned object memory
|
| - // as uninitialized.
|
| - allocation_size = size_in_bytes;
|
| + if (filler_size != 0) {
|
| + object = heap()->AlignWithFiller(object, size_in_bytes, allocation_size,
|
| + alignment);
|
| + // Filler objects are initialized, so mark only the aligned object
|
| + // memory as uninitialized.
|
| + allocation_size = size_in_bytes;
|
| + }
|
| }
|
| }
|
|
|
|
|