cino hilliard on Tue, 04 Apr 2006 23:09:28 +0200

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

Re: elapsed time and system command

Hi Joerg,

From: Joerg Arndt <>
Subject: Re: elapsed time and system command
Date: Tue, 4 Apr 2006 11:16:02 +0200

You now have compile-time workaround, so everything should be fine.

You can always measure wall-clock time with /usr/bin/time
You do (at least, also) want to know how many cycles where eaten.

We might introduce a time format string that
gives the possibility to see it all.
As in

% /usr/bin/time find
 0.03user 0.14system 0:11.55elapsed 1%CPU

Then we have it all.

default(timeformat," %Uuser %Ssystem %Eelapsed %C%%CPU") <--= suggestion
which at the moment would be
default(timeformat,"time = %U ")
as in
? factor(2^239-1)
time = 23 ms.
Thanks for your effort to help.

I am using the windiows binary in xp pro.
(11:11) gp > \v
                   GP/PARI CALCULATOR Version 2.2.12 (beta)
               i686 running cygwin (ix86 kernel) 32-bit version
              compiled: Jan  3 2006, gcc-3.4.1 (cygming special)
               (readline v5.0 enabled, extended help available)

I could not implement the above.

I changed my .gprc to
prompt = "(%T)  gp > "
By using the arrow keys and return to retrieve the last input quickly with practice you can get a
good timeing.

(11:15:42) gp > g(n) = for(x=1,n,write("testtime1.txt","12345678901"))
(11:17:31) gp > g(100000)
(11:18:30) gp >
(11:18:46) gp > g(100000)
(11:19:36) gp >
The last two lines gives 50 sec as opposed to
(11:19:36:19S) gp > ##
 ***   last result computed in 11,360 ms.
This is awkward. I changed it back.
Back to the stop watch.

Thanks again,