Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Beginner
15 Views

unresolved external symbols: numroc_ & descinit_

Hi,

How can I call the functions numroc_ and descinit_  in c + +. I just read a similar posts but still do not know how to link these two functions.

Thanks,

Stan

0 Kudos
3 Replies
Highlighted
Black Belt
15 Views

Those look like Fortran functions compiled according to the most common default for linux, MAC, BSD (but not Windows). A direct call from C++ would use those function names literally with extern "C" qualifier, and of course parameters by reference. For choice of corresponding MKL libraries, if -mkl isn't what you want, you would use the MKL link advisor (if it is active today).
0 Kudos
Highlighted
Beginner
15 Views

Hi TimP, I tried to directly call in c + + but never failed: #ifdef __cplusplus extern "C" { #endif void Cblacs_pinfo(int* mypnum, int* nprocs); // OK void Cigebs2d(int icontxt, char *scope, char *top, int m, int n, int *A, int lda); //OK void descinit_(int *idescal, int *m, int *n,int *mb,int *nb, int *dummy1 , int *dummy2 , int *icon, int *mla, int *info); //error: unresolved external symbols int numroc_(int *n, int *nb, int *iproc, int *isrcprocs, int *nprocs); //error: unresolved external symbols #ifdef __cplusplus } #endif #define dgesd2d_ DGESD2D //OK the same: #define numroc_ NUMROC //error: unresolved external symbols Now wrapped it in pure c and is OK. Regards Stan
0 Kudos
Highlighted
Beginner
15 Views

Hello, I'm having a similar problem here.

I've recently aquired Composure XE 2013 with MKL and tried to run the example programs for pblasc but have been unable.  When looking into the problem I think it is because these basic functions, numroc_ and descinit_, don't seem to be in the include files.  Since numroc_ and descinit_ are not in the include files in any form, should I simply add them to mkl_pblas.h with the above data types as inputs and just hope they are in the libraries and give the right output?

Thanks,

-Gabe

0 Kudos