3rd (of 3) CLs to ensure complete alignment of FixedDoubleArrays.
TEST=
BUG=
R=mstarzinger@chromium.org, plind44@gmail.com
Review URL: https://codereview.chromium.org/
35313002
Patch from Dusan Milosavljevic <Dusan.Milosavljevic@rt-rk.com>.
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@17809
ce2b1a6d-e550-0410-aec6-
3dcde31c8c00
bool double_align,
AllocationSpace space) {
Heap* heap = isolate->heap();
+ if (double_align) size += kPointerSize;
RUNTIME_ASSERT(IsAligned(size, kPointerSize));
RUNTIME_ASSERT(size > 0);
RUNTIME_ASSERT(size <= heap->MaxRegularSpaceAllocationSize());
MemoryChunk* chunk = MemoryChunk::FromAddress(allocation->address());
ASSERT(chunk->owner()->identity() == space);
#endif
+ if (double_align) {
+ allocation = heap->EnsureDoubleAligned(allocation, size);
+ }
heap->CreateFillerObjectAt(allocation->address(), size);
return allocation;
}