2011/6/22 Fabrizio Giudici <[email protected]>

> On 06/22/2011 03:14 PM, Cédric Beust ♔ wrote:
>
>> Amazing, and disappointing too. If javac misses that, what else is it
>> missing?
>>
> OTOH, I'm wondering whether this is irrelevant from the performance
> perspective as the JIT will optimize it correctly...


Probably (although I'm not sure, since it's a one time initialization, isn't
it exactly what a JIT would not bother with?), but it's such an easy
peephole optimization (constant expression) that I would think this kind of
thing would be in the 1.0 version of a compiler...

-- 
Cédric

-- 
You received this message because you are subscribed to the Google Groups "The 
Java Posse" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/javaposse?hl=en.

Reply via email to