3 SUBROUTINE psgsepreq( NIN, MEM, MEMSIZE, NOUT, ISEED, NTESTS,
4 $ NSKIPPED, NNOCHECK, NPASSED, INFO )
12 INTEGER INFO, MEMSIZE, NIN, NNOCHECK, NOUT, NPASSED,
75 INTEGER BLOCK_CYCLIC_2D, DLEN_, DTYPE_, CTXT_, M_, N_,
76 $ mb_, nb_, rsrc_, csrc_, lld_
77 parameter( block_cyclic_2d = 1, dlen_ = 9, dtype_ = 1,
78 $ ctxt_ = 2, m_ = 3, n_ = 4, mb_ = 5, nb_ = 6,
79 $ rsrc_ = 7, csrc_ = 8, lld_ = 9 )
81 parameter( five = 5.0e+0 )
82 INTEGER REALSZ, INTGSZ
83 parameter( realsz = 4, intgsz = 4 )
85 parameter( maxsetsize = 50 )
89 INTEGER CONTEXT, IAM, IBTYPE, IMIDPAD, INITCON,
90 $ ipostpad, iprepad, isizesubtst, isizesyevx,
91 $ isizetst, lda, llwork, matsize, mattype, mycol,
92 $ myrow, n, nb, nibtypes, nmatsizes, nmattypes,
93 $ nnodes, np, npcol, npconfigs, nprow, nq,
94 $ nuplos, order, pconfig, ptra, ptrb, ptrcopya,
95 $ ptrcopyb, ptrgap, ptriclus, ptrifail, ptriwrk,
96 $ ptrw, ptrw2, ptrwork, ptrz, res, sizechk,
97 $ sizemqrleft, sizemqrright, sizeqrf, sizeqtq,
98 $ sizesubtst, sizesyevx, sizetms, sizetst, uplo
103 INTEGER DESCA( DLEN_ ), MATSIZES( MAXSETSIZE ),
104 $ mattypes( maxsetsize ), nbs( maxsetsize ),
105 $ npcols( maxsetsize ), nprows( maxsetsize )
109 INTEGER ICEIL, NUMROC
110 EXTERNAL lsame, iceil, numroc
113 EXTERNAL blacs_abort, blacs_get, blacs_gridexit,
114 $ blacs_gridinfo, blacs_gridinit, blacs_pinfo,
122 IF( block_cyclic_2d*csrc_*ctxt_*dlen_*dtype_*lld_*mb_*m_*nb_*n_*
125 CALL blacs_pinfo( iam, nnodes )
126 CALL blacs_get( -1, 0, initcon )
127 CALL blacs_gridinit( initcon,
'R', 1, nnodes )
129 CALL pssepinfo( initcon, iam, nin, nout, maxsetsize, nmatsizes,
130 $ matsizes, nuplos, uplos, npconfigs, nprows,
131 $ npcols, nbs, nmattypes, mattypes, 22, subtests,
132 $ thresh, order, abstol, info )
134 CALL blacs_gridexit( initcon )
142 DO 50 matsize = 1, nmatsizes
144 DO 40 pconfig = 1, npconfigs
146 DO 30 mattype = 1, nmattypes
148 DO 20 uplo = 1, nuplos
149 IF( lsame( subtests,
'Y' ) )
THEN
154 DO 10 ibtype = 1, nibtypes
156 n = matsizes( matsize )
159 nprow = nprows( pconfig )
160 npcol = npcols( pconfig )
163 np = numroc( n, nb, 0, 0, nprow )
164 nq = numroc( n, nb, 0, 0, npcol )
165 iprepad =
max( nb, np )
167 ipostpad =
max( nb, nq )
169 lda =
max( np, 1 ) + imidpad
171 CALL blacs_get( -1, 0, context )
172 CALL blacs_gridinit( context,
'R', nprow,
174 CALL blacs_gridinfo( context, nprow, npcol,
176 IF( myrow.GE.0 )
THEN
177 CALL descinit( desca, n, n, nb, nb, 0, 0,
178 $ context, lda, info )
180 $ sizemqrleft, sizemqrright,
181 $ sizeqrf, sizetms, sizeqtq,
182 $ sizechk, sizesyevx,
183 $ isizesyevx, sizesubtst,
184 $ isizesubtst, sizetst,
188 ptrz = ptra + lda*nq + iprepad + ipostpad
189 ptrcopyb = ptrz + lda*nq + iprepad + ipostpad
190 ptrb = ptrcopyb + lda*nq + iprepad + ipostpad
191 ptrcopya = ptrb + lda*nq + iprepad + ipostpad
192 ptrw = ptrcopya + lda*nq + iprepad + ipostpad
193 ptrw2 = ptrw +
max( n, 1 ) + iprepad +
195 ptrgap = ptrw2 +
max( n, 1 ) + iprepad +
197 ptrifail = ptrgap + nprow*npcol + iprepad +
199 ptriclus = ptrifail +
200 $ iceil( n+iprepad+ipostpad,
202 ptriwrk = ptriclus + iceil( 2*nprow*npcol+
203 $ iprepad+ipostpad, realsz / intgsz )
204 ptrwork = ptriwrk + iceil( isizetst+iprepad+
205 $ ipostpad, realsz / intgsz )
206 llwork = memsize - ptrwork - ipostpad -
209 IF( llwork.LT.sizetst )
THEN
210 nskipped = nskipped + 1
213 $ mattypes( mattype ),
214 $ ibtype, subtests, thresh,
221 $ mem( ptrw ), mem( ptrw2 ),
224 $ mem( ptrgap ), iprepad,
225 $ ipostpad, mem( ptrwork ),
226 $ llwork, mem( ptriwrk ),
227 $ isizetst, nout, res )
230 npassed = npassed + 1
231 ELSE IF( res.EQ.2 )
THEN
232 nnocheck = nnocheck + 1
233 ELSE IF( res.EQ.3 )
THEN
234 nskipped = nskipped + 1
235 WRITE( nout, fmt = * )
236 $
' pSGSEPREQ failed'
237 CALL blacs_abort( context, -1 )
239 CALL blacs_gridexit( context )