mem0 17779 third_party/sqlite/amalgamation/sqlite3.c } mem0 = { 0, 0, 0, 0, 0, 0, 0, 0 }; mem0 17781 third_party/sqlite/amalgamation/sqlite3.c #define mem0 GLOBAL(struct Mem0Global, mem0) mem0 17806 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_enter(mem0.mutex); mem0 17807 third_party/sqlite/amalgamation/sqlite3.c mem0.alarmCallback = xCallback; mem0 17808 third_party/sqlite/amalgamation/sqlite3.c mem0.alarmArg = pArg; mem0 17809 third_party/sqlite/amalgamation/sqlite3.c mem0.alarmThreshold = iThreshold; mem0 17811 third_party/sqlite/amalgamation/sqlite3.c mem0.nearlyFull = (iThreshold>0 && iThreshold<=nUsed); mem0 17812 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_leave(mem0.mutex); mem0 17840 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_enter(mem0.mutex); mem0 17841 third_party/sqlite/amalgamation/sqlite3.c priorLimit = mem0.alarmThreshold; mem0 17842 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_leave(mem0.mutex); mem0 17865 third_party/sqlite/amalgamation/sqlite3.c memset(&mem0, 0, sizeof(mem0)); mem0 17867 third_party/sqlite/amalgamation/sqlite3.c mem0.mutex = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MEM); mem0 17877 third_party/sqlite/amalgamation/sqlite3.c mem0.pScratchFree = pSlot; mem0 17878 third_party/sqlite/amalgamation/sqlite3.c mem0.nScratchFree = n; mem0 17884 third_party/sqlite/amalgamation/sqlite3.c mem0.pScratchEnd = (void*)&pSlot[1]; mem0 17886 third_party/sqlite/amalgamation/sqlite3.c mem0.pScratchEnd = 0; mem0 17906 third_party/sqlite/amalgamation/sqlite3.c return mem0.nearlyFull; mem0 17916 third_party/sqlite/amalgamation/sqlite3.c memset(&mem0, 0, sizeof(mem0)); mem0 17950 third_party/sqlite/amalgamation/sqlite3.c if( mem0.alarmCallback==0 ) return; mem0 17951 third_party/sqlite/amalgamation/sqlite3.c xCallback = mem0.alarmCallback; mem0 17953 third_party/sqlite/amalgamation/sqlite3.c pArg = mem0.alarmArg; mem0 17954 third_party/sqlite/amalgamation/sqlite3.c mem0.alarmCallback = 0; mem0 17955 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_leave(mem0.mutex); mem0 17957 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_enter(mem0.mutex); mem0 17958 third_party/sqlite/amalgamation/sqlite3.c mem0.alarmCallback = xCallback; mem0 17959 third_party/sqlite/amalgamation/sqlite3.c mem0.alarmArg = pArg; mem0 17969 third_party/sqlite/amalgamation/sqlite3.c assert( sqlite3_mutex_held(mem0.mutex) ); mem0 17972 third_party/sqlite/amalgamation/sqlite3.c if( mem0.alarmCallback!=0 ){ mem0 17974 third_party/sqlite/amalgamation/sqlite3.c if( nUsed+nFull >= mem0.alarmThreshold ){ mem0 17975 third_party/sqlite/amalgamation/sqlite3.c mem0.nearlyFull = 1; mem0 17978 third_party/sqlite/amalgamation/sqlite3.c mem0.nearlyFull = 0; mem0 17983 third_party/sqlite/amalgamation/sqlite3.c if( p==0 && mem0.alarmCallback ){ mem0 18013 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_enter(mem0.mutex); mem0 18015 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_leave(mem0.mutex); mem0 18058 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_enter(mem0.mutex); mem0 18059 third_party/sqlite/amalgamation/sqlite3.c if( mem0.nScratchFree && sqlite3GlobalConfig.szScratch>=n ){ mem0 18060 third_party/sqlite/amalgamation/sqlite3.c p = mem0.pScratchFree; mem0 18061 third_party/sqlite/amalgamation/sqlite3.c mem0.pScratchFree = mem0.pScratchFree->pNext; mem0 18062 third_party/sqlite/amalgamation/sqlite3.c mem0.nScratchFree--; mem0 18065 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_leave(mem0.mutex); mem0 18071 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_leave(mem0.mutex); mem0 18073 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_leave(mem0.mutex); mem0 18078 third_party/sqlite/amalgamation/sqlite3.c assert( sqlite3_mutex_notheld(mem0.mutex) ); mem0 18104 third_party/sqlite/amalgamation/sqlite3.c if( p>=sqlite3GlobalConfig.pScratch && p<mem0.pScratchEnd ){ mem0 18108 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_enter(mem0.mutex); mem0 18109 third_party/sqlite/amalgamation/sqlite3.c pSlot->pNext = mem0.pScratchFree; mem0 18110 third_party/sqlite/amalgamation/sqlite3.c mem0.pScratchFree = pSlot; mem0 18111 third_party/sqlite/amalgamation/sqlite3.c mem0.nScratchFree++; mem0 18112 third_party/sqlite/amalgamation/sqlite3.c assert( mem0.nScratchFree <= (u32)sqlite3GlobalConfig.nScratch ); mem0 18114 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_leave(mem0.mutex); mem0 18122 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_enter(mem0.mutex); mem0 18127 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_leave(mem0.mutex); mem0 18175 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_enter(mem0.mutex); mem0 18179 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_leave(mem0.mutex); mem0 18236 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_enter(mem0.mutex); mem0 18239 third_party/sqlite/amalgamation/sqlite3.c mem0.alarmThreshold ){ mem0 18245 third_party/sqlite/amalgamation/sqlite3.c if( pNew==0 && mem0.alarmCallback ){ mem0 18253 third_party/sqlite/amalgamation/sqlite3.c sqlite3_mutex_leave(mem0.mutex); mem0 74 third_party/sqlite/src/src/malloc.c } mem0 = { 0, 0, 0, 0, 0, 0, 0, 0 }; mem0 76 third_party/sqlite/src/src/malloc.c #define mem0 GLOBAL(struct Mem0Global, mem0) mem0 101 third_party/sqlite/src/src/malloc.c sqlite3_mutex_enter(mem0.mutex); mem0 102 third_party/sqlite/src/src/malloc.c mem0.alarmCallback = xCallback; mem0 103 third_party/sqlite/src/src/malloc.c mem0.alarmArg = pArg; mem0 104 third_party/sqlite/src/src/malloc.c mem0.alarmThreshold = iThreshold; mem0 106 third_party/sqlite/src/src/malloc.c mem0.nearlyFull = (iThreshold>0 && iThreshold<=nUsed); mem0 107 third_party/sqlite/src/src/malloc.c sqlite3_mutex_leave(mem0.mutex); mem0 135 third_party/sqlite/src/src/malloc.c sqlite3_mutex_enter(mem0.mutex); mem0 136 third_party/sqlite/src/src/malloc.c priorLimit = mem0.alarmThreshold; mem0 137 third_party/sqlite/src/src/malloc.c sqlite3_mutex_leave(mem0.mutex); mem0 160 third_party/sqlite/src/src/malloc.c memset(&mem0, 0, sizeof(mem0)); mem0 162 third_party/sqlite/src/src/malloc.c mem0.mutex = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MEM); mem0 172 third_party/sqlite/src/src/malloc.c mem0.pScratchFree = pSlot; mem0 173 third_party/sqlite/src/src/malloc.c mem0.nScratchFree = n; mem0 179 third_party/sqlite/src/src/malloc.c mem0.pScratchEnd = (void*)&pSlot[1]; mem0 181 third_party/sqlite/src/src/malloc.c mem0.pScratchEnd = 0; mem0 201 third_party/sqlite/src/src/malloc.c return mem0.nearlyFull; mem0 211 third_party/sqlite/src/src/malloc.c memset(&mem0, 0, sizeof(mem0)); mem0 245 third_party/sqlite/src/src/malloc.c if( mem0.alarmCallback==0 ) return; mem0 246 third_party/sqlite/src/src/malloc.c xCallback = mem0.alarmCallback; mem0 248 third_party/sqlite/src/src/malloc.c pArg = mem0.alarmArg; mem0 249 third_party/sqlite/src/src/malloc.c mem0.alarmCallback = 0; mem0 250 third_party/sqlite/src/src/malloc.c sqlite3_mutex_leave(mem0.mutex); mem0 252 third_party/sqlite/src/src/malloc.c sqlite3_mutex_enter(mem0.mutex); mem0 253 third_party/sqlite/src/src/malloc.c mem0.alarmCallback = xCallback; mem0 254 third_party/sqlite/src/src/malloc.c mem0.alarmArg = pArg; mem0 264 third_party/sqlite/src/src/malloc.c assert( sqlite3_mutex_held(mem0.mutex) ); mem0 267 third_party/sqlite/src/src/malloc.c if( mem0.alarmCallback!=0 ){ mem0 269 third_party/sqlite/src/src/malloc.c if( nUsed+nFull >= mem0.alarmThreshold ){ mem0 270 third_party/sqlite/src/src/malloc.c mem0.nearlyFull = 1; mem0 273 third_party/sqlite/src/src/malloc.c mem0.nearlyFull = 0; mem0 278 third_party/sqlite/src/src/malloc.c if( p==0 && mem0.alarmCallback ){ mem0 308 third_party/sqlite/src/src/malloc.c sqlite3_mutex_enter(mem0.mutex); mem0 310 third_party/sqlite/src/src/malloc.c sqlite3_mutex_leave(mem0.mutex); mem0 353 third_party/sqlite/src/src/malloc.c sqlite3_mutex_enter(mem0.mutex); mem0 354 third_party/sqlite/src/src/malloc.c if( mem0.nScratchFree && sqlite3GlobalConfig.szScratch>=n ){ mem0 355 third_party/sqlite/src/src/malloc.c p = mem0.pScratchFree; mem0 356 third_party/sqlite/src/src/malloc.c mem0.pScratchFree = mem0.pScratchFree->pNext; mem0 357 third_party/sqlite/src/src/malloc.c mem0.nScratchFree--; mem0 360 third_party/sqlite/src/src/malloc.c sqlite3_mutex_leave(mem0.mutex); mem0 366 third_party/sqlite/src/src/malloc.c sqlite3_mutex_leave(mem0.mutex); mem0 368 third_party/sqlite/src/src/malloc.c sqlite3_mutex_leave(mem0.mutex); mem0 373 third_party/sqlite/src/src/malloc.c assert( sqlite3_mutex_notheld(mem0.mutex) ); mem0 399 third_party/sqlite/src/src/malloc.c if( p>=sqlite3GlobalConfig.pScratch && p<mem0.pScratchEnd ){ mem0 403 third_party/sqlite/src/src/malloc.c sqlite3_mutex_enter(mem0.mutex); mem0 404 third_party/sqlite/src/src/malloc.c pSlot->pNext = mem0.pScratchFree; mem0 405 third_party/sqlite/src/src/malloc.c mem0.pScratchFree = pSlot; mem0 406 third_party/sqlite/src/src/malloc.c mem0.nScratchFree++; mem0 407 third_party/sqlite/src/src/malloc.c assert( mem0.nScratchFree <= (u32)sqlite3GlobalConfig.nScratch ); mem0 409 third_party/sqlite/src/src/malloc.c sqlite3_mutex_leave(mem0.mutex); mem0 417 third_party/sqlite/src/src/malloc.c sqlite3_mutex_enter(mem0.mutex); mem0 422 third_party/sqlite/src/src/malloc.c sqlite3_mutex_leave(mem0.mutex); mem0 470 third_party/sqlite/src/src/malloc.c sqlite3_mutex_enter(mem0.mutex); mem0 474 third_party/sqlite/src/src/malloc.c sqlite3_mutex_leave(mem0.mutex); mem0 531 third_party/sqlite/src/src/malloc.c sqlite3_mutex_enter(mem0.mutex); mem0 534 third_party/sqlite/src/src/malloc.c mem0.alarmThreshold ){ mem0 540 third_party/sqlite/src/src/malloc.c if( pNew==0 && mem0.alarmCallback ){ mem0 548 third_party/sqlite/src/src/malloc.c sqlite3_mutex_leave(mem0.mutex);