Developer Guide

  • 2021.1
  • 12/04/2020
  • Public Content
Contents

Managing Invalid Input Checking in LAPACKE Functions

The high-level interface includes an optional, on by default, NaN check on all matrix inputs before calling any LAPACK routine. This option affects all routines. If an input matrix contains any NaNs, the input parameter corresponding to this matrix is flagged with a return value error. For example, if the fifth parameter is found to contain a NaN, the routine returns the value,
-5
. The middle-level interface does not contain the NaN check.
NaN checking on matrix input can be expensive. By default, NaN checking is turned
on
. LAPACKE provides a way to set it through the environment variable:
  • Setting environment variable
    LAPACKE_NANCHECK
    to
    0
    turns OFF NaN-checking
  • Setting environment variable
    LAPACKE_NANCHECK
    to
    1
    turns ON NaN-checking
The other way is the call the
LAPACKE_set_nancheck
function; see the Developer Reference for C's section for more information.
Note that the NaN-checking flag value set by the call to
LAPACKE_set_nancheck
always has higher priority than the environment variable,
LAPACKE_NANCHECK
.

Product and Performance Information

1

Performance varies by use, configuration and other factors. Learn more at www.Intel.com/PerformanceIndex.