1186 COMPLEX zero, half, one
1187 parameter ( zero = ( 0.0, 0.0 ), half = ( 0.5, 0.0 ),
1188 $ one = ( 1.0, 0.0 ) )
1190 parameter ( rzero = 0.0 )
1193 INTEGER incmax, nidim, ninc, nkb, nmax, nout, ntra,
1195 LOGICAL fatal, rewi, trace
1198 COMPLEX a( nmax, nmax ), aa( nmax*nmax ),
1199 $ as( nmax*nmax ), x( nmax ), xs( nmax*incmax ),
1200 $ xt( nmax ), xx( nmax*incmax ), z( nmax )
1202 INTEGER idim( nidim ), inc( ninc ), kb( nkb )
1206 INTEGER i, icd, ict, icu, ik, in, incx, incxs, ix, k,
1207 $ ks, laa, lda, ldas, lx, n, nargs, nc, nk, ns
1208 LOGICAL banded, full, null, packed, reset, same
1209 CHARACTER*1 diag, diags, trans, transs, uplo, uplos
1210 CHARACTER*14 cuplo,ctrans,cdiag
1211 CHARACTER*2 ichd, ichu
1219 EXTERNAL cmake,
cmvch, cctbmv, cctbsv, cctpmv,
1220 $ cctpsv, cctrmv, cctrsv
1224 INTEGER infot, noutc
1227 COMMON /infoc/infot, noutc, ok
1229 DATA ichu/
'UL'/, icht/
'NTC'/, ichd/
'UN'/
1231 full = sname( 9: 9 ).EQ.
'r'
1232 banded = sname( 9: 9 ).EQ.
'b'
1233 packed = sname( 9: 9 ).EQ.
'p'
1237 ELSE IF( banded )
THEN
1239 ELSE IF( packed )
THEN
1251 DO 110 in = 1, nidim
1277 laa = ( n*( n + 1 ) )/2
1284 uplo = ichu( icu: icu )
1285 IF (uplo.EQ.
'U')
THEN
1286 cuplo =
' CblasUpper'
1288 cuplo =
' CblasLower'
1292 trans = icht( ict: ict )
1293 IF (trans.EQ.
'N')
THEN
1294 ctrans =
' CblasNoTrans'
1295 ELSE IF (trans.EQ.
'T')
THEN
1296 ctrans =
' CblasTrans'
1298 ctrans =
'CblasConjTrans'
1302 diag = ichd( icd: icd )
1303 IF (diag.EQ.
'N')
THEN
1304 cdiag =
' CblasNonUnit'
1306 cdiag =
' CblasUnit'
1312 CALL cmake( sname( 8: 9 ), uplo, diag, n, n, a,
1313 $ nmax, aa, lda, k, k, reset, transl )
1322 CALL cmake(
'ge',
' ',
' ', 1, n, x, 1, xx,
1323 $ abs( incx ), 0, n - 1, reset,
1327 xx( 1 + abs( incx )*( n/2 - 1 ) ) = zero
1350 IF( sname( 10: 11 ).EQ.
'mv' )
THEN
1353 $
WRITE( ntra, fmt = 9993 )nc, sname,
1354 $ cuplo, ctrans, cdiag, n, lda, incx
1357 CALL cctrmv( iorder, uplo, trans, diag,
1358 $ n, aa, lda, xx, incx )
1359 ELSE IF( banded )
THEN
1361 $
WRITE( ntra, fmt = 9994 )nc, sname,
1362 $ cuplo, ctrans, cdiag, n, k, lda, incx
1365 CALL cctbmv( iorder, uplo, trans, diag,
1366 $ n, k, aa, lda, xx, incx )
1367 ELSE IF( packed )
THEN
1369 $
WRITE( ntra, fmt = 9995 )nc, sname,
1370 $ cuplo, ctrans, cdiag, n, incx
1373 CALL cctpmv( iorder, uplo, trans, diag,
1376 ELSE IF( sname( 10: 11 ).EQ.
'sv' )
THEN
1379 $
WRITE( ntra, fmt = 9993 )nc, sname,
1380 $ cuplo, ctrans, cdiag, n, lda, incx
1383 CALL cctrsv( iorder, uplo, trans, diag,
1384 $ n, aa, lda, xx, incx )
1385 ELSE IF( banded )
THEN
1387 $
WRITE( ntra, fmt = 9994 )nc, sname,
1388 $ cuplo, ctrans, cdiag, n, k, lda, incx
1391 CALL cctbsv( iorder, uplo, trans, diag,
1392 $ n, k, aa, lda, xx, incx )
1393 ELSE IF( packed )
THEN
1395 $
WRITE( ntra, fmt = 9995 )nc, sname,
1396 $ cuplo, ctrans, cdiag, n, incx
1399 CALL cctpsv( iorder, uplo, trans, diag,
1407 WRITE( nout, fmt = 9992 )
1414 isame( 1 ) = uplo.EQ.uplos
1415 isame( 2 ) = trans.EQ.transs
1416 isame( 3 ) = diag.EQ.diags
1417 isame( 4 ) = ns.EQ.n
1419 isame( 5 ) =
lce( as, aa, laa )
1420 isame( 6 ) = ldas.EQ.lda
1422 isame( 7 ) =
lce( xs, xx, lx )
1424 isame( 7 ) =
lceres(
'ge',
' ', 1, n, xs,
1427 isame( 8 ) = incxs.EQ.incx
1428 ELSE IF( banded )
THEN
1429 isame( 5 ) = ks.EQ.k
1430 isame( 6 ) =
lce( as, aa, laa )
1431 isame( 7 ) = ldas.EQ.lda
1433 isame( 8 ) =
lce( xs, xx, lx )
1435 isame( 8 ) =
lceres(
'ge',
' ', 1, n, xs,
1438 isame( 9 ) = incxs.EQ.incx
1439 ELSE IF( packed )
THEN
1440 isame( 5 ) =
lce( as, aa, laa )
1442 isame( 6 ) =
lce( xs, xx, lx )
1444 isame( 6 ) =
lceres(
'ge',
' ', 1, n, xs,
1447 isame( 7 ) = incxs.EQ.incx
1455 same = same.AND.isame( i )
1456 IF( .NOT.isame( i ) )
1457 $
WRITE( nout, fmt = 9998 )i
1465 IF( sname( 10: 11 ).EQ.
'mv' )
THEN
1469 CALL cmvch( trans, n, n, one, a, nmax, x,
1470 $ incx, zero, z, incx, xt, g,
1471 $ xx, eps, err, fatal, nout,
1473 ELSE IF( sname( 10: 11 ).EQ.
'sv' )
THEN
1478 z( i ) = xx( 1 + ( i - 1 )*
1480 xx( 1 + ( i - 1 )*abs( incx ) )
1483 CALL cmvch( trans, n, n, one, a, nmax, z,
1484 $ incx, zero, x, incx, xt, g,
1485 $ xx, eps, err, fatal, nout,
1488 errmax = max( errmax, err )
1511 IF( errmax.LT.thresh )
THEN
1512 WRITE( nout, fmt = 9999 )sname, nc
1514 WRITE( nout, fmt = 9997 )sname, nc, errmax
1519 WRITE( nout, fmt = 9996 )sname
1521 WRITE( nout, fmt = 9993 )nc, sname, cuplo, ctrans, cdiag, n,
1523 ELSE IF( banded )
THEN
1524 WRITE( nout, fmt = 9994 )nc, sname, cuplo, ctrans, cdiag, n, k,
1526 ELSE IF( packed )
THEN
1527 WRITE( nout, fmt = 9995 )nc, sname, cuplo, ctrans, cdiag, n,
1534 9999
FORMAT(
' ',a12,
' PASSED THE COMPUTATIONAL TESTS (', i6,
' CALL',
1536 9998
FORMAT(
' ******* FATAL ERROR - PARAMETER NUMBER ', i2,
' WAS CH',
1537 $
'ANGED INCORRECTLY *******' )
1538 9997
FORMAT(
' ',a12,
' COMPLETED THE COMPUTATIONAL TESTS (', i6,
' C',
1539 $
'ALLS)', /
' ******* BUT WITH MAXIMUM TEST RATIO', f8.2,
1540 $
' - SUSPECT *******' )
1541 9996
FORMAT(
' ******* ',a12,
' FAILED ON CALL NUMBER:' )
1542 9995
FORMAT(1x, i6,
': ',a12,
'(', 3( a14,
',' ),/ 10x, i3,
', AP, ',
1544 9994
FORMAT(1x, i6,
': ',a12,
'(', 3( a14,
',' ),/ 10x, 2( i3,
',' ),
1545 $
' A,', i3,
', X,', i2,
') .' )
1546 9993
FORMAT( 1x, i6,
': ',a12,
'(', 3( a14,
',' ),/ 10x, i3,
', A,',
1547 $ i3,
', X,', i2,
') .' )
1548 9992
FORMAT(
' ******* FATAL ERROR - ERROR-EXIT TAKEN ON VALID CALL *',
subroutine cmvch(TRANS, M, N, ALPHA, A, NMAX, X, INCX, BETA, Y, INCY, YT, G, YY, EPS, ERR, FATAL, NOUT, MV)
logical function lce(RI, RJ, LR)
subroutine cmake(TYPE, UPLO, DIAG, M, N, A, NMAX, AA, LDA, KL, KU, RESET, TRANSL)
logical function lceres(TYPE, UPLO, M, N, AA, AS, LDA)