How to counter object created by hotspot

Coleen Phillimore - Sun Microsystems Coleen.Phillimore at Sun.COM
Mon Jul 13 17:51:40 PDT 2009


Forgot to also copy hotspot-dev.

On 07/13/09 18:16, Coleen Phillimore - Sun Microsystems wrote:
>
> There are monitoring and management tools, try jmap and jhat.
> http://java.sun.com/developer/technicalArticles/J2SE/monitoring/
>
> Coleen
>
> On 07/13/09 17:58, Colin(Du Li) wrote:
>> Can anyone give a hand?
>> Thanks a lot!
>>
>> Colin
>>
>> Colin(Du Li) wrote:
>>   
>>> Hi, guys,
>>>
>>> I wanna count the number of Java Objects created by Hotspot. Does Hotspot
>>> have some tool to count them?
>>>
>>> If no, I just count how many times the following two methods are invoked,
>>> is that accurate? 
>>>             CollectedHeap::common_permanent_mem_allocate_init(size_t size,
>>> TRAPS)
>>>             CollectedHeap::common_mem_allocate_init(size_t size, bool
>>> is_noref, TRAPS)
>>>
>>> Is there better solution to do this counting?
>>>
>>> p.s. I use serial GC.
>>>
>>> Thanks a lot!
>>>
>>> Colin
>>>
>>>     
>>
>>   
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.openjdk.java.net/pipermail/hotspot-dev/attachments/20090713/a77a355e/attachment.html 


More information about the hotspot-dev mailing list