This is the mail archive of the
insight@sources.redhat.com
mailing list for the Insight project.
untangling c & tcl code
- From: Duane Ellis <duane_ellis at franklin dot com>
- To: insight at sources dot redhat dot com
- Date: Wed, 13 Feb 2002 10:11:57 -0500
- Subject: untangling c & tcl code
- Reply-to: duane_ellis at franklin dot com
In a previous thread...
andrew> Just BTW, gdb's internals have changed.
things do look far better. :->
yes, I've noticed. We have 3+ custom ports of GDB for our custom CPU
chips that we do. I maintain them.
I'm in the process of updating one of them a 1998 snapshot release of insight.
Does anybody have a good solution to debugging (er, untangling, and
understanding) how tk and tcl interact with GDB.
My problem:
When I need to figure out how something works I use a debugger to
step through the C code. But then... GDB calls some TK/TCL script
function and I cannot step through that portion in any productive
way.
Oh yea, I can see that the code is calling the cached pre-compiled
bytecode for something.... Just what... is next to impossible
to figure out.
I'd really like to stop right there and start stepping through
the tcl/tk code so I can see how that interacts and then calls
back into the C code at various places.
It's a mixed language debugging problem.
The only solution I've found is to insert lots of "printf()" type
statements in the tcl/tk code and spew forth messages. And that sucks
cause you have to stop, go instrument the tcl/tk code and restart
debug session.
-Duane.