On 23 Jun 2006, at 14:16, Dennis Cote wrote:

John Stanton wrote:
Cacheing will drive you crazy.

Very well put.

Most of SQLite's disk I/O is actually going to the memory used for the operating system's disk cache, not directly to the disk. Hence its speed is not much different when using a disk based database than a memory based database. I'm still a little surprised that a disk based database is actually slightly faster than a memory based one, but that just means that SQLite's memory based page I/O is less optimized than the OS's file I/O libraries.

I did some experiments along these lines a few months ago, and was similarly surprised. I got zero improvement running a database in memory compared to the on-disk version of the same database.

-Eric


Reply via email to