English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
ocamlc vs ocamlc.opt?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2007-02-14 (10:16)
From: Robert Roessler <roessler@r...>
Subject: Re: [Caml-list] ocamlc vs ocamlc.opt?
Robert Roessler wrote:
> ...
> Given "Compatibility with the bytecode compiler is extremely high: the 
> same source code should run identically when compiled with ocamlc and 
> ocamlopt." in Chapter 11 of the OCaml manual, I am really not expecting 
> ocamlc and ocamlc.opt to function any differently.  Choosing either of 
> the commands from a cleanly built OCaml installation should be a matter 
> of taste or personal preference, NOT correctness.

I performed further tests and gathered more data on this.  I verified 
that the cmo and cmi files produced by the two versions of ocamlc are 
identical - they are (well, at least their md5 hashes are).  So this 
would suggest that it is not the COMPILE portions of the two ocamlc 
versions that are causing this - which leaves how the BYTECODE-mode 
executable is produced.

Covering even more bases, I pulled the CVS version of the OCaml source 
tree and built it on the target FC6/gcc 4.1.1 box... NO change.

Again, what IS the difference in operation between the two versions of 
ocamlc, one built as a BYTECODE executable, the other built NATIVE?

Robert Roessler