[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: More on interpreter speed

From: Tom Holroyd (NIH/NIMH) [E]
Subject: Re: More on interpreter speed
Date: Wed, 04 Oct 2006 15:58:42 -0400
User-agent: Mozilla Thunderbird 1.0.7-1.1.fc3 (X11/20050929)

It's also worth pointing out that cputime is more accurate, and that if you use 
the form

        [t, u, s] = cputime();

then you can distinguish between time spent in the OS (s) and time spent in 
Octave (u).
Might be useful to do that here.

John W. Eaton wrote:
On  4-Oct-2006, Quentin Spencer wrote:

| This may be of interest to those who have recently expressed interest in | finding ways of speeding up the interpreter. I was recently testing two | different ways of computing the same vector inside a function to see | which was fastest. My code was organized in the form: | | tic
|   block A
| toc
| tic
|   block B
| toc
| | where blocks A and B compute the same thing in different ways, but using | some (not all) of the same intermediate variables. I was consistently | getting results that looked like this:
| Elapsed time is 0.025230 seconds.
| Elapsed time is 0.001198 seconds.

This could just be a bug.  Can you post a complete example that
demonstrates the problem?


Tom Holroyd, Ph.D.
We experience the world not as it is, but as we expect it to be.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]