Profiling NetBeans 7.0 Beta 2 and Reporting Problems
Posted
by christopher.jones
on Oracle Blogs
See other posts from Oracle Blogs
or by christopher.jones
Published on Tue, 01 Mar 2011 13:12:10 -0800
Indexed on
2011/03/01
23:29 UTC
Read the original article
Hit count: 280
With NetBeans 7.0 recently going into Beta 2 phase, now is the time to test it out properly and report issues. The development team has been squashing bugs, including memory issues with the PHP bundle.
There are some great new PHP related features in NetBeans 7.0, so you know you want to try it out.
If you identify something wrong with NetBeans, please report it following the guidelines http://wiki.netbeans.org/IssueReportingGuidelines
Depending on the issues, data to attach to the report is mentioned on: http://wiki.netbeans.org/FaqLogMessagesFile and http://wiki.netbeans.org/FaqProfileMeNow
If you have a memory issue then a memory dump would also be useful. Run the jmap tool for this. There is some background information on http://wiki.netbeans.org/FaqMemoryDump. Here's how I used it.
First I set my environment to match the JDK used by NetBeans. In my case I am using a nightly build so the JDK is in the configuration file under $HOME/netbeans-dev-201102210501:
$ egrep netbeans_jdkhome $HOME/netbeans-dev-201102210501/etc/netbeans.conf netbeans_jdkhome="/home/cjones/src/jdk1.6.0_24" $ export JAVA_HOME=/home/cjones/src/jdk1.6.0_24 $ export PATH=$JAVA_HOME/bin:$PATH
Next, I found the correct process number to examine:
$ ps -ef | egrep 'netbeans|jdk'
cjones 23230 1 0 16:07 ? 00:00:00 /bin/bash /home/cjones/netbeans-
cjones 23438 23230 2 16:07 ? 00:00:09 /home/cjones/src/jdk1.6.0_24/bin
Finally I used the parent JDK process as the jmap argument:
num #instances #bytes class name
----------------------------------------------
1: 12075 9028656 [I
2: 49535 6581920
3: 49535 3964128 <methodKlass>
4: 80256 3840776 <symbolKlass>
5: 36093 3635336 [C
6: 5095 3341312 <constantPoolKlass>
7: 5095 2486016 <instanceKlassKlass>
8: 4325 1961432 <constantPoolCacheKlass>
9: 18729 1763976 [B
10: 59952 1438848 java.util.HashMap$Entry
. . .
This histogram memory report will help identify the kind of memory issues you are seeing. It may not be as complete as an often tens of megabyte jmap -dump:live,file=/tmp/nbheap.log 23438 heap dump, but is much more easily attached to a bug report.
If you want to keep up to date with NetBeans, nightly builds are at: http://bits.netbeans.org/download/trunk/nightly/latest/zip/
© Oracle Blogs or respective owner