#include "catalog/pg_type_d.h"
Go to the source code of this file.
|
#define | fetchatt(A, T) fetch_att(T, (A)->attbyval, (A)->attlen) |
|
#define | att_align_datum(cur_offset, attalign, attlen, attdatum) |
|
#define | att_datum_alignby(cur_offset, attalignby, attlen, attdatum) |
|
#define | att_align_pointer(cur_offset, attalign, attlen, attptr) |
|
#define | att_pointer_alignby(cur_offset, attalignby, attlen, attptr) |
|
#define | att_align_nominal(cur_offset, attalign) |
|
#define | att_nominal_alignby(cur_offset, attalignby) TYPEALIGN(attalignby, cur_offset) |
|
#define | att_addlength_datum(cur_offset, attlen, attdatum) att_addlength_pointer(cur_offset, attlen, DatumGetPointer(attdatum)) |
|
#define | att_addlength_pointer(cur_offset, attlen, attptr) |
|
◆ att_addlength_datum
◆ att_addlength_pointer
#define att_addlength_pointer |
( |
|
cur_offset, |
|
|
|
attlen, |
|
|
|
attptr |
|
) |
| |
Value:( \
( \
) \
( \
) \
: \
( \
(cur_offset) + (strlen((char *) (attptr)) + 1) \
)) \
)
#define AssertMacro(condition)
Definition at line 185 of file tupmacs.h.
◆ att_align_datum
Value:( \
(uintptr_t) (cur_offset) : \
att_align_nominal(cur_offset,
attalign) \
)
static Pointer DatumGetPointer(Datum X)
#define VARATT_IS_SHORT(PTR)
Definition at line 87 of file tupmacs.h.
◆ att_align_nominal
#define att_align_nominal |
( |
|
cur_offset, |
|
|
|
attalign |
|
) |
| |
Value:( \
(((
attalign) == TYPALIGN_CHAR) ? (uintptr_t) (cur_offset) : \
( \
))) \
)
Definition at line 150 of file tupmacs.h.
◆ att_align_pointer
Value:( \
(uintptr_t) (cur_offset) : \
)
#define att_align_nominal(cur_offset, attalign)
#define VARATT_NOT_PAD_BYTE(PTR)
Definition at line 118 of file tupmacs.h.
◆ att_datum_alignby
#define att_datum_alignby |
( |
|
cur_offset, |
|
|
|
attalignby, |
|
|
|
attlen, |
|
|
|
attdatum |
|
) |
| |
Value: ( \
(uintptr_t) (cur_offset) : \
TYPEALIGN(attalignby, cur_offset))
Definition at line 98 of file tupmacs.h.
◆ att_nominal_alignby
#define att_nominal_alignby |
( |
|
cur_offset, |
|
|
|
attalignby |
|
) |
| TYPEALIGN(attalignby, cur_offset) |
◆ att_pointer_alignby
#define att_pointer_alignby |
( |
|
cur_offset, |
|
|
|
attalignby, |
|
|
|
attlen, |
|
|
|
attptr |
|
) |
| |
Value: ( \
(uintptr_t) (cur_offset) : \
#define TYPEALIGN(ALIGNVAL, LEN)
Definition at line 129 of file tupmacs.h.
◆ fetchatt
◆ att_isnull()
static bool att_isnull |
( |
int |
ATT, |
|
|
const bits8 * |
BITS |
|
) |
| |
|
inlinestatic |
Definition at line 26 of file tupmacs.h.
27{
28 return !(BITS[ATT >> 3] & (1 << (ATT & 0x07)));
29}
Referenced by brin_deconstruct_tuple(), check_tuple_attribute(), fastgetattr(), heap_attisnull(), heap_deform_tuple(), index_deform_tuple_internal(), index_getattr(), nocache_index_getattr(), nocachegetattr(), slot_deform_heap_tuple_internal(), and tuple_data_split_internal().
◆ fetch_att()
static Datum fetch_att |
( |
const void * |
T, |
|
|
bool |
attbyval, |
|
|
int |
attlen |
|
) |
| |
|
inlinestatic |
Definition at line 53 of file tupmacs.h.
54{
56 {
58 {
59 case sizeof(char):
65#if SIZEOF_DATUM == 8
67 return *((
const Datum *)
T);
68#endif
69 default:
71 return 0;
72 }
73 }
74 else
76}
static const uint32 T[65]
static Datum PointerGetDatum(const void *X)
static Datum Int16GetDatum(int16 X)
static Datum Int32GetDatum(int32 X)
static Datum CharGetDatum(char X)
References attbyval, attlen, CharGetDatum(), elog, ERROR, Int16GetDatum(), Int32GetDatum(), PointerGetDatum(), and T.
Referenced by array_iter_next(), array_iterate(), array_replace_internal(), array_to_text_internal(), ArrayCast(), brin_range_deserialize(), deconstruct_array(), ExecEvalHashedScalarArrayOp(), ExecEvalScalarArrayOp(), multirange_get_bounds(), PLyList_FromArray_recurse(), range_deserialize(), statext_mcv_deserialize(), width_bucket_array_fixed(), and width_bucket_array_variable().
◆ store_att_byval()
static void store_att_byval |
( |
void * |
T, |
|
|
Datum |
newdatum, |
|
|
int |
attlen |
|
) |
| |
|
inlinestatic |
Definition at line 211 of file tupmacs.h.
212{
214 {
215 case sizeof(char):
217 break;
220 break;
223 break;
224#if SIZEOF_DATUM == 8
227 break;
228#endif
229 default:
231 }
232}
static char DatumGetChar(Datum X)
static int16 DatumGetInt16(Datum X)
static int32 DatumGetInt32(Datum X)
References attlen, DatumGetChar(), DatumGetInt16(), DatumGetInt32(), elog, ERROR, and T.
Referenced by ArrayCastAndSet(), brin_range_serialize(), datum_write(), fill_val(), and statext_mcv_serialize().