LAPACK Archives

[Lapack] One more bug in LAPACK: real workspace size in (C/Z)GELSD is un


ZGELSD crashes on large matrices (eq M=N=NHRS>=88), if real workspace allocated 
exactly as reported on workspace query.
Root cause is wrong estimation of real workspace size in ZLALSA (on path 
zgelsd->zlalsd->zlalsa). It assumes that RWORK array length should be max( N, 
(SMLSZ+1)*NRHS*3 ), where SMLSIZ=25. But in fact the function calls zlals0 
which requires RWORK to be ( K*(1+NRHS) + 2*NRHS ), where K could be as large 
as number of columns in matrix A.
The same is actual for CGELSD.
Example of diff which fixes the problem is attached.


Closed Joint Stock Company Intel A/O
Registered legal address: Krylatsky Hills Business Park, 
17 Krylatskaya Str., Bldg 4, Moscow 121614, 
Russian Federation

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.
-------------- next part --------------
An HTML attachment was scrubbed...
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: diff.txt

<Prev in Thread] Current Thread [Next in Thread>

For additional information you may use the LAPACK/ScaLAPACK Forum.
Or one of the mailing lists, or