Re: 2nd Level Buffer Cache - Mailing list pgsql-hackers

From Greg Stark
Subject Re: 2nd Level Buffer Cache
Date
Msg-id AANLkTimL0se6Ddjoyxp2_66-ZQhHXLpAmvWGwfvRvDQL@mail.gmail.com
Whole thread Raw
In response to Re: 2nd Level Buffer Cache  (Jeff Janes <jeff.janes@gmail.com>)
Responses Re: 2nd Level Buffer Cache
List pgsql-hackers
On Thu, Mar 24, 2011 at 11:33 PM, Jeff Janes <jeff.janes@gmail.com> wrote:
> I tried under the circumstances I thought were mostly likely to show a
> time difference, and I was unable to detect a reliable difference in
> timing between free list and clock sweep.

It strikes me that it shouldn't be terribly hard to add a profiling
option to Postgres to dump out a list of precisely which blocks of
data were accessed in which order. Then it's fairly straightforward to
process that list using different algorithms to measure which
generates the fewest cache misses.

This is usually how the topic is handled in academic discussions. The
optimal cache policy is the one which flushes the cache entry which
will be used next the furthest into the future. Given a precalculated
file you can calculate the results from that optimal strategy and then
compare each strategy against that one.


-- 
greg


pgsql-hackers by date:

Previous
From: Daniel Farina
Date:
Subject: Avoiding timeline generation
Next
From: Piyush Newe
Date:
Subject: Re: Rectifying wrong Date outputs