Skip to content

*trsm: remove zero-RHS skip for consistent NaN on singular matrix#1301

Open
jschueller wants to merge 1 commit into
Reference-LAPACK:masterfrom
jschueller:issue636
Open

*trsm: remove zero-RHS skip for consistent NaN on singular matrix#1301
jschueller wants to merge 1 commit into
Reference-LAPACK:masterfrom
jschueller:issue636

Conversation

@jschueller

Copy link
Copy Markdown
Contributor

The left-solving non-transposed path in DTRSM/S/CTRSM/ZTRSM has an optimization that skips the division B(K,J)/A(K,K) when B(K,J) is exactly zero. When A(K,K) is also zero (singular matrix), this leaves B(K,J)=0 instead of computing 0/0=NaN, producing inconsistent results across different calling variants of the same triangular solve.

Closes #636

The left-solving non-transposed path in DTRSM/S/CTRSM/ZTRSM has an
optimization that skips the division B(K,J)/A(K,K) when B(K,J) is
exactly zero. When A(K,K) is also zero (singular matrix), this
leaves B(K,J)=0 instead of computing 0/0=NaN, producing inconsistent
results across different calling variants of the same triangular
solve.

Closes Reference-LAPACK#636
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.

DTRSM inconsistent behavior with zeros on the diagonal and an all-zero right-hand side

1 participant