Lithium is probably the least invasive way to remove checks (last-minute). For now it is probably alright to keep it there if there's not too much code (so we
can easily move things when it becomes relevant).

Added some structural comments inline.


https://chromiumcodereview.appspot.com/12225099/diff/4001/src/ia32/lithium-codegen-ia32.cc
File src/ia32/lithium-codegen-ia32.cc (right):

https://chromiumcodereview.appspot.com/12225099/diff/4001/src/ia32/lithium-codegen-ia32.cc#newcode5338
src/ia32/lithium-codegen-ia32.cc:5338: if
(maps->at(i)->is_dictionary_map()) can_ommit_checks = false;
This could should really go somewhere else; probably in the map. Add a
utility method Map::CanOmitPrototypeChecks or so.

https://chromiumcodereview.appspot.com/12225099/diff/4001/src/objects.cc
File src/objects.cc (right):

https://chromiumcodereview.appspot.com/12225099/diff/4001/src/objects.cc#newcode5296
src/objects.cc:5296:
DeoptimizeDependentCodes(DependentCodes::kPrototypeCheckGroup);
Placing this in CopyDropDescriptors is probably a bit too heavy-weight,
given that you only care about this when transitions are added. I
presume you could rather use the Map::AddTransition api as entry-point
to deoptimize. It already special-cases for the case that you are adding
the first transition.

https://chromiumcodereview.appspot.com/12225099/diff/4001/src/objects.cc#newcode9581
src/objects.cc:9581: }
I guess the if(!..) { } is not necessary; since after you go over it,
it'll always be set to true. I presume set_marked doesn't trigger extra
computation given that it's lowercase; but if it does, you could move
the condition in that method.

https://chromiumcodereview.appspot.com/12225099/diff/4001/src/objects.cc#newcode9582
src/objects.cc:9582: }
I don't particularly like this API. It seems like we'd want to have an
iterator here. Also codes->Compute...(starts) seems a bit odd. Why not
just ::GroupStartIndexes starts(codes) and let the constructor compute?

https://chromiumcodereview.appspot.com/12225099/

--
--
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