[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug awt/28186] New: Graphics2D.drawString slowdown
From: |
hendrich at informatik dot uni-hamburg dot de |
Subject: |
[Bug awt/28186] New: Graphics2D.drawString slowdown |
Date: |
28 Jun 2006 07:59:14 -0000 |
As free swing is getting mature now, I tried actually running a few of
applications on classpath+jamvm instead of the JDK. Startup is pretty fast,
and initial performance is often ok. However, after some minutes of runtime,
some applications start to react very slowly. It seems the problem is related
to Graphics2D.drawString.
1. One way to reproduce this is running my sudoku solver. Start and begin to
solve a game. Initial GUI performance is pretty good, but after a few minutes
a single repaint (triggered by mouse moves or clicks or keytypes) takes over
a second and using the application becomes very hard.
http://tams-www.informatik.uni-hamburg.de/personal/hendrich/sudoku/)
Once the app is sluggish, top shows the following (linux x86):
1421 root 25 0 97512 31m 3680 R 69.4 6.3 1:40.12 X
1863 hendrich 15 0 21348 20m 5984 S 12.0 4.1 1:14.46 jamvm
1845 hendrich 15 0 31064 30m 2132 S 0.7 6.0 0:01.15 gdb
but stacktraces look normal for all threads. Note that the memory usage for
jamvm looks ok (no leak). I also tried running with cacao, which shows the
same symptom (but also seems to leak memory).
As SudokuCanvas.paintComponent() only uses fillRect and drawString, this
means the problem is probably related to Graphics2D.drawString.
2. I see similar behaviour (initially ok, unuseable after some work) for other
Swing apps which do frequent repainting.
3. To provide a testcase, I added a "drawString" mode to my GraphicsDemo
benchmark test. Compile and run, then select the "drawString" mode a let
the app run for a few minutes. Initial redraw times are reasonable, but
after about three minutes (on my system) the redraw times suddenly increase
(from about 300ms per frame to over 1000ms per frame) and never recover.
Redraw times for the other graphics operations do not show this sudden
degration.
Could anyone please confirm that the slowdown happens on other systems, too?
Any ideas on how to debug this?
Any ideas on how to write a Mauve test for this - it needs to run for
minutes before the bug occurs for the first time...
--
Summary: Graphics2D.drawString slowdown
Product: classpath
Version: 0.92
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: awt
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: hendrich at informatik dot uni-hamburg dot de
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28186
- [Bug awt/28186] New: Graphics2D.drawString slowdown,
hendrich at informatik dot uni-hamburg dot de <=