On Fri, Sep 2, 2011 at 6:04 PM, Dan Kennedy <danielk1...@gmail.com> wrote: > On 09/02/2011 07:32 PM, Filip Navara wrote: >> >> On Fri, Sep 2, 2011 at 11:04 AM, Filip Navara<filip.nav...@gmail.com> >> wrote: >> *snip* >>> >>> The time to create an index on my 266 Mb experimental database is more >>> than 9 minutes. >> >> *snip* >> >> I erroneously measured the time with DEBUG build, so I've rerun the >> experiment with several SQLite versions: >> >> [2869ed2829] Leaf: Avoid using uninitialized variables after failures >> in the merge sort code. (user: drh, tags: trunk) >> CPU Time: user 107.359888 sys 135.050066 >> >> [7769fb988d] Instead of a temporary b-tree, use a linked-list and >> merge-sort to sort records in main memory in vdbesort.c. (user: dan, >> tags: merge-sort) >> CPU Time: user 118.451559 sys 132.117247 >> >> [71075673c6] Leaf: If all data being sorted fits in memory, avoid >> writing any data out to temporary files in vdbesort.c. (user: dan, >> tags: merge-sort) >> CPU Time: user 116.813549 sys 132.710051 > > Thanks for doing this. There is (hopefully) a fix for the performance > regression up now.
Thanks, it looks much better now: [68e26c4487] Leaf: The build works again with -DSQLITE_OMIT_MERGE_SORT. The merge-sorter now avoids spilling to disk (letting the in-memory linked list grow without bound) if PRAGMA temp_store=3. (user: drh, tags: merge-sort) CPU Time: user 86.486954 sys 132.273248 Best regards, Filip Navara _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users