[Mono-dev] correct tail call optimization in mono

Rodrigo Kumpera kumpera at gmail.com
Sun Aug 23 16:07:06 EDT 2009


Mono doesn't support TCO as well as .NET.
It's planned to be fixed eventually. The problem is that the  mono team at
Novell
doesn't have available manpower to fix this anytime soon.

So, if you do care about F# on mono, please contribute the required fixes
for the
JIT to support more broad TCO.

Cheers,
Rodrigo

On Sun, Aug 2, 2009 at 6:17 PM, Peter Hercek <phercek at gmail.com> wrote:

> Hi,
>
> I read some contradictory information about tail call optimization in
> mono. So I did this test in FSharp:
>
> let test_1 fn n = if n < 0 then 1 else fn (n - 1)
> let rec test_2 n = if n < 0 then 1 else test_1 test_2 (n - 1)
> let main = test_1 test_2 10000000
>
> It works on MS .Net but crashes on mono (linux).
>
> Do you plan to support the correct tail call optimization?
> If yes, when it should be supported correctly?
>
> Thanks,
>  Peter.
>
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20090823/1e10a63c/attachment-0001.html 


More information about the Mono-devel-list mailing list