Ha, your Gnome slowdowns are nothin’

Federico, you want to improve Gnome performance? It takes me about 20 seconds (yes, twenty!) from the time I type my password in GDM until my session finishes loading up. This is on a 1 GHz iBook G4.

I’ve got a few applets: clock, system monitor, battery, processor, weather, but the big slowdown is my terminals. My session opens two gnome-terminals, each with 4 tabs, and each tab is a login shell that runs keychain.

This actually got 5-10 seconds slower when upgrading to Gnome 2.14 from 2.12 — it used to only take ~10 seconds to get everything started up.

[Gentoo] Old kernels

Just for fun:

uname on a 2.2 kernel

We’ve got ebuilds for really old stuff in our tree: linux-headers-2.0.40.ebuild, vanilla-sources-2.0.40-r1.ebuild, linux-headers-2.2.26.ebuild, vanilla-sources-2.2.26-r1.ebuild. So I decided to see whether they actually worked. The good news is, 2.2 was really easy to get up and running. Here’s the steps I followed in an attempt to get 2.0 working, but they also work great for 2.2:

  • Install from stage3 normally.
  • Set LT_KERNEL_VERSION=”2.0.0″ in make.conf and rebuild glibc. This changes the minimum ABI that glibc will run programs on. If you only want 2.2 compatibility, feel free to change that value to “2.2.0”.
  • Next, rebuild all apps with ’emerge -e world’. You can check app ABI’s with ‘file’ or ‘eu-readelf -n’. If you use ‘file’, it will show ‘for GNU/Linux 2.0.0’. If you use eu-readelf, it will show ‘OS: Linux, ABI: 2.0.0’ once things are built properly.
  • ‘echo “=sys-kernel/linux-headers-2.2* -*” >> /etc/portage/package.keywords’,
    then ’emerge =linux-headers-2.2* =vanilla-sources-2.2*’.
  • Install gcc 2.95; gcc 3.4 cannot compile a 2.2 kernel. This will require that you change your profile to a gcc2 profile. ‘cd /etc; rm make.profile; ln -s ../usr/portage/profiles/default-linux/x86/gcc2 make.profile’ The emerge of 2.95 will switch to it automatically, but remember to run ‘source /etc/profile’ before compiling the kernel.
  • Install sys-devel/bin86. It’s needed to build a 2.2 kernel.
  • Configure and compile the 2.2 kernel. It’s just like a 2.4 kernel: ‘make menuconfig; make dep; make bzImage modules modules_install’, then install the bzImage to /boot/ and set up grub.conf as usual.
  • Switch back to a gcc-3 compiler using gcc-config. Only use 2.95 for the kernel, because a lot of newer apps fail to compile with it.
  • Emerge sys-fs/static-dev since devfs wasn’t really working well, unless you want to apply the devfs patch. ‘echo “sys-fs/static-dev ~x86” >> /etc/portage/package.keywords’. You should be able to leave sys-fs/udev installed, because our startup scripts autodetect what you’re capable of.

Unfortunately glibc 2.3.4 won’t compile against linux-headers-2.0.40, so it will require some more work to drop back to a 2.0 kernel. Maybe glibc 2.2.5 will work.

[Gentoo] Xgl, getting into OSS

Finally got around to trying out Xgl on Wednesday. Used the xgl-coffee overlay (link to HOWTO) and modified ebuilds to be live cvs instead of dated snapshots, so I don’t need to ever bump them. You can get the new ones from my overlay if you want them — x11-base/{xgl,xorg-server,x11-drm}, x11-wm/compiz, x11-libs/{cairo,libdrm}, media-libs/{glitz,mesa}, x11-drivers/xf86-video-ati will get you basically the latest X there is.

After fixing an accidentally applied aiglx-only patch that made all the pixmaps upside-down in compiz, stuff worked quite well on my iBook G4 (Radeon 9600 or so).

The motivation for doing this was a demo to my LUG at the meeting. I also gave a 5-minute talk on how to get involved in open source. I’ve posted the slides [PDF], but they’re quite unhelpful without me narrating.