Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

F# crashes on Mono 2.10

Tags:

After reading some reports about the inadequacies of the Mono 2.6 garbage collector, I decided to give Mono 2.10 a go. I found that the 2.10 runtime crashes with the following simple F# program:

let rec f x acc =
  if x = 0 then acc
  else f (x - 1) (acc + 1)

f 10 0

Equivalent looping C# code runs just fine as does an F# hello world program. The F# code also works ok with Mono 2.6 and .Net. Can anyone else reproduce this? Is it a bug or is it just my installation?

Here are the various runtimes I've tried and results I got.

  • Mono 2.10.2 (compiled from sources on Debian Squeeze)

    -- "Stack overflow: IP: 0x4153bb84, fault addr: (nil)"
    
  • Mono 2.8 (compiled from sources on Debian Squeeze)

    -- "Native stacktrace: ..."
    
  • Mono 2.10.2 (Windows binary)

    -- "mono.exe has stopped working" dialog.
    
  • Mono 2.10.2 (VMware image)

    -- Segmentation fault
    
  • Mono 2.6.7 (bundled with Debian Squeeze)

    -- Works fine
    

The F# compiler used was from the November 2010 CTP.

like image 260
petebu Avatar asked May 15 '11 18:05

petebu


1 Answers

I've reported this problem as bug #693905 at https://bugzilla.novell.com/show_bug.cgi?id=693905.

like image 149
petebu Avatar answered Sep 19 '22 07:09

petebu