EscapeAnalysis diagnostics + user-guided stack allocation

Vitaly Davidovich vitalyd at gmail.com
Tue Jan 17 10:48:22 PST 2012


Vladimir,

Diagnostic in product would be much appreciated - in a corporate setting
it's not that simple to get a debug build in-house, unfortunately.

I'll follow up with hotspot-dev on my 2nd question.

Thank you

Sent from my phone
On Jan 17, 2012 1:38 PM, "Vladimir Kozlov" <vladimir.kozlov at oracle.com>
wrote:

> Vitaly Davidovich wrote:
>
>> Hi,
>>
>> Is there a way, in product build, to get diagnostics on EA? For example,
>> to see which allocations in a method are removed? I realize EA is an
>> implementation detail and subject to change release to release, but it
>> would be a great option to have for performance tuning.  There are many
>> classes which are simple wrappers on top of a primitive (e.g. Apache's
>> HashCodeBuilder, EqualsBuilder) which people use, and if the allocations
>> are not removed, they create a lot of GC pressure.  In cases where EA does
>> not remove them, it would be advantageous to hand-code the functionality
>> instead of using these utility wrappers.  However, the only way to know
>> right now (to my knowledge) is to look at disassembly via hsdis -- it'd be
>> great if there was a simpler and quicker way to do that check.
>>
>
> There is debug flag PrintEliminateAllocations. Nobody asked before to make
> it available but we can change it to diagnostic flag.
>
>
>> Also, are there any plans to support struct/value-type like (ala CLR's
>> struct) constructs in the JVM (presumably java can then target it)? This
>> would allow developer to control where something gets allocated without
>> relying on EA, and it would also reduce the amount of indirection in object
>> graphs (and the mem/cpu performance hit of them) since struct members of a
>> heap allocated object could be allocated "inline".  Apologies if this
>> mailgroup isn't the most appropriate for this particular question, so feel
>> free to redirect me to the right one.
>>
>
> I don't known about such plans. Send this question to
> hotspot-dev at openjdk.java.net
>
> Vladimir
>
>
>> Thanks
>>
>> --
>> Vitaly
>> 617-548-7007 (mobile)
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.openjdk.java.net/pipermail/hotspot-compiler-dev/attachments/20120117/4b3b46f8/attachment.html 


More information about the hotspot-compiler-dev mailing list