GNU bug report logs - #42574
Probable (system vm trace) bug

Previous Next

Package: guile;

Reported by: Prafulla Giri <pratheblackdiamond <at> gmail.com>

Date: Tue, 28 Jul 2020 09:39:01 UTC

Severity: normal

Done: lloda <lloda <at> sarc.name>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 42574 in the body.
You can then email your comments to 42574 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guile <at> gnu.org:
bug#42574; Package guile. (Tue, 28 Jul 2020 09:39:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Prafulla Giri <pratheblackdiamond <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-guile <at> gnu.org. (Tue, 28 Jul 2020 09:39:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Prafulla Giri <pratheblackdiamond <at> gmail.com>
To: bug-guile <at> gnu.org
Subject: Probable (system vm trace) bug
Date: Tue, 28 Jul 2020 15:23:19 +0545
[Message part 1 (text/plain, inline)]
Esteemed Maintainers,

I am quite positive that what I am experiencing is not quite a bug but just
some mis-step on my part. But I have been encouraged to report this as a
possible bug. Thus, here it is.

Context:
Guile version: 3.0.2 (installed using guix)
Loaded Files: simply.scm (
https://github.com/hosoe-masaki/SimplyScheme/blob/master/simply.scm)
Reverse function (referred to in the report, assumes 'simply.scm' has been
loaded):
(define (reverse wd) (if (equal? wd "") "" (word (reverse (bf wd)) (first
wd))))
;; (reverse 'asdf) -> 'fdsa

This started with my first wanting to run a (trace) of a recursive
procedure as seen in Chapter 13 of the book 'Simply Scheme' (
https://people.eecs.berkeley.edu/~bh/ssch13/convince-recur.html). I looked
for a waay to (trace) in guile, but couldn't find anything except ,trace,
which was giving a trace of everything that the function (reverse) called
from inside of it, thus making the trace 'polluted'.

I then looked around and found that a (trace) function, much like the one
being demonstrated in the book used to exist once in guile:
https://www.gnu.org/software/guile/docs/docs-1.8/guile-ref/Tracing.html and
then found that for guile3 there was something that looked similarly
promising: the (trace-calls-to-procedure) function (
https://www.gnu.org/software/guile/docs/master/guile.html/Tracing-Traps.html).
However,
> (trace-calls-to-procedure reverse)
> (reverse 'asdf)
fdsa
produced no trace. This led me to ask around IRC for some guidance
regarding it. Someone from #emacs suggested I try doing this:
http://ix.io/2suZ
When I attempted to do the same thing, however, I encountered the following
error, at the sight of which, it was recommended that I file a (possible)
bug report: https://termbin.com/6nm5

The following `script` typescript might also be of interest to the
maintainers (to be replayed using `scriptreplay`):
typescript - https://termbin.com/sx5o
timing file - https://termbin.com/73ei
(This one records the (call-with-trace) call with both #:call? #f and
without the specification).

I must confess, I don't understand a whole lot of this. All I would like to
say is that I have a feeling (trace-calls-to-procedure procedure) should
have worked like (trace) as shown in chapter 13 section 'trace' in the book
(https://people.eecs.berkeley.edu/~bh/ssch13/convince-recur.html); it just
seems 'right' by the name of it. I was expecting the trace from
(trace-call-to-procedure
reverse) (reverse 'asdf) to be basically like ,trace (reverse 'asdf) but
without the traces of all other procedures.

Please do let me know if I have left out any important details. And please
do let me know if I am doing something wrong here. I am almost quite
certain this is just a minor error on my part, rather than a bug (and I'd
really like to be able to trace those procedures).
[Message part 2 (text/html, inline)]

Information forwarded to bug-guile <at> gnu.org:
bug#42574; Package guile. (Wed, 29 Jul 2020 15:05:01 GMT) Full text and rfc822 format available.

Message #8 received at 42574 <at> debbugs.gnu.org (full text, mbox):

From: Prafulla Giri <pratheblackdiamond <at> gmail.com>
To: 42574 <at> debbugs.gnu.org
Subject: Permanent Records
Date: Wed, 29 Jul 2020 20:49:06 +0545
[Message part 1 (text/plain, inline)]
I just realized that the termbin links are going to expire in a month or
so. Therefore I am attaching files containing the contents of the links
here.

Please pardon the inconvenience.
[Message part 2 (text/html, inline)]
[emacs_suggestion (application/octet-stream, attachment)]
[simply.scm (text/x-scheme, attachment)]
[possible-bug (application/octet-stream, attachment)]
[typescript (application/octet-stream, attachment)]
[timingfile (application/octet-stream, attachment)]

Information forwarded to bug-guile <at> gnu.org:
bug#42574; Package guile. (Sat, 01 Aug 2020 13:06:01 GMT) Full text and rfc822 format available.

Message #11 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Prafulla Giri <pratheblackdiamond <at> gmail.com>
To: bug-guile <at> gnu.org
Subject: Re: Probable (system vm trace) bug
Date: Sat, 1 Aug 2020 18:50:38 +0545
[Message part 1 (text/plain, inline)]
Attached is a patch to fix this issue. I would like to acknowledge
RhodiumToad, who actually figured out what was causing this issue.

On Tue, Jul 28, 2020 at 3:23 PM Prafulla Giri <pratheblackdiamond <at> gmail.com>
wrote:

> Esteemed Maintainers,
>
> I am quite positive that what I am experiencing is not quite a bug but
> just some mis-step on my part. But I have been encouraged to report this as
> a possible bug. Thus, here it is.
>
> Context:
> Guile version: 3.0.2 (installed using guix)
> Loaded Files: simply.scm (
> https://github.com/hosoe-masaki/SimplyScheme/blob/master/simply.scm)
> Reverse function (referred to in the report, assumes 'simply.scm' has been
> loaded):
> (define (reverse wd) (if (equal? wd "") "" (word (reverse (bf wd)) (first
> wd))))
> ;; (reverse 'asdf) -> 'fdsa
>
> This started with my first wanting to run a (trace) of a recursive
> procedure as seen in Chapter 13 of the book 'Simply Scheme' (
> https://people.eecs.berkeley.edu/~bh/ssch13/convince-recur.html). I
> looked for a waay to (trace) in guile, but couldn't find anything except
> ,trace, which was giving a trace of everything that the function (reverse)
> called from inside of it, thus making the trace 'polluted'.
>
> I then looked around and found that a (trace) function, much like the one
> being demonstrated in the book used to exist once in guile:
> https://www.gnu.org/software/guile/docs/docs-1.8/guile-ref/Tracing.html
> and then found that for guile3 there was something that looked similarly
> promising: the (trace-calls-to-procedure) function (
> https://www.gnu.org/software/guile/docs/master/guile.html/Tracing-Traps.html).
> However,
> > (trace-calls-to-procedure reverse)
> > (reverse 'asdf)
> fdsa
> produced no trace. This led me to ask around IRC for some guidance
> regarding it. Someone from #emacs suggested I try doing this:
> http://ix.io/2suZ
> When I attempted to do the same thing, however, I encountered the
> following error, at the sight of which, it was recommended that I file a
> (possible) bug report: https://termbin.com/6nm5
>
> The following `script` typescript might also be of interest to the
> maintainers (to be replayed using `scriptreplay`):
> typescript - https://termbin.com/sx5o
> timing file - https://termbin.com/73ei
> (This one records the (call-with-trace) call with both #:call? #f and
> without the specification).
>
> I must confess, I don't understand a whole lot of this. All I would like
> to say is that I have a feeling (trace-calls-to-procedure procedure)
> should have worked like (trace) as shown in chapter 13 section 'trace' in
> the book (https://people.eecs.berkeley.edu/~bh/ssch13/convince-recur.html);
> it just seems 'right' by the name of it. I was expecting the trace from (trace-call-to-procedure
> reverse) (reverse 'asdf) to be basically like ,trace (reverse 'asdf) but
> without the traces of all other procedures.
>
> Please do let me know if I have left out any important details. And please
> do let me know if I am doing something wrong here. I am almost quite
> certain this is just a minor error on my part, rather than a bug (and I'd
> really like to be able to trace those procedures).
>
[Message part 2 (text/html, inline)]
[0001-Fix-return-handler-of-trace-calls-to-procedure.patch (text/x-patch, attachment)]

Reply sent to lloda <lloda <at> sarc.name>:
You have taken responsibility. (Fri, 21 May 2021 18:39:01 GMT) Full text and rfc822 format available.

Notification sent to Prafulla Giri <pratheblackdiamond <at> gmail.com>:
bug acknowledged by developer. (Fri, 21 May 2021 18:39:01 GMT) Full text and rfc822 format available.

Message #16 received at 42574-done <at> debbugs.gnu.org (full text, mbox):

From: lloda <lloda <at> sarc.name>
To: 42574-done <at> debbugs.gnu.org
Cc: pratheblackdiamond <at> gmail.com
Subject: Re: bug#42574: Probable (system vm trace) bug
Date: Fri, 21 May 2021 20:38:33 +0200
This has been fixed in f9f55b9ce74898d1b0a77dcc9b4aa260e5cd208d. Apologies for not noticing the earlier patch... there were a couple later duplicates.

Thanks!



bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sat, 19 Jun 2021 11:24:07 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 310 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.