viod*

Hi.
There is a function
int MPI_Bcast( void *buffer, int count, MPI_Datatype datatype, int root, MPI_Comm comm )

Is it possible for me to pass it a two dimensional array **b? How if yes?

Thanks in advance
it's possible ...
but that would be strange, wouldn't it ?

the parameters accept 1 dimensional array doesn't it ??


anyway,
I am assuming that you want to pass it to buffer param
 
void *buffer = ( void * ) ( b );


is this what you want ?
b is a pointer to pointer, and the function accepts just a pointer, so one level of indirection is probably needed.

casting 'b' to a void* is strange. I myself wrote 'b[0]' but am not sure if it gets the job done.
Topic archived. No new replies allowed.