Please also add tests for this functionality.

https://codereview.chromium.org/1239803004/diff/20001/src/objects.cc
File src/objects.cc (right):

https://codereview.chromium.org/1239803004/diff/20001/src/objects.cc#newcode2367
src/objects.cc:2367: if (!prev_object->IsUndefined()) {
How about adding "!old_map->is_extensible() &&" to avoid unnecessary
transition array queries?

https://codereview.chromium.org/1239803004/diff/20001/src/objects.cc#newcode2587
src/objects.cc:2587: }
You should add
  if (*target_map != *real_old_map) {
    real_old_map->NotifyLeafMapLayoutChange();
  }
here.

https://codereview.chromium.org/1239803004/diff/20001/src/objects.cc#newcode2865
src/objects.cc:2865: MaybeHandle<Map> transition_map =
TransitionForPreventExtensions(
It does not make sense to search for transition here because they do not
exist. At this point we do CopyInstallDescriptors at lease once which
creates new map without transitions. So I think you should just call
Map::CopyForPreventExtensions() here instead which will also call
necessary "real_old_map->NotifyLeafMapLayoutChange()".

https://codereview.chromium.org/1239803004/

--
--
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/d/optout.

Reply via email to