|
PostgreSQL Source Code git master
|
#include "postgres.h"#include "fmgr.h"#include "miscadmin.h"#include "storage/lwlock.h"#include "utils/builtins.h"#include "utils/wait_classes.h"
Go to the source code of this file.
Macros | |
| #define | STARTUP_TRANCHE_NAME "test_lwlock_tranches_startup" |
| #define | DYNAMIC_TRANCHE_NAME "test_lwlock_tranches_dynamic" |
| #define | NUM_STARTUP_TRANCHES (32) |
| #define | NUM_DYNAMIC_TRANCHES (256 - NUM_STARTUP_TRANCHES) |
| #define | GET_TRANCHE_NAME(a) GetLWLockIdentifier(PG_WAIT_LWLOCK, (a)) |
Variables | |
| PG_MODULE_MAGIC | |
| static shmem_request_hook_type | prev_shmem_request_hook |
| #define DYNAMIC_TRANCHE_NAME "test_lwlock_tranches_dynamic" |
Definition at line 25 of file test_lwlock_tranches.c.
| #define GET_TRANCHE_NAME | ( | a | ) | GetLWLockIdentifier(PG_WAIT_LWLOCK, (a)) |
Definition at line 30 of file test_lwlock_tranches.c.
| #define NUM_DYNAMIC_TRANCHES (256 - NUM_STARTUP_TRANCHES) |
Definition at line 28 of file test_lwlock_tranches.c.
| #define NUM_STARTUP_TRANCHES (32) |
Definition at line 27 of file test_lwlock_tranches.c.
| #define STARTUP_TRANCHE_NAME "test_lwlock_tranches_startup" |
Definition at line 24 of file test_lwlock_tranches.c.
| void _PG_init | ( | void | ) |
Definition at line 36 of file test_lwlock_tranches.c.
References prev_shmem_request_hook, shmem_request_hook, and test_lwlock_tranches_shmem_request().
| PG_FUNCTION_INFO_V1 | ( | test_lwlock_initialize | ) |
| PG_FUNCTION_INFO_V1 | ( | test_lwlock_tranche_creation | ) |
| PG_FUNCTION_INFO_V1 | ( | test_lwlock_tranche_lookup | ) |
| PG_FUNCTION_INFO_V1 | ( | test_lwlock_tranches | ) |
| Datum test_lwlock_initialize | ( | PG_FUNCTION_ARGS | ) |
Definition at line 115 of file test_lwlock_tranches.c.
References LWLockInitialize(), PG_GETARG_INT32, and PG_RETURN_VOID.
| Datum test_lwlock_tranche_creation | ( | PG_FUNCTION_ARGS | ) |
Definition at line 87 of file test_lwlock_tranches.c.
References LWLockNewTrancheId(), PG_ARGISNULL, PG_GETARG_DATUM, PG_RETURN_VOID, and TextDatumGetCString.
| Datum test_lwlock_tranche_lookup | ( | PG_FUNCTION_ARGS | ) |
Definition at line 101 of file test_lwlock_tranches.c.
References GetNamedLWLockTranche(), PG_GETARG_DATUM, PG_RETURN_VOID, and TextDatumGetCString.
| Datum test_lwlock_tranches | ( | PG_FUNCTION_ARGS | ) |
Definition at line 58 of file test_lwlock_tranches.c.
References DYNAMIC_TRANCHE_NAME, elog, ERROR, GET_TRANCHE_NAME, i, LWLockNewTrancheId(), LWTRANCHE_FIRST_USER_DEFINED, NUM_DYNAMIC_TRANCHES, NUM_STARTUP_TRANCHES, PG_RETURN_VOID, and STARTUP_TRANCHE_NAME.
|
static |
Definition at line 43 of file test_lwlock_tranches.c.
References i, NUM_STARTUP_TRANCHES, prev_shmem_request_hook, RequestNamedLWLockTranche(), and STARTUP_TRANCHE_NAME.
Referenced by _PG_init().
| PG_MODULE_MAGIC |
Definition at line 22 of file test_lwlock_tranches.c.
|
static |
Definition at line 32 of file test_lwlock_tranches.c.
Referenced by _PG_init(), and test_lwlock_tranches_shmem_request().