* dgemm benchmarks for axp Linux and Dec Unix
@ 1998-03-09 22:44 Robert Williams
1998-03-11 13:57 ` Robert Williams
0 siblings, 1 reply; 7+ messages in thread
From: Robert Williams @ 1998-03-09 22:44 UTC (permalink / raw)
To: axp-list; +Cc: gamess-users
Quick comparison of three different dgemm
(double precision matrix-matrix multiply) packages
on Linux and Dec Unix. Matrices were 1012x1012.
The 625 MHz alpha is a Dec 8400 (21164A) running Dec Unix.
The 433 MHz machine is a PC164 (21164A) running Linux.
______________________________________________________________________________
MFlops -- CPU ---- OS -------- Compiler ----- BLAS
691. -- 625 MHz -- Dec Unix -- Dec ---------- Dec DXML dgemm
415. -- 625 MHz -- Dec Unix -- Dec ---------- Kazushige Goto's assembler
dgemm
415. -- 433 MHz -- Linux ----- egcs-980221 -- Kazushige Goto's assembler
dgemm
296. -- 433 MHz -- Linux ----- Dec ---------- Kazushige Goto's assembler
dgemm
27. -- 625 MHz -- Dec Unix -- Dec ---------- Public Domain dgemm
(netlib)
23. -- 433 MHz -- Dec Unix -- Dec ---------- Public Domain dgemm
(netlib)
24. -- 433 MHz -- Linux ----- egcs-980221 -- Public Domain dgemm
(netlib)
______________________________________________________________________________
I used the level 3 blas timing routine:
PROGRAM DB3TIM
* -- Written on 1-July-1988.
* Jeremy Du Croz and Mick Pont, NAG Central Office.
with N=M=K=1012. Only transa = transb = 'T' are show.
This program has some roundoff problems.
It was written in the days when a large matrix multiply
would take more than a few seconds, so timings are
in seconds. I haven't had a chance to fix that yet.
So, for example, there are two benchmarks at 415 MFlops,
due to this roundoff problem.
The assembler dgemm, written specifically for the
21164A, requires that matrix size
must be aligned (a multiple of four). It drops back
to a somewhat tuned c language routine running at
about half the speed of the assembler when the size
is not aligned. The assembler routine is specific
to the transa = transb = 'N' case. Cases requiring
a transpose use the tuned c routines.
The speed in Mflops varied significantly with the
size of the problem.
Generally, the assembler dgemm that was compiled with egcs
and run on the Linux machine appears to perform
significantly better than it does compiled
with Dec compilers and run under Linux
(compare 415 with 296). So it appears that
entirely native Linux/GNU code may be faster than
DEC's DXML, for which a direct comparison could
not be made here.
--
Bob Williams, http://bob.usuf2.usuhs.mil/
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: dgemm benchmarks for axp Linux and Dec Unix
1998-03-09 22:44 dgemm benchmarks for axp Linux and Dec Unix Robert Williams
@ 1998-03-11 13:57 ` Robert Williams
1998-03-11 18:21 ` GU: " Robert Williams
0 siblings, 1 reply; 7+ messages in thread
From: Robert Williams @ 1998-03-11 13:57 UTC (permalink / raw)
To: axp-list; +Cc: gamess-users
Robert Williams wrote:
>
> Quick comparison of three different dgemm
> ...
> I used the level 3 blas timing routine:
> PROGRAM DB3TIM
> * -- Written on 1-July-1988.
> This program has some roundoff problems.
I would like to retract these comparisons
I posted earlier until I've looked carefully
at the effects of the roundoff problems in
this old benchmarking code. Some preliminary
fixes have changed the results downward in a very
disconcerting way.
--
Bob Williams, http://bob.usuf2.usuhs.mil/
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: GU: Re: dgemm benchmarks for axp Linux and Dec Unix
1998-03-11 13:57 ` Robert Williams
@ 1998-03-11 18:21 ` Robert Williams
1998-03-11 19:22 ` Richard Henderson
0 siblings, 1 reply; 7+ messages in thread
From: Robert Williams @ 1998-03-11 18:21 UTC (permalink / raw)
To: gamess-users; +Cc: axp-list
Robert Williams wrote:
>
> Robert Williams wrote:
> >
> > Quick comparison of three different dgemm...
>
> I would like to retract these comparisons.
> ...Some preliminary
> fixes have changed the results downward in a very
> disconcerting way.
The numbers posted previously do appear to
be good within the significance imposed by
the roundoff problem. The slowdown I refer
to above appears to have been caused
by some unpredictable paging caused by a newer
(beta) version of the assembler dgemm.
The Fortran "time()" call is inadequate for
these tests. Matrix size must be large to
make a significantly long test, but paging
becomes a problem. I would like to continue
to use the Fortran benchmark code if possible,
since the context that most of us may be using
a fast dgemm in will probably (?) be Fortran.
Does anyone have a good idea about how
to time the dgemm call?
Here's what the original looks like:
S0 = DBLE ( TIME ( ) )
S1 = DBLE ( TIME ( ) )
CALL DGEMM( TRANSA, TRANSB, M, N, K, ALPHA, A, LDA, B, LDB,
$ BETA, C, LDC )
S2 = DBLE ( TIME ( ) )
TIMES= ( S2 - S1 ) - ( S1 - S0 )
RNOP = DBLE(2*M)*DBLE(N)*DBLE(K)
IF( TIMES.LE.0.0D0 )THEN
RESLTS( IMVAL, INVAL ) = 0.0D0
ELSE
RESLTS( IMVAL, INVAL ) = RNOP/( 1.0D6*TIMES)
etc...
--
Bob Williams, http://bob.usuf2.usuhs.mil/
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: GU: Re: dgemm benchmarks for axp Linux and Dec Unix
1998-03-11 18:21 ` GU: " Robert Williams
@ 1998-03-11 19:22 ` Richard Henderson
1998-03-13 20:00 ` Robert Williams
0 siblings, 1 reply; 7+ messages in thread
From: Richard Henderson @ 1998-03-11 19:22 UTC (permalink / raw)
To: axp-list; +Cc: gamess-users
On Wed, Mar 11, 1998 at 01:21:35PM -0500, Robert Williams wrote:
> The Fortran "time()" call is inadequate for these tests.
[...]
> Does anyone have a good idea about how
> to time the dgemm call?
G77 at least has an etime() that returns a double, that is the
number of virtual seconds elapsed. The fractional part is filled
in as available.
r~
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: dgemm benchmarks for axp Linux and Dec Unix
1998-03-11 19:22 ` Richard Henderson
@ 1998-03-13 20:00 ` Robert Williams
1998-03-16 19:09 ` Claus Denk
0 siblings, 1 reply; 7+ messages in thread
From: Robert Williams @ 1998-03-13 20:00 UTC (permalink / raw)
To: axp-list; +Cc: gamess-users
Here is an updated comparison of three different dgemm
(double precision matrix-matrix multiply) packages
on axp Linux and Dec Unix. A few problems in the benchmark
code have been fixed, particularly the roundoff
problem imposed by a 1 second resolution in the Fortran
time() call. This version implements the dtime(tarray)
call with a resolution of 1/60 second, good enough
for a five second test. The most notable
result of this fix is a lowering of the DEC DXML numbers.
Matrices are 1012x1012 for the
public domain (netlib) dgemm, and 3000x3000 for the assembler
dgemm.
Results for two versions of
Kazushige Goto's assembler dgemm code
are shown. This code is 15-30% faster
than DEC's own DXML dgemm for alligned problems.
It's remarkable.
Kazushige Goto's address: <goto@statabo.rim.or.jp>
The 625 MHz alpha is a 6 cpu Dec 8400 (21164A) running Dec Unix.
On chip: 8 Kbyte instruction cache, 8 Kbyte data cache, 96-Kbyte
write-back second level cache. On board: 4 Mbyte third level
cache for each cpu. Tests were run in the forground with
interactive priority while the machine was in full use running
lower priority batch jobs.
The 433 MHz machine is an Alpine Durango PC164 (21164A) running Linux.
On chip: same as for 8400. On board: 1 Mbyte third level cache.
This machine was otherwise quiescent during the tests.
------------------------------------------------------------------------------
Tests with maximum matrix dimension = 2048 and N=M=K=1012, average of 4
runs;
standard deviations were all about 2 MFlops.
______________________________________________________________________________
MFlops - CPU MHz -- OS --- Compilers ----- BLAS
657. --- 625 --- Dec Unix -- Dec -------- Kazushige Goto's fast dgemm
631. --- 625 --- Dec Unix -- Dec -------- Kazushige Goto's V.1 dgemm
575. --- 625 --- Dec Unix -- Dec -------- Dec DXML dgemm
460. --- 433 --- Linux ----- Dec -------- Kazushige Goto's fast dgemm
453. --- 433 --- Linux --- egcs-980221 -- Kazushige Goto's fast dgemm
407. --- 433 --- Linux --- egcs-980221 -- Kazushige Goto's V.1 dgemm
390. --- 433 --- Linux ----- Dec -------- Kazushige Goto's V.1 dgemm
27. --- 625 --- Dec Unix -- Dec -------- Public Domain dgemm (netlib)
23. --- 433 --- Dec Unix -- Dec -------- Public Domain dgemm (netlib)
24. --- 433 --- Linux --- egcs-980221 -- Public Domain dgemm (netlib)
______________________________________________________________________________
Tests with maximum matrix dimension = 2048 and N=M=K=2000, average of 3
runs;
standard deviations are in parenthesis.
______________________________________________________________________________
MFlops - CPU MHz -- OS --- Compilers ----- BLAS
706(5)-- 625 --- Dec Unix -- Dec -------- Kazushige Goto's fast dgemm
668(4)-- 625 --- Dec Unix -- Dec -------- Kazushige Goto's V.1 dgemm
548(7)-- 625 --- Dec Unix -- Dec -------- Dec DXML dgemm
456(5)-- 433 --- Linux ----- Dec -------- Kazushige Goto's fast dgemm
434(7)-- 433 --- Linux --- egcs-980221 -- Kazushige Goto's fast dgemm
429(1)-- 433 --- Linux ----- Dec -------- Kazushige Goto's V.1 dgemm
390(1)-- 433 --- Linux --- egcs-980221 -- Kazushige Goto's V.1 dgemm
------------------------------------------------------------------------------
Tests with maximum matrix dimension = 4000 and N=M=K=1012, average of 4
runs;
standard deviations are shown in parenthesis. Paging is a factor here
on the
PC164. Performance appears to be the same on the 8400 with N=M=2000.
______________________________________________________________________________
MF(std)- CPU MHz -- OS --- Compilers ----- BLAS
652(21)- 625 --- Dec Unix -- Dec -------- Kazushige Goto's fast dgemm
630(6)-- 625 --- Dec Unix -- Dec -------- Kazushige Goto's V.1 dgemm
531(11)- 625 --- Dec Unix -- Dec -------- Dec DXML dgemm
. --- 433 --- Linux ----- Dec -------- Kazushige Goto's fast dgemm
327(42)- 433 --- Linux --- egcs-980221 -- Kazushige Goto's fast dgemm
331(33)- 433 --- Linux --- egcs-980221 -- Kazushige Goto's V.1 dgemm
. --- 433 --- Linux ----- Dec -------- Kazushige Goto's V.1 dgemm
______________________________________________________________________________
>
I used a modified level 3 blas timing routine:
> PROGRAM DB3TIM
> * -- Written on 1-July-1988.
> * Jeremy Du Croz and Mick Pont, NAG Central Office.
changed to use the dtime(tarray) call, 13 March, 1998.
Only transa = transb = 'N' are show.
> The assembler dgemm, written specifically for the
> 21164A, requires that matrix size
> must be aligned (a multiple of four). It drops back
> to a somewhat tuned c language routine running at
> about half the speed of the assembler when the size
> is not aligned. The assembler routine is specific
> to the transa = transb = 'N' case. Cases requiring
> a transpose use the tuned c routines.
> The speed in Mflops varied significantly with the
> size of the problem.
--
Bob Williams, http://bob.usuf2.usuhs.mil/
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: dgemm benchmarks for axp Linux and Dec Unix
1998-03-13 20:00 ` Robert Williams
@ 1998-03-16 19:09 ` Claus Denk
1998-03-16 19:04 ` Robert Williams
0 siblings, 1 reply; 7+ messages in thread
From: Claus Denk @ 1998-03-16 19:09 UTC (permalink / raw)
To: axp-list
Robert Williams wrote:
>
> Here is an updated comparison of three different dgemm
> (double precision matrix-matrix multiply) packages
> on axp Linux and Dec Unix.
> .....
> .....
>
> MFlops - CPU MHz -- OS --- Compilers ----- BLAS
>
> 657. --- 625 --- Dec Unix -- Dec -------- Kazushige Goto's fast dgemm
> 631. --- 625 --- Dec Unix -- Dec -------- Kazushige Goto's V.1 dgemm
> 575. --- 625 --- Dec Unix -- Dec -------- Dec DXML dgemm
> 460. --- 433 --- Linux ----- Dec -------- Kazushige Goto's fast dgemm
> 453. --- 433 --- Linux --- egcs-980221 -- Kazushige Goto's fast dgemm
> 407. --- 433 --- Linux --- egcs-980221 -- Kazushige Goto's V.1 dgemm
> 390. --- 433 --- Linux ----- Dec -------- Kazushige Goto's V.1 dgemm
> 27. --- 625 --- Dec Unix -- Dec -------- Public Domain dgemm (netlib)
> 23. --- 433 --- Dec Unix -- Dec -------- Public Domain dgemm (netlib)
> 24. --- 433 --- Linux --- egcs-980221 -- Public Domain dgemm (netlib)
>
Are you shure about the last three values ? The netlib dgemm
performed with 27 Mflops when compiled with g77 on a 500 Mhz -Linux
box we use here. This compares fine with your 24 Mflops having in
mind the frequency difference. But when compiled under DU I get 115
Mflops for the same routine. Matrix sizes were different however (small
matrices 32x32 up to 128x128).
Where can one obtain the assembler version of K. Goto ?
regards, Claus
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: dgemm benchmarks for axp Linux and Dec Unix
1998-03-16 19:09 ` Claus Denk
@ 1998-03-16 19:04 ` Robert Williams
0 siblings, 0 replies; 7+ messages in thread
From: Robert Williams @ 1998-03-16 19:04 UTC (permalink / raw)
To: axp-list
Claus Denk wrote:
>
> Robert Williams wrote:
> > 657. --- 625 --- Dec Unix -- Dec -------- Kazushige Goto's fast dgemm
> > .....
> > 27. --- 625 --- Dec Unix -- Dec -------- Public Domain dgemm (netlib)
> > 23. --- 433 --- Dec Unix -- Dec -------- Public Domain dgemm (netlib)
> > 24. --- 433 --- Linux --- egcs-980221 -- Public Domain dgemm (netlib)
>
> Are you sure about the last three values ?...
> when compiled under DU I get 115
> Mflops for the same routine. Matrix sizes were different however (small
> matrices 32x32 up to 128x128).
Yes. I just recompiled on the DEC 8400 with DEC f77
again, and reproduced the 27 GFlops. I get much higher
numbers with a 100x100 matrix, but the dtime call
has a resolution of 1/60 sec, and at 625 MHz a 100x100
goes in less than 1/10 sec.
> Where can one obtain the assembler version of K. Goto ?
Kazushige Goto's address: <goto@statabo.rim.or.jp>
Kazushige, what is your policy for releasing and
distributing your code?
--
Bob Williams, http://bob.usuf2.usuhs.mil/
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~1998-03-16 19:04 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1998-03-09 22:44 dgemm benchmarks for axp Linux and Dec Unix Robert Williams
1998-03-11 13:57 ` Robert Williams
1998-03-11 18:21 ` GU: " Robert Williams
1998-03-11 19:22 ` Richard Henderson
1998-03-13 20:00 ` Robert Williams
1998-03-16 19:09 ` Claus Denk
1998-03-16 19:04 ` Robert Williams
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox