Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
From: "Wes Bauske" <wsb@paralleldata.com>
To: axp-list@redhat.com
Subject: Re: Performance again
Date: Sun, 03 Jan 1999 21:45:12 +0000	[thread overview]
Message-ID: <368FE4E8.9F66FAE6@paralleldata.com> (raw)
In-Reply-To: Pine.LNX.4.04.9901031537320.15758-200000@hjs.goth.net

Herwin Jan Steehouwer wrote:
> 
> oops, i forgot the source :
> 

Herwin,

I ran your test on my 533 PC164LX but the loop was
optimized out of the code. All tests, i/f/d were
0.03 seconds WCT. So, you need a little change
to the test t make the compiler run the loops.

Just print out the last value of val1 in your
print statements. This forces the compiler to
really calculate the loop. I got the following 
results with that change:


[wsb@wsb5 home]$ time preftest d
double val1=2 
0.24user 0.00system 0:00.25elapsed 98%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (68major+13minor)pagefaults 0swaps
[wsb@wsb5 home]$ time preftest i
mixed int val1=2.000000
2.01user 0.00system 0:02.02elapsed 99%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (68major+13minor)pagefaults 0swaps
[wsb@wsb5 home]$ time preftest f
float val1=2.000000 
0.18user 0.00system 0:00.18elapsed 98%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (68major+13minor)pagefaults 0swaps

Also, I used gcc -O2 : 

gcc version egcs-2.90.29 980515 (egcs-1.0.3 release)

Watch out though how you use the results. This test is
way too simple to represent a real application. Most
likely almost all the work was moved out of the loop
because it doesn't vary from iteration to iteration.


Wes


  reply	other threads:[~1999-01-03 20:58 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-01-03  8:59 Accessing Serial Port on Noname MB (AXPXI33) under RH 5.1 Ron
1999-01-03 11:21 ` Performance again Herwin Jan Steehouwer
1999-01-03 13:23   ` geerten kuiper
1999-01-03 14:36     ` Herwin Jan Steehouwer
1999-01-03 20:22       ` Ed Hall
1999-01-04  4:49       ` Joseph Curtis
1999-01-03 14:37     ` Herwin Jan Steehouwer
1999-01-03 21:45       ` Wes Bauske [this message]
1999-01-03 22:06   ` warp
1999-01-03 22:35     ` warp
1999-01-03 13:35 ` Accessing Serial Port on Noname MB (AXPXI33) under RH 5.1 Kari Davidsson
1999-01-03 17:07   ` (Help) " Ron
1999-01-03 20:32     ` (Help) Accessing Serial Port on Noname MB (AXPXI33) under RH Matthew Geier
1999-01-03 21:47     ` (Help) Accessing Serial Port on Noname MB (AXPXI33) under RH 5.1 Wes Bauske
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox