LWN.net Logo

Xfce 4.4: The best lightweight desktop environment (Linux.com)

Xfce 4.4: The best lightweight desktop environment (Linux.com)

Posted Feb 21, 2007 3:59 UTC (Wed) by drag (subscriber, #31333)
In reply to: Xfce 4.4: The best lightweight desktop environment (Linux.com) by i3839
Parent article: Xfce 4.4: The best lightweight desktop environment (Linux.com)

Gnome's not that horrible when it comes to memory usage.

If you look at the default setup from XFCE and the default setup from Gnome folks, the default gnome setup and not the way it's configured from distributions, then XFCE only has the advantage of a couple dozen megs less then gnome.

More or less.

By the time you try to get a full XFCE desktop running with applications and such.. if you try to avoid Gnome as much as possible and use non-gnome applications... then with XFCE you'll probably end up using MORE ram then Gnome with a bunch of it's applications open.

Personally right now I am running OpenBox with XFCE panel and mostly gnome applications. The only thing I start up automaticly for gnome-support-wise is gnome-settings-manager, which I stuck in my xinitrc because I like gnome's theming support.

The only things I have open right now is Epiphany and Gnome-terminal (UTF-8 support niceness) and it's cruising along with 96megs being used. The largest user, after the browser, is X-windows itself.


(Log in to post comments)

Xfce 4.4: The best lightweight desktop environment (Linux.com)

Posted Feb 21, 2007 7:18 UTC (Wed) by muwlgr (guest, #35359) [Link]

Modern xterm versions support UTF-8 just as nicely, for abour 3..4 years already. And xterm is light, its memory consumption does not grow exponentially with development progress. No terminal is nicer than xterm with 'terminus' font :>

As for tabs, I just had not got used to them.
Don't know if this feature is really worth.

Xfce 4.4: The best lightweight desktop environment (Linux.com)

Posted Feb 21, 2007 15:12 UTC (Wed) by drag (subscriber, #31333) [Link]

I don't use tabs either.

Gnome-terminal may be more bloated, but it's faster. If that sort of thing matters for you.

time seq 1 8 |while read i;do find;done

Just doing find on my home directory. It's all in cache so it's not bound by disk i/o any.

for Gnome-terminal:
real 0m23.513s
user 0m1.076s
sys 0m1.232s

For Xterm:
real 1m2.605s
user 0m1.580s
sys 0m1.464s

And that is gnome-terminal using the 'DejaVu Sans Mono Book' font with the 'best shapes' font rendering vs whatever is the default for xterm.

Although it's slightly faster opennning up...
time seq 1 18 |while read i;do xterm -e ls ;done

for gnome-terminal
real 0m8.645s
user 0m1.784s
sys 0m0.424

for xterm
real 0m7.079s
user 0m3.036s
sys 0m0.320

$ xterm -v
XTerm(224)

Gnome gnome-terminal 2.14.2

:)

Xfce 4.4: The best lightweight desktop environment (Linux.com)

Posted Feb 21, 2007 18:56 UTC (Wed) by kreijack (guest, #43513) [Link]

My tests:

konsole: time python -c "print 'a'*10000000"
[...]
real 0m4.268s
user 0m0.040s
sys 0m0.120s

xterm: time python -c "print 'a'*10000000"
[...]
real 0m17.486s
user 0m0.032s
sys 0m0.220s

gnome-terminal: time python -c "print 'a'*10000000"
[...]
real 0m38.939s
user 0m0.036s
sys 0m0.132s

The tests was performed on a AMD Sempron 3000+, on a [k]ubuntu
edgy. The DE was kde; the graphics adapter was a NVidia GeForce 5200. The
font are the same under gnome-terminal and konsole (Bitstream Vera Sans
Mono 12pt); under xterm the font was the "huge" and the windows size was
the same of the other two console.

I repeated the test several times, and konsole requires about 4-6 seconds;
xterm requires 15-18 seconds; and gnome-terminal requires 38-40 seconds.

Goffredo

Xfce 4.4: The best lightweight desktop environment (Linux.com)

Posted Feb 21, 2007 19:23 UTC (Wed) by muwlgr (guest, #35359) [Link]

Please also check and specify if you have 'multiScroll' set to 'true' in your xterm resources. This should speed things up.

As I see there is quite an speed race between various x-terminals developers. In Gnome 2.14, gnome-terminal had been sped up greatly. But it is also worth to note that this speed-up is mostly for local case (X client and server both on the same host). xterm as lower-level X application is said to have more stable performance being run over the network.

Xfce 4.4: The best lightweight desktop environment (Linux.com)

Posted Feb 22, 2007 8:02 UTC (Thu) by drag (subscriber, #31333) [Link]

cool. I like fast x terminals. Used to be these things would bring a machine to it's knees.

I am using PowerPC 1.2ghz G4 with ATI 9200 DRI/XAA drivers.

The
time python -c "print 'a'*10000000"
microbenchmark

With Gnome-terminal:
real 0m19.088s
user 0m0.059s
sys 0m0.382s

With Xterm:
real 0m24.315s
user 0m0.052s
sys 0m0.364

I tried the tables thing by sticking:
xterm*multiScroll: on

in .Xresources file. But it didn't seem to make any difference.

Now with remote X it was pretty bizzare.

This is going over ssh on a internet connection with a 45KB/s connection between both hosts.
ssh -X remote-host gnome-terminal

I ran:
time python -c "print 'a'*10000000"
real 0m5.861s
user 0m0.016s
sys 0m0.068s

!!! that's bizzare.

Then I tried my first microbenchmark which was run find on my home directory
find ./

First time I ran it I got 1minute 23 seconds. But second time I ran it I got:
real 0m28.653s
user 0m0.584s
sys 0m1.480s

And the 3rd time was exactly the same.

Just so you know...
time find ./ |wc
133705 151271 10996476

real 0m19.248s
user 0m1.444s
sys 0m0.812s

(which I suppose is why the python command is much better, eh?)

Now with:

user 0m0.052s
sys 0m0.364

I tried the tables thing by sticking:
xterm*multiScroll: on

in .Xresources file. But it didn't seem to make any difference.

Now with remote X it was pretty bizzare.

This is going over ssh on a internet connection with a 45KB/s connection between both hosts.
ssh -X remote-host gnome-terminal

I ran:
time python -c "print 'a'*10000000"
real 0m5.861s
user 0m0.016s
sys 0m0.068s

!!! that's bizzare.

Then I tried my first microbenchmark which was run find on my home directory
find ./

First time I ran it I got 1minute 23 seconds. But second time I ran it I got:
real 0m28.653s
user 0m0.584s
sys 0m1.480s

And the 3rd time was exactly the same.

Just so you know...
time find ./ |wc
133705 151271 10996476

real 0m19.248s
user 0m1.444s
sys 0m0.812s

(which I suppose is why the python command is much better, eh?)

Now with:
ssh -X remote-host xterm

real 9m3.364s
user 0m0.020s
sys 0m0.048

!!!

That's over 9 minutes for xterm versus 5 _seconds_ for gnome-terminal.

And I was watching the bandwidth usage. It got a solid 42-46 KB/s the entire time. There was only a disconnect for about 6 seconds.

time find ./
real 14m37.836s
user 0m0.464s
sys 0m1.100s

That's 15 minutes for Xterm vs 25 seconds for Gnome-terminal.

That's bizzare. The Gnome folks are nailing some sort of optimization in their libraries for this. Are they incorporating NX optimizations or something?

I am sorry, but this is hilarious. Completely unexpected.
Comparing Gnome-terminal vs Xterm over a slow network connection is like watch Gozilla vs Methuselah (in his later days) in a no-hold-barred cage fight.

To be fair I tried
ssh -XC remote-host xterm

The python command gave me this:
real 0m22.725s
user 0m0.020s
sys 0m0.088s

So compression helps a lot.

The find ./ game me this
real 1m30.950s
user 0m0.464s
sys 0m1.140s

So I tried it with gnome-terminal and compression:

The python command:
real 0m5.912s
user 0m0.016s
sys 0m0.088s

the find command:
real 0m24.609s
user 0m0.512s
sys 0m1.460s

So not that much of a difference, for gnome-teminal.

So I figure I don't want any disk I/O limits to limit performance.
So I mounted tmpfs to /mnt
and went:
find ./ > /mnt/cow

That created a 11meg file.

So with:
ssh -XC remote-host gnome-terminal

Then:
time cat /mnt/cow
real 0m7.314s
user 0m0.000s
sys 0m0.168s

With
ssh -XC remote-host xterm
real 1m18.927s
user 0m0.008s
sys 0m0.128s

Then for comparision the amount of time it takes to transfer the file.

time scp -C remote-host:/mnt/cow ./
cow 100% 10MB 488.1KB/s 00:22

real 0m27.538s
user 0m0.483s
sys 0m0.265s

Keep in mind that there was about 3-4 seconds before the command launched.

So Gnome-terminal is cheating. Cheating heavily. I don't dissaprove.

Is there a better benchmark? Or is this going to reflect real-world performance? I don't have any problem using either over the connection.

Xfce 4.4: The best lightweight desktop environment (Linux.com)

Posted Feb 22, 2007 8:08 UTC (Thu) by drag (subscriber, #31333) [Link]

Sorry for the very long post.

I won't do it again. It's absurdly long.

Xfce 4.4: The best lightweight desktop environment (Linux.com)

Posted Feb 24, 2007 20:06 UTC (Sat) by mikov (subscriber, #33179) [Link]

I did a few tests on my machine. gnome-terminal came out 2 times faster than xterm with the "python" test. konsole came out 30 times faster than xterm ! I am as surprised as you are.

As for starting time, xterm literally trumps them. From this test (time seq 1 18 |while read i;do xterm -e ls ;done) I have:

xterm - 2.723s
gnome-terminal - 11.137s
konsole - 15.590s

In all cases I had another instance already open.

Xfce 4.4: The best lightweight desktop environment (Linux.com)

Posted Mar 1, 2007 11:19 UTC (Thu) by azverkan (guest, #41051) [Link]

Give multi-gnome-terminal a try.

It's nearly as fast as xterm, but with support for tabs.

Xfce 4.4: The best lightweight desktop environment (Linux.com)

Posted Feb 23, 2007 6:48 UTC (Fri) by muwlgr (guest, #35359) [Link]

May be gnome-terminal does more aggressive "perceptive" optimizations. i.e. it buffers everything until network becomes ready, or until its application calls "read" from the pty. Which xterm does not and so loses, unfortunately.
It could be understood that on slower networks gnome-terminal could be even faster since it has to update its window less frequently than in local case.
Weird, indeed. But anyway, these optimizations do not seem to be a "rocket science" and I think it should not be hard to repeat them in xterm.
Should Dickey wish it :>

Xfce 4.4: The best lightweight desktop environment (Linux.com)

Posted Feb 23, 2007 20:14 UTC (Fri) by i3839 (guest, #31386) [Link]

Oh guys, look at you: Benchmarking text output speed for terminals.

I don't want my terminal to spit out too much data to read quickly, I want it to start up instantly when I need it. So go test that on a non-native system. (That is, no konsole on KDE, or Gnome-terminal on Gnome. Try it on twm or something.) Doing it after an "echo 3 > /proc/sys/vm/drop_caches" might be fun too.

Starting up rxvt is instantly for me, but takes noticable time when Firefox is in the background (when it instantiates in front of FF I mean).

Xfce 4.4: The best lightweight desktop environment (Linux.com)

Posted Feb 21, 2007 20:03 UTC (Wed) by oak (subscriber, #2786) [Link]

> The largest user, after the browser, is X-windows itself.

By "X-windows" I assume you mean the X server. If you check out where
the X server memory actually goes with e.g. pmap and xrestop, you
probably find out it's:
- video card memory mapped from the kernel
(i.e. not really X server memory)
- browser's pixmaps it's storing at the X server side
X server in itself uses fairly little memory.

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds