File:  [local] / rpl / lapack / blas / xerbla_array.f
Revision 1.8: download - view: text, annotated - select for diffs - revision graph
Mon Aug 7 08:38:44 2023 UTC (8 months, 3 weeks ago) by bertrand
Branches: MAIN
CVS tags: rpl-4_1_35, rpl-4_1_34, HEAD
Première mise à jour de lapack et blas.

    1: *> \brief \b XERBLA_ARRAY
    2: *
    3: *  =========== DOCUMENTATION ===========
    4: *
    5: * Online html documentation available at
    6: *            http://www.netlib.org/lapack/explore-html/
    7: *
    8: *  Definition:
    9: *  ===========
   10: *
   11: *       SUBROUTINE XERBLA_ARRAY(SRNAME_ARRAY, SRNAME_LEN, INFO)
   12: *
   13: *       .. Scalar Arguments ..
   14: *       INTEGER SRNAME_LEN, INFO
   15: *       ..
   16: *       .. Array Arguments ..
   17: *       CHARACTER(1) SRNAME_ARRAY(SRNAME_LEN)
   18: *       ..
   19: *
   20: *
   21: *> \par Purpose:
   22: *  =============
   23: *>
   24: *> \verbatim
   25: *>
   26: *> XERBLA_ARRAY assists other languages in calling XERBLA, the LAPACK
   27: *> and BLAS error handler.  Rather than taking a Fortran string argument
   28: *> as the function's name, XERBLA_ARRAY takes an array of single
   29: *> characters along with the array's length.  XERBLA_ARRAY then copies
   30: *> up to 32 characters of that array into a Fortran string and passes
   31: *> that to XERBLA.  If called with a non-positive SRNAME_LEN,
   32: *> XERBLA_ARRAY will call XERBLA with a string of all blank characters.
   33: *>
   34: *> Say some macro or other device makes XERBLA_ARRAY available to C99
   35: *> by a name lapack_xerbla and with a common Fortran calling convention.
   36: *> Then a C99 program could invoke XERBLA via:
   37: *>    {
   38: *>      int flen = strlen(__func__);
   39: *>      lapack_xerbla(__func__, &flen, &info);
   40: *>    }
   41: *>
   42: *> Providing XERBLA_ARRAY is not necessary for intercepting LAPACK
   43: *> errors.  XERBLA_ARRAY calls XERBLA.
   44: *> \endverbatim
   45: *
   46: *  Arguments:
   47: *  ==========
   48: *
   49: *> \param[in] SRNAME_ARRAY
   50: *> \verbatim
   51: *>          SRNAME_ARRAY is CHARACTER(1) array, dimension (SRNAME_LEN)
   52: *>          The name of the routine which called XERBLA_ARRAY.
   53: *> \endverbatim
   54: *>
   55: *> \param[in] SRNAME_LEN
   56: *> \verbatim
   57: *>          SRNAME_LEN is INTEGER
   58: *>          The length of the name in SRNAME_ARRAY.
   59: *> \endverbatim
   60: *>
   61: *> \param[in] INFO
   62: *> \verbatim
   63: *>          INFO is INTEGER
   64: *>          The position of the invalid parameter in the parameter list
   65: *>          of the calling routine.
   66: *> \endverbatim
   67: *
   68: *  Authors:
   69: *  ========
   70: *
   71: *> \author Univ. of Tennessee
   72: *> \author Univ. of California Berkeley
   73: *> \author Univ. of Colorado Denver
   74: *> \author NAG Ltd.
   75: *
   76: *> \ingroup aux_blas
   77: *
   78: *  =====================================================================
   79:       SUBROUTINE XERBLA_ARRAY(SRNAME_ARRAY, SRNAME_LEN, INFO)
   80: *
   81: *  -- Reference BLAS level1 routine --
   82: *  -- Reference BLAS is a software package provided by Univ. of Tennessee,    --
   83: *  -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..--
   84: *
   85: *     .. Scalar Arguments ..
   86:       INTEGER SRNAME_LEN, INFO
   87: *     ..
   88: *     .. Array Arguments ..
   89:       CHARACTER(1) SRNAME_ARRAY(SRNAME_LEN)
   90: *     ..
   91: *
   92: * =====================================================================
   93: *
   94: *     ..
   95: *     .. Local Scalars ..
   96:       INTEGER I
   97: *     ..
   98: *     .. Local Arrays ..
   99:       CHARACTER*32 SRNAME
  100: *     ..
  101: *     .. Intrinsic Functions ..
  102:       INTRINSIC MIN, LEN
  103: *     ..
  104: *     .. External Functions ..
  105:       EXTERNAL XERBLA
  106: *     ..
  107: *     .. Executable Statements ..
  108:       SRNAME = ' '
  109:       DO I = 1, MIN( SRNAME_LEN, LEN( SRNAME ) )
  110:          SRNAME( I:I ) = SRNAME_ARRAY( I )
  111:       END DO
  112: 
  113:       CALL XERBLA( SRNAME, INFO )
  114: 
  115:       RETURN
  116: *
  117: *     End of XERBLA_ARRAY
  118: *
  119:       END

CVSweb interface <joel.bertrand@systella.fr>