GNOME Bugzilla – Bug 588438
awn uses 100% cpu with gtk+ 2.17.3 (csw)
Last modified: 2009-08-14 12:57:58 UTC
the bug has been opened on https://bugs.launchpad.net/bugs/398008 "when awn is opened, cpu usage raises to 100% which leave the system completly unoperable a lot of errors in .xsession-errors: (awn:20360): Gdk-CRITICAL **: gdk_region_destroy: assertion `region != NULL' failed The same problem with the version from: http://ppa.launchpad.net/awn-testing/ppa/ubuntu" the issue is still there using gtk 2.17.4
It would be nice if you could get a stacktrace from where those assertions occur.
Created attachment 138832 [details] downstream bug-buddy stacktrace Here's a stacktrace (created via bug-buddy) from the downstream bug.
+ Trace 216546
these two would be most helpful in figuring out where the problem lies... any chance you can repeat that with awn debuginfo ?
One of missing functions will be configure-event callback.
Created attachment 138846 [details] Full backtrace
Created attachment 138853 [details] callgrind profile file I think this callgrind produced file can shed more light on the real issue - if you view it (using kcachegrind for example), you can see that most time is spent in gdk_cairo_set_source_pixbuf, which is called in somewhere in the expose-event callback, in fact the expose-event is called over 3400 times, but there was no reason for so many exposes - but please note that the widget which was being exposed has in the parent hierarchy a widget on which gdk_window_set_composited(widget, TRUE) was called, this is probably the reason of the never-ending exposes.
The critical errors are from bug 589275 (fixed).
After additional testing the actual issue was identified - the never-ending redraws are caused by a gdk_window_raise() call inside expose-event callback. This python script demonstrates it (works on in GTK versions prior to 2.17.3, 100% cpu in latest versions): import gtk win = gtk.Window() label = gtk.Label("non-empty label") win.add(label) def expose_cb(widget, event): widget.window.raise_() return False win.connect("expose-event", expose_cb) win.show_all() gtk.main()
I guess it should be clear that that is not a good idea...
I agree, but it's still a regression.
Fixed in git master
users have confirmed that the fix is working
(using the 2.17.7 tarball version)
the bug is fixed in git now