-   Linux - General (
-   -   Xfbdev starting time (

djdjdjole 10-01-2012 01:39 PM

Xfbdev starting time
I built Linux for my ARM board with Xfbdev support. This is my .xinitrc file:

twm &
xclock -geometry 30x30+0+0 &
exec xterm -geometry 50x50+1-1 -name login

When I give xinit command to start this server, xterm appears after 10 seconds and xclock, after 25 seconds more.
When command is given seccond time, then everithing is much faster. Why the diference in speed and also, how can I achieve it run faster ?


djdjdjole 10-04-2012 02:05 AM

After moderate testing I made some conclusion, but seems very fragile to me. I made testings with root file system settled at NFS and other time in SD card. Exact starting times are with NFS: xterm - after 12 sec and xclock, after 70 sec but with SD card: xterm - after 12 sec and xclock after 90 sec.
As my ARM board has 64M RAM I consider that problem is in swapping time. That would explain differences between NFS and SD card startup time (ethernet is 100Mb, SD card - 25MHz). However question exists- why difference in starting of xterm and the xclock. My only (faint) explanation is that maybe xterm uses direct X server library calls (and X server starts after 10 sec so it's libraries are then available), but xclock program is build for GTK, so GTK libraries need to be also loaded in RAM and because of that swapping exists.
Does it seem as logical explanation to anyone (not so to me)?
However, I must confess that even 30 sec sounds as pretty long time to me (CPU= 400MHz), and above mentioned times don't include kernel booting time (which is "acceptable"). Just for comparation - Windows CE 6.0 needs 7 sec (from power on) on that very same board to show desktop with icons !
I appretiate any comments.


djdjdjole 10-05-2012 05:56 AM

Probably last report regarding Xfbdev starting time, because I have no more ideas. Regarding Xterm- it is true -it uses pure Xlib library and that's why it starts first. Xclock does use GTK and it starts (much) slower.
Final test, I prepared was to install everything (kernel + root file system) in NAND FLASH of my board. In that case, Xclock starts 35 sec after command to start X (and 40 sec more should be accounted from the moment of power on).
Very, very slow and I don't know if something could be done regarding speed.


Weapon S 10-05-2012 12:19 PM

Sound like plausible times for such a system. I'm not entirely sure, but at start-up there might be some things running simultaneously in separate threads to set-up some things. Trying to start any (other) program then might go slow. Also there's the reuse of memory the second time you start it (not everything is unloaded).

djdjdjole 10-07-2012 02:17 AM

I think I can make boot time faster, for example to start in "quite" mode (although don't know the exact command) ie. without messages on tty, or possibly without udev (ie static nodes only). Also, I may exclude some services in SusV scripting system. But I don't know if anything could be done regarding application (xclock in this case) startup time. And related to that, I heard of another file system (jffs2 is mine), named ubifs, which is declared to be faster, but expect not much time to gain from it.


All times are GMT -5. The time now is 03:54 AM.