--- layout: releasenotes title: 'Mono 5.10.0 Release Notes' version: 5.10.0 releasedate: '2018-02-26' --- ## Release History - 5.10.0.160 - Stable Release *(07 Mar 2018)* - 5.10.0.140 - Stable Release *(26 Feb 2018)*

Preview Releases

## Highlights - [Interpreter compiled by default](#interpreter) - [Default Interface Method support](#default-interface-methods) - [Mono SDKs](#mono-sdks) - [.NET 4.7.1](#class-libraries) ## In Depth ### Runtime #### Interpreter The interpreter is now compiled in by default into Mono, and you can use it by running `mono --interpreter`. Check out the recent [interpreter blog post](/news/2017/11/13/mono-interpreter/) for more details about this work. We are getting closer to get the interpreter working with JIT/AOT and on mobile: - exception handling and debugger support has been unified with JIT/AOT - we support more AppDomain and Remoting cases It is not yet as feature complete as the JIT, so there will be some behavior differences or breakages; we are currently working on making our complete test suite pass. #### Default Interface Methods The runtime now supports [Default Interface Methods](https://github.com/dotnet/csharplang/blob/master/proposals/default-interface-methods.md), we now only miss the C# compiler support. #### Mono SDKs This is a new way of building Mono for some of the platforms that we support: Android, iOS and WebAssembly. The goal is to move most of the build logic into Mono so that we can more easily make changes and test those platforms as part of CI. You can find some documentation at the [README](https://github.com/mono/mono/blob/2017-12/sdks/README.md) and [Makefile build targets](https://github.com/mono/mono/blob/2017-12/sdks/builds). This is still a work-in-progress, we'll make it easier to use with upcoming releases, and more documentation will also be added. #### WebAssembly port This is the first release where the interpreter can reliably run most of the class libraries test suite. Multiple bugs affecting the Basic Class Libraries were fixed. The WebAssembly port is leveraging the work done around Mono SDKs to provide an improved developer experience to those working on mono. While there will be no official release at this point, the adventurous ones can try our code drops [directly from CI](https://jenkins.mono-project.com/job/test-mono-mainline-wasm/). #### Dedicated Coverage profiler The coverage profiler has been extracted from the log profiler, making it much more lightweight. It also removes the dependency on `mprof-report` to generate the XML report, and instead generates the report directly. You can find more documentation by looking at the `COVERAGE PROFILER` section of the `mono-profilers` man page. #### Support for Android Unified Headers Android NDK unified headers required changes to the way Mono detects real-time signal definitions (`SIGRTMIN`/`SIGRTMAX`), as well as a number of workarounds for 64-bit API declarations on target platforms (\< API 24) which do not have the correct declarations. A number of compatibility tweaks was also done to declarations of `fgetpos`, `fsetpos`, `mmap`, `sendfile` and `statvfs` calls. Mono builds targeting Android require that the `__ANDROID_API__` macro is set to the target platform level (e.g. 21, 24 or O) #### ARM Memory Barriers Explicitly encode memory barrier type on ARM64, instead of relying on undefined behaviour according to the ARMv8 ABI. This is to respect the ARM specification closer, reducing the risk of hardware-specific bugs. #### AOT Size Reduction via Code Deduplication We now support deduplicating generics code across assemblies. For example, code for `List` is now deduplicated for usage in the user code and `System.dll`. ### Class Libraries The recently announced .NET 4.7.1 is now supported and available as a specific target via MSBuild configuration. The `System.Data` assembly was fully replaced with CoreFX implementation resolving many limitations and corner cases issue we had as well as implementing missing features and APIs. Significant parts of `System.Security` assembly implementation were replaced with CoreFX implementation. ### Tools #### C# compiler The Roslyn compiler (csc) has been updated to version 2.6.0 which includes all C# 7.2 [features](https://docs.microsoft.com/en-us/dotnet/csharp/whats-new/csharp-7-2). The Mono C# compiler (mcs) gained support for the following C# 7.x features: - default literal - non-trailing named arguments - discards - tuples implicit deconstruction - generalized async return types - stackalloc to Span assignment conversion - ref struct - readonly structs #### F# compiler The F# compiler was updated to the latest 4.1 version. The FSharp.Core.dll assembly is no longer installed into the GAC, solving many problems users faced when using NuGets. #### MSBuild MSBuild was updated to the latest version available. Mono's list of incompatible NuGet assemblies was extended and updated which should help with NuGets which bundle the same assemblies as installed by Mono as those are now skipped. ## Bug Fixes - Bugzilla [#19503](https://bugzilla.xamarin.com/show_bug.cgi?id=19503) - Process.Start on OS X fails silently for missing file - Bugzilla [#20562](https://bugzilla.xamarin.com/show_bug.cgi?id=20562) - Seeming valid IL produces invalid result - Bugzilla [#40699](https://bugzilla.xamarin.com/show_bug.cgi?id=40699) - Console.ReadXXX does not echo input after TermInfoDriver is initialized - Bugzilla [#45893](https://bugzilla.xamarin.com/show_bug.cgi?id=45893) - I18N: EncoderFallbackBuffer.Fallback gets next character instead of the current one - Bugzilla [#50189](https://bugzilla.xamarin.com/show_bug.cgi?id=50189) - SGEN XMM scanning: Linux/Intel (32 + 64) - Bugzilla [#50190](https://bugzilla.xamarin.com/show_bug.cgi?id=50190) - SGEN FPU scanning: Darwin/ARM64 - Bugzilla [#52675](https://bugzilla.xamarin.com/show_bug.cgi?id=52675) - HttpListener doesn't work with SSL - Bugzilla [#53296](https://bugzilla.xamarin.com/show_bug.cgi?id=53296) - Latin1Encoding throws exception on Mono when it doesn't on MS.NET - Bugzilla [#56003](https://bugzilla.xamarin.com/show_bug.cgi?id=56003) - URI returns wrong absolute path on OSX when File name is UTF-8 - Bugzilla [#56194](https://bugzilla.xamarin.com/show_bug.cgi?id=56194) - SIGSEGV on System.Runtime.CompilerServices.RuntimeHelpers.InitializeArray() - Bugzilla [#56727](https://bugzilla.xamarin.com/show_bug.cgi?id=56727) - Runtime crashes when disposing DeflateStream - Bugzilla [#57892](https://bugzilla.xamarin.com/show_bug.cgi?id=57892) - Static lib in the msi distrib doesn't resolve all symbols - Bugzilla [#57893](https://bugzilla.xamarin.com/show_bug.cgi?id=57893) - mkbundle is not working on Windows - Bugzilla [#57938](https://bugzilla.xamarin.com/show_bug.cgi?id=57938) - Differences in behavior Type.Fullname in Mono and .NET Framework when Type is a generic type that is not a generic type definition but contains unresolved type parameters - Bugzilla [#58400](https://bugzilla.xamarin.com/show_bug.cgi?id=58400) - System.Uri broken with files - Bugzilla [#58411](https://bugzilla.xamarin.com/show_bug.cgi?id=58411) - System.Security.Cryptography.CryptographicException: Store root doesn't exist - Bugzilla [#59080](https://bugzilla.xamarin.com/show_bug.cgi?id=59080) - Type information of underlying type for enums compiled by Mono.CSharp.dll seems to be incorrect - Bugzilla [#59182](https://bugzilla.xamarin.com/show_bug.cgi?id=59182) - Crash/SIGSEGV with interop callback with struct parameter from native to managed on Xamarin.Android on armv7 - Bugzilla [#59184](https://bugzilla.xamarin.com/show_bug.cgi?id=59184) - MethodInfo.Invoke fails for generic methods with too many/too large arguments - Bugzilla [#59393](https://bugzilla.xamarin.com/show_bug.cgi?id=59393) - NullReferenceException when MonthCalendar clicked out of min/max date - Bugzilla [#59608](https://bugzilla.xamarin.com/show_bug.cgi?id=59608) - Attribute MethodImplOptions.AggressiveInlining causes method to always return NULL - Bugzilla [#59664](https://bugzilla.xamarin.com/show_bug.cgi?id=59664) - Type.GetType("", true) throws ArgumentException on Mono but TypeLoadException on .NET - Bugzilla [#59832](https://bugzilla.xamarin.com/show_bug.cgi?id=59832) - \[iOS\]MT3001 error: Could not AOT the assembly error while building iOS/mobile samples - Bugzilla [#59881](https://bugzilla.xamarin.com/show_bug.cgi?id=59881) - DllImport calls a wrong function if its function number greater than 65535 - Bugzilla [#59909](https://bugzilla.xamarin.com/show_bug.cgi?id=59909) - WebInvokeAttributeTest.RejectTwoParametersWhenNotWrapped() fails on Android - Bugzilla [#59916](https://bugzilla.xamarin.com/show_bug.cgi?id=59916) - get_current_locale_name fails under the load with String conversion error: Illegal byte sequence encounted in the input - Bugzilla [#59956](https://bugzilla.xamarin.com/show_bug.cgi?id=59956) - \[llvm\]\[bitcode\] \[FAIL\] UniqueIdTest.Ctor_Id (System.Runtime.Serialization tests) - Bugzilla [#60028](https://bugzilla.xamarin.com/show_bug.cgi?id=60028) - Timer doesn't throw ODE after Dispose() - Bugzilla [#60029](https://bugzilla.xamarin.com/show_bug.cgi?id=60029) - AsyncLocal inconsistency with .NET - Bugzilla [#60175](https://bugzilla.xamarin.com/show_bug.cgi?id=60175) - AOT mis-compiles when coverage is used - Bugzilla [#60224](https://bugzilla.xamarin.com/show_bug.cgi?id=60224) - Coverage profiler uses type names which don't exist - Bugzilla [#60233](https://bugzilla.xamarin.com/show_bug.cgi?id=60233) - Assertion in dynamic-image.c after 792b5367cd3a6ffa1a192c4d2d7ace3509cbb646 - Bugzilla [#60238](https://bugzilla.xamarin.com/show_bug.cgi?id=60238) - Mono assertion hit when using csharp repl - Bugzilla [#60255](https://bugzilla.xamarin.com/show_bug.cgi?id=60255) - Wrong exception in emulated opcodes - Bugzilla [#60267](https://bugzilla.xamarin.com/show_bug.cgi?id=60267) - Inconsistent symlink traversal results - Bugzilla [#60288](https://bugzilla.xamarin.com/show_bug.cgi?id=60288) - Large Array Initializer Causes TypeLoadException - Bugzilla [#60298](https://bugzilla.xamarin.com/show_bug.cgi?id=60298) - LayoutKind.Explicit, Size = 12 ignored with 64bit alignment - Bugzilla [#60317](https://bugzilla.xamarin.com/show_bug.cgi?id=60317) - Stuck WebRequest - Bugzilla [#60422](https://bugzilla.xamarin.com/show_bug.cgi?id=60422) - Native crash due to unhandled errno values when accessing files on networked filesystems - Bugzilla [#60435](https://bugzilla.xamarin.com/show_bug.cgi?id=60435) - The DataGridViewRow.CreateCellsInstance method is never invoked - Bugzilla [#60539](https://bugzilla.xamarin.com/show_bug.cgi?id=60539) - mini-codegen.c:1265, condition \`reginfo \[sreg\].born_in > 0' not met - Bugzilla [#60545](https://bugzilla.xamarin.com/show_bug.cgi?id=60545) - Multiple argument generic with contravariant interface as an argument causes MissingMethodException - Bugzilla [#60621](https://bugzilla.xamarin.com/show_bug.cgi?id=60621) - XmlDocument.Load() throws WebException when DTD url is not reachable - Bugzilla [#60634](https://bugzilla.xamarin.com/show_bug.cgi?id=60634) - Assertion failure 'align > 0' happening as of d15-5 - Bugzilla [#60680](https://bugzilla.xamarin.com/show_bug.cgi?id=60680) - C# 7 ref returns fail to compile - Bugzilla [#60771](https://bugzilla.xamarin.com/show_bug.cgi?id=60771) - Attempting to JIT compile method 'System.Runtime.CompilerServices.Unsafe:Add (byte&,int)' while running in aot-only mode - Bugzilla [#60865](https://bugzilla.xamarin.com/show_bug.cgi?id=60865) - \* Assertion at mini-codegen.c:2264, condition \`sp > 0' not met - Bugzilla [#61202](https://bugzilla.xamarin.com/show_bug.cgi?id=61202) - Fatal error when adding aspect ratio constraint - GitHub [#6169](https://github.com/mono/mono/issues/6169) - Thread objects are being leaked - GitHub [#6187](https://github.com/mono/mono/issues/6187) - mkbundle Linux - program doesn't run on system unless `mono-core` is installed - GitHub [#6192](https://github.com/mono/mono/issues/6192) - System.Reflection.Emit: PropertyBuilder with generic type doesn't add generic parameter - GitHub [#6320](https://github.com/mono/mono/issues/6320) - \[arm\] unaligned access in `ves_icall_System_ValueType_Equals` - GitHub [#6339](https://github.com/mono/mono/issues/6339) - System.TypeLoadException is thrown when run .net standard library with Mono - GitHub [#6383](https://github.com/mono/mono/issues/6383) - System.Diagnostics.ProcessTest.Start1_FileName_NotFound failing - GitHub [#6401](https://github.com/mono/mono/issues/6401) - Invalid array cast is supported - GitHub [#6414](https://github.com/mono/mono/issues/6414) - sbyte comparison broken by optimization - GitHub [#6490](https://github.com/mono/mono/issues/6490) - Reenable weak-fields.exe test - GitHub [#6721](https://github.com/mono/mono/issues/6721) - Negate operation on uint.MaxValue gives wrong result on arm64 - GitHub [#6777](https://github.com/mono/mono/issues/6777) - Memory corruption in Mono 5.8.0.108. - GitHub [#6848](https://github.com/mono/mono/issues/6848) - netstandard facade dlls have different public key tokens - GitHub [#6848](https://github.com/mono/mono/issues/6948) - \[XI\]WatchOS apps fail to build with error "Undefined symbols for architecture armv7k" using XI with mono-2017-12 support - GitHub [#6940](https://github.com/mono/mono/issues/6940) - DNS lookup of IPv6-only hosts fails - GitHub [#7086](https://github.com/mono/mono/issues/7086) - Hybrid AOT throws invalid cast exception on dictionaries indexed with enum - GitHub [#7093](https://github.com/mono/mono/issues/7093) - Regression in Array interface conversions - GitHub [#7095](https://github.com/mono/mono/issues/7095) - Assertion at class-accessors.c:31, condition 'mono_class_is_ginst (klass)' not met - GitHub [#7262](https://github.com/mono/mono/issues/7262) - .config with dllmap not working with app domains with shadow copying enabled - GitHub [#7338](https://github.com/mono/mono/issues/7338) - Finalizer crashes because of FileSystemWatcher Dispose exception in FileSystemWatcher_mobile.cs - GitHub [#7364](https://github.com/mono/mono/issues/7364) - watchOS/LLVM crashes at launch on device - GitHub [#7408](https://github.com/mono/mono/issues/7408) - No longer builds with CentOS 6 (GCC 4.4.7) - GitHub [#7637](https://github.com/mono/mono/issues/7637) - iOS release build: "Could not AOT the assembly" -> "p - buf \< buf_size not met" - GitHub [xamarin/maccore#629](https://github.com/xamarin/maccore/issues/629) - iOS 32-bit sim: TimeZoneTest.TestCtors (D02) fails ## Contributors Aleksey Kliger, Alex Rønne Petersen, Alexander Kyte, Alexander Köplinger, Alexis Christoforides, Andreas Lindh, Ankit Jain, Bernhard Urban, Brendan Zagaeski, Chris Hamons, Cody Russell, Dave Curylo, David Karlaš, Egor Bogatov, Hugh Bellamy, Jo Shields, Johan Lorensson, Jon Purdy, Jonathan Chambers, Jonathan Peppers, Jonathan Pryor, Josip Medved, Katelyn Gadd, Konstantin Safonov, Lluis Sanchez, Ludovic Henry, Manuel de la Pena, Marek Habersack, Marek Safar, Marius Ungureanu, Martin Baulig, Miguel de Icaza, Mikhail Filippov, Nate Woolls, Neale Ferguson, Radek Doulik, Rodrigo Kumpera, Rolf Bjarne Kvinge, Stephen C. Wills, Uri Simchoni, Vincent Povirk, Vlad Brezae, Vladimir Kargov, Vladimir Kazakov, YuriyGS, Zoltan Varga, cherusker, lateralusX, markusbeth, oittaa, robotrovsky, vinogradniy