179 SUBROUTINE zla_syamv( UPLO, N, ALPHA, A, LDA, X, INCX, BETA, Y,
188 DOUBLE PRECISION alpha, beta
189 INTEGER incx, incy, lda, n
193 COMPLEX*16 a( lda, * ), x( * )
194 DOUBLE PRECISION y( * )
200 DOUBLE PRECISION one, zero
201 parameter( one = 1.0d+0, zero = 0.0d+0 )
205 DOUBLE PRECISION temp, safe1
206 INTEGER i, info, iy, j, jx, kx, ky
218 INTRINSIC max, abs, sign,
REAL, dimag
221 DOUBLE PRECISION cabs1
224 cabs1( zdum ) = abs( dble( zdum ) ) + abs( dimag( zdum ) )
231 IF ( uplo.NE.
ilauplo(
'U' ) .AND.
234 ELSE IF( n.LT.0 )
THEN
236 ELSE IF( lda.LT.max( 1, n ) )
THEN
238 ELSE IF( incx.EQ.0 )
THEN
240 ELSE IF( incy.EQ.0 )
THEN
244 CALL
xerbla(
'DSYMV ', info )
250 IF( ( n.EQ.0 ).OR.( ( alpha.EQ.zero ).AND.( beta.EQ.one ) ) )
258 kx = 1 - ( n - 1 )*incx
263 ky = 1 - ( n - 1 )*incy
269 safe1 =
dlamch(
'Safe minimum' )
279 IF ( incx.EQ.1 )
THEN
280 IF ( uplo .EQ.
ilauplo(
'U' ) )
THEN
282 IF ( beta .EQ. zero )
THEN
285 ELSE IF ( y( iy ) .EQ. zero )
THEN
289 y( iy ) = beta * abs( y( iy ) )
291 IF ( alpha .NE. zero )
THEN
293 temp = cabs1( a( j, i ) )
294 symb_zero = symb_zero .AND.
295 $ ( x( j ) .EQ. zero .OR. temp .EQ. zero )
297 y( iy ) = y( iy ) + alpha*cabs1( x( j ) )*temp
300 temp = cabs1( a( i, j ) )
301 symb_zero = symb_zero .AND.
302 $ ( x( j ) .EQ. zero .OR. temp .EQ. zero )
304 y( iy ) = y( iy ) + alpha*cabs1( x( j ) )*temp
308 IF ( .NOT.symb_zero )
309 $ y( iy ) = y( iy ) + sign( safe1, y( iy ) )
315 IF ( beta .EQ. zero )
THEN
318 ELSE IF ( y( iy ) .EQ. zero )
THEN
322 y( iy ) = beta * abs( y( iy ) )
324 IF ( alpha .NE. zero )
THEN
326 temp = cabs1( a( i, j ) )
327 symb_zero = symb_zero .AND.
328 $ ( x( j ) .EQ. zero .OR. temp .EQ. zero )
330 y( iy ) = y( iy ) + alpha*cabs1( x( j ) )*temp
333 temp = cabs1( a( j, i ) )
334 symb_zero = symb_zero .AND.
335 $ ( x( j ) .EQ. zero .OR. temp .EQ. zero )
337 y( iy ) = y( iy ) + alpha*cabs1( x( j ) )*temp
341 IF ( .NOT.symb_zero )
342 $ y( iy ) = y( iy ) + sign( safe1, y( iy ) )
348 IF ( uplo .EQ.
ilauplo(
'U' ) )
THEN
350 IF ( beta .EQ. zero )
THEN
353 ELSE IF ( y( iy ) .EQ. zero )
THEN
357 y( iy ) = beta * abs( y( iy ) )
360 IF ( alpha .NE. zero )
THEN
362 temp = cabs1( a( j, i ) )
363 symb_zero = symb_zero .AND.
364 $ ( x( j ) .EQ. zero .OR. temp .EQ. zero )
366 y( iy ) = y( iy ) + alpha*cabs1( x( jx ) )*temp
370 temp = cabs1( a( i, j ) )
371 symb_zero = symb_zero .AND.
372 $ ( x( j ) .EQ. zero .OR. temp .EQ. zero )
374 y( iy ) = y( iy ) + alpha*cabs1( x( jx ) )*temp
379 IF ( .NOT.symb_zero )
380 $ y( iy ) = y( iy ) + sign( safe1, y( iy ) )
386 IF ( beta .EQ. zero )
THEN
389 ELSE IF ( y( iy ) .EQ. zero )
THEN
393 y( iy ) = beta * abs( y( iy ) )
396 IF ( alpha .NE. zero )
THEN
398 temp = cabs1( a( i, j ) )
399 symb_zero = symb_zero .AND.
400 $ ( x( j ) .EQ. zero .OR. temp .EQ. zero )
402 y( iy ) = y( iy ) + alpha*cabs1( x( jx ) )*temp
406 temp = cabs1( a( j, i ) )
407 symb_zero = symb_zero .AND.
408 $ ( x( j ) .EQ. zero .OR. temp .EQ. zero )
410 y( iy ) = y( iy ) + alpha*cabs1( x( jx ) )*temp
415 IF ( .NOT.symb_zero )
416 $ y( iy ) = y( iy ) + sign( safe1, y( iy ) )