[mpich-discuss] how to make mpich crash hard so I can gdb bt it?

Ken Raffenetti raffenet at mcs.anl.gov
Fri Oct 11 17:08:23 CDT 2013


Try:

  MPI_Comm_set_errhandler(MPI_COMM_WORLD, MPI_ERRORS_RETURN);

Or similar for your communicator at runtime.

----- Original Message -----
> From: "Jeff Hammond" <jeff.science at gmail.com>
> To: "MPICH" <discuss at mpich.org>
> Sent: Friday, October 11, 2013 4:44:52 PM
> Subject: [mpich-discuss] how to make mpich crash hard so I can gdb bt it?
> 
> I apologize if this is a stupid question, but I would like MPICH to
> crash and burn rather than terminate gently when an error occurs so
> that I can gdb bt it to know where the error is in my program, since
> I
> am absolutely certain that this error is in the application and not
> MPICH.
> 
> Ideally, I would be able to select the failure mode at runtime, e.g.
> MPICH_FAILURE_MODE={hard,soft}, so that I can get either the nice
> MPICH trace when I think MPICH is the problem and a brutal
> light-the-machine-room-on-fire-and-abort-the-universe error when I
> think it's my fault.
> 
> Thanks,
> 
> Jeff
> 
> <running in gdb>
> Assertion failed in file ../src/mpi/coll/helper_fns.c at line 81:
> FALSE
> memcpy argument memory ranges overlap, dst_=0x101401000
> src_=0x101401000 len_=400
> 
> internal ABORT - process 0
> Fatal error in MPI_Win_free: Other MPI error, error stack:
> MPI_Win_free(134)..........: MPI_Win_free(win=0x10000b394) failed
> MPIDI_CH3_SHM_Win_free(103): pthread mutex routine failed (Resource
> busy)
> 
> Program exited with code 01.
> (gdb) bt
> 
> $ mpichversion
> MPICH Version:    	3.1b2
> MPICH Release date:	unreleased development copy
> MPICH Device:    	ch3:nemesis
> MPICH configure: 	CC=clang CXX=clang++ FC=/bin/false --disable-fc
> --disable-f77 --enable-threads --enable-g --with-pm=hydra
> --prefix=/opt/mpich/dev/clang
> MPICH CC: 	clang    -g -O2
> MPICH CXX: 	clang++   -g -O2
> MPICH F77: 	no   -g
> MPICH FC: 	no   -g
> 
> --
> Jeff Hammond
> jeff.science at gmail.com
> _______________________________________________
> discuss mailing list     discuss at mpich.org
> To manage subscription options or unsubscribe:
> https://lists.mpich.org/mailman/listinfo/discuss
> 



More information about the discuss mailing list