[cig-commits] commit: added flag "pauseToAttachDebugger" to create a delay during the AssignFromXML phase. this is useful when trying to attach a debugger for mpi debugging.

Mercurial hg at geodynamics.org
Mon Feb 1 15:32:06 PST 2010


changeset:   696:a472698bbd09
branch:      pcu_rejig
user:        JohnMansour <john.mansour at maths.monash.edu.au>
date:        Thu Nov 19 15:51:21 2009 +1100
files:       Base/Context/src/AbstractContext.c
description:
added flag "pauseToAttachDebugger" to create a delay during the AssignFromXML phase.  this is useful when trying to attach a debugger for mpi debugging.


diff -r dacbbdea91a5 -r a472698bbd09 Base/Context/src/AbstractContext.c
--- a/Base/Context/src/AbstractContext.c	Wed Nov 18 18:22:17 2009 +1100
+++ b/Base/Context/src/AbstractContext.c	Thu Nov 19 15:51:21 2009 +1100
@@ -352,6 +352,9 @@ void _AbstractContext_AssignFromXML( voi
 	
 	Journal_Printf( self->debug, "In: %s\n", __func__ );
 
+   /* the following just pauses at this point to allow time to attach a debugger.. useful for mpi debugging */
+   sleep( Dictionary_Entry_Value_AsUnsignedInt(Dictionary_GetDefault( self->dictionary, "pauseToAttachDebugger", Dictionary_Entry_Value_FromUnsignedInt( 0 )) ) ); 
+      
 	/* Main input parameters */
 	self->frequentOutputEvery = Dictionary_Entry_Value_AsUnsignedInt( 
 		Dictionary_GetDefault( self->dictionary, "outputEvery", Dictionary_Entry_Value_FromUnsignedInt( 1 ) ) );



More information about the CIG-COMMITS mailing list