Re: automatic analyze: readahead - add "IO read time" log message

From: Stephen Frost <sfrost(at)snowman(dot)net>
To: Justin Pryzby <pryzby(at)telsasoft(dot)com>
Cc: Tomas Vondra <tomas(dot)vondra(at)enterprisedb(dot)com>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi>, Tomas Vondra <tomas(dot)vondra(at)2ndquadrant(dot)com>, Jakub Wartak <Jakub(dot)Wartak(at)tomtom(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: automatic analyze: readahead - add "IO read time" log message
Date: 2021-05-26 00:57:31
Message-ID: 20210526005731.GX20766@tamriel.snowman.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Greetings,

* Justin Pryzby (pryzby(at)telsasoft(dot)com) wrote:
> This patch adds hits/misses/dirtied, but explain says hit/read/dirtied/written.
>
> Should it say "read" instead of "misses" ?
>
> src/backend/access/heap/vacuumlazy.c: _("buffer usage: %lld hits, %lld misses, %lld dirtied\n"),

Errr, the analyze readahead patch set didn't add the above use of
'misses', that's been around for an age or more. For giggles, I hunted
it back to be this 2011 commit: 9d3b50244357ef4c4e3b6e01f91de599077179c8

As for the "misses" usage which was actually added by the patch here:

src/backend/commands/analyze.c: appendStringInfo(&buf, _("buffer usage: %lld hits, %lld misses, %lld dirtied\n"),

That was specifically done to match the 'vacuumlazy.c' usage of 'misses'
above.

As for which to use, I don't have any particular dog in that fight, but
I do think we should be consistent between how VACUUM reports this
information and how ANALYZE does.

Thanks!

Stephen

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message houzj.fnst@fujitsu.com 2021-05-26 01:05:05 RE: Skip partition tuple routing with constant partition key
Previous Message Justin Pryzby 2021-05-26 00:49:35 Re: automatic analyze: readahead - add "IO read time" log message