Skip to content

Make sure I/O Timings are correctly taken into account #710

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
pgiraud opened this issue Mar 14, 2025 · 0 comments
Open

Make sure I/O Timings are correctly taken into account #710

pgiraud opened this issue Mar 14, 2025 · 0 comments

Comments

@pgiraud
Copy link
Member

pgiraud commented Mar 14, 2025

In PG17, at least, I/O timings may be detailed (info for shared, temp, etc.)

I/O Timings: shared read=60857.349 write=2075.348, temp read=190561.144 write=20711.103

We should make sure this is correctly parsed and managed / shown.

Example plan: https://explain.dalibo.com/plan/40ed3a382gah1b44#plan


                                                                                       QUERY PLAN                                                                                       
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 MixedAggregate  (cost=0.72..61651817.79 rows=533341364 width=165) (actual time=0.040..1787528.803 rows=1600008002 loops=1)
   Output: count(*), avg(aid), avg(bid), aid, bid, filler
   Hash Key: pgbench_accounts.bid
   Hash Key: pgbench_accounts.bid, pgbench_accounts.filler
   Group Key: pgbench_accounts.aid, pgbench_accounts.bid, pgbench_accounts.filler
   Group Key: pgbench_accounts.aid, pgbench_accounts.bid
   Group Key: pgbench_accounts.aid
   Group Key: ()
   Sort Key: pgbench_accounts.filler, pgbench_accounts.aid
     Group Key: pgbench_accounts.filler, pgbench_accounts.aid
     Group Key: pgbench_accounts.filler
   Batches: 1  Memory Usage: 4505kB
   Buffers: shared hit=36161 read=7614118 written=389455, temp read=5039174 written=5039224
   I/O Timings: shared read=60857.349 write=2075.348, temp read=190561.144 write=20711.103
   ->  Incremental Sort  (cost=0.72..24654143.31 rows=133333355 width=93) (actual time=0.029..214525.022 rows=400000000 loops=1)
         Output: aid, bid, filler
         Sort Key: pgbench_accounts.aid, pgbench_accounts.bid, pgbench_accounts.filler
         Presorted Key: pgbench_accounts.aid
         Full-sort Groups: 12500000  Sort Method: quicksort  Average Memory: 28kB  Peak Memory: 28kB
         Buffers: shared hit=36160 read=7614118 written=389455
         I/O Timings: shared read=60857.349 write=2075.348
         ->  Index Scan using pgbench_accounts_pkey on public.pgbench_accounts  (cost=0.57..18654142.33 rows=133333355 width=93) (actual time=0.017..154112.353 rows=400000000 loops=1)
               Output: aid, bid, filler
               Filter: ((((3 * pgbench_accounts.aid) - (17 * pgbench_accounts.bid)) + 33) > 5)
               Buffers: shared hit=36160 read=7614118 written=389455
               I/O Timings: shared read=60857.349 write=2075.348
 Query Identifier: 7834501604919028676
 Planning:
   Memory: used=33kB  allocated=64kB
 Planning Time: 0.076 ms
 Execution Time: 1849934.115 ms

Related to #477 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant