On Wed, Feb 16, 2005 at 10:59:00PM -0500, Jason Merrill wrote:
> I suspect that the problem is that the transformations fold_indirect_ref_1
> is doing on arrays don't mix well with how fortran handles arrays.
I have been trying to look at the problem in the BLAS sources,
and I find it hard to debug because it goes away when print
statements are added to the source (I hate that...)
Anyway, this looks like a character-related failure. The first error
in the single precision level 2 BLAS routines is the following:
***** ILLEGAL VALUE OF PARAMETER NUMBER 1 NOT DETECTED BY SGEMV *****
******* SGEMV FAILED THE TESTS OF ERROR-EXITS *******
The call to SGEMV happens in line 2325 in sblat2.f and looks like this:
CALL SGEMV( '/', 0, 0, ALPHA, A, 1, X, 1, BETA, Y, 1 )
The argument list to SGEMV looks like this:
SUBROUTINE SGEMV ( TRANS, M, N, ALPHA, A, LDA, X, INCX,
$ BETA, Y, INCY )
* .. Scalar Arguments ..
REAL ALPHA, BETA
INTEGER INCX, INCY, LDA, M, N
CHARACTER*1 TRANS
* .. Array Arguments ..
REAL A( LDA, * ), X( * ), Y( * )
* ..
and the first executable statements are
IF ( .NOT.LSAME( TRANS, 'N' ).AND.
$ .NOT.LSAME( TRANS, 'T' ).AND.
$ .NOT.LSAME( TRANS, 'C' ) )THEN
INFO = 1
...
where LSAME is a logical function that compares single-character
strings for equality. For some reason that I can't fathom,
the INFO=1 statement isn't reached.
If the statement
print *,trans
is insterted before the if statement, the failure in question does
not occur.
That's as far as I could get. You can get BLAS from netlib if you
download LAPACK.
Thomas