That worked perfectly. Thank you. I'm surprised that clang didn't emit a warning about this!
-Devon On Mon, May 9, 2016 at 3:42 PM, Gilles Gouaillardet < gilles.gouaillar...@gmail.com> wrote: > Devon, > > send() is a libc function that is used internally by Open MPI, and it uses > your user function instead of the libc ne. > simply rename your function mysend() or something else that is not used by > libc, and your issue will likely be fixed > > Cheers, > > Gilles > > > On Tuesday, May 10, 2016, Devon Hollowood <devonhollow...@gmail.com> > wrote: > >> Hello, >> >> I am having trouble understanding why I am getting an error when running >> the program produced by the attached C file. In this file, there are three >> short functions: send(), bounce() and main(). send() and bounce() both use >> MPI_Send() and MPI_Recv(), but critically, neither one is called from >> main(), so as I understand it, neither function should ever be run. main() >> is just: >> >> int main(int argc, char *argv[]) { >>> int rank; >>> >>> MPI_Init(&argc, &argv); >>> MPI_Comm_rank(MPI_COMM_WORLD, &rank); >>> >>> MPI_Finalize(); >>> } >>> >> >> Despite the fact that the program should never enter send() or bounce(), >> when I compile with >> >> mpicc mpi-issue.c -o mpi-issue >>> >> >> and run with >> >> mpirun -n 2 --verbose ./mpi-issue >>> >> >> I get the following: >> >> *** An error occurred in MPI_Send >>> *** on a NULL communicator >>> *** MPI_ERRORS_ARE_FATAL (processes in this communicator will now abort, >>> *** and potentially your MPI job) >>> [dhcp-visitor-enr-117-111.slac.stanford.edu:99119] Local abort before >>> MPI_INIT completed successfully; not able to aggregate error messages, and >>> not able to guarantee that all other processes were killed! >>> ------------------------------------------------------- >>> Primary job terminated normally, but 1 process returned >>> a non-zero exit code.. Per user-direction, the job has been aborted. >>> ------------------------------------------------------- >>> >>> -------------------------------------------------------------------------- >>> mpirun detected that one or more processes exited with non-zero status, >>> thus causing >>> the job to be terminated. The first process to do so was: >>> >>> Process name: [[2829,1],0] >>> Exit code: 1 >>> >>> -------------------------------------------------------------------------- >>> >>> >> >> How is it possible to be getting an error in MPI_Send(), if MPI_Send() >> never gets run? >> >> I am running open-mpi 1.10.2, installed via the Homebrew open-mpi >> package, and this is running on my Macbook, which is running OSX Yosemite. >> I have attached the results of ompi_info --all as ompi_info.txt.bz2 >> >> Any help would be appreciated! Sorry if this is a newb question and I am >> missing something obvious--I tried my best to search for this issue but I >> couldn't find anything. >> >> -Devon >> > > _______________________________________________ > users mailing list > us...@open-mpi.org > Subscription: https://www.open-mpi.org/mailman/listinfo.cgi/users > Link to this post: > http://www.open-mpi.org/community/lists/users/2016/05/29147.php >