Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: Markus Mottl <mottl@miss.wu-wien.ac.at>
To: ortmann@us.ibm.com
Cc: Pierre Weis <Pierre.Weis@inria.fr>,
	Georges Mariano <georges.mariano@inrets.fr>,
	caml-list@inria.fr
Subject: Re: tiny toplevel
Date: Wed, 9 Aug 2000 13:29:41 +0200	[thread overview]
Message-ID: <20000809132941.A16537@miss.wu-wien.ac.at> (raw)
In-Reply-To: <85256935.0059D0CD.00@D51MTA04.pok.ibm.com>; from ortmann@us.ibm.com on Tue, Aug 08, 2000 at 11:21:09 -0500

On Tue, 08 Aug 2000, ortmann@us.ibm.com wrote:
> > USER  PID %CPU %MEM   VSZ  RSS TTY   STAT START TIME COMMAND
> > weis 7546  0.1  1.2  2840 1652 pts/5 T    14:16 0:00 ocamlrun /usr/bin
> > weis 7656  1.6  0.5  1484  660 pts/5 T    14:17 0:00 camlrun /usr/loca

> Any idea how big Java is?

Interesting question - I tried it out on a Sun Ultra 5:

    PID USERNAME THR PRI NICE  SIZE   RES STATE   TIME    CPU COMMAND
  11183 markusm    1   5    0 3000K 2448K run     0:10 33.63% ocaml
  11184 markusm    1  15    0 4232K 2656K run     0:04 18.04% java
  11402 markusm    1   5    0 1960K 1272K run     0:01  5.27% ocamlrun

The OCaml-program:

  while true do () done

The Java-program (an example of conciseness ;)

  class test {
    public static void main (String args[]) {
      while (true);
    }
  }

One could argue now that the initial heap settings for Java are larger (I
don't know), but even explicitely setting them to the lowest level does not
allow it to "beat" OCaml:

java -ms1000 test:

  11270 markusm    1   5    0 3336K 2480K run     0:05 23.44% java

No match for OCaml (even the toplevel interpreter is smaller), not even to
mention caml-light, which is at least 2-3 times smaller...

I don't know how Java scales up with more interesting programs, but I don't
expect any surprises here... - so if somebody wants to go "embedded", don't
do it with Java... ;)

Best regards,
Markus Mottl

-- 
Markus Mottl, mottl@miss.wu-wien.ac.at, http://miss.wu-wien.ac.at/~mottl



  reply	other threads:[~2000-08-09 13:55 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-08-08 16:21 ortmann
2000-08-09 11:29 ` Markus Mottl [this message]
2000-08-09 12:29   ` Georges Mariano
2000-08-09 13:03     ` Markus Mottl
2000-08-09 17:45     ` Xavier Leroy
  -- strict thread matches above, loose matches on Subject: below --
2000-08-08 13:52 Georges Mariano
2000-08-08 13:41 ` Pierre Weis

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=20000809132941.A16537@miss.wu-wien.ac.at \
    --to=mottl@miss.wu-wien.ac.at \
    --cc=Pierre.Weis@inria.fr \
    --cc=caml-list@inria.fr \
    --cc=georges.mariano@inrets.fr \
    --cc=ortmann@us.ibm.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