Re: [sqlite] Strange execution times

2006-02-23 Thread John Stanton
Ulrich, all improvements in knowledge start with curiosity, our most precious asset. JS Ulrich Schöbel wrote: Hi John, there isn't really much to remove, but nevertheless I followed your advice and replaced the sqlite select by a small standard tcl procedure. Maybe that set me on the right

Re: [sqlite] Strange execution times

2006-02-22 Thread Ulrich Schöbel
Hi John, there isn't really much to remove, but nevertheless I followed your advice and replaced the sqlite select by a small standard tcl procedure. Maybe that set me on the right track. There were also some exceptionally high execution times in between, but not in every test run and not always

Re: [sqlite] Strange execution times

2006-02-22 Thread John Stanton
Ulrich, try designing an experiment which removes SQLITE and measures the performance of the other software layers. That might resolve your dilemma. JS Ulrich Schöbel wrote: Hi Richard, thanks for trying to reproduce my 'problem'. I'm using Linux 2.6.12 (Ubuntu Breezy Badger, a debian

Re: [sqlite] Strange execution times

2006-02-22 Thread Dennis Jenkins
Ulrich Schöbel wrote: > Hi Richard, > > thanks for trying to reproduce my 'problem'. > > I'm using Linux 2.6.12 (Ubuntu Breezy Badger, a debian distro), > Tcl/Tk 8.4.12, sqlite 3.3.4, all pretty recent versions. > > I made the same tests today with the same results. > > Nevertheless, sqlite is by

Re: [sqlite] Strange execution times

2006-02-22 Thread Jose Da Silva
On February 22, 2006 05:59 am, Adrian Ho wrote: > On Wed, Feb 22, 2006 at 11:11:45AM +0200, Ulrich Sch?bel wrote: > > I tried your script and got, after a slight modification, quite > > consistent results. When I tried it as is, I got slightly varying > > time results with a peak in the 50 to 100

Re: [sqlite] Strange execution times

2006-02-22 Thread Ulrich Schöbel
On Wednesday 22 February 2006 15:59, Adrian Ho wrote: > > Do you come to similar results? > > Nope, mine were a lot more consistent (Centrino 1.6GHz laptop, 512MB RAM): > > t(1)=254 microseconds per iteration > t(5)=186.6 microseconds per iteration > t(10)=156.1 microseconds per iteration >

Re: [sqlite] Strange execution times

2006-02-22 Thread Adrian Ho
On Wed, Feb 22, 2006 at 11:11:45AM +0200, Ulrich Sch?bel wrote: > I tried your script and got, after a slight modification, quite > consistent results. When I tried it as is, I got slightly varying > time results with a peak in the 50 to 100 region. Then I > commented out all lines concerning the

Re: [sqlite] Strange execution times

2006-02-22 Thread Ulrich Schöbel
Hi Richard, thanks for trying to reproduce my 'problem'. I'm using Linux 2.6.12 (Ubuntu Breezy Badger, a debian distro), Tcl/Tk 8.4.12, sqlite 3.3.4, all pretty recent versions. I made the same tests today with the same results. Nevertheless, sqlite is by far faster than mySQL, so I'm going to

Re: [sqlite] Strange execution times

2006-02-22 Thread drh
Ulrich =?iso-8859-1?q?Sch=F6bel?= <[EMAIL PROTECTED]> wrote: > > % time {db eval {select * from cust_persons where first_name='Ulrich'}} 1000 > 75.498 microseconds per iteration > % time {db eval {select * from cust_persons where first_name='Ulrich'}} 1 > 51.6179 microseconds per iteration >

Re: [sqlite] Strange execution times

2006-02-22 Thread Ulrich Schöbel
Hi Ran, no, sorry. It's running on a normal Linux PC, runnning 24/7. No laptop, no stepping up. Time calculation is probably a bit less accurate in the lower regions, but not that much. It's really a mind boggler. Thanks and kind regards Ulrich On Wednesday 22 February 2006 11:27, Ran wrote:

Re: [sqlite] Strange execution times

2006-02-22 Thread Ran
Could it be connected to the stepping up of the CPU? Do you run those tests on a laptop? This at least could explain how the many iterations are faster (the CPU has time to step up). It does not explain why the 10 and 5 are fast as well (maybe when doing few iterations, the time calculation is

Re: [sqlite] Strange execution times

2006-02-22 Thread Ulrich Schöbel
Hi Adrian, I tried your script and got, after a slight modification, quite consistent results. When I tried it as is, I got slightly varying time results with a peak in the 50 to 100 region. Then I commented out all lines concerning the deletion, creation and filling to get the pure retrieval

Re: [sqlite] Strange execution times

2006-02-21 Thread Adrian Ho
On Wed, Feb 22, 2006 at 01:13:19AM +0200, Ulrich Sch??bel wrote: > I don't think it's an interface problem. I'm using Tcl, more or less > the 'natural' language for sqlite. Tcl doesn't have a garbage > collection. Tcl certainly *does* have garbage collection:

Re: [sqlite] Strange execution times

2006-02-21 Thread Ulrich Schöbel
Hi Nathaniel, even if it is not absolutely accurate, a factor of about 5 is beyond accuracy tolerances. Kind regards Ulrich On Wednesday 22 February 2006 01:38, Nathaniel Smith wrote: > On Wed, Feb 22, 2006 at 01:13:19AM +0200, Ulrich Schöbel wrote: > > I tried the 10 reps expecting even more.

Re: [sqlite] Strange execution times

2006-02-21 Thread Nathaniel Smith
On Wed, Feb 22, 2006 at 01:13:19AM +0200, Ulrich Schöbel wrote: > I tried the 10 reps expecting even more. Then came the surprise: > only 67 microsecs. > > My first feeling was, something like a busy disk or so came > in just when I tried the 100 reps. But the results were reproducible, >

Re: [sqlite] Strange execution times

2006-02-21 Thread Ulrich Schöbel
Hi Thomas, no, I can't reproduce it in C. The problem is not worth the effort, I can live with these timings, it's just strange. I don't think it's an interface problem. I'm using Tcl, more or less the 'natural' language for sqlite. Tcl doesn't have a garbage collection. The strangest thing is,

Re: [sqlite] Strange execution times

2006-02-21 Thread drh
Ulrich =?iso-8859-1?q?Sch=F6bel?= <[EMAIL PROTECTED]> wrote: > > % time {db eval {select * from cust_persons where first_name='Ulrich'}} 1000 > 75.498 microseconds per iteration > % time {db eval {select * from cust_persons where first_name='Ulrich'}} 1 > 51.6179 microseconds per iteration >

Re: [sqlite] Strange execution times

2006-02-21 Thread Thomas Chust
On Tue, 21 Feb 2006, UlrichSchöbel wrote: [...] Where do those 309.95 microseconds come from? What's the difference between running a query 100 times or 1 times? Should I avoid running a select exactly 100 times for some obscure reason? [...] Hello, can you reproduce similar timings in

[sqlite] Strange execution times

2006-02-21 Thread Ulrich Schöbel
Hi all, I just made my first steps into sqlite (3.3.4). I created a small table, filled it with two rows of data and timed a select. Those were the results: % time {db eval {select * from cust_persons where first_name='Ulrich'}} 1000 75.498 microseconds per iteration % time {db eval {select *