caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Jonathan Roewen <jonathan.roewen@gmail.com>
To: caml-list@yquem.inria.fr
Subject: Re: [Caml-list] The Bytecode Interpreter...
Date: Sat, 22 Oct 2005 13:39:12 +1300	[thread overview]
Message-ID: <ad8cfe7e0510211739k748e68e0y5d6dd62565b0a0a6@mail.gmail.com> (raw)
In-Reply-To: <ad8cfe7e0510210301n69e7a384s23e45f2870de9395@mail.gmail.com>

Hi Again,

I have a few more questions about the toplevel/bytecode interpreter.

I've noted in startup.c that caml_main tries to open itself, and do
some sort of work on the file. The problem is that I want to be able
to run the ocaml toplevel on the bare metal (and later extend it into
an operating system of sorts). I've seen there is a caml_startup_code
function in startup.c that appears to setup the caml environment
without reading itself: however, how do I find all the values to pass
to it?

Alternatively, another idea, which I'd like some feedback on for suitability is:
- load the 'kernel' as a module as well as the kernel itself (so I
suppose mapped into memory twice).
- provide some dummy C functions that a) let us open the 'kernel', and
b) provide read-only access to the file.
- let caml_main use this in-memory representation of the 'kernel' to
start itself up.

I'm wondering what kind of other obstacles would also affect my desire
to achieve this as well.

One last thing =) How does the toplevel get initialised, etc., and
started running? Does it depend on ocamlrun being in the path, and
being able to load it into memory or something?

Jonathan


  parent reply	other threads:[~2005-10-22  0:39 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-10-21 10:01 Jonathan Roewen
2005-10-21 11:27 ` David MENTRE
2005-10-21 22:24   ` Jonathan Roewen
2005-10-21 23:49     ` Oliver Bandel
2005-10-22 21:33       ` Jonathan Roewen
2005-10-22  0:32     ` Jon Harrop
2005-10-22  0:39     ` Jacques Garrigue
2005-10-23  1:03   ` Jonathan Roewen
2005-10-23 10:21     ` Gerd Stolpmann
2005-10-24  5:38       ` Jonathan Roewen
2005-10-24  6:13         ` Jacques Garrigue
2005-10-24  6:48           ` Jonathan Roewen
2005-10-22  0:39 ` Jonathan Roewen [this message]
2005-10-26  0:33   ` Jonathan Roewen
2005-10-26  9:56 ` Jonathan Roewen
2005-10-26 10:20   ` Jonathan Roewen
2005-10-27 14:12   ` Damien Doligez
2005-10-28 21:41     ` Jonathan Roewen
2005-10-29 11:29       ` Gerd Stolpmann
2005-10-29 15:22         ` skaller
2005-10-30  0:41           ` Jonathan Roewen
2005-11-10 10:26         ` Damien Doligez

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=ad8cfe7e0510211739k748e68e0y5d6dd62565b0a0a6@mail.gmail.com \
    --to=jonathan.roewen@gmail.com \
    --cc=caml-list@yquem.inria.fr \
    /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).