mirror of
https://github.com/amd/blis.git
synced 2026-05-11 01:30:00 +00:00
Migrated integer usage to stdint.h types.
Details: - Changed the way bli_type_defs.h defines integer types so that dim_t, inc_t, doff_t, etc. are all defined in terms of gint_t (general signed integer) or guint_t (general unsigned integer). - Renamed Fortran types fchar and fint to f77_char and f77_int. - Define f77_int as int64_t if a new configuration variable, BLIS_ENABLE_BLIS2BLAS_INT64, is defined, and int32_t otherwise. These types are defined in stdint.h, which is now included in blis.h. - Renamed "complex" type in f2c files to "singlecomplex" and typedef'ed in terms of scomplex. - Renamed "char" type in f2c files to "character" and typedef'ed in terms of char. - Updated bla_amax() wrappers so that the return type is defined directly as f77_int, rather than letting the prototype-generating macro decide the type. This was the only use of GENTFUNC2I/GENTPROT2I-related macros, so I removed them. Also, changed the body of the wrapper so that a gint_t is passed into abmaxv, which is THEN typecast to an f77_int before returning the value. - Updated f2c code that accessed .r and .i fields of complex and doublecomplex types so that they use .real and .imag instead (now that we are using scomplex and dcomplex).
This commit is contained in:
@@ -43,24 +43,24 @@
|
||||
-lf2c -lm (in that order)
|
||||
*/
|
||||
|
||||
/* Subroutine */ int PASTEF77(c,hpr2)(char *uplo, integer *n, complex *alpha, complex *
|
||||
x, integer *incx, complex *y, integer *incy, complex *ap)
|
||||
/* Subroutine */ int PASTEF77(c,hpr2)(character *uplo, integer *n, singlecomplex *alpha, singlecomplex *
|
||||
x, integer *incx, singlecomplex *y, integer *incy, singlecomplex *ap)
|
||||
{
|
||||
/* System generated locals */
|
||||
integer i__1, i__2, i__3, i__4, i__5, i__6;
|
||||
real r__1;
|
||||
complex q__1, q__2, q__3, q__4;
|
||||
singlecomplex q__1, q__2, q__3, q__4;
|
||||
|
||||
/* Builtin functions */
|
||||
void r_cnjg(complex *, complex *);
|
||||
void r_cnjg(singlecomplex *, singlecomplex *);
|
||||
|
||||
/* Local variables */
|
||||
integer info;
|
||||
complex temp1, temp2;
|
||||
singlecomplex temp1, temp2;
|
||||
integer i__, j, k;
|
||||
extern logical lsame_(char *, char *, ftnlen, ftnlen);
|
||||
extern logical lsame_(character *, character *, ftnlen, ftnlen);
|
||||
integer kk, ix, iy, jx = 0, jy = 0, kx = 0, ky = 0;
|
||||
extern /* Subroutine */ int xerbla_(char *, integer *, ftnlen);
|
||||
extern /* Subroutine */ int xerbla_(character *, integer *, ftnlen);
|
||||
|
||||
/* .. Scalar Arguments .. */
|
||||
/* .. Array Arguments .. */
|
||||
@@ -187,7 +187,7 @@
|
||||
|
||||
/* Quick return if possible. */
|
||||
|
||||
if (*n == 0 || (alpha->r == 0.f && alpha->i == 0.f)) {
|
||||
if (*n == 0 || (alpha->real == 0.f && alpha->imag == 0.f)) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -222,56 +222,56 @@
|
||||
for (j = 1; j <= i__1; ++j) {
|
||||
i__2 = j;
|
||||
i__3 = j;
|
||||
if (x[i__2].r != 0.f || x[i__2].i != 0.f || (y[i__3].r != 0.f
|
||||
|| y[i__3].i != 0.f)) {
|
||||
if (x[i__2].real != 0.f || x[i__2].imag != 0.f || (y[i__3].real != 0.f
|
||||
|| y[i__3].imag != 0.f)) {
|
||||
r_cnjg(&q__2, &y[j]);
|
||||
q__1.r = alpha->r * q__2.r - alpha->i * q__2.i, q__1.i =
|
||||
alpha->r * q__2.i + alpha->i * q__2.r;
|
||||
temp1.r = q__1.r, temp1.i = q__1.i;
|
||||
q__1.real = alpha->real * q__2.real - alpha->imag * q__2.imag, q__1.imag =
|
||||
alpha->real * q__2.imag + alpha->imag * q__2.real;
|
||||
temp1.real = q__1.real, temp1.imag = q__1.imag;
|
||||
i__2 = j;
|
||||
q__2.r = alpha->r * x[i__2].r - alpha->i * x[i__2].i,
|
||||
q__2.i = alpha->r * x[i__2].i + alpha->i * x[i__2]
|
||||
.r;
|
||||
q__2.real = alpha->real * x[i__2].real - alpha->imag * x[i__2].imag,
|
||||
q__2.imag = alpha->real * x[i__2].imag + alpha->imag * x[i__2]
|
||||
.real;
|
||||
r_cnjg(&q__1, &q__2);
|
||||
temp2.r = q__1.r, temp2.i = q__1.i;
|
||||
temp2.real = q__1.real, temp2.imag = q__1.imag;
|
||||
k = kk;
|
||||
i__2 = j - 1;
|
||||
for (i__ = 1; i__ <= i__2; ++i__) {
|
||||
i__3 = k;
|
||||
i__4 = k;
|
||||
i__5 = i__;
|
||||
q__3.r = x[i__5].r * temp1.r - x[i__5].i * temp1.i,
|
||||
q__3.i = x[i__5].r * temp1.i + x[i__5].i *
|
||||
temp1.r;
|
||||
q__2.r = ap[i__4].r + q__3.r, q__2.i = ap[i__4].i +
|
||||
q__3.i;
|
||||
q__3.real = x[i__5].real * temp1.real - x[i__5].imag * temp1.imag,
|
||||
q__3.imag = x[i__5].real * temp1.imag + x[i__5].imag *
|
||||
temp1.real;
|
||||
q__2.real = ap[i__4].real + q__3.real, q__2.imag = ap[i__4].imag +
|
||||
q__3.imag;
|
||||
i__6 = i__;
|
||||
q__4.r = y[i__6].r * temp2.r - y[i__6].i * temp2.i,
|
||||
q__4.i = y[i__6].r * temp2.i + y[i__6].i *
|
||||
temp2.r;
|
||||
q__1.r = q__2.r + q__4.r, q__1.i = q__2.i + q__4.i;
|
||||
ap[i__3].r = q__1.r, ap[i__3].i = q__1.i;
|
||||
q__4.real = y[i__6].real * temp2.real - y[i__6].imag * temp2.imag,
|
||||
q__4.imag = y[i__6].real * temp2.imag + y[i__6].imag *
|
||||
temp2.real;
|
||||
q__1.real = q__2.real + q__4.real, q__1.imag = q__2.imag + q__4.imag;
|
||||
ap[i__3].real = q__1.real, ap[i__3].imag = q__1.imag;
|
||||
++k;
|
||||
/* L10: */
|
||||
}
|
||||
i__2 = kk + j - 1;
|
||||
i__3 = kk + j - 1;
|
||||
i__4 = j;
|
||||
q__2.r = x[i__4].r * temp1.r - x[i__4].i * temp1.i,
|
||||
q__2.i = x[i__4].r * temp1.i + x[i__4].i *
|
||||
temp1.r;
|
||||
q__2.real = x[i__4].real * temp1.real - x[i__4].imag * temp1.imag,
|
||||
q__2.imag = x[i__4].real * temp1.imag + x[i__4].imag *
|
||||
temp1.real;
|
||||
i__5 = j;
|
||||
q__3.r = y[i__5].r * temp2.r - y[i__5].i * temp2.i,
|
||||
q__3.i = y[i__5].r * temp2.i + y[i__5].i *
|
||||
temp2.r;
|
||||
q__1.r = q__2.r + q__3.r, q__1.i = q__2.i + q__3.i;
|
||||
r__1 = ap[i__3].r + q__1.r;
|
||||
ap[i__2].r = r__1, ap[i__2].i = 0.f;
|
||||
q__3.real = y[i__5].real * temp2.real - y[i__5].imag * temp2.imag,
|
||||
q__3.imag = y[i__5].real * temp2.imag + y[i__5].imag *
|
||||
temp2.real;
|
||||
q__1.real = q__2.real + q__3.real, q__1.imag = q__2.imag + q__3.imag;
|
||||
r__1 = ap[i__3].real + q__1.real;
|
||||
ap[i__2].real = r__1, ap[i__2].imag = 0.f;
|
||||
} else {
|
||||
i__2 = kk + j - 1;
|
||||
i__3 = kk + j - 1;
|
||||
r__1 = ap[i__3].r;
|
||||
ap[i__2].r = r__1, ap[i__2].i = 0.f;
|
||||
r__1 = ap[i__3].real;
|
||||
ap[i__2].real = r__1, ap[i__2].imag = 0.f;
|
||||
}
|
||||
kk += j;
|
||||
/* L20: */
|
||||
@@ -281,18 +281,18 @@
|
||||
for (j = 1; j <= i__1; ++j) {
|
||||
i__2 = jx;
|
||||
i__3 = jy;
|
||||
if (x[i__2].r != 0.f || x[i__2].i != 0.f || (y[i__3].r != 0.f
|
||||
|| y[i__3].i != 0.f)) {
|
||||
if (x[i__2].real != 0.f || x[i__2].imag != 0.f || (y[i__3].real != 0.f
|
||||
|| y[i__3].imag != 0.f)) {
|
||||
r_cnjg(&q__2, &y[jy]);
|
||||
q__1.r = alpha->r * q__2.r - alpha->i * q__2.i, q__1.i =
|
||||
alpha->r * q__2.i + alpha->i * q__2.r;
|
||||
temp1.r = q__1.r, temp1.i = q__1.i;
|
||||
q__1.real = alpha->real * q__2.real - alpha->imag * q__2.imag, q__1.imag =
|
||||
alpha->real * q__2.imag + alpha->imag * q__2.real;
|
||||
temp1.real = q__1.real, temp1.imag = q__1.imag;
|
||||
i__2 = jx;
|
||||
q__2.r = alpha->r * x[i__2].r - alpha->i * x[i__2].i,
|
||||
q__2.i = alpha->r * x[i__2].i + alpha->i * x[i__2]
|
||||
.r;
|
||||
q__2.real = alpha->real * x[i__2].real - alpha->imag * x[i__2].imag,
|
||||
q__2.imag = alpha->real * x[i__2].imag + alpha->imag * x[i__2]
|
||||
.real;
|
||||
r_cnjg(&q__1, &q__2);
|
||||
temp2.r = q__1.r, temp2.i = q__1.i;
|
||||
temp2.real = q__1.real, temp2.imag = q__1.imag;
|
||||
ix = kx;
|
||||
iy = ky;
|
||||
i__2 = kk + j - 2;
|
||||
@@ -300,17 +300,17 @@
|
||||
i__3 = k;
|
||||
i__4 = k;
|
||||
i__5 = ix;
|
||||
q__3.r = x[i__5].r * temp1.r - x[i__5].i * temp1.i,
|
||||
q__3.i = x[i__5].r * temp1.i + x[i__5].i *
|
||||
temp1.r;
|
||||
q__2.r = ap[i__4].r + q__3.r, q__2.i = ap[i__4].i +
|
||||
q__3.i;
|
||||
q__3.real = x[i__5].real * temp1.real - x[i__5].imag * temp1.imag,
|
||||
q__3.imag = x[i__5].real * temp1.imag + x[i__5].imag *
|
||||
temp1.real;
|
||||
q__2.real = ap[i__4].real + q__3.real, q__2.imag = ap[i__4].imag +
|
||||
q__3.imag;
|
||||
i__6 = iy;
|
||||
q__4.r = y[i__6].r * temp2.r - y[i__6].i * temp2.i,
|
||||
q__4.i = y[i__6].r * temp2.i + y[i__6].i *
|
||||
temp2.r;
|
||||
q__1.r = q__2.r + q__4.r, q__1.i = q__2.i + q__4.i;
|
||||
ap[i__3].r = q__1.r, ap[i__3].i = q__1.i;
|
||||
q__4.real = y[i__6].real * temp2.real - y[i__6].imag * temp2.imag,
|
||||
q__4.imag = y[i__6].real * temp2.imag + y[i__6].imag *
|
||||
temp2.real;
|
||||
q__1.real = q__2.real + q__4.real, q__1.imag = q__2.imag + q__4.imag;
|
||||
ap[i__3].real = q__1.real, ap[i__3].imag = q__1.imag;
|
||||
ix += *incx;
|
||||
iy += *incy;
|
||||
/* L30: */
|
||||
@@ -318,21 +318,21 @@
|
||||
i__2 = kk + j - 1;
|
||||
i__3 = kk + j - 1;
|
||||
i__4 = jx;
|
||||
q__2.r = x[i__4].r * temp1.r - x[i__4].i * temp1.i,
|
||||
q__2.i = x[i__4].r * temp1.i + x[i__4].i *
|
||||
temp1.r;
|
||||
q__2.real = x[i__4].real * temp1.real - x[i__4].imag * temp1.imag,
|
||||
q__2.imag = x[i__4].real * temp1.imag + x[i__4].imag *
|
||||
temp1.real;
|
||||
i__5 = jy;
|
||||
q__3.r = y[i__5].r * temp2.r - y[i__5].i * temp2.i,
|
||||
q__3.i = y[i__5].r * temp2.i + y[i__5].i *
|
||||
temp2.r;
|
||||
q__1.r = q__2.r + q__3.r, q__1.i = q__2.i + q__3.i;
|
||||
r__1 = ap[i__3].r + q__1.r;
|
||||
ap[i__2].r = r__1, ap[i__2].i = 0.f;
|
||||
q__3.real = y[i__5].real * temp2.real - y[i__5].imag * temp2.imag,
|
||||
q__3.imag = y[i__5].real * temp2.imag + y[i__5].imag *
|
||||
temp2.real;
|
||||
q__1.real = q__2.real + q__3.real, q__1.imag = q__2.imag + q__3.imag;
|
||||
r__1 = ap[i__3].real + q__1.real;
|
||||
ap[i__2].real = r__1, ap[i__2].imag = 0.f;
|
||||
} else {
|
||||
i__2 = kk + j - 1;
|
||||
i__3 = kk + j - 1;
|
||||
r__1 = ap[i__3].r;
|
||||
ap[i__2].r = r__1, ap[i__2].i = 0.f;
|
||||
r__1 = ap[i__3].real;
|
||||
ap[i__2].real = r__1, ap[i__2].imag = 0.f;
|
||||
}
|
||||
jx += *incx;
|
||||
jy += *incy;
|
||||
@@ -349,56 +349,56 @@
|
||||
for (j = 1; j <= i__1; ++j) {
|
||||
i__2 = j;
|
||||
i__3 = j;
|
||||
if (x[i__2].r != 0.f || x[i__2].i != 0.f || (y[i__3].r != 0.f
|
||||
|| y[i__3].i != 0.f)) {
|
||||
if (x[i__2].real != 0.f || x[i__2].imag != 0.f || (y[i__3].real != 0.f
|
||||
|| y[i__3].imag != 0.f)) {
|
||||
r_cnjg(&q__2, &y[j]);
|
||||
q__1.r = alpha->r * q__2.r - alpha->i * q__2.i, q__1.i =
|
||||
alpha->r * q__2.i + alpha->i * q__2.r;
|
||||
temp1.r = q__1.r, temp1.i = q__1.i;
|
||||
q__1.real = alpha->real * q__2.real - alpha->imag * q__2.imag, q__1.imag =
|
||||
alpha->real * q__2.imag + alpha->imag * q__2.real;
|
||||
temp1.real = q__1.real, temp1.imag = q__1.imag;
|
||||
i__2 = j;
|
||||
q__2.r = alpha->r * x[i__2].r - alpha->i * x[i__2].i,
|
||||
q__2.i = alpha->r * x[i__2].i + alpha->i * x[i__2]
|
||||
.r;
|
||||
q__2.real = alpha->real * x[i__2].real - alpha->imag * x[i__2].imag,
|
||||
q__2.imag = alpha->real * x[i__2].imag + alpha->imag * x[i__2]
|
||||
.real;
|
||||
r_cnjg(&q__1, &q__2);
|
||||
temp2.r = q__1.r, temp2.i = q__1.i;
|
||||
temp2.real = q__1.real, temp2.imag = q__1.imag;
|
||||
i__2 = kk;
|
||||
i__3 = kk;
|
||||
i__4 = j;
|
||||
q__2.r = x[i__4].r * temp1.r - x[i__4].i * temp1.i,
|
||||
q__2.i = x[i__4].r * temp1.i + x[i__4].i *
|
||||
temp1.r;
|
||||
q__2.real = x[i__4].real * temp1.real - x[i__4].imag * temp1.imag,
|
||||
q__2.imag = x[i__4].real * temp1.imag + x[i__4].imag *
|
||||
temp1.real;
|
||||
i__5 = j;
|
||||
q__3.r = y[i__5].r * temp2.r - y[i__5].i * temp2.i,
|
||||
q__3.i = y[i__5].r * temp2.i + y[i__5].i *
|
||||
temp2.r;
|
||||
q__1.r = q__2.r + q__3.r, q__1.i = q__2.i + q__3.i;
|
||||
r__1 = ap[i__3].r + q__1.r;
|
||||
ap[i__2].r = r__1, ap[i__2].i = 0.f;
|
||||
q__3.real = y[i__5].real * temp2.real - y[i__5].imag * temp2.imag,
|
||||
q__3.imag = y[i__5].real * temp2.imag + y[i__5].imag *
|
||||
temp2.real;
|
||||
q__1.real = q__2.real + q__3.real, q__1.imag = q__2.imag + q__3.imag;
|
||||
r__1 = ap[i__3].real + q__1.real;
|
||||
ap[i__2].real = r__1, ap[i__2].imag = 0.f;
|
||||
k = kk + 1;
|
||||
i__2 = *n;
|
||||
for (i__ = j + 1; i__ <= i__2; ++i__) {
|
||||
i__3 = k;
|
||||
i__4 = k;
|
||||
i__5 = i__;
|
||||
q__3.r = x[i__5].r * temp1.r - x[i__5].i * temp1.i,
|
||||
q__3.i = x[i__5].r * temp1.i + x[i__5].i *
|
||||
temp1.r;
|
||||
q__2.r = ap[i__4].r + q__3.r, q__2.i = ap[i__4].i +
|
||||
q__3.i;
|
||||
q__3.real = x[i__5].real * temp1.real - x[i__5].imag * temp1.imag,
|
||||
q__3.imag = x[i__5].real * temp1.imag + x[i__5].imag *
|
||||
temp1.real;
|
||||
q__2.real = ap[i__4].real + q__3.real, q__2.imag = ap[i__4].imag +
|
||||
q__3.imag;
|
||||
i__6 = i__;
|
||||
q__4.r = y[i__6].r * temp2.r - y[i__6].i * temp2.i,
|
||||
q__4.i = y[i__6].r * temp2.i + y[i__6].i *
|
||||
temp2.r;
|
||||
q__1.r = q__2.r + q__4.r, q__1.i = q__2.i + q__4.i;
|
||||
ap[i__3].r = q__1.r, ap[i__3].i = q__1.i;
|
||||
q__4.real = y[i__6].real * temp2.real - y[i__6].imag * temp2.imag,
|
||||
q__4.imag = y[i__6].real * temp2.imag + y[i__6].imag *
|
||||
temp2.real;
|
||||
q__1.real = q__2.real + q__4.real, q__1.imag = q__2.imag + q__4.imag;
|
||||
ap[i__3].real = q__1.real, ap[i__3].imag = q__1.imag;
|
||||
++k;
|
||||
/* L50: */
|
||||
}
|
||||
} else {
|
||||
i__2 = kk;
|
||||
i__3 = kk;
|
||||
r__1 = ap[i__3].r;
|
||||
ap[i__2].r = r__1, ap[i__2].i = 0.f;
|
||||
r__1 = ap[i__3].real;
|
||||
ap[i__2].real = r__1, ap[i__2].imag = 0.f;
|
||||
}
|
||||
kk = kk + *n - j + 1;
|
||||
/* L60: */
|
||||
@@ -408,31 +408,31 @@
|
||||
for (j = 1; j <= i__1; ++j) {
|
||||
i__2 = jx;
|
||||
i__3 = jy;
|
||||
if (x[i__2].r != 0.f || x[i__2].i != 0.f || (y[i__3].r != 0.f
|
||||
|| y[i__3].i != 0.f)) {
|
||||
if (x[i__2].real != 0.f || x[i__2].imag != 0.f || (y[i__3].real != 0.f
|
||||
|| y[i__3].imag != 0.f)) {
|
||||
r_cnjg(&q__2, &y[jy]);
|
||||
q__1.r = alpha->r * q__2.r - alpha->i * q__2.i, q__1.i =
|
||||
alpha->r * q__2.i + alpha->i * q__2.r;
|
||||
temp1.r = q__1.r, temp1.i = q__1.i;
|
||||
q__1.real = alpha->real * q__2.real - alpha->imag * q__2.imag, q__1.imag =
|
||||
alpha->real * q__2.imag + alpha->imag * q__2.real;
|
||||
temp1.real = q__1.real, temp1.imag = q__1.imag;
|
||||
i__2 = jx;
|
||||
q__2.r = alpha->r * x[i__2].r - alpha->i * x[i__2].i,
|
||||
q__2.i = alpha->r * x[i__2].i + alpha->i * x[i__2]
|
||||
.r;
|
||||
q__2.real = alpha->real * x[i__2].real - alpha->imag * x[i__2].imag,
|
||||
q__2.imag = alpha->real * x[i__2].imag + alpha->imag * x[i__2]
|
||||
.real;
|
||||
r_cnjg(&q__1, &q__2);
|
||||
temp2.r = q__1.r, temp2.i = q__1.i;
|
||||
temp2.real = q__1.real, temp2.imag = q__1.imag;
|
||||
i__2 = kk;
|
||||
i__3 = kk;
|
||||
i__4 = jx;
|
||||
q__2.r = x[i__4].r * temp1.r - x[i__4].i * temp1.i,
|
||||
q__2.i = x[i__4].r * temp1.i + x[i__4].i *
|
||||
temp1.r;
|
||||
q__2.real = x[i__4].real * temp1.real - x[i__4].imag * temp1.imag,
|
||||
q__2.imag = x[i__4].real * temp1.imag + x[i__4].imag *
|
||||
temp1.real;
|
||||
i__5 = jy;
|
||||
q__3.r = y[i__5].r * temp2.r - y[i__5].i * temp2.i,
|
||||
q__3.i = y[i__5].r * temp2.i + y[i__5].i *
|
||||
temp2.r;
|
||||
q__1.r = q__2.r + q__3.r, q__1.i = q__2.i + q__3.i;
|
||||
r__1 = ap[i__3].r + q__1.r;
|
||||
ap[i__2].r = r__1, ap[i__2].i = 0.f;
|
||||
q__3.real = y[i__5].real * temp2.real - y[i__5].imag * temp2.imag,
|
||||
q__3.imag = y[i__5].real * temp2.imag + y[i__5].imag *
|
||||
temp2.real;
|
||||
q__1.real = q__2.real + q__3.real, q__1.imag = q__2.imag + q__3.imag;
|
||||
r__1 = ap[i__3].real + q__1.real;
|
||||
ap[i__2].real = r__1, ap[i__2].imag = 0.f;
|
||||
ix = jx;
|
||||
iy = jy;
|
||||
i__2 = kk + *n - j;
|
||||
@@ -442,24 +442,24 @@
|
||||
i__3 = k;
|
||||
i__4 = k;
|
||||
i__5 = ix;
|
||||
q__3.r = x[i__5].r * temp1.r - x[i__5].i * temp1.i,
|
||||
q__3.i = x[i__5].r * temp1.i + x[i__5].i *
|
||||
temp1.r;
|
||||
q__2.r = ap[i__4].r + q__3.r, q__2.i = ap[i__4].i +
|
||||
q__3.i;
|
||||
q__3.real = x[i__5].real * temp1.real - x[i__5].imag * temp1.imag,
|
||||
q__3.imag = x[i__5].real * temp1.imag + x[i__5].imag *
|
||||
temp1.real;
|
||||
q__2.real = ap[i__4].real + q__3.real, q__2.imag = ap[i__4].imag +
|
||||
q__3.imag;
|
||||
i__6 = iy;
|
||||
q__4.r = y[i__6].r * temp2.r - y[i__6].i * temp2.i,
|
||||
q__4.i = y[i__6].r * temp2.i + y[i__6].i *
|
||||
temp2.r;
|
||||
q__1.r = q__2.r + q__4.r, q__1.i = q__2.i + q__4.i;
|
||||
ap[i__3].r = q__1.r, ap[i__3].i = q__1.i;
|
||||
q__4.real = y[i__6].real * temp2.real - y[i__6].imag * temp2.imag,
|
||||
q__4.imag = y[i__6].real * temp2.imag + y[i__6].imag *
|
||||
temp2.real;
|
||||
q__1.real = q__2.real + q__4.real, q__1.imag = q__2.imag + q__4.imag;
|
||||
ap[i__3].real = q__1.real, ap[i__3].imag = q__1.imag;
|
||||
/* L70: */
|
||||
}
|
||||
} else {
|
||||
i__2 = kk;
|
||||
i__3 = kk;
|
||||
r__1 = ap[i__3].r;
|
||||
ap[i__2].r = r__1, ap[i__2].i = 0.f;
|
||||
r__1 = ap[i__3].real;
|
||||
ap[i__2].real = r__1, ap[i__2].imag = 0.f;
|
||||
}
|
||||
jx += *incx;
|
||||
jy += *incy;
|
||||
@@ -480,7 +480,7 @@
|
||||
-lf2c -lm (in that order)
|
||||
*/
|
||||
|
||||
/* Subroutine */ int PASTEF77(z,hpr2)(char *uplo, integer *n, doublecomplex *alpha,
|
||||
/* Subroutine */ int PASTEF77(z,hpr2)(character *uplo, integer *n, doublecomplex *alpha,
|
||||
doublecomplex *x, integer *incx, doublecomplex *y, integer *incy,
|
||||
doublecomplex *ap)
|
||||
{
|
||||
@@ -496,9 +496,9 @@
|
||||
integer info;
|
||||
doublecomplex temp1, temp2;
|
||||
integer i__, j, k;
|
||||
extern logical lsame_(char *, char *, ftnlen, ftnlen);
|
||||
extern logical lsame_(character *, character *, ftnlen, ftnlen);
|
||||
integer kk, ix, iy, jx = 0, jy = 0, kx = 0, ky = 0;
|
||||
extern /* Subroutine */ int xerbla_(char *, integer *, ftnlen);
|
||||
extern /* Subroutine */ int xerbla_(character *, integer *, ftnlen);
|
||||
|
||||
/* .. Scalar Arguments .. */
|
||||
/* .. Array Arguments .. */
|
||||
@@ -625,7 +625,7 @@
|
||||
|
||||
/* Quick return if possible. */
|
||||
|
||||
if (*n == 0 || (alpha->r == 0. && alpha->i == 0.)) {
|
||||
if (*n == 0 || (alpha->real == 0. && alpha->imag == 0.)) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -660,56 +660,56 @@
|
||||
for (j = 1; j <= i__1; ++j) {
|
||||
i__2 = j;
|
||||
i__3 = j;
|
||||
if (x[i__2].r != 0. || x[i__2].i != 0. || (y[i__3].r != 0. ||
|
||||
y[i__3].i != 0.)) {
|
||||
if (x[i__2].real != 0. || x[i__2].imag != 0. || (y[i__3].real != 0. ||
|
||||
y[i__3].imag != 0.)) {
|
||||
d_cnjg(&z__2, &y[j]);
|
||||
z__1.r = alpha->r * z__2.r - alpha->i * z__2.i, z__1.i =
|
||||
alpha->r * z__2.i + alpha->i * z__2.r;
|
||||
temp1.r = z__1.r, temp1.i = z__1.i;
|
||||
z__1.real = alpha->real * z__2.real - alpha->imag * z__2.imag, z__1.imag =
|
||||
alpha->real * z__2.imag + alpha->imag * z__2.real;
|
||||
temp1.real = z__1.real, temp1.imag = z__1.imag;
|
||||
i__2 = j;
|
||||
z__2.r = alpha->r * x[i__2].r - alpha->i * x[i__2].i,
|
||||
z__2.i = alpha->r * x[i__2].i + alpha->i * x[i__2]
|
||||
.r;
|
||||
z__2.real = alpha->real * x[i__2].real - alpha->imag * x[i__2].imag,
|
||||
z__2.imag = alpha->real * x[i__2].imag + alpha->imag * x[i__2]
|
||||
.real;
|
||||
d_cnjg(&z__1, &z__2);
|
||||
temp2.r = z__1.r, temp2.i = z__1.i;
|
||||
temp2.real = z__1.real, temp2.imag = z__1.imag;
|
||||
k = kk;
|
||||
i__2 = j - 1;
|
||||
for (i__ = 1; i__ <= i__2; ++i__) {
|
||||
i__3 = k;
|
||||
i__4 = k;
|
||||
i__5 = i__;
|
||||
z__3.r = x[i__5].r * temp1.r - x[i__5].i * temp1.i,
|
||||
z__3.i = x[i__5].r * temp1.i + x[i__5].i *
|
||||
temp1.r;
|
||||
z__2.r = ap[i__4].r + z__3.r, z__2.i = ap[i__4].i +
|
||||
z__3.i;
|
||||
z__3.real = x[i__5].real * temp1.real - x[i__5].imag * temp1.imag,
|
||||
z__3.imag = x[i__5].real * temp1.imag + x[i__5].imag *
|
||||
temp1.real;
|
||||
z__2.real = ap[i__4].real + z__3.real, z__2.imag = ap[i__4].imag +
|
||||
z__3.imag;
|
||||
i__6 = i__;
|
||||
z__4.r = y[i__6].r * temp2.r - y[i__6].i * temp2.i,
|
||||
z__4.i = y[i__6].r * temp2.i + y[i__6].i *
|
||||
temp2.r;
|
||||
z__1.r = z__2.r + z__4.r, z__1.i = z__2.i + z__4.i;
|
||||
ap[i__3].r = z__1.r, ap[i__3].i = z__1.i;
|
||||
z__4.real = y[i__6].real * temp2.real - y[i__6].imag * temp2.imag,
|
||||
z__4.imag = y[i__6].real * temp2.imag + y[i__6].imag *
|
||||
temp2.real;
|
||||
z__1.real = z__2.real + z__4.real, z__1.imag = z__2.imag + z__4.imag;
|
||||
ap[i__3].real = z__1.real, ap[i__3].imag = z__1.imag;
|
||||
++k;
|
||||
/* L10: */
|
||||
}
|
||||
i__2 = kk + j - 1;
|
||||
i__3 = kk + j - 1;
|
||||
i__4 = j;
|
||||
z__2.r = x[i__4].r * temp1.r - x[i__4].i * temp1.i,
|
||||
z__2.i = x[i__4].r * temp1.i + x[i__4].i *
|
||||
temp1.r;
|
||||
z__2.real = x[i__4].real * temp1.real - x[i__4].imag * temp1.imag,
|
||||
z__2.imag = x[i__4].real * temp1.imag + x[i__4].imag *
|
||||
temp1.real;
|
||||
i__5 = j;
|
||||
z__3.r = y[i__5].r * temp2.r - y[i__5].i * temp2.i,
|
||||
z__3.i = y[i__5].r * temp2.i + y[i__5].i *
|
||||
temp2.r;
|
||||
z__1.r = z__2.r + z__3.r, z__1.i = z__2.i + z__3.i;
|
||||
d__1 = ap[i__3].r + z__1.r;
|
||||
ap[i__2].r = d__1, ap[i__2].i = 0.;
|
||||
z__3.real = y[i__5].real * temp2.real - y[i__5].imag * temp2.imag,
|
||||
z__3.imag = y[i__5].real * temp2.imag + y[i__5].imag *
|
||||
temp2.real;
|
||||
z__1.real = z__2.real + z__3.real, z__1.imag = z__2.imag + z__3.imag;
|
||||
d__1 = ap[i__3].real + z__1.real;
|
||||
ap[i__2].real = d__1, ap[i__2].imag = 0.;
|
||||
} else {
|
||||
i__2 = kk + j - 1;
|
||||
i__3 = kk + j - 1;
|
||||
d__1 = ap[i__3].r;
|
||||
ap[i__2].r = d__1, ap[i__2].i = 0.;
|
||||
d__1 = ap[i__3].real;
|
||||
ap[i__2].real = d__1, ap[i__2].imag = 0.;
|
||||
}
|
||||
kk += j;
|
||||
/* L20: */
|
||||
@@ -719,18 +719,18 @@
|
||||
for (j = 1; j <= i__1; ++j) {
|
||||
i__2 = jx;
|
||||
i__3 = jy;
|
||||
if (x[i__2].r != 0. || x[i__2].i != 0. || (y[i__3].r != 0. ||
|
||||
y[i__3].i != 0.)) {
|
||||
if (x[i__2].real != 0. || x[i__2].imag != 0. || (y[i__3].real != 0. ||
|
||||
y[i__3].imag != 0.)) {
|
||||
d_cnjg(&z__2, &y[jy]);
|
||||
z__1.r = alpha->r * z__2.r - alpha->i * z__2.i, z__1.i =
|
||||
alpha->r * z__2.i + alpha->i * z__2.r;
|
||||
temp1.r = z__1.r, temp1.i = z__1.i;
|
||||
z__1.real = alpha->real * z__2.real - alpha->imag * z__2.imag, z__1.imag =
|
||||
alpha->real * z__2.imag + alpha->imag * z__2.real;
|
||||
temp1.real = z__1.real, temp1.imag = z__1.imag;
|
||||
i__2 = jx;
|
||||
z__2.r = alpha->r * x[i__2].r - alpha->i * x[i__2].i,
|
||||
z__2.i = alpha->r * x[i__2].i + alpha->i * x[i__2]
|
||||
.r;
|
||||
z__2.real = alpha->real * x[i__2].real - alpha->imag * x[i__2].imag,
|
||||
z__2.imag = alpha->real * x[i__2].imag + alpha->imag * x[i__2]
|
||||
.real;
|
||||
d_cnjg(&z__1, &z__2);
|
||||
temp2.r = z__1.r, temp2.i = z__1.i;
|
||||
temp2.real = z__1.real, temp2.imag = z__1.imag;
|
||||
ix = kx;
|
||||
iy = ky;
|
||||
i__2 = kk + j - 2;
|
||||
@@ -738,17 +738,17 @@
|
||||
i__3 = k;
|
||||
i__4 = k;
|
||||
i__5 = ix;
|
||||
z__3.r = x[i__5].r * temp1.r - x[i__5].i * temp1.i,
|
||||
z__3.i = x[i__5].r * temp1.i + x[i__5].i *
|
||||
temp1.r;
|
||||
z__2.r = ap[i__4].r + z__3.r, z__2.i = ap[i__4].i +
|
||||
z__3.i;
|
||||
z__3.real = x[i__5].real * temp1.real - x[i__5].imag * temp1.imag,
|
||||
z__3.imag = x[i__5].real * temp1.imag + x[i__5].imag *
|
||||
temp1.real;
|
||||
z__2.real = ap[i__4].real + z__3.real, z__2.imag = ap[i__4].imag +
|
||||
z__3.imag;
|
||||
i__6 = iy;
|
||||
z__4.r = y[i__6].r * temp2.r - y[i__6].i * temp2.i,
|
||||
z__4.i = y[i__6].r * temp2.i + y[i__6].i *
|
||||
temp2.r;
|
||||
z__1.r = z__2.r + z__4.r, z__1.i = z__2.i + z__4.i;
|
||||
ap[i__3].r = z__1.r, ap[i__3].i = z__1.i;
|
||||
z__4.real = y[i__6].real * temp2.real - y[i__6].imag * temp2.imag,
|
||||
z__4.imag = y[i__6].real * temp2.imag + y[i__6].imag *
|
||||
temp2.real;
|
||||
z__1.real = z__2.real + z__4.real, z__1.imag = z__2.imag + z__4.imag;
|
||||
ap[i__3].real = z__1.real, ap[i__3].imag = z__1.imag;
|
||||
ix += *incx;
|
||||
iy += *incy;
|
||||
/* L30: */
|
||||
@@ -756,21 +756,21 @@
|
||||
i__2 = kk + j - 1;
|
||||
i__3 = kk + j - 1;
|
||||
i__4 = jx;
|
||||
z__2.r = x[i__4].r * temp1.r - x[i__4].i * temp1.i,
|
||||
z__2.i = x[i__4].r * temp1.i + x[i__4].i *
|
||||
temp1.r;
|
||||
z__2.real = x[i__4].real * temp1.real - x[i__4].imag * temp1.imag,
|
||||
z__2.imag = x[i__4].real * temp1.imag + x[i__4].imag *
|
||||
temp1.real;
|
||||
i__5 = jy;
|
||||
z__3.r = y[i__5].r * temp2.r - y[i__5].i * temp2.i,
|
||||
z__3.i = y[i__5].r * temp2.i + y[i__5].i *
|
||||
temp2.r;
|
||||
z__1.r = z__2.r + z__3.r, z__1.i = z__2.i + z__3.i;
|
||||
d__1 = ap[i__3].r + z__1.r;
|
||||
ap[i__2].r = d__1, ap[i__2].i = 0.;
|
||||
z__3.real = y[i__5].real * temp2.real - y[i__5].imag * temp2.imag,
|
||||
z__3.imag = y[i__5].real * temp2.imag + y[i__5].imag *
|
||||
temp2.real;
|
||||
z__1.real = z__2.real + z__3.real, z__1.imag = z__2.imag + z__3.imag;
|
||||
d__1 = ap[i__3].real + z__1.real;
|
||||
ap[i__2].real = d__1, ap[i__2].imag = 0.;
|
||||
} else {
|
||||
i__2 = kk + j - 1;
|
||||
i__3 = kk + j - 1;
|
||||
d__1 = ap[i__3].r;
|
||||
ap[i__2].r = d__1, ap[i__2].i = 0.;
|
||||
d__1 = ap[i__3].real;
|
||||
ap[i__2].real = d__1, ap[i__2].imag = 0.;
|
||||
}
|
||||
jx += *incx;
|
||||
jy += *incy;
|
||||
@@ -787,56 +787,56 @@
|
||||
for (j = 1; j <= i__1; ++j) {
|
||||
i__2 = j;
|
||||
i__3 = j;
|
||||
if (x[i__2].r != 0. || x[i__2].i != 0. || (y[i__3].r != 0. ||
|
||||
y[i__3].i != 0.)) {
|
||||
if (x[i__2].real != 0. || x[i__2].imag != 0. || (y[i__3].real != 0. ||
|
||||
y[i__3].imag != 0.)) {
|
||||
d_cnjg(&z__2, &y[j]);
|
||||
z__1.r = alpha->r * z__2.r - alpha->i * z__2.i, z__1.i =
|
||||
alpha->r * z__2.i + alpha->i * z__2.r;
|
||||
temp1.r = z__1.r, temp1.i = z__1.i;
|
||||
z__1.real = alpha->real * z__2.real - alpha->imag * z__2.imag, z__1.imag =
|
||||
alpha->real * z__2.imag + alpha->imag * z__2.real;
|
||||
temp1.real = z__1.real, temp1.imag = z__1.imag;
|
||||
i__2 = j;
|
||||
z__2.r = alpha->r * x[i__2].r - alpha->i * x[i__2].i,
|
||||
z__2.i = alpha->r * x[i__2].i + alpha->i * x[i__2]
|
||||
.r;
|
||||
z__2.real = alpha->real * x[i__2].real - alpha->imag * x[i__2].imag,
|
||||
z__2.imag = alpha->real * x[i__2].imag + alpha->imag * x[i__2]
|
||||
.real;
|
||||
d_cnjg(&z__1, &z__2);
|
||||
temp2.r = z__1.r, temp2.i = z__1.i;
|
||||
temp2.real = z__1.real, temp2.imag = z__1.imag;
|
||||
i__2 = kk;
|
||||
i__3 = kk;
|
||||
i__4 = j;
|
||||
z__2.r = x[i__4].r * temp1.r - x[i__4].i * temp1.i,
|
||||
z__2.i = x[i__4].r * temp1.i + x[i__4].i *
|
||||
temp1.r;
|
||||
z__2.real = x[i__4].real * temp1.real - x[i__4].imag * temp1.imag,
|
||||
z__2.imag = x[i__4].real * temp1.imag + x[i__4].imag *
|
||||
temp1.real;
|
||||
i__5 = j;
|
||||
z__3.r = y[i__5].r * temp2.r - y[i__5].i * temp2.i,
|
||||
z__3.i = y[i__5].r * temp2.i + y[i__5].i *
|
||||
temp2.r;
|
||||
z__1.r = z__2.r + z__3.r, z__1.i = z__2.i + z__3.i;
|
||||
d__1 = ap[i__3].r + z__1.r;
|
||||
ap[i__2].r = d__1, ap[i__2].i = 0.;
|
||||
z__3.real = y[i__5].real * temp2.real - y[i__5].imag * temp2.imag,
|
||||
z__3.imag = y[i__5].real * temp2.imag + y[i__5].imag *
|
||||
temp2.real;
|
||||
z__1.real = z__2.real + z__3.real, z__1.imag = z__2.imag + z__3.imag;
|
||||
d__1 = ap[i__3].real + z__1.real;
|
||||
ap[i__2].real = d__1, ap[i__2].imag = 0.;
|
||||
k = kk + 1;
|
||||
i__2 = *n;
|
||||
for (i__ = j + 1; i__ <= i__2; ++i__) {
|
||||
i__3 = k;
|
||||
i__4 = k;
|
||||
i__5 = i__;
|
||||
z__3.r = x[i__5].r * temp1.r - x[i__5].i * temp1.i,
|
||||
z__3.i = x[i__5].r * temp1.i + x[i__5].i *
|
||||
temp1.r;
|
||||
z__2.r = ap[i__4].r + z__3.r, z__2.i = ap[i__4].i +
|
||||
z__3.i;
|
||||
z__3.real = x[i__5].real * temp1.real - x[i__5].imag * temp1.imag,
|
||||
z__3.imag = x[i__5].real * temp1.imag + x[i__5].imag *
|
||||
temp1.real;
|
||||
z__2.real = ap[i__4].real + z__3.real, z__2.imag = ap[i__4].imag +
|
||||
z__3.imag;
|
||||
i__6 = i__;
|
||||
z__4.r = y[i__6].r * temp2.r - y[i__6].i * temp2.i,
|
||||
z__4.i = y[i__6].r * temp2.i + y[i__6].i *
|
||||
temp2.r;
|
||||
z__1.r = z__2.r + z__4.r, z__1.i = z__2.i + z__4.i;
|
||||
ap[i__3].r = z__1.r, ap[i__3].i = z__1.i;
|
||||
z__4.real = y[i__6].real * temp2.real - y[i__6].imag * temp2.imag,
|
||||
z__4.imag = y[i__6].real * temp2.imag + y[i__6].imag *
|
||||
temp2.real;
|
||||
z__1.real = z__2.real + z__4.real, z__1.imag = z__2.imag + z__4.imag;
|
||||
ap[i__3].real = z__1.real, ap[i__3].imag = z__1.imag;
|
||||
++k;
|
||||
/* L50: */
|
||||
}
|
||||
} else {
|
||||
i__2 = kk;
|
||||
i__3 = kk;
|
||||
d__1 = ap[i__3].r;
|
||||
ap[i__2].r = d__1, ap[i__2].i = 0.;
|
||||
d__1 = ap[i__3].real;
|
||||
ap[i__2].real = d__1, ap[i__2].imag = 0.;
|
||||
}
|
||||
kk = kk + *n - j + 1;
|
||||
/* L60: */
|
||||
@@ -846,31 +846,31 @@
|
||||
for (j = 1; j <= i__1; ++j) {
|
||||
i__2 = jx;
|
||||
i__3 = jy;
|
||||
if (x[i__2].r != 0. || x[i__2].i != 0. || (y[i__3].r != 0. ||
|
||||
y[i__3].i != 0.)) {
|
||||
if (x[i__2].real != 0. || x[i__2].imag != 0. || (y[i__3].real != 0. ||
|
||||
y[i__3].imag != 0.)) {
|
||||
d_cnjg(&z__2, &y[jy]);
|
||||
z__1.r = alpha->r * z__2.r - alpha->i * z__2.i, z__1.i =
|
||||
alpha->r * z__2.i + alpha->i * z__2.r;
|
||||
temp1.r = z__1.r, temp1.i = z__1.i;
|
||||
z__1.real = alpha->real * z__2.real - alpha->imag * z__2.imag, z__1.imag =
|
||||
alpha->real * z__2.imag + alpha->imag * z__2.real;
|
||||
temp1.real = z__1.real, temp1.imag = z__1.imag;
|
||||
i__2 = jx;
|
||||
z__2.r = alpha->r * x[i__2].r - alpha->i * x[i__2].i,
|
||||
z__2.i = alpha->r * x[i__2].i + alpha->i * x[i__2]
|
||||
.r;
|
||||
z__2.real = alpha->real * x[i__2].real - alpha->imag * x[i__2].imag,
|
||||
z__2.imag = alpha->real * x[i__2].imag + alpha->imag * x[i__2]
|
||||
.real;
|
||||
d_cnjg(&z__1, &z__2);
|
||||
temp2.r = z__1.r, temp2.i = z__1.i;
|
||||
temp2.real = z__1.real, temp2.imag = z__1.imag;
|
||||
i__2 = kk;
|
||||
i__3 = kk;
|
||||
i__4 = jx;
|
||||
z__2.r = x[i__4].r * temp1.r - x[i__4].i * temp1.i,
|
||||
z__2.i = x[i__4].r * temp1.i + x[i__4].i *
|
||||
temp1.r;
|
||||
z__2.real = x[i__4].real * temp1.real - x[i__4].imag * temp1.imag,
|
||||
z__2.imag = x[i__4].real * temp1.imag + x[i__4].imag *
|
||||
temp1.real;
|
||||
i__5 = jy;
|
||||
z__3.r = y[i__5].r * temp2.r - y[i__5].i * temp2.i,
|
||||
z__3.i = y[i__5].r * temp2.i + y[i__5].i *
|
||||
temp2.r;
|
||||
z__1.r = z__2.r + z__3.r, z__1.i = z__2.i + z__3.i;
|
||||
d__1 = ap[i__3].r + z__1.r;
|
||||
ap[i__2].r = d__1, ap[i__2].i = 0.;
|
||||
z__3.real = y[i__5].real * temp2.real - y[i__5].imag * temp2.imag,
|
||||
z__3.imag = y[i__5].real * temp2.imag + y[i__5].imag *
|
||||
temp2.real;
|
||||
z__1.real = z__2.real + z__3.real, z__1.imag = z__2.imag + z__3.imag;
|
||||
d__1 = ap[i__3].real + z__1.real;
|
||||
ap[i__2].real = d__1, ap[i__2].imag = 0.;
|
||||
ix = jx;
|
||||
iy = jy;
|
||||
i__2 = kk + *n - j;
|
||||
@@ -880,24 +880,24 @@
|
||||
i__3 = k;
|
||||
i__4 = k;
|
||||
i__5 = ix;
|
||||
z__3.r = x[i__5].r * temp1.r - x[i__5].i * temp1.i,
|
||||
z__3.i = x[i__5].r * temp1.i + x[i__5].i *
|
||||
temp1.r;
|
||||
z__2.r = ap[i__4].r + z__3.r, z__2.i = ap[i__4].i +
|
||||
z__3.i;
|
||||
z__3.real = x[i__5].real * temp1.real - x[i__5].imag * temp1.imag,
|
||||
z__3.imag = x[i__5].real * temp1.imag + x[i__5].imag *
|
||||
temp1.real;
|
||||
z__2.real = ap[i__4].real + z__3.real, z__2.imag = ap[i__4].imag +
|
||||
z__3.imag;
|
||||
i__6 = iy;
|
||||
z__4.r = y[i__6].r * temp2.r - y[i__6].i * temp2.i,
|
||||
z__4.i = y[i__6].r * temp2.i + y[i__6].i *
|
||||
temp2.r;
|
||||
z__1.r = z__2.r + z__4.r, z__1.i = z__2.i + z__4.i;
|
||||
ap[i__3].r = z__1.r, ap[i__3].i = z__1.i;
|
||||
z__4.real = y[i__6].real * temp2.real - y[i__6].imag * temp2.imag,
|
||||
z__4.imag = y[i__6].real * temp2.imag + y[i__6].imag *
|
||||
temp2.real;
|
||||
z__1.real = z__2.real + z__4.real, z__1.imag = z__2.imag + z__4.imag;
|
||||
ap[i__3].real = z__1.real, ap[i__3].imag = z__1.imag;
|
||||
/* L70: */
|
||||
}
|
||||
} else {
|
||||
i__2 = kk;
|
||||
i__3 = kk;
|
||||
d__1 = ap[i__3].r;
|
||||
ap[i__2].r = d__1, ap[i__2].i = 0.;
|
||||
d__1 = ap[i__3].real;
|
||||
ap[i__2].real = d__1, ap[i__2].imag = 0.;
|
||||
}
|
||||
jx += *incx;
|
||||
jy += *incy;
|
||||
|
||||
Reference in New Issue
Block a user