float b = 0f;
if (b < ulong.MaxValue)
"hit" is never hit when mono is compiled as 64 bit on mac
I can't reproduce this. Can you attach a complete testcase plus the generated .exe ?
This is actually AOT issue
public static void Main ()
ulong ul = ulong.MaxValue;
System.Console.WriteLine ((float) ul);
When compiled and run with mono JIT I get
when using --aot I get
[mono] ~/git/mono/mcs/mcs$ mono --aot test-mcs.exe
Mono Ahead of Time compiler - compiling assembly /Users/marek/git/mono/mcs/mcs/test-mcs.exe
Code: 163 Info: 5 Ex Info: 8 Unwind Info: 17 Class Info: 34 PLT: 3 GOT Info: 17 GOT: 28 Offsets: 48
Compiled: 2/2 (100%), No GOT slots: 1 (50%), Direct calls: 0 (100%)
Executing the native assembler: as -arch i386 -W -o /var/folders/zw/_2mb6txx19b1c3g9ls4mwngr0000gn/T/mono_aot_1M2W4C.o /var/folders/zw/_2mb6txx19b1c3g9ls4mwngr0000gn/T/mono_aot_1M2W4C
Executing the native linker: gcc -m32 -dynamiclib -o /Users/marek/git/mono/mcs/mcs/test-mcs.exe.dylib.tmp /var/folders/zw/_2mb6txx19b1c3g9ls4mwngr0000gn/T/mono_aot_1M2W4C.o
Generating debug symbols: dsymutil /Users/marek/git/mono/mcs/mcs/test-mcs.exe.dylib
JIT time: 0 ms, Generation time: 0 ms, Assembly+Link time: 32 ms.
[mono] ~/git/mono/mcs/mcs$ mono test-mcs.exe
Fixed in master.
Notice (2018-05-21): bugzilla.xamarin.com will be
switching to read-only mode on Thursday, 2018-05-25 22:00 UTC.
Please join us on
Visual Studio Developer Community and
GitHub to continue tracking
issues. Bugzilla will remain available for reference in read-only mode.
We will continue to work on open Bugzilla bugs and copy them to the new
locations as needed for follow-up. The See Also field
on each Bugzilla bug will be updated with a link to its new location
After Bugzilla is read-only, if you have new information to add for a
bug that does not yet have a matching issue on Developer Community or
GitHub, you can create a follow-up issue in the new location. Copy and
paste the title and description from this bug, and then add your new
details. You can get a pre-formatted version of the title and
In special cases you might also want the comments:
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.