test_fsync on MinGW(win32)

Started by Hiroshi Saitoalmost 20 years ago2 messagespatches
Jump to latest
#1Hiroshi Saito
z-saito@guitar.ocn.ne.jp

Hi.

I wanted to see this difference. It is somewhat ad hoc.
However, It is more effective than it doesn't show it at all.

-- MinGW(win32) --
$ test_fsync
Simple write timing:
write 3.644000

Compare fsync times on write() and non-write() descriptor:
(If the times are similar, fsync() can sync data written
on a different descriptor.)
write, fsync, close 40.543000
write, close, fsync 47.033000

Compare one o_sync write to two:
(o_sync unavailable)
open o_dsync, write 0.094000

(fdatasync unavailable)
write, fsync, 26.700000

Compare file sync methods with 2 8k writes:
open o_dsync, write 0.203000
(fdatasync unavailable)
write, fsync, 27.920000

Regards,
Hiroshi Saito

Attachments:

test_fsync_patchapplication/octet-stream; name=test_fsync_patchDownload+41-23
#2Bruce Momjian
bruce@momjian.us
In reply to: Hiroshi Saito (#1)
Re: test_fsync on MinGW(win32)

Patch applied. Thanks.

---------------------------------------------------------------------------

Hiroshi Saito wrote:

Hi.

I wanted to see this difference. It is somewhat ad hoc.
However, It is more effective than it doesn't show it at all.

-- MinGW(win32) --
$ test_fsync
Simple write timing:
write 3.644000

Compare fsync times on write() and non-write() descriptor:
(If the times are similar, fsync() can sync data written
on a different descriptor.)
write, fsync, close 40.543000
write, close, fsync 47.033000

Compare one o_sync write to two:
(o_sync unavailable)
open o_dsync, write 0.094000

(fdatasync unavailable)
write, fsync, 26.700000

Compare file sync methods with 2 8k writes:
open o_dsync, write 0.203000
(fdatasync unavailable)
write, fsync, 27.920000

Regards,
Hiroshi Saito

[ Attachment, skipping... ]

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

http://archives.postgresql.org

--
Bruce Momjian bruce@momjian.us
EnterpriseDB http://www.enterprisedb.com

+ If your life is a hard drive, Christ can be your backup. +