guile-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: guile-debugging: how to access source properties from trap context


From: Holger Blasum
Subject: Re: guile-debugging: how to access source properties from trap context
Date: Mon, 2 Jan 2006 23:33:17 +0100
User-agent: Mutt/1.5.6+20040722i

Hello Neil,

On 01-02 and 02-02, Neil Jerram wrote:
> Neil Jerram <address@hidden> writes:
... 
> debug> step
...
> debug> info frame
(iterate ad nauseam)

Thanks that was I was looking for! Hadn't thought of using
"info frame" to spit out the source properties (argh even gdb
does this).

FWIW, maybe I should explain (didnt want to bloat the first posting 
with that) that I am trying to study the inner workings of a theorem prover 
(minlog) so I'm tracing -crudely put- "where the action is". In addition, 
one (admittedly brute force) way of profiling anything in any system 
is just to pipe a long list of "step" + "info frame" into the guile 
[or whatever] stepper and parse the output 
for position information. (Moreover unlike a gprof-approach
I prefer not to loose the sequential order of what 
is called.)

What in that context of stepping would interest me is: is there 
also a trap not only for evaluations and applications but also for 
definitions (I mean performance-wise definitions dont come for free 
either). 

> It's not important for the rest of my reply, but can you indicate
> exactly where in the doc you are referring to, so I can review
> whether this encouragement is worded as well as it could be?

2.4.4 Trap Context: "This information can be accessed through
the procedures beginning tc: that are exported by the (ossau
traps) modules", this had insinuated to me that any
public method would have appeared as 'tc:'-prefixed one (defined 
in the <trap-context> class in the beginning of that source 
file) as opposed to the non 'tc:'-prefixed extra goodies 
you have now mentioned '(trace/source trap-context)'.

While we are at it, to give feedback, for the imperative-language-
impaired like me "2.10 Step Traps" maybe could be renamed to sth 
like "2.10 Step Traps and gdb-like stepping" including the small 
sample you had sent. And a note on profiling (perhaps 2.15?) 
could be sweet. (Disclaimer: these are just ramblings.)

At last, some words on "[FIXME: should we include examples of traditional
debuggers and explain why they can't be used to debug interpreted
Scheme or Lisp?]" 
http://www.gnu.org/software/guile/docs/guile-ref/Debugging-Features.html#Debugging%20Features
might be of interest to anyone still following this thread ;)

Thanks again!

-- 
Holger Blasum +49-174-7313590 (gsm) GnuPG 1024D/ACDFC3B769DC1ED66B47
"It has turned out that the networking of many small computers, at many 
places, is more efficient than the one supercomputer - the success of 
the internet is based on this principle." - Angela Merkel, government
declaration, 30 Nov 2005

Attachment: signature.asc
Description: Digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]