[Mono-osx] "Illegal instruction" for stack overflow

Geoff Norton gnorton at novell.com
Fri Apr 4 22:49:50 EDT 2008


   We don't currently support StackOverflowExceptions on OSX (linux  
only, MAYBE(?) windows?)

Please file a bug so we can track this and we can look at implementing  


On 4-Apr-08, at 9:52 PM, Chuck Esterbrook wrote:

> On Mono 1.9_5 on Mac OS X 10.4, a stack overflow due to unlimited
> recursion causes an "Illegal instruction". What I really want is the
> last set of stack frames. Python does this and it's great for quickly
> diagnosing the recursion cycle.
> In January, I mentioned this to Miguel de Icaza who I sat next to at
> Lang.NET. He showed me that with the then-current Mono built from
> svn/source, this worked. Unless I was dreaming...?  :-)
> I'm wondering what happened to that, or if there is an environment
> variable or something I have to set.
> Here is some offensive code:
> class X {
>        public static void Main() {
>                Main();
>        }
> }
> Of course, the example is silly, but the real life occurrences involve
> thousands of lines of code cranking on complex object graphs.
> I tried cms and gmcs, and I tried -debug+ with the compilers and
> --debug with mono. No luck with getting a partial stack trace.
> $ gmcs -debug+ stack-overflow.cs
> $ mono --debug stack-overflow.exe
> Illegal instruction
> -Chuck
> _______________________________________________
> Mono-osx mailing list
> Mono-osx at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-osx

More information about the Mono-osx mailing list