Skip to content

TESTING: Make the test failures fatal and resolve all of them - #1371

Draft
ACSimon33 wants to merge 10 commits into
masterfrom
fatal_test_failures
Draft

TESTING: Make the test failures fatal and resolve all of them#1371
ACSimon33 wants to merge 10 commits into
masterfrom
fatal_test_failures

Conversation

@ACSimon33

@ACSimon33 ACSimon33 commented Aug 25, 2026

Copy link
Copy Markdown
Collaborator

Description

The test suite could not fail. A driver that found a numerical error printed it and exited with status 0, and every fatal STOP was either bare or carried a character stop code, which also exits with 0 — so ctest and lapack_testing.py, which both check the status, saw a passing run. This branch closes those paths and fixes what the CI then reported.

Merge this last: the numerical failures it exposes are fixed on their own branches (see table below).

Failures now fail

  • LAPACK_Test_Summary runs with --fail-on-error, so a numerical failure or error reported by any driver fails the run.
  • 177 fatal STOPs become STOP 1, across 45 files in BLAS/TESTING, CBLAS/testing, TESTING/EIG and TESTING/LIN.
  • The ALLOCATE checks passed their message as the stop code, which goes to stderr where the script never sees it; they now write it to the output unit.

Reports name their job

lapack_testing.py --junit-job NAME prefixes the JUnit suite (job / suite) and class (job.class) names, exposed to CMake as LAPACK_TESTING_JUNIT_JOB_ID. Codecov keys a test case on those names alone, so the reports of ~40 jobs collapsed onto one another, and a failure did not say where it came from.

Error-exit tests

  • On a Windows shared build, the drivers' own XERBLA cannot replace the library's, so the first deliberate illegal argument killed the driver before any test ran (CBLAS already skips its xerbla tests for this). LAPACK_SKIP_ERROR_EXIT_TESTS plus the new lapack_test_input() feed such a build a copy of the input with TSTERR off, written where lapack_testing.py looks for it so a hand-run driver uses the same input ctest does. This could be fixed by REGISTER_XERBLA - override the error-handler without linker stuff #1407.
  • ?ec.in had no TSTERR line at all — ?chkee hard-coded .TRUE.. It is now read from the file, the line is added to sec.in/dec.in/cec.in/zec.in, and the input-format docs in [sdcz]chkee.F are updated.

The numerical failures, fixed elsewhere

Fix Clears
#1396 macos-26-nagfor, sec/dec; closes #598
#1397 ubuntu-26.04-gfortran, the 803-row cnep/ced/znep/zed baseline
#1398 STFSM 1 of 7776, every x86-64 gfortran job; closes #679
#1400 SHS/CHS 1 of 2016, ARM gfortran and armflang
#1401 ubuntu-26.04-arm-flang, ubuntu-24.04-arm-armflang; item 3 of #732

Earlier test failures cleared on the way here; all merged: #1337, #1338, #1340, #1342, #1343, #1344, #1346, #1347, #1355.

…iles are now differentiated between the jobs.
@codecov

codecov Bot commented Aug 25, 2026

Copy link
Copy Markdown

❌ 34 Tests Failed:

Tests completed Failed Passed Skipped
9501 34 9467 0
View the top 3 failed test(s) by shortest run time
ubuntu-26.04-arm-gfortran-shared.LAPACK_64.eig::snep_64.out (REAL Nonsymmetric Eigenvalue Problem)
Stack Traces | 0.03s run time
1 numerical error(s), 10080 test(s) run
 SHS:    1 out of  2016 tests failed to pass the threshold
ubuntu-26.04-arm-gfortran-static.LAPACK.eig::snep.out (REAL Nonsymmetric Eigenvalue Problem)
Stack Traces | 0.03s run time
1 numerical error(s), 10080 test(s) run
 SHS:    1 out of  2016 tests failed to pass the threshold
ubuntu-26.04-arm-gfortran-static.LAPACK_64.eig::snep_64.out (REAL Nonsymmetric Eigenvalue Problem)
Stack Traces | 0.03s run time
1 numerical error(s), 10080 test(s) run
 SHS:    1 out of  2016 tests failed to pass the threshold
openmp-ubuntu-26.04-arm-shared.LAPACK.eig::snep.out (REAL Nonsymmetric Eigenvalue Problem)
Stack Traces | 0.04s run time
1 numerical error(s), 10080 test(s) run
 SHS:    1 out of  2016 tests failed to pass the threshold
openmp-ubuntu-26.04-arm-shared.LAPACK_64.eig::snep_64.out (REAL Nonsymmetric Eigenvalue Problem)
Stack Traces | 0.04s run time
1 numerical error(s), 10080 test(s) run
 SHS:    1 out of  2016 tests failed to pass the threshold
openmp-ubuntu-26.04-arm-static.LAPACK.eig::snep.out (REAL Nonsymmetric Eigenvalue Problem)
Stack Traces | 0.04s run time
1 numerical error(s), 10080 test(s) run
 SHS:    1 out of  2016 tests failed to pass the threshold
openmp-ubuntu-26.04-arm-static.LAPACK_64.eig::snep_64.out (REAL Nonsymmetric Eigenvalue Problem)
Stack Traces | 0.04s run time
1 numerical error(s), 10080 test(s) run
 SHS:    1 out of  2016 tests failed to pass the threshold
ubuntu-26.04-arm-gfortran-shared.LAPACK.eig::snep.out (REAL Nonsymmetric Eigenvalue Problem)
Stack Traces | 0.04s run time
1 numerical error(s), 10080 test(s) run
 SHS:    1 out of  2016 tests failed to pass the threshold
ubuntu-24.04-arm-armflang-shared.LAPACK_64.eig::cnep_64.out (COMPLEX Nonsymmetric Eigenvalue Problem)
Stack Traces | 0.07s run time
1 numerical error(s), 10080 test(s) run
 CHS:    1 out of  2016 tests failed to pass the threshold
ubuntu-24.04-arm-armflang-static.LAPACK_64.eig::cnep_64.out (COMPLEX Nonsymmetric Eigenvalue Problem)
Stack Traces | 0.07s run time
1 numerical error(s), 10080 test(s) run
 CHS:    1 out of  2016 tests failed to pass the threshold
openmp-ubuntu-26.04-shared.LAPACK_64.rfp::stest_rfp_64.out (REAL RFP linear equation routines)
Stack Traces | 0.13s run time
1 numerical error(s), 13128 test(s) run
 STFSM_ auxiliary routine:     1 out of  7776 tests failed to pass the threshold
openmp-ubuntu-26.04-shared.LAPACK.rfp::stest_rfp.out (REAL RFP linear equation routines)
Stack Traces | 0.14s run time
1 numerical error(s), 13128 test(s) run
  STFSM auxiliary routine:     1 out of  7776 tests failed to pass the threshold
openmp-ubuntu-26.04-static.LAPACK.rfp::stest_rfp.out (REAL RFP linear equation routines)
Stack Traces | 0.16s run time
1 numerical error(s), 13128 test(s) run
  STFSM auxiliary routine:     1 out of  7776 tests failed to pass the threshold
openmp-ubuntu-26.04-static.LAPACK_64.rfp::stest_rfp_64.out (REAL RFP linear equation routines)
Stack Traces | 0.16s run time
1 numerical error(s), 13128 test(s) run
 STFSM_ auxiliary routine:     1 out of  7776 tests failed to pass the threshold
ubuntu-26.04-gfortran-shared.LAPACK_64.rfp::stest_rfp_64.out (REAL RFP linear equation routines)
Stack Traces | 0.18s run time
1 numerical error(s), 13128 test(s) run
 STFSM_ auxiliary routine:     1 out of  7776 tests failed to pass the threshold
ubuntu-26.04-gfortran-static.LAPACK.rfp::stest_rfp.out (REAL RFP linear equation routines)
Stack Traces | 0.18s run time
1 numerical error(s), 13128 test(s) run
  STFSM auxiliary routine:     1 out of  7776 tests failed to pass the threshold
ubuntu-26.04-gfortran-static.LAPACK_64.rfp::stest_rfp_64.out (REAL RFP linear equation routines)
Stack Traces | 0.18s run time
1 numerical error(s), 13128 test(s) run
 STFSM_ auxiliary routine:     1 out of  7776 tests failed to pass the threshold
ubuntu-24.04-arm-armflang-static.LAPACK.eig::ced.out (COMPLEX Nonsymmetric Eigenvalue)
Stack Traces | 0.19s run time
8 numerical error(s), 14088 test(s) run
 CEV:    8 out of  1100 tests failed to pass the threshold
ubuntu-26.04-gfortran-shared.LAPACK.rfp::stest_rfp.out (REAL RFP linear equation routines)
Stack Traces | 0.19s run time
1 numerical error(s), 13128 test(s) run
  STFSM auxiliary routine:     1 out of  7776 tests failed to pass the threshold
ubuntu-24.04-arm-armflang-shared.LAPACK.eig::ced.out (COMPLEX Nonsymmetric Eigenvalue)
Stack Traces | 0.2s run time
8 numerical error(s), 14088 test(s) run
 CEV:    8 out of  1100 tests failed to pass the threshold
ubuntu-24.04-arm-armflang-shared.LAPACK_64.eig::ced_64.out (COMPLEX Nonsymmetric Eigenvalue)
Stack Traces | 0.2s run time
6 numerical error(s), 14086 test(s) run
 CEV:    6 out of  1098 tests failed to pass the threshold
ubuntu-24.04-arm-armflang-static.LAPACK_64.eig::ced_64.out (COMPLEX Nonsymmetric Eigenvalue)
Stack Traces | 0.2s run time
6 numerical error(s), 14086 test(s) run
 CEV:    6 out of  1098 tests failed to pass the threshold
ubuntu-24.04-arm-armflang-static.LAPACK.eig::zed.out (COMPLEX16 Nonsymmetric Eigenvalue)
Stack Traces | 0.27s run time
10 numerical error(s), 14090 test(s) run
 ZEV:   10 out of  1102 tests failed to pass the threshold
ubuntu-24.04-arm-armflang-static.LAPACK_64.eig::zed_64.out (COMPLEX16 Nonsymmetric Eigenvalue)
Stack Traces | 0.27s run time
10 numerical error(s), 14090 test(s) run
 ZEV:   10 out of  1102 tests failed to pass the threshold
ubuntu-24.04-arm-armflang-shared.LAPACK.eig::zed.out (COMPLEX16 Nonsymmetric Eigenvalue)
Stack Traces | 0.29s run time
10 numerical error(s), 14090 test(s) run
 ZEV:   10 out of  1102 tests failed to pass the threshold
ubuntu-24.04-arm-armflang-shared.LAPACK_64.eig::zed_64.out (COMPLEX16 Nonsymmetric Eigenvalue)
Stack Traces | 0.29s run time
10 numerical error(s), 14090 test(s) run
 ZEV:   10 out of  1102 tests failed to pass the threshold
ubuntu-26.04-arm-flang-static.LAPACK.eig::ced.out (COMPLEX Nonsymmetric Eigenvalue)
Stack Traces | 0.3s run time
8 numerical error(s), 14088 test(s) run
 CEV:    8 out of  1100 tests failed to pass the threshold
ubuntu-26.04-arm-flang-static.LAPACK_64.eig::ced_64.out (COMPLEX Nonsymmetric Eigenvalue)
Stack Traces | 0.3s run time
8 numerical error(s), 14088 test(s) run
 CEV:    8 out of  1100 tests failed to pass the threshold
ubuntu-26.04-arm-flang-shared.LAPACK.eig::ced.out (COMPLEX Nonsymmetric Eigenvalue)
Stack Traces | 0.32s run time
8 numerical error(s), 14088 test(s) run
 CEV:    8 out of  1100 tests failed to pass the threshold
ubuntu-26.04-arm-flang-shared.LAPACK_64.eig::ced_64.out (COMPLEX Nonsymmetric Eigenvalue)
Stack Traces | 0.32s run time
8 numerical error(s), 14088 test(s) run
 CEV:    8 out of  1100 tests failed to pass the threshold
ubuntu-26.04-arm-flang-static.LAPACK.eig::zed.out (COMPLEX16 Nonsymmetric Eigenvalue)
Stack Traces | 0.4s run time
10 numerical error(s), 14090 test(s) run
 ZEV:   10 out of  1102 tests failed to pass the threshold
ubuntu-26.04-arm-flang-static.LAPACK_64.eig::zed_64.out (COMPLEX16 Nonsymmetric Eigenvalue)
Stack Traces | 0.4s run time
10 numerical error(s), 14090 test(s) run
 ZEV:   10 out of  1102 tests failed to pass the threshold
ubuntu-26.04-arm-flang-shared.LAPACK.eig::zed.out (COMPLEX16 Nonsymmetric Eigenvalue)
Stack Traces | 0.43s run time
10 numerical error(s), 14090 test(s) run
 ZEV:   10 out of  1102 tests failed to pass the threshold
ubuntu-26.04-arm-flang-shared.LAPACK_64.eig::zed_64.out (COMPLEX16 Nonsymmetric Eigenvalue)
Stack Traces | 0.43s run time
10 numerical error(s), 14090 test(s) run
 ZEV:   10 out of  1102 tests failed to pass the threshold

To view more test analytics, go to the Test Analytics Dashboard
📋 Got 3 mins? Take this short survey to help us improve Test Analytics.

ACSimon33 and others added 5 commits September 8, 2026 13:17
The merge kept both sides of the LAPACK_Test_Summary block, so nothing
configured at all: add_test refused the second, duplicate, test name.
Keep this branch's copy, which passes --fail-on-error and the job id,
and take the mention of LAPACKE from master's comment.

Moving the input check into the helper also dropped the rule that a BLAS
driver reading an input file must not have its stdout redirected: it
takes the name of its summary file from that input and opens it on unit
6 itself, so the redirect opened the one file twice and xBLAT2 died on
the second open.  Only xBLAT1, which has no input, needs it.

Also drop a reference to the preprocessor macro the error-exit tests no
longer use.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
ACSimon33 and others added 4 commits September 9, 2026 17:36
nagfor rejects the SQRT( -ONE ) that creates a NaN, and the LAPACKE test
build regenerates the ?errcxx drivers without the -Onopropagate that
TESTING/LIN applies, so every nagfor job has failed to build since the
LAPACKE LIN tests were merged.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Every STOP in the test drivers was either bare or carried a character
stop code, and both exit with status 0.  That is not an accident of the
implementation: the standard recommends the exit status be taken from an
integer stop code, and recommends zero when the stop code is of type
character or absent.  So a driver that abandoned its run - an
unrecognised subprogram name, an input file it could not parse, a failed
ALLOCATE, or its own reference arithmetic evaluating wrongly - reported
success, and ctest and lapack_testing.py, which both do check the
status, saw a passing test.

The 177 fatal paths now use STOP 1.  A digit string as the stop code is
FORTRAN 77, and STOP keeps normal termination, so all units are still
flushed and closed; ERROR STOP would need Fortran 2008 and only
recommends flushing.  The 24 STOPs that end a program normally are left
as they are.

The ALLOCATE checks printed their message as the stop code, which sends
it to standard error where lapack_testing.py never sees it.  They now
write it to the output unit before stopping.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
--fail-if-empty only looked at the grand total, so one driver that wrote
its header and then ran nothing passed unnoticed as long as its siblings
kept the total above zero.  That is the shape of a driver whose input
file has stopped lining up with what it reads: the run is not an error
by any measure the script applies, the tests simply are not there.

Report every analyzed output file whose test count is zero, and let
--fail-if-empty fail on it as well.  Measured over a clean build, the
smallest per-file count is 6 tests and none is zero, so this does not
fire on a healthy run.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

stest_rfp: STFSM test is very sensitive to small numeric errors in BLAS STRSM LAPACK slaln2.f: more accuracy hurts if not consistent

2 participants