bugGNU Octave - Bugs: bug #38575, crash on lapack error if libraries...

 
 

bug #38575: crash on lapack error if libraries built with -Bsymbolic

Submitter:  Mike Miller <mtmiller>
Submitted:  Fri 22 Mar 2013 11:56:24 PM UTC
   
 
Category:  Configuration and Build System Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Segfault, Bus Error, etc.
Status:  Wont Fix Assigned to:  None
Originator Name:  Open/Closed:  * Closed
Release:  * dev Operating System:  * GNU/Linux
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Fri 27 Sep 2013 02:15:51 AM UTC, comment #2: 

Closing my own bug as wont-fix, this is something that should probably be addressed in the way the numerical libraries are compiled and I don't think there is much Octave could do about it, other than detecting and printing a warning in the configure script.

Now that the lapack library in Ubuntu has been fixed to build without the -Bsymbolic-functions option, the only case of this I cared about has vanished, so closing.

Mike Miller <mtmiller>
Group Member
Fri 22 Mar 2013 11:57:58 PM UTC, comment #1: 

I forgot to conclude:

It should be easy to detect this in configure, but what to do when this is the case? Fail to compile? Is there any other way we could work around this problem?

Mike Miller <mtmiller>
Group Member
Fri 22 Mar 2013 11:56:24 PM UTC, original submission:  

Octave crashes, or rather exits from within the BLAS or LAPACK libraries, when those libraries are linked with the -Bsymbolic or -Bsymbolic-functions linker options. The entire Ubuntu distribution is built by default with -Bsymbolic-functions, for example.

The problem is that Octave expects to be able to override the XERBLA error handler function by defining its own copy and linking it first so it takes precedence over BLAS and LAPACK's own copies. This has no effect when the LAPACK shared library is linked using -Bsymbolic-functions.

The attached program (modified from a snippet posted by jwe in a different bug report) shows the difference between Debian and Ubuntu, both with LAPACK version 3.4.2:


mike@deb:~$ gfortran -o xerbla-test xerbla-test.f -lblas -llapack
mike@deb:~$ ./xerbla-test
 In do-nothing xerbla
          -4
                       NaN   0.0000000000000000
                       NaN

mike@ubu:~$ gfortran -o xerbla-test xerbla-test.f -lblas -llapack
mike@ubu:~$ ./xerbla-test
 ** On entry to DLASCL parameter number  4 had an illegal value


Mike Miller <mtmiller>
Group Member

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #27663:  xerbla-test.f added by mtmiller (789B - text/x-fortran)

 

Depends on the following items: None found

Digest:
   bug dependencies.

 

Carbon-Copy List
  • -email is unavailable- added by mtmiller (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2013-09-27 mtmiller StatusNone Wont Fix
        Open/ClosedOpen Closed
    2013-08-15 mtmiller Dependencies- bugs #39788 is dependent
    2013-03-22 mtmiller Attached File- Added xerbla-test.f, #27663

    Back to the top

    Powered by Savane 3.13-f8d8.
    Corresponding source code