Version française
Home     About     Download     Resources     Contact us    
Browse thread
RE: [Caml-list] Turning off type-checking
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Gregory Morrisett <jgm@C...>
Subject: RE: [Caml-list] Turning off type-checking
> Could the type experts on this list confirm or deny that :
> 	- For ``classical'' types, type-checking amounts to 
> term unification.
> 	- Term unification can be done in worst-case linear-time.
> 	- Ocaml's unification algorithm is worst-case suboptimal.
> 	- This explains the ``awful amount of time'' needed for 
> type checking.

Well, type-checking ML involves more than term unification -- the 
worst case complexity is something truly horrible (EXP-time).
Having said this, for most programs, the worst-case complexity
rarely, if ever arises in "natural" code.  (I've not run into
it...)

So, I'd actually be surprised if there was any significant speedup
obtained by eliminating the type-inference from the compilation
path.  

-Greg
-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners