Re: Performance optimization of btree binary search

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andres Freund <andres(at)2ndquadrant(dot)com>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Peter Geoghegan <pg(at)heroku(dot)com>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org>, Stephen Frost <sfrost(at)snowman(dot)net>
Subject: Re: Performance optimization of btree binary search
Date: 2013-12-05 16:11:18
Message-ID: 16787.1386259878@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Andres Freund <andres(at)2ndquadrant(dot)com> writes:
> On 2013-12-05 10:34:16 -0500, Tom Lane wrote:
>> In any case, the number of bugs I can remember that such a thing
>> would've prevented is negligible.

> Cases talked about upthread, where a plain datatype is returned as a
> Datum instead of using FooGetDatum() and the reverse, would be
> impossible. I don't think those are that infrequent?

[ shrug... ] The performance changes we're talking about here would have
the effect of making the compiler's implicit casts be the right thing
anyway. In any case, I don't think you'd have accomplished much by
forcing people to use FooGetDatum, unless you can force them to use the
*right* FooGetDatum. The errors I can remember seeing in this area were
more in the line of choosing the wrong macro.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2013-12-05 16:12:48 Re: Dynamic Shared Memory stuff
Previous Message Andres Freund 2013-12-05 16:05:17 Re: Performance optimization of btree binary search