Turning off pre-emption (see an earlier post) didn't work. In fact, although I didn't benchmark it, I think it made things slightly worse. I've still got the commit=60,noatime,nodiratime in fstab, as that seems harmless enough and may possibly have made a very slight difference despite the following:
a) Performance before making any changes:
- Code: Select all
# hdparm -tT /dev/sda
/dev/sda:
Timing cached reads: 6192 MB in 2.00 seconds = 3102.36 MB/sec
Timing buffered disk reads: 142 MB in 3.04 seconds = 46.78 MB/sec
b) Performance with the commit=60,noatime,nodiratime in fstab:
- Code: Select all
# hdparm -tT /dev/sda
/dev/sda:
Timing cached reads: 5148 MB in 2.00 seconds = 2578.84 MB/sec
Timing buffered disk reads: 122 MB in 3.02 seconds = 40.36 MB/sec
Read rates are worse for case (b)!
Well, below are a few of the suggestions on the Gentoo forums:
1. Disable pre-emption. (Didn't work for me.

)
2. commit=60,noatime,nodiratime in fstab (Didn't work for me.

)
3. Look at CFLAGS. (I have not tried it yet.)
4. Change from ext3 to ext2, ext4 or reiserfs. (I have not tried it yet.)
5. Install Gentoo x86 instead of x86_64. (I have not tried it yet.)
6. blockdev --setra 16384 /dev/sda (Didn't work for me.

)
7. Change the I/O scheduler from CFQ to deadline-scheduler in grub.conf or kernel config. (I have not tried it yet.)
8. Adjust SWAPPINESS from 60 (default) to 20. (Didn't work for me.

)
9. Device Drivers --->
ATA/ATAPI/MFM/RLL support --->
<*> XXXXXXXX chipset support (if it exists)
(ATA/ATAPI/MFM/RLL support is disabled in the SL 2.6.26 kernel, being superseded by SCSI support, and, in any case, I couldn't see an entry for my particular Intel chipset.

)
10. Turn off nmi_watchdog in grub.conf (I've tried it and it does not seem to have any effect.

)
11. Set libata (CONFIG_ATA) but not IDE (CONFIG_IDE) (This is the 2.6.26 SL config default anyway.

)
12. Turn off CONFIG_CC_OPTIMIZE_FOR_SIZE (This is the 2.6.26 SL config default anyway.

)
13. Use compcache (I have not tried it yet.)
So, where am I now? Well, I performed Step 10 above and rebooted (with Compiz-Fusion enabled) and it didn't make any difference. Neither did it when I then exited from Compiz-Fusion. But I left Compiz-Fusion off and shut down, and I've just rebooted and at least now the video does not pause/stutter while I don't touch anything. So is that just down to not having Compiz-Fusion starting after boot, or have Steps 2 and 10 also played a part? I shall have to remove them one by one to see.
Well, at least I can get the SL x86_64 performance on my laptop to be a bit better by disabling Compiz-Fusion, although it's still not
nearly as good as the performance under Windows XP on my laptop or under Vista on my tower PC (see my earlier post). And viewing videos with Compiz-Fusion enabled is a total non-starter.

I'm going to continue to investigate. My gut feeling is still that this is a kernel issue. I've noticed that if I just leave the video running with Compiz-Fusion then it pauses and/or stutters periodically, and so does the disk LED on my laptop, so I still believe this is somehow tied to SATA I/O. I wonder what kernel 2.6.27 will bring?
EDIT: Fixed a few typos (to help searching in future.)