Tomas Vondra <to...@vondra.me> writes: > On 2/11/25 21:18, Tom Lane wrote: >> I think what we actually would like to know is how often we have to >> close an open FD in order to make room to open a different file. >> Maybe that's the same thing you mean by "cache miss", but it doesn't >> seem like quite the right terminology. Anyway, +1 for adding some way >> to discover how often that's happening.
> We can count the evictions (i.e. closing a file so that we can open a > new one) too, but AFAICS that's about the same as counting "misses" > (opening a file after not finding it in the cache). After the cache > warms up, those counts should be about the same, I think. Umm ... only if the set of files you want access to is quite static, which doesn't seem like a great bet in the presence of temporary tables and such. I think if we don't explicitly count evictions then we'll be presenting misleading results. regards, tom lane