[racket-dev] Passing flvectors to BLAS and LAPACK

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Thu Dec 20 21:33:40 EST 2012

`flvector->cpointer'?

At Thu, 20 Dec 2012 19:17:13 -0700, Neil Toronto wrote:
> How hard would it be to allow flvectors to be passed to foreign 
> functions as double pointers?
> 
> BLAS and LAPACK linear algebra functions primarily accept pointers to 
> floating-point arrays in row-major order. If we could send flvectors 
> directly (or at least pointers to their elements), we could reuse the 
> `FlArray' type for LAPACK-accelerated matrices, cut down on copying, and 
> more easily transparently use LAPACK on systems that have it.
> 
> Would it require somehow allocating flvectors with 'atomic-interior so 
> they wouldn't be relocated?
> 
> Neil ⊥
> 
> _________________________
>   Racket Developers list:
>   http://lists.racket-lang.org/dev


Posted on the dev mailing list.