1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-07 02:42:48 +03:00

When reusing pages as part of creating a new index, allocate the leaves from each free-list trunk page in ascending order, instead of trying to maximize localization for each individual allocation. This increases the chance that pages will be written to disk in ascending order by a large CREATE INDEX statement, improving overall performance.

FossilOrigin-Name: d045f8b2d44e388d8c4549ff02d4ca7eff4e2038
This commit is contained in:
dan
2012-08-06 18:50:11 +00:00
parent 8c5287ec73
commit 428c218c90
11 changed files with 125 additions and 25 deletions

View File

@@ -361,7 +361,8 @@ static int tvfsWrite(
if( p->pScript && p->mask&TESTVFS_WRITE_MASK ){
tvfsExecTcl(p, "xWrite",
Tcl_NewStringObj(pFd->zFilename, -1), pFd->pShmId, 0
Tcl_NewStringObj(pFd->zFilename, -1), pFd->pShmId,
Tcl_NewWideIntObj(iOfst)
);
tvfsResultCode(p, &rc);
}