lapack icon indicating copy to clipboard operation
lapack copied to clipboard

CBLAS Interface for the Skew-Symmetric Matrices

Open grisuthedragon opened this issue 1 month ago • 7 comments

Although #1155 provides the skew symmetric matrix suppport, the CBLAS interface is missing. The CBLAS interface should be adjusted accordingly.

grisuthedragon avatar Nov 26 '25 07:11 grisuthedragon

That's a good point @grisuthedragon. Thanks.

tagging @sh-zheng so that they are aware of this issue

langou avatar Nov 26 '25 08:11 langou

Yes, CBLAS is in progress. It will be submitted in several days.

After that, the skew-symmetric linear solver, corresponding lapacke, the skew-symmetric eigensolver, and corresponding lapacke.

sh-zheng avatar Nov 26 '25 13:11 sh-zheng

CBLAS is in PR #1169 .

sh-zheng avatar Nov 26 '25 17:11 sh-zheng

There is another point.

Now the blas subroutine *gemmtr has been adopted in symmetric Bunch-Kaufman decomposition. But it will disturb the diagonal element and can't be used directly in skew-symmetric decomposition. I'm not sure which of the following choice would be the best:

a. Keep the skew-symmetric code unchanged and don't use *gemmtr. b. Implement a new blas subroutine to update strictly triangle matrix (named *gemmstr or *gemmtrs). c. Add a new parameter to indicate the type of operation (including or excluding the diagonal). But this may make trouble for users. d. Add new meaning to the certain existed parameter (which is suitable).

sh-zheng avatar Nov 27 '25 13:11 sh-zheng

Since gemmtr is the new name for the gemmt functionality, which is already used in a bunch of places (not only in LAPACK), it's interface could not be changed. So option c is out. B means maintaining a 95% equal code, which is also not the best option. So either a) oder is there an option with creating a backup of the diagonal? D) we can add new meanings for the upper/lower parameter. But U and L independent of the case are out.

grisuthedragon avatar Nov 27 '25 13:11 grisuthedragon

I will not introduce gemmtr in my next submission, but in a long run I would like to adopt it.

Backup of the diagonal lies on how we interpret "undisturbed", just keep the value, or never access them (may be important in parallel). So I tend to add new meanings. Since U and L are unmodifiable, maybe we can adopt Top and Bottom (like in *lasr)?

sh-zheng avatar Nov 27 '25 14:11 sh-zheng

I think top and bottom are fine.

grisuthedragon avatar Nov 27 '25 16:11 grisuthedragon