From: Han-Wen Nienhuys <hanwen@xs4all.nl>
Cc: guile-devel@gnu.org
Subject: Re: frames / stacks / source? was Re: coverage/profiling
Date: Wed, 10 Jan 2007 16:43:58 +0100 [thread overview]
Message-ID: <45A509BE.7060100@xs4all.nl> (raw)
In-Reply-To: <87wt3vhmon.fsf@ossau.uklinux.net>
Neil Jerram escreveu:
> Han-Wen Nienhuys <hanwen@xs4all.nl> writes:
>
>> Since noone responded, I decided to take a look myself.
>> My overall idea was to do the following:
>>
>> - at the top of deval(), find out current source file and line
>
> OK, but with the code where you have it at the moment, you'll miss
> tail-recursive calls.
>
>> - invoke some kind of callback that increments a counter for the
>> source location
>>
>> - produce pretty pretty coverage graphs with the contents of the hash
>>
>> The last two steps are trivial, but I'm getting lost with the first
>> step.
>>
>> I tried to follow what happens when an error backtrace is generated.
>> My try is below. Unfortunately, I can't find much documentation on how
>> frames/stacks/etc. interact. Can anyone gently nudge me in the right
>> direction?
>
> Do you think you need to do this in C? (You might do, for reasonable
Unfortunately, this is way too slow.
**
[lilydev@haring lilypond]$ time lilypond input/example-1
GNU LilyPond 2.11.10
Hangup
real 0m2.534s
user 0m2.456s
sys 0m0.063s
[lilydev@haring lilypond]$ time lilypond -dcoverage input/example-1
GNU LilyPond 2.11.10
Hangup
real 1m22.184s
user 1m19.808s
sys 0m0.235s
**
Perhaps the better option is to somehow instrument the code such that
memoization of an expression records the coverage. Then we won't get
execution counts, but it should be almost as fast as normal running.
--
Han-Wen Nienhuys - hanwen@xs4all.nl - http://www.xs4all.nl/~hanwen
_______________________________________________
Guile-devel mailing list
Guile-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-devel
next prev parent reply other threads:[~2007-01-10 15:43 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-01-02 18:19 coverage/profiling Han-Wen Nienhuys
2007-01-08 23:48 ` frames / stacks / source? was coverage/profiling Han-Wen Nienhuys
2007-01-09 9:10 ` Ludovic Courtès
2007-01-09 13:32 ` Han-Wen Nienhuys
2007-01-09 14:07 ` Andy Wingo
2007-01-09 22:05 ` Kevin Ryde
2007-01-09 22:15 ` Neil Jerram
2007-01-09 22:45 ` Han-Wen Nienhuys
2007-01-09 22:48 ` Han-Wen Nienhuys
2007-01-10 8:46 ` Neil Jerram
2007-01-10 12:59 ` Han-Wen Nienhuys
2007-01-10 9:16 ` Ludovic Courtès
2007-01-10 11:44 ` Han-Wen Nienhuys
2007-01-17 22:57 ` Kevin Ryde
2007-01-10 15:43 ` Han-Wen Nienhuys [this message]
2007-01-11 8:46 ` Ludovic Courtès
2007-01-11 10:19 ` Han-Wen Nienhuys
2007-01-11 15:57 ` Ludovic Courtès
2007-01-14 0:36 ` Neil Jerram
2007-01-18 23:15 ` Kevin Ryde
2007-01-27 18:12 ` Neil Jerram
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/guile/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=45A509BE.7060100@xs4all.nl \
--to=hanwen@xs4all.nl \
--cc=guile-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).