Re: Raising our compiler requirements for 9.6

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Heikki Linnakangas <hlinnaka(at)iki(dot)fi>, Andres Freund <andres(at)anarazel(dot)de>, Noah Misch <noah(at)leadboat(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Raising our compiler requirements for 9.6
Date: 2015-08-28 22:23:06
Message-ID: 20150828222306.GD18678@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Aug 12, 2015 at 04:47:55PM -0400, Robert Haas wrote:
> On Wed, Aug 12, 2015 at 4:34 PM, Heikki Linnakangas <hlinnaka(at)iki(dot)fi> wrote:
> > Andres didn't mention how big the performance benefit he saw with pgbench
> > was, but I bet it was barely distinguishible from noise. But that's OK. In
> > fact, there's no reason to believe this would make any difference to
> > performance. The point is to make the code more readable, and it certainly
> > achieves that.
>
> I think that when Bruce macro-ized this ten years ago or whenever it
> was, he got a significant performance benefit from it; otherwise I
> don't think he would have done it.

(You over-estimate me. ;-) )

What happened is that I was looking at call graph counts and
fastgetattr() was called a bazillion times, so I inlined it, and saw a
noticeably performance improvement, maybe 2% on an in-memory
SELECT-only workload. Same with a few other macros I created in those
early years.

Frankly, my hacks last a lot longer than I expected. (Did someone say
pg_upgrade. :-) )

--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ Everyone has their own god. +

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2015-08-28 22:23:30 Re: Adding commit details to SGML release notes
Previous Message Bruce Momjian 2015-08-28 22:15:13 Re: Raising our compiler requirements for 9.6