David P Grove wrote:
The frequency estimator is supposed to be either profile-driven or
structural if no profile information is available. So, it doesn't
look at the loop bounds themselves, just the branch probabilities
(which will either be 0.5 if unknown or "real" values derived from
edge count profiles if we have them). As I understand the bug you are
describing LICM is actually doing the right thing, but we've given it
bad frequency information so it's garbage in garbage out. I'd suggest
looking into why OPT_EstimateBasicFrerquencies is doing the wrong
thing. Quite a few optimizations are driven by the frequency
estimates, so if they are wrong more than just LICM is impacted. I can
help out with debugging the frequency estimation code if you want.
Sorry, a related issue is we should probably open an RFE so that the
block frequency estimator uses the annotated LST nodes. This calculates
upper and lower bounds, strides and the like, if the information exists
- which it won't in this case :-)
Ian
Logged In: YES
user_id=1215435
Originator: YES
Moved to JIRA: http://jira.codehaus.org/browse/RVM-578