Skip to content

out of the array bound in SRC/ssytrs_aa.f in LAPACK 3.8.0 #312

Closed

Description

@collinmines

I'm installing LAPACK 3.8.0 with GCC (gfortran) 8.2.1. I have added the flag -fcheck=all in the make.inc so I know what happened at runtime, because there are some errors reported by the test code during installation. Run "make all", at the end I got
...
./LIN/xlintsts < stest.in > stest.out 2>&1
make[1]: *** [stest.out] Error 2
make[1]: Leaving directory.`../.../lapack-3.8.0/TESTING'

The beginning part of "stest.out" shows:

At line 216 of file ssytrs_aa.f
Fortran runtime error: Index '2' of dimension 1 of array 'b' above upper bound of 1

Error termination. Backtrace:
#0 0x3fff80d4ddaf in ???
#1 0x3fff80d4f7e7 in ???
#2 0x3fff80d5019b in ???
#3 0x1013d71b in ???
#4 0x1003591f in ???
#5 0x1001a42f in ???
#6 0x10001433 in ???
#7 0x3fff80554bf7 in ???
#8 0x3fff80554e03 in ???
#9 0xffffffffffffffff in ???
Tests of the REAL LAPACK routines
LAPACK VERSION 3.8.0
...

The source code location is ./SRC/ssytrs_aa.f. I believe that in this code (lines 215, 216), when the STRSM is called, the value of LDB is 1, which is in conflict with B( 2,1), because B array is declared as B(LDB, *). So we got the out of bound issue. Can you confirm it?

Thanks!

Activity

  1. collinmines commented on Jan 18, 2019

    @collinmines
    Author

    the main routine is TESTING/LIN/schkaa.f for the test exe ./LIN/xlintsts. The schkaa.f calls schksy_aa, which further calls ssytrs_aa. Not sure how the LDB value got initialized or propagates from one to the other. Or maybe a parameter in the input file stest.in is incorrect?

  2. langou commented on Jan 19, 2019

    @langou
    Contributor

    Hi @collinmines , I contacted @iyamazaki and he is on it. There are a few other fixes in the documentation that he wanted to push. Cheers, @langou .

  3. collinmines commented on Jan 22, 2019

    @collinmines
    Author

    Thanks, @langou . Please let me know when a update is committed to fix these issues so I'll test it.

  4. iyamazaki commented on Jan 23, 2019

    @iyamazaki
    Contributor

    Thank you for the bug report. Julien merged my pull-request (thank you). Please let me know if there are still issues.

  5. collinmines commented on Jan 23, 2019

    @collinmines
    Author

    Thanks for the updates. Just tested it. I run "git clone ..." and then "git pull" in the lapack directory. Let me know if I'm missing something here to clone the latest version. The gfortran compiler (v8.2.1) flag is the same (-fcheck=all) as before in make.inc. Now, this time it reports something differently. Run "make all", I got:
    ...
    ./LIN/xlintsts < stest.in > stest.out 2>&1
    make[1]: *** [stest.out] Error 2
    make[1]: Leaving directory.`../.../lapack/TESTING'

    Now, ./TESTING/stest.out shows:

    At line 482 of file slasyf_aa.f
    Fortran runtime error: Index '3' of dimension 1 of array 'a' above upper bound of 2
    ...
    Tests of the REAL LAPACK routines
    LAPACK VERSION 3.8.0

    It complains the other source code in .SRC/slasyf_aa.f, which is different from what I saw before. But still out of array bound issue. Can you please take a look?

  6. iyamazaki commented on Jan 25, 2019

    @iyamazaki
    Contributor

    I'm sorry for the incomplete pull-request. Julien merged another pull-request. Hopefully, this fixed the problem. Please let me know if you have more issues.

  7. collinmines commented on Jan 25, 2019

    @collinmines
    Author

    Thanks for the updates. Just tested it again this morning.

    Now, the source code passed the test with ./LIN/xlintsts, which is good. But it hit the other out of array bound issue in ./EIG/xeigtsts. Below is the detail:

    ...
    ./EIG/xeigtsts < se2.in > sse2.out 2>&1
    make[1]: *** [sse2.out] Error 2
    make[1]: Leaving directory `../lapack/TESTING'
    make: *** [lapack_testing] Error 2

    The content of sse2.out is:

    At line 169 of file slaset.f
    Fortran runtime error: Index '2' of dimension 1 of array 'a' above upper bound of 1

    Error termination. Backtrace:
    #0 0x10000042ddaf in ???
    #1 0x10000042f7e7 in ???
    #2 0x10000043019b in ???
    #3 0x101c9107 in ???
    #4 0x1002889b in ???
    #5 0x10005a13 in ???
    #6 0x10001313 in ???
    #7 0x100000764bf7 in ???
    #8 0x100000764e03 in ???
    #9 0xffffffffffffffff in ???
    Tests of the Symmetric Eigenvalue Problem routines

    LAPACK VERSION 3.8.0

    The following parameter values will be used:
    M: 0 1 2 3 5 20
    N: 0 1 2 3 5 20
    NB: 1 3 3 3 10
    NBMIN: 2 2 2 2 2
    NX: 1 0 5 9 1

    Relative machine underflow is taken to be 0.117549E-37
    Relative machine overflow is taken to be 0.340282E+39
    Relative machine precision is taken to be 0.596046E-07

    Routines pass computational tests if test ratio is less than 50.00
    SST routines passed the tests of the error exits (209 tests done)
    SE2: NB = 1, NBMIN = 2, NX = 1

    Thanks a lot for your time again!
    Collin

  8. iyamazaki commented on Jan 25, 2019

    @iyamazaki
    Contributor

    Since this is in another subroutine, maybe, we can open another issue?

  9. collinmines commented on Jan 25, 2019

    @collinmines
    Author

    Sure and will open a new issue.

  10. langou commented on Feb 14, 2019

    @langou
    Contributor

    Fixed with #314, #315, and #317
    Thanks to @collinmines and @iyamazaki

  11. added this to the LAPACK 3.9.0 milestone on Nov 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions