Re: Temp tables and LRU-K caching - Mailing list pgsql-hackers

From Bruce Momjian
Subject Re: Temp tables and LRU-K caching
Date
Msg-id 200209231634.g8NGYXq24378@candle.pha.pa.us
Whole thread Raw
In response to Temp tables and LRU-K caching  (Mike Mascari <mascarm@mascari.com>)
Responses Re: Temp tables and LRU-K caching  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Mike Mascari wrote:
> Hello.
> 
> I'm just curious as to the 7.3 status of a couple of things:
> 
> 1. Back in Feb. I wrote (in regards to Oracle behavior):
> 
> "Unlike normal queries where blocks are added to the MRU end of 
> an LRU list, full table scans add the blocks to the LRU end of 
> the LRU list. I was wondering, in the light of the discussion of 
> using LRU-K, if PostgreSQL does, or if anyone has tried, this 
> technique?"
> 
> Bruce wrote:
> 
> "Yes, someone from India has a project to test LRU-K and MRU for 
> large table scans and report back the results.  He will 
> implement whichever is best."
> 
> Did this make it into 7.3?

That person stopped working on it.  It is still on the TODO list.

> 2. Gavin Sherry had worked up a patch so that temporary 
> relations could be dropped automatically upon transaction 
> commit. Did any of those patches it make it? I notice that 
> whenever I create a temporary table in a transaction, my HD 
> light blinks. Is this a forced fsync() causes by the fact that 
> the SQL standard defines temporary relations as surviving across 
> transactions? If so, I'd bet those of us who use 
> transaction-local temporary tables could get few drops more of 
> performance from an ON COMMIT drop patch w/o fsync.

This has me confused.  There was an exchange with Gavin Auguest 27/28
which resulted in a patch:
http://archives.postgresql.org/pgsql-patches/2002-08/msg00475.php

and my adding it to the patches list:
http://archives.postgresql.org/pgsql-patches/2002-08/msg00502.php

However, it was never applied.  I don't see any discussion refuting the
patch or any email removing it from the queue.  The only thing I can
think of is that somehow I didn't apply it.  

My only guess is that I said I was putting in the queue, but didn't. I
am concerned if there are any other patches I missed.  I see the cube
patch being added to the queue 40 seconds later, and I know that was in
there because I see the message removing it from the queue.  I must have
made a mistake on that one.

What do we do now?  The author clearly got it in before beta, but we are
in beta now.   I think we should apply it.

--  Bruce Momjian                        |  http://candle.pha.pa.us pgman@candle.pha.pa.us               |  (610)
359-1001+  If your life is a hard drive,     |  13 Roberts Road +  Christ can be your backup.        |  Newtown Square,
Pennsylvania19073
 


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Temp tables and LRU-K caching
Next
From: Bruce Momjian
Date:
Subject: Re: Temp tables and LRU-K caching