/ Check-in [bb5d7782]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Record when an allocated page is taken from the freelist trunk.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | experimentalIoLog
Files: files | file ages | folders
SHA1: bb5d7782bdc73748e54d202ddd7b082c6ee58ebf
User & Date: drh 2015-08-10 20:53:22
Context
2015-08-11
01:45
Two more places where logging of freelist trunk pages is needed. check-in: 56ff336e user: drh tags: experimentalIoLog
2015-08-10
20:53
Record when an allocated page is taken from the freelist trunk. check-in: bb5d7782 user: drh tags: experimentalIoLog
20:22
Add the sqlite3_experimental_log_open() interface. This is for diagnostic use only and is not intended to ever go on trunk. check-in: ac5d2e9d user: drh tags: experimentalIoLog
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/btree.c.

5561
5562
5563
5564
5565
5566
5567



5568
5569
5570
5571
5572
5573
5574
        if( rc ){
          goto end_allocate_page;
        }
        *pPgno = iTrunk;
        memcpy(&pPage1->aData[32], &pTrunk->aData[0], 4);
        *ppPage = pTrunk;
        pTrunk = 0;



        TRACE(("ALLOCATE: %d trunk - %d free pages left\n", *pPgno, n-1));
      }else if( k>(u32)(pBt->usableSize/4 - 2) ){
        /* Value of k is out of range.  Database corruption */
        rc = SQLITE_CORRUPT_BKPT;
        goto end_allocate_page;
#ifndef SQLITE_OMIT_AUTOVACUUM
      }else if( searchList 







>
>
>







5561
5562
5563
5564
5565
5566
5567
5568
5569
5570
5571
5572
5573
5574
5575
5576
5577
        if( rc ){
          goto end_allocate_page;
        }
        *pPgno = iTrunk;
        memcpy(&pPage1->aData[32], &pTrunk->aData[0], 4);
        *ppPage = pTrunk;
        pTrunk = 0;
        if( pBt->pLog ){
          sqlite3ExperimentalLog(pBt->pLog, "freelist-trunk-alloc %d", iTrunk);
        }
        TRACE(("ALLOCATE: %d trunk - %d free pages left\n", *pPgno, n-1));
      }else if( k>(u32)(pBt->usableSize/4 - 2) ){
        /* Value of k is out of range.  Database corruption */
        rc = SQLITE_CORRUPT_BKPT;
        goto end_allocate_page;
#ifndef SQLITE_OMIT_AUTOVACUUM
      }else if( searchList