Bug 32020 - Don't default to --with-tls=pthread on Solaris/x86
Summary: Don't default to --with-tls=pthread on Solaris/x86
Alias: None
Product: Runtime
Classification: Mono
Component: General ()
Version: 4.0.0
Hardware: PC Other
: --- normal
Target Milestone: ---
Assignee: Bugzilla
Depends on:
Reported: 2015-07-16 08:22 UTC by Rainer Orth
Modified: 2016-04-11 16:16 UTC (History)
3 users (show)

Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and 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 Links.

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.

Related Links:

Description Rainer Orth 2015-07-16 08:22:07 UTC
After an initial build of mono on 64-bit Solaris 11/x86 with --disable-sgen (since that's what I'd needed
with mono 3.2.6 to get a working mono at all), I tried again without to check what happens.  The build aborted here:

usage: mcs [-cdHpVz] [-A file ] [-a string] [-n name] file...
make[6]: *** [build/deps/basic-profile-check.exe] Error 1
*** The compiler 'mcs' doesn't appear to be usable.
*** Trying the 'monolite' directory.
sgen is not supported when using --with-tls=pthread.

When I commented the corresponding clause in configure.ac:

@@ -295,7 +295,7 @@ case "$host" in
 		# This doesn't seem to work on solaris/x86, but the configure test runs
-		with_tls=pthread
+		#with_tls=pthread

and rebuilt, the build went fine.  Contrary to the the make check results with --with-tls=pthread, where 4
different tests hang hard and had to be killed manually, make check with --with-tls=__thread passed without
those hangs.  I've no idea what this comment above refers to, but I'm not aware of any TLS problems on Solaris 10+,
so this seems ill-conceived.  There were all sorts of problems in Solaris 8 and 9, but both are no longer relevant.

Comment 1 Alex Rønne Petersen 2016-04-11 07:54:59 UTC

None of us on the team really test Mono on Solaris regularly, so I'll take your word for it that it works. It's also worth noting that the fallback to pthread TLS was added nearly a decade ago, so it's certainly unlikely that it's needed anymore.

PR: https://github.com/mono/mono/pull/2866
Comment 2 Alex Rønne Petersen 2016-04-11 16:16:13 UTC
PR merged, marking as fixed.