Skip site navigation (1) Skip section navigation (2)

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search for
  Advanced Search

Re: Index vacuum improvements


  • From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
  • To: Heikki Linnakangas <hlinnaka(at)iki(dot)fi>
  • Cc: pgsql-hackers(at)postgresql(dot)org
  • Subject: Re: Index vacuum improvements
  • Date: Fri, 31 Mar 2006 11:50:17 -0500
  • Message-id: <9780(dot)1143823817(at)sss(dot)pgh(dot)pa(dot)us>

Heikki Linnakangas <hlinnaka(at)iki(dot)fi> writes:
> On Wed, 29 Mar 2006, Tom Lane wrote:
>> That loses the ability to reflect tuple deadness back into LP_DELETE
>> flags, no?

> At first glance, it doesn't look so hard. index_getmulti could mark 
> those tids that are dead, and btgetmulti would rescan the index page and 
> set LP_DELETE on all tuples that are still there.

> We don't have to care about splits; if the index tuple is no longer where 
> it used to be, just ignore it. Right, no?

True --- as long as there's even a reasonable probability of the tuple
getting marked, we'll get the performance benefit.  I don't see a way to
make it work for bitmap indexscans though --- by the time we visit the
heap, the index has long since forgotten where those index entries were.

I think this may be worth doing even disregarding any possible vacuum
speedup, simply because it'll reduce the number of index page lock/unlock
cycles needed during a regular indexscan.

			regards, tom lane



Home | Main Index | Thread Index

Privacy Policy | PostgreSQL Archives hosted by Command Prompt, Inc. | Designed by tinysofa
Copyright © 1996 – 2008 PostgreSQL Global Development Group