31 #include "utils/fmgrprotos.h"
97 lohalf ^= (
val >= 0) ? hihalf : ~hihalf;
110 lohalf ^= (
val >= 0) ? hihalf : ~hihalf;
172 return hash_any((
unsigned char *) &key8,
sizeof(key8));
276 (
errcode(ERRCODE_INDETERMINATE_COLLATION),
277 errmsg(
"could not determine which collation to use for string hashing"),
278 errhint(
"Use the COLLATE clause to set the collation explicitly.")));
296 bsize =
pg_strnxfrm(NULL, 0, keydata, keylen, mylocale);
303 elog(
ERROR,
"pg_strnxfrm() returned unexpected result");
331 (
errcode(ERRCODE_INDETERMINATE_COLLATION),
332 errmsg(
"could not determine which collation to use for string hashing"),
333 errhint(
"Use the COLLATE clause to set the collation explicitly.")));
351 bsize =
pg_strnxfrm(NULL, 0, keydata, keylen, mylocale);
358 elog(
ERROR,
"pg_strnxfrm() returned unexpected result");
int errhint(const char *fmt,...)
int errcode(int sqlerrcode)
int errmsg(const char *fmt,...)
#define ereport(elevel,...)
static float8 get_float8_nan(void)
#define PG_FREE_IF_COPY(ptr, n)
#define PG_RETURN_UINT32(x)
#define PG_GETARG_TEXT_PP(n)
#define PG_GETARG_FLOAT8(n)
#define PG_GETARG_CHAR(n)
#define PG_GETARG_POINTER(n)
#define PG_GETARG_INT64(n)
#define PG_GETARG_NAME(n)
#define PG_RETURN_UINT64(x)
#define PG_GETARG_VARLENA_PP(n)
#define PG_GETARG_INT32(n)
#define PG_GETARG_FLOAT4(n)
#define PG_GET_COLLATION()
#define PG_GETARG_INT16(n)
static Datum hash_uint32(uint32 k)
static Datum hash_any_extended(const unsigned char *k, int keylen, uint64 seed)
static Datum hash_any(const unsigned char *k, int keylen)
static Datum hash_uint32_extended(uint32 k, uint64 seed)
Datum hashenum(PG_FUNCTION_ARGS)
Datum hashvarlenaextended(PG_FUNCTION_ARGS)
Datum hashfloat8extended(PG_FUNCTION_ARGS)
Datum hashenumextended(PG_FUNCTION_ARGS)
Datum hashtextextended(PG_FUNCTION_ARGS)
Datum hashoidvector(PG_FUNCTION_ARGS)
Datum hashint8extended(PG_FUNCTION_ARGS)
Datum hashint2(PG_FUNCTION_ARGS)
Datum hashint2extended(PG_FUNCTION_ARGS)
Datum hashfloat4(PG_FUNCTION_ARGS)
Datum hashfloat8(PG_FUNCTION_ARGS)
Datum hashoidextended(PG_FUNCTION_ARGS)
Datum hashnameextended(PG_FUNCTION_ARGS)
Datum hashbytea(PG_FUNCTION_ARGS)
Datum hashint8(PG_FUNCTION_ARGS)
Datum hashname(PG_FUNCTION_ARGS)
Datum hashint4extended(PG_FUNCTION_ARGS)
Datum hashtext(PG_FUNCTION_ARGS)
Datum hashchar(PG_FUNCTION_ARGS)
Datum hashbyteaextended(PG_FUNCTION_ARGS)
Datum hashoid(PG_FUNCTION_ARGS)
Datum hashcharextended(PG_FUNCTION_ARGS)
Datum hashfloat4extended(PG_FUNCTION_ARGS)
Datum hashvarlena(PG_FUNCTION_ARGS)
Datum hashint4(PG_FUNCTION_ARGS)
Datum hashoidvectorextended(PG_FUNCTION_ARGS)
void pfree(void *pointer)
size_t pg_strnxfrm(char *dest, size_t destsize, const char *src, ssize_t srclen, pg_locale_t locale)
pg_locale_t pg_newlocale_from_collation(Oid collid)
#define VARSIZE_ANY_EXHDR(PTR)