Instead of storing a boolean to indicate whether a field is only
intialized to an integer store the propagated type instead. If
different types are encountered for the same field indicate this with
HType.UNKNOWN.
Also fix a bug in the checking, as potential single type initializers
is not the same as known single type initializers.
This is in preparation for information on other types than integers.
R=floitsch@google.com
BUG=
TEST=
Review URL: https://chromiumcodereview.appspot.com//10584009
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8963 260f80e4-7a28-3924-810f-c04153c831b5
For each field which is accessed directly in the generated JavaScript
code track whether all the setters are setting the field to an integer
constant. If that is the case the codegen will always generate ===
comparison when comparing to an integer constant.
To know for sure that only integer constants are assigned the
functions having the getters need to be recompiled.
This gives ~10% on Delta Blue.
R=ngeoffray@google.com, floitsch@google.com
BUG=
TEST=
Review URL: https://chromiumcodereview.appspot.com//10539156
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8796 260f80e4-7a28-3924-810f-c04153c831b5
This is a prototype with the ability for dart2js to retry the
compilation of a method after everything has been compiled
once. Information collected during the first compilation can then be
used when retrying the compilation.
During compilation information on whether setters are used on specific
fields is collected. When compilation is retried and there are no
setters for a field it is treated as if it was declared final.
As this is a prototype there are some issues we need to discuss, e.g.
* The two queues should probably be generalized some way - maybe with
listeners on specific changes to the collected information
* Throwing Pass2BailoutException when retrying compilation is a bit of
a hack. We should probably not try to retry something we can't.
* Where to store the imformation collected during compilation
This is one way of improving Delta Blue with 25-30%.
R=ahe@google.com, ngeoffray@google.com, kasperl@google.com, ager@google.com
BUG=
TEST=
Review URL: https://chromiumcodereview.appspot.com//10537025
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@8647 260f80e4-7a28-3924-810f-c04153c831b5