Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
cywgin stack overflow
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2007-06-13 (12:39)
From: skaller <skaller@u...>
Subject: Re: [Caml-list] cywgin stack overflow
On Wed, 2007-06-13 at 17:34 +1000, skaller wrote:
> Hi, we've got a problem with an Ocaml native code program running under
> Cygwin exiting without producing output or diagnostics. I think
> Cygwin is running Ocaml 3.08. It was suggested
> this was probably a stack overflow. The program is Dypgen GLR
> parser generator, which is probably heavily recursive. It works
> fine on my AMD64/Ubuntu Linux box, Ocaml 3.10-dev+25 or something.
> Does anyone know how to increase the stack size, or have any other
> idea how to work around this problem? Or any idea if it could
> be any other problem?

Woops! I misdiagnosed the problem I think. I put -ccopts and
dypgen runs fine .. however Ocamlopt.opt does not compile it
the generated file ;(

The file src/ is generated by Dypgen, but ocamlopt.opt
doesn't compile it, nor issue any diagnostic (not even returning
with an error code). It just completes without generating a
src/flx_parse.cmx file.

Unfortunately, recompiling Ocaml on Cygwin isn't an option.
Is there someone here maintaining the Cygwin port? 
Any chance of 3.09 series Ocaml, and, with the native
code compiler built with a larger stack?

I've yet to try running with larger memory for Cygwin as
suggested by Igor -- the ml file is quite large:

 20555  92221 804093 src/

src/flx_parse.cmx on amd64/Ubuntu is 83569 bytes.

I also suppose I can try ocamlopt (sans .opt) or even
ocamlc (ouch!).

John Skaller <skaller at users dot sf dot net>
Felix, successor to C++: