>> > WinXP  fsync = true     20-28 tps
>> > WinXP  fsync = false      600 tps
>> > Linux  fsync = true       800 tps
>> > Linux  fsync = false      980 tps
>> 
>> Wow, that's terrible on Windows.  If there's a solution, it'd be nice
>to
>> backport it...
>> 
>
>there is.  I just rigged up a test benchmark comparing sync methods.  I
>ran on 2 boxes, my xp workstation on 10k raptor and a win2k server on
>3ware raid 5 (also on 10k raptors).
>
>Workstation:
>did 1000 FILE_FLAG_WRITE_THROUGH | FILE_FLAG_NO_BUFFERING writes in
>5.729633 seconds
>did 1000 FILE_FLAG_WRITE_THROUGH writes in 0.593322 seconds
>did 1000 flushfilebuffers writes in 15.898989 seconds
>
>server:
>did 1000 FILE_FLAG_WRITE_THROUGH | FILE_FLAG_NO_BUFFERING writes in
>16.501076 seconds
>did 1000 FILE_FLAG_WRITE_THROUGH writes in 16.104133 seconds
>did 1000 flushfilebuffers writes in 18.962439 seconds
>
>server after running super altra secret dskcache '+p' mode:
>did 1000 FILE_FLAG_WRITE_THROUGH | FILE_FLAG_NO_BUFFERING writes in
>0.256574 seconds
>did 1000 FILE_FLAG_WRITE_THROUGH writes in 2.627602 seconds
>did 1000 flushfilebuffers writes in 15.290967 seconds
>
>dskcache.exe is required to enable power protect mode (unbypassing raid
>conttoller write cache settings) on win2k.

I draw the following conclusions:
1) Using just FILE_FLAG_WRITE_THROUGH is not enough. It sends it out of
the cache, but it returns to the application before the data has hit
disk. AFAIK, that's not good enough for us.

2) Using both, we can get a *significant* speed boost.

Tom, if you look at all the requirements of FILE_FLAG_NO_BUFFERING on
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/fileio/
base/createfile.asp, can you say offhand if the WAL code fulfills them?
If it does, we can probably just hack it in win32_open (at least for
testing and a possible backpatch). Ifn ot, then we'll need to stuff code
in xlog.c.
(Specifically, I'm most worried about the memory alignment requirement)

//Magnus

---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

Reply via email to