robertsmith632 wrote:Maybe I can try and retry until something works, but I am really short on time, so if I could find directions or a no-src-but-many-docs package, that would be great.
graphicsRat wrote:Josselin wrote:My dll is compiled with msys.
I do a dll with my visual studio project.
Do you mean to say that you're creating a dll project in Visual Studio? (Note that compiling the GotoBLAS2 dll in MSYS is a different issue and must not be confused.)
If you are creating a dll project in Visual Studio, you may want to first try a writing small console application in order to test your GotoBLAS2 build.
Try the sample program here http://www.cs.rochester.edu/~bh/cs400/using_lapack.html
If you've (saved your file as *.cpp and are) compiling with C++, rename the prototypes
void dgesv_( )
void dgels_( )
in the above program to
extern "C" void dgesv_( )
extern "C" void dgels_( )
and don't forget to use the "Multithreaded-Debug (/MTd)" runtime library.Josselin wrote:I use /MTd or MT but it doesn t work.
What exactly do you mean? What errors are you getting?
If you are creating a dll in visual studio, use the Multi-threaded Debug DLL (/MDd) runtime library.
I've got two visual studio projects in my solution file, both using LAPACK. The first one is a console application and therefore uses the "Multithreaded-Debug (/MTd)" runtime library while the second is dll (AutoDesk Maya Plugin) and therefore uses the Multi-threaded Debug DLL (/MDd) runtime library. Why? because dlls and console applications (debug or release) cannot link against the same version of the C or C++ runtime library.
graphicsRat wrote:flexo1234 wrote:But now if I compare the time it takes to do a matrix-vector multiplication with this optimized BLAS library and with Matlab, Matlab is still a bit faster. Is this normal? Did anyone else compare the speed between these?
Did you use the BLAS subroutines SGEMV and DGEMV (GotoBLAS implements both). They should outperform Matlab by many orders of magnitude. I would be very surprised if they didn't.
A1(i, j) = 0;
A2(i, j) = 0;
AN(i,j) = 0;
A1(i, j) = A1(i, j) + B1(i,k)*C1(k,i);
A2(i, j) = A2(i, j) + B2(i,k)*C2(k,i);
AN(i, j) = AN(i, j) + BN(i,k)*CN(k,i);
Do the routines dgemv and dgemm run in parallel? If they are not, how different is it running the BLAS routine to coding my own loops in C to make the multiplication?
Users browsing this forum: No registered users and 4 guests