Mirror changes from mono/corefx,coreclr (#17777)
commitbd278dd00dd24b3e8c735a4220afa6cb3ba317ee
authorFilip Navara <navara@emclient.com>
Tue, 12 Nov 2019 17:46:00 +0000 (12 18:46 +0100)
committerZoltan Varga <vargaz@gmail.com>
Tue, 12 Nov 2019 17:46:00 +0000 (12 18:46 +0100)
treee672fdc37be0cfb459e231279fc9b3a8381a38a6
parent4728cec01fc490b850607a161342ee0927d5c057
Mirror changes from mono/corefx,coreclr (#17777)

* Rewrite the rest of the array non-generic fast paths in C# (#27703)

* Rewrite the rest of the array non-generic fast paths in C#

* Add missing resource string

* Use CorElementType and handle native ints to match the unmanaged implementation

* Avoid try pattern for Sort and Reverse

* Match the native implementation more closely

Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
* Rewrite Enum.CompareTo in C# (dotnet/coreclr#27792)

* Rewrite Enum.CompareTo in C#

* Handle floating point too for match the existing native implementation

Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
* Remove unused argument from GetRegionDisplayName (dotnet/coreclr#27806)

* Remove unused argument from GetRegionDisplayName

* Address race conditions in CultureData

While most of the race conditions in this file are benign, in these cases, a thread could end up returning an intermediate value due to multiple potential writes to the same field.

Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
* Fix StyleCop rule SA1129 ("Do not use default value type constructor") (#27716)

Will enable the rule in corefx once these changes have propagated.

Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
* Remove non-shared Enum.CompareTo/InternalCompareTo implementation, add new Array icalls used by shared code
61 files changed:
mono/metadata/icall-def-netcore.h
mono/metadata/icall.c
netcore/System.Private.CoreLib/resources/SR.cs
netcore/System.Private.CoreLib/resources/Strings.resx
netcore/System.Private.CoreLib/shared/Internal/IO/File.Windows.cs
netcore/System.Private.CoreLib/shared/System/Array.cs
netcore/System.Private.CoreLib/shared/System/Buffer.cs
netcore/System.Private.CoreLib/shared/System/Collections/Concurrent/ConcurrentQueue.cs
netcore/System.Private.CoreLib/shared/System/Collections/Concurrent/ConcurrentQueueSegment.cs
netcore/System.Private.CoreLib/shared/System/Collections/Generic/Dictionary.cs
netcore/System.Private.CoreLib/shared/System/Collections/Hashtable.cs
netcore/System.Private.CoreLib/shared/System/Diagnostics/Tracing/EventSource.cs
netcore/System.Private.CoreLib/shared/System/Diagnostics/Tracing/TraceLogging/DataCollector.cs
netcore/System.Private.CoreLib/shared/System/Diagnostics/Tracing/TraceLogging/EventSourceActivity.cs
netcore/System.Private.CoreLib/shared/System/Diagnostics/Tracing/TraceLogging/TraceLoggingEventSource.cs
netcore/System.Private.CoreLib/shared/System/Enum.cs
netcore/System.Private.CoreLib/shared/System/Globalization/CalendarData.Unix.cs
netcore/System.Private.CoreLib/shared/System/Globalization/CalendarData.Windows.cs
netcore/System.Private.CoreLib/shared/System/Globalization/CompareInfo.Windows.cs
netcore/System.Private.CoreLib/shared/System/Globalization/CultureData.Unix.cs
netcore/System.Private.CoreLib/shared/System/Globalization/CultureData.Windows.cs
netcore/System.Private.CoreLib/shared/System/Globalization/CultureData.cs
netcore/System.Private.CoreLib/shared/System/Globalization/DateTimeParse.cs
netcore/System.Private.CoreLib/shared/System/Globalization/TimeSpanFormat.cs
netcore/System.Private.CoreLib/shared/System/Globalization/TimeSpanParse.cs
netcore/System.Private.CoreLib/shared/System/Guid.cs
netcore/System.Private.CoreLib/shared/System/IO/DisableMediaInsertionPrompt.cs
netcore/System.Private.CoreLib/shared/System/IO/PathHelper.Windows.cs
netcore/System.Private.CoreLib/shared/System/Lazy.cs
netcore/System.Private.CoreLib/shared/System/Numerics/Matrix4x4.cs
netcore/System.Private.CoreLib/shared/System/Numerics/Quaternion.cs
netcore/System.Private.CoreLib/shared/System/Numerics/Vector.cs
netcore/System.Private.CoreLib/shared/System/Numerics/Vector.tt
netcore/System.Private.CoreLib/shared/System/Numerics/Vector2.cs
netcore/System.Private.CoreLib/shared/System/Numerics/Vector3.cs
netcore/System.Private.CoreLib/shared/System/Numerics/Vector4.cs
netcore/System.Private.CoreLib/shared/System/Reflection/Emit/EventToken.cs
netcore/System.Private.CoreLib/shared/System/Reflection/Emit/FieldToken.cs
netcore/System.Private.CoreLib/shared/System/Reflection/Emit/MethodToken.cs
netcore/System.Private.CoreLib/shared/System/Reflection/Emit/ParameterToken.cs
netcore/System.Private.CoreLib/shared/System/Reflection/Emit/PropertyToken.cs
netcore/System.Private.CoreLib/shared/System/Reflection/Emit/SignatureToken.cs
netcore/System.Private.CoreLib/shared/System/Reflection/Emit/TypeToken.cs
netcore/System.Private.CoreLib/shared/System/Runtime/CompilerServices/RuntimeHelpers.cs
netcore/System.Private.CoreLib/shared/System/Runtime/CompilerServices/TaskAwaiter.cs
netcore/System.Private.CoreLib/shared/System/Runtime/CompilerServices/YieldAwaitable.cs
netcore/System.Private.CoreLib/shared/System/Runtime/MemoryFailPoint.Windows.cs
netcore/System.Private.CoreLib/shared/System/RuntimeType.cs
netcore/System.Private.CoreLib/shared/System/Threading/CancellationTokenSource.cs
netcore/System.Private.CoreLib/shared/System/Threading/ExecutionContext.cs
netcore/System.Private.CoreLib/shared/System/Threading/ManualResetEventSlim.cs
netcore/System.Private.CoreLib/shared/System/Threading/SemaphoreSlim.cs
netcore/System.Private.CoreLib/shared/System/Threading/SpinLock.cs
netcore/System.Private.CoreLib/shared/System/Threading/SpinWait.cs
netcore/System.Private.CoreLib/shared/System/Threading/Tasks/Task.cs
netcore/System.Private.CoreLib/shared/System/Threading/Tasks/TaskCanceledException.cs
netcore/System.Private.CoreLib/shared/System/Threading/Tasks/TaskCompletionSource.cs
netcore/System.Private.CoreLib/shared/System/ThrowHelper.cs
netcore/System.Private.CoreLib/shared/System/ValueTuple.cs
netcore/System.Private.CoreLib/src/System/Array.Mono.cs
netcore/System.Private.CoreLib/src/System/Enum.Mono.cs