1 SUBROUTINE pdgehdrv( N, ILO, IHI, A, IA, JA, DESCA, TAU, WORK )
9 INTEGER IA, IHI, ILO, , N
13 DOUBLE PRECISION A( * ), TAU( * ), WORK( * )
90 INTEGER BLOCK_CYCLIC_2D, CSRC_, CTXT_, DLEN_, DTYPE_,
91 $ LLD_, , M_, NB_, N_, RSRC_
92 parameter( block_cyclic_2d = 1, dlen_ = 9, dtype_ = 1,
93 $ ctxt_ = 2, m_ = 3, n_ = 4, mb_
94 $ rsrc_ = 7, csrc_ = 8, lld_ = 9 )
96 parameter( zero = 0.0d+0 )
99 INTEGER I, IACOL, IAROW, ICTXT, IHLP, II
104 INTEGER DESCV( DLEN_ )
121 ictxt = desca( ctxt_ )
130 ioff = mod( ia+ilo-2, nb )
131 CALL infog2l( ia+ilo-1, ja+ilo-1, desca, nprow, npcol, myrow,
132 $ mycol, ii, jj, iarow, iacol )
133 ihlp = numroc( ihi-ilo+ioff+1, nb, myrow, iarow, nprow )
137 ipw = ipv + ihlp * nb
138 jl =
max( ( ( ja+ihi-2 ) / nb ) * nb + 1, ja + ilo - 1 )
139 CALL descset( descv, ihi-ilo+ioff+1, nb, nb, nb, iarow,
140 $
indxg2p( jl, desca( nb_ ), mycol, desca( csrc_ ),
141 $ npcol ), ictxt,
max( 1, ihlp ) )
143 DO 10 j = jl, ilo+ja+nb-ioff-1, -nb
144 jb =
min( ja+ihi-j-1, nb )
147 iv = k - ilo + ioff + 1
151 CALL pdlarft(
'Forward',
'Columnwise', ihi-k, jb, a, i+1, j,
152 $ desca, tau, work( ipt ), work( ipw ) )
156 CALL pdlacpy(
'All', ihi-k, jb, a, i+1, j, desca, work( ipv ),
161 CALL pdlaset(
'Lower', ihi-k-1, jb, zero, zero, a, i+2, j,
166 CALL pdlarfb(
'Left',
'No transpose',
'Forward',
'Columnwise'
167 $ ihi-k, n-k+1, jb, work( ipv ), iv+1, 1, descv,
168 $ work( ipt ), a, i+1, j, desca, work( ipw ) )
172 CALL pdlarfb( 'right
', 'transpose
', 'forward
', 'columnwise
',
173 $ IHI, IHI-K, JB, WORK( IPV ), IV+1, 1, DESCV,
174 $ WORK( IPT ), A, IA, J+1, DESCA, WORK( IPW ) )
176 DESCV( CSRC_ ) = MOD( DESCV( CSRC_ ) + NPCOL - 1, NPCOL )
185 JB = MIN( NB-IOFF, JA+IHI-J-1 )
189 CALL PDLARFT( 'forward
', 'columnwise
', IHI-ILO, JB, A, I+1, J,
190 $ DESCA, TAU, WORK( IPT ), WORK( IPW ) )
194 CALL PDLACPY( 'all
', IHI-ILO, JB, A, I+1, J, DESCA, WORK( IPV ),
200 $ CALL PDLASET( 'lower
', IHI-ILO-1, JB, ZERO, ZERO, A, I+2, J,
205 CALL PDLARFB( 'left
', 'no transpose
', 'forward
', 'columnwise
',
206 $ IHI-ILO, N-ILO+1, JB, WORK( IPV ), IV+1, 1, DESCV,
207 $ WORK( IPT ), A, I+1, J, DESCA, WORK( IPW ) )
211 CALL PDLARFB( 'right
', 'transpose
', 'forward
', 'columnwise
', IHI,
212 $ IHI-ILO, JB, WORK( IPV ), IV+1, 1, DESCV,
213 $ WORK( IPT ), A, IA, J+1, DESCA, WORK( IPW ) )
subroutine infog2l(grindx, gcindx, desc, nprow, npcol, myrow, mycol, lrindx, lcindx, rsrc, csrc)
subroutine pdlarfb(side, trans, direct, storev, m, n, k, v, iv, jv, descv, t, c, ic, jc, descc, work)