9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: Bakul Shah <bakul+plan9@bitblocks.com>
To: 9fans@9fans.net
Subject: [9fans] lisp
Date: Mon,  7 Jul 2008 11:15:50 -0700	[thread overview]
Message-ID: <20080707181551.0531A5B4D@mail.bitblocks.com> (raw)

[Questions in the third para below.]
CMUCL "initializes" its state essentialy by loading a
previously dumped core image file.  This is slow the first
time around but once the ~25MB core image is cached,
execution is really fast and you have access to a lot of
goodies.  So a script like

#!/usr/local/bin/cmucl -script
(format t "Hello, World!~%")

can execute in a few milliseconds.  On systems with mmap(2)
or equivalent, the core image is simply copy-on-write mmaped.
This is a win since only the required pages will be loaded
(and not all of 25MB) and COW allows local changes.

>From what I understand, to do something equivalent on plan9
would require creating a segment and copying the core file to
it.  Is this correct?  Presumably the reads are cached?  Even
so, there will the cost of copying to the segment.  Or can
one create multiple text and data segments in some way so
that stuff will be paged in as necessary?  Also, if a shared
segment is created won't the forked processes be able to
modify this segment?  Ideally one would like a private copy
for each child.  Is segattach + read the best (only?) way to
do this?

sbcl too uses a core file like cmucl.  They both compile code
so are generally faster than clisp, which is the third
alternative.  Note: my interest is purely hypothetical at the
moment.

Thanks!



             reply	other threads:[~2008-07-07 18:15 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-07 18:15 Bakul Shah [this message]
2008-07-07 18:45 ` erik quanstrom
2008-07-07 19:20   ` David Leimbach
2008-07-07 19:44   ` Bakul Shah
2008-07-07 19:55     ` Charles Forsyth
2008-07-07 20:15       ` Bakul Shah
2008-07-07 20:21         ` David Leimbach
2008-07-07 20:47           ` Bakul Shah
2008-07-07 20:51             ` David Leimbach
2008-07-08 14:08         ` Dave Eckhardt
2008-07-08 15:07           ` David Leimbach
2008-07-08 19:05             ` Bakul Shah
2008-07-08 21:12               ` C H Forsyth
2008-07-08 21:42                 ` Bakul Shah
2008-07-07 20:43   ` geoff

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20080707181551.0531A5B4D@mail.bitblocks.com \
    --to=bakul+plan9@bitblocks.com \
    --cc=9fans@9fans.net \
    /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 NNTP newsgroup(s).