Hi all, I add some debug information in sqlite3.c, and test Sqlite cache metch times, unmetch times and read() called times in Linux, I found that page unmetch times in cache is bigger than read() called times.
Then I found in Btree.c getAndInitPage() function called sqlite3PageLookup, and sqlite3PageLookup() called sqlite3PcacheFetch() which do the cache search. If the page is not in cache, getAndInitPage() will call sqlite3BtreeGetPage() to get a page, in sqlite3BtreeGetPage() will call sqlite3PagerAcquire(), in sqlite3PagerAcquire(), it also call sqlite3PcacheFetch() to do a cache search. My English is not very well, in a word, in getAndInitPage() function, if a page it want to get is not in Sqlite cache, it will do 2 times search in cache, Is it reasonable? or something I did wrong? Thanks very much! yang _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users