From: Andres Freund <andres@anarazel.de>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Add FIELDNO_* macro designating offset into structs required for
Date: Thu, 22 Mar 2018 21:50:32 +0000
Message-ID: <E1ez86S-00036E-Ex@gemulon.postgresql.org> (raw)
Add FIELDNO_* macro designating offset into structs required for JIT.
For any interesting JIT target, fields inside structs need to be
accessed. b96d550e contains infrastructure for syncing the definition
of types between postgres C code and runtime code generation with
LLVM. But that doesn't sync the number or names of fields inside
structs, just the types (including padding etc).
One option would be to hardcode the offset numbers in the JIT code,
but that'd be hard to keep in sync. Instead add macros indicating the
field offset to the fields that need to be accessed. Not pretty, but
manageable.
Author: Andres Freund
Discussion: https://postgr.es/m/20170901064131.tazjxwus3k2w3ybh@alap3.anarazel.de
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/7ced1d1247286399df53823eb76cacaf6d7fdb22
Modified Files
--------------
src/include/access/htup.h | 1 +
src/include/access/htup_details.h | 4 ++++
src/include/executor/nodeAgg.h | 3 +++
src/include/executor/tuptable.h | 7 +++++++
src/include/fmgr.h | 3 +++
src/include/nodes/execnodes.h | 16 ++++++++++++++++
6 files changed, 34 insertions(+)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: andres@anarazel.de
Subject: Re: pgsql: Add FIELDNO_* macro designating offset into structs required for
In-Reply-To: <E1ez86S-00036E-Ex@gemulon.postgresql.org>
References: <E1ez86S-00036E-Ex@gemulon.postgresql.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox