Hello,

I'm new to sqlite and I'm using it in my MFC program.  I compiled the sqlite
lib myself.  I'm using in-memory DB.  My program has two threads, say thread
A and B.  Thread A is the producer, which inserts rows inside a table named
'master'.  Thread B is a consumer, which selects and updates rows from the
table 'master'.  The SCUD operations are embedded into a singleton, which is
responsible for critical section locks.  The master table has a primary key
composed of two columns, one is integer type and the other is string type.

What confuses me is a strange phoenomenon.  The first 30 seconds thread A
can insert 6000 rows, and the next 30 seconds another 2000, and next 30
seconds 1900, 1800, ... steadily decaying.  Meanwhile thread B keeps the
same pace to make 2 updates per 30 seconds.  I've tried to tune the
MAX_PAGES to 1048576 and MAX_BYTES_PER_ROW to 17646.  It helps boosting up
some performance but the phoenomenon of decaying is still there.

I have a rival program which has same functionality but it's written in MDAC
(I can't use MDAC for some reasons).  The first 30 seconds 8500 rows are
inserted, and the next is 17000 rows, 26500, ..., almost linear.

Where should I look into to tune my SQLite compilation in order that I can
match the MDAC version performance?  Any cent is much appreciated.

TIA,

Arthur



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to