HP MLIB User's Guide Vol. 1 7th Ed.
Chapter 3 Basic Matrix Operations 337
Error handler XERBLA
Name XERBLA
Error handler
Purpose This subprogram is the error handler for many of the subprograms in this
chapter, as indicated in the “Notes” section in the applicable subprogram
descriptions. As supplied in VECLIB, XERBLA writes the following error
message onto the standard error file:
*****************************************************************************
* XERBLA: subprogram name called with invalid value of argument number iarg *
*****************************************************************************
where name is the name of the subprogram in which the error was detected,
and iarg is the argument number of the offending argument. For example, in
SGEMV, trans is argument number 1 and m is argument number 2. XERBLA
then terminates execution with a nonzero exit status.
You can supply a version of XERBLA that alters this action. Be aware that
other subprograms, including many in LAPACK, also call XERBLA. All BLAS,
VECLIB and LAPACK subprograms that call XERBLA follow the CALL
XERBLA
statement with a RETURN statement, so your version of XERBLA can
exit with a RETURN statement. However, many of those subprograms do not
have a status response variable in their argument list that could be used to
alert the caller. If you write an XERBLA that does not end with a STOP
statement, you need some other mechanism to detect errors occurring in those
subprograms. One such mechanism is a flag in a common block that is set by
your XERBLA and tested by the calling program after calls where errors could
be detected.
Usage VECLIB:
CHARACTER*6 name
INTEGER*4 iarg
CALL XERBLA(name, iarg)
VECLIB8:
CHARACTER*6 name
INTEGER*8 iarg
CALL XERBLA(name, iarg)
Input name The name of the subprogram in which the error was
detected.
iarg The number of the argument that was found to be in
error.
Notes This subprogram conforms to specifications of the Level 2 and 3 BLAS and
LAPACK.