Comment 3 for bug 689741

Revision history for this message
eXtace (djandruczyk) wrote :

Removing a call to a cpu eating yet UNNEEDED function isn't trivial? I don't understand your reasoning. Removing 10 year old UNUSED cruft that results in a significant speedup to Applications with large(r) numbers of widgets, seems like a win, esp since it appears to be unused and unneeded.

From My chat logs with Owen taylor on #gtk+ (irc.gnome.org)

(10:54:06 AM) owen: profiling it seems to indicate some possible major optimizations - weirdly most of the time seems to be spent on a piece of GTK+ that isn't really used at all - support for widgets shaped with the SHAPE extension
(11:01:45 AM) owen: dj1: I don't have a source build of GTK+ 2.0 around, but if you have one or want to create one ,and you remove the call to gtk-widget_reset_shapes() from gtk_widget_set_style_internal() I think that will help a lot
(11:02:40 AM) owen: (it was added for some experiemental stuff we did when we were first adding theming to GTK+ in 1998 and has absolutely no point now)
(11:17:41 AM) dave: owen: huge improvement for your test program with that fix. i can get up to 32x32 easily, and even up to 48x48 without pegging the cpu, though it renders at a bit over half speed at that size
(11:18:16 AM) dave: I'm going to see if ubuntu will accept that as a patch as its bound to improve other areas I suspect.
(11:21:08 AM) owen: dj1: filed https://bugzilla.gnome.org/show_bug.cgi?id=637155 for and https://bugzilla.gnome.org/show_bug.cgi?id=637156 for the two issues that combine together here to create the problem
(11:21:45 AM) dave: owen: the patched GTK+ solves the render issue in my app, thanks for the help!
(11:24:18 AM) owen: dj1: thanks for mentioning the problem, and sorry for blaming your app. :-) I knew there was something going weird that wasn't just GTK+ recomputing sizes, but wasn't expecting it to be some left-over code in GTK+ from a decade ago.

Even owen admits it was forgotten leftover code.