summaryrefslogtreecommitdiff
path: root/external/public-domain/sqlite/man/sqlite3_mutex_held.3
blob: 116e6706d1b475b802a1cc1ec86bb463dbd2e3da (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
.Dd December 19, 2018
.Dt SQLITE3_MUTEX_HELD 3
.Os
.Sh NAME
.Nm sqlite3_mutex_held ,
.Nm sqlite3_mutex_notheld
.Nd Mutex Verification Routines
.Sh SYNOPSIS
.Ft int 
.Fo sqlite3_mutex_held
.Fa "sqlite3_mutex*"
.Fc
.Ft int 
.Fo sqlite3_mutex_notheld
.Fa "sqlite3_mutex*"
.Fc
.Sh DESCRIPTION
The sqlite3_mutex_held() and sqlite3_mutex_notheld() routines are intended
for use inside assert() statements.
The SQLite core never uses these routines except inside an assert()
and applications are advised to follow the lead of the core.
The SQLite core only provides implementations for these routines when
it is compiled with the SQLITE_DEBUG flag.
External mutex implementations are only required to provide these routines
if SQLITE_DEBUG is defined and if NDEBUG is not defined.
.Pp
These routines should return true if the mutex in their argument is
held or not held, respectively, by the calling thread.
.Pp
The implementation is not required to provide versions of these routines
that actually work.
If the implementation does not provide working versions of these routines,
it should at least provide stubs that always return true so that one
does not get spurious assertion failures.
.Pp
If the argument to sqlite3_mutex_held() is a NULL pointer then the
routine should return 1.
This seems counter-intuitive since clearly the mutex cannot be held
if it does not exist.
But the reason the mutex does not exist is because the build is not
using mutexes.
And we do not want the assert() containing the call to sqlite3_mutex_held()
to fail, so a non-zero return is the appropriate thing to do.
The sqlite3_mutex_notheld() interface should also return 1 when given
a NULL pointer.
r>2019-03-27- expose vmparams to userland on arm, like other archs do.christos 2018-10-27Trailing whitespaceskrll 2017-02-13G/C VM_MAX_KERNEL_BUFskrll 2015-10-18pull in arm/arm32/param.hjmcneill 2015-06-20__USE_TOPDOWN_VMskrll 2015-06-02Back off MAXDSIZ to 1.5GB to avoid some virtual memory exhausted messages.matt 2015-05-28ARM systems are no longer small, increase MAXTSIZ/MAXDSIZ/MAXSSIZ.matt 2015-02-24Restore PAGER_MAP_DEFAULT_SIZE for ARMv4, they typically have only 256MBjoerg 2014-07-27More fixes as a step towards ARM_MMU_EXTENDED on RPI.skrll 2014-03-31For ARM_MMU_EXTENDED, a KERNEL_BASE >= 0x80000000 is ok but amatt 2014-02-26Revert previous - will fix userland with new sysctls for VM_MIN_ADDRESS/martin 2014-02-26Include param.h here - userland expects VM_* defines to work with justmartin 2014-02-26Use PAGE_SIZE instead of 1000matt 2014-02-21Remove unnecessary include of sys/simplelock.hskrll 2013-02-27Define PAGESHIFT using PGSHIFTmatt 2013-02-25Bump max text/data/stack sizes to more reasonable values.matt 2012-08-16Tweak max addresses a bit so that [r1, #off] can't overflow them.matt 2012-02-16expose stuff that crash needs to kmemuserchristos 2010-11-14Move struct vm_page_md definition from vmparam.h to pmap.h, becauseuebayasi 2009-03-06Remove SHMMAXPGS from all kernel configs. Dynamically compute thejoerg 2008-08-06Change pv_entries to use SLIST.matt 2008-04-27Merge kernel changes in matt-armv6 to HEAD.matt 2008-01-04Header cleanup.ad 2007-01-06From Scott Alan in http://mail-index.netbsd.org/port-arm/2006/07/26/0000.htmlchristos 2003-05-22Use virtual_avail and virtual_end to compute the size of the availablethorpej 2003-05-21Remove #ifdefs supporting the old pmap, switching fully to the new.thorpej 2003-05-04VM_{MIN,MAX}* are now the same for ARM32_PMAP_NEW with both new andthorpej 2003-05-03Don't expose KERNEL_TEXT_BASE outside of board-specific code. This givesthorpej 2003-05-02Don't need to reserve a page of space before KERNEL_BASE in thethorpej 2003-05-02Eliminate PTE_BASE and the PT-PT completely in the ARM32_PMAP_NEW case.thorpej 2003-04-18Add the generic arm32 bits of the new pmap, contributed by Wasabi Systems.scw 2003-04-02Use PAGE_SIZE rather than NBPG.thorpej 2002-12-10Use __LDPGSZ (which must be == USRTEXT) as the text address for a.outthorpej