21 #include "utils/fmgrprotos.h"
23 #define GETENTRY(vec,pos) DatumGetTSQuerySign((vec)->vector[pos].key)
72 retval = (
key & sq) == sq;
74 retval = (
key & sq) != 0;
78 retval = (
key & sq) ==
key;
80 retval = (
key & sq) != 0;
98 for (
i = 0;
i < entryvec->
n;
i++)
164 #define WISH_F(a,b,c) (double)( -(double)(((a)-(b))*((a)-(b))*((a)-(b)))*(c) )
197 if (size_waste > waste)
206 if (seed_1 == 0 || seed_2 == 0)
212 datum_l =
GETENTRY(entryvec, seed_1);
213 datum_r =
GETENTRY(entryvec, seed_2);
219 costvector[
j - 1].
pos =
j;
222 costvector[
j - 1].
cost = abs(size_alpha - size_beta);
226 for (k = 0; k < maxoff; k++)
228 j = costvector[k].
pos;
235 else if (
j == seed_2)
static void PGresult * res
#define PG_GETARG_POINTER(n)
#define PG_GETARG_UINT16(n)
#define PG_RETURN_POINTER(x)
#define PG_RETURN_BOOL(x)
#define gistentryinit(e, k, r, pg, o, l)
static int pg_cmp_s32(int32 a, int32 b)
#define OffsetNumberNext(offsetNumber)
#define FirstOffsetNumber
#define qsort(a, b, c, d)
static pg_noinline void Size size
#define RTContainsStrategyNumber
#define RTContainedByStrategyNumber
static TSQuery DatumGetTSQuery(Datum X)
#define PG_GETARG_TSQUERY(n)
static Datum TSQuerySignGetDatum(TSQuerySign X)
static TSQuerySign DatumGetTSQuerySign(Datum X)
#define PG_GETARG_TSQUERYSIGN(n)
#define PG_RETURN_TSQUERYSIGN(X)
#define GETENTRY(vec, pos)
Datum gtsquery_consistent(PG_FUNCTION_ARGS)
Datum gtsquery_consistent_oldsig(PG_FUNCTION_ARGS)
Datum gtsquery_union(PG_FUNCTION_ARGS)
Datum gtsquery_compress(PG_FUNCTION_ARGS)
static int sizebitvec(TSQuerySign sign)
Datum gtsquery_penalty(PG_FUNCTION_ARGS)
Datum gtsquery_same(PG_FUNCTION_ARGS)
static int hemdist(TSQuerySign a, TSQuerySign b)
Datum gtsquery_picksplit(PG_FUNCTION_ARGS)
static int comparecost(const void *a, const void *b)
TSQuerySign makeTSQuerySign(TSQuery a)