174 SUBROUTINE dla_geamv ( TRANS, M, N, ALPHA, A, LDA, X, INCX, BETA,
183 DOUBLE PRECISION alpha, beta
184 INTEGER incx, incy, lda, m, n, trans
187 DOUBLE PRECISION a( lda, * ), x( * ), y( * )
193 DOUBLE PRECISION one, zero
194 parameter( one = 1.0d+0, zero = 0.0d+0 )
198 DOUBLE PRECISION temp, safe1
199 INTEGER i, info, iy, j, jx, kx, ky, lenx, leny
210 INTRINSIC max, abs, sign
217 IF ( .NOT.( ( trans.EQ.
ilatrans(
'N' ) )
219 $ .OR. ( trans.EQ.
ilatrans(
'C' )) ) )
THEN
221 ELSE IF( m.LT.0 )
THEN
223 ELSE IF( n.LT.0 )
THEN
225 ELSE IF( lda.LT.max( 1, m ) )
THEN
227 ELSE IF( incx.EQ.0 )
THEN
229 ELSE IF( incy.EQ.0 )
THEN
233 CALL
xerbla(
'DLA_GEAMV ', info )
239 IF( ( m.EQ.0 ).OR.( n.EQ.0 ).OR.
240 $ ( ( alpha.EQ.zero ).AND.( beta.EQ.one ) ) )
256 kx = 1 - ( lenx - 1 )*incx
261 ky = 1 - ( leny - 1 )*incy
267 safe1 =
dlamch(
'Safe minimum' )
277 IF ( incx.EQ.1 )
THEN
280 IF ( beta .EQ. zero )
THEN
283 ELSE IF ( y( iy ) .EQ. zero )
THEN
287 y( iy ) = beta * abs( y( iy ) )
289 IF ( alpha .NE. zero )
THEN
291 temp = abs( a( i, j ) )
292 symb_zero = symb_zero .AND.
293 $ ( x( j ) .EQ. zero .OR. temp .EQ. zero )
295 y( iy ) = y( iy ) + alpha*abs( x( j ) )*temp
299 IF ( .NOT.symb_zero )
300 $ y( iy ) = y( iy ) + sign( safe1, y( iy ) )
306 IF ( beta .EQ. zero )
THEN
309 ELSE IF ( y( iy ) .EQ. zero )
THEN
313 y( iy ) = beta * abs( y( iy ) )
315 IF ( alpha .NE. zero )
THEN
317 temp = abs( a( j, i ) )
318 symb_zero = symb_zero .AND.
319 $ ( x( j ) .EQ. zero .OR. temp .EQ. zero )
321 y( iy ) = y( iy ) + alpha*abs( x( j ) )*temp
325 IF ( .NOT.symb_zero )
326 $ y( iy ) = y( iy ) + sign( safe1, y( iy ) )
334 IF ( beta .EQ. zero )
THEN
337 ELSE IF ( y( iy ) .EQ. zero )
THEN
341 y( iy ) = beta * abs( y( iy ) )
343 IF ( alpha .NE. zero )
THEN
346 temp = abs( a( i, j ) )
347 symb_zero = symb_zero .AND.
348 $ ( x( jx ) .EQ. zero .OR. temp .EQ. zero )
350 y( iy ) = y( iy ) + alpha*abs( x( jx ) )*temp
356 $ y( iy ) = y( iy ) + sign( safe1, y( iy ) )
362 IF ( beta .EQ. zero )
THEN
365 ELSE IF ( y( iy ) .EQ. zero )
THEN
369 y( iy ) = beta * abs( y( iy ) )
371 IF ( alpha .NE. zero )
THEN
374 temp = abs( a( j, i ) )
375 symb_zero = symb_zero .AND.
376 $ ( x( jx ) .EQ. zero .OR. temp .EQ. zero )
378 y( iy ) = y( iy ) + alpha*abs( x( jx ) )*temp
384 $ y( iy ) = y( iy ) + sign( safe1, y( iy ) )