This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Entering GDB stubs from an application


On Thu, 2003-09-04 at 13:00, Doyle, Patrick wrote:
> I am trying to track down a problem right now and I would like to drop my
> application into GDB stubs when an external event happens.  (I have to use
> the serial port to configure and control the application, but I want to go
> in after the fact and poke around).  I tried accessing non-existent memory
> and dividing by zero, neither of which dropped me into GDB stubs.  I tried
> reading the CDL for an option that looked like it would do the trick, but
> came up empty (after trying a few things) there too, so now I turn to you.
> 
> I think I have run into a case where the kernel is helping me by ignoring
> the exception.  In a production system, I think that's a great idea (I don't
> want the production system to drop into GDB stubs for no apparent (to the
> end user) reason), but in this case, I would like to force it to happen.
> 
> Any ideas?
> 
> Since I wrote the HAL myself, it is possible/likely that I missed something.

Try 'breakpoint()' - this should cause an immediate entry into GDB.   If
you then want to continue, you'll have to advance the PC manually over 
the breakpoint instruction.

-- 
Gary Thomas <gary@mlbassoc.com>
MLB Associates


-- 
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss


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