4 CHARACTER*7 SNAMES( NSUBS )
6 DATA snames/
'PDGEMV ',
'PDSYMV ',
'PDTRMV ',
7 $
'PDTRSV ',
'PDGER ',
'PDSYR ',
114 INTEGER maxtests, maxgrids, dblesz, totmem, memsiz,
117 parameter( maxtests = 20, maxgrids = 20, dblesz = 8,
118 $ one = 1.0d+0, totmem = 2000000, nsubs = 7,
119 $ memsiz = totmem / dblesz )
120 INTEGER block_cyclic_2d_inb, csrc_, ctxt_, dlen_,
121 $ dtype_, imb_, inb_, lld_, mb_, m_, nb_, n_,
123 parameter( block_cyclic_2d_inb = 2, dlen_ = 11,
124 $ dtype_ = 1, ctxt_ = 2, m_ = 3, n_ = 4,
125 $ imb_ = 5, inb_ = 6, mb_ = 7, nb_ = 8,
126 $ rsrc_ = 9, csrc_ = 10, lld_ = 11 )
129 CHARACTER*1 aform, diag, diagdo, trans, uplo
130 INTEGER csrca, csrcx, csrcy, i, ia, iam, iaseed, ictxt,
131 $ imba, imbx, imby, imida, imidx, imidy, inba,
132 $ inbx, inby, incx, incy, ipa, iposta, ipostx,
133 $ iposty, iprea, iprex, iprey, ipx, ipy, ix,
134 $ ixseed, iy, iyseed, j, ja, jx, jy, k, m, ma,
135 $ mba, mbx, mby, memreqd, mpa, mpx, mpy, mx, my,
136 $ mycol, myrow, n, na, nba, nbx, nby, ncola,
137 $ ngrids, nlx, nly, nout, npcol, nprocs, nprow,
138 $ nqa, nqx, nqy, nrowa, ntests, nx, ny, offd,
139 $ rsrca, rsrcx, rsrcy
140 DOUBLE PRECISION alpha, beta, cflops, nops, scale, wflops
143 LOGICAL ltest( nsubs ), ycheck( nsubs )
144 CHARACTER*1 diagval( maxtests ), tranval( maxtests ),
145 $ uploval( maxtests )
147 INTEGER cscaval( maxtests ), cscxval( maxtests ),
148 $ cscyval( maxtests ), desca( dlen_ ),
149 $ descx( dlen_ ), descy( dlen_ ),
150 $ iaval( maxtests ), ierr( 3 ),
151 $ imbaval( maxtests ), imbxval( maxtests ),
152 $ imbyval( maxtests ), inbaval( maxtests ),
153 $ inbxval( maxtests ), inbyval( maxtests ),
154 $ incxval( maxtests ), incyval( maxtests ),
155 $ ixval( maxtests ), iyval( maxtests ),
156 $ javal( maxtests ), jxval( maxtests ),
157 $ jyval( maxtests ), maval( maxtests ),
158 $ mbaval( maxtests ), mbxval( maxtests ),
159 $ mbyval( maxtests ), mval( maxtests ),
160 $ mxval( maxtests ), myval( maxtests ),
161 $ naval( maxtests ), nbaval( maxtests ),
162 $ nbxval( maxtests ), nbyval( maxtests ),
163 $ nval( maxtests ), nxval( maxtests ),
164 $ nyval( maxtests ), pval( maxtests ),
165 $ qval( maxtests ), rscaval( maxtests ),
166 $ rscxval( maxtests ), rscyval( maxtests )
167 DOUBLE PRECISION ctime( 1 ), mem( memsiz ), wtime( 1 )
170 EXTERNAL blacs_barrier, blacs_exit, blacs_get,
171 $ blacs_gridexit, blacs_gridinfo, blacs_gridinit,
187 CHARACTER*7 snames( nsubs )
190 COMMON /snamec/snames
191 COMMON /infoc/info, nblog
192 COMMON /pberrorc/nout, abrtflg
195 DATA ycheck/.true., .true., .false., .false.,
196 $ .true., .false., .true./
215 CALL blacs_pinfo( iam, nprocs )
217 $ uploval, mval, nval, maval, naval, imbaval,
218 $ mbaval, inbaval, nbaval, rscaval, cscaval,
219 $ iaval, javal, mxval, nxval, imbxval, mbxval,
220 $ inbxval, nbxval, rscxval, cscxval, ixval,
221 $ jxval, incxval, myval, nyval, imbyval,
222 $ mbyval, inbyval, nbyval, rscyval,
223 $ cscyval, iyval, jyval, incyval, maxtests,
224 $ ngrids, pval, maxgrids, qval, maxgrids,
225 $ nblog, ltest, iam, nprocs, alpha, beta, mem )
228 $
WRITE( nout, fmt = 9983 )
240 IF( nprow.LT.1 )
THEN
242 $
WRITE( nout, fmt = 9999 )
'GRID SIZE',
'NPROW', nprow
244 ELSE IF( npcol.LT.1 )
THEN
246 $
WRITE( nout, fmt = 9999 )
'GRID SIZE',
'NPCOL', npcol
248 ELSE IF( nprow*npcol.GT.nprocs )
THEN
250 $
WRITE( nout, fmt = 9998 ) nprow*npcol, nprocs
254 IF( ierr( 1 ).GT.0 )
THEN
256 $
WRITE( nout, fmt = 9997 )
'GRID'
262 CALL blacs_get( -1, 0, ictxt )
263 CALL blacs_gridinit( ictxt,
'Row-major', nprow, npcol )
264 CALL blacs_gridinfo( ictxt, nprow, npcol, myrow, mycol )
269 IF( myrow.GE.nprow .OR. mycol.GE.npcol )
322 WRITE( nout, fmt = * )
323 WRITE( nout, fmt = 9996 ) j, nprow, npcol
324 WRITE( nout, fmt = * )
326 WRITE( nout, fmt = 9995 )
327 WRITE( nout, fmt = 9994 )
328 WRITE( nout, fmt = 9995 )
329 WRITE( nout, fmt = 9993 ) m, n, uplo, trans, diag
331 WRITE( nout, fmt = 9995 )
332 WRITE( nout, fmt = 9992 )
333 WRITE( nout, fmt = 9995 )
334 WRITE( nout, fmt = 9991 ) ia, ja, ma, na, imba, inba,
335 $ mba, nba, rsrca, csrca
337 WRITE( nout, fmt = 9995 )
338 WRITE( nout, fmt = 9990 )
339 WRITE( nout, fmt = 9995 )
340 WRITE( nout, fmt = 9989 ) ix, jx, mx, nx, imbx, inbx,
341 $ mbx, nbx, rsrcx, csrcx, incx
343 WRITE( nout, fmt = 9995 )
344 WRITE( nout, fmt = 9988 )
345 WRITE( nout, fmt = 9995 )
346 WRITE( nout, fmt = 9989 ) iy, jy, my, ny, imby, inby,
347 $ mby, nby, rsrcy, csrcy, incy
349 WRITE( nout, fmt = 9995 )
350 WRITE( nout, fmt = 9980 )
356 IF( .NOT.
lsame( uplo,
'U' ).AND.
357 $ .NOT.
lsame( uplo,
'L' ) )
THEN
359 $
WRITE( nout, fmt = 9997 )
'UPLO'
363 IF( .NOT.
lsame( trans,
'N' ).AND.
364 $ .NOT.
lsame( trans,
'T' ).AND.
365 $ .NOT.
lsame( trans,
'C' ) )
THEN
367 $
WRITE( nout, fmt = 9997 )
'TRANS'
371 IF( .NOT.
lsame( diag ,
'U' ).AND.
372 $ .NOT.
lsame( diag ,
'N' ) )
THEN
374 $
WRITE( nout, fmt = 9997 ) trans
375 WRITE( nout, fmt = 9997 )
'DIAG'
382 $ block_cyclic_2d_inb, ma, na, imba, inba,
383 $ mba, nba, rsrca, csrca, mpa, nqa, iprea,
384 $ imida, iposta, 0, 0, ierr( 1 ) )
386 $ block_cyclic_2d_inb, mx, nx, imbx, inbx,
387 $ mbx, nbx, rsrcx, csrcx, incx, mpx, nqx,
388 $ iprex, imidx, ipostx, 0, 0, ierr( 2 ) )
390 $ block_cyclic_2d_inb, my, ny, imby, inby,
391 $ mby, nby, rsrcy, csrcy, incy, mpy, nqy,
392 $ iprey, imidy, iposty, 0, 0, ierr( 3 ) )
394 IF( ierr( 1 ).GT.0 .OR. ierr( 2 ).GT.0 .OR.
395 $ ierr( 3 ).GT.0 )
THEN
403 ipx = ipa + desca( lld_ ) * nqa
404 ipy = ipx + descx( lld_ ) * nqx
408 memreqd = ipy + descy( lld_ ) * nqy - 1
410 IF( memreqd.GT.memsiz )
THEN
412 $
WRITE( nout, fmt = 9986 ) memreqd*dblesz
418 CALL igsum2d( ictxt,
'All',
' ', 1, 1, ierr, 1, -1, 0 )
420 IF( ierr( 1 ).GT.0 )
THEN
422 $
WRITE( nout, fmt = 9987 )
432 IF( .NOT.ltest( k ) )
440 IF(
lsame( trans,
'N' ) )
THEN
447 ELSE IF( k.EQ.5 )
THEN
461 CALL pmdimchk( ictxt, nout, nrowa, ncola,
'A', ia, ja,
463 CALL pvdimchk( ictxt, nout, nlx,
'X', ix, jx, descx,
465 CALL pvdimchk( ictxt, nout, nly,
'Y', iy, jy, descy,
468 IF( ierr( 1 ).NE.0 .OR. ierr( 2 ).NE.0 .OR.
469 $ ierr( 3 ).NE.0 )
THEN
475 IF( k.EQ.2 .OR. k.EQ.6 .OR. k.EQ.7 )
THEN
479 ELSE IF( ( k.EQ.4 ).AND.(
lsame( diag,
'N' ) ) )
THEN
489 CALL pdlagen( .false., aform, diagdo, offd, ma, na,
490 $ 1, 1, desca, iaseed, mem( ipa ),
492 CALL pdlagen( .false.,
'None',
'No diag', 0, mx, nx,
493 $ 1, 1, descx, ixseed, mem( ipx ),
496 $
CALL pdlagen( .false.,
'None',
'No diag', 0, my,
497 $ ny, 1, 1, descy, iyseed, mem( ipy ),
500 IF( ( k.EQ.4 ).AND.( .NOT.(
lsame( diag,
'N' ) ) ).AND.
501 $ (
max( nrowa, ncola ).GT.1 ) )
THEN
502 scale = one / dble(
max( nrowa, ncola ) )
503 IF(
lsame( uplo,
'L' ) )
THEN
504 CALL pdlascal(
'Lower', nrowa-1, ncola-1, scale,
505 $ mem( ipa ), ia+1, ja, desca )
507 CALL pdlascal(
'Upper', nrowa-1, ncola-1, scale,
508 $ mem( ipa ), ia, ja+1, desca )
514 CALL blacs_barrier( ictxt,
'All' )
523 CALL pdgemv( trans, m, n, alpha, mem( ipa ), ia, ja,
524 $ desca, mem( ipx ), ix, jx, descx, incx,
525 $ beta, mem( ipy ), iy, jy, descy, incy )
528 ELSE IF( k.EQ.2 )
THEN
533 CALL pdsymv( uplo, n, alpha, mem( ipa ), ia, ja,
534 $ desca, mem( ipx ), ix, jx, descx, incx,
535 $ beta, mem( ipy ), iy, jy, descy, incy )
538 ELSE IF( k.EQ.3 )
THEN
543 CALL pdtrmv( uplo, trans, diag, n, mem( ipa ), ia, ja,
544 $ desca, mem( ipx ), ix, jx, descx, incx )
547 ELSE IF( k.EQ.4 )
THEN
552 CALL pdtrsv( uplo, trans, diag, n, mem( ipa ), ia, ja,
553 $ desca, mem( ipx ), ix, jx, descx, incx )
556 ELSE IF( k.EQ.5 )
THEN
561 CALL pdger( m, n, alpha, mem( ipx ), ix, jx, descx,
562 $ incx, mem( ipy ), iy, jy, descy, incy,
563 $ mem( ipa ), ia, ja, desca )
566 ELSE IF( k.EQ.6 )
THEN
571 CALL pdsyr( uplo, n, alpha, mem( ipx ), ix, jx, descx,
572 $ incx, mem( ipa ), ia, ja, desca )
575 ELSE IF( k.EQ.7 )
THEN
580 CALL pdsyr2( uplo, n, alpha, mem( ipx ), ix, jx,
581 $ descx, incx, mem( ipy ), iy, jy, descy,
582 $ incy, mem( ipa ), ia, ja, desca )
591 $
WRITE( nout, fmt = 9982 ) info
595 CALL pb_combine( ictxt,
'All',
'>',
'W', 1, 1, wtime )
596 CALL pb_combine( ictxt,
'All',
'>',
'C', 1, 1, ctime )
604 nops =
pdopbl2( snames( k ), nrowa, ncola, 0, 0 )
608 IF( wtime( 1 ).GT.0.0d+0 )
THEN
609 wflops = nops / ( wtime( 1 ) * 1.0d+6 )
616 IF( ctime( 1 ).GT.0.0d+0 )
THEN
617 cflops = nops / ( ctime( 1 ) * 1.0d+6 )
622 WRITE( nout, fmt = 9981 ) snames( k ), wtime( 1 ),
623 $ wflops, ctime( 1 ), cflops
629 40
IF( iam.EQ.0 )
THEN
630 WRITE( nout, fmt = 9995 )
631 WRITE( nout, fmt = * )
632 WRITE( nout, fmt = 9985 ) j
637 CALL blacs_gridexit( ictxt )
644 WRITE( nout, fmt = * )
645 WRITE( nout, fmt = 9984 )
646 WRITE( nout, fmt = * )
651 9999
FORMAT(
'ILLEGAL ', a,
': ', a,
' = ', i10,
652 $
' should be at least 1' )
653 9998
FORMAT(
'ILLEGAL GRID: NPROW*NPCOL = ', i4,
654 $
'. It can be at most', i4 )
655 9997
FORMAT(
'Bad ', a,
' parameters: going on to next test case.' )
656 9996
FORMAT( 2x,
'Test number ', i2 ,
' started on a ', i4,
' x ',
657 $ i4,
' process grid.' )
658 9995
FORMAT( 2x,
' ------------------------------------------------',
659 $
'--------------------------' )
660 9994
FORMAT( 2x,
' M N UPLO TRANS DIAG' )
661 9993
FORMAT( 5x,i6,1x,i6,9x,a1,11x,a1,10x,a1 )
662 9992
FORMAT( 2x,
' IA JA MA NA IMBA INBA',
663 $
' MBA NBA RSRCA CSRCA' )
664 9991
FORMAT( 5x,i6,1x,i6,1x,i6,1x,i6,1x,i6,1x,i6,1x,i6,1x,i6,
666 9990
FORMAT( 2x,
' IX JX MX NX IMBX INBX',
667 $
' MBX NBX RSRCX CSRCX INCX' )
668 9989
FORMAT( 5x,i6,1x,i6,1x,i6,1x,i6,1x,i6,1x,i6,1x,i6,1x,i6,
669 $ 1x,i5,1x,i5,1x,i6 )
670 9988
FORMAT( 2x,
' IY JY MY NY IMBY INBY',
671 $
' MBY NBY RSRCY CSRCY INCY' )
672 9987
FORMAT(
'Not enough memory for this test: going on to',
673 $
' next test case.' )
674 9986
FORMAT(
'Not enough memory. Need: ', i12 )
675 9985
FORMAT( 2x,
'Test number ', i2,
' completed.' )
676 9984
FORMAT( 2x,
'End of Tests.' )
677 9983
FORMAT( 2x,
'Tests started.' )
678 9982
FORMAT( 2x,
' ***** Operation not supported, error code: ',
680 9981
FORMAT( 2x,
'| ', a, 2x, f13.3, 2x, f13.3, 2x, f13.3, 2x, f13.3 )
681 9980
FORMAT( 2x,
' WALL time (s) WALL Mflops ',
682 $
' CPU time (s) CPU Mflops' )
689 SUBROUTINE pdbla2timinfo( SUMMRY, NOUT, NMAT, DIAGVAL, TRANVAL,
690 $ UPLOVAL, MVAL, NVAL, MAVAL, NAVAL,
691 $ IMBAVAL, MBAVAL, INBAVAL, NBAVAL,
692 $ RSCAVAL, CSCAVAL, IAVAL, JAVAL,
693 $ MXVAL, NXVAL, IMBXVAL, MBXVAL,
694 $ INBXVAL, NBXVAL, RSCXVAL, CSCXVAL,
695 $ IXVAL, JXVAL, INCXVAL, MYVAL, NYVAL,
696 $ IMBYVAL, MBYVAL, INBYVAL, NBYVAL,
697 $ RSCYVAL, CSCYVAL, IYVAL, JYVAL,
698 $ INCYVAL, LDVAL, NGRIDS, PVAL, LDPVAL,
699 $ QVAL, LDQVAL, NBLOG, LTEST, IAM, NPROCS,
700 $ ALPHA, BETA, WORK )
708 INTEGER IAM, LDPVAL, LDQVAL, LDVAL, NBLOG, NGRIDS,
710 DOUBLE PRECISION ALPHA, BETA
713 CHARACTER*( * ) SUMMRY
714 CHARACTER*1 DIAGVAL( LDVAL ), TRANVAL( LDVAL ),
717 INTEGER CSCAVAL( LDVAL ), CSCXVAL( LDVAL ),
718 $ CSCYVAL( LDVAL ), IAVAL( LDVAL ),
719 $ imbaval( ldval ), imbxval( ldval ),
720 $ imbyval( ldval ), inbaval( ldval ),
721 $ inbxval( ldval ), inbyval( ldval ),
722 $ incxval( ldval ), incyval( ldval ),
723 $ ixval( ldval ), iyval( ldval ), javal( ldval ),
724 $ jxval( ldval ), jyval( ldval ), maval( ldval ),
725 $ mbaval( ldval ), mbxval( ldval ),
726 $ mbyval( ldval ), mval( ldval ), mxval( ldval ),
727 $ myval( ldval ), naval( ldval ),
728 $ nbaval( ldval ), nbxval( ldval ),
729 $ nbyval( ldval ), nval( ldval ), nxval( ldval ),
730 $ nyval( ldval ), pval( ldpval ), qval( ldqval ),
731 $ rscaval( ldval ), rscxval( ldval ),
732 $ rscyval( ldval ), work( * )
999 PARAMETER ( NIN = 11, nsubs = 7 )
1007 CHARACTER*79 USRINFO
1010 EXTERNAL blacs_abort, blacs_get, blacs_gridexit,
1011 $ blacs_gridinit, blacs_setup, dgebr2d, dgebs2d,
1012 $
icopy, igebr2d, igebs2d, sgebr2d, sgebs2d
1015 INTRINSIC char, ichar,
max,
min
1018 CHARACTER*7 SNAMES( NSUBS )
1019 COMMON /SNAMEC/SNAMES
1030 OPEN( nin, file=
'PDBLAS2TIM.dat', status=
'OLD' )
1031 READ( nin, fmt = * ) summry
1036 READ( nin, fmt = 9999 ) usrinfo
1040 READ( nin, fmt = * ) summry
1041 READ( nin, fmt = * ) nout
1042 IF( nout.NE.0 .AND. nout.NE.6 )
1043 $
OPEN( nout, file = summry, status =
'UNKNOWN' )
1049 READ( nin, fmt = * ) nblog
1055 READ( nin, fmt = * ) ngrids
1056 IF( ngrids.LT.1 .OR. ngrids.GT.ldpval )
THEN
1057 WRITE( nout, fmt = 9998 )
'Grids', ldpval
1059 ELSE IF( ngrids.GT.ldqval )
THEN
1060 WRITE( nout, fmt = 9998 )
'Grids', ldqval
1066 READ( nin, fmt = * ) ( pval( i ), i = 1, ngrids )
1067 READ( nin, fmt = * ) ( qval( i ), i = 1, ngrids )
1071 READ( nin, fmt = * ) alpha
1072 READ( nin, fmt = * ) beta
1076 READ( nin, fmt = * ) nmat
1077 IF( nmat.LT.1 .OR. nmat.GT.ldval )
THEN
1078 WRITE( nout, fmt = 9998 )
'Tests', ldval
1084 READ( nin, fmt = * ) ( uploval( i ), i = 1, nmat )
1085 READ( nin, fmt = * ) ( tranval( i ), i = 1, nmat )
1086 READ( nin, fmt = * ) ( diagval( i ), i = 1, nmat )
1087 READ( nin, fmt = * ) ( mval( i ), i = 1, nmat )
1088 READ( nin, fmt = * ) ( nval( i ), i = 1, nmat )
1089 READ( nin, fmt = * ) ( maval( i ), i = 1, nmat )
1090 READ( nin, fmt = * ) ( naval( i ), i = 1, nmat )
1091 READ( nin, fmt = * ) ( imbaval( i ), i = 1, nmat )
1092 READ( nin, fmt = * ) ( inbaval( i ), i = 1, nmat )
1093 READ( nin, fmt = * ) ( mbaval( i ), i = 1, nmat )
1094 READ( nin, fmt = * ) ( nbaval( i ), i = 1, nmat )
1095 READ( nin, fmt = * ) ( rscaval( i ), i = 1, nmat )
1096 READ( nin, fmt = * ) ( cscaval( i ), i = 1, nmat )
1097 READ( nin, fmt = * ) ( iaval( i ), i = 1, nmat )
1098 READ( nin, fmt = * ) ( javal( i ), i = 1, nmat )
1099 READ( nin, fmt = * ) ( mxval( i ), i = 1, nmat )
1100 READ( nin, fmt = * ) ( nxval( i ), i = 1, nmat )
1101 READ( nin, fmt = * ) ( imbxval( i ), i = 1, nmat )
1102 READ( nin, fmt = * ) ( inbxval( i ), i = 1, nmat )
1103 READ( nin, fmt = * ) ( mbxval( i ), i = 1, nmat )
1104 READ( nin, fmt = * ) ( nbxval( i ), i = 1, nmat )
1105 READ( nin, fmt = * ) ( rscxval( i ), i = 1, nmat )
1106 READ( nin, fmt = * ) ( cscxval( i ), i = 1, nmat )
1107 READ( nin, fmt = * ) ( ixval( i ), i = 1, nmat )
1108 READ( nin, fmt = * ) ( jxval( i ), i = 1, nmat )
1109 READ( nin, fmt = * ) ( incxval( i ), i = 1, nmat )
1110 READ( nin, fmt = * ) ( myval( i ), i = 1, nmat )
1111 READ( nin, fmt = * ) ( nyval( i ), i = 1, nmat )
1112 READ( nin, fmt = * ) ( imbyval( i ), i = 1, nmat )
1113 READ( nin, fmt = * ) ( inbyval( i ), i = 1, nmat )
1114 READ( nin, fmt = * ) ( mbyval( i ), i = 1, nmat )
1115 READ( nin, fmt = * ) ( nbyval( i ), i = 1, nmat )
1116 READ( nin, fmt = * ) ( rscyval( i ), i = 1, nmat )
1117 READ( nin, fmt = * ) ( cscyval( i ), i = 1, nmat )
1118 READ( nin, fmt = * ) ( iyval( i ), i = 1, nmat )
1119 READ( nin, fmt = * ) ( jyval( i ), i = 1, nmat )
1120 READ( nin, fmt = * ) ( incyval( i ), i = 1, nmat )
1126 ltest( i ) = .false.
1129 READ( nin, fmt = 9996,
END = 50 ) SNAMET, ltestt
1131 IF( snamet.EQ.snames( i ) )
1135 WRITE( nout, fmt = 9995 )snamet
1151 IF( nprocs.LT.1 )
THEN
1154 nprocs =
max( nprocs, pval( i )*qval( i ) )
1156 CALL blacs_setup( iam, nprocs )
1162 CALL blacs_get( -1, 0, ictxt )
1163 CALL blacs_gridinit( ictxt,
'Row-major', 1, nprocs )
1167 CALL dgebs2d( ictxt,
'All',
' ', 1, 1, alpha, 1 )
1168 CALL dgebs2d( ictxt,
'All',
' ', 1, 1, beta, 1 )
1173 CALL igebs2d( ictxt,
'All',
' ', 3, 1, work, 3 )
1177 work( i ) = ichar( diagval( j ) )
1178 work( i+1 ) = ichar( tranval( j ) )
1179 work( i+2 ) = ichar( uploval( j ) )
1182 CALL icopy( ngrids, pval, 1, work( i ), 1 )
1184 CALL icopy( ngrids, qval, 1, work( i ), 1 )
1186 CALL icopy( nmat, mval, 1, work( i ), 1 )
1188 CALL icopy( nmat, nval, 1, work( i ), 1 )
1190 CALL icopy( nmat, maval, 1, work( i ), 1 )
1192 CALL icopy( nmat, naval, 1, work( i ), 1 )
1194 CALL icopy( nmat, imbaval, 1, work( i ), 1 )
1196 CALL icopy( nmat, inbaval, 1, work( i ), 1 )
1198 CALL icopy( nmat, mbaval, 1, work( i ), 1 )
1200 CALL icopy( nmat, nbaval, 1, work( i ), 1 )
1202 CALL icopy( nmat, rscaval, 1, work( i ), 1 )
1204 CALL icopy( nmat, cscaval, 1, work( i ), 1 )
1206 CALL icopy( nmat, iaval, 1, work( i ), 1 )
1208 CALL icopy( nmat, javal, 1, work( i ), 1 )
1210 CALL icopy( nmat, mxval, 1, work( i ), 1 )
1212 CALL icopy( nmat, nxval, 1, work( i ), 1 )
1214 CALL icopy( nmat, imbxval, 1, work( i ), 1 )
1216 CALL icopy( nmat, inbxval, 1, work( i ), 1 )
1218 CALL icopy( nmat, mbxval, 1, work( i ), 1 )
1220 CALL icopy( nmat, nbxval, 1, work( i ), 1 )
1222 CALL icopy( nmat, rscxval, 1, work( i ), 1 )
1224 CALL icopy( nmat, cscxval, 1, work( i ), 1 )
1226 CALL icopy( nmat, ixval, 1, work( i ), 1 )
1228 CALL icopy( nmat, jxval, 1, work( i ), 1 )
1230 CALL icopy( nmat, incxval, 1, work( i ), 1 )
1232 CALL icopy( nmat, myval, 1, work( i ), 1 )
1234 CALL icopy( nmat, nyval, 1, work( i ), 1 )
1236 CALL icopy( nmat, imbyval, 1, work( i ), 1 )
1238 CALL icopy( nmat, inbyval, 1, work( i ), 1 )
1240 CALL icopy( nmat, mbyval, 1, work( i ), 1 )
1242 CALL icopy( nmat, nbyval, 1, work( i ), 1 )
1244 CALL icopy( nmat, rscyval, 1, work( i ), 1 )
1246 CALL icopy( nmat, cscyval, 1, work( i ), 1 )
1248 CALL icopy( nmat, iyval, 1, work( i ), 1 )
1250 CALL icopy( nmat, jyval, 1, work( i ), 1 )
1252 CALL icopy( nmat, incyval, 1, work( i ), 1 )
1256 IF( ltest( j ) )
THEN
1264 CALL igebs2d( ictxt,
'All',
' ', i, 1, work, i )
1268 WRITE( nout, fmt = 9999 )
1269 $
'Level 2 PBLAS timing program.'
1270 WRITE( nout, fmt = 9999 ) usrinfo
1271 WRITE( nout, fmt = * )
1272 WRITE( nout, fmt = 9999 )
1273 $
'Tests of the real double precision '//
1275 WRITE( nout, fmt = * )
1276 WRITE( nout, fmt = 9992 ) nmat
1277 WRITE( nout, fmt = 9986 ) nblog
1278 WRITE( nout, fmt = 9991 ) ngrids
1279 WRITE( nout, fmt = 9989 )
1280 $
'P', ( pval(i), i = 1,
min(ngrids, 5) )
1282 $
WRITE( nout, fmt = 9990 ) ( pval(i), i = 6,
1283 $
min( 10, ngrids ) )
1285 $
WRITE( nout, fmt = 9990 ) ( pval(i), i = 11,
1286 $
min( 15, ngrids ) )
1288 $
WRITE( nout, fmt = 9990 ) ( pval(i), i = 16, ngrids )
1289 WRITE( nout, fmt = 9989 )
1290 $
'Q', ( qval(i), i = 1,
min(ngrids, 5) )
1292 $
WRITE( nout, fmt = 9990 ) ( qval(i), i = 6,
1293 $
min( 10, ngrids ) )
1295 $
WRITE( nout, fmt = 9990 ) ( qval(i), i = 11,
1296 $
min( 15, ngrids ) )
1298 $
WRITE( nout, fmt = 9990 ) ( qval(i), i = 16, ngrids )
1299 WRITE( nout, fmt = 9994 ) alpha
1300 WRITE( nout, fmt = 9993 ) beta
1301 IF( ltest( 1 ) )
THEN
1302 WRITE( nout, fmt = 9988 ) snames( 1 ),
' ... Yes'
1304 WRITE( nout, fmt = 9988 ) snames( 1 ),
' ... No '
1307 IF( ltest( i ) )
THEN
1308 WRITE( nout, fmt = 9987 ) snames( i ),
' ... Yes'
1310 WRITE( nout, fmt = 9987 ) snames( i ),
' ... No '
1313 WRITE( nout, fmt = * )
1320 $
CALL blacs_setup( iam, nprocs )
1325 CALL blacs_get( -1, 0, ictxt )
1326 CALL blacs_gridinit( ictxt,
'Row-major', 1, nprocs )
1328 CALL dgebr2d( ictxt,
'All',
' ', 1, 1, alpha, 1, 0, 0 )
1329 CALL dgebr2d( ictxt,
'All',
' ', 1, 1, beta, 1, 0, 0 )
1331 CALL igebr2d( ictxt,
'All',
' ', 3, 1, work, 3, 0, 0 )
1336 i = 2*ngrids + 37*nmat + nsubs
1337 CALL igebr2d( ictxt,
'All',
' ', i, 1, work, i, 0, 0 )
1341 diagval( j ) = char( work( i ) )
1342 tranval( j ) = char( work( i+1 ) )
1343 uploval( j ) = char( work( i+2 ) )
1346 CALL icopy( ngrids, work( i ), 1, pval, 1 )
1348 CALL icopy( ngrids, work( i ), 1, qval, 1 )
1350 CALL icopy( nmat, work( i ), 1, mval, 1 )
1352 CALL icopy( nmat, work( i ), 1, nval, 1 )
1354 CALL icopy( nmat, work( i ), 1, maval, 1 )
1356 CALL icopy( nmat, work( i ), 1, naval, 1 )
1358 CALL icopy( nmat, work( i ), 1, imbaval, 1 )
1360 CALL icopy( nmat, work( i ), 1, inbaval, 1 )
1362 CALL icopy( nmat, work( i ), 1, mbaval, 1 )
1364 CALL icopy( nmat, work( i ), 1, nbaval, 1 )
1366 CALL icopy( nmat, work( i ), 1, rscaval, 1 )
1368 CALL icopy( nmat, work( i ), 1, cscaval, 1 )
1370 CALL icopy( nmat, work( i ), 1, iaval, 1 )
1372 CALL icopy( nmat, work( i ), 1, javal, 1 )
1374 CALL icopy( nmat, work( i ), 1, mxval, 1 )
1376 CALL icopy( nmat, work( i ), 1, nxval, 1 )
1378 CALL icopy( nmat, work( i ), 1, imbxval, 1 )
1380 CALL icopy( nmat, work( i ), 1, inbxval, 1 )
1382 CALL icopy( nmat, work( i ), 1, mbxval, 1 )
1384 CALL icopy( nmat, work( i ), 1, nbxval, 1 )
1386 CALL icopy( nmat, work( i ), 1, rscxval, 1 )
1388 CALL icopy( nmat, work( i ), 1, cscxval, 1 )
1390 CALL icopy( nmat, work( i ), 1, ixval, 1 )
1392 CALL icopy( nmat, work( i ), 1, jxval, 1 )
1394 CALL icopy( nmat, work( i ), 1, incxval, 1 )
1396 CALL icopy( nmat, work( i ), 1, myval, 1 )
1398 CALL icopy( nmat, work( i ), 1, nyval, 1 )
1400 CALL icopy( nmat, work( i ), 1, imbyval, 1 )
1402 CALL icopy( nmat, work( i ), 1, inbyval, 1 )
1404 CALL icopy( nmat, work( i ), 1, mbyval, 1 )
1406 CALL icopy( nmat, work( i ), 1, nbyval, 1 )
1408 CALL icopy( nmat, work( i ), 1, rscyval, 1 )
1410 CALL icopy( nmat, work( i ), 1, cscyval, 1 )
1412 CALL icopy( nmat, work( i ), 1, iyval, 1 )
1414 CALL icopy( nmat, work( i ), 1, jyval, 1 )
1416 CALL icopy( nmat, work( i ), 1, incyval, 1 )
1420 IF( work( i ).EQ.1 )
THEN
1423 ltest( j ) = .false.
1430 CALL blacs_gridexit( ictxt )
1434 120
WRITE( nout, fmt = 9997 )
1436 IF( nout.NE.6 .AND. nout.NE.0 )
1438 CALL blacs_abort( ictxt, 1 )
1443 9998
FORMAT(
' Number of values of ',5a,
' is less than 1 or greater ',
1445 9997
FORMAT(
' Illegal input in file ',40a,
'. Aborting run.' )
1446 9996
FORMAT( a7, l2 )
1447 9995
FORMAT(
' Subprogram name ', a7,
' not recognized',
1448 $ /
' ******* TESTS ABANDONED *******' )
1449 9994
FORMAT( 2x,
'Alpha : ', g16.6 )
1450 9993
FORMAT( 2x,
'Beta : ', g16.6 )
1451 9992
FORMAT( 2x,
'Number of Tests : ', i6 )
1452 9991
FORMAT( 2x,
'Number of process grids : ', i6 )
1453 9990
FORMAT( 2x,
' : ', 5i6 )
1454 9989
FORMAT( 2x, a1,
' : ', 5i6 )
1455 9988
FORMAT( 2x,
'Routines to be tested : ', a, a8 )
1456 9987
FORMAT( 2x,
' ', a, a8 )
1457 9986
FORMAT( 2x,
'Logical block size : ', i6 )