Bug 34078 - LLVM / native stack trace failure on trivial F# exe comparing structures (general & fundamental problem in codegen)
Summary: LLVM / native stack trace failure on trivial F# exe comparing structures (gen...
Status: NEW
Alias: None
Product: Runtime
Classification: Mono
Component: JIT (show other bugs)
Version: 4.0.0
Hardware: PC Linux
: --- normal
Target Milestone: ---
Assignee: Bugzilla
Depends on:
Reported: 2015-09-18 19:27 UTC by Jonathan Shore
Modified: 2015-09-19 08:53 UTC (History)
2 users (show)

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

simple project demonstrating problem (8.07 KB, application/x-bzip2)
2015-09-18 19:27 UTC, Jonathan Shore

Description Jonathan Shore 2015-09-18 19:27:59 UTC
Created attachment 12972 [details]
simple project demonstrating problem

Have a number of F# / C# programs that run fine on OS X but then fail on recent Linux mono VMs (4.0.x).   Had updated source, rebuilt, but seems consistent in the 4.0.x codebase and may be present in 4.2.x.

Any sort of comparison of a struct causes a failure (here am comparing 2 instances of a struct class called Tenor)

Unknown immediate size
UNREACHABLE executed at MCTargetDesc/X86BaseInfo.h:562!

  at <unknown> <0xffffffff>
  at TestCLRIssue.Tenor.Equals (object,System.Collections.IEqualityComparer) <0x00019>
  at TestCLRIssue.Main.main (string[]) <0x0028f>
  at (wrapper runtime-invoke) <Module>.runtime_invoke_int_object (object,intptr,intptr,intptr) <0xffffffff>

This simple exe runs fine without LLVM (no --llvm).  Note that it does not matter whether the struct is defined in F# or in a C# codebase.  Doing a comparison between two structs will cause the CLR to fall over.

Note that this is a Linux / LLVM issue and not an issue on OS X.

Including the project as a tar attachment.

Note You need to log in before you can comment on or make changes to this bug.