This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 226080 - org.netbeans.modules.findbugs.options.FindBugsPanel.<init>: LowPerformance took 3081 ms.
Summary: org.netbeans.modules.findbugs.options.FindBugsPanel.<init>: LowPerformance to...
Status: RESOLVED WORKSFORME
Alias: None
Product: platform
Classification: Unclassified
Component: Module System (show other bugs)
Version: 7.3
Hardware: All All
: P4 normal (vote)
Assignee: Jaroslav Tulach
URL:
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2013-02-13 18:05 UTC by Exceptions Reporter
Modified: 2013-03-21 09:06 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 198573


Attachments
nps snapshot (40.73 KB, application/nps)
2013-02-13 18:05 UTC, Exceptions Reporter
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Exceptions Reporter 2013-02-13 18:05:26 UTC
This bug was originally marked as duplicate of bug 213203, that is already resolved. This bug is still valid, so this seems to be another bug, but it might be related.

Build: NetBeans IDE 7.3 Beta 2 (Build 201211062253)
VM: Java HotSpot(TM) 64-Bit Server VM, 23.6-b04, Java(TM) SE Runtime Environment, 1.7.0_11-b21
OS: Windows 8
Maximum slowness yet reported was 3081 ms, average is 3081
Comment 1 Exceptions Reporter 2013-02-13 18:05:28 UTC
Created attachment 131357 [details]
nps snapshot
Comment 2 Jan Lahoda 2013-02-13 23:27:57 UTC
The constructor of FindBugsPanel does this:
----
        defaultsToDisabled = cc != null;
        WORKER.post(new Runnable() {
            @Override public void run() {
                final TreeNode root = backgroundInit();
                
                SwingUtilities.invokeLater(new Runnable() {
                    @Override public void run() {
                        FindBugsPanel.this.removeAll();
                        FindBugsPanel.this.uiInit(filter, root, cc);
                    }
                });
            }
        });

        setLayout(new GridBagLayout());
        add(new JLabel(Bundle.LBL_Loading()), new GridBagConstraints());
----

I don't know how it could do less, or how I could make it work faster. In fact, the snapshot shows 1238ms spent in this constructor, out of which 1174 is spent in JPanel's constructor, ultimately spent in classloading, which spends the time in opening the zip files. So I guess its the classloading that needs to be made faster. (Remaining 63.5ms is spent in Bundle.LBL_Loading() - I can stop using NbBundle.Messages, if that is desired.)
Comment 3 Jaroslav Tulach 2013-03-21 09:06:48 UTC
The only way to deal with this is to preload the classes outside of EDT. Anyway it is 3s in 7.3beta, single report. Classifies at most to P4 and closing anyway while waiting for more reports.