#NEWLINE# def dbg_repr_run( self , run_addr ) : #NEWLINE# #INDENT# '\n        Debugging output of a single SimRun slice.\n\n        :param run_addr:    Address of the SimRun.\n        :return:            A string representation.\n        ' #NEWLINE# if self . project . is_hooked ( run_addr ) : #NEWLINE# #INDENT# ss = ( '%#x Hooked\n' % run_addr ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# ss = ( '%#x\n' % run_addr ) #NEWLINE# chosen_statements = self . chosen_statements [ run_addr ] #NEWLINE# vex_block = self . project . factory . block ( run_addr ) . vex #NEWLINE# statements = vex_block . statements #NEWLINE# for i in range ( 0 , len ( statements ) ) : #NEWLINE# #INDENT# if ( i in chosen_statements ) : #NEWLINE# #INDENT# line = '+' #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# line = '-' #NEWLINE# #UNINDENT# line += ( '[% 3d] ' % i ) #NEWLINE# line += str ( statements [ i ] ) #NEWLINE# ss += ( line + '\n' ) #NEWLINE# #UNINDENT# targets = self . chosen_exits [ run_addr ] #NEWLINE# addr_strs = [ ] #NEWLINE# for ( exit_stmt_id , target_addr ) in targets : #NEWLINE# #INDENT# if ( target_addr is None ) : #NEWLINE# #INDENT# addr_strs . append ( 'default' ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# addr_strs . append ( ( '%#x' % target_addr ) ) #NEWLINE# #UNINDENT# #UNINDENT# ss += ( 'Chosen exits: ' + ', ' . join ( addr_strs ) ) #NEWLINE# #UNINDENT# return ss