0

http://scicomp.stackexchange.comで、IDLの並列行列アルゴリズムについてこの質問をしました。回答は、マルチスレッドのLAPACK実装を使用することを提案し、IDLに特定のLAPACKライ​​ブラリを使用させるためのいくつかのハックを提案します。私はこれを機能させることができませんでした。

理想的には、既存のLAPACK DLMでマルチスレッドのLAPACKライ​​ブラリを使用できるようにしたいと思います。これは可能であると思われますが、成功していません。あるいは、次の最も簡単なステップは、新しいDLMを作成して、行列反転呼び出しをCコードでラップし、このDLMが目的の実装を指していることを確認することだと思います。ただし、DLMを作成するためのドキュメントは斜視になっているので、これを行うためのヒント(必要な場合)もありがたいです。

4

1 に答える 1

1

What platform are you targeting?

Looking at idl_lapack.so with nm on my platform (Mac OS X, IDL 8.2.1) seems to indicate that the LAPACK routines are directly in the .so, so my (albeit limited) understanding is that it would not be simple to swap out (i.e., by setting LD_LIBRARY_PATH).

$ nm idl_lapack.so
...
000000000023d5bb t _dgemm_
000000000023dfcb t _dgemv_
000000000009d9be t _dgeqp3_
000000000009e204 t _dgeqr2_
000000000009e41d t _dgeqrf_
000000000023e714 t _dger_
000000000009e9ad t _dgerfs_
000000000009f4ba t _dgerq2_
000000000009f6e1 t _dgerqf_

Some other possibilities...

My personal library has a directory src/dist_tools/bindings containing routines for automatically creating bindings for a library given "simple" (i.e., not using typedefs) function prototypes. LAPACK would be fairly easy to create bindings for (the hardest part would probably be to build the package you want to use ATLAS, PLAPACK, ScaLAPACK, etc.). The library is free to use, a small consulting contract could be done if you would like it done for you.

The next version of GPULib will contain a GPU implementation of LAPACK, using the MAGMA library. This is effectively a highly parallel option, but only works on CUDA graphics cards. It would also work best if other operations besides the matrix inversion could be done on the GPU to minimize memory transfer. This option costs money.

于 2013-01-11T00:12:31.263 に答える