Re: win32 performance - fsync question - Mailing list pgsql-hackers

From Tom Lane
Subject Re: win32 performance - fsync question
Date
Msg-id 10137.1108669196@sss.pgh.pa.us
Whole thread Raw
In response to Re: win32 performance - fsync question  ("Magnus Hagander" <mha@sollentuna.net>)
List pgsql-hackers
"Magnus Hagander" <mha@sollentuna.net> writes:
> 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 I'm reading it right, you are referring to:
   File access must begin at byte offsets within the file that are   integer multiples of the volume's sector size.
File access must be for numbers of bytes that are integer multiples   of the volume's sector size. For example, if the
sectorsize is 512   bytes, an application can request reads and writes of 512, 1024, or   2048 bytes, but not of 335,
981,or 7171 bytes.
 
   Buffer addresses for read and write operations should be sector   aligned (aligned on addresses in memory that are
integermultiples   of the volume's sector size). Depending on the disk, this   requirement may not be enforced.
 

1 and 2 should be no problem since we only read or write integral pages
(8K).  3 is a bit bogus IMHO, or even a lot bogus.  You can set
ALIGNOF_BUFFER in src/include/pg_config_manual.h to whatever you think
the alignment requirement really needs to be (I'd try 512).
        regards, tom lane


pgsql-hackers by date:

Previous
From: "Merlin Moncure"
Date:
Subject: Re: win32 performance - fsync question
Next
From: "Merlin Moncure"
Date:
Subject: Re: win32 performance - fsync question