From: Kevin Ryde <user42@zip.com.au>
To: guile-devel@gnu.org
Subject: Re: Optimizing record accessors
Date: Tue, 21 Aug 2007 10:10:16 +1000 [thread overview]
Message-ID: <874pitvjbr.fsf@zip.com.au> (raw)
In-Reply-To: <874pjb8k5l.fsf@chbouib.org> ("Ludovic Courtès"'s message of "Tue, 07 Aug 2007 17:00:06 +0200")
ludo@gnu.org (Ludovic Courtès) writes:
>
> Changing `record-accessor' as in the attached file yields
Gets rid of one scheme function call in the normal case does it?
I expect an apply-able smob thingie would be fastest (and smaller too)
for accessors and modifiers, if anyone felt like going down that track.
Probably quite worthwhile on the general principle of getting low-level
bits running fast.
> Type-safety is still guaranteed (e.g., `struct-vtable' will fail if OBJ
> is not a struct), though not as precisely (e.g., instead of a
> `not-a-record' error, we get a `wrong-type-arg' error in
> `struct-vtable').
As long as it's still `wrong-type-arg' it ought to be ok. If the whole
lot goes into C at some stage then the errors will be easier to control.
_______________________________________________
Guile-devel mailing list
Guile-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-devel
next prev parent reply other threads:[~2007-08-21 0:10 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-07 15:00 Optimizing record accessors Ludovic Courtès
2007-08-08 15:08 ` Ludovic Courtès
2007-08-21 0:10 ` Kevin Ryde [this message]
2007-08-21 7:58 ` Ludovic Courtès
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=874pitvjbr.fsf@zip.com.au \
--to=user42@zip.com.au \
--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).