Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report on
GitHub or Developer Community with
your current version information, steps to reproduce, and relevant error
messages or log files if you are hitting an issue that looks similar to
this resolved bug and you do not yet see a matching new report.
Hello, I'm lambdalice, 16 years old Japanese student.
I'm from Nemerle Forum and we have a problem.
In conclusion, we hope that [these lines in the corlib]( https://github.com/mono/mono/blob/master/mcs/class/corlib/System.Threading/Thread.cs#L829-832 ) be removed.
We can't compile Nemerle on Mono, because of Mono's too tight stack limit.
Compiling Nemerle sources make many recursions, and always cause StackOverflow and fail to compile, so we can't be accepted the package by Debian.
We started to research the history of Mono's stack limit.
Please see the old [wthreads.c]( https://gitorious.org/mono/mono/source/4bb580d93174a4b683ddc1616009805bbdbb7944:mono/io-layer/wthreads.c#L377-381 ).
First, it was 2MB on x32 and 4MB on x64 and it was reduced to half.
The comment says:
> temporarily changed to use 1 MB: this allows more threads
> to be used, as well as using less virtual memory and so
> more is available for the GC heap.
And now, these lines are removed and moved to [mono-threads-posix.c]( https://github.com/mono/mono/blob/master/mono/utils/mono-threads-posix.c#L123-132 ).
Then we tried to remove https://github.com/mono/mono/blob/master/mcs/class/corlib/System.Threading/Thread.cs#L829-832 and build it.
By using the modified Mono make it possible to compile Nemerle successfully, even though we didn't change any lines in mono-threads-posix.c.
This is quite strange.
Of course, we tried to rewrite Nemerle Compiler, and we found it very diffifult.
Because there is many recursion and corecursion, and we have to rewrite them in a imperative style.
And we've found some projects that can be compiled on Windows and Mono on Windows, but can't do on Mono on Linux.
In this point Mono (on Linux) is no longer not .NET compatible, and we hope to eliminate the stack size limitation (or make it bigger).
Please see also a discussion in Nemerle Forum: https://groups.google.com/forum/#!topic/nemerle-en/xNrjBBqtoYE
Best Regards, lambdalice
Sorry for my misspelling;
- In this point Mono (on Linux) is no longer not .NET compatible
+ In this point Mono (on Linux) is no longer .NET compatible
Fixed in mono master 6d95657a21434fc46b5fa1b02d76781f5d53846c. This change will not make mono 3.2.7/3.2.8.
Reverted Zoltan's fix.
We should keep the old behavior when possible. Now we're using getrlimit to get the max thread stack size.