From: | Michael Paquier <michael(at)paquier(dot)xyz> |
---|---|
To: | Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com> |
Cc: | Postgres hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, "Drouvot, Bertrand" <bdrouvot(at)amazon(dot)com> |
Subject: | Re: Generating code for query jumbling through gen_node_support.pl |
Date: | 2023-01-30 10:39:30 |
Message-ID: | Y9eeYinDb1AcpWrG@paquier.xyz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Fri, Jan 27, 2023 at 11:59:47AM +0900, Michael Paquier wrote:
> Using that, I can compile the following results for various cases (-O2
> and compute_query_id=on):
> query | mode | iterations | avg_runtime_ns | avg_jumble_ns
> -------------------------+--------+------------+----------------+---------------
> begin | string | 50000000 | 4.53116 | 4.54
> begin | jumble | 50000000 | 30.94578 | 30.94
> commit | string | 50000000 | 4.76004 | 4.74
> commit | jumble | 50000000 | 31.4791 | 31.48
> create table 1 column | string | 50000000 | 7.22836 | 7.08
> create table 1 column | jumble | 50000000 | 152.10852 | 151.96
> create table 5 columns | string | 50000000 | 12.43412 | 12.28
> create table 5 columns | jumble | 50000000 | 352.88976 | 349.1
> create table 20 columns | string | 5000000 | 49.591 | 48.2
> create table 20 columns | jumble | 5000000 | 2272.4066 | 2271
> drop table 1 column | string | 50000000 | 6.70538 | 6.56
> drop table 1 column | jumble | 50000000 | 50.38 | 50.24
> drop table 5 columns | string | 50000000 | 6.88256 | 6.74
> drop table 5 columns | jumble | 50000000 | 50.02898 | 49.9
> SET work_mem | string | 50000000 | 7.28752 | 7.28
> SET work_mem | jumble | 50000000 | 91.66588 | 91.64
> (16 rows)
Just to close the loop here, I have done more measurements to compare
the jumble done for some DMLs and some SELECTs between HEAD and the
patch (forgot to post some last Friday). Both methods show comparable
results:
query | mode | iterations | avg_runtime_ns | avg_jumble_ns
----------------------+--------+------------+----------------+---------------
insert table 10 cols | master | 50000000 | 377.17878 | 377.04
insert table 10 cols | jumble | 50000000 | 409.47924 | 409.34
insert table 20 cols | master | 50000000 | 692.94924 | 692.8
insert table 20 cols | jumble | 50000000 | 710.0901 | 709.96
insert table 5 cols | master | 50000000 | 232.44308 | 232.3
insert table 5 cols | jumble | 50000000 | 253.49854 | 253.36
select 10 cols | master | 50000000 | 449.13608 | 383.36
select 10 cols | jumble | 50000000 | 491.61912 | 323.86
select 5 cols | master | 50000000 | 277.477 | 277.46
select 5 cols | jumble | 50000000 | 323.88152 | 323.86
(10 rows)
The averages are in ns, so the difference does not bother me much.
There may be some noise mixed in that ;)
(Attached is the tweak I have applied on HEAD to get some numbers.)
--
Michael
Attachment | Content-Type | Size |
---|---|---|
jumble-benchmark.txt | text/plain | 1.9 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2023-01-30 10:42:12 | Re: [DOCS] Stats views and functions not in order? |
Previous Message | Takamichi Osumi (Fujitsu) | 2023-01-30 10:33:43 | RE: Time delayed LR (WAS Re: logical replication restrictions) |