Re: Shrinking GTK for PDA usage



On Mon, 2002-06-17 at 03:59, Sven Neumann wrote:
> > As I wrote before, fonts are a bigger part of the size problem than the
> > libraries themselves - truetype fonts, in particular, are huge. And the
> > rest of the Linux OS overhead ain't too shabby either, in my case, over
> > 5x the size of the graphics core. 
> > 
> > Got numbers for a directFB one, on arm? (glib 2.0/gtk 2.0/pango/atk/etc)
> 
> I should have at least given you some numbers. Sorry, I don't have any
> at hand for the ARM platform, but here are some for ix86 measured a few
> months ago:
> 
> libgtk-directfb-2.0.so.0   2163k
> libgdk-directfb-2.0.so.0    307k
> libatk-1.0.so.0              82k
> libgdk_pixbuf-2.0.so.0       71k
> libpangoft2-1.0.so.0        176k
> libpango-1.0.so.0           189k
> libgobject-2.0.so.0         216k
> libgmodule-2.0.so.0          10k
> libglib-2.0.so.0            396k
> libdirectfb-0.9.so.10       148k
> libfreetype.so.6            246k
> libpng.so.2                 174k
> libz.so.1                    55k
>                            -----
>                            4233k
> 
> This is a full-featured GTK+-2.0 setup. We have been able to strip
> GTK+ down to below 1MB by removing lots of widgets we don't need. Of
> course this is very application-dependant:
> 
> libgtk-directfb-2.0.so.0    962k
>                            -----
>                            3032k
>                            
> 
> the dependency on libatk can easily be dropped and the size of
> freetype may also be reduced by removing unneeded font drivers so it
> should definitely be possible to get a useful GTK+-2.0 setup below
> 3MB. Of course we have omitted the kernel, the base system as well as
> libc in this calculation.
> 
> Using dietlibc, we have also created a statically linked GTK+-2.0
> application that has _no_ additional dependencies and weights in under
> 2MB. Oh well, perhaps I should sit down and prepare the slides from
> our talk at Guadec3 for the web.

I didn't include libz, png, and freetype in my calculation, because they
are common between the two comparisons. I note you didn't include
numbers for gdk-pixbuf's loaders (neither did I, but I will), and that
you don't have any applications listed. I'd be very interested in
hearing more about the size of the rest of your stack (java, mhp,
browser, etc)

As a rule of thumb, code expansion on gcc 2.9.5 of arm and powerpc, vs
x86, is about 1.2. Mips is worse, about 1.7. 

The course you are on is exactly the right thing for a single
application (e.g. MHP) implementation, but inappropriate for less
specialized (e.g. PDA) implementations.

> 
> 
> Salut, Sven
-- 
______________
Michael Taht			BLOG: http://the-edge.blogspot.com
Member, Visionary Staff 	MontaVista Software

"The difficulty in managing [technology] displacement threats is often 
attributed to an unwillingness to cannibalize existing technology 
investments; organizational inertia; and the inability to adopt
necessary 
skills needed to engage in the new technology." - Ron Adner




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]