Linux vs WinXP

A forum just for SPCR's folding team... by request.

Moderators: NeilBlanchard, Ralf Hutter, sthayashi, Lawrence Lee

Post Reply
geordie
Friend of SPCR
Posts: 175
Joined: Mon Jun 09, 2003 4:00 am
Location: Reading, UK

Linux vs WinXP

Post by geordie » Thu Apr 22, 2004 12:30 am

A quick check of FahLogStats yesterday showed my WinXP machine giving an estimated ~530ppw and my linux machine ~380ppw on the same work unit. I was rather shocked at the difference so decided to wait 'til they had both finished and check the logs for the full unit times.

I've trimmed the log files to the bare essentials and added time calculations. Times are taken as

Code: Select all

time at completed 100% steps - time at completed 0% steps
Also note that all work units finish in under 24 hours, ie I haven't removed several days messages in between and hence cocked up the calculations!

WinXP machine:
AthlonXP 2500+ @2600+ (166*11.5), stock voltage in ASUS A7NX8 Dlx

Code: Select all

# Windows Console Edition #####################################################
###############################################################################

                       Folding@home Client Version 4.00

                          http://folding.stanford.edu

###############################################################################
###############################################################################

Arguments: -local -service -forceSSE -forceasm -verbosity 4 

[20:33:02] Project: 572 (Run 112, Clone 9, Gen 3)
[20:33:02] 
[20:33:02] Assembly optimizations on if available.
[20:33:02] Entering M.D.
[20:33:40] Protein: p572_L939_K12M
[20:33:40] 
[20:33:40] Writing local files
[20:33:40] Extra SSE boost OK.
[20:33:45] Writing local files
[20:33:47] Completed 0 out of 500000 steps  (0)
...
[11:40:29] Completed 500000 out of 500000 steps  (100)
[11:41:32] Folding@home Core Shutdown: FINISHED_UNIT
*Total time = 15h 8m 42s


[11:42:34] Project: 572 (Run 84, Clone 113, Gen 7)
[11:42:34] 
[11:42:34] Assembly optimizations on if available.
[11:42:34] Entering M.D.
[11:43:10] Protein: p572_L939_K12M
[11:43:10] 
[11:43:10] Writing local files
[11:43:10] Extra SSE boost OK.
[11:43:15] Writing local files
[11:43:17] Completed 0 out of 500000 steps  (0)
...
[02:49:20] Completed 500000 out of 500000 steps  (100)
[02:50:20] Folding@home Core Shutdown: FINISHED_UNIT
*Total time = 15h 6m 3s
I happened to get 2 of these proteins in a row. As you can see, the total times are almost identical. A little light web browsing here and there probably adds more margin of error.

Linux Machine:
AthlonXP 2500+ (166*11) @1.525v, Biostar M7NCG-400 v1.0

Code: Select all

# Linux Console Edition #######################################################
###############################################################################

                       Folding@home Client Version 4.00

                          http://folding.stanford.edu

###############################################################################
###############################################################################

Arguments: -advmethods -forceasm -forceSSE -verbosity 4 

[22:03:43] Project: 572 (Run 35, Clone 24, Gen 6)
[22:03:43] 
[22:03:43] Assembly optimizations on if available.
[22:03:43] Entering M.D.
[22:04:40] Protein: p572_L939_K12M
[22:04:40] 
[22:04:40] Writing local files
[22:04:40] Extra SSE boost OK.
[22:04:44] Writing local files
[22:04:47] Completed 0 out of 500000 steps  (0%)
...
[07:17:02] Completed 205000 out of 500000 steps  (41%)
* Reboot!
[07:28:31] Completed 205000 out of 500000 steps  (41%)
[07:28:32] Extra SSE boost OK.
[20:42:34] Completed 500000 out of 500000 steps  (100%)
[20:43:38] Folding@home Core Shutdown: FINISHED_UNIT
*Total time = 22h 26m 18s (accounting for down time for reboot)
I did a little web browsing on this machine too, but no compilation or any other processor intensive task.

The frame times in the log file are fairly constant throughout at ~9min per frame on WinXP and ~13min per frame on linux. This bears out the fact I wasn't doing much else with either machine. Also note the same flags are used for each and that SSE is working in both cases.

To allow for the difference in clock speed, calculate total time for WinXP at stock 166*11

Code: Select all

15:08:42 / 11 * 11.5 = 15:50:00
I believe it is fair to assume clock speed has a linear effect.

Now we have the same processor at the same speed on the same chipset, so the only (well not only but near enough) difference is the OS.

The work unit was worth 47 points.
WinXP - 15:50:00 per wu = 10.61 wu per week = 499ppw
Linux - 22:26:18 per wu = 7.49 wu per week = 352 ppw

So for this wu I get ~150ppw more just by running WinXP instead of linux :?

Someone please tell me this isn't correct :(

haysdb
Patron of SPCR
Posts: 2425
Joined: Fri Aug 29, 2003 11:09 pm
Location: Earth

Post by haysdb » Thu Apr 22, 2004 12:36 am

I can only tell you what my experience has been, and that is my WinXP machines hold a negligible (1% to 2%) advantage over my Linux blades.

Obvious question: Is something taking cpu time away from FAH on the Linux machine? Some service perhaps?

David

geordie
Friend of SPCR
Posts: 175
Joined: Mon Jun 09, 2003 4:00 am
Location: Reading, UK

Post by geordie » Thu Apr 22, 2004 3:37 am

I was expecting pretty much identical performance between OSes which is what confused me in the first place.

As far as I know I don't have anything running that should be taking much cpu time. I don't have much installed to be honest! Unless there's anything in this lot which may be the problem:

Gentoo kernel 2.4.25 and stage3 base system.
A system logger and cron daemon.
samba
kde + all the 90-odd packages it comes with!
OpenOffice
Mozilla

When I'm not logged in then kde isn't running (I just startx at the moment, haven't setup graphical login). I'll have to check the running processes when I get home, but I don't remember seeing anything unexpected last time I checked.

CoolGav
Posts: 398
Joined: Wed Jul 23, 2003 4:26 am
Location: €ngland
Contact:

Post by CoolGav » Thu Apr 22, 2004 4:06 am

from a console you can run 'top' and take a look at whats taking CPU cycles.

mas92264
Patron of SPCR
Posts: 659
Joined: Fri Sep 26, 2003 5:26 pm
Location: Palm Springs, CA, USA

Post by mas92264 » Thu Apr 22, 2004 5:58 am

Yep, something appears amiss with your Linux box. I've got the same protein, p572, running on a 2000+ Palomino and it's showing average frame times of 11:07 for a total time of <20 hours. W2k os.

Once, I was doing some testing with Prime 95 and accidentially left it running in the task bar, then started f@h. Couldn't figure out why my frame times were taking so long. :)

M

sbabb
*Lifetime Patron*
Posts: 327
Joined: Tue Aug 19, 2003 10:04 am
Location: New Hampshire, USA

Post by sbabb » Thu Apr 22, 2004 6:17 am

Samba, huh?

Does this mean that your Linux box is also a file server and it could be incurring CPU load from network requests even when you're not logged in?

tay
Friend of SPCR
Posts: 793
Joined: Sat Dec 06, 2003 5:56 pm
Location: Boston, MA
Contact:

Post by tay » Thu Apr 22, 2004 7:46 am

This is most likely due to compiler issues. gcc does not optimize particularly well especially when compared with intels optimizing compiler. Can you recompile the f@h software? Is the source available?

Samba, ftpd, ntpd, etc take up virtually no cpu time even on my p3-550. Copying at 10 MB/s on samba takes 20% cpu cycles while saturating the fast ethernet link.

geordie
Friend of SPCR
Posts: 175
Joined: Mon Jun 09, 2003 4:00 am
Location: Reading, UK

Post by geordie » Thu Apr 22, 2004 7:57 am

CoolGav wrote:from a console you can run 'top' and take a look at whats taking CPU cycles.
Excellent. Much better than ps aux I was using before!

Doesn't show anything much taking cpu time, although the extra instances of folding are puzzling.

Code: Select all

top - 16:42:37 up 1 day,  8:17,  1 user,  load average: 0.99, 0.97, 0.91
Tasks:  35 total,   2 running,  32 sleeping,   1 stopped,   0 zombie
Cpu(s):   0.0% user,  28.7% system,  71.3% nice,   0.0% idle
Mem:    482952k total,   477936k used,     5016k free,   169840k buffers
Swap:  1510100k total,        8k used,  1510092k free,   113680k cached

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND                                                      
13363 fah       20  19 28396  27m 1072 R 99.9  5.9   1127:51 FahCore_78.exe                                               
    1 root       8   0   488  484  432 S  0.0  0.1   0:04.87 init                                                         
    2 root       9   0     0    0    0 S  0.0  0.0   0:00.21 keventd                                                      
    3 root      18  19     0    0    0 S  0.0  0.0   0:00.00 ksoftirqd_CPU0                                               
    4 root       9   0     0    0    0 S  0.0  0.0   0:00.01 kswapd                                                       
    5 root       9   0     0    0    0 S  0.0  0.0   0:00.00 bdflush                                                      
    6 root       9   0     0    0    0 S  0.0  0.0   0:00.00 kupdated                                                     
  154 root       9   0     0    0    0 S  0.0  0.0   0:00.00 khubd                                                        
  800 root       9   0     0    0    0 S  0.0  0.0   0:00.00 kreiserfsd                                                   
  963 root       9   0   912  912  624 S  0.0  0.2   0:00.10 devfsd                                                       
 1867 root       9   0   704  700  552 S  0.0  0.1   0:00.07 syslog-ng                                                    
 3239 root       9   0   448  448  400 S  0.0  0.1   0:00.00 dhcpcd                                                       
 3328 root       9   0  1828 1824 1652 S  0.0  0.4   0:00.00 smbd                                                         
 3330 root       9   0  1640 1640 1124 S  0.0  0.3   0:00.14 nmbd                                                         
 3366 root       8   0   644  644  560 S  0.0  0.1   0:00.00 cron                                                         
 3527 xfs        9   0  4912 4912  960 S  0.0  1.0   0:00.32 xfs                                                          
 3559 root       9   0   664  660  580 S  0.0  0.1   0:00.00 agetty                                                       
 3560 root       9   0   664  660  580 S  0.0  0.1   0:00.00 agetty                                                       
 3561 root       9   0   664  660  580 S  0.0  0.1   0:00.00 agetty                                                       
 3562 root       9   0   664  660  580 S  0.0  0.1   0:00.00 agetty                                                       
 3563 root       9   0   664  660  580 S  0.0  0.1   0:00.00 agetty                                                       
 3650 fah        9   0   928  924  828 S  0.0  0.2   0:00.00 FaH                                                          
 3652 fah        9   0  2332 2328  792 S  0.0  0.5   0:07.60 fahclient1                                                   
 3701 fah        9   0  2332 2328  792 S  0.0  0.5   0:00.00 fahclient1                                                   
 3702 fah        9   0  2332 2328  792 S  0.0  0.5   0:00.02 fahclient1                                                   
 3703 fah        9   0  2332 2328  792 S  0.0  0.5   0:00.00 fahclient1                                                   
 3717 root       9   0  1184 1184  976 S  0.0  0.2   0:00.11 login                                                        
 3855 andrew     9   0  1268 1268 1064 S  0.0  0.3   0:00.05 bash                                                         
 9905 root       9   0  2476 2476 2144 S  0.0  0.5   0:00.04 smbd                                                         
13360 fah        9   0  2332 2328  792 S  0.0  0.5   0:00.00 fahclient1                                                   
13361 fah       19  19 28396  27m 1072 S  0.0  5.9   0:00.44 FahCore_78.exe                                               
13362 fah       19  19 28396  27m 1072 S  0.0  5.9   0:00.00 FahCore_78.exe                                               
13364 fah       19  19 28396  27m 1072 S  0.0  5.9   0:00.00 FahCore_78.exe                                               
 4508 andrew     9   0   680  672  560 T  0.0  0.1   0:00.00 top                                                          
 4544 andrew     9   0   984  984  808 R  0.0  0.2   0:00.01 top                                                          
Any ideas where the extra processes came from? They don't appear to be interfering but I don't like to see them listed anyway. Could it be something to do with how FaH is started i.e. one script calls another script which calls another script ... which eventually runs the exe file. That's how finstall set it up.
sbabb wrote:Does this mean that your Linux box is also a file server and it could be incurring CPU load from network requests even when you're not logged in?
The only other machine on the network is my WinXP box so when I'm not there samba should be idle. The only share I've setup so far is the folding directory so I can use logstats on my XP box!

I'm puzzled as to what else could be up. It is now running a p212 135 pointer and logstats reports 496ppw :? I really need another p572 on the linux box to confirm it wasn't just a freak wu.

dukla2000
*Lifetime Patron*
Posts: 1465
Joined: Sun Mar 09, 2003 12:27 pm
Location: Reading.England.EU

Re: Linux vs WinXP

Post by dukla2000 » Thu Apr 22, 2004 8:48 am

geordie wrote: I believe it is fair to assume clock speed has a linear effect.
Yes (comparing Tbred to Tbred, Duron to Duron etc).
geordie wrote:Someone please tell me this isn't correct :(
You are doing something wrong!
1) When I was swapping from Win98SE to Linux around the turn of the year I compared quite a few WU times on Win and Linux and could not find any obvious speed differences.
2) 1 of my Tbred Bs (SuSE 9, 12.5*133 = 2GHz = XP2400) is currently running a p572 just under 9 minutes a frame - log extract below. (In this case, comparing to your WinXP Barton, it seems the extra 100MHz on my CPU are equivalent to the extra cache on your Barton)

Code: Select all

[16:05:37] (Starting from checkpoint)
[16:05:37] Protein: p572_L939_K12M
[16:05:37]
[16:05:37] Writing local files
[16:05:37] Completed 368058 out of 500000 steps  (73%)
[16:05:37] Extra SSE boost OK.
[16:10:21] Writing local files
[16:10:23] Completed 370000 out of 500000 steps  (74%)
[16:19:19] Writing local files
[16:19:21] Completed 375000 out of 500000 steps  (75%)
[16:28:18] Writing local files
[16:28:20] Completed 380000 out of 500000 steps  (76%)
[16:37:17] Writing local files
[16:37:19] Completed 385000 out of 500000 steps  (77%)
ps - the 'extra' processes in Linux are normal. They are documented somewhere, can't find it to hand.

pps - you are sure both your CPUs are Bartons?
Last edited by dukla2000 on Thu Apr 22, 2004 8:55 am, edited 1 time in total.

CoolGav
Posts: 398
Joined: Wed Jul 23, 2003 4:26 am
Location: €ngland
Contact:

Post by CoolGav » Thu Apr 22, 2004 8:54 am

The extra processes you see in 'top' or a 'ps -e' are quite normal.

geordie
Friend of SPCR
Posts: 175
Joined: Mon Jun 09, 2003 4:00 am
Location: Reading, UK

Post by geordie » Thu Apr 22, 2004 9:19 am

Cheers. I'll just have to ignore the extra processes, although they do make a mess of the display :lol:

20 hours to go before it finishes the p212. The ~500ppw it is averaging for this wu seems more in line with expectation. Unless I get another p572 to compare with I might have to accept that low performance was an anomaly and (hopefully) won't happen again. Not a very satisfactory explanation though, which will bug me for quite a while :evil:

haysdb
Patron of SPCR
Posts: 2425
Joined: Fri Aug 29, 2003 11:09 pm
Location: Earth

Post by haysdb » Thu Apr 22, 2004 10:23 am

sbabb wrote:Samba, huh?

Does this mean that your Linux box is also a file server and it could be incurring CPU load from network requests even when you're not logged in?
I am running Samba also, so that I can monitor my Linux boxes from my main WinXP desktop machine.
tay wrote:This is most likely due to compiler issues. gcc does not optimize particularly well especially when compared with intels optimizing compiler. Can you recompile the f@h software? Is the source available?
No way Jose!

David

geordie
Friend of SPCR
Posts: 175
Joined: Mon Jun 09, 2003 4:00 am
Location: Reading, UK

Post by geordie » Fri Jun 04, 2004 2:53 pm

Well I'd resigned myself to the fact my Linux box was just underperforming, though it has bugged me for the last month or so. I even thought about putting XP back on it, but not for long :)

Then today I compile a new kernel 2.6.5 (I had been using 2.4.25) and instantly the performance has jumped up to the expected level. :?

I checked for any differences in the output from top and it's now saying 99.7% nice time. Checking back a couple of posts I see it was 71.3% before, with the rest system time. :shock:
Those percentages are of the right order for the points differences seen (~450ppw before, ~650ppw now).

Assuming this explains things, wtf was all that system time for. The actual fah process is listed as 99.9% cpu time in both cases.

Putz
Posts: 368
Joined: Thu Aug 21, 2003 1:25 am
Location: Ottawa, Canada
Contact:

Post by Putz » Fri Jun 04, 2004 4:10 pm

Reading over your earlier post (just now, unfortunately), I noticed that your System vs. Nice times were screwy. Mine says ~99.7%, and it's a much slower system. So, I was thinking that maybe the Linux kernel you are using has some slightly incompatible drivers or something, perhaps affecting memory access or process scheduling or who knows what.

The time taken by any system calls (ie. calls that require the kernel to do something) made by a process are still counted as part of that process' "CPU Time" figure. So if there was something within those system calls that was taking longer than it should (a lot!), it would account for the discrepancies you noted.

I have no idea what exactly was causing the problem though. Anyway, problem solved, and now your system should be back to reaching its potential! Good stuff.

trodas
Posts: 509
Joined: Sun Dec 14, 2003 6:21 am
Location: Czech republic
Contact:

Post by trodas » Sun Jun 06, 2004 5:32 am

resume: folders with linux - use the latest kernel or face poor performance :?

...but that way we never catch MAC OS X team! :o :lol:

geordie
Friend of SPCR
Posts: 175
Joined: Mon Jun 09, 2003 4:00 am
Location: Reading, UK

Post by geordie » Sun Jun 06, 2004 10:28 am

OH CRAP !!

I noticed my linux box crashed at some point yesterday. Needed hardware resetting :evil: Now take a look at this extract from the fah log file

Code: Select all

[22:09:15] Completed 990000 out of 1000000 steps  (99%)
[22:29:24] Writing local files
[22:29:24] Completed 1000000 out of 1000000 steps  (100%)
[22:29:25] Writing final coordinates.
[22:29:25] Past main M.D. loop


--- Opening Log file [June 5 23:42:02] 


# Linux Console Edition #######################################################

(removed a load of useless messages!)

[23:42:08] *------------------------------*
[23:42:08] Folding@home Gromacs Core
[23:42:08] Version 1.64 (April 29, 2004)
[23:42:08] 
[23:42:08] Preparing to commence simulation
[23:42:08] - Ensuring status. Please wait.
[23:42:25] - Assembly optimizations manually forced on.
[23:42:25] - Not checking prior termination.
[23:42:26] - Expanded 459083 -> 2328497 (decompressed 507.2 percent)
[23:42:26] - Checksums don't match (work/wudata_08.arc)
[23:42:26] - Starting from initial work packet
[23:42:26] 
[23:42:26] Project: 737 (Run 38, Clone 10, Gen 2)
[23:42:26] 
[23:42:26] Assembly optimizations on if available.
[23:42:26] Entering M.D.
[23:42:32] Protein: p737_Protein
[23:42:32] 
[23:42:32] Writing local files
[23:42:34] Extra SSE boost OK.
[23:42:34] Writing local files
[23:42:34] Completed 0 out of 1000000 steps  (0%)
So it trashed my wu at the time of completion.
And it was a p737 128 pointer :evil: :x

I deleted the wu but promptly got yet another p737 :roll:
So I have to wait another day to see if it will complete the wu this time or if it's time to do so formatting and reinstalling :twisted:

kai
Posts: 30
Joined: Thu Nov 06, 2003 5:42 pm

Post by kai » Mon Jun 07, 2004 4:41 pm

So I have to wait another day to see if it will complete the wu this time or if it's time to do so formatting and reinstalling
geordie,

you might want to try running cpuburn and memtest before reinstalling. You may have some hardware problems that will surface again after you reinstall.

I notice you're using Gentoo. Have emerges been completing w/o problems? Usually (though not always) long compiles are pretty good at catching hardware problems (especially RAM)

geordie
Friend of SPCR
Posts: 175
Joined: Mon Jun 09, 2003 4:00 am
Location: Reading, UK

Post by geordie » Tue Jun 08, 2004 10:02 am

Well the next couple of wu have completed successfully so things are looking up. :)

I've not had any other signs of instability on this machine, including a marathon 24hr+ compile of xfree, kde & openoffice. :roll:
I ran memtest a few months back when I first setup the machine so I'm pretty sure that's fine. I got impatient after 4 hours of prime95 and just got it folding after that. WinXP was on it for a few weeks before I put Gentoo on and there were no problems then folding 24/7.

Maybe the voltage is right on the limit for absolute stability. It's at 1.525v now. Maybe I'll knock it up to 1.55v.

Of course we would be going through a hot spell at the moment too which doesn't help.

Post Reply