[Gtk-sharp-list] question of performance

Miguel de Icaza miguel@ximian.com
07 May 2003 02:18:02 -0400


Hello,

> I am curious about GTK# performance. After working extensively with
> Java/Swing and not being particularly happy with performance I am hoping
> to not experience the same thing with C#/GTK#. 
> 
> Also, would there be any noticeable performance difference between a
> C/GTK+ application and a C#/GTK# application (doing the same thing)?

I do not notice a difference, but am running on a pretty fast machine.

Also, Swing has earned the slow reputation due to other factors:

	* The GUI binding is relatively heavy.

	* It uses an MVC model for everything.  Which is academically
	  very nice, but in most cases it gets in the way and adds to
	  the bloat.

> With my first C#/GTK# app I noticed that my CPU usage and System memory
> usage skyrockets whenever I run it. It is a shell of an application with
> just a GUI layed out and a few callbacks connected. The only thing I can
> think of is that I am using Glade.XML and there are tons of signals not
> connected. I am also using mint (mono freaks out). Do you have any
> suggestions about this? I can provide code/more information if needed.

Mono and Gtk# will add an extra overhead over your traditional C/Gtk
application in terms of memory, as it has extra code layered on top of
Gtk#.  There are also a few memory leaks that we should track down (I
should file a bug report myself about these).

If Mono has problems running your program, it would be best if you
could file a bug report in bugzilla.ximian.com, that way we will make
sure that it gets fixed.

Miguel.