Reviewers: Hannes Payer, Benedikt Meurer,

Message:
This seems to work, but it's complex code, so unit tests are needed. I will try to add some, but am publishing now to get some early feedback on the approach. Any feedback on how to approach unit testing here is welcome. I don't see any
Heap usage in existing unit tests.


https://codereview.chromium.org/1150593003/diff/60001/src/heap/spaces-inl.h
File src/heap/spaces-inl.h (left):

https://codereview.chromium.org/1150593003/diff/60001/src/heap/spaces-inl.h#oldcode377
src/heap/spaces-inl.h:377: (kDoubleUnaligned && (OffsetFrom(obj) &
kDoubleAlignmentMask) != 0));
I eliminated this since it can never assert.

Description:
Clean up aligned allocation code in preparation for SIMD alignments.
Move alignment fill calculation into a single static Heap method.
Make default case that we fill before an object that needs alignment.
Rename kDoubleUnaligned -> kDoubleValueAligned.
Use above to simplify heap spaces allocation code.
Make DoubleAlignForDeserialization explicitly fill after an already
aligned object.

LOG=N
BUG=v8:4124

Please review this at https://codereview.chromium.org/1150593003/

Base URL: https://chromium.googlesource.com/v8/v8.git@master

Affected files (+52, -77 lines):
  M src/globals.h
  M src/heap/heap.h
  M src/heap/heap.cc
  M src/heap/spaces.h
  M src/heap/spaces.cc
  M src/heap/spaces-inl.h


--
--
v8-dev mailing list
v8-dev@googlegroups.com
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to