https://codereview.chromium.org/22378003/diff/38001/src/hydrogen-instructions.cc
File src/hydrogen-instructions.cc (right):

https://codereview.chromium.org/22378003/diff/38001/src/hydrogen-instructions.cc#newcode3431
src/hydrogen-instructions.cc:3431: // space memory.
nit: Seems like an "otherwise" is missing at the end of this sentence.

https://codereview.chromium.org/22378003/diff/38001/src/hydrogen-instructions.cc#newcode3452
src/hydrogen-instructions.cc:3452:
UpdateFreeSpaceFiller(dominator_free_space_size,
It seems these methods are called on the allocations being folded away.
I think it would make much more sense to actually call them on the
dominating allocation. These methods look like "bastard static functions
not being static". This would also make it easier to address the
comment in HAllocate::UpdateFreeSpaceFiller.

https://codereview.chromium.org/22378003/diff/38001/src/hydrogen-instructions.cc#newcode3459
src/hydrogen-instructions.cc:3459: CreateFreeSpaceFiller(dominator,
dominator_size, current_size);
Addressing the comment above would allow you to not pass the dominator
as a parameter but as the receiver instead.

https://codereview.chromium.org/22378003/diff/38001/src/hydrogen-instructions.cc#newcode3471
src/hydrogen-instructions.cc:3471:
old_filler_size->DeleteAndReplaceWith(new_free_space_size);
This looks dangerous, can you guarantee that "old_filler_size" is only
used by the dominating allocation and not something else as well? Can we
either assert that this is the only use or set
Hallocate::filler_free_space_size explicitly?

https://codereview.chromium.org/22378003/diff/38001/src/hydrogen-instructions.h
File src/hydrogen-instructions.h (right):

https://codereview.chromium.org/22378003/diff/38001/src/hydrogen-instructions.h#newcode3419
src/hydrogen-instructions.h:3419: Representation r =
Representation::Tagged(),
As discussed offline: Please don't add default parameters to this
constructor. This constructor should only be called for very well-known
values, where all the arguments can be explicitly specified.

https://codereview.chromium.org/22378003/

--
--
v8-dev mailing list
[email protected]
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 [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to