unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
From: Noah Lavine <noah.b.lavine@gmail.com>
To: Andy Wingo <wingo@pobox.com>
Cc: guile-devel <guile-devel@gnu.org>
Subject: Re: Patches for wip-rtl
Date: Mon, 22 Apr 2013 21:34:19 -0400	[thread overview]
Message-ID: <CA+U71=OitMC-eS13Ru=0GaSrjmeO-znNBT7egUsjk=FsCxyWoA@mail.gmail.com> (raw)
In-Reply-To: <8761zejopa.fsf@pobox.com>

[-- Attachment #1: Type: text/plain, Size: 1564 bytes --]

Hello,

On Mon, Apr 22, 2013 at 4:27 PM, Andy Wingo <wingo@pobox.com> wrote:

> Hi Noah,
>
> Do I understand you correctly that you're just making a sequence of
> non-idiomatic instructions because you know that doing the
> assert-nargs-ee will check nargs?  I would think in a normal case you'd
> want to do "assert-nargs-ge 0", then "bind-rest 0", then "reserve-locals
> 0" (or not; in this case it would not be necessary).
>

Yes, that's exactly why I'm doing it. I just wanted to find a way to test
that the bug was fixed and stayed fixed. In this case that's a bit weird,
because we probably don't want to guarantee that this pattern of
instructions will continue to work, but I don't have a great alternative. I
think any sort of test for this is going to be dependent on the internals
of the VM. (My earlier email about adding accessors for the VM was about
this same bug, but then I realized that nargs isn't part of the vm
structure so I couldn't solve it like that.)


> However the bug you have seen with bind-rest is probably also present
> with keyword arguments.  We should probably just change the
> reserve-locals instruction to also take "nargs" as a value, given that
> we know it statically at compile-time.
>
> Does that make sense to you?
>

I'm not sure. As long as nargs is going to be a local variable, I don't see
a reason not to use it. It might make more sense to either keep it the way
it is or change every instruction that uses nargs. But I haven't looked to
see how many there are, or how important it is that they know nargs.

Noah

[-- Attachment #2: Type: text/html, Size: 2259 bytes --]

  reply	other threads:[~2013-04-23  1:34 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-20 23:30 Patches for wip-rtl Noah Lavine
2013-04-21 15:23 ` Noah Lavine
2013-04-21 15:50   ` Noah Lavine
2013-04-22 20:27     ` Andy Wingo
2013-04-23  1:34       ` Noah Lavine [this message]
2013-04-22 20:39 ` Andy Wingo
2013-04-23  2:38   ` Noah Lavine
2013-04-23 10:13     ` Andy Wingo
2013-05-05  1:29       ` Noah Lavine

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='CA+U71=OitMC-eS13Ru=0GaSrjmeO-znNBT7egUsjk=FsCxyWoA@mail.gmail.com' \
    --to=noah.b.lavine@gmail.com \
    --cc=guile-devel@gnu.org \
    --cc=wingo@pobox.com \
    /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).