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 100243 - Export to image is slow and freezes UI
Summary: Export to image is slow and freezes UI
Status: RESOLVED DUPLICATE of bug 78574
Alias: None
Product: uml
Classification: Unclassified
Component: Diagram Sequence (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: issues@uml
URL:
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2007-04-06 16:44 UTC by _ rkubacki
Modified: 2007-04-06 22:47 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
result of export (25.72 KB, image/png)
2007-04-06 16:45 UTC, _ rkubacki
Details
few thread dumps (62.30 KB, text/plain)
2007-04-06 16:47 UTC, _ rkubacki
Details

Note You need to log in before you can comment on or make changes to this bug.
Description _ rkubacki 2007-04-06 16:44:29 UTC
NetBeans IDE Dev (Build 200704041800, C/C++ Pack 20070404)
1.6.0_01-ea; Java HotSpot(TM) Client VM 1.6.0_01-ea-b03
Linux version 2.6.18-1.2239_1.fc5.cubbi_suspend2 running on i386
en_US (nb); UTF-8

using NBI insatller with all components.

Export of simple sequence diagram takes 80 seconds on my 1.7GHz PentiumM
notebook with 1GB RAM. The result is image of 25.7kB size. 

To make it worse the GUI is frozen during this time and does not respond to user
actions.
Comment 1 _ rkubacki 2007-04-06 16:45:11 UTC
Created attachment 40563 [details]
result of export
Comment 2 _ rkubacki 2007-04-06 16:47:19 UTC
Created attachment 40564 [details]
few thread dumps
Comment 3 Viktor Lapitski 2007-04-06 18:21:01 UTC
This piece from the attached stack trace suggests that it is a case of offscreen
pixmaps. Thus i'd close it as a duplicate of 78574. Please verify by 
trying with the -Dsun.java2d.pmoffscreen=false flag. 

   java.lang.Thread.State: RUNNABLE
        at sun.awt.image.DataBufferNative.getElem(Native Method)
        at sun.awt.image.DataBufferNative.getElem(DataBufferNative.java:57)
        at java.awt.image.DataBuffer.getElem(DataBuffer.java:219)
        at
java.awt.image.SinglePixelPackedSampleModel.getDataElements(SinglePixelPackedSampleModel.java:405)
        at java.awt.image.SampleModel.getDataElements(SampleModel.java:403)
        at java.awt.image.Raster.getDataElements(Raster.java:1503)
        at
sun.awt.image.OffScreenImageSource.sendPixels(OffScreenImageSource.java:118)
        at sun.awt.image.OffScreenImageSource.produce(OffScreenImageSource.java:169)
        at
sun.awt.image.OffScreenImageSource.addConsumer(OffScreenImageSource.java:48)
        - locked <0x6a4305f8> (a sun.awt.image.OffScreenImageSource)
        at
sun.awt.image.OffScreenImageSource.startProduction(OffScreenImageSource.java:62)
        at java.awt.image.PixelGrabber.grabPixels(PixelGrabber.java:242)
Comment 4 _ rkubacki 2007-04-06 19:05:20 UTC
Difference between this and 78574 is that this one is with local display (no
remote X)
Comment 5 Viktor Lapitski 2007-04-06 21:21:31 UTC
due to decoupled nature of X11 client-server architecture an X11 server is
always kind of "remote" even when it is being run on the same machine (i.e.
looks like "local"). (Note: most modern X servers are able to exploit the fact
of being on the same machine using something like extension mechanism (in terms
of XFree86/Xorg servers), yet it depends on how the X server was built,
installed and configured)  

Did the -Dsun.java2d.pmoffscreen=false flag solved the problem?
Comment 6 Sergey Petrov 2007-04-06 21:44:54 UTC
may be we should review issues with RE|MOTE_X and rise priority, beccause low
priority was justified we do not support remote desktop, but we support linux
with x11 :) and if issues can be reproduced..
Comment 7 Viktor Lapitski 2007-04-06 22:21:05 UTC
at this moment i'd say this question is kind of outside engineering 
realm - we know that we need this switch (at least until much more serious 
modifications, on the scale of graph rendering engine replacemnt, done). 
I even observed a case when it helped in some particular machine case of 82394, 
yet it is clashes with the performance hit on the rest of Netbeans (or so 
i heard as the reason for removing of the switch)
Comment 8 Peter Lam 2007-04-06 22:34:34 UTC
I think the exporting to png format is by itself and issue regardless of remote
or local from the users point of view. Maybe it's worse if it is thru remote.
Since we're using the 3rd party graphics library to do this, not sure what can
be done but the bug is valid in both remote and local use of ide.
Comment 9 Peter Lam 2007-04-06 22:43:19 UTC
I wanted to close this issue as a duplicate of issue 78574. I updated issue
78574 as not a specific issue on remote usage. Therefore, this is the same issue.

*** This issue has been marked as a duplicate of 78574 ***
Comment 10 Viktor Lapitski 2007-04-06 22:47:13 UTC
i fixed the specific png encoder issue in 91260.  Please let me know if it can't
be verified.