PostgreSQL Source Code
git master
|
#include "postgres.h"
#include <ctype.h>
#include <limits.h>
#include <math.h>
#include "common/int.h"
#include "funcapi.h"
#include "libpq/pqformat.h"
#include "nodes/nodeFuncs.h"
#include "nodes/supportnodes.h"
#include "optimizer/optimizer.h"
#include "utils/builtins.h"
#include "utils/int8.h"
Go to the source code of this file.
Data Structures | |
struct | generate_series_fctx |
Datum dtoi8 | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1340 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, FLOAT8_FITS_IN_INT64, PG_GETARG_FLOAT8, PG_RETURN_INT64, and unlikely.
Referenced by int8_to_char().
Datum ftoi8 | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1375 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, FLOAT4_FITS_IN_INT64, PG_GETARG_FLOAT4, PG_RETURN_INT64, and unlikely.
Datum generate_series_int8 | ( | PG_FUNCTION_ARGS | ) |
Datum generate_series_int8_support | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1502 of file int8.c.
References generate_unaccent_rules::args, DatumGetInt64, estimate_expression_value(), is_funcclause(), IsA, linitial, list_length(), lsecond, lthird, SupportRequestRows::node, PG_GETARG_POINTER, PG_RETURN_POINTER, SupportRequestRows::root, and SupportRequestRows::rows.
Datum generate_series_step_int8 | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1426 of file int8.c.
References generate_series_fctx::current, ereport, errcode(), errmsg(), ERROR, generate_series_fctx::finish, Int64GetDatum(), MemoryContextSwitchTo(), FuncCallContext::multi_call_memory_ctx, palloc(), pg_add_s64_overflow(), PG_GETARG_INT64, PG_NARGS, SRF_FIRSTCALL_INIT, SRF_IS_FIRSTCALL, SRF_PERCALL_SETUP, SRF_RETURN_DONE, SRF_RETURN_NEXT, generate_series_fctx::step, and FuncCallContext::user_fctx.
Referenced by generate_series_int8().
Datum i8tod | ( | PG_FUNCTION_ARGS | ) |
Datum i8tof | ( | PG_FUNCTION_ARGS | ) |
Datum i8tooid | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1396 of file int8.c.
References arg, ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT64, PG_RETURN_OID, PG_UINT32_MAX, and unlikely.
Datum in_range_int8_int8 | ( | PG_FUNCTION_ARGS | ) |
Definition at line 487 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, pg_add_s64_overflow(), PG_GETARG_BOOL, PG_GETARG_INT64, PG_RETURN_BOOL, unlikely, and val.
Datum int28 | ( | PG_FUNCTION_ARGS | ) |
Datum int28div | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1198 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT16, PG_GETARG_INT64, PG_RETURN_INT64, PG_RETURN_NULL, and unlikely.
Datum int28eq | ( | PG_FUNCTION_ARGS | ) |
Definition at line 427 of file int8.c.
References PG_GETARG_INT16, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int28ge | ( | PG_FUNCTION_ARGS | ) |
Definition at line 472 of file int8.c.
References PG_GETARG_INT16, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int28gt | ( | PG_FUNCTION_ARGS | ) |
Definition at line 454 of file int8.c.
References PG_GETARG_INT16, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int28le | ( | PG_FUNCTION_ARGS | ) |
Definition at line 463 of file int8.c.
References PG_GETARG_INT16, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int28lt | ( | PG_FUNCTION_ARGS | ) |
Definition at line 445 of file int8.c.
References PG_GETARG_INT16, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int28mi | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1170 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT16, PG_GETARG_INT64, PG_RETURN_INT64, pg_sub_s64_overflow(), and unlikely.
Datum int28mul | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1184 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT16, PG_GETARG_INT64, pg_mul_s64_overflow(), PG_RETURN_INT64, and unlikely.
Datum int28ne | ( | PG_FUNCTION_ARGS | ) |
Definition at line 436 of file int8.c.
References PG_GETARG_INT16, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int28pl | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1156 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, pg_add_s64_overflow(), PG_GETARG_INT16, PG_GETARG_INT64, PG_RETURN_INT64, and unlikely.
Datum int48 | ( | PG_FUNCTION_ARGS | ) |
Datum int48div | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1056 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT32, PG_GETARG_INT64, PG_RETURN_INT64, PG_RETURN_NULL, and unlikely.
Datum int48eq | ( | PG_FUNCTION_ARGS | ) |
Definition at line 313 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int48ge | ( | PG_FUNCTION_ARGS | ) |
Definition at line 358 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int48gt | ( | PG_FUNCTION_ARGS | ) |
Definition at line 340 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int48le | ( | PG_FUNCTION_ARGS | ) |
Definition at line 349 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int48lt | ( | PG_FUNCTION_ARGS | ) |
Definition at line 331 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int48mi | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1028 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT32, PG_GETARG_INT64, PG_RETURN_INT64, pg_sub_s64_overflow(), and unlikely.
Datum int48mul | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1042 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT32, PG_GETARG_INT64, pg_mul_s64_overflow(), PG_RETURN_INT64, and unlikely.
Datum int48ne | ( | PG_FUNCTION_ARGS | ) |
Definition at line 322 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int48pl | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1014 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, pg_add_s64_overflow(), PG_GETARG_INT32, PG_GETARG_INT64, PG_RETURN_INT64, and unlikely.
Datum int82 | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1313 of file int8.c.
References arg, ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT64, PG_INT16_MAX, PG_INT16_MIN, PG_RETURN_INT16, and unlikely.
Datum int82div | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1117 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT16, PG_GETARG_INT64, PG_INT64_MIN, PG_RETURN_INT64, PG_RETURN_NULL, and unlikely.
Datum int82eq | ( | PG_FUNCTION_ARGS | ) |
Definition at line 370 of file int8.c.
References PG_GETARG_INT16, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int82ge | ( | PG_FUNCTION_ARGS | ) |
Definition at line 415 of file int8.c.
References PG_GETARG_INT16, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int82gt | ( | PG_FUNCTION_ARGS | ) |
Definition at line 397 of file int8.c.
References PG_GETARG_INT16, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int82le | ( | PG_FUNCTION_ARGS | ) |
Definition at line 406 of file int8.c.
References PG_GETARG_INT16, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int82lt | ( | PG_FUNCTION_ARGS | ) |
Definition at line 388 of file int8.c.
References PG_GETARG_INT16, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int82mi | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1089 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT16, PG_GETARG_INT64, PG_RETURN_INT64, pg_sub_s64_overflow(), and unlikely.
Datum int82mul | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1103 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT16, PG_GETARG_INT64, pg_mul_s64_overflow(), PG_RETURN_INT64, and unlikely.
Datum int82ne | ( | PG_FUNCTION_ARGS | ) |
Definition at line 379 of file int8.c.
References PG_GETARG_INT16, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int82pl | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1075 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, pg_add_s64_overflow(), PG_GETARG_INT16, PG_GETARG_INT64, PG_RETURN_INT64, and unlikely.
Datum int84 | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1292 of file int8.c.
References arg, ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT64, PG_INT32_MAX, PG_INT32_MIN, PG_RETURN_INT32, and unlikely.
Referenced by int8_to_char().
Datum int84div | ( | PG_FUNCTION_ARGS | ) |
Definition at line 975 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT32, PG_GETARG_INT64, PG_INT64_MIN, PG_RETURN_INT64, PG_RETURN_NULL, and unlikely.
Datum int84eq | ( | PG_FUNCTION_ARGS | ) |
Definition at line 256 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int84ge | ( | PG_FUNCTION_ARGS | ) |
Definition at line 301 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int84gt | ( | PG_FUNCTION_ARGS | ) |
Definition at line 283 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int84le | ( | PG_FUNCTION_ARGS | ) |
Definition at line 292 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int84lt | ( | PG_FUNCTION_ARGS | ) |
Definition at line 274 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int84mi | ( | PG_FUNCTION_ARGS | ) |
Definition at line 947 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT32, PG_GETARG_INT64, PG_RETURN_INT64, pg_sub_s64_overflow(), and unlikely.
Datum int84mul | ( | PG_FUNCTION_ARGS | ) |
Definition at line 961 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT32, PG_GETARG_INT64, pg_mul_s64_overflow(), PG_RETURN_INT64, and unlikely.
Datum int84ne | ( | PG_FUNCTION_ARGS | ) |
Definition at line 265 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_BOOL.
Datum int84pl | ( | PG_FUNCTION_ARGS | ) |
Definition at line 933 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, pg_add_s64_overflow(), PG_GETARG_INT32, PG_GETARG_INT64, PG_RETURN_INT64, and unlikely.
Datum int8abs | ( | PG_FUNCTION_ARGS | ) |
Definition at line 632 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT64, PG_INT64_MIN, PG_RETURN_INT64, and unlikely.
Datum int8and | ( | PG_FUNCTION_ARGS | ) |
Datum int8dec | ( | PG_FUNCTION_ARGS | ) |
Definition at line 843 of file int8.c.
References AggCheckCallContext(), arg, ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT64, PG_GETARG_POINTER, PG_RETURN_INT64, PG_RETURN_POINTER, pg_sub_s64_overflow(), and unlikely.
Referenced by int8dec_any().
Datum int8dec_any | ( | PG_FUNCTION_ARGS | ) |
Datum int8div | ( | PG_FUNCTION_ARGS | ) |
Definition at line 590 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT64, PG_INT64_MIN, PG_RETURN_INT64, PG_RETURN_NULL, and unlikely.
Datum int8eq | ( | PG_FUNCTION_ARGS | ) |
Datum int8gcd | ( | PG_FUNCTION_ARGS | ) |
Definition at line 753 of file int8.c.
References int8gcd_internal(), PG_GETARG_INT64, and PG_RETURN_INT64.
|
static |
Datum int8ge | ( | PG_FUNCTION_ARGS | ) |
Datum int8gt | ( | PG_FUNCTION_ARGS | ) |
Datum int8in | ( | PG_FUNCTION_ARGS | ) |
Definition at line 134 of file int8.c.
References PG_GETARG_CSTRING, PG_RETURN_INT64, scanint8(), and generate_unaccent_rules::str.
Referenced by defGetInt64().
Datum int8inc | ( | PG_FUNCTION_ARGS | ) |
Definition at line 805 of file int8.c.
References AggCheckCallContext(), arg, ereport, errcode(), errmsg(), ERROR, pg_add_s64_overflow(), PG_GETARG_INT64, PG_GETARG_POINTER, PG_RETURN_INT64, PG_RETURN_POINTER, and unlikely.
Referenced by int8inc_any(), and int8inc_float8_float8().
Datum int8inc_any | ( | PG_FUNCTION_ARGS | ) |
Datum int8inc_float8_float8 | ( | PG_FUNCTION_ARGS | ) |
Datum int8larger | ( | PG_FUNCTION_ARGS | ) |
Datum int8lcm | ( | PG_FUNCTION_ARGS | ) |
Definition at line 768 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, gcd(), int8gcd_internal(), PG_GETARG_INT64, PG_INT64_MIN, pg_mul_s64_overflow(), PG_RETURN_INT64, and unlikely.
Datum int8le | ( | PG_FUNCTION_ARGS | ) |
Datum int8lt | ( | PG_FUNCTION_ARGS | ) |
Datum int8mi | ( | PG_FUNCTION_ARGS | ) |
Definition at line 562 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT64, PG_RETURN_INT64, pg_sub_s64_overflow(), and unlikely.
Datum int8mod | ( | PG_FUNCTION_ARGS | ) |
Definition at line 649 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT64, PG_RETURN_INT64, PG_RETURN_NULL, and unlikely.
Datum int8mul | ( | PG_FUNCTION_ARGS | ) |
Definition at line 576 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT64, pg_mul_s64_overflow(), PG_RETURN_INT64, and unlikely.
Referenced by int4_cash(), int8_cash(), and int8_to_char().
Datum int8ne | ( | PG_FUNCTION_ARGS | ) |
Datum int8not | ( | PG_FUNCTION_ARGS | ) |
Datum int8or | ( | PG_FUNCTION_ARGS | ) |
Datum int8out | ( | PG_FUNCTION_ARGS | ) |
Definition at line 147 of file int8.c.
References buf, MAXINT8LEN, palloc(), PG_GETARG_INT64, pg_lltoa(), PG_RETURN_CSTRING, and val.
Referenced by int8_to_char().
Datum int8pl | ( | PG_FUNCTION_ARGS | ) |
Definition at line 548 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, pg_add_s64_overflow(), PG_GETARG_INT64, PG_RETURN_INT64, and unlikely.
Referenced by int8range_canonical().
Datum int8recv | ( | PG_FUNCTION_ARGS | ) |
Definition at line 169 of file int8.c.
References buf, PG_GETARG_POINTER, PG_RETURN_INT64, and pq_getmsgint64().
Datum int8send | ( | PG_FUNCTION_ARGS | ) |
Definition at line 180 of file int8.c.
References buf, PG_GETARG_INT64, PG_RETURN_BYTEA_P, pq_begintypsend(), pq_endtypsend(), and pq_sendint64().
Datum int8shl | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1262 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_INT64.
Datum int8shr | ( | PG_FUNCTION_ARGS | ) |
Definition at line 1271 of file int8.c.
References PG_GETARG_INT32, PG_GETARG_INT64, and PG_RETURN_INT64.
Datum int8smaller | ( | PG_FUNCTION_ARGS | ) |
Datum int8um | ( | PG_FUNCTION_ARGS | ) |
Definition at line 526 of file int8.c.
References arg, ereport, errcode(), errmsg(), ERROR, PG_GETARG_INT64, PG_INT64_MIN, PG_RETURN_INT64, and unlikely.
Datum int8up | ( | PG_FUNCTION_ARGS | ) |
Datum int8xor | ( | PG_FUNCTION_ARGS | ) |
Datum oidtoi8 | ( | PG_FUNCTION_ARGS | ) |
Definition at line 55 of file int8.c.
References ereport, errcode(), errmsg(), ERROR, PG_INT64_MIN, pg_mul_s64_overflow(), pg_sub_s64_overflow(), generate_unaccent_rules::str, and unlikely.
Referenced by int8in(), make_const(), and parse_output_parameters().