unresolved external symbols: numroc_ & descinit_

unresolved external symbols: numroc_ & descinit_


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.



4 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

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).

Hi TimP,
I tried to directly call in c + + but never failed:

#ifdef __cplusplus
extern "C" {
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
#define dgesd2d_ DGESD2D //OK

the same:
#define numroc_ NUMROC //error: unresolved external symbols

Now wrapped it in pure c and is OK.


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?



Leave a Comment

Please sign in to add a comment. Not a member? Join today