[Scottish] debug

Huard, Elise - D C&W Consultant Elise.Huard at sbs.siemens.co.uk
Thu Jan 22 14:57:15 GMT 2004


yes, sorry, using a core file.  My code 'catches' SIGFPE and a few other
baddies and provokes a segmentation fault, but that's not of great use if i
don't know how to use the core file ...
Thanks for your tips,

> ----------
> From: 	Allan Whiteford[SMTP:allan at whiteford.org.uk]
> Reply To: 	SLUG-list
> Sent: 	22 January 2004 14:45
> To: 	SLUG-list
> Subject: 	Re: [Scottish] debug
> Huard, Elise - D C&W Consultant wrote:
> > Hi,
> > 
> > what would you say are the most useful commands for dbx ? 
> "help" :).
> What commands are useful depends on if you're stepping through code as 
> it runs or examine a core file. If you're familiar with gdb then a lot 
> of versions of dbx include the command "gdb on" which allow you to use 
> gdb style commands such as "bt". "bt" is probably what you think of as 
> "stack". The intrinsic dbx command might be "whereami", I'm afraid I use 
> it with a mixture of dbx and gdb commands.
> To find an FPE error you probably want to turn the signal handling 
> functions off, run the code, get a core file. Load the core file, and 
> find out which line you are on (bt or whereami) - hence which line is 
> dividing by zero[1].
> Thanks,
> Allan
> [1] Floating point exceptions are always division by zero :).
> _______________________________________________
> Scottish mailing list
> Scottish at mailman.lug.org.uk
> http://mailman.lug.org.uk/mailman/listinfo/scottish
This email and any accompanying files are confidential.      If you are
not  the  intended recipient  you  must not use,  copy or disclose the
content.   If you have received this email in error please contact the 
sender by return email and delete this message. 
Thankyou for your co-operation.

More information about the Scottish mailing list