seeking simple program to demo a debugger

B

Baron Samedi

Sounds unbelievable, I know, but I joined a company whether they don't
do any host testing, only target. No one test their code in an IDE on
a PC - they just link it and try to test the whole thing on the
target.

I want to give a quick demo of the benefits of using a decent
debugger. Anything too fancy will be wasted on them, I am afraid, so
just simple tuff like run to cursor, or to breakpoint, examine &
change variables one-step into and over functions, view & unwind call
stack, maybe a watch or two.

I could quickly write some demo code, but why bother? Would anyone
like to recommend something small but which can still provide a good
demo?

Thanks.
 
I

Ian Collins

Baron said:
Sounds unbelievable, I know, but I joined a company whether they don't
do any host testing, only target. No one test their code in an IDE on
a PC - they just link it and try to test the whole thing on the
target.

I want to give a quick demo of the benefits of using a decent
debugger. Anything too fancy will be wasted on them, I am afraid, so
just simple tuff like run to cursor, or to breakpoint, examine &
change variables one-step into and over functions, view & unwind call
stack, maybe a watch or two.

I could quickly write some demo code, but why bother? Would anyone
like to recommend something small but which can still provide a good
demo?
Considering your situation select a piece of their code, build it on
your host and use that.
 
B

Baron Samedi

Considering your situation select a piece of their code, build it on
your host and use that.

I would - that's obviously best, as at least one of them ought to know
it. However, they have a single product with 500 source files and not
the best structure. So I would have to either build the whole system -
and run into problems abstracting the o/s, as they only have a
makefile for VxWorks/Arm, and nothing for Dos/Windows - or I can take
a single file and create dummies for the interfaces, but the lack of
structure makes that difficult.

I will either find or code something simpler. A little "hell world"
with some nested function calls, to show the call stack, and a stuct,
or class, to show some data dump.
 
V

Victor Bazarov

Baron said:
[..]
I will either find or code something simpler. A little "hell world"
with some nested function calls, to show the call stack, and a stuct,
or class, to show some data dump.

Take a somewhat faulty code which you could actually debug. I would
recommend perusing PC-lint's "bug of the month" archives.

V
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,731
Messages
2,569,432
Members
44,832
Latest member
GlennSmall

Latest Threads

Top