Browse thread
Missing overflow exception message in ocamlopt
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Robert Roessler <roessler@r...> |
| Subject: | Re: [Caml-list] Missing overflow exception message in ocamlopt |
Jakob Lichtenberg wrote: > Is this a bug in ocamlopt? No - rather, it is the ugly intrusion of reality. ;) As has been already pointed out, it isn't easy to generate code that detects this at runtime under a widely varying set of environments and conditions... to tighten it up further would likely start costing in performance (and what is ocamlopt for?). A related veiwpoint says that while you still don't understand your app's logic and control paths well enough to predict/avoid things like runaway stack usage - you use the interpreted version. THEN you switch to the ocamlopt version when you think you are ready (and be prepared to switch back if you are proven wrong). > On Wednesday 11 October 2006 19:46, Jakob Lichtenberg wrote: >> When I compile the following program as byte code I see a stack > overflow >> (expected). When using ocamlopt it seems that the program dies and I > do >> not see the expected overflow exception? > > OCaml doesn't always throw the Stack_overflow exception from native > code. On > some systems it seg faults. Robert Roessler roessler@rftp.com http://www.rftp.com