Postcards from the Fridge

Thursday, June 15, 2006

She sells Seashells

No concrete progress right now, as I've basically been doing research.

Reading Code
I've been spending alot of 'heads-down' time reading through the nautilus code and docs in the nautilus directory. I'm beginning to understand how things fit together, and I can see the parts of nautilius that Federico analyzed/optimzed before.

I am currently looking at why there is such a long time between the call to gtk_main, and the first call to "nautilus-icon-container.c expose_event()". I've been stepping through the code with gdb just to get some idea of how it all fits together. This is horrible from a timing point of view, but at least I can see what parts of this enourmous system are called when.

I know that this has been said before, but the asynchronous nature of nautilus makes it tricky to figure out what is happening and why.

Tracing
I also understand a little bit about how Federico's tracing code works. It is a clever (ab)use of the 'access ' system call to basically put an arbitrary message in strace's message buffers. Strace provides the time stamps, and handles the case where multiple threads might be calling the log function at the same time.
Neat.

BTW. If we would wrap this tracing in a check for an env variable (GNOME_TRACING? GNOME_LOG?), we should be able to include this in the source and ship it. That way we can trace/time this stuff in the field. A call to getenv is SO lightweight, that benefit should outweigh the cost.

....
I haven't been able to use Federico's patches directly because I can't get strace to work on 'startx' when running FC5. It probably doesn't like a user stracing a SUID (X) executable. I wrote another variation which doesn't use strace, and instead opens a file, and dumps a timestamp and the message when the log function is called.

BTW. Does anyone know how to make strace work on FC5?

When I start to 'strace startx' it doesn't work and I get some SElinux errors. I know this is vague, but maybe it rings a bell for someone.
X startup

Last time I talked about some Xorg developers getting a 2X imrpovement in startup time. Turns out it was closer to 5%. (Which is still nice).

Why 2X? The original timings where when running strace on X. Since the patchs removed MANY MANY system calls, it greatly decreased the overhead generated by strace, and as a result greatly sped-up the startup.

Graduated
On a personal note, I got my Masters last Thursday. I flew from Pittsburgh, PA to Cambridge, MA and back again within 24 hours. I flew through Philadelphia and sat in the airpot for HOURS as weather conditions slowed down the flights. (Why can't all airports be like Pittsburgh and give free wifi?)

I didn't get home to 3am, and worked the next morning. Ugh.

--Phil

1 Comments:

  • Hello
    I tested "strace startx" on FC5 with SELinux disabeld, and I didnt have errors. If you have the rights to disable SELinux, I think it will work.
    Thank for your work and your blog.

    By Blogger Mariot Chauvin, at 9:18 AM  

Post a Comment

<< Home