| From: | Andres Freund <andres(at)anarazel(dot)de> | 
|---|---|
| To: | Michael Paquier <michael(at)paquier(dot)xyz> | 
| Cc: | Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> | 
| Subject: | Re: removing unnecessary get_att*() lsyscache functions | 
| Date: | 2018-10-23 00:19:44 | 
| Message-ID: | 20181023001944.g6jpgnitb7yemmiv@alap3.anarazel.de | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-hackers | 
Hi,
On 2018-10-23 09:11:17 +0900, Michael Paquier wrote:
> On Mon, Oct 22, 2018 at 07:12:28PM +0200, Peter Eisentraut wrote:
> > OK, slightly reworked version attached.
> 
> +   attTup = (Form_pg_attribute) GETSTRUCT(tuple);
>     attnum = ((Form_pg_attribute) GETSTRUCT(tuple))->attnum;
> 
> No need to call twice GETSTRUCT here..  The rest looks fine.
Just about every optimize compiler can optimize that away, it's just a
bit of pointer magic.  Obviously we don't want to repeat longer lines
superfluously, but twice isn't that bad...
Greetings,
Andres Freund
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Amit Langote | 2018-10-23 00:28:53 | Re: relhassubclass and partitioned indexes | 
| Previous Message | Michael Paquier | 2018-10-23 00:11:17 | Re: removing unnecessary get_att*() lsyscache functions |