octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #39000] Can't override BLAS XERBLA handler on


From: Avinoam Kalma
Subject: [Octave-bug-tracker] [bug #39000] Can't override BLAS XERBLA handler on Windows
Date: Tue, 21 Nov 2017 00:19:34 -0500 (EST)
User-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.94 Safari/537.36

Follow-up Comment #31, bug #39000 (project octave):

The line


N=10;D=randn(N,3);C=rand(N,1)>.9;D(10,2)=NaN;D\C


Causes crash in Windows, and the error


** On entry to DLASCL parameter number  4 had an illegal value
error: exception encountered in Fortran subroutine dgelsd_


In Linux.

The crash is in line 2217 of dMatrix.cc. The check


      if (octave::math::isinf (anorm) || octave::math::isnan (anorm))


Does not help.

A solution could something like


     int nanflag = 0;

      for (F77_INT j = 0; j < atmp.cols (); j++)
            for (F77_INT i = 0; i < atmp.rows (); i++)
              if (octave::math::isinf (atmp.elem (i, j)) || 
                  octave::math::isnan (atmp.elem (i, j)))
                nanflag = 1;

       if (nanflag) {
          ....
       }


But:

* Is there a better way to find if there is a NaN/Inf in the matrix?
* Where should we locate this check?



    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?39000>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]