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

Re: [PATCH v4] Avoid manual shift-and-test logic in AllocSetFreeIndex

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Jeremy Kerr <jk(at)ozlabs(dot)org>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: [PATCH v4] Avoid manual shift-and-test logic in AllocSetFreeIndex
Date: 2009-07-21 19:59:58
Message-ID: 18739.1248206398@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-hackers
Jeremy Kerr <jk(at)ozlabs(dot)org> writes:
> Rather than testing single bits in a loop, change AllocSetFreeIndex to
> use the __builtin_clz() function to calculate the chunk index.

Per subsequent discussion and testing, I've committed a patch that
uses a lookup table instead of depending on __builtin_clz().
http://archives.postgresql.org/message-id/20090721195312.207CA75331E@cvs.postgresql.org

			regards, tom lane

In response to

pgsql-hackers by date

Next:From: Tom LaneDate: 2009-07-21 20:02:42
Subject: Re: psql \du and \dg is the same - pg 8.4
Previous:From: Dickson S. GuedesDate: 2009-07-21 19:55:19
Subject: Re: WIP patch for TODO Item: Add prompt escape to display the client and server versions

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group