GNU bug report logs -
#68895
Difference between trace behavior in guix repl and guile
Previous Next
To reply to this bug, email your comments to 68895 AT debbugs.gnu.org.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-guix <at> gnu.org
:
bug#68895
; Package
guix
.
(Fri, 02 Feb 2024 16:28:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Adriel Dumas--Jondeau <leirda <at> disroot.org>
:
New bug report received and forwarded. Copy sent to
bug-guix <at> gnu.org
.
(Fri, 02 Feb 2024 16:28:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Here's what's happening in a guix repl:
```
(guix-user)> ,use (guix scripts build)
(guix-user)> ,trace (guix-build "hello") ; doesn't output any trace for some reason
```
And here'the same for a guile repl:
```
(guile-user)> ,use (guix scripts build)
(guile-user)> ,trace (guix-build "hello") ; however it does work
trace: | (guix-build "hello")
trace: | | (_ (guix scripts) #:ensure #f)
trace: | | (_ #<procedure 7ff4802c5000 at ice-9/boot-9.scm:3241:7 ()>)
trace: | | | (lock-mutex #<mutex 7ff487d01fc0>)
...
```
This was observed during a working group on profiling during the Guix Days.
--
Adriel
[signature.asc (application/pgp-signature, inline)]
Information forwarded
to
bug-guix <at> gnu.org
:
bug#68895
; Package
guix
.
(Sat, 04 Jan 2025 18:26:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 68895 <at> debbugs.gnu.org (full text, mbox):
Adriel Dumas--Jondeau <leirda <at> disroot.org> writes:
> (guix-user)> ,use (guix scripts build)
> (guix-user)> ,trace (guix-build "hello") ; doesn't output any trace for some reason
It looks like this isn't the only REPL command that doesn't work in
`guix repl`. I haven't done anything close to a full investigation (I am
new to using Guile!), but many other commands simply don't work.
For example, breakpoints are not respected.
`guix repl`:
--8<---------------cut here---------------start------------->8---
scheme@(guix-user)> (define (my-f x) (+ x 1))
scheme@(guix-user)> ,break my-f
Trap 0: Breakpoint at #<procedure my-f (x)>.
scheme@(guix-user)> (my-f 2)
$1 = 3
--8<---------------cut here---------------end--------------->8---
`guile`:
--8<---------------cut here---------------start------------->8---
scheme@(guix-user)> (define (my-f x) (+ x 1))
scheme@(guix-user)> ,break my-f
Trap 0: Breakpoint at #<procedure my-f (x)>.
scheme@(guix-user)> (my-f 2)
$1 = 3
--8<---------------cut here---------------end--------------->8---
Neither are tracepoints.
`guix repl`:
--8<---------------cut here---------------start------------->8---
scheme@(guix-user)> (define (my-f x) (+ x 1))
scheme@(guix-user)> ,tracepoint my-f
Trap 0: Tracepoint at #<procedure my-f (x)>.
scheme@(guix-user)> (my-f 2)
$1 = 3
--8<---------------cut here---------------end--------------->8---
`guile`:
--8<---------------cut here---------------start------------->8---
scheme@(guile-user)> (define (my-f x) (+ x 1))
scheme@(guile-user)> ,tracepoint my-f
Trap 0: Tracepoint at #<procedure my-f (x)>.
scheme@(guile-user)> (my-f 2)
Trap 0: (my-f 2)
Trap 0: 3
$1 = 3
--8<---------------cut here---------------end--------------->8---
Information forwarded
to
bug-guix <at> gnu.org
:
bug#68895
; Package
guix
.
(Wed, 08 Jan 2025 15:22:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 68895 <at> debbugs.gnu.org (full text, mbox):
45mg <45mg.writes <at> gmail.com> writes:
> It looks like this isn't the only REPL command that doesn't work in
> `guix repl`. I haven't done anything close to a full investigation (I am
> new to using Guile!), but many other commands simply don't work.
Thank you for your investigation. I am cc-ing guix-devel in case they
have insight regarding these.
--
Suhail
Information forwarded
to
bug-guix <at> gnu.org
:
bug#68895
; Package
guix
.
(Wed, 08 Jan 2025 15:26:01 GMT)
Full text and
rfc822 format available.
Message #14 received at 68895 <at> debbugs.gnu.org (full text, mbox):
Suhail Singh <suhailsingh247 <at> gmail.com> writes:
>> It looks like this isn't the only REPL command that doesn't work in
>> `guix repl`. I haven't done anything close to a full investigation (I am
>> new to using Guile!), but many other commands simply don't work.
>
> Thank you for your investigation. I am cc-ing guix-devel in case they
> have insight regarding these.
Whoops, sent too quickly. Current (probably inexhaustive) list:
- trace
- tracepoint
- break
--
Suhail
Information forwarded
to
bug-guix <at> gnu.org
:
bug#68895
; Package
guix
.
(Tue, 21 Jan 2025 14:16:02 GMT)
Full text and
rfc822 format available.
Message #17 received at 68895 <at> debbugs.gnu.org (full text, mbox):
Hello,
Suhail Singh <suhailsingh247 <at> gmail.com> writes:
> Suhail Singh <suhailsingh247 <at> gmail.com> writes:
>
>>> It looks like this isn't the only REPL command that doesn't work in
>>> `guix repl`. I haven't done anything close to a full investigation (I am
>>> new to using Guile!), but many other commands simply don't work.
>>
>> Thank you for your investigation. I am cc-ing guix-devel in case they
>> have insight regarding these.
>
> Whoops, sent too quickly. Current (probably inexhaustive) list:
>
> - trace
> - tracepoint
> - break
Perhaps Guix configures Guile to use the no-debug VM even for the REPL?
Se the '--no-debug' documentation in info '(guile) Command-line
Options':
‘--debug’
Start with the debugging virtual machine (VM) engine. Using the
debugging VM will enable support for VM hooks, which are needed for
tracing, breakpoints, and accurate call counts when profiling. The
debugging VM is slower than the regular VM, though, by about ten
percent. *Note VM Hooks::, for more information.
By default, the debugging VM engine is only used when entering an
interactive session. When executing a script with ‘-s’ or ‘-c’,
the normal, faster VM is used by default.
Indeed, if you look at the shebang of scripts/guix.in, which is the
template for the 'guix' entry point script, it uses the '-s' argument.
I'm not sure if there's a way to enable the debug VM after Guile was
started in the equivalent of --no-debug.
--
Thanks,
Maxim
This bug report was last modified 152 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.