Viktor Hofer [Wed, 8 Apr 2020 01:09:31 +0000 (03:09 +0200)]
Redesign the subset feature (#34663)
* Redesign subset feature and remove subsetcategory
Implement proposal from https://github.com/dotnet/runtime/issues/34403.
Remove subsetcategory and allow all subsets to specified via the -subset
switch.
Alexander Köplinger [Wed, 8 Apr 2020 00:03:39 +0000 (02:03 +0200)]
Remove .pkgproj from Mono (#34643)
They are no longer needed since we have normal runtime packs now.
Jo Shields [Wed, 8 Apr 2020 00:00:28 +0000 (20:00 -0400)]
Initial addition of tvOS Mono (#34475)
Viktor Hofer [Tue, 7 Apr 2020 23:26:53 +0000 (01:26 +0200)]
Rename CoreFx.Private.TestUtilities and reference it in slns (#34656)
* Rename CoreFx.Private.TestUtilities to TestUtilities
* Add TestUtilities reference to slns
David Wrighton [Tue, 7 Apr 2020 21:53:22 +0000 (14:53 -0700)]
Publish crossgen2 as a .zip/tar.gz file (#34623)
- For consumption in dotnet-docker repo
David Wrighton [Tue, 7 Apr 2020 21:49:50 +0000 (14:49 -0700)]
Fix unsupported instruction set handling in crossgen2 (#34605)
- A refactoring during crossgen2 production in the recent pr broke the unsupported instruction set mode for crossgen
Fixes #34628
dotnet-maestro[bot] [Tue, 7 Apr 2020 21:48:26 +0000 (21:48 +0000)]
[master] Update dependencies from 5 repositories (#34275)
* Update dependencies from https://github.com/dotnet/llvm-project build
20200324.1
- runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools - 6.0.1-alpha.1.20174.1
- runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk - 6.0.1-alpha.1.20174.1
- runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools - 6.0.1-alpha.1.20174.1
- runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk - 6.0.1-alpha.1.20174.1
- runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools - 6.0.1-alpha.1.20174.1
- runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk - 6.0.1-alpha.1.20174.1
* Update dependencies from https://github.com/mono/linker build
20200329.1
- ILLink.Tasks - 5.0.0-preview.3.20179.1
* Update dependencies from https://github.com/microsoft/vstest build
20200330-01
- Microsoft.NET.Test.Sdk - 16.6.0-preview-
20200330-01
* Update dependencies from https://github.com/dotnet/arcade build
20200330.5
- Microsoft.DotNet.XUnitExtensions - 5.0.0-beta.20180.5
- Microsoft.DotNet.VersionTools.Tasks - 5.0.0-beta.20180.5
- Microsoft.DotNet.ApiCompat - 5.0.0-beta.20180.5
- Microsoft.DotNet.Arcade.Sdk - 5.0.0-beta.20180.5
- Microsoft.DotNet.Build.Tasks.Feed - 5.0.0-beta.20180.5
- Microsoft.DotNet.Build.Tasks.Packaging - 5.0.0-beta.20180.5
- Microsoft.DotNet.Build.Tasks.SharedFramework.Sdk - 5.0.0-beta.20180.5
- Microsoft.DotNet.Build.Tasks.TargetFramework.Sdk - 5.0.0-beta.20180.5
- Microsoft.DotNet.CodeAnalysis - 5.0.0-beta.20180.5
- Microsoft.DotNet.GenAPI - 5.0.0-beta.20180.5
- Microsoft.DotNet.GenFacades - 5.0.0-beta.20180.5
- Microsoft.DotNet.Helix.Sdk - 5.0.0-beta.20180.5
- Microsoft.DotNet.RemoteExecutor - 5.0.0-beta.20180.5
- Microsoft.DotNet.XUnitConsoleRunner - 2.5.1-beta.20180.5
* Update dependencies from https://github.com/mono/linker build
20200331.4
- ILLink.Tasks - 5.0.0-preview.3.20181.4
* Update dependencies from https://github.com/mono/linker build
20200331.6
- ILLink.Tasks - 5.0.0-preview.3.20181.6
* Update dependencies from https://github.com/microsoft/vstest build
20200401-02
- Microsoft.NET.Test.Sdk - 16.6.0
* Update dependencies from https://github.com/dotnet/arcade build
20200401.2
- Microsoft.DotNet.XUnitExtensions - 5.0.0-beta.20201.2
- Microsoft.DotNet.VersionTools.Tasks - 5.0.0-beta.20201.2
- Microsoft.DotNet.ApiCompat - 5.0.0-beta.20201.2
- Microsoft.DotNet.Arcade.Sdk - 5.0.0-beta.20201.2
- Microsoft.DotNet.Build.Tasks.Feed - 5.0.0-beta.20201.2
- Microsoft.DotNet.Build.Tasks.Packaging - 5.0.0-beta.20201.2
- Microsoft.DotNet.Build.Tasks.SharedFramework.Sdk - 5.0.0-beta.20201.2
- Microsoft.DotNet.Build.Tasks.TargetFramework.Sdk - 5.0.0-beta.20201.2
- Microsoft.DotNet.CodeAnalysis - 5.0.0-beta.20201.2
- Microsoft.DotNet.GenAPI - 5.0.0-beta.20201.2
- Microsoft.DotNet.GenFacades - 5.0.0-beta.20201.2
- Microsoft.DotNet.Helix.Sdk - 5.0.0-beta.20201.2
- Microsoft.DotNet.RemoteExecutor - 5.0.0-beta.20201.2
- Microsoft.DotNet.XUnitConsoleRunner - 2.5.1-beta.20201.2
* Update dependencies from https://github.com/microsoft/vstest build
20200402-01
- Microsoft.NET.Test.Sdk - 16.6.0-preview-
20200402-01
* Update dependencies from https://github.com/mono/linker build
20200402.1
- ILLink.Tasks - 5.0.0-preview.3.20202.1
* Update dependencies from https://github.com/mono/linker build
20200403.2
- ILLink.Tasks - 5.0.0-preview.3.20203.2
* Update dependencies from https://github.com/dotnet/runtime-assets build
20200403.1
- System.Windows.Extensions.TestData - 5.0.0-beta.20203.1
- System.Security.Cryptography.X509Certificates.TestData - 5.0.0-beta.20203.1
- System.Private.Runtime.UnicodeData - 5.0.0-beta.20203.1
- System.Net.TestData - 5.0.0-beta.20203.1
- System.IO.Packaging.TestData - 5.0.0-beta.20203.1
- System.IO.Compression.TestData - 5.0.0-beta.20203.1
- System.Drawing.Common.TestData - 5.0.0-beta.20203.1
- System.ComponentModel.TypeConverter.TestData - 5.0.0-beta.20203.1
* Update dependencies from https://github.com/dotnet/llvm-project build
20200331.1
- runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools - 6.0.1-alpha.1.20181.1
- runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools - 6.0.1-alpha.1.20181.1
- runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk - 6.0.1-alpha.1.20181.1
- runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools - 6.0.1-alpha.1.20181.1
- runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk - 6.0.1-alpha.1.20181.1
- runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk - 6.0.1-alpha.1.20181.1
* Update dependencies from https://github.com/dotnet/runtime-assets build
20200406.1
- System.Windows.Extensions.TestData - 5.0.0-beta.20206.1
- System.Security.Cryptography.X509Certificates.TestData - 5.0.0-beta.20206.1
- System.Private.Runtime.UnicodeData - 5.0.0-beta.20206.1
- System.Net.TestData - 5.0.0-beta.20206.1
- System.IO.Packaging.TestData - 5.0.0-beta.20206.1
- System.IO.Compression.TestData - 5.0.0-beta.20206.1
- System.Drawing.Common.TestData - 5.0.0-beta.20206.1
- System.ComponentModel.TypeConverter.TestData - 5.0.0-beta.20206.1
* Update dependencies from https://github.com/mono/linker build
20200406.2
- ILLink.Tasks - 5.0.0-preview.3.20206.2
* Update dependencies from https://github.com/dotnet/llvm-project build
20200406.1
- runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools - 6.0.1-alpha.1.20206.1
- runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools - 6.0.1-alpha.1.20206.1
- runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk - 6.0.1-alpha.1.20206.1
- runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools - 6.0.1-alpha.1.20206.1
- runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk - 6.0.1-alpha.1.20206.1
- runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk - 6.0.1-alpha.1.20206.1
* Update dependencies from https://github.com/microsoft/vstest build
20200406-12
- Microsoft.NET.Test.Sdk - 16.6.0-preview-
20200406-12
Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: Viktor Hofer <viktor.hofer@microsoft.com>
Levi Broderick [Tue, 7 Apr 2020 19:16:24 +0000 (12:16 -0700)]
Fix various LastIndexOf bugs when given zero-length target values (#34616)
- string.LastIndexOf(string.Empty) shouldn't perform -1 adjustment
- MemoryExtensions.LastIndexOf(ROS<char>, string.Empty) shouldn't return 0
- Tighten up some existing unit tests
Eric Erhardt [Tue, 7 Apr 2020 18:57:31 +0000 (13:57 -0500)]
Enable RuntimeIdentifierTests (#34595)
* Enable RuntimeIdentifierTests
Now that we have an updated test host, we can enable the RuntimeInformation.RuntimeIdentifier tests that are disabled.
Fix #26780
* Trim quotes from ID in /etc/os-release
Matt Mitchell [Tue, 7 Apr 2020 17:01:44 +0000 (10:01 -0700)]
Feed cleanup (#34044)
* Feed cleanup
Move away from blob feeds.
* Add dotnet5 feed
* Update version of System.CommandLine.Experimental
* Revert to released versions in SuperILC and R2RDump
* Don't remove public feeds for tests
Stephen Toub [Tue, 7 Apr 2020 14:49:38 +0000 (10:49 -0400)]
Fix ObjectDisposedException in FileSystemWatcher.OSX.cs (#34589)
Synchronize access to disposing the SafeHandle, and clean up some code distributed oddly between the ctor and Start, so as to make more fields readonly and only register for cancellation once everything has started, to avoid race conditions that could otherwise result between cancellation and starting happening concurrently.
Viktor Hofer [Tue, 7 Apr 2020 13:37:19 +0000 (15:37 +0200)]
Restore followup (#34632)
* Remove dead yml file
* Fix installer prepare for publish
Egor Bogatov [Tue, 7 Apr 2020 12:02:48 +0000 (15:02 +0300)]
Use HostArch as a default TargetArchitecture (#34619)
Jan Vorlicek [Tue, 7 Apr 2020 10:21:38 +0000 (12:21 +0200)]
Merge pull request #34468 from janvorli/fix-native-callable-method-hijack
Prevent return address hijacking of NativeCallable method
Vlad Brezae [Tue, 7 Apr 2020 09:56:08 +0000 (12:56 +0300)]
[sgen] Fix coverity issue (#34629)
Jan Vorlicek [Tue, 7 Apr 2020 09:21:48 +0000 (11:21 +0200)]
Add cgroup v2 support to coreclr (#34334)
Upstream cgroup v2 documentation is available at:
https://www.kernel.org/doc/Documentation/cgroup-v2.txt
Some notable differences between cgroup v1 and v2, from a coreclr point
of view, include:
- cgroup v2 has a single hierarchy, so we just look for a single "cgroup2"
entry in /proc/self/mountinfo (without looking for a subsystem match).
- Since cgroup v2 has a single hierarchy, /proc/self/cgroup generally
has a single line "0::/path". There's no need to match subsystems or
hierarchy ids here.
- "memory.limit_in_bytes" is now "memory.max". It can contain the
literal "max" to indicate no limit.
- "memory.usage_in_bytes" is now "memory.current"
- "cpu.cfs_quota_us" and "cpu.cfs_period_us" have been combined into a
single "cpu.max" file with the format "$MAX $PERIOD". The max value
can be a literal "max" to indicate a limit is not active.
It is possible to have both cgroup v1 and v2 enabled on a host (but not
inside a container, AFAIK). In that case, this change will pick one
based on /sys/fs/cgroup.
Fadi Hanna [Tue, 7 Apr 2020 05:19:15 +0000 (22:19 -0700)]
Fix IsBlittable flag bug on types. (#34613)
The issue is that we are automatically assuming that types are blittable until proven otherwise while traversing the list of fields declared on the type. In the case of a type with no fields, we have to also check if the parent type is blittable, before blindly setting the flag to true (Ex: what if the base type has non-blittable fields?)
Jan Kotas [Tue, 7 Apr 2020 04:38:18 +0000 (21:38 -0700)]
Change FrameworkName to .NET (#34615)
Fixes #33680
Jan Kotas [Tue, 7 Apr 2020 04:33:03 +0000 (21:33 -0700)]
Use valid instructions in StubPrecode and NDirectImportPrecode on x64 (#34611)
StubPrecode and NDirectImportPrecode precoded used undefined instruction
encodings on x64 due to copy&paste from x86. Change them to use valid
instructions.
Aaron Robinson [Tue, 7 Apr 2020 04:18:28 +0000 (21:18 -0700)]
Add back support for Delegate field marshaling (#34620)
* Block route trip of function pointer as Delegate field.
Add tests for scenario.
* Update MarshalStructAsParamDLL.cpp
Anirudh Agnihotry [Tue, 7 Apr 2020 04:12:10 +0000 (21:12 -0700)]
moving more tfm dependent properties to targets file (#34532)
* moving more tfm dependent properties to targets file
* correct allconfig build
* shimrefpath -> runtime and indentation
Aaron Robinson [Tue, 7 Apr 2020 04:11:19 +0000 (21:11 -0700)]
Missed feedback. (#34622)
Egor Bogatov [Tue, 7 Apr 2020 01:25:11 +0000 (04:25 +0300)]
[mono] Implement Arm intrinsics: ArmBase, Crc32 (#34240)
* Implement Arm.ArmBase and Arm.Crc32 intrinsics
Marcus Turewicz [Mon, 6 Apr 2020 23:56:54 +0000 (09:56 +1000)]
Adds de/serialization support for JsonDocument (#34537)
* Adds deserialization support for JsonDocument
This change adds support to `System.Text.Json` for deserializing `JsonDocument`.
Specifically, an internal converter `JsonDocumentConverter` is added to the default converter dictionary.
I have created a basic test, but I feel more could be done here, and it may not be in the right file/class - some guidance would be helpful here.
Fixes #1573
* Adds JsonDocumentTests
* Dispose JsonDocument
Aaron Robinson [Mon, 6 Apr 2020 23:48:39 +0000 (16:48 -0700)]
Don't test ANSI any mapping on non en-US locales. (#34599)
Tomáš Rylek [Mon, 6 Apr 2020 22:33:51 +0000 (00:33 +0200)]
SuperIlc fixes to unblock composite build using the shared library (#34430)
monojenkins [Mon, 6 Apr 2020 22:14:07 +0000 (18:14 -0400)]
[llvm] Define a separate symbol for the aot method info for every method. Pass this symbol to the init functions instead of the method index. (#34009)
This removes a dependency the generated code has on the method index, hopefully allowing separate compilation etc. in the future.
<!--
Thank you for your Pull Request!
If you are new to contributing to Mono, please try to do your best at conforming to our coding guidelines http://www.mono-project.com/community/contributing/coding-guidelines/ but don't worry if you get something wrong. One of the project members will help you to get things landed.
Does your pull request fix any of the existing issues? Please use the following format: Fixes #issue-number
-->
Co-authored-by: vargaz <vargaz@users.noreply.github.com>
Kevin Jones [Mon, 6 Apr 2020 17:31:58 +0000 (13:31 -0400)]
Enable more nullable reference types in asn.xslt.
string and Oid types on Choice can be null.
Reference types that are @optional can be null.
Also, remove #nullable enable, because all projects that include the ASN.1 generate files should already have nullable enable project-wide.
Marcus Turewicz [Mon, 6 Apr 2020 17:27:59 +0000 (03:27 +1000)]
Adds tests for missing object and collection properties in S.T.J.S (#34559)
Elinor Fung [Mon, 6 Apr 2020 17:23:46 +0000 (10:23 -0700)]
Fix missing version info in host binaries (#34520)
Mitchell Hwang [Mon, 6 Apr 2020 16:30:36 +0000 (12:30 -0400)]
Add build configuration to generate runtime packs for Android (#34192)
* [installer] Include Android into installer
* [eng] Provide Android with just Microsoft.NETCore.App.Runtime
* Attempt to make same changes from iOS PR
Co-authored-by: Mitchell Hwang <mihw@microsoft.com>
Marcus Turewicz [Mon, 6 Apr 2020 15:55:19 +0000 (01:55 +1000)]
Fix contructor attributes nullability in S.R.E.CustomAttributeBuilder (#34556)
* Fix contructor attributes nullability in S.R.E.CustomAttributeBuilder
Fixes #819
* Finalise nullable
* Updates ref
Gleb Balykov [Mon, 6 Apr 2020 15:40:10 +0000 (18:40 +0300)]
Fix Linux x86 build (#34548)
* Fix Linux x86 build
Related to #33005
* Fix Linux x86 build
Related to #33653, #33005
* Fix Linux x86 build
Related to #32250
Omair Majid [Tue, 31 Mar 2020 16:06:44 +0000 (12:06 -0400)]
Add cgroup v2 support to coreclr
Upstream cgroup v2 documentation is available at:
https://www.kernel.org/doc/Documentation/cgroup-v2.txt
Some notable differences between cgroup v1 and v2, from a coreclr point
of view, include:
- cgroup v2 has a single hierarchy, so we just look for a single "cgroup2"
entry in /proc/self/mountinfo (without looking for a subsystem match).
- Since cgroup v2 has a single hierarchy, /proc/self/cgroup generally
has a single line "0::/path". There's no need to match subsystems or
hierarchy ids here.
- "memory.limit_in_bytes" is now "memory.max". It can contain the
literal "max" to indicate no limit.
- "memory.usage_in_bytes" is now "memory.current"
- "cpu.cfs_quota_us" and "cpu.cfs_period_us" have been combined into a
single "cpu.max" file with the format "$MAX $PERIOD". The max value
can be a literal "max" to indicate a limit is not active.
It is possible to have both cgroup v1 and v2 enabled on a host (but not
inside a container, AFAIK). In that case, this change will pick one
based on /sys/fs/cgroup.
Prashanth Govindarajan [Mon, 6 Apr 2020 15:22:34 +0000 (08:22 -0700)]
Changed triggered by the StringBuilder analyzer (#34574)
Viktor Hofer [Mon, 6 Apr 2020 13:38:04 +0000 (15:38 +0200)]
Remove entry point helper scripts (#33756)
* Remove entry point helper scripts
The entry point helper scripts were useful during the consolidation of
the repositories. This work is mostly done and the build.cmd/sh script
should be used, going forward.
Jan Vorlicek [Mon, 6 Apr 2020 13:13:27 +0000 (15:13 +0200)]
Fix x86 build break and reflect PR feedback
Viktor Hofer [Mon, 6 Apr 2020 09:54:10 +0000 (11:54 +0200)]
Enable restore for ref and src projects in libs (#33553)
- Use RestoreUseStaticGraphEvaluation which improves no-op restore by 10-15x down to 10-20 seconds.
- .builds msbuild files renamed to .proj as RestoreUseStaticGraphEvaluation throws for non .proj files without an env var set.
- Introducing subsets for libraries and mono and replacing -buildtests switch which was only working for libraries in favor of the subset switch -subset tests which works consistently.
- Fixing the Microsoft.DotNet.CodeAnalysis analyzer which wasn't running and adding missing exclusions.
- Separating restore and build phases in different parts in the repo (ie for installer.tasks) as generated props and targets need to be imported which requires a reevaluation in the build phase.
- Fix eng/docker/build-docker-sdk.ps1 by using the official build entrypoints (cc @alnikola)
- Remove a few depprojs in favor of project restore (faster restore :))
- Fix root code coverage measurement not working correctly
- Traversal support instead of dir.traversal.targets or manual build target defines.
- Introduce a root Build.proj entrypoint which is responsible for building and restoring the repository. This is necessary to enable the new NuGet fast restore which works best and fastest with a single entrypoint.
- Avoid binclashes in libraries and between libraries and installer (netstandard.depproj vs netstandard.csproj)
- Upgrading the SDK to 5.0 latest
- Code cleanup
Fadi Hanna [Mon, 6 Apr 2020 03:04:38 +0000 (20:04 -0700)]
Fix incorrect assumption around the presence of ICF frames in EH codebase for 64-bit targets (#34526)
Kevin Jones [Sun, 5 Apr 2020 19:11:43 +0000 (15:11 -0400)]
Support ECParameters that contain only D on Windows and Linux
If D (private key) is supplied but not the public key (Q), permit
this and allow the platform to re-calculate the public key from
the private key.
* Windows uses CNG blobs with the Q.X and Q.Y values set to (0,0).
* LInux uses the ECC math module to recompute Q from D and G.
* macOS is TBD.
monojenkins [Sun, 5 Apr 2020 19:09:04 +0000 (15:09 -0400)]
[llvm] Enable optimizations for LLVM 9 JIT. (#34555)
Share more code between LLVM 6 and LLVM 9.
Mangler::getNameWithPrefix takes a Twine, not a std::string, so use a
StringRef to avoid an unnecessary allocation.
InstructionCombiningPass grew a dependency on
ProfileSummaryInfoWrapperPass in
https://github.com/dotnet/llvm-project/commit/
09e539fcaebb6362795d352cdcf4a818cf4d0d6a,
which depends on the enclosing FunctionPassManager having a valid
reference to a module. This commit adds a dummy module to satisfy this,
instead of recreating a new FunctionPassManager on every compilation.
(See also
http://lists.llvm.org/pipermail/llvm-dev/2019-March/130690.html.)
Co-authored-by: imhameed <imhameed@users.noreply.github.com>
Bruce Forstall [Sun, 5 Apr 2020 17:10:46 +0000 (10:10 -0700)]
Fix memory leak in SuperPMI (#34523)
Introduced by change to Heap APIs. Also fixes a long-existing
memory leak on Linux.
Introduce a small, simple class to keep track of memory allocations
associated with the CompileResult that we need to free. In the replay
case, SuperPMI allocates these (such as for the JIT calling allocMem).
In the case of collection, the VM allocates memory for allocMem (and related),
so that memory doesn't need to be tracked.
monojenkins [Sun, 5 Apr 2020 14:20:58 +0000 (10:20 -0400)]
[WIP] LLVM changes (#33847)
<!--
Thank you for your Pull Request!
If you are new to contributing to Mono, please try to do your best at conforming to our coding guidelines http://www.mono-project.com/community/contributing/coding-guidelines/ but don't worry if you get something wrong. One of the project members will help you to get things landed.
Does your pull request fix any of the existing issues? Please use the following format: Fixes #issue-number
-->
Co-authored-by: vargaz <vargaz@users.noreply.github.com>
Stephen Toub [Sun, 5 Apr 2020 11:41:49 +0000 (07:41 -0400)]
Remove a few string allocations from System.IO.FileSystem (#34551)
Elinor Fung [Sun, 5 Apr 2020 08:34:03 +0000 (01:34 -0700)]
Fix host linker options to have -Bsymbolic (#34534)
* Fix host linker options to have -Bsymbolic
* Remove -Bsymbolic-functions
Marcus Turewicz [Sun, 5 Apr 2020 03:13:17 +0000 (13:13 +1000)]
Adds scripting guide doc (#34539)
Scripting guide for Shell, PowerShell and CMD files for styling or other guidance.
Fixes #9317
monojenkins [Sat, 4 Apr 2020 23:57:56 +0000 (19:57 -0400)]
[debugger] Bump protocol for multi threaded single step implementation (#34531)
As suggested by @jbevain we should bump the protocol to implement multi threaded single step.
Co-authored-by: thaystg <thaystg@users.noreply.github.com>
Thomas Levesque [Sat, 4 Apr 2020 21:50:31 +0000 (23:50 +0200)]
Add test for max depth in exception message (#34528)
Co-authored-by: Thomas Levesque <thomaslevesque@users.noreply.github.com>
Karel Zikmund [Sat, 4 Apr 2020 21:17:51 +0000 (14:17 -0700)]
Disable test DnsGetHostEntry_LocalHost_ReturnsFqdnAndLoopbackIPs (#34527)
Aaron Robinson [Sat, 4 Apr 2020 16:48:45 +0000 (09:48 -0700)]
Memory leak during marshal failure. (#34533)
Minor code cleanup to make the logic clearer.
Borislav Ivanov [Sat, 4 Apr 2020 16:28:45 +0000 (19:28 +0300)]
Update formatting (#34538)
Nathan Ricci [Sat, 4 Apr 2020 16:28:03 +0000 (12:28 -0400)]
Added links to issues in issues.targets. (#34530)
Adeel Mujahid [Sat, 4 Apr 2020 16:27:01 +0000 (19:27 +0300)]
Define dirent d_type for Solaris based OS (#34263)
Matt Mitchell [Sat, 4 Apr 2020 14:19:06 +0000 (07:19 -0700)]
Fixup more package dependencies for Microsoft.Windows.Compatibility (#34479)
A few more dependencies on removed packages. System.Reflection.Emit*
monojenkins [Sat, 4 Apr 2020 11:37:03 +0000 (07:37 -0400)]
[wasm] Wasm TimeZoneInfo implementation VFS (#34186)
Right now WebAssembly does not have an implementation for TimeZoneInfo and instead throws exceptions.
This is an alternate implementation of https://github.com/mono/mono/pull/17617 that loads the zone information into the webassembly virtual file system using a pre-loaded file package.
__BCL Changes__
TimeZoneInfo implementation for WebAssembly to read from WASM VFS `/zoneinfo`.
- Remove `TimeZoneInfo.WebAssembly.cs` file
- Remove source dependencies on `TimeZoneInfo.WebAssembly.cs`.
- Modify TimeZoneInfo for specific WASM functionality
- Default root directory is `zoneinfo`
- Add icall `mono_timezone_get_local_name` for WASM in CreateLocal
- Add icall implementation
- ves_icall_System_TimeZoneInfo_mono_timezone_get_local_name
__WASM Runtime Build__
- Add `-s FORCE_FILESYSTEM=1` to mono wasm runtime build
- Required so that it includes support for loading pre preload packages
* Message when generating the zoneinfo data.
> Remember to build the main file with -s FORCE_FILESYSTEM=1 so that it includes support for loading this file package
- Add targets to run time zone tests.
- make run-tzd-sample
- make run-tzd-interp-sample
- make run-tzd-aot-sample
- Modify `runtime-tests.js` to load and parse the zoneinfo data manually to load into the VFS.
__WASM Driver - aka `driver.c`__
- Add implementations of the following:
- mono_timezone_get_local_name
These will be called from the managed bcl module `TimeZoneInfo.cs` module.
__packager.exe__
- Add `-s FORCE_FILESYSTEM=1`
- Required so that it includes support for loading pre preload packages
* Message when generating the zoneinfo data.
> Remember to build the main file with -s FORCE_FILESYSTEM=1 so that it includes support for
__Zone Info data and support files__
- Three files for zoneinfo VFS support.
- `mono-webassembly-zoneinfo-fs-smd.js.metadata` - This is the separate metadata output by emscripten file-packager. Used to parse the zoneinfo data in non browser environments. See `runtime-tests.js`
- `mono-webassembly-zoneinfo-fs.js` - Output by emscripten file-packager that will be referenced by browser environments to load the zoneinfo data into the VFS at `/zoneinfo`
- `zoneinfo.data` - The binary file output by emscripten file-packager. The file contains the actual zoneinfo data loaded into the VFS and parsed by `TimeZoneInfo`.
The packages are generated automatically and the repo is temporarily at: https://github.com/kjpou1/mono-webassembly-zoneinfo
There are some limitations to this method where the file packages generated by the emscripten [file_packager](https://emscripten.org/docs/porting/files/packaging_files.html#packaging-using-the-file-packager-tool) only runs within a web browser.
Special consideration is needed to load the VFS with the data outside of browser. See modification for `runtime-tests.js` where the zoneinfo data is parsed manually and loaded into the VFS. We may need to create our own file packager to handle some of the other cases.
Co-authored-by: kjpou1 <kjpou1@users.noreply.github.com>
Santiago Fernandez Madero [Sat, 4 Apr 2020 10:04:36 +0000 (03:04 -0700)]
Fix testhost publish condition and omptimize assets we publish in official builds (#34469)
* Fix testhost publish condition and omptimize assets we publish in official builds
* Publish ref/ folder in official builds as it is needed for the installer build
* Just validate all assets paths when IncludeOOB* is true
monojenkins [Sat, 4 Apr 2020 08:08:12 +0000 (04:08 -0400)]
[wasm][debugger] Improve array visualization (#34482)
TODO: viz for multidim arrays
Co-authored-by: radical <radical@users.noreply.github.com>
Eric Erhardt [Sat, 4 Apr 2020 02:26:04 +0000 (21:26 -0500)]
Update Dotnet host for testing and other runtime => runtime dependencies (#34516)
Eric Erhardt [Sat, 4 Apr 2020 01:47:17 +0000 (20:47 -0500)]
Move DependencyModel to libraries (#34296)
* Move DependencyModel to libraries
Moving DependencyModel to the same folder and infrastructure as the rest of our libraries, and out of the installer folder.
I also dropped support for anything below netstandard2.0 at this time.
Contributes to #3470
Fix #3425
* Exclude DependencyModel in shims and package checks since it has a duplicated type with System.Collections.
* Harvest previous TFM assets from the previously shipped package.
This also means we start building DependencyModel for net461 to ensure full framework support works correctly, and doesn't pick up the old net451 asset.
* Fix unit tests to consistently pass on core and netfx.
* Add back HashCodeCombiner as obsolete.
* Fix DependencyModel pkg build to reference the correct version of Newtonsoft.Json for the harvested package assets.
* Adding IgnoredTypes for Serialization.Primitives in netcoreapp1.0 and netcoreapp1.1
Co-authored-by: Jose Perez Rodriguez <joperezr@microsoft.com>
Kunal Pathak [Sat, 4 Apr 2020 00:26:57 +0000 (17:26 -0700)]
BitOperations arm64 intrinsic for LeadingZeroCount, TrailingZeroCount and Log2 (#34486)
ARM64 intrinsic for:
- LeadingZeroCount
- Log2
- TrailingZeroCount
Jeremy Koritzinsky [Sat, 4 Apr 2020 00:24:12 +0000 (17:24 -0700)]
Fix building WinRT tests on new Windows SDK (with new cppwinrt). (#34513)
Jan Vorlicek [Sat, 4 Apr 2020 00:22:30 +0000 (17:22 -0700)]
Little refactoring based on PR feedback
Anirudh Agnihotry [Fri, 3 Apr 2020 23:09:55 +0000 (16:09 -0700)]
Moving more Tfm specific properties to the targetFramework.props file (#34349)
* follow up
* other occurences
* fixing compiler services failure
David Wrighton [Fri, 3 Apr 2020 23:02:12 +0000 (16:02 -0700)]
Hardware instruction set support for crossgen2 (#33274)
- Add support for the --instruction-set parameter as described in #226 .
NOTE: As the abi for Vector parameters is not yet stable, support for the --instruction-set parameter is only enabled if --inputbubble is also enabled. Parallel work to stabilize the abi is in progress, but is not complete.
ALSO NOTE: The names of the instruction sets are shared with mono, and don't follow the names in issue #226
- Add concept of baseline instruction set support to R2R file format
- Can be applied at a per method level or at the entire R2R file level
- R2RDump support for dumping the extra data
- Refactor how support for hardware intrinsics beyond SSE2 support are handled in crossgen2
- Add feature to the JIT to detect which hardware features are actually used
- Tell the JIT unconditionally that SSE42+Lzcnt+Popcnt+Pclmulqdq are supported
- But if support beyond the --instruction-set specified baseline is used, notate the method with a per-method instruction set support fixup.
- This enables usage of many intrinsics in corelib with greater efficiency than today
- This enables usage of SSE42 and below intrinsics safely in non-CoreLib code. Use of higher level intrinsics in non CoreLib code will generate code which does not use the higher level intrinsic, and note that the method's code should not be used in the presence of hardware which does support greater CPU capabilities.
- In the future a logical enhancement of this work would be to generate multiple bodies of code to handle these more complex cases.
- In combination with the --instruction-set argument, if Avx2 is enabled, then the logic gracefully adds a dependency on Avx2 capability and Vector<T> becomes useable by crossgen'd code.
David Mason [Fri, 3 Apr 2020 22:10:18 +0000 (15:10 -0700)]
Add profiler tests to the runtime repo (#34411)
Ports GCBasic, ReJIT, and EventPipe tests as well as adds a test that verifies profilers can call MetaDataGetDispenser.
Stephen Toub [Fri, 3 Apr 2020 21:18:30 +0000 (17:18 -0400)]
Enable nullable reference types for mono's Corelib (#34400)
* Enable nullable reference types for mono's Corelib
Corelib had nullable reference types enabled, but all warnings were suppressed. This fixes the thousands of warnings that were being hidden and fully enables nullable reference types for mono's corelib, as it is for coreclr's corelib.
I copied over the public API annotations from coreclr's corelib and tried to annotate the mono source as accurately as possible. However, I'm 100% sure there are issues, both places I misexpressed the contract of an internal API and places where I suppresed warnings with `!` where it likely could actually null ref. Along the way, when there was an obvious null ref where coreclr was doing a null check and providing different behavior, I fixed it or at least added a comment, but I expect there are more issues lurking.
* Fix iOS build for GetSpecialFolder
* Address PR feedback
Tom Deseyn [Fri, 3 Apr 2020 18:42:52 +0000 (20:42 +0200)]
Socket.Windows: support ConnectAsync(SocketAsyncEventArgs) for UDP, and Unix sockets (#33674)
Socket.Windows: support ConnectAsync(SocketAsyncEventArgs) for non-stream protocols
Eirik Tsarpalis [Fri, 3 Apr 2020 18:28:19 +0000 (19:28 +0100)]
[CBOR] Add a CborReader.SkipValue() method (#34477)
* Add a CborReader.SkipValue() method
* revert reader state format error changes
* refactor skip from recursive to imperative
* use non-allocating skips for string data items
* add a test for extremely nested values
* remove blank line
* consolidate SkipString() methods
Alexander Köplinger [Fri, 3 Apr 2020 18:24:35 +0000 (20:24 +0200)]
Disable iOS_arm builds on official builds too (#34504)
It started failing with the same issue as https://github.com/dotnet/runtime/issues/34465
Tomáš Rylek [Fri, 3 Apr 2020 17:48:08 +0000 (19:48 +0200)]
Crossgen2 fixes to enable composite build with shared framework (#34431)
These changes involve targeted fixes to issues seen due to the new
build mode and generic signature encoding fixes identified in
my offline investigation with JanV. While I locally see the tests
passing with just a handful of failures, I still seem unable to
make the tests run in the lab; I keep investigating that but
I believe it's useful to merge this delta in to let us parallelize
follow-up efforts.
Thanks
Tomas
Manish Godse [Fri, 3 Apr 2020 17:37:09 +0000 (10:37 -0700)]
Parallel Builds PRv2 (#34460)
* simplify libraries build dependencies.
* FIx depends for tests
* Fix artifact name for webAssembly
Gleb Balykov [Fri, 3 Apr 2020 16:22:56 +0000 (19:22 +0300)]
Add armel arch in help message (#34491)
Jan Kotas [Fri, 3 Apr 2020 16:21:48 +0000 (09:21 -0700)]
Delete stale CPU cache size detection (#34488)
Fixes #34478
Alexis Christoforides [Fri, 3 Apr 2020 14:28:23 +0000 (10:28 -0400)]
Port CoreCLR's TypeNameBuilder to C#, and use it in Mono too (#33701)
* Port CoreCLR's TypeNameBuilder to C#, and use it in Mono too
Mono's System.Reflection.Emit creates type names that fail to be normalized or shaped in all ways that CoreCLR does.
Port CoreCLR's mixed-mode thread-unsafe implementation to thread-safe C#, and start using it in Mono for names in TypeBuilder.
Fixes issues with e.g. null-delimited type names being passed to different Reflection.Emit builders. Contributes to https://github.com/dotnet/runtime/issues/2389.
Layomi Akinrinade [Fri, 3 Apr 2020 13:27:27 +0000 (09:27 -0400)]
Fix WriteLargeJsonToStreamWithoutFlushing test (#34489)
Egor Bogatov [Fri, 3 Apr 2020 13:24:55 +0000 (16:24 +0300)]
Don't build `System.Utf8String.Experimental.Tests.csproj` tests for mono (#34445)
nietras [Fri, 3 Apr 2020 13:20:10 +0000 (15:20 +0200)]
Fix subsetCategory is just one `-` not two `--` (#34498)
Otherwise fails with:
```
MSBUILD : error MSB1001: Unknown switch.
Switch: --subsetCategory
```
on Windows
Vlad Brezae [Fri, 3 Apr 2020 12:49:06 +0000 (15:49 +0300)]
[sgen] Implement api for allocating pinned arrays (#34398)
* [sgen] Add support for allocating pinned array
These objects will end up allocated either in LOS (which is by design not moved around) or into special major blocks where compaction doesn't take place.
* [sgen] Be consistent with coreclr on GC api
* Enable GC tests for pinned array allocation
* Skip large array allocation test on mono
Alexis Christoforides [Fri, 3 Apr 2020 12:48:12 +0000 (08:48 -0400)]
[mono][sre] Add an expected attribute on underlying fields of enum classes (#34212)
Follow CoreCLR's example and add the RTSpecialName type attribute to any class field with the 'value__' name when , used as the value store for enumeration class instances.
Second part of the "RTSpecialName fix" that started with https://github.com/dotnet/runtime/pull/33389 - before, our behavior was to add the RTSpecialName immediately, as soon as the EnumBuilder was constructed.
Contributes to https://github.com/dotnet/runtime/issues/2389
Jan Vorlicek [Fri, 3 Apr 2020 11:39:35 +0000 (13:39 +0200)]
Fix two issues detected by Valgrind (#34462)
* Fix two issues detected by Valgrind
When I have used Valgrind to investigate a memory corruption issue recently,
I've noticed that it has also reported two cases when a conditional jump
was using an uninitialized variable as one of the inputs to the condition.
This change fixes these.
Jan Vorlicek [Fri, 3 Apr 2020 08:56:03 +0000 (10:56 +0200)]
Fix Unix build break
Alexander Köplinger [Fri, 3 Apr 2020 06:04:07 +0000 (08:04 +0200)]
Disable iOS arm PR builds (#34467)
* Disable iOS arm PR builds
Infrastructure issue: https://github.com/dotnet/runtime/issues/34465
* Add tracking issue and disable installer iOS arm build too
Maryam Ariyan [Fri, 3 Apr 2020 01:51:21 +0000 (18:51 -0700)]
Remove -runtime version suffix hack for M.E. (#34464)
Tamar Christina [Fri, 3 Apr 2020 01:19:15 +0000 (02:19 +0100)]
Arm64: Add xtn and xtn2 intrinsics codegen, api and tests. (#33108)
Dan Moseley [Fri, 3 Apr 2020 01:11:08 +0000 (18:11 -0700)]
Remove @jeremykuhne from area owners (#34483)
cc @ericstj
Jared Parsons [Thu, 2 Apr 2020 22:59:51 +0000 (15:59 -0700)]
Enable warn as error for libraries (#34457)
This enables warn as error for the libraries jobs now that our builds
are warning free.
Jan Vorlicek [Thu, 2 Apr 2020 20:45:07 +0000 (22:45 +0200)]
Move the reverse pinvoke frame check to EECodeManager
Reflects PR feedback.
James Newton-King [Thu, 2 Apr 2020 20:21:24 +0000 (09:21 +1300)]
Sync changes from ASP.NET Core dynamic HPack (#34247)
David Wrighton [Thu, 2 Apr 2020 18:35:24 +0000 (11:35 -0700)]
Experimental pgo tool (#34433)
* Experimental pgo tool
- Experiment and rough design going forward for providing profile data to the compiler
* Update build so dotnet-pgo is built
Steve Pfister [Thu, 2 Apr 2020 17:42:08 +0000 (13:42 -0400)]
Add build configuration to generate runtime packs for iOS (#34050)
This adds support for generating Microsoft.NETCore.App.Runtime packs for ios-x64, ios-arm, and ios-arm64.
Ryan Lucia [Thu, 2 Apr 2020 16:45:42 +0000 (12:45 -0400)]
[meta] Add mono_type_get_name_full to public API (#34436)
This is needed by Xamarin.Android to be able to round-trip with names fetched via reflection, as the only public API for this (mono_type_get_name) uses the IL format instead.
Egor Bogatov [Thu, 2 Apr 2020 16:32:31 +0000 (19:32 +0300)]
fix iOS sample build (#34455)
Ryan Lucia [Thu, 2 Apr 2020 16:19:22 +0000 (12:19 -0400)]
[loader] Add append option to loader hook installation functions (#34284)
monojenkins [Thu, 2 Apr 2020 15:36:54 +0000 (11:36 -0400)]
[wasm][debugger] Add support for visualizing valuetypes (#33604)
Co-authored-by: radical <radical@users.noreply.github.com>
Jan Vorlicek [Thu, 2 Apr 2020 15:27:21 +0000 (17:27 +0200)]
Prevent return address hijacking of NativeCallable method
We have seen a failure in the CI where the OnHijackWorkerTripThread was
called in preemptive mode and so a contract in Thread::SetFrame down its
call chain has fired when checking that the thread is in cooperative
mode.
I have found that the issue is caused by hijacking a NativeCallable
method. Such methods switch to preemptive mode before they return and so
when they are hijacked, the OnHijackWorkerTripThread is called in
preemptive mode.
The fix is to prevent return address hijacking for NativeCallable
methods.
Manish Godse [Thu, 2 Apr 2020 14:25:28 +0000 (07:25 -0700)]
Merge pull request #34166 from mangod9/master
Add support for building S.P.CoreLib in a separate job
Jared Parsons [Thu, 2 Apr 2020 13:44:05 +0000 (06:44 -0700)]
Update WASM image (#34421)
Move to an Ubuntu image which has the `en_US.UTF-8` locale available.
This should remove the spurious warning that we're seeing during
PR / CI
closes #34280
Jan Vorlicek [Thu, 2 Apr 2020 13:11:13 +0000 (15:11 +0200)]
Fix large version bubble field offset computation (#34401)
This change fixes two bugs in field offset computation where the results
that crossgen2 was getting was different from what runtime computes. In
both cases, the problem was caused by alignment of a derived class being
done differently.
The first issue was happening for the case when the base and derived
classes are in different assemblies. Runtime detect if two assemblies
are in the same version bubble using the native manifest metadata table
containing a list of assemblies that was supposed to contain all
assemblies that the assembly being compiled was found to reference.
However, it contained only assemblies that were not in the original
assembly reference list, e.g. ones pulled in by inlining. So runtime
wasn't getting the same view on what's in the bubble.
The second issue happened for the case when both the base and derived
class were from the same assembly, but one of the ancestor classes had a
field of a value class type that was from another assembly and could be
transitively decomposed to fields of types from the same assembly or types
like primitive types, object, pointer or enums. The alignment of a derived
class members is determined based on that and runtime decision is to
align if there is any type from another assembly in the type hierarchy
of a class or in fields of any ancestors.
For example, the decision would be different for the following scenario:
Assembly A:
struct AA
{
int a;
}
Assembly B:
class B1
{
AA aa;
}
class B2 : B1
{
int x;
}
Here crossgen2 would not align the first member but runtime would. So the
layout of B2 produced by crossgen2 would be:
```
Offset Field
0 MethodTable
8 a
12 x
```
Layout produced by the runtime would be
```
Offset Field
0 MethodTable
8 a
16 x
```
The fix for the first issue is to put all referenced assemblies into the
native manifest metadata.
The fix for the second issue is to stop decomposing members of value
classes once we hit a value class that's from another module.
Tomáš Rylek [Thu, 2 Apr 2020 12:52:48 +0000 (14:52 +0200)]
R2RDump fixes for parsing composite images (#34429)
1. Fixed several inconsistencies w.r.t. signature context in
recursive descent into generic signatures based on offline
investigation with JanV.
2. Don't crash the dump upon invalid UTF8 characters.
Thanks
Tomas
Andrey Kurdyumov [Thu, 2 Apr 2020 11:55:41 +0000 (17:55 +0600)]
Fix ordering of the instructions (#34447)
Command for opening Visual Studio works from root folder,
but not inside library folder as was implied by ordering in the instructions.