Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[RFC]: Add BLAS bindings and implementations for linear algebra (tracking issue) #2039

Open
aman-095 opened this issue Mar 25, 2024 · 10 comments
Labels
Accepted RFC feature request which has been accepted. BLAS Issue or pull request related to Basic Linear Algebra Subprograms (BLAS). C Issue involves or relates to C. difficulty: 4 Likely to be moderately difficult. Feature Issue or pull request for adding a new feature. Fortran Issue involves or relates to Fortran. JavaScript Issue involves or relates to JavaScript. Native Addons Issue involves or relates to Node.js native add-ons. priority: High High priority concern or feature request. RFC Request for comments. Feature requests and proposed changes. Tracking Issue Tracking issue.

Comments

@aman-095
Copy link
Contributor

aman-095 commented Mar 25, 2024

Description

This RFC proposes adding BLAS routines. The purpose of this issue is to serve as a tracking issue for adding BLAS routines.

Implementation Status for BLAS Routines

Level 1

Single Precision

  • SROTG
  • SROTMG
  • SROT
  • SROTM
  • SSWAP
  • SSCAL
  • SCOPY
  • SAXPY
  • SDOT
  • SDSDOT
  • SNRM2
  • SCNRM2
  • SASUM
  • ISAMAX

Double Precision

  • DROTG
  • DROTMG
  • DROT
  • DROTM
  • DSWAP
  • DSCAL
  • DCOPY
  • DAXPY
  • DDOT
  • DSDOT
  • DNRM2
  • DZNRM2
  • DASUM
  • IDAMAX

Complex Single

  • CROTG
  • CSROT
  • CSWAP
  • CSCAL
  • CSSCAL
  • CCOPY
  • CAXPY
  • CDOTU
  • CDOTC
  • SCASUM
  • ICAMAX

Complex Double

  • ZROTG
  • ZDROT
  • ZSWAP
  • ZSCAL
  • ZDSCAL
  • ZCOPY
  • ZAXPY
  • ZDOTU
  • ZDOTC
  • DZASUM
  • IZAMAX

Level 2

Single Precision

  • SGEMV
  • SGBMV
  • SSYMV
  • SSBMV
  • SSPMV
  • STRMV
  • STBMV
  • STPMV
  • STRSV
  • STBSV
  • STPSV
  • SGER
  • SSYR
  • SSPR
  • SSYR2
  • SSPR2

Double Precision

  • DGEMV
  • DGBMV
  • DSYMV
  • DSBMV
  • DSPMV
  • DTRMV
  • DTBMV
  • DTPMV
  • DTRSV
  • DTBSV
  • DTPSV
  • DGER
  • DSYR
  • DSPR
  • DSYR2
  • DSPR2

Complex Single

  • CGEMV
  • CGBMV
  • CHEMV
  • CHBMV
  • CHPMV
  • CTRMV
  • CTBMV
  • CTPMV
  • CTRSV
  • CTBSV
  • CTPSV
  • CGERU
  • CGERC
  • CHER
  • CHPR
  • CHER2
  • CHPR2

Complex Double

  • ZGEMV
  • ZGBMV
  • ZHEMV
  • ZHBMV
  • ZHPMV
  • ZTRMV
  • ZTBMV
  • ZTPMV
  • ZTRSV
  • ZTBSV
  • ZTPSV
  • ZGERU
  • ZGERC
  • ZHER
  • ZHPR
  • ZHER2
  • ZHPR2

Level 3

Single Precision

  • SGEMM
  • SSYMM
  • SSYRK
  • SSYR2K
  • STRMM
  • STRSM

Double Precision

  • DGEMM
  • DSYMM
  • DSYRK
  • DSYR2K
  • DTRMM
  • DTRSM

Complex Single

  • CGEMM
  • CSYMM
  • CHEMM
  • CSYRK
  • CHERK
  • CSYR2K
  • CHER2K
  • CTRMM
  • CTRSM

Complex Double

  • ZGEMM
  • ZSYMM
  • ZHEMM
  • ZSYRK
  • ZHERK
  • ZSYR2K
  • ZHER2K
  • ZTRMM
  • ZTRSM

Related Issues

None.

Questions

No.

Other

No.

Checklist

  • I have read and understood the Code of Conduct.
  • Searched for existing issues and pull requests.
  • The issue name begins with RFC:.
@performant23
Copy link
Contributor

Hello, thanks @aman-095 for adding this tracker. So, I just wanted to let you know that I am working on ZSWAP just so we don't end up working on the same package :)

Apologies for not adding an issue for the same earlier, thanks!

@kgryte kgryte added RFC Request for comments. Feature requests and proposed changes. Feature Issue or pull request for adding a new feature. Native Addons Issue involves or relates to Node.js native add-ons. Accepted RFC feature request which has been accepted. BLAS Issue or pull request related to Basic Linear Algebra Subprograms (BLAS). priority: High High priority concern or feature request. Tracking Issue Tracking issue. Fortran Issue involves or relates to Fortran. C Issue involves or relates to C. difficulty: 4 Likely to be moderately difficult. JavaScript Issue involves or relates to JavaScript. labels Mar 28, 2024
kgryte added a commit that referenced this issue Apr 3, 2024
PR-URL: 	#2064
Ref: #2039
Co-authored-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Athan Reines <kgryte@gmail.com> 
Signed-off-by: Athan Reines <kgryte@gmail.com>
kgryte added a commit that referenced this issue Apr 3, 2024
PR-URL: 	#2075
Closes: #2047
Ref: #2039
Ref: https://netlib.org/lapack/explore-html-3.6.1/d2/df9/group__complex16__blas__level1_ga13a187010a0cae1fef2820072404e857.html#ga13a187010a0cae1fef2820072404e857
Co-authored-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Athan Reines <kgryte@gmail.com> 
Signed-off-by: Athan Reines <kgryte@gmail.com>
Co-authored-by: stdlib-bot <82920195+stdlib-bot@users.noreply.github.com>
@aman-095
Copy link
Contributor Author

Working on idamax and isamax level 1 routines. 

@performant23
Copy link
Contributor

Working on csscal (L1)

@kgryte
Copy link
Member

kgryte commented Apr 12, 2024

@performant23 That one is already being worked on in #2104.

@kgryte
Copy link
Member

kgryte commented Apr 12, 2024

@performant23 Maybe try dznrm2?

@performant23
Copy link
Contributor

performant23 commented Apr 12, 2024

Oh, hey! I think csscal is different right? In cscal we have a complex scalar and in csscal we have a real scalar if I remember correctly.

@kgryte
Copy link
Member

kgryte commented Apr 12, 2024

Ah, you're right. That one should be straightforward.

@performant23
Copy link
Contributor

Hi @kgryte, we would need a generic interface to perform Givens rotation with vectors of other data types like integers, right? If so, I'd like to work on such an interface i.e. grot to get an idea of how generic g* interfaces are sampled from their equivalent d* implementations and also since we have implementations for those available for this package (JS implementation for drot is reviewed), this should be good to go!

@aman-095
Copy link
Contributor Author

Working on Level 1 routine drotm

@kgryte
Copy link
Member

kgryte commented Apr 16, 2024

@performant23 Yes, go for it. The one thing you need to do is ensure accessor array support. See gcopy and gswap for an idea.

kgryte added a commit that referenced this issue Apr 16, 2024
PR-URL: 	#2152
Ref: #2039
Co-authored-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Philipp Burckhardt <pburckhardt@outlook.com>
Reviewed-by: Pranav Goswami <goswami.4@iitj.ac.in>
kgryte added a commit that referenced this issue Apr 19, 2024
PR-URL: #1823
Closes: #276
Ref: #2039
Co-authored-by: Athan Reines <kgryte@gmail.com>
Co-authored-by: Pranav Goswami <goswami.4@iitj.ac.in>
Reviewed-by: Athan Reines <kgryte@gmail.com> 
Reviewed-by: Pranav Goswami <goswami.4@iitj.ac.in>
Signed-off-by: Athan Reines <kgryte@gmail.com>
Signed-off-by: Pranav Goswami <goswami.4@iitj.ac.in>
kgryte added a commit that referenced this issue Apr 20, 2024
PR-URL: #1844
Closes: #277
Ref: #2039
Co-authored-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Athan Reines <kgryte@gmail.com>
kgryte added a commit that referenced this issue Apr 20, 2024
PR-URL: #2153
Ref: #2039
Co-authored-by: Athan Reines <kgryte@gmail.com>
Reviewed-by: Athan Reines <kgryte@gmail.com>
@kgryte kgryte pinned this issue Apr 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Accepted RFC feature request which has been accepted. BLAS Issue or pull request related to Basic Linear Algebra Subprograms (BLAS). C Issue involves or relates to C. difficulty: 4 Likely to be moderately difficult. Feature Issue or pull request for adding a new feature. Fortran Issue involves or relates to Fortran. JavaScript Issue involves or relates to JavaScript. Native Addons Issue involves or relates to Node.js native add-ons. priority: High High priority concern or feature request. RFC Request for comments. Feature requests and proposed changes. Tracking Issue Tracking issue.
Projects
None yet
Development

No branches or pull requests

3 participants