This is the mail archive of the gdb@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: signal names


> Hello!
> 
> Is there any convenient way to add custom signal names, used by
> 
> /* Return the string for a signal.  */
> extern char *target_signal_to_string PARAMS ((enum target_signal));
> 
> /* Return the name (SIGHUP, etc.) for a signal.  */
> extern char *target_signal_to_name PARAMS ((enum target_signal));
> 
> /* Given a name (SIGHUP, etc.), return its signal.  */
> enum target_signal target_signal_from_name PARAMS ((char *));
> 
> We would need special hardware names, which will be used for
> catchpoints?
> I would really like to avoid adding ifdefs in target.c and target.h

Not really.

GDB has a very UNIX/signal centric view of the target's event model.  It 
assumes that everything to do with a target event can be represented as 
a very small integer - with real hardware events that is almost never 
the case.

People debugging embedded systems typically map hardware signals onto 
roughly equivalent UNIX signals.  From what I've seen this works pretty 
well.


	Andrew



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]