|
3 年之前 | |
---|---|---|
.. | ||
CMakeLists.txt | de2939e222 HPCC-27136 Clean up CMake warnings and errors | 3 年之前 |
README.md | adae826495 HPCC-16282 Add BLAS wrappers as standard library attributes and plugins | 8 年之前 |
dasum.cpp | 937173f4fe HPCC-16571 Mangle the functions exported from eclblas plugin | 8 年之前 |
daxpy.cpp | 937173f4fe HPCC-16571 Mangle the functions exported from eclblas plugin | 8 年之前 |
dgemm.cpp | bcf397408e HPCC-17543 Work around misaligned double access in eclblas::dgemm | 8 年之前 |
dgetf2.cpp | 937173f4fe HPCC-16571 Mangle the functions exported from eclblas plugin | 8 年之前 |
dpotf2.cpp | 937173f4fe HPCC-16571 Mangle the functions exported from eclblas plugin | 8 年之前 |
dscal.cpp | 937173f4fe HPCC-16571 Mangle the functions exported from eclblas plugin | 8 年之前 |
dsyrk.cpp | 937173f4fe HPCC-16571 Mangle the functions exported from eclblas plugin | 8 年之前 |
dtrsm.cpp | 937173f4fe HPCC-16571 Mangle the functions exported from eclblas plugin | 8 年之前 |
eclblas.cpp | adae826495 HPCC-16282 Add BLAS wrappers as standard library attributes and plugins | 8 年之前 |
eclblas.hpp | 116fab0239 Merge branch 'candidate-6.2.0' into candidate-6.4.0 | 8 年之前 |
extract_tri.cpp | fa2e97e93e HPCC-16655 Extract_Tri anomaly in eclblas | 8 年之前 |
lib_eclblas.ecllib | fa2e97e93e HPCC-16655 Extract_Tri anomaly in eclblas | 8 年之前 |
make_diag.cpp | 937173f4fe HPCC-16571 Mangle the functions exported from eclblas plugin | 8 年之前 |
sourcedoc.xml | adae826495 HPCC-16282 Add BLAS wrappers as standard library attributes and plugins | 8 年之前 |
This is the ECL plugin to utilize the Basic Linear Algebra Sysem (BLAS). It utilizes the C wrappers for BLAS
To build the plugin with the HPCC-Platform, is required.
sudo apt-get install atlas-dev
The libcblas.so library can be found in several packages including ATLAS and LAPACK.
The eclblas plugin features are exposed via the ECL Standard library Std.BLAS module.
###An ECL Example
IMPORT Std.BLAS AS BLAS;
IMPORT BLAS.Types AS Types;
Types.matrix_t init1 := [1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0];
Types.matrix_t init2 := [9.0, 8.0, 7.0, 6.0, 5.0, 4.0, 3.0, 2.0, 1.0];
Types.matrix_t init3 := [1.0, 2.0, 3.0];
Types.matrix_t init4 := [2.0, 2.0, 2.0];
Test1_mat := BLAS.dgemm(FALSE, TRUE, 3, 3, 1, 1.0, init3, init4);
Test2_mat := BLAS.dgemm(TRUE, FALSE, 1, 1, 3, 1.0, init3, init4);
Test3_mat := BLAS.dgemm(FALSE, TRUE, 3, 1, 3, -1.0, init1, init4);
Test4_mat := BLAS.dgemm(FALSE, TRUE, 3, 1, 3, 1.0, init1, init4, 5, init3);
OUTPUT(Test1_mat);
OUTPUT(Test2_mat);
OUTPUT(Test3_mat);
OUTPUT(test4_mat);
Yields the various matrix products.
All of the arrays are column major. The underlying Fortran code expects column major, so we do not need the library to interpret the data as row major (usual C convention).