Convert all remaining float4 and float8 functions to new fmgr style.

At this point I think it'd be possible to make float4 be pass-by-value
without too much work --- and float8 too on machines where Datum is
8 bytes.  Something to try when the mood strikes, anyway.
This commit is contained in:
Tom Lane 2000-08-01 18:29:35 +00:00
parent 92bd532c1e
commit 463f1f5cda
10 changed files with 910 additions and 1163 deletions

View File

@ -9,7 +9,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/commands/variable.c,v 1.39 2000/07/14 15:35:44 thomas Exp $
* $Header: /cvsroot/pgsql/src/backend/commands/variable.c,v 1.40 2000/08/01 18:29:29 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@ -566,7 +566,7 @@ parse_random_seed(char *value)
else
{
sscanf(value, "%lf", &seed);
setseed(&seed);
DirectFunctionCall1(setseed, Float8GetDatum(seed));
}
return (TRUE);
}
@ -583,7 +583,7 @@ reset_random_seed(void)
{
double seed = 0.5;
setseed(&seed);
DirectFunctionCall1(setseed, Float8GetDatum(seed));
return (TRUE);
}

View File

@ -9,7 +9,7 @@
* workings can be found in the book "Software Solutions in C" by
* Dale Schumacher, Academic Press, ISBN: 0-12-632360-7.
*
* $Header: /cvsroot/pgsql/src/backend/utils/adt/cash.c,v 1.43 2000/07/07 18:49:52 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/utils/adt/cash.c,v 1.44 2000/08/01 18:29:35 tgl Exp $
*/
#include <limits.h>
@ -425,31 +425,31 @@ cash_mi(Cash *c1, Cash *c2)
/* cash_mul_flt8()
* Multiply cash by float8.
*/
Cash *
cash_mul_flt8(Cash *c, float8 *f)
Datum
cash_mul_flt8(PG_FUNCTION_ARGS)
{
Cash *result;
Cash c = PG_GETARG_CASH(0);
float8 f = PG_GETARG_FLOAT8(1);
Cash result;
if (!PointerIsValid(f) || !PointerIsValid(c))
return NULL;
if (!PointerIsValid(result = palloc(sizeof(Cash))))
elog(ERROR, "Memory allocation failed, can't multiply cash");
*result = ((*f) * (*c));
return result;
} /* cash_mul_flt8() */
result = c * f;
PG_RETURN_CASH(result);
}
/* flt8_mul_cash()
* Multiply float8 by cash.
*/
Cash *
flt8_mul_cash(float8 *f, Cash *c)
Datum
flt8_mul_cash(PG_FUNCTION_ARGS)
{
return cash_mul_flt8(c, f);
} /* flt8_mul_cash() */
float8 f = PG_GETARG_FLOAT8(0);
Cash c = PG_GETARG_CASH(1);
Cash result;
result = f * c;
PG_RETURN_CASH(result);
}
/* cash_div_flt8()
@ -458,53 +458,48 @@ flt8_mul_cash(float8 *f, Cash *c)
* XXX Don't know if rounding or truncating is correct behavior.
* Round for now. - tgl 97/04/15
*/
Cash *
cash_div_flt8(Cash *c, float8 *f)
Datum
cash_div_flt8(PG_FUNCTION_ARGS)
{
Cash *result;
Cash c = PG_GETARG_CASH(0);
float8 f = PG_GETARG_FLOAT8(1);
Cash result;
if (!PointerIsValid(f) || !PointerIsValid(c))
return NULL;
if (!PointerIsValid(result = palloc(sizeof(Cash))))
elog(ERROR, "Memory allocation failed, can't divide cash");
if (*f == 0.0)
if (f == 0.0)
elog(ERROR, "cash_div: divide by 0.0 error");
*result = rint(*c / *f);
return result;
} /* cash_div_flt8() */
result = rint(c / f);
PG_RETURN_CASH(result);
}
/* cash_mul_flt4()
* Multiply cash by float4.
*/
Cash *
cash_mul_flt4(Cash *c, float4 *f)
Datum
cash_mul_flt4(PG_FUNCTION_ARGS)
{
Cash *result;
Cash c = PG_GETARG_CASH(0);
float4 f = PG_GETARG_FLOAT4(1);
Cash result;
if (!PointerIsValid(f) || !PointerIsValid(c))
return NULL;
if (!PointerIsValid(result = palloc(sizeof(Cash))))
elog(ERROR, "Memory allocation failed, can't multiply cash");
*result = ((*f) * (*c));
return result;
} /* cash_mul_flt4() */
result = c * f;
PG_RETURN_CASH(result);
}
/* flt4_mul_cash()
* Multiply float4 by float4.
* Multiply float4 by cash.
*/
Cash *
flt4_mul_cash(float4 *f, Cash *c)
Datum
flt4_mul_cash(PG_FUNCTION_ARGS)
{
return cash_mul_flt4(c, f);
} /* flt4_mul_cash() */
float4 f = PG_GETARG_FLOAT4(0);
Cash c = PG_GETARG_CASH(1);
Cash result;
result = f * c;
PG_RETURN_CASH(result);
}
/* cash_div_flt4()
@ -513,24 +508,19 @@ flt4_mul_cash(float4 *f, Cash *c)
* XXX Don't know if rounding or truncating is correct behavior.
* Round for now. - tgl 97/04/15
*/
Cash *
cash_div_flt4(Cash *c, float4 *f)
Datum
cash_div_flt4(PG_FUNCTION_ARGS)
{
Cash *result;
Cash c = PG_GETARG_CASH(0);
float4 f = PG_GETARG_FLOAT4(1);
Cash result;
if (!PointerIsValid(f) || !PointerIsValid(c))
return NULL;
if (!PointerIsValid(result = palloc(sizeof(Cash))))
elog(ERROR, "Memory allocation failed, can't divide cash");
if (*f == 0.0)
if (f == 0.0)
elog(ERROR, "cash_div: divide by 0.0 error");
*result = rint(*c / *f);
return result;
} /* cash_div_flt4() */
result = rint(c / f);
PG_RETURN_CASH(result);
}
/* cash_mul_int4()

File diff suppressed because it is too large Load Diff

View File

@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/int.c,v 1.41 2000/07/17 03:05:17 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/utils/adt/int.c,v 1.42 2000/08/01 18:29:35 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@ -65,7 +65,7 @@ int2out(PG_FUNCTION_ARGS)
int16 arg1 = PG_GETARG_INT16(0);
char *result = (char *) palloc(7); /* sign, 5 digits, '\0' */
itoa((int) arg1, result);
pg_itoa(arg1, result);
PG_RETURN_CSTRING(result);
}
@ -123,7 +123,7 @@ int2vectorout(PG_FUNCTION_ARGS)
{
if (num != 0)
*rp++ = ' ';
ltoa(int2Array[num], rp);
pg_itoa(int2Array[num], rp);
while (*++rp != '\0')
;
}
@ -187,7 +187,7 @@ int44out(PG_FUNCTION_ARGS)
walk = result;
for (i = 0; i < 4; i++)
{
itoa(an_array[i], walk);
pg_ltoa(an_array[i], walk);
while (*++walk != '\0')
;
*walk++ = ' ';
@ -221,7 +221,7 @@ int4out(PG_FUNCTION_ARGS)
int32 arg1 = PG_GETARG_INT32(0);
char *result = (char *) palloc(12); /* sign, 10 digits, '\0' */
ltoa(arg1, result);
pg_ltoa(arg1, result);
PG_RETURN_CSTRING(result);
}
@ -259,7 +259,7 @@ int2_text(PG_FUNCTION_ARGS)
int16 arg1 = PG_GETARG_INT16(0);
text *result = (text *) palloc(7+VARHDRSZ); /* sign,5 digits, '\0' */
itoa((int) arg1, VARDATA(result));
pg_itoa(arg1, VARDATA(result));
VARATT_SIZEP(result) = strlen(VARDATA(result)) + VARHDRSZ;
PG_RETURN_TEXT_P(result);
}
@ -290,7 +290,7 @@ int4_text(PG_FUNCTION_ARGS)
int32 arg1 = PG_GETARG_INT32(0);
text *result = (text *) palloc(12+VARHDRSZ); /* sign,10 digits,'\0' */
ltoa(arg1, VARDATA(result));
pg_ltoa(arg1, VARDATA(result));
VARATT_SIZEP(result) = strlen(VARDATA(result)) + VARHDRSZ;
PG_RETURN_TEXT_P(result);
}

View File

@ -5,7 +5,7 @@
*
* 1998 Jan Wieck
*
* $Header: /cvsroot/pgsql/src/backend/utils/adt/numeric.c,v 1.33 2000/07/29 03:26:41 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/utils/adt/numeric.c,v 1.34 2000/08/01 18:29:35 tgl Exp $
*
* ----------
*/
@ -1766,17 +1766,19 @@ numeric_float8(PG_FUNCTION_ARGS)
{
Numeric num = PG_GETARG_NUMERIC(0);
char *tmp;
float64 result;
Datum result;
if (NUMERIC_IS_NAN(num))
PG_RETURN_FLOAT8(NAN);
tmp = DatumGetCString(DirectFunctionCall1(numeric_out,
NumericGetDatum(num)));
result = float8in(tmp);
result = DirectFunctionCall1(float8in, CStringGetDatum(tmp));
pfree(tmp);
PG_RETURN_POINTER(result);
PG_RETURN_DATUM(result);
}
@ -1809,17 +1811,19 @@ numeric_float4(PG_FUNCTION_ARGS)
{
Numeric num = PG_GETARG_NUMERIC(0);
char *tmp;
float32 result;
Datum result;
if (NUMERIC_IS_NAN(num))
PG_RETURN_FLOAT4(NAN);
PG_RETURN_FLOAT4((float4) NAN);
tmp = DatumGetCString(DirectFunctionCall1(numeric_out,
NumericGetDatum(num)));
result = float4in(tmp);
result = DirectFunctionCall1(float4in, CStringGetDatum(tmp));
pfree(tmp);
PG_RETURN_POINTER(result);
PG_RETURN_DATUM(result);
}

View File

@ -3,7 +3,7 @@
* numutils.c
* utility functions for I/O of built-in numeric types.
*
* integer: itoa, ltoa
* integer: pg_itoa, pg_ltoa
* floating point: ftoa, atof1
*
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
@ -11,7 +11,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/numutils.c,v 1.41 2000/07/12 22:59:09 petere Exp $
* $Header: /cvsroot/pgsql/src/backend/utils/adt/numutils.c,v 1.42 2000/08/01 18:29:35 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@ -116,27 +116,27 @@ pg_atoi(char *s, int size, int c)
}
/*
* itoa - converts a short int to its string represention
* pg_itoa - converts a short int to its string represention
*
* Note:
* previously based on ~ingres/source/gutil/atoi.c
* now uses vendor's sprintf conversion
*/
void
itoa(int i, char *a)
pg_itoa(int16 i, char *a)
{
sprintf(a, "%hd", (short) i);
}
/*
* ltoa - converts a long int to its string represention
* pg_ltoa - converts a long int to its string represention
*
* Note:
* previously based on ~ingres/source/gutil/atoi.c
* now uses vendor's sprintf conversion
*/
void
ltoa(int32 l, char *a)
pg_ltoa(int32 l, char *a)
{
sprintf(a, "%d", l);
}

View File

@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/oid.c,v 1.37 2000/07/03 23:09:52 wieck Exp $
* $Header: /cvsroot/pgsql/src/backend/utils/adt/oid.c,v 1.38 2000/08/01 18:29:35 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@ -79,7 +79,7 @@ oidvectorout(PG_FUNCTION_ARGS)
{
if (num != 0)
*rp++ = ' ';
ltoa(oidArray[num], rp);
pg_ltoa((int32) oidArray[num], rp);
while (*++rp != '\0')
;
}

View File

@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: pg_proc.h,v 1.154 2000/07/31 22:39:05 tgl Exp $
* $Id: pg_proc.h,v 1.155 2000/08/01 18:29:30 tgl Exp $
*
* NOTES
* The script catalog/genbki.sh reads this file and generates .bki
@ -365,13 +365,13 @@ DESCR("modulus");
DATA(insert OID = 175 ( int42mod PGUID 12 f t t t 2 f 23 "23 21" 100 0 0 100 int42mod - ));
DESCR("modulus");
DATA(insert OID = 176 ( int2pl PGUID 12 f t t t 2 f 21 "21 21" 100 0 0 100 int2pl - ));
DESCR("addition");
DESCR("add");
DATA(insert OID = 177 ( int4pl PGUID 12 f t t t 2 f 23 "23 23" 100 0 0 100 int4pl - ));
DESCR("addition");
DESCR("add");
DATA(insert OID = 178 ( int24pl PGUID 12 f t t t 2 f 23 "21 23" 100 0 0 100 int24pl - ));
DESCR("addition");
DESCR("add");
DATA(insert OID = 179 ( int42pl PGUID 12 f t t t 2 f 23 "23 21" 100 0 0 100 int42pl - ));
DESCR("addition");
DESCR("add");
DATA(insert OID = 180 ( int2mi PGUID 12 f t t t 2 f 21 "21 21" 100 0 0 100 int2mi - ));
DESCR("subtract");
DATA(insert OID = 181 ( int4mi PGUID 12 f t t t 2 f 23 "23 23" 100 0 0 100 int4mi - ));
@ -415,27 +415,27 @@ DESCR("r-tree");
/* OIDS 200 - 299 */
DATA(insert OID = 200 ( float4in PGUID 11 f t t t 1 f 700 "0" 100 0 0 100 float4in - ));
DATA(insert OID = 200 ( float4in PGUID 12 f t t t 1 f 700 "0" 100 0 0 100 float4in - ));
DESCR("(internal)");
DATA(insert OID = 201 ( float4out PGUID 11 f t t t 1 f 23 "0" 100 0 0 100 float4out - ));
DATA(insert OID = 201 ( float4out PGUID 12 f t t t 1 f 23 "700" 100 0 0 100 float4out - ));
DESCR("(internal)");
DATA(insert OID = 202 ( float4mul PGUID 11 f t t t 2 f 700 "700 700" 100 0 0 100 float4mul - ));
DATA(insert OID = 202 ( float4mul PGUID 12 f t t t 2 f 700 "700 700" 100 0 0 100 float4mul - ));
DESCR("multiply");
DATA(insert OID = 203 ( float4div PGUID 11 f t t t 2 f 700 "700 700" 100 0 0 100 float4div - ));
DATA(insert OID = 203 ( float4div PGUID 12 f t t t 2 f 700 "700 700" 100 0 0 100 float4div - ));
DESCR("divide");
DATA(insert OID = 204 ( float4pl PGUID 11 f t t t 2 f 700 "700 700" 100 0 0 100 float4pl - ));
DESCR("addition");
DATA(insert OID = 205 ( float4mi PGUID 11 f t t t 2 f 700 "700 700" 100 0 0 100 float4mi - ));
DATA(insert OID = 204 ( float4pl PGUID 12 f t t t 2 f 700 "700 700" 100 0 0 100 float4pl - ));
DESCR("add");
DATA(insert OID = 205 ( float4mi PGUID 12 f t t t 2 f 700 "700 700" 100 0 0 100 float4mi - ));
DESCR("subtract");
DATA(insert OID = 206 ( float4um PGUID 11 f t t t 1 f 700 "700" 100 0 0 100 float4um - ));
DATA(insert OID = 206 ( float4um PGUID 12 f t t t 1 f 700 "700" 100 0 0 100 float4um - ));
DESCR("negate");
DATA(insert OID = 207 ( float4abs PGUID 11 f t t t 1 f 700 "700" 100 0 0 100 float4abs - ));
DATA(insert OID = 207 ( float4abs PGUID 12 f t t t 1 f 700 "700" 100 0 0 100 float4abs - ));
DESCR("absolute value");
DATA(insert OID = 208 ( float4_accum PGUID 12 f t t t 2 f 1022 "1022 700" 100 0 0 100 float4_accum - ));
DESCR("aggregate transition function");
DATA(insert OID = 209 ( float4larger PGUID 11 f t t t 2 f 700 "700 700" 100 0 0 100 float4larger - ));
DATA(insert OID = 209 ( float4larger PGUID 12 f t t t 2 f 700 "700 700" 100 0 0 100 float4larger - ));
DESCR("larger of two");
DATA(insert OID = 211 ( float4smaller PGUID 11 f t t t 2 f 700 "700 700" 100 0 0 100 float4smaller - ));
DATA(insert OID = 211 ( float4smaller PGUID 12 f t t t 2 f 700 "700 700" 100 0 0 100 float4smaller - ));
DESCR("smaller of two");
DATA(insert OID = 212 ( int4um PGUID 12 f t t t 1 f 23 "23" 100 0 0 100 int4um - ));
@ -443,27 +443,27 @@ DESCR("negate");
DATA(insert OID = 213 ( int2um PGUID 12 f t t t 1 f 21 "21" 100 0 0 100 int2um - ));
DESCR("negate");
DATA(insert OID = 214 ( float8in PGUID 11 f t t t 1 f 701 "0" 100 0 0 100 float8in - ));
DATA(insert OID = 214 ( float8in PGUID 12 f t t t 1 f 701 "0" 100 0 0 100 float8in - ));
DESCR("(internal)");
DATA(insert OID = 215 ( float8out PGUID 11 f t t t 1 f 23 "0" 100 0 0 100 float8out - ));
DATA(insert OID = 215 ( float8out PGUID 12 f t t t 1 f 23 "701" 100 0 0 100 float8out - ));
DESCR("(internal)");
DATA(insert OID = 216 ( float8mul PGUID 11 f t t t 2 f 701 "701 701" 100 0 0 100 float8mul - ));
DATA(insert OID = 216 ( float8mul PGUID 12 f t t t 2 f 701 "701 701" 100 0 0 100 float8mul - ));
DESCR("multiply");
DATA(insert OID = 217 ( float8div PGUID 11 f t t t 2 f 701 "701 701" 100 0 0 100 float8div - ));
DATA(insert OID = 217 ( float8div PGUID 12 f t t t 2 f 701 "701 701" 100 0 0 100 float8div - ));
DESCR("divide");
DATA(insert OID = 218 ( float8pl PGUID 11 f t t t 2 f 701 "701 701" 100 0 0 100 float8pl - ));
DESCR("addition");
DATA(insert OID = 219 ( float8mi PGUID 11 f t t t 2 f 701 "701 701" 100 0 0 100 float8mi - ));
DATA(insert OID = 218 ( float8pl PGUID 12 f t t t 2 f 701 "701 701" 100 0 0 100 float8pl - ));
DESCR("add");
DATA(insert OID = 219 ( float8mi PGUID 12 f t t t 2 f 701 "701 701" 100 0 0 100 float8mi - ));
DESCR("subtract");
DATA(insert OID = 220 ( float8um PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 float8um - ));
DATA(insert OID = 220 ( float8um PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 float8um - ));
DESCR("negate");
DATA(insert OID = 221 ( float8abs PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 float8abs - ));
DATA(insert OID = 221 ( float8abs PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 float8abs - ));
DESCR("absolute value");
DATA(insert OID = 222 ( float8_accum PGUID 12 f t t t 2 f 1022 "1022 701" 100 0 0 100 float8_accum - ));
DESCR("aggregate transition function");
DATA(insert OID = 223 ( float8larger PGUID 11 f t t t 2 f 701 "701 701" 100 0 0 100 float8larger - ));
DATA(insert OID = 223 ( float8larger PGUID 12 f t t t 2 f 701 "701 701" 100 0 0 100 float8larger - ));
DESCR("larger of two");
DATA(insert OID = 224 ( float8smaller PGUID 11 f t t t 2 f 701 "701 701" 100 0 0 100 float8smaller - ));
DATA(insert OID = 224 ( float8smaller PGUID 12 f t t t 2 f 701 "701 701" 100 0 0 100 float8smaller - ));
DESCR("smaller of two");
DATA(insert OID = 225 ( lseg_center PGUID 12 f t t t 1 f 600 "601" 100 0 0 100 lseg_center - ));
@ -473,19 +473,19 @@ DESCR("center of");
DATA(insert OID = 227 ( poly_center PGUID 12 f t t t 1 f 600 "604" 100 0 0 100 poly_center - ));
DESCR("center of");
DATA(insert OID = 228 ( dround PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dround - ));
DESCR("round to integer");
DATA(insert OID = 229 ( dtrunc PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dtrunc - ));
DATA(insert OID = 228 ( dround PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dround - ));
DESCR("round to nearest integer");
DATA(insert OID = 229 ( dtrunc PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dtrunc - ));
DESCR("truncate to integer");
DATA(insert OID = 230 ( dsqrt PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dsqrt - ));
DATA(insert OID = 230 ( dsqrt PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dsqrt - ));
DESCR("square root");
DATA(insert OID = 231 ( dcbrt PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dcbrt - ));
DATA(insert OID = 231 ( dcbrt PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dcbrt - ));
DESCR("cube root");
DATA(insert OID = 232 ( dpow PGUID 11 f t t t 2 f 701 "701 701" 100 0 0 100 dpow - ));
DATA(insert OID = 232 ( dpow PGUID 12 f t t t 2 f 701 "701 701" 100 0 0 100 dpow - ));
DESCR("exponentiation (x^y)");
DATA(insert OID = 233 ( dexp PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dexp - ));
DATA(insert OID = 233 ( dexp PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dexp - ));
DESCR("natural exponential (e^x)");
DATA(insert OID = 234 ( dlog1 PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dlog1 - ));
DATA(insert OID = 234 ( dlog1 PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dlog1 - ));
DESCR("natural logarithm");
DATA(insert OID = 235 ( float8 PGUID 12 f t t t 1 f 701 "21" 100 0 0 100 i2tod - ));
DESCR("convert int2 to float8");
@ -507,7 +507,7 @@ DESCR("(internal)");
DATA(insert OID = 243 ( reltimeout PGUID 12 f t f t 1 f 23 "0" 100 0 0 100 reltimeout - ));
DESCR("(internal)");
DATA(insert OID = 244 ( timepl PGUID 12 f t f t 2 f 702 "702 703" 100 0 0 100 timepl - ));
DESCR("addition");
DESCR("add");
DATA(insert OID = 245 ( timemi PGUID 12 f t f t 2 f 702 "702 703" 100 0 0 100 timemi - ));
DESCR("subtract");
DATA(insert OID = 246 ( tintervalin PGUID 12 f t f t 1 f 704 "0" 100 0 0 100 tintervalin - ));
@ -579,80 +579,80 @@ DESCR("");
DATA(insert OID = 278 ( inter_lb PGUID 12 f t t t 2 f 16 "628 603" 100 0 0 100 inter_lb - ));
DESCR("");
DATA(insert OID = 279 ( float48mul PGUID 11 f t t t 2 f 701 "700 701" 100 0 0 100 float48mul - ));
DATA(insert OID = 279 ( float48mul PGUID 12 f t t t 2 f 701 "700 701" 100 0 0 100 float48mul - ));
DESCR("multiply");
DATA(insert OID = 280 ( float48div PGUID 11 f t t t 2 f 701 "700 701" 100 0 0 100 float48div - ));
DATA(insert OID = 280 ( float48div PGUID 12 f t t t 2 f 701 "700 701" 100 0 0 100 float48div - ));
DESCR("divide");
DATA(insert OID = 281 ( float48pl PGUID 11 f t t t 2 f 701 "700 701" 100 0 0 100 float48pl - ));
DESCR("addition");
DATA(insert OID = 282 ( float48mi PGUID 11 f t t t 2 f 701 "700 701" 100 0 0 100 float48mi - ));
DATA(insert OID = 281 ( float48pl PGUID 12 f t t t 2 f 701 "700 701" 100 0 0 100 float48pl - ));
DESCR("add");
DATA(insert OID = 282 ( float48mi PGUID 12 f t t t 2 f 701 "700 701" 100 0 0 100 float48mi - ));
DESCR("subtract");
DATA(insert OID = 283 ( float84mul PGUID 11 f t t t 2 f 701 "701 700" 100 0 0 100 float84mul - ));
DATA(insert OID = 283 ( float84mul PGUID 12 f t t t 2 f 701 "701 700" 100 0 0 100 float84mul - ));
DESCR("multiply");
DATA(insert OID = 284 ( float84div PGUID 11 f t t t 2 f 701 "701 700" 100 0 0 100 float84div - ));
DATA(insert OID = 284 ( float84div PGUID 12 f t t t 2 f 701 "701 700" 100 0 0 100 float84div - ));
DESCR("divide");
DATA(insert OID = 285 ( float84pl PGUID 11 f t t t 2 f 701 "701 700" 100 0 0 100 float84pl - ));
DESCR("addition");
DATA(insert OID = 286 ( float84mi PGUID 11 f t t t 2 f 701 "701 700" 100 0 0 100 float84mi - ));
DATA(insert OID = 285 ( float84pl PGUID 12 f t t t 2 f 701 "701 700" 100 0 0 100 float84pl - ));
DESCR("add");
DATA(insert OID = 286 ( float84mi PGUID 12 f t t t 2 f 701 "701 700" 100 0 0 100 float84mi - ));
DESCR("subtract");
DATA(insert OID = 287 ( float4eq PGUID 11 f t t t 2 f 16 "700 700" 100 0 0 100 float4eq - ));
DATA(insert OID = 287 ( float4eq PGUID 12 f t t t 2 f 16 "700 700" 100 0 0 100 float4eq - ));
DESCR("equal");
DATA(insert OID = 288 ( float4ne PGUID 11 f t t t 2 f 16 "700 700" 100 0 0 100 float4ne - ));
DATA(insert OID = 288 ( float4ne PGUID 12 f t t t 2 f 16 "700 700" 100 0 0 100 float4ne - ));
DESCR("not equal");
DATA(insert OID = 289 ( float4lt PGUID 11 f t t t 2 f 16 "700 700" 100 0 0 100 float4lt - ));
DATA(insert OID = 289 ( float4lt PGUID 12 f t t t 2 f 16 "700 700" 100 0 0 100 float4lt - ));
DESCR("less-than");
DATA(insert OID = 290 ( float4le PGUID 11 f t t t 2 f 16 "700 700" 100 0 0 100 float4le - ));
DATA(insert OID = 290 ( float4le PGUID 12 f t t t 2 f 16 "700 700" 100 0 0 100 float4le - ));
DESCR("less-than-or-equal");
DATA(insert OID = 291 ( float4gt PGUID 11 f t t t 2 f 16 "700 700" 100 0 0 100 float4gt - ));
DATA(insert OID = 291 ( float4gt PGUID 12 f t t t 2 f 16 "700 700" 100 0 0 100 float4gt - ));
DESCR("greater-than");
DATA(insert OID = 292 ( float4ge PGUID 11 f t t t 2 f 16 "700 700" 100 0 0 100 float4ge - ));
DATA(insert OID = 292 ( float4ge PGUID 12 f t t t 2 f 16 "700 700" 100 0 0 100 float4ge - ));
DESCR("greater-than-or-equal");
DATA(insert OID = 293 ( float8eq PGUID 11 f t t t 2 f 16 "701 701" 100 0 0 100 float8eq - ));
DATA(insert OID = 293 ( float8eq PGUID 12 f t t t 2 f 16 "701 701" 100 0 0 100 float8eq - ));
DESCR("equal");
DATA(insert OID = 294 ( float8ne PGUID 11 f t t t 2 f 16 "701 701" 100 0 0 100 float8ne - ));
DATA(insert OID = 294 ( float8ne PGUID 12 f t t t 2 f 16 "701 701" 100 0 0 100 float8ne - ));
DESCR("not equal");
DATA(insert OID = 295 ( float8lt PGUID 11 f t t t 2 f 16 "701 701" 100 0 0 100 float8lt - ));
DATA(insert OID = 295 ( float8lt PGUID 12 f t t t 2 f 16 "701 701" 100 0 0 100 float8lt - ));
DESCR("less-than");
DATA(insert OID = 296 ( float8le PGUID 11 f t t t 2 f 16 "701 701" 100 0 0 100 float8le - ));
DATA(insert OID = 296 ( float8le PGUID 12 f t t t 2 f 16 "701 701" 100 0 0 100 float8le - ));
DESCR("less-than-or-equal");
DATA(insert OID = 297 ( float8gt PGUID 11 f t t t 2 f 16 "701 701" 100 0 0 100 float8gt - ));
DATA(insert OID = 297 ( float8gt PGUID 12 f t t t 2 f 16 "701 701" 100 0 0 100 float8gt - ));
DESCR("greater-than");
DATA(insert OID = 298 ( float8ge PGUID 11 f t t t 2 f 16 "701 701" 100 0 0 100 float8ge - ));
DATA(insert OID = 298 ( float8ge PGUID 12 f t t t 2 f 16 "701 701" 100 0 0 100 float8ge - ));
DESCR("greater-than-or-equal");
DATA(insert OID = 299 ( float48eq PGUID 11 f t t t 2 f 16 "700 701" 100 0 0 100 float48eq - ));
DATA(insert OID = 299 ( float48eq PGUID 12 f t t t 2 f 16 "700 701" 100 0 0 100 float48eq - ));
DESCR("equal");
/* OIDS 300 - 399 */
DATA(insert OID = 300 ( float48ne PGUID 11 f t t t 2 f 16 "700 701" 100 0 0 100 float48ne - ));
DATA(insert OID = 300 ( float48ne PGUID 12 f t t t 2 f 16 "700 701" 100 0 0 100 float48ne - ));
DESCR("not equal");
DATA(insert OID = 301 ( float48lt PGUID 11 f t t t 2 f 16 "700 701" 100 0 0 100 float48lt - ));
DATA(insert OID = 301 ( float48lt PGUID 12 f t t t 2 f 16 "700 701" 100 0 0 100 float48lt - ));
DESCR("less-than");
DATA(insert OID = 302 ( float48le PGUID 11 f t t t 2 f 16 "700 701" 100 0 0 100 float48le - ));
DATA(insert OID = 302 ( float48le PGUID 12 f t t t 2 f 16 "700 701" 100 0 0 100 float48le - ));
DESCR("less-than-or-equal");
DATA(insert OID = 303 ( float48gt PGUID 11 f t t t 2 f 16 "700 701" 100 0 0 100 float48gt - ));
DATA(insert OID = 303 ( float48gt PGUID 12 f t t t 2 f 16 "700 701" 100 0 0 100 float48gt - ));
DESCR("greater-than");
DATA(insert OID = 304 ( float48ge PGUID 11 f t t t 2 f 16 "700 701" 100 0 0 100 float48ge - ));
DATA(insert OID = 304 ( float48ge PGUID 12 f t t t 2 f 16 "700 701" 100 0 0 100 float48ge - ));
DESCR("greater-than-or-equal");
DATA(insert OID = 305 ( float84eq PGUID 11 f t t t 2 f 16 "701 700" 100 0 0 100 float84eq - ));
DATA(insert OID = 305 ( float84eq PGUID 12 f t t t 2 f 16 "701 700" 100 0 0 100 float84eq - ));
DESCR("equal");
DATA(insert OID = 306 ( float84ne PGUID 11 f t t t 2 f 16 "701 700" 100 0 0 100 float84ne - ));
DATA(insert OID = 306 ( float84ne PGUID 12 f t t t 2 f 16 "701 700" 100 0 0 100 float84ne - ));
DESCR("not equal");
DATA(insert OID = 307 ( float84lt PGUID 11 f t t t 2 f 16 "701 700" 100 0 0 100 float84lt - ));
DATA(insert OID = 307 ( float84lt PGUID 12 f t t t 2 f 16 "701 700" 100 0 0 100 float84lt - ));
DESCR("less-than");
DATA(insert OID = 308 ( float84le PGUID 11 f t t t 2 f 16 "701 700" 100 0 0 100 float84le - ));
DATA(insert OID = 308 ( float84le PGUID 12 f t t t 2 f 16 "701 700" 100 0 0 100 float84le - ));
DESCR("less-than-or-equal");
DATA(insert OID = 309 ( float84gt PGUID 11 f t t t 2 f 16 "701 700" 100 0 0 100 float84gt - ));
DATA(insert OID = 309 ( float84gt PGUID 12 f t t t 2 f 16 "701 700" 100 0 0 100 float84gt - ));
DESCR("greater-than");
DATA(insert OID = 310 ( float84ge PGUID 11 f t t t 2 f 16 "701 700" 100 0 0 100 float84ge - ));
DATA(insert OID = 310 ( float84ge PGUID 12 f t t t 2 f 16 "701 700" 100 0 0 100 float84ge - ));
DESCR("greater-than-or-equal");
DATA(insert OID = 311 ( float8 PGUID 11 f t t t 1 f 701 "700" 100 0 0 100 ftod - ));
DATA(insert OID = 311 ( float8 PGUID 12 f t t t 1 f 701 "700" 100 0 0 100 ftod - ));
DESCR("convert float4 to float8");
DATA(insert OID = 312 ( float4 PGUID 11 f t t t 1 f 700 "701" 100 0 0 100 dtof - ));
DATA(insert OID = 312 ( float4 PGUID 12 f t t t 1 f 700 "701" 100 0 0 100 dtof - ));
DESCR("convert float8 to float4");
DATA(insert OID = 313 ( int4 PGUID 12 f t t t 1 f 23 "21" 100 0 0 100 i2toi4 - ));
DESCR("convert int2 to int4");
@ -662,11 +662,11 @@ DATA(insert OID = 315 ( int2vectoreq PGUID 12 f t t t 2 f 16 "22 22" 100 0
DESCR("equal");
DATA(insert OID = 316 ( float8 PGUID 12 f t t t 1 f 701 "23" 100 0 0 100 i4tod - ));
DESCR("convert int4 to float8");
DATA(insert OID = 317 ( int4 PGUID 11 f t t t 1 f 23 "701" 100 0 0 100 dtoi4 - ));
DATA(insert OID = 317 ( int4 PGUID 12 f t t t 1 f 23 "701" 100 0 0 100 dtoi4 - ));
DESCR("convert float8 to int4");
DATA(insert OID = 318 ( float4 PGUID 12 f t t t 1 f 700 "23" 100 0 0 100 i4tof - ));
DESCR("convert int4 to float4");
DATA(insert OID = 319 ( int4 PGUID 11 f t t t 1 f 23 "700" 100 0 0 100 ftoi4 - ));
DATA(insert OID = 319 ( int4 PGUID 12 f t t t 1 f 23 "700" 100 0 0 100 ftoi4 - ));
DESCR("convert float4 to int4");
DATA(insert OID = 320 ( rtinsert PGUID 12 f t f t 5 f 23 "0 0 0 0 0" 100 0 0 100 rtinsert - ));
@ -842,9 +842,9 @@ DESCR("(internal)");
DATA(insert OID = 462 ( int8um PGUID 12 f t t t 1 f 20 "20" 100 0 0 100 int8um - ));
DESCR("negate");
DATA(insert OID = 463 ( int8pl PGUID 12 f t t t 2 f 20 "20 20" 100 0 0 100 int8pl - ));
DESCR("addition");
DESCR("add");
DATA(insert OID = 464 ( int8mi PGUID 12 f t t t 2 f 20 "20 20" 100 0 0 100 int8mi - ));
DESCR("subtraction");
DESCR("subtract");
DATA(insert OID = 465 ( int8mul PGUID 12 f t t t 2 f 20 "20 20" 100 0 0 100 int8mul - ));
DESCR("multiply");
DATA(insert OID = 466 ( int8div PGUID 12 f t t t 2 f 20 "20 20" 100 0 0 100 int8div - ));
@ -1058,11 +1058,11 @@ DESCR("convert float8 to text");
DATA(insert OID = 841 ( text PGUID 12 f t t t 1 f 25 "700" 100 0 0 100 float4_text -));
DESCR("convert float4 to text");
DATA(insert OID = 846 ( cash_mul_flt4 PGUID 11 f t t t 2 f 790 "790 700" 100 0 0 100 cash_mul_flt4 - ));
DATA(insert OID = 846 ( cash_mul_flt4 PGUID 12 f t t t 2 f 790 "790 700" 100 0 0 100 cash_mul_flt4 - ));
DESCR("multiply");
DATA(insert OID = 847 ( cash_div_flt4 PGUID 11 f t t t 2 f 790 "790 700" 100 0 0 100 cash_div_flt4 - ));
DATA(insert OID = 847 ( cash_div_flt4 PGUID 12 f t t t 2 f 790 "790 700" 100 0 0 100 cash_div_flt4 - ));
DESCR("divide");
DATA(insert OID = 848 ( flt4_mul_cash PGUID 11 f t t t 2 f 790 "700 790" 100 0 0 100 flt4_mul_cash - ));
DATA(insert OID = 848 ( flt4_mul_cash PGUID 12 f t t t 2 f 790 "700 790" 100 0 0 100 flt4_mul_cash - ));
DESCR("multiply");
DATA(insert OID = 849 ( position PGUID 12 f t t t 2 f 23 "25 25" 100 0 1 0 textpos - ));
@ -1127,19 +1127,19 @@ DESCR("greater-than");
DATA(insert OID = 893 ( cash_ge PGUID 11 f t t t 2 f 16 "790 790" 100 0 0 100 cash_ge - ));
DESCR("greater-than-or-equal");
DATA(insert OID = 894 ( cash_pl PGUID 11 f t t t 2 f 790 "790 790" 100 0 0 100 cash_pl - ));
DESCR("addition");
DESCR("add");
DATA(insert OID = 895 ( cash_mi PGUID 11 f t t t 2 f 790 "790 790" 100 0 0 100 cash_mi - ));
DESCR("subtract");
DATA(insert OID = 896 ( cash_mul_flt8 PGUID 11 f t t t 2 f 790 "790 701" 100 0 0 100 cash_mul_flt8 - ));
DATA(insert OID = 896 ( cash_mul_flt8 PGUID 12 f t t t 2 f 790 "790 701" 100 0 0 100 cash_mul_flt8 - ));
DESCR("multiply");
DATA(insert OID = 897 ( cash_div_flt8 PGUID 11 f t t t 2 f 790 "790 701" 100 0 0 100 cash_div_flt8 - ));
DATA(insert OID = 897 ( cash_div_flt8 PGUID 12 f t t t 2 f 790 "790 701" 100 0 0 100 cash_div_flt8 - ));
DESCR("divide");
DATA(insert OID = 898 ( cashlarger PGUID 11 f t t t 2 f 790 "790 790" 100 0 0 100 cashlarger - ));
DESCR("larger of two");
DATA(insert OID = 899 ( cashsmaller PGUID 11 f t t t 2 f 790 "790 790" 100 0 0 100 cashsmaller - ));
DESCR("smaller of two");
DATA(insert OID = 919 ( flt8_mul_cash PGUID 11 f t t t 2 f 790 "701 790" 100 0 0 100 flt8_mul_cash - ));
DATA(insert OID = 919 ( flt8_mul_cash PGUID 12 f t t t 2 f 790 "701 790" 100 0 0 100 flt8_mul_cash - ));
DESCR("multiply");
/* OIDS 900 - 999 */
@ -1348,7 +1348,7 @@ DESCR("smaller of two");
DATA(insert OID = 1140 ( date_mi PGUID 12 f t t t 2 f 23 "1082 1082" 100 0 0 100 date_mi - ));
DESCR("subtract");
DATA(insert OID = 1141 ( date_pli PGUID 12 f t t t 2 f 1082 "1082 23" 100 0 0 100 date_pli - ));
DESCR("addition");
DESCR("add");
DATA(insert OID = 1142 ( date_mii PGUID 12 f t t t 2 f 1082 "1082 23" 100 0 0 100 date_mii - ));
DESCR("subtract");
DATA(insert OID = 1143 ( time_in PGUID 12 f t f t 1 f 1083 "0" 100 0 0 100 time_in - ));
@ -1359,7 +1359,7 @@ DATA(insert OID = 1145 ( time_eq PGUID 12 f t t t 2 f 16 "1083 1083" 100 0
DESCR("equal");
DATA(insert OID = 1146 ( circle_add_pt PGUID 12 f t t t 2 f 718 "718 600" 100 0 0 100 circle_add_pt - ));
DESCR("addition");
DESCR("add");
DATA(insert OID = 1147 ( circle_sub_pt PGUID 12 f t t t 2 f 718 "718 600" 100 0 0 100 circle_sub_pt - ));
DESCR("subtract");
DATA(insert OID = 1148 ( circle_mul_pt PGUID 12 f t t t 2 f 718 "718 600" 100 0 0 100 circle_mul_pt - ));
@ -1405,7 +1405,7 @@ DESCR("greater-than");
DATA(insert OID = 1168 ( interval_um PGUID 12 f t f t 1 f 1186 "1186" 100 0 0 100 interval_um - ));
DESCR("subtract");
DATA(insert OID = 1169 ( interval_pl PGUID 12 f t f t 2 f 1186 "1186 1186" 100 0 0 100 interval_pl - ));
DESCR("addition");
DESCR("add");
DATA(insert OID = 1170 ( interval_mi PGUID 12 f t f t 2 f 1186 "1186 1186" 100 0 0 100 interval_mi - ));
DESCR("subtract");
DATA(insert OID = 1171 ( date_part PGUID 12 f t f t 2 f 701 "25 1184" 100 0 0 100 timestamp_part - ));
@ -1494,17 +1494,17 @@ DATA(insert OID = 1272 ( datetime_pl PGUID 12 f t f t 2 f 1184 "1082 1083" 1
DESCR("convert date and time to timestamp");
DATA(insert OID = 1274 ( int84pl PGUID 12 f t t t 2 f 20 "20 23" 100 0 0 100 int84pl - ));
DESCR("addition");
DESCR("add");
DATA(insert OID = 1275 ( int84mi PGUID 12 f t t t 2 f 20 "20 23" 100 0 0 100 int84mi - ));
DESCR("subtraction");
DESCR("subtract");
DATA(insert OID = 1276 ( int84mul PGUID 12 f t t t 2 f 20 "20 23" 100 0 0 100 int84mul - ));
DESCR("multiply");
DATA(insert OID = 1277 ( int84div PGUID 12 f t t t 2 f 20 "20 23" 100 0 0 100 int84div - ));
DESCR("divide");
DATA(insert OID = 1278 ( int48pl PGUID 12 f t t t 2 f 20 "23 20" 100 0 0 100 int48pl - ));
DESCR("addition");
DESCR("add");
DATA(insert OID = 1279 ( int48mi PGUID 12 f t t t 2 f 20 "23 20" 100 0 0 100 int48mi - ));
DESCR("subtraction");
DESCR("subtract");
DATA(insert OID = 1280 ( int48mul PGUID 12 f t t t 2 f 20 "23 20" 100 0 0 100 int48mul - ));
DESCR("multiply");
DATA(insert OID = 1281 ( int48div PGUID 12 f t t t 2 f 20 "23 20" 100 0 0 100 int48div - ));
@ -1582,23 +1582,23 @@ DESCR("character length");
DATA(insert OID = 1326 ( interval_div PGUID 12 f t f t 2 f 1186 "1186 701" 100 0 0 100 interval_div - ));
DESCR("divide");
DATA(insert OID = 1339 ( dlog10 PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dlog10 - ));
DATA(insert OID = 1339 ( dlog10 PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dlog10 - ));
DESCR("base 10 logarithm");
DATA(insert OID = 1340 ( log PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dlog10 - ));
DATA(insert OID = 1340 ( log PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dlog10 - ));
DESCR("base 10 logarithm");
DATA(insert OID = 1341 ( ln PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dlog1 - ));
DATA(insert OID = 1341 ( ln PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dlog1 - ));
DESCR("natural logarithm");
DATA(insert OID = 1342 ( round PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dround - ));
DESCR("round to integral part");
DATA(insert OID = 1343 ( trunc PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dtrunc - ));
DESCR("truncate to integral part");
DATA(insert OID = 1344 ( sqrt PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dsqrt - ));
DATA(insert OID = 1342 ( round PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dround - ));
DESCR("round to nearest integer");
DATA(insert OID = 1343 ( trunc PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dtrunc - ));
DESCR("truncate to integer");
DATA(insert OID = 1344 ( sqrt PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dsqrt - ));
DESCR("square root");
DATA(insert OID = 1345 ( cbrt PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dcbrt - ));
DATA(insert OID = 1345 ( cbrt PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dcbrt - ));
DESCR("cube root");
DATA(insert OID = 1346 ( pow PGUID 11 f t t t 2 f 701 "701 701" 100 0 0 100 dpow - ));
DATA(insert OID = 1346 ( pow PGUID 12 f t t t 2 f 701 "701 701" 100 0 0 100 dpow - ));
DESCR("exponentiation");
DATA(insert OID = 1347 ( exp PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dexp - ));
DATA(insert OID = 1347 ( exp PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dexp - ));
DESCR("exponential");
DATA(insert OID = 1348 ( obj_description PGUID 14 f t f t 1 f 25 "26" 100 0 0 100 "select description from pg_description where objoid = $1" - ));
@ -1696,9 +1696,9 @@ DATA(insert OID = 1392 ( factorial PGUID 12 f t t t 1 f 23 "23" 100 0 0 100
DESCR("factorial");
DATA(insert OID = 1393 ( factorial PGUID 12 f t t t 1 f 20 "20" 100 0 0 100 int8fac - ));
DESCR("factorial");
DATA(insert OID = 1394 ( abs PGUID 11 f t t t 1 f 700 "700" 100 0 0 100 float4abs - ));
DATA(insert OID = 1394 ( abs PGUID 12 f t t t 1 f 700 "700" 100 0 0 100 float4abs - ));
DESCR("absolute value");
DATA(insert OID = 1395 ( abs PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 float8abs - ));
DATA(insert OID = 1395 ( abs PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 float8abs - ));
DESCR("absolute value");
DATA(insert OID = 1396 ( abs PGUID 12 f t t t 1 f 20 "20" 100 0 0 100 int8abs - ));
DESCR("absolute value");
@ -1993,34 +1993,34 @@ DESCR("less than");
DATA(insert OID = 1596 ( bitcmp PGUID 11 f t t t 2 f 23 "1560 1560" 100 0 1 0 bitcmp - ));
DESCR("compare");
DATA(insert OID = 1598 ( random PGUID 11 f t f t 0 f 701 "0" 100 0 0 100 drandom - ));
DESCR("radians to degrees");
DATA(insert OID = 1599 ( setseed PGUID 11 f t t t 1 f 23 "701" 100 0 0 100 setseed - ));
DESCR("radians to degrees");
DATA(insert OID = 1598 ( random PGUID 12 f t f t 0 f 701 "0" 100 0 0 100 drandom - ));
DESCR("random value");
DATA(insert OID = 1599 ( setseed PGUID 12 f t f t 1 f 23 "701" 100 0 0 100 setseed - ));
DESCR("set random seed");
/* OIDS 1600 - 1699 */
DATA(insert OID = 1600 ( asin PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dasin - ));
DATA(insert OID = 1600 ( asin PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dasin - ));
DESCR("arcsine");
DATA(insert OID = 1601 ( acos PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dacos - ));
DESCR("arcsine");
DATA(insert OID = 1602 ( atan PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 datan - ));
DATA(insert OID = 1601 ( acos PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dacos - ));
DESCR("arccosine");
DATA(insert OID = 1602 ( atan PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 datan - ));
DESCR("arctangent");
DATA(insert OID = 1603 ( atan2 PGUID 11 f t t t 2 f 701 "701 701" 100 0 0 100 datan2 - ));
DATA(insert OID = 1603 ( atan2 PGUID 12 f t t t 2 f 701 "701 701" 100 0 0 100 datan2 - ));
DESCR("arctangent, two arguments");
DATA(insert OID = 1604 ( sin PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dsin - ));
DATA(insert OID = 1604 ( sin PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dsin - ));
DESCR("sine");
DATA(insert OID = 1605 ( cos PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dcos - ));
DATA(insert OID = 1605 ( cos PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dcos - ));
DESCR("cosine");
DATA(insert OID = 1606 ( tan PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dtan - ));
DATA(insert OID = 1606 ( tan PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dtan - ));
DESCR("tangent");
DATA(insert OID = 1607 ( cot PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 dcot - ));
DATA(insert OID = 1607 ( cot PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 dcot - ));
DESCR("cotangent");
DATA(insert OID = 1608 ( degrees PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 degrees - ));
DATA(insert OID = 1608 ( degrees PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 degrees - ));
DESCR("radians to degrees");
DATA(insert OID = 1609 ( radians PGUID 11 f t t t 1 f 701 "701" 100 0 0 100 radians - ));
DESCR("radians to degrees");
DATA(insert OID = 1610 ( pi PGUID 11 f t t t 0 f 701 "0" 100 0 0 100 dpi - ));
DATA(insert OID = 1609 ( radians PGUID 12 f t t t 1 f 701 "701" 100 0 0 100 radians - ));
DESCR("degrees to radians");
DATA(insert OID = 1610 ( pi PGUID 12 f t t t 0 f 701 "0" 100 0 0 100 dpi - ));
DESCR("PI");
DATA(insert OID = 1618 ( interval_mul PGUID 12 f t t t 2 f 1186 "1186 701" 100 0 0 100 interval_mul - ));
@ -2295,7 +2295,7 @@ DESCR("lower-than");
DATA(insert OID = 1723 ( numeric_le PGUID 12 f t t t 2 f 16 "1700 1700" 100 0 0 100 numeric_le - ));
DESCR("lower-than-or-equal");
DATA(insert OID = 1724 ( numeric_add PGUID 12 f t t t 2 f 1700 "1700 1700" 100 0 0 100 numeric_add - ));
DESCR("addition");
DESCR("add");
DATA(insert OID = 1725 ( numeric_sub PGUID 12 f t t t 2 f 1700 "1700 1700" 100 0 0 100 numeric_sub - ));
DESCR("subtract");
DATA(insert OID = 1726 ( numeric_mul PGUID 12 f t t t 2 f 1700 "1700 1700" 100 0 0 100 numeric_mul - ));

View File

@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: builtins.h,v 1.127 2000/07/30 22:14:04 tgl Exp $
* $Id: builtins.h,v 1.128 2000/08/01 18:29:31 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@ -141,19 +141,9 @@ extern int namestrcpy(Name name, const char *str);
extern int namestrcmp(Name name, const char *str);
/* numutils.c */
/* XXX hack. HP-UX has a ltoa (with different arguments) already. */
#ifdef __hpux
#define ltoa pg_ltoa
#endif /* hpux */
extern int32 pg_atoi(char *s, int size, int c);
/* XXX hack. QNX has itoa and ltoa (with different arguments) already. */
#ifdef __QNX__
#define itoa pg_itoa
#define ltoa pg_ltoa
#endif /* QNX */
extern void itoa(int i, char *a);
extern void ltoa(int32 l, char *a);
extern void pg_itoa(int16 i, char *a);
extern void pg_ltoa(int32 l, char *a);
/*
* Per-opclass comparison functions for new btrees. These are
@ -172,105 +162,99 @@ extern Datum btcharcmp(PG_FUNCTION_ARGS);
extern Datum btnamecmp(PG_FUNCTION_ARGS);
extern Datum bttextcmp(PG_FUNCTION_ARGS);
/* filename.c */
extern char *filename_in(char *file);
extern char *filename_out(char *s);
/* float.c */
extern float32 float4in(char *num);
extern char *float4out(float32 num);
extern float64 float8in(char *num);
extern char *float8out(float64 num);
extern float32 float4abs(float32 arg1);
extern float32 float4um(float32 arg1);
extern float32 float4larger(float32 arg1, float32 arg2);
extern float32 float4smaller(float32 arg1, float32 arg2);
extern float64 float8abs(float64 arg1);
extern float64 float8um(float64 arg1);
extern float64 float8larger(float64 arg1, float64 arg2);
extern float64 float8smaller(float64 arg1, float64 arg2);
extern float32 float4pl(float32 arg1, float32 arg2);
extern float32 float4mi(float32 arg1, float32 arg2);
extern float32 float4mul(float32 arg1, float32 arg2);
extern float32 float4div(float32 arg1, float32 arg2);
extern float64 float8pl(float64 arg1, float64 arg2);
extern float64 float8mi(float64 arg1, float64 arg2);
extern float64 float8mul(float64 arg1, float64 arg2);
extern float64 float8div(float64 arg1, float64 arg2);
extern bool float4eq(float32 arg1, float32 arg2);
extern bool float4ne(float32 arg1, float32 arg2);
extern bool float4lt(float32 arg1, float32 arg2);
extern bool float4le(float32 arg1, float32 arg2);
extern bool float4gt(float32 arg1, float32 arg2);
extern bool float4ge(float32 arg1, float32 arg2);
extern bool float8eq(float64 arg1, float64 arg2);
extern bool float8ne(float64 arg1, float64 arg2);
extern bool float8lt(float64 arg1, float64 arg2);
extern bool float8le(float64 arg1, float64 arg2);
extern bool float8gt(float64 arg1, float64 arg2);
extern bool float8ge(float64 arg1, float64 arg2);
extern float64 ftod(float32 num);
extern Datum float4in(PG_FUNCTION_ARGS);
extern Datum float4out(PG_FUNCTION_ARGS);
extern Datum float8in(PG_FUNCTION_ARGS);
extern Datum float8out(PG_FUNCTION_ARGS);
extern Datum float4abs(PG_FUNCTION_ARGS);
extern Datum float4um(PG_FUNCTION_ARGS);
extern Datum float4larger(PG_FUNCTION_ARGS);
extern Datum float4smaller(PG_FUNCTION_ARGS);
extern Datum float8abs(PG_FUNCTION_ARGS);
extern Datum float8um(PG_FUNCTION_ARGS);
extern Datum float8larger(PG_FUNCTION_ARGS);
extern Datum float8smaller(PG_FUNCTION_ARGS);
extern Datum float4pl(PG_FUNCTION_ARGS);
extern Datum float4mi(PG_FUNCTION_ARGS);
extern Datum float4mul(PG_FUNCTION_ARGS);
extern Datum float4div(PG_FUNCTION_ARGS);
extern Datum float8pl(PG_FUNCTION_ARGS);
extern Datum float8mi(PG_FUNCTION_ARGS);
extern Datum float8mul(PG_FUNCTION_ARGS);
extern Datum float8div(PG_FUNCTION_ARGS);
extern Datum float4eq(PG_FUNCTION_ARGS);
extern Datum float4ne(PG_FUNCTION_ARGS);
extern Datum float4lt(PG_FUNCTION_ARGS);
extern Datum float4le(PG_FUNCTION_ARGS);
extern Datum float4gt(PG_FUNCTION_ARGS);
extern Datum float4ge(PG_FUNCTION_ARGS);
extern Datum float8eq(PG_FUNCTION_ARGS);
extern Datum float8ne(PG_FUNCTION_ARGS);
extern Datum float8lt(PG_FUNCTION_ARGS);
extern Datum float8le(PG_FUNCTION_ARGS);
extern Datum float8gt(PG_FUNCTION_ARGS);
extern Datum float8ge(PG_FUNCTION_ARGS);
extern Datum ftod(PG_FUNCTION_ARGS);
extern Datum i4tod(PG_FUNCTION_ARGS);
extern Datum i2tod(PG_FUNCTION_ARGS);
extern float32 dtof(float64 num);
extern int32 dtoi4(float64 num);
extern Datum dtof(PG_FUNCTION_ARGS);
extern Datum dtoi4(PG_FUNCTION_ARGS);
extern Datum dtoi2(PG_FUNCTION_ARGS);
extern Datum i4tof(PG_FUNCTION_ARGS);
extern Datum i2tof(PG_FUNCTION_ARGS);
extern int32 ftoi4(float32 num);
extern Datum ftoi4(PG_FUNCTION_ARGS);
extern Datum ftoi2(PG_FUNCTION_ARGS);
extern Datum text_float8(PG_FUNCTION_ARGS);
extern Datum text_float4(PG_FUNCTION_ARGS);
extern Datum float8_text(PG_FUNCTION_ARGS);
extern Datum float4_text(PG_FUNCTION_ARGS);
extern float64 dround(float64 arg1);
extern float64 dtrunc(float64 arg1);
extern float64 dsqrt(float64 arg1);
extern float64 dcbrt(float64 arg1);
extern float64 dpow(float64 arg1, float64 arg2);
extern float64 dexp(float64 arg1);
extern float64 dlog1(float64 arg1);
extern float64 dlog10(float64 arg1);
extern float64 dacos(float64 arg1);
extern float64 dasin(float64 arg1);
extern float64 datan(float64 arg1);
extern float64 datan2(float64 arg1, float64 arg2);
extern float64 dcos(float64 arg1);
extern float64 dcot(float64 arg1);
extern float64 dsin(float64 arg1);
extern float64 dtan(float64 arg1);
extern float64 degrees(float64 arg1);
extern float64 dpi(void);
extern float64 radians(float64 arg1);
extern float64 dtan(float64 arg1);
extern float64 drandom(void);
extern int32 setseed(float64 seed);
extern Datum dround(PG_FUNCTION_ARGS);
extern Datum dtrunc(PG_FUNCTION_ARGS);
extern Datum dsqrt(PG_FUNCTION_ARGS);
extern Datum dcbrt(PG_FUNCTION_ARGS);
extern Datum dpow(PG_FUNCTION_ARGS);
extern Datum dexp(PG_FUNCTION_ARGS);
extern Datum dlog1(PG_FUNCTION_ARGS);
extern Datum dlog10(PG_FUNCTION_ARGS);
extern Datum dacos(PG_FUNCTION_ARGS);
extern Datum dasin(PG_FUNCTION_ARGS);
extern Datum datan(PG_FUNCTION_ARGS);
extern Datum datan2(PG_FUNCTION_ARGS);
extern Datum dcos(PG_FUNCTION_ARGS);
extern Datum dcot(PG_FUNCTION_ARGS);
extern Datum dsin(PG_FUNCTION_ARGS);
extern Datum dtan(PG_FUNCTION_ARGS);
extern Datum degrees(PG_FUNCTION_ARGS);
extern Datum dpi(PG_FUNCTION_ARGS);
extern Datum radians(PG_FUNCTION_ARGS);
extern Datum drandom(PG_FUNCTION_ARGS);
extern Datum setseed(PG_FUNCTION_ARGS);
extern Datum float8_accum(PG_FUNCTION_ARGS);
extern Datum float4_accum(PG_FUNCTION_ARGS);
extern Datum float8_avg(PG_FUNCTION_ARGS);
extern Datum float8_variance(PG_FUNCTION_ARGS);
extern Datum float8_stddev(PG_FUNCTION_ARGS);
extern float64 float48pl(float32 arg1, float64 arg2);
extern float64 float48mi(float32 arg1, float64 arg2);
extern float64 float48mul(float32 arg1, float64 arg2);
extern float64 float48div(float32 arg1, float64 arg2);
extern float64 float84pl(float64 arg1, float32 arg2);
extern float64 float84mi(float64 arg1, float32 arg2);
extern float64 float84mul(float64 arg1, float32 arg2);
extern float64 float84div(float64 arg1, float32 arg2);
extern bool float48eq(float32 arg1, float64 arg2);
extern bool float48ne(float32 arg1, float64 arg2);
extern bool float48lt(float32 arg1, float64 arg2);
extern bool float48le(float32 arg1, float64 arg2);
extern bool float48gt(float32 arg1, float64 arg2);
extern bool float48ge(float32 arg1, float64 arg2);
extern bool float84eq(float64 arg1, float32 arg2);
extern bool float84ne(float64 arg1, float32 arg2);
extern bool float84lt(float64 arg1, float32 arg2);
extern bool float84le(float64 arg1, float32 arg2);
extern bool float84gt(float64 arg1, float32 arg2);
extern bool float84ge(float64 arg1, float32 arg2);
extern Datum float48pl(PG_FUNCTION_ARGS);
extern Datum float48mi(PG_FUNCTION_ARGS);
extern Datum float48mul(PG_FUNCTION_ARGS);
extern Datum float48div(PG_FUNCTION_ARGS);
extern Datum float84pl(PG_FUNCTION_ARGS);
extern Datum float84mi(PG_FUNCTION_ARGS);
extern Datum float84mul(PG_FUNCTION_ARGS);
extern Datum float84div(PG_FUNCTION_ARGS);
extern Datum float48eq(PG_FUNCTION_ARGS);
extern Datum float48ne(PG_FUNCTION_ARGS);
extern Datum float48lt(PG_FUNCTION_ARGS);
extern Datum float48le(PG_FUNCTION_ARGS);
extern Datum float48gt(PG_FUNCTION_ARGS);
extern Datum float48ge(PG_FUNCTION_ARGS);
extern Datum float84eq(PG_FUNCTION_ARGS);
extern Datum float84ne(PG_FUNCTION_ARGS);
extern Datum float84lt(PG_FUNCTION_ARGS);
extern Datum float84le(PG_FUNCTION_ARGS);
extern Datum float84gt(PG_FUNCTION_ARGS);
extern Datum float84ge(PG_FUNCTION_ARGS);
/* misc.c */
extern Datum nullvalue(PG_FUNCTION_ARGS);

View File

@ -25,13 +25,13 @@ extern bool cash_ge(Cash *c1, Cash *c2);
extern Cash *cash_pl(Cash *c1, Cash *c2);
extern Cash *cash_mi(Cash *c1, Cash *c2);
extern Cash *cash_mul_flt8(Cash *c, float8 *f);
extern Cash *cash_div_flt8(Cash *c, float8 *f);
extern Cash *flt8_mul_cash(float8 *f, Cash *c);
extern Datum cash_mul_flt8(PG_FUNCTION_ARGS);
extern Datum cash_div_flt8(PG_FUNCTION_ARGS);
extern Datum flt8_mul_cash(PG_FUNCTION_ARGS);
extern Cash *cash_mul_flt4(Cash *c, float4 *f);
extern Cash *cash_div_flt4(Cash *c, float4 *f);
extern Cash *flt4_mul_cash(float4 *f, Cash *c);
extern Datum cash_mul_flt4(PG_FUNCTION_ARGS);
extern Datum cash_div_flt4(PG_FUNCTION_ARGS);
extern Datum flt4_mul_cash(PG_FUNCTION_ARGS);
extern Datum cash_mul_int4(PG_FUNCTION_ARGS);
extern Datum cash_div_int4(PG_FUNCTION_ARGS);