MATMUL - A Matrix Multiplication Benchmark
MATMUL is a program that carries out the matrix calculation
A*B = C.
It can do this for a variety of matrix sizes, and for different
arithmetics (real, complex, double precision, integer, even logical!)
There are a variety of algorithms available as well, including the
simple triple DO loop (actually not so simple; there are 6 ways to
set it up), some unrolling techniques, and the level 1 and 2 BLAS
routines.
Since the program is interactive, the user can easily pursue any
line of inquiry that seems promising. New algorithms or locally
available methods are not to hard to add.
Files you may copy include:
The list of routines includes:
-
MAIN is the main program for a matrix multiplication performance test.
-
CH_CAP capitalizes a single character.
-
C_MATMUL computes A = B*C using FORTRAN 90 MATMUL and complex arithmetic.
-
C_IJK computes A = B*C using index order IJK and complex arithmetic.
-
C_SET initializes the complex A, B and C matrices.
-
D_MATMUL computes A = B*C using FORTRAN 90 MATMUL and double precision arithmetic.
-
D_IJK multiplies A = B*C using index order IJK and double precision.
-
D_SET initializes the double precision A, B and C matrices.
-
DOMETHOD calls a specific multiplication routine.
-
GETN determines the problem sizes desired by the user.
-
GETSHO determines what items the user wishes to print out.
-
HEADER prints out a header for the results.
-
HELLO says hello to the user.
-
HELP prints a list of the available commands.
-
INIT initializes data.
-
I_MATMUL computes A = B*C using FORTRAN 90 MATMUL and integer arithmetic.
-
I_IJK multiplies A = B*C using index order IJK, using integer arithmetic.
-
I_IJK_46 multiplies A = B*C using index order IJK, and 46 bit integer arithmetic.
-
I_SET initializes the integer A, B and C matrices.
-
L_IJK "multiplies" A = B*C using index order IJK, using logical data.
-
L_SET initializes the logical A, B and C matrices.
-
MATMUL_CPU_TIMER computes total CPU seconds.
-
MATMUL_REAL_TIMER returns a reading of the real time clock.
-
MULT carries out the matrix multiplication, using the requested method.
-
NSTEP is used when a set of values of N is being generated.
-
ORDER_GET reads a new value of order from the user.
-
ORDER_LIST_PRINT prints the list of choices for the algorithm.
-
PRINTR prints out those parameters the user wants to see.
-
R_DOT_PRODUCT multiplies A = B*C using the FORTRAN90 DOT_PRODUCT function.
-
R_MATMUL computes A = B*C using FORTRAN 90 MATMUL and real arithmetic.
-
R_IJ multiplies A = B*C using index order IJ with implicit K.
-
R_IJK multiplies A = B*C using index order IJK.
-
R_IJK_M multiplies A = B*C using index order IJK.
-
R_IJK_S multiplies A = B*C using index order IJK, and no Cray vectorization.
-
R_IJK_I2 multiplies A = B*C using index order IJK and unrolling I 2 times.
-
R_IJK_I4 multiplies A = B*C using index order IJK and unrolling I 4 times.
-
R_IJK_I8 multiplies A = B*C using index order IJK and unrolling I 8 times.
-
R_IJK_J4 multiplies A = B*C using index order IJK, and unrolling on J.
-
R_IJK_K4 multiplies A = B*C using index order IJK and unrolling on K.
-
R_IKJ multiplies A = B*C using index order IKJ.
-
R_JIK multiplies A = B*C using index order JIK.
-
R_JKI multiplies A = B*C using index order JKI.
-
R_KIJ multiplies A = B*C using index order KIJ.
-
R_KJI multiplies A = B*C using index order KJI.
-
R_KJI_M multiplies A = B*C using index order KJI and multitasking.
-
R_MXMA multiplies A = B*C using optimized MXMA.
-
R_SAXPYC multiplies A = B*C columnwise, using optimized SAXPY.
-
R_SAXPYR multiplies A = B*C "rowwise", using optimized SAXPY.
-
R_SDOT multiplies A = B*C using optimized SDOT.
-
R_SET initializes the real A, B and C matrices.
-
R_SGEMM multiplies A = B*C using optimized SGEMM.
-
R_SGEMMS multiplies A = B*C using optimized SGEMMS.
-
R_TAXPYC multiplies A = B*C columnwise, using unoptimized SAXPY.
-
R_TAXPYR multiplies A = B*C rowwise using source code SAXPY.
-
R_TDOT multiplies A = B * C using source code SDOT.
-
R_TGEMM multiplies A = B*C using TGEMM.
-
REPORT reports the results for each multiplication experiment.
-
S_BLANK_DELETE removes blanks from a string, left justifying the remainder.
-
S_CAP replaces any lowercase letters by uppercase ones in a string.
-
S_EQI is a case insensitive comparison of two strings for equality.
-
S_TO_I reads an integer value from a string.
-
TAXPY is unoptimized standard BLAS routine SAXPY.
-
TDOT computes the inner product of two vectors.
-
TERBLA is the source code for the BLAS error handler.
-
TGEMM is a source code copy of SGEMM, a BLAS matrix * matrix routine.
-
TGEMVF is a source code copy of BLAS SGEMVF, a matrix * vector routine.
-
TLSAME is a source code copy of BLAS LSAME, testing character equality.
Back to the FORTRAN software page.
Last revised on 27 March 2001.