From: | "Ryohei Takahashi (Fujitsu)" <r(dot)takahashi_2(at)fujitsu(dot)com> |
---|---|
To: | "Ryohei Takahashi (Fujitsu)" <r(dot)takahashi_2(at)fujitsu(dot)com>, 'Vladlen Popolitov' <v(dot)popolitov(at)postgrespro(dot)ru> |
Cc: | 'Robert Haas' <robertmhaas(at)gmail(dot)com>, "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | RE: COPY performance on Windows |
Date: | 2025-01-14 06:55:04 |
Message-ID: | TY3PR01MB1189178759FA74DB8E508533B82182@TY3PR01MB11891.jpnprd01.prod.outlook.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
I compared the performance between 94f9c08 (previous commit of 82a4edabd2) and 82a4edabd2 with nclient = 8.
The performance is degraded by 8%.
* 94f9c08 (previous commit of 82a4edabd2)
75sec
* 82a4edabd2
81sec
I looked the pg_stat_io view after COPY completed.
* 94f9c08 (previous commit of 82a4edabd2)
backend_type | object | context | reads | read_time | writes | write_time | writebacks | writeback_time | extends | extend_time | op_bytes | hits | evictions | reuses | fsyncs | fsync_time | stats_reset
client backend | relation | bulkwrite | 0 | 0 | 4408399 | 57207.667 | 0 | 0 | 4424783 | 43897.679000000004 | 8192 | 6559989 | 0 | 4408399 | | | 2025-01-14 13:57:29.162001+09
* 82a4edabd2
backend_type | object | context | reads | read_time | writes | write_time | writebacks | writeback_time | extends | extend_time | op_bytes | hits | evictions | reuses | fsyncs | fsync_time | stats_reset
client backend | relation | bulkwrite | 0 | 0 | 4408514 | 112722.993 | 0 | 0 | 4424898 | 33416.076 | 8192 | 5245654 | 0 | 4408514 | | | 2025-01-14 13:54:40.643054+09
By applying 82a4edabd2, extend_time is reduced from 43897ms to 33416ms.
It seems it is the effect of 82a4edabd2.
On the other hand, write_time is increased from 57207ms to 112722ms.
I think write_time is just the time for pwrite(), so I cannot understand why 82a4edabd2 affects write_time.
How do you think about this?
Regards,
Ryohei Takahashi
From | Date | Subject | |
---|---|---|---|
Next Message | Shubham Khanna | 2025-01-14 07:02:04 | Re: Log a warning in pg_createsubscriber for max_slot_wal_keep_size |
Previous Message | Shubham Khanna | 2025-01-14 06:54:19 | Re: Log a warning in pg_createsubscriber for max_slot_wal_keep_size |