platform/upstream/dotnet/runtime.git
3 years ago[class] Add GC Unsafe transitions to a few more external only functions (#55748)
Aleksey Kliger (λgeek) [Thu, 15 Jul 2021 20:44:40 +0000 (16:44 -0400)]
[class] Add GC Unsafe transitions to a few more external only functions (#55748)

3 years agoAdd option to MonoAOTCompiler msbuild task to generate .so files (#55753)
Alexander Köplinger [Thu, 15 Jul 2021 20:40:54 +0000 (22:40 +0200)]
Add option to MonoAOTCompiler msbuild task to generate .so files (#55753)

3 years agoXmlSerializer dont skip date time offset (#55101)
Steve Molloy [Thu, 15 Jul 2021 20:37:37 +0000 (13:37 -0700)]
XmlSerializer dont skip date time offset (#55101)

* Add DateTimeOffset as a primitive for XmlSerializer.

* Fix DefaultValueAttribute handling for DTO.

* Add tests for DateTimeAttribute and XmlSerializer.

* Missed a 'KnownType' spot.

* Update SGen tests to use current dotnet.exe from build.

* Unbreak runtimeconfig creation for testing.

* Debugging failure to resolve CoreCLR path.

* Test fixup.

* More test cleanup.

* Temporarily disable generator tests.

* Use InitObj instead of constructors for DateTimeOffset and TimeSpan.

3 years agoLocalized file check-in by OneLocBuild Task: Build definition ID 679: Build ID 124001...
dotnet bot [Thu, 15 Jul 2021 20:07:34 +0000 (13:07 -0700)]
Localized file check-in by OneLocBuild Task: Build definition ID 679: Build ID 1240010 (#55743)

* Localized file check-in by OneLocBuild Task

* Remove asserts against localized text from Logging generator tests

Co-authored-by: Eric StJohn <ericstj@microsoft.com>
3 years agoUse local assertion prop to omit casts on returns (#55632)
SingleAccretion [Thu, 15 Jul 2021 18:55:09 +0000 (21:55 +0300)]
Use local assertion prop to omit casts on returns (#55632)

When inserting normalizing casts for returns in pre-order
morph, "fgMorphCast" was used, which did not account for
the fact that local assertion propagation could tell us
that the cast is in fact unnecessary. Fix this by calling
"fgMorphTree" instead.

Also some miscellaneous code cleanup.

3 years agoRemove support for deprecated obs-fold in header values (#53505)
Miha Zupan [Thu, 15 Jul 2021 18:47:04 +0000 (11:47 -0700)]
Remove support for deprecated obs-fold in header values (#53505)

* Remove support for deprecated obs-fold in header values

* Add new-line validation to Well-Known header parsing

3 years agoDo abortive connection shutdown in MsQuicConnection.Dispose (#55493)
Geoff Kizer [Thu, 15 Jul 2021 18:42:40 +0000 (11:42 -0700)]
Do abortive connection shutdown in MsQuicConnection.Dispose (#55493)

* do abortive connection shutdown in MsQuicConnection.Dispose, add test for CloseAsync and Dispose, and remove CloseAsync from RunClientServer as it should not be necessary anymore

* CloseAsync is no-op if disposed

* more review feedback

Co-authored-by: Geoffrey Kizer <geoffrek@windows.microsoft.com>
3 years agoSupport more collections in STJ source generator (#55566)
Layomi Akinrinade [Thu, 15 Jul 2021 18:41:56 +0000 (11:41 -0700)]
Support more collections in STJ source generator (#55566)

* Support more collections in STJ source generator

* Fix tests

* Revert redundant MLC change and address feedback

3 years agoImprove `TryTransformStoreObjAsStoreInd` optimization. (#55727)
Sergey Andreenko [Thu, 15 Jul 2021 18:13:15 +0000 (11:13 -0700)]
Improve `TryTransformStoreObjAsStoreInd` optimization. (#55727)

* Fix `TryTransformStoreObjAsStoreInd` optimization.

* Disable the assert.

It was failing on DevDiv_280120 arm32 linux, did not repro with an altjit.

3 years agoIncrease max loops optimized by RyuJIT from 16 to 64. (#55614)
Bruce Forstall [Thu, 15 Jul 2021 17:52:36 +0000 (10:52 -0700)]
Increase max loops optimized by RyuJIT from 16 to 64. (#55614)

16 seems remarkably small. Note that this number is used to allocate the
statically-sized loop table, as well as for memory allocation for value
numbering, so there is some overhead to increasing it.

A few microbenchmarks that have diffs show benefit, including 9% for MulMatrix

| Method |        Job |                                                                         Toolchain |     Mean |   Error |  StdDev |   Median |      Min |      Max | Ratio |
|------- |----------- |---------------------------------------------------------------------------------- |---------:|--------:|--------:|---------:|---------:|---------:|------:|
| LLoops | Job-JXEMSM | \runtime2\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 559.9 ms | 8.20 ms | 7.67 ms | 556.4 ms | 550.6 ms | 576.0 ms |  1.00 |
| LLoops | Job-MUOLTV |  \runtime\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 552.3 ms | 5.84 ms | 5.46 ms | 552.0 ms | 542.4 ms | 561.1 ms |  0.99 |
| MulMatrix | Job-JXEMSM | \runtime2\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 369.7 ms | 4.01 ms | 3.56 ms | 369.9 ms | 364.6 ms | 376.9 ms |  1.00 |
| MulMatrix | Job-MUOLTV |  \runtime\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 338.1 ms | 2.69 ms | 2.51 ms | 337.7 ms | 332.2 ms | 341.9 ms |  0.91 |
| Puzzle | Job-JXEMSM | \runtime2\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 403.4 ms | 6.93 ms | 6.48 ms | 402.3 ms | 394.8 ms | 412.5 ms |  1.00 |
| Puzzle | Job-MUOLTV |  \runtime\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 394.9 ms | 4.16 ms | 3.68 ms | 395.5 ms | 388.2 ms | 401.8 ms |  0.98 |

spmi diffs:

```

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 6264
Total bytes of diff: 6285
Total bytes of delta: 21 (0.34% of base)
Total relative delta: 0.00
    diff is a regression.
    relative diff is a regression.
```
<details>

<summary>Detail diffs</summary>

```

Top file regressions (bytes):
          21 : 42451.dasm (0.34% of base)

1 total files with Code Size differences (0 improved, 1 regressed), 0 unchanged.

Top method regressions (bytes):
          21 ( 0.34% of base) : 42451.dasm - RelationalModel:Create(IModel,IRelationalAnnotationProvider):IRelationalModel

Top method regressions (percentages):
          21 ( 0.34% of base) : 42451.dasm - RelationalModel:Create(IModel,IRelationalAnnotationProvider):IRelationalModel

1 total methods with Code Size differences (0 improved, 1 regressed), 0 unchanged.

```

</details>

--------------------------------------------------------------------------------

```

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 39243
Total bytes of diff: 39940
Total bytes of delta: 697 (1.78% of base)
Total relative delta: 0.16
    diff is a regression.
    relative diff is a regression.
```
<details>

<summary>Detail diffs</summary>

```

Top file regressions (bytes):
         536 : 25723.dasm (18.29% of base)
         185 : 26877.dasm (2.21% of base)
          66 : 16212.dasm (1.39% of base)
          16 : 16196.dasm (0.36% of base)
          13 : 13322.dasm (0.27% of base)
           9 : 15596.dasm (0.16% of base)

Top file improvements (bytes):
        -125 : 27270.dasm (-6.93% of base)
          -3 : 13993.dasm (-0.05% of base)

8 total files with Code Size differences (2 improved, 6 regressed), 0 unchanged.

Top method regressions (bytes):
         536 (18.29% of base) : 25723.dasm - Benchstone.BenchI.MulMatrix:Inner(System.Int32[][],System.Int32[][],System.Int32[][])
         185 ( 2.21% of base) : 26877.dasm - Benchstone.BenchF.LLoops:Main1(int):this
          66 ( 1.39% of base) : 16212.dasm - Jil.Deserialize.Methods:SkipWithLeadChar(System.IO.TextReader,int)
          16 ( 0.36% of base) : 16196.dasm - DynamicClass:_DynamicMethod9(System.IO.TextReader,int):MicroBenchmarks.Serializers.MyEventsListerViewModel
          13 ( 0.27% of base) : 13322.dasm - DynamicClass:Regex1_Go(System.Text.RegularExpressions.RegexRunner)
           9 ( 0.16% of base) : 15596.dasm - DynamicClass:_DynamicMethod9(byref,int):MicroBenchmarks.Serializers.MyEventsListerViewModel

Top method improvements (bytes):
        -125 (-6.93% of base) : 27270.dasm - Benchstone.BenchI.Puzzle:DoIt():bool:this
          -3 (-0.05% of base) : 13993.dasm - Jil.Deserialize.Methods:SkipWithLeadCharThunkReader(byref,int)

Top method regressions (percentages):
         536 (18.29% of base) : 25723.dasm - Benchstone.BenchI.MulMatrix:Inner(System.Int32[][],System.Int32[][],System.Int32[][])
         185 ( 2.21% of base) : 26877.dasm - Benchstone.BenchF.LLoops:Main1(int):this
          66 ( 1.39% of base) : 16212.dasm - Jil.Deserialize.Methods:SkipWithLeadChar(System.IO.TextReader,int)
          16 ( 0.36% of base) : 16196.dasm - DynamicClass:_DynamicMethod9(System.IO.TextReader,int):MicroBenchmarks.Serializers.MyEventsListerViewModel
          13 ( 0.27% of base) : 13322.dasm - DynamicClass:Regex1_Go(System.Text.RegularExpressions.RegexRunner)
           9 ( 0.16% of base) : 15596.dasm - DynamicClass:_DynamicMethod9(byref,int):MicroBenchmarks.Serializers.MyEventsListerViewModel

Top method improvements (percentages):
        -125 (-6.93% of base) : 27270.dasm - Benchstone.BenchI.Puzzle:DoIt():bool:this
          -3 (-0.05% of base) : 13993.dasm - Jil.Deserialize.Methods:SkipWithLeadCharThunkReader(byref,int)

8 total methods with Code Size differences (2 improved, 6 regressed), 0 unchanged.

```

</details>

--------------------------------------------------------------------------------

```

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 142908
Total bytes of diff: 143387
Total bytes of delta: 479 (0.34% of base)
Total relative delta: 0.42
    diff is a regression.
    relative diff is a regression.
```
<details>

<summary>Detail diffs</summary>

```

Top file regressions (bytes):
         536 : 248723.dasm (18.29% of base)
         390 : 220441.dasm (14.45% of base)
         390 : 220391.dasm (14.61% of base)
         150 : 239253.dasm (1.78% of base)
          71 : 234803.dasm (1.72% of base)
          16 : 225588.dasm (1.00% of base)
          16 : 225590.dasm (1.00% of base)
           5 : 225285.dasm (0.26% of base)

Top file improvements (bytes):
        -359 : 215690.dasm (-0.99% of base)
        -320 : 215701.dasm (-1.16% of base)
        -128 : 215723.dasm (-0.73% of base)
        -128 : 215666.dasm (-0.62% of base)
        -125 : 239280.dasm (-6.93% of base)
         -29 : 216754.dasm (-0.33% of base)
          -3 : 225316.dasm (-0.15% of base)
          -3 : 225313.dasm (-0.15% of base)

16 total files with Code Size differences (8 improved, 8 regressed), 0 unchanged.

Top method regressions (bytes):
         536 (18.29% of base) : 248723.dasm - Benchstone.BenchI.MulMatrix:Inner(System.Int32[][],System.Int32[][],System.Int32[][])
         390 (14.45% of base) : 220441.dasm - VectorTest:Main():int
         390 (14.61% of base) : 220391.dasm - VectorTest:Main():int
         150 ( 1.78% of base) : 239253.dasm - Benchstone.BenchF.LLoops:Main1(int):this
          71 ( 1.72% of base) : 234803.dasm - SmallLoop1:Main():int
          16 ( 1.00% of base) : 225588.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
          16 ( 1.00% of base) : 225590.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
           5 ( 0.26% of base) : 225285.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int

Top method improvements (bytes):
        -359 (-0.99% of base) : 215690.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
        -320 (-1.16% of base) : 215701.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
        -128 (-0.73% of base) : 215723.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
        -128 (-0.62% of base) : 215666.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
        -125 (-6.93% of base) : 239280.dasm - Benchstone.BenchI.Puzzle:DoIt():bool:this
         -29 (-0.33% of base) : 216754.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
          -3 (-0.15% of base) : 225316.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
          -3 (-0.15% of base) : 225313.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int

Top method regressions (percentages):
         536 (18.29% of base) : 248723.dasm - Benchstone.BenchI.MulMatrix:Inner(System.Int32[][],System.Int32[][],System.Int32[][])
         390 (14.61% of base) : 220391.dasm - VectorTest:Main():int
         390 (14.45% of base) : 220441.dasm - VectorTest:Main():int
         150 ( 1.78% of base) : 239253.dasm - Benchstone.BenchF.LLoops:Main1(int):this
          71 ( 1.72% of base) : 234803.dasm - SmallLoop1:Main():int
          16 ( 1.00% of base) : 225588.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
          16 ( 1.00% of base) : 225590.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
           5 ( 0.26% of base) : 225285.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int

Top method improvements (percentages):
        -125 (-6.93% of base) : 239280.dasm - Benchstone.BenchI.Puzzle:DoIt():bool:this
        -320 (-1.16% of base) : 215701.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
        -359 (-0.99% of base) : 215690.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
        -128 (-0.73% of base) : 215723.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
        -128 (-0.62% of base) : 215666.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
         -29 (-0.33% of base) : 216754.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
          -3 (-0.15% of base) : 225316.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int
          -3 (-0.15% of base) : 225313.dasm - IntelHardwareIntrinsicTest.Program:Main(System.String[]):int

16 total methods with Code Size differences (8 improved, 8 regressed), 0 unchanged.

```

</details>

--------------------------------------------------------------------------------

```

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 15351
Total bytes of diff: 15448
Total bytes of delta: 97 (0.63% of base)
Total relative delta: 0.08
    diff is a regression.
    relative diff is a regression.
```
<details>

<summary>Detail diffs</summary>

```

Top file regressions (bytes):
          71 : 63973.dasm (7.63% of base)
          26 : 106039.dasm (0.19% of base)

2 total files with Code Size differences (0 improved, 2 regressed), 1 unchanged.

Top method regressions (bytes):
          71 ( 7.63% of base) : 63973.dasm - Microsoft.Diagnostics.Tracing.Parsers.Symbol.FileVersionTraceData:ToXml(System.Text.StringBuilder):System.Text.StringBuilder:this
          26 ( 0.19% of base) : 106039.dasm - Microsoft.VisualBasic.CompilerServices.VBBinder:BindToMethod(int,System.Reflection.MethodBase[],byref,System.Reflection.ParameterModifier[],System.Globalization.CultureInfo,System.String[],byref):System.Reflection.MethodBase:this

Top method regressions (percentages):
          71 ( 7.63% of base) : 63973.dasm - Microsoft.Diagnostics.Tracing.Parsers.Symbol.FileVersionTraceData:ToXml(System.Text.StringBuilder):System.Text.StringBuilder:this
          26 ( 0.19% of base) : 106039.dasm - Microsoft.VisualBasic.CompilerServices.VBBinder:BindToMethod(int,System.Reflection.MethodBase[],byref,System.Reflection.ParameterModifier[],System.Globalization.CultureInfo,System.String[],byref):System.Reflection.MethodBase:this

2 total methods with Code Size differences (0 improved, 2 regressed), 1 unchanged.

```

</details>

--------------------------------------------------------------------------------

```

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 22540
Total bytes of diff: 22576
Total bytes of delta: 36 (0.16% of base)
Total relative delta: 0.01
    diff is a regression.
    relative diff is a regression.
```
<details>

<summary>Detail diffs</summary>

```

Top file regressions (bytes):
          23 : 104600.dasm (0.15% of base)
          14 : 43143.dasm (0.47% of base)

Top file improvements (bytes):
          -1 : 35267.dasm (-0.03% of base)

3 total files with Code Size differences (1 improved, 2 regressed), 0 unchanged.

Top method regressions (bytes):
          23 ( 0.15% of base) : 104600.dasm - Microsoft.VisualBasic.CompilerServices.VBBinder:BindToMethod(int,System.Reflection.MethodBase[],byref,System.Reflection.ParameterModifier[],System.Globalization.CultureInfo,System.String[],byref):System.Reflection.MethodBase:this
          14 ( 0.47% of base) : 43143.dasm - Microsoft.CodeAnalysis.CSharp.Symbols.SourceMemberContainerTypeSymbol:ForceComplete(Microsoft.CodeAnalysis.SourceLocation,System.Threading.CancellationToken):this

Top method improvements (bytes):
          -1 (-0.03% of base) : 35267.dasm - Microsoft.CodeAnalysis.CSharp.Syntax.InternalSyntax.LanguageParser:ParseNamespaceBody(byref,byref,byref,ushort):this

Top method regressions (percentages):
          14 ( 0.47% of base) : 43143.dasm - Microsoft.CodeAnalysis.CSharp.Symbols.SourceMemberContainerTypeSymbol:ForceComplete(Microsoft.CodeAnalysis.SourceLocation,System.Threading.CancellationToken):this
          23 ( 0.15% of base) : 104600.dasm - Microsoft.VisualBasic.CompilerServices.VBBinder:BindToMethod(int,System.Reflection.MethodBase[],byref,System.Reflection.ParameterModifier[],System.Globalization.CultureInfo,System.String[],byref):System.Reflection.MethodBase:this

Top method improvements (percentages):
          -1 (-0.03% of base) : 35267.dasm - Microsoft.CodeAnalysis.CSharp.Syntax.InternalSyntax.LanguageParser:ParseNamespaceBody(byref,byref,byref,ushort):this

3 total methods with Code Size differences (1 improved, 2 regressed), 0 unchanged.

```

</details>

--------------------------------------------------------------------------------

```

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 53782
Total bytes of diff: 53837
Total bytes of delta: 55 (0.10% of base)
Total relative delta: 0.00
    diff is a regression.
    relative diff is a regression.
```
<details>

<summary>Detail diffs</summary>

```

Top file regressions (bytes):
          28 : 28889.dasm (0.16% of base)
          27 : 28887.dasm (0.15% of base)

2 total files with Code Size differences (0 improved, 2 regressed), 2 unchanged.

Top method regressions (bytes):
          28 ( 0.16% of base) : 28889.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.freach.freach003.freach003.Test:MainMethod():int
          27 ( 0.15% of base) : 28887.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.freach.freach004.freach004.Test:MainMethod():int

Top method regressions (percentages):
          28 ( 0.16% of base) : 28889.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.freach.freach003.freach003.Test:MainMethod():int
          27 ( 0.15% of base) : 28887.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.freach.freach004.freach004.Test:MainMethod():int

2 total methods with Code Size differences (0 improved, 2 regressed), 2 unchanged.

```

</details>

--------------------------------------------------------------------------------

3 years agoFix crash with unmapped shuffle thunk stub (#55718)
Jan Vorlicek [Thu, 15 Jul 2021 17:45:43 +0000 (19:45 +0200)]
Fix crash with unmapped shuffle thunk stub (#55718)

This change fixes an intermittent issue that was showing up in
the System.Linq.Expressions.Tests suite. When the delegate class
was in a collectible ALC, some of the stubs were being used even
after the underlying loader allocator was deleted, thus the memory
the stubs occupied was already unmapped.

Before my recent W^X change, the stubs were always being allocated
from an executable allocator / executable heap in the global loader
allocator due to a bug in the AssemblyLoaderAllocator::SetCollectible
and AssemblyLoaderAllocator::Init ordering (the SetCollectible
was being called before the Init, so the m_pStubHeap was not yet
set and the ShuffleThunkCache was being passed NULL as the heap
pointer. The cache handles that case as a request to allocate from
global executable heap.

In this fix, I've changed the AssemblyLoaderAllocator::Init to pass
the SystemDomain::GetGlobalLoaderAllocator()->GetExecutableHeap()
as the heap to the ShuffleThunkCache constructor. It is a workaround
until the actual issue with stubs outliving the delegate classes
is understood and fixed.

Besides the fix, this change also fixes two unrelated issues that
would only possibly cause trouble when the W^X is enabled. There
were two places where memory was being reserved by the new
ExecutableAllocator, but cleaned up using the ClrVirtualFree.

3 years agoinFlight ref-counting of strong GCHandle for JSObject, while in flight over the manag...
Pavel Savara [Thu, 15 Jul 2021 17:23:27 +0000 (19:23 +0200)]
inFlight ref-counting of strong GCHandle for JSObject, while in flight over the managed/JS boundary (#54453)

3 years agoRelax LinkTarget so it always returns null when steps on an error (#55668)
David Cantú [Thu, 15 Jul 2021 16:52:42 +0000 (09:52 -0700)]
Relax LinkTarget so it always returns null when steps on an error (#55668)

3 years agoUse alternatives to redirecting threads via IP changes in the context, for a few...
Koundinya Veluri [Thu, 15 Jul 2021 16:34:36 +0000 (09:34 -0700)]
Use alternatives to redirecting threads via IP changes in the context, for a few cases on Windows (#55649)

* Use alternatives to redirecting threads via IP changes in the context, for a few cases on Windows

- For GC/debugger suspension, a new variant of an APC is used to interrupt the thread
- For hardware exceptions, an exception is raised from the vectored exception handler instead of redirecting and then raising an exception
- Made changes to enable /guard:ehcont and /cetcompat for binaries, but commented out the enablement for now since it looks like we will first need .pgd files generated with /guard:ehcont and published for release builds to succeed

3 years agomore fixes for msquic packaging (#55607)
Tomas Weinfurt [Thu, 15 Jul 2021 15:14:43 +0000 (08:14 -0700)]
more fixes for msquic packaging (#55607)

* more fixes for msquic packaging

* feedback from review

3 years agoJIT: enable GDV when static class deduction fails. (#55660)
Andy Ayers [Thu, 15 Jul 2021 14:51:44 +0000 (07:51 -0700)]
JIT: enable GDV when static class deduction fails. (#55660)

Update the early bailout in impDevirtualizeCall that gives up if
the object class cannot not be determined to check if we can do
GDV (guarded devirtualization) based on profile data.

Fixes one of the cases noted in #55079.

3 years ago[mono] Disable unsupported apply update scenarios (#55698)
Aleksey Kliger (λgeek) [Thu, 15 Jul 2021 14:46:47 +0000 (10:46 -0400)]
[mono] Disable unsupported apply update scenarios (#55698)

* Disallow mixing ApplyChanges and debugger apply changes

* Don't allow debugger thread to start if ApplyChanges has been called

* Don't allow ApplyChanges managed API call if debugger is attached

* MONO_COMPONENT_API mono_error_set_not_supported

3 years agoAdd json support for F# options, lists, sets, maps and records (#55108)
Eirik Tsarpalis [Thu, 15 Jul 2021 14:40:30 +0000 (17:40 +0300)]
Add json support for F# options, lists, sets, maps and records (#55108)

* Add json support for F# options, lists, sets, maps and records

* fix ILLink warnings

* address ILLink annotations feedback

* add support for ValueOption

* revert unneeded sln changes

* add JsonIgnoreCondition tests for optional types

* Revert "revert unneeded sln changes"

This reverts commit 2e793422dca84bd22d55cdfa2cd6c9b6c5d4963e.

* remove lock from singleton initialization

* improve FSharp.Core missing member error mesages

* throw NotSupportedException on discriminated unions

* extend optional test coverage to include list, set and map payloads

* simplify changes required to converter infrastructure

3 years ago[android][debugger] Implement support to debug after hot reload. (#55722)
Thays Grazia [Thu, 15 Jul 2021 14:33:23 +0000 (07:33 -0700)]
[android][debugger] Implement support to debug after hot reload. (#55722)

* Implement support to debug after hot reload.

* Remove unused variable.

3 years agoPrevent ActivityId leak across threads (#55625)
Noah Falk [Thu, 15 Jul 2021 12:59:38 +0000 (05:59 -0700)]
Prevent ActivityId leak across threads (#55625)

Prevent ActivityId leak across threads

Fixes #51608

Previously running an async task with two or more levels of nesting on the EventSource activity stack would leave the ActivityID set on the old thread after being swapped out at a yield point. This meant that threadpool threads would often have stale ActivityIDs present when they began a new work item. This in turn produced non-sensical logs where it appeared that unrelated work items were nested within each other.

Most of this change is adding tests. The ActivityIdIsZeroedOnThreadSwitchOut test is the one being fixed. The remainder of the new tests pass both before and after the change. I added those to better describe some of the existing behavior and add a little confidence that the change didn't have unintended effects elsewhere. As best I can tell the Activity tracking feature didn't have any testing previously and there is certainly still room for improvement on test coverage.

3 years agoEnable StructEnreg by default on all platforms. (#55558)
Sergey Andreenko [Thu, 15 Jul 2021 09:01:47 +0000 (02:01 -0700)]
Enable StructEnreg by default on all platforms. (#55558)

* enable for arm32.

fix arm32

Fix arm/arm64.

now we can have contained lclRead for other platforms, not only xarch.

* enable x64 unix.

* Fix and enable arm64.

* fix bad merge and arm32 failures.

3 years agoAvoid nullref while trying to throw a more helpful exception. (#55316)
Steve Molloy [Thu, 15 Jul 2021 06:59:35 +0000 (23:59 -0700)]
Avoid nullref while trying to throw a more helpful exception. (#55316)

3 years agoRemove default value from param in ResolveLinkTarget(bool returnFinalTarget) missed...
David Cantú [Thu, 15 Jul 2021 06:07:12 +0000 (23:07 -0700)]
Remove default value from param in ResolveLinkTarget(bool returnFinalTarget) missed in the main PR (#55670)

3 years agoSupport Invariant Mode Case Mapping (#55520)
Tarek Mahmoud Sayed [Thu, 15 Jul 2021 06:05:03 +0000 (23:05 -0700)]
Support Invariant Mode Case Mapping (#55520)

* Support InvariantMode Case Mapping

3 years agoRevert "Handle getting the address of an RVA static correctly in a composite image...
David Wrighton [Thu, 15 Jul 2021 04:57:22 +0000 (21:57 -0700)]
Revert "Handle getting the address of an RVA static correctly in a composite image (#55301)" (#55713)

This reverts commit e3d319bb727efb82f1ab4236f6f58a5dfffcfc5c.
It breaks the crossgen2 outerloop runs

3 years agoSupport sigaction with SIG_DFL and SA_SIGINFO. (#55673)
Tom Deseyn [Thu, 15 Jul 2021 04:41:01 +0000 (06:41 +0200)]
Support sigaction with SIG_DFL and SA_SIGINFO. (#55673)

Fixes #55645

3 years agoInclude native underlying handler support in HttpClientHandler for iOS/tvOS/MacCataly...
Steve Pfister [Thu, 15 Jul 2021 04:36:02 +0000 (00:36 -0400)]
Include native underlying handler support in HttpClientHandler for iOS/tvOS/MacCatalyst and Android (#55384)

Completes the plan for net6 laid out in https://github.com/dotnet/designs/blob/main/accepted/2020/mono-convergence/platform-specific-httpclient.md#the-plan-for-net-5

This change supports using either the native HttpMessageHandler types that exist in the Xamarin repos (NSUrlSessionHandler for iOS/tvOS/Catalyst and AndroidMessageHandler for Android) or SocketsHttpHandler as the underlying handler in HttpClientHandler.

The behavior for new HttpClient() was established earlier in net6, but did not go all the way. For example, if the System.Net.Http.UseNativeHttpHandler feature switch was set to true, using HttpClient in different ways would lead to different underlying handlers.

Before this PR:

// System.Net.Http.UseNativeHttpHandler == true

new HttpClient();    // Chooses the native handler as the underlying handler

var handler = new HttpClientHandler();       // SocketsHttpHandler is the only choice
new HttpClient(handler);

The change creates a handful of partial HttpClientHandler files in order to split out the platform specific parts. As you review the PR, you'll notice a bunch of if (IsSocketHandler) blocks. The intent of these are to make use of the linker and get linked out once the linker knows which handler is the active one.

get
{
    if (IsSocketHandler)
    {
        return _socketHandler!.UseCookies;
    }
    else
    {
        return GetUseCookies();
    }
}

Get and Set methods like GetUseCookies make it easier to tell the linker via DynamicDependency to preserve the reflection calls being made to the native underlying handler.

[DynamicDependency("get_UseCookies", "Xamarin.Android.Net.AndroidMessageHandler", "Mono.Android")]
private bool GetUseCookies() => (bool)InvokeNativeHandlerMethod("get_UseCookies");

It is important to point out that the underlying handler has to be derived from HttpMessageHandler. It cannot be HttpClientHandler or you'll end up with a circular dependency.

3 years agoSupport cloning loops with array of struct indexing expressions (#55612)
Bruce Forstall [Thu, 15 Jul 2021 03:35:45 +0000 (20:35 -0700)]
Support cloning loops with array of struct indexing expressions (#55612)

* Support cloning loops with array of struct indexing expressions

Loop cloning, in `optExtractArrIndex()`, was matching the post-morph
trees representing array index expressions. This was not necessary,
as all the information we actually need is in the array bound check node,
namely the array base and the array index. The code was verifying that the
bounds check information matched the morph expression, but we don't really
need to do that anyway, as the main thing we care about it whether or not
we can remove the bounds check.

The full array index expression morphed tree can be complex, especially
for arrays of structs. Simply deleting this parsing code enables cloning to
kick in for arrays of structs.

There was one bug needing fixing, though: after removing the array bounds
check, the GTF_EXCEPT bits are recalculated over the entire Statement tree.
It was doing this top-down, but needs to do it bottom-up to handle the array
of structs case where we have `IND(COMMA(..., ADDR()))`, to propagate the bit
through the COMMA.

Fixes #48897

There are a few microbenchmark wins ("runtime2" is baseline, "runtime" is diff):
```
|    Method |        Job |                                                                         Toolchain |     Mean |   Error |  StdDev |   Median |      Min |      Max | Ratio |
|---------- |----------- |---------------------------------------------------------------------------------- |---------:|--------:|--------:|---------:|---------:|---------:|------:|
| MulMatrix | Job-LARQLS | \runtime2\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 370.8 ms | 1.32 ms | 1.17 ms | 370.5 ms | 369.3 ms | 373.1 ms |  1.00 |
| MulMatrix | Job-GYTYVK |  \runtime\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 351.6 ms | 1.92 ms | 1.60 ms | 351.6 ms | 349.2 ms | 355.2 ms |  0.95 |
|                   |            |                                                                                   |            |          |          |            |            |            |       |         |
| SpectralNorm_1 | Job-LARQLS | \runtime2\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 865.0 us | 16.71 us | 18.57 us | 858.8 us | 843.3 us | 896.0 us |  1.00 |
| SpectralNorm_1 | Job-GYTYVK |  \runtime\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 844.6 us |  9.47 us |  8.40 us | 841.5 us | 836.3 us | 860.6 us |  0.97 |
|                   |            |                                                                                   |            |          |          |            |            |            |       |         |
|      BenchEmFloat | Job-LARQLS | \runtime2\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 3,183.1 ms | 14.45 ms | 13.52 ms | 3,188.8 ms | 3,157.0 ms | 3,205.5 ms |  1.00 |    0.00 |
|      BenchEmFloat | Job-GYTYVK |  \runtime\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 3,115.8 ms | 13.19 ms | 12.34 ms | 3,109.3 ms | 3,105.3 ms | 3,147.1 ms |  0.98 |    0.00 |
|                   |            |                                                                                   |            |          |          |            |            |            |       |         |
| BenchAssignJagged | Job-LARQLS | \runtime2\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe |   938.1 ms |  5.26 ms |  4.66 ms |   937.8 ms |   932.3 ms |   946.4 ms |  1.00 |    0.00 |
| BenchAssignJagged | Job-GYTYVK |  \runtime\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe |   954.0 ms | 12.19 ms | 10.18 ms |   951.8 ms |   943.6 ms |   978.7 ms |  1.02 |    0.01 |
|                   |            |                                                                                   |            |          |          |            |            |            |       |         |
|     BenchLUDecomp | Job-LARQLS | \runtime2\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 1,094.6 ms | 14.91 ms | 13.95 ms | 1,095.0 ms | 1,072.5 ms | 1,117.7 ms |  1.00 |    0.00 |
|     BenchLUDecomp | Job-GYTYVK |  \runtime\artifacts\tests\coreclr\windows.x64.Checked\Tests\Core_Root\CoreRun.exe | 1,133.9 ms | 16.55 ms | 15.48 ms | 1,139.1 ms | 1,107.9 ms | 1,154.0 ms |  1.04 |    0.02 |
```

spmi diffs:

```

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 10605
Total bytes of diff: 13993
Total bytes of delta: 3388 (31.95% of base)
Total relative delta: 13.43
    diff is a regression.
    relative diff is a regression.
```
<details>

<summary>Detail diffs</summary>

```

Top file regressions (bytes):
         190 : 41209.dasm (89.62% of base)
         190 : 19281.dasm (89.62% of base)
         163 : 41303.dasm (67.08% of base)
         163 : 19393.dasm (67.08% of base)
         126 : 38635.dasm (50.00% of base)
         126 : 17973.dasm (50.00% of base)
         125 : 35718.dasm (29.07% of base)
         125 : 18582.dasm (29.07% of base)
         125 : 39316.dasm (29.07% of base)
         124 : 12493.dasm (47.51% of base)
         124 : 15994.dasm (47.51% of base)
         124 : 31342.dasm (49.80% of base)
         124 : 36770.dasm (48.44% of base)
         124 : 30776.dasm (48.44% of base)
         106 : 32284.dasm (39.85% of base)
         106 : 19181.dasm (39.85% of base)
         105 : 41328.dasm (53.85% of base)
         105 : 19427.dasm (53.85% of base)
          94 : 19275.dasm (19.34% of base)
          94 : 41203.dasm (19.34% of base)

Top file improvements (bytes):
         -32 : 22627.dasm (-12.55% of base)
         -32 : 35972.dasm (-12.55% of base)
         -32 : 30648.dasm (-12.55% of base)

36 total files with Code Size differences (3 improved, 33 regressed), 1 unchanged.

Top method regressions (bytes):
         190 (89.62% of base) : 41209.dasm - Dictionary`2:CopyEntries(ref,int):this
         190 (89.62% of base) : 19281.dasm - Dictionary`2:CopyEntries(ref,int):this
         163 (67.08% of base) : 41303.dasm - Dictionary`2:CopyTo(ref,int):this
         163 (67.08% of base) : 19393.dasm - Dictionary`2:CopyTo(ref,int):this
         126 (50.00% of base) : 38635.dasm - Dictionary`2:Resize(int,bool):this
         126 (50.00% of base) : 17973.dasm - Dictionary`2:Resize(int,bool):this
         125 (29.07% of base) : 35718.dasm - Dictionary`2:Resize(int,bool):this
         125 (29.07% of base) : 18582.dasm - Dictionary`2:Resize(int,bool):this
         125 (29.07% of base) : 39316.dasm - Dictionary`2:Resize(int,bool):this
         124 (47.51% of base) : 12493.dasm - Dictionary`2:Resize(int,bool):this
         124 (47.51% of base) : 15994.dasm - Dictionary`2:Resize(int,bool):this
         124 (49.80% of base) : 31342.dasm - Dictionary`2:Resize(int,bool):this
         124 (48.44% of base) : 36770.dasm - Dictionary`2:Resize(int,bool):this
         124 (48.44% of base) : 30776.dasm - Dictionary`2:Resize(int,bool):this
         106 (39.85% of base) : 32284.dasm - EnumerableSorter`2:ComputeKeys(ref,int):this
         106 (39.85% of base) : 19181.dasm - EnumerableSorter`2:ComputeKeys(ref,int):this
         105 (53.85% of base) : 41328.dasm - EnumerableSorter`2:ComputeKeys(ref,int):this
         105 (53.85% of base) : 19427.dasm - EnumerableSorter`2:ComputeKeys(ref,int):this
          94 (19.34% of base) : 19275.dasm - Dictionary`2:AddRange(IEnumerable`1):this
          94 (19.34% of base) : 41203.dasm - Dictionary`2:AddRange(IEnumerable`1):this

Top method improvements (bytes):
         -32 (-12.55% of base) : 22627.dasm - ObjectEqualityComparer`1:IndexOf(ref,__Canon,int,int):int:this
         -32 (-12.55% of base) : 35972.dasm - ObjectEqualityComparer`1:IndexOf(ref,__Canon,int,int):int:this
         -32 (-12.55% of base) : 30648.dasm - ObjectEqualityComparer`1:IndexOf(ref,__Canon,int,int):int:this

Top method regressions (percentages):
         190 (89.62% of base) : 41209.dasm - Dictionary`2:CopyEntries(ref,int):this
         190 (89.62% of base) : 19281.dasm - Dictionary`2:CopyEntries(ref,int):this
         163 (67.08% of base) : 41303.dasm - Dictionary`2:CopyTo(ref,int):this
         163 (67.08% of base) : 19393.dasm - Dictionary`2:CopyTo(ref,int):this
         105 (53.85% of base) : 41328.dasm - EnumerableSorter`2:ComputeKeys(ref,int):this
         105 (53.85% of base) : 19427.dasm - EnumerableSorter`2:ComputeKeys(ref,int):this
          78 (51.66% of base) : 37496.dasm - RouteValueDictionary:TryFindItem(String,byref):bool:this
         126 (50.00% of base) : 38635.dasm - Dictionary`2:Resize(int,bool):this
         126 (50.00% of base) : 17973.dasm - Dictionary`2:Resize(int,bool):this
         124 (49.80% of base) : 31342.dasm - Dictionary`2:Resize(int,bool):this
         124 (48.44% of base) : 36770.dasm - Dictionary`2:Resize(int,bool):this
         124 (48.44% of base) : 30776.dasm - Dictionary`2:Resize(int,bool):this
          88 (47.57% of base) : 37495.dasm - RouteValueDictionary:TryGetValue(String,byref):bool:this
          88 (47.57% of base) : 22930.dasm - RouteValueDictionary:TryGetValue(String,byref):bool:this
         124 (47.51% of base) : 12493.dasm - Dictionary`2:Resize(int,bool):this
         124 (47.51% of base) : 15994.dasm - Dictionary`2:Resize(int,bool):this
          76 (44.97% of base) : 18170.dasm - ValueCollection:CopyTo(ref,int):this
          76 (44.97% of base) : 38751.dasm - ValueCollection:CopyTo(ref,int):this
          76 (44.19% of base) : 30837.dasm - ValueCollection:CopyTo(ref,int):this
          76 (44.19% of base) : 36738.dasm - ValueCollection:CopyTo(ref,int):this

Top method improvements (percentages):
         -32 (-12.55% of base) : 22627.dasm - ObjectEqualityComparer`1:IndexOf(ref,__Canon,int,int):int:this
         -32 (-12.55% of base) : 35972.dasm - ObjectEqualityComparer`1:IndexOf(ref,__Canon,int,int):int:this
         -32 (-12.55% of base) : 30648.dasm - ObjectEqualityComparer`1:IndexOf(ref,__Canon,int,int):int:this

36 total methods with Code Size differences (3 improved, 33 regressed), 1 unchanged.

```

</details>

--------------------------------------------------------------------------------

```

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 19656
Total bytes of diff: 21755
Total bytes of delta: 2099 (10.68% of base)
Total relative delta: 6.71
    diff is a regression.
    relative diff is a regression.
```
<details>

<summary>Detail diffs</summary>

```

Top file regressions (bytes):
         314 : 10636.dasm (65.42% of base)
         281 : 25723.dasm (9.59% of base)
         276 : 10626.dasm (85.98% of base)
         191 : 17802.dasm (46.81% of base)
         113 : 9414.dasm (49.78% of base)
          98 : 11859.dasm (19.72% of base)
          98 : 11860.dasm (19.72% of base)
          89 : 7680.dasm (51.45% of base)
          84 : 7683.dasm (48.00% of base)
          84 : 15110.dasm (8.06% of base)
          80 : 7673.dasm (13.01% of base)
          80 : 3345.dasm (47.62% of base)
          77 : 9246.dasm (82.80% of base)
          76 : 2291.dasm (44.19% of base)
          62 : 14611.dasm (13.45% of base)
          62 : 14612.dasm (13.36% of base)
          57 : 25481.dasm (36.54% of base)
          45 : 20229.dasm (22.39% of base)
          28 : 24281.dasm (31.11% of base)
          28 : 12802.dasm (1.63% of base)

Top file improvements (bytes):
         -48 : 1274.dasm (-14.20% of base)
         -36 : 2717.dasm (-10.17% of base)
         -14 : 14028.dasm (-2.84% of base)
         -13 : 24210.dasm (-3.06% of base)
         -11 : 20189.dasm (-6.25% of base)
         -10 : 24211.dasm (-2.35% of base)
          -8 : 21902.dasm (-7.69% of base)
          -6 : 17322.dasm (-4.44% of base)
          -5 : 8348.dasm (-1.40% of base)
          -4 : 15533.dasm (-0.35% of base)
          -3 : 13358.dasm (-4.76% of base)
          -3 : 15111.dasm (-0.43% of base)
          -2 : 15133.dasm (-0.35% of base)
          -2 : 19751.dasm (-0.36% of base)
          -2 : 15621.dasm (-0.35% of base)

39 total files with Code Size differences (15 improved, 24 regressed), 2 unchanged.

Top method regressions (bytes):
         314 (65.42% of base) : 10636.dasm - EMFloat:DoEmFloatIteration(EMFloat+InternalFPF[],EMFloat+InternalFPF[],EMFloat+InternalFPF[],int,int):long
         281 ( 9.59% of base) : 25723.dasm - Benchstone.BenchI.MulMatrix:Inner(System.Int32[][],System.Int32[][],System.Int32[][])
         276 (85.98% of base) : 10626.dasm - EMFloat:SetupCPUEmFloatArrays(EMFloat+InternalFPF[],EMFloat+InternalFPF[],EMFloat+InternalFPF[],int)
         191 (46.81% of base) : 17802.dasm - Microsoft.CodeAnalysis.MetadataDecoder`5[__Canon,__Canon,__Canon,__Canon,__Canon][System.__Canon,System.__Canon,System.__Canon,System.__Canon,System.__Canon]:DoPropertySignaturesMatch(Microsoft.CodeAnalysis.ParamInfo`1[System.__Canon][],Microsoft.CodeAnalysis.ParamInfo`1[System.__Canon][],bool,bool,bool):bool:this
         113 (49.78% of base) : 9414.dasm - System.Collections.Generic.Dictionary`2[__Canon,__Canon][System.__Canon,System.__Canon]:CopyTo(System.Collections.Generic.KeyValuePair`2[System.__Canon,System.__Canon][],int):this
          98 (19.72% of base) : 11859.dasm - KeyCollection[Int32,Int32][System.Int32,System.Int32]:System.Collections.ICollection.CopyTo(System.Array,int):this
          98 (19.72% of base) : 11860.dasm - ValueCollection[Int32,Int32][System.Int32,System.Int32]:System.Collections.ICollection.CopyTo(System.Array,int):this
          89 (51.45% of base) : 7680.dasm - KeyCollection[Int32,Int32][System.Int32,System.Int32]:CopyTo(System.Int32[],int):this
          84 (48.00% of base) : 7683.dasm - ValueCollection[Int32,Int32][System.Int32,System.Int32]:CopyTo(System.Int32[],int):this
          84 ( 8.06% of base) : 15110.dasm - ProtoBuf.Compiler.CompilerContext:Switch(ProtoBuf.Compiler.CodeLabel[]):this
          80 (13.01% of base) : 7673.dasm - System.Collections.Generic.Dictionary`2[Int32,Int32][System.Int32,System.Int32]:AddRange(System.Collections.Generic.IEnumerable`1[KeyValuePair`2]):this
          80 (47.62% of base) : 3345.dasm - KeyCollection[__Canon,__Canon][System.__Canon,System.__Canon]:CopyTo(System.__Canon[],int):this
          77 (82.80% of base) : 9246.dasm - System.Collections.Generic.GenericEqualityComparer`1[OpCode][System.Reflection.Emit.OpCode]:IndexOf(System.Reflection.Emit.OpCode[],System.Reflection.Emit.OpCode,int,int):int:this
          76 (44.19% of base) : 2291.dasm - ValueCollection[__Canon,__Canon][System.__Canon,System.__Canon]:CopyTo(System.__Canon[],int):this
          62 (13.45% of base) : 14611.dasm - KeyCollection[__Canon,__Canon][System.__Canon,System.__Canon]:System.Collections.ICollection.CopyTo(System.Array,int):this
          62 (13.36% of base) : 14612.dasm - ValueCollection[__Canon,__Canon][System.__Canon,System.__Canon]:System.Collections.ICollection.CopyTo(System.Array,int):this
          57 (36.54% of base) : 25481.dasm - System.Collections.Tests.Perf_PriorityQueue`2[__Canon,__Canon][System.__Canon,System.__Canon]:K_Max_Elements():this
          45 (22.39% of base) : 20229.dasm - WithManyWeakChildren:.ctor(WithManyChildrenBase,Microsoft.CodeAnalysis.SyntaxNode,int):this
          28 (31.11% of base) : 24281.dasm - SciMark2.FFT:inverse(System.Double[])
          28 ( 1.63% of base) : 12802.dasm - AssignJagged:second_assignments(System.Int32[][],System.Int16[][])

Top method improvements (bytes):
         -48 (-14.20% of base) : 1274.dasm - System.Collections.Generic.ObjectEqualityComparer`1[__Canon][System.__Canon]:IndexOf(System.__Canon[],System.__Canon,int,int):int:this
         -36 (-10.17% of base) : 2717.dasm - System.Collections.Generic.GenericEqualityComparer`1[__Canon][System.__Canon]:IndexOf(System.__Canon[],System.__Canon,int,int):int:this
         -14 (-2.84% of base) : 14028.dasm - Microsoft.Extensions.Caching.Memory.Tests.MemoryCacheTests:AddThenRemove_NoExpiration():this
         -13 (-3.06% of base) : 24210.dasm - BenchmarksGame.SpectralNorm_1:MultiplyAv(int,System.Double[],System.Double[]):this
         -11 (-6.25% of base) : 20189.dasm - Microsoft.CodeAnalysis.Syntax.InternalSyntax.SyntaxList:List(Microsoft.CodeAnalysis.GreenNode[],int):Microsoft.CodeAnalysis.GreenNode
         -10 (-2.35% of base) : 24211.dasm - BenchmarksGame.SpectralNorm_1:MultiplyAtv(int,System.Double[],System.Double[]):this
          -8 (-7.69% of base) : 21902.dasm - System.Reflection.Internal.ObjectPool`1[__Canon][System.__Canon]:Allocate():System.__Canon:this
          -6 (-4.44% of base) : 17322.dasm - Microsoft.CodeAnalysis.CommonReferenceManager`2[__Canon,__Canon][System.__Canon,System.__Canon]:CheckCircularReference(System.Collections.Generic.IReadOnlyList`1[__Canon]):bool
          -5 (-1.40% of base) : 8348.dasm - Internal.Cryptography.Pal.ChainPal:GetChainStatusInformation(int):System.Security.Cryptography.X509Certificates.X509ChainStatus[]
          -4 (-0.35% of base) : 15533.dasm - LUDecomp:build_problem(System.Double[][],int,System.Double[])
          -3 (-4.76% of base) : 13358.dasm - BenchmarksGame.Fasta_1:MakeCumulative(BenchmarksGame.Fasta_1+Frequency[])
          -3 (-0.43% of base) : 15111.dasm - DynamicClass:proto_1(System.Object,ProtoBuf.ProtoWriter)
          -2 (-0.35% of base) : 15133.dasm - Microsoft.Extensions.Caching.Memory.Tests.MemoryCacheTests:AddThenRemove_RelativeExpiration():this
          -2 (-0.36% of base) : 19751.dasm - Microsoft.Extensions.Caching.Memory.Tests.MemoryCacheTests:AddThenRemove_ExpirationTokens():this
          -2 (-0.35% of base) : 15621.dasm - Microsoft.Extensions.Caching.Memory.Tests.MemoryCacheTests:AddThenRemove_SlidingExpiration():this

Top method regressions (percentages):
         276 (85.98% of base) : 10626.dasm - EMFloat:SetupCPUEmFloatArrays(EMFloat+InternalFPF[],EMFloat+InternalFPF[],EMFloat+InternalFPF[],int)
          77 (82.80% of base) : 9246.dasm - System.Collections.Generic.GenericEqualityComparer`1[OpCode][System.Reflection.Emit.OpCode]:IndexOf(System.Reflection.Emit.OpCode[],System.Reflection.Emit.OpCode,int,int):int:this
         314 (65.42% of base) : 10636.dasm - EMFloat:DoEmFloatIteration(EMFloat+InternalFPF[],EMFloat+InternalFPF[],EMFloat+InternalFPF[],int,int):long
          89 (51.45% of base) : 7680.dasm - KeyCollection[Int32,Int32][System.Int32,System.Int32]:CopyTo(System.Int32[],int):this
         113 (49.78% of base) : 9414.dasm - System.Collections.Generic.Dictionary`2[__Canon,__Canon][System.__Canon,System.__Canon]:CopyTo(System.Collections.Generic.KeyValuePair`2[System.__Canon,System.__Canon][],int):this
          84 (48.00% of base) : 7683.dasm - ValueCollection[Int32,Int32][System.Int32,System.Int32]:CopyTo(System.Int32[],int):this
          80 (47.62% of base) : 3345.dasm - KeyCollection[__Canon,__Canon][System.__Canon,System.__Canon]:CopyTo(System.__Canon[],int):this
         191 (46.81% of base) : 17802.dasm - Microsoft.CodeAnalysis.MetadataDecoder`5[__Canon,__Canon,__Canon,__Canon,__Canon][System.__Canon,System.__Canon,System.__Canon,System.__Canon,System.__Canon]:DoPropertySignaturesMatch(Microsoft.CodeAnalysis.ParamInfo`1[System.__Canon][],Microsoft.CodeAnalysis.ParamInfo`1[System.__Canon][],bool,bool,bool):bool:this
          76 (44.19% of base) : 2291.dasm - ValueCollection[__Canon,__Canon][System.__Canon,System.__Canon]:CopyTo(System.__Canon[],int):this
          57 (36.54% of base) : 25481.dasm - System.Collections.Tests.Perf_PriorityQueue`2[__Canon,__Canon][System.__Canon,System.__Canon]:K_Max_Elements():this
          28 (31.11% of base) : 24281.dasm - SciMark2.FFT:inverse(System.Double[])
          45 (22.39% of base) : 20229.dasm - WithManyWeakChildren:.ctor(WithManyChildrenBase,Microsoft.CodeAnalysis.SyntaxNode,int):this
          98 (19.72% of base) : 11859.dasm - KeyCollection[Int32,Int32][System.Int32,System.Int32]:System.Collections.ICollection.CopyTo(System.Array,int):this
          98 (19.72% of base) : 11860.dasm - ValueCollection[Int32,Int32][System.Int32,System.Int32]:System.Collections.ICollection.CopyTo(System.Array,int):this
          27 (16.17% of base) : 10346.dasm - System.Security.Cryptography.Primitives.Tests.Performance.Perf_FixedTimeEquals:Setup(System.String,System.String):this
          62 (13.45% of base) : 14611.dasm - KeyCollection[__Canon,__Canon][System.__Canon,System.__Canon]:System.Collections.ICollection.CopyTo(System.Array,int):this
          62 (13.36% of base) : 14612.dasm - ValueCollection[__Canon,__Canon][System.__Canon,System.__Canon]:System.Collections.ICollection.CopyTo(System.Array,int):this
          80 (13.01% of base) : 7673.dasm - System.Collections.Generic.Dictionary`2[Int32,Int32][System.Int32,System.Int32]:AddRange(System.Collections.Generic.IEnumerable`1[KeyValuePair`2]):this
         281 ( 9.59% of base) : 25723.dasm - Benchstone.BenchI.MulMatrix:Inner(System.Int32[][],System.Int32[][],System.Int32[][])
          84 ( 8.06% of base) : 15110.dasm - ProtoBuf.Compiler.CompilerContext:Switch(ProtoBuf.Compiler.CodeLabel[]):this

Top method improvements (percentages):
         -48 (-14.20% of base) : 1274.dasm - System.Collections.Generic.ObjectEqualityComparer`1[__Canon][System.__Canon]:IndexOf(System.__Canon[],System.__Canon,int,int):int:this
         -36 (-10.17% of base) : 2717.dasm - System.Collections.Generic.GenericEqualityComparer`1[__Canon][System.__Canon]:IndexOf(System.__Canon[],System.__Canon,int,int):int:this
          -8 (-7.69% of base) : 21902.dasm - System.Reflection.Internal.ObjectPool`1[__Canon][System.__Canon]:Allocate():System.__Canon:this
         -11 (-6.25% of base) : 20189.dasm - Microsoft.CodeAnalysis.Syntax.InternalSyntax.SyntaxList:List(Microsoft.CodeAnalysis.GreenNode[],int):Microsoft.CodeAnalysis.GreenNode
          -3 (-4.76% of base) : 13358.dasm - BenchmarksGame.Fasta_1:MakeCumulative(BenchmarksGame.Fasta_1+Frequency[])
          -6 (-4.44% of base) : 17322.dasm - Microsoft.CodeAnalysis.CommonReferenceManager`2[__Canon,__Canon][System.__Canon,System.__Canon]:CheckCircularReference(System.Collections.Generic.IReadOnlyList`1[__Canon]):bool
         -13 (-3.06% of base) : 24210.dasm - BenchmarksGame.SpectralNorm_1:MultiplyAv(int,System.Double[],System.Double[]):this
         -14 (-2.84% of base) : 14028.dasm - Microsoft.Extensions.Caching.Memory.Tests.MemoryCacheTests:AddThenRemove_NoExpiration():this
         -10 (-2.35% of base) : 24211.dasm - BenchmarksGame.SpectralNorm_1:MultiplyAtv(int,System.Double[],System.Double[]):this
          -5 (-1.40% of base) : 8348.dasm - Internal.Cryptography.Pal.ChainPal:GetChainStatusInformation(int):System.Security.Cryptography.X509Certificates.X509ChainStatus[]
          -3 (-0.43% of base) : 15111.dasm - DynamicClass:proto_1(System.Object,ProtoBuf.ProtoWriter)
          -2 (-0.36% of base) : 19751.dasm - Microsoft.Extensions.Caching.Memory.Tests.MemoryCacheTests:AddThenRemove_ExpirationTokens():this
          -2 (-0.35% of base) : 15133.dasm - Microsoft.Extensions.Caching.Memory.Tests.MemoryCacheTests:AddThenRemove_RelativeExpiration():this
          -2 (-0.35% of base) : 15621.dasm - Microsoft.Extensions.Caching.Memory.Tests.MemoryCacheTests:AddThenRemove_SlidingExpiration():this
          -4 (-0.35% of base) : 15533.dasm - LUDecomp:build_problem(System.Double[][],int,System.Double[])

39 total methods with Code Size differences (15 improved, 24 regressed), 2 unchanged.

```

</details>

--------------------------------------------------------------------------------

```

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 50789
Total bytes of diff: 57962
Total bytes of delta: 7173 (14.12% of base)
Total relative delta: 10.94
    diff is a regression.
    relative diff is a regression.
```
<details>

<summary>Detail diffs</summary>

```

Top file regressions (bytes):
         314 : 194633.dasm (65.42% of base)
         310 : 169017.dasm (26.12% of base)
         310 : 168630.dasm (26.12% of base)
         310 : 168802.dasm (26.12% of base)
         310 : 169110.dasm (26.12% of base)
         310 : 168724.dasm (26.12% of base)
         310 : 168920.dasm (26.12% of base)
         281 : 248723.dasm (9.59% of base)
         276 : 194632.dasm (85.98% of base)
         267 : 168730.dasm (16.11% of base)
         267 : 168808.dasm (16.11% of base)
         267 : 169021.dasm (16.11% of base)
         267 : 168926.dasm (16.11% of base)
         267 : 169114.dasm (16.11% of base)
         267 : 168636.dasm (16.11% of base)
         259 : 213032.dasm (102.37% of base)
         249 : 167322.dasm (66.58% of base)
         216 : 251496.dasm (91.14% of base)
         216 : 194592.dasm (12.80% of base)
         174 : 249196.dasm (20.67% of base)

Top file improvements (bytes):
         -26 : 166707.dasm (-10.36% of base)
         -13 : 248646.dasm (-3.06% of base)
         -10 : 248647.dasm (-2.35% of base)
          -5 : 166775.dasm (-0.69% of base)
          -4 : 194691.dasm (-0.35% of base)
          -3 : 168634.dasm (-1.91% of base)
          -3 : 168918.dasm (-2.75% of base)
          -3 : 168803.dasm (-1.91% of base)
          -3 : 168631.dasm (-1.91% of base)
          -3 : 168800.dasm (-2.75% of base)
          -3 : 168921.dasm (-1.91% of base)
          -3 : 168628.dasm (-2.75% of base)
          -3 : 168806.dasm (-1.91% of base)
          -3 : 168924.dasm (-1.91% of base)
          -3 : 241130.dasm (-0.99% of base)
          -3 : 168722.dasm (-2.75% of base)
          -3 : 168728.dasm (-1.91% of base)
          -3 : 239163.dasm (-4.76% of base)
          -3 : 168725.dasm (-1.91% of base)
          -2 : 241128.dasm (-0.77% of base)

70 total files with Code Size differences (20 improved, 50 regressed), 0 unchanged.

Top method regressions (bytes):
         314 (65.42% of base) : 194633.dasm - EMFloat:DoEmFloatIteration(EMFloat+InternalFPF[],EMFloat+InternalFPF[],EMFloat+InternalFPF[],int,int):long
         310 (26.12% of base) : 169017.dasm - Helper:ValidateInnerArraySequential(InnerArraySequential,InnerArraySequential,System.String):bool
         310 (26.12% of base) : 168630.dasm - Helper:ValidateInnerArraySequential(InnerArraySequential,InnerArraySequential,System.String):bool
         310 (26.12% of base) : 168802.dasm - Helper:ValidateInnerArraySequential(InnerArraySequential,InnerArraySequential,System.String):bool
         310 (26.12% of base) : 169110.dasm - Helper:ValidateInnerArraySequential(InnerArraySequential,InnerArraySequential,System.String):bool
         310 (26.12% of base) : 168724.dasm - Helper:ValidateInnerArraySequential(InnerArraySequential,InnerArraySequential,System.String):bool
         310 (26.12% of base) : 168920.dasm - Helper:ValidateInnerArraySequential(InnerArraySequential,InnerArraySequential,System.String):bool
         281 ( 9.59% of base) : 248723.dasm - Benchstone.BenchI.MulMatrix:Inner(System.Int32[][],System.Int32[][],System.Int32[][])
         276 (85.98% of base) : 194632.dasm - EMFloat:SetupCPUEmFloatArrays(EMFloat+InternalFPF[],EMFloat+InternalFPF[],EMFloat+InternalFPF[],int)
         267 (16.11% of base) : 168730.dasm - Helper:ValidateOUTER3(OUTER3,OUTER3,System.String):bool
         267 (16.11% of base) : 168808.dasm - Helper:ValidateOUTER3(OUTER3,OUTER3,System.String):bool
         267 (16.11% of base) : 169021.dasm - Helper:ValidateOUTER3(OUTER3,OUTER3,System.String):bool
         267 (16.11% of base) : 168926.dasm - Helper:ValidateOUTER3(OUTER3,OUTER3,System.String):bool
         267 (16.11% of base) : 169114.dasm - Helper:ValidateOUTER3(OUTER3,OUTER3,System.String):bool
         267 (16.11% of base) : 168636.dasm - Helper:ValidateOUTER3(OUTER3,OUTER3,System.String):bool
         259 (102.37% of base) : 213032.dasm - ArrayMarshal:IsCorrect(ArrayMarshal+S2[],ArrayMarshal+S2[]):bool
         249 (66.58% of base) : 167322.dasm - Internal.IL.EcmaMethodIL:GetExceptionRegions():Internal.IL.ILExceptionRegion[]:this
         216 (91.14% of base) : 251496.dasm - VectorMathTests.Program:sum(System.Numerics.Vector4[]):float
         216 (12.80% of base) : 194592.dasm - Huffman:DoHuffIteration(System.Byte[],System.Byte[],System.Byte[],int,int,huff_node[]):long
         174 (20.67% of base) : 249196.dasm - SimpleArray_01.Test:BadMatrixMul1()

Top method improvements (bytes):
         -26 (-10.36% of base) : 166707.dasm - Internal.TypeSystem.TypeSystemHelpers:RequiresSlotUnification(Internal.TypeSystem.MethodDesc):bool
         -13 (-3.06% of base) : 248646.dasm - BenchmarksGame.SpectralNorm_1:MultiplyAv(int,System.Double[],System.Double[]):this
         -10 (-2.35% of base) : 248647.dasm - BenchmarksGame.SpectralNorm_1:MultiplyAtv(int,System.Double[],System.Double[]):this
          -5 (-0.69% of base) : 166775.dasm - Internal.TypeSystem.MetadataVirtualMethodAlgorithm:ResolveInterfaceMethodToDefaultImplementationOnType(Internal.TypeSystem.MethodDesc,Internal.TypeSystem.MetadataType,byref):int
          -4 (-0.35% of base) : 194691.dasm - LUDecomp:build_problem(System.Double[][],int,System.Double[])
          -3 (-1.91% of base) : 168634.dasm - Helper:NewOUTER3(int,float,System.String,System.String):OUTER3
          -3 (-2.75% of base) : 168918.dasm - Helper:NewInnerArraySequential(int,float,System.String):InnerArraySequential
          -3 (-1.91% of base) : 168803.dasm - Helper:NewInnerArrayExplicit(int,float,System.String,System.String):InnerArrayExplicit
          -3 (-1.91% of base) : 168631.dasm - Helper:NewInnerArrayExplicit(int,float,System.String,System.String):InnerArrayExplicit
          -3 (-2.75% of base) : 168800.dasm - Helper:NewInnerArraySequential(int,float,System.String):InnerArraySequential
          -3 (-1.91% of base) : 168921.dasm - Helper:NewInnerArrayExplicit(int,float,System.String,System.String):InnerArrayExplicit
          -3 (-2.75% of base) : 168628.dasm - Helper:NewInnerArraySequential(int,float,System.String):InnerArraySequential
          -3 (-1.91% of base) : 168806.dasm - Helper:NewOUTER3(int,float,System.String,System.String):OUTER3
          -3 (-1.91% of base) : 168924.dasm - Helper:NewOUTER3(int,float,System.String,System.String):OUTER3
          -3 (-0.99% of base) : 241130.dasm - Vector3Test:VectorArray(float):int
          -3 (-2.75% of base) : 168722.dasm - Helper:NewInnerArraySequential(int,float,System.String):InnerArraySequential
          -3 (-1.91% of base) : 168728.dasm - Helper:NewOUTER3(int,float,System.String,System.String):OUTER3
          -3 (-4.76% of base) : 239163.dasm - BenchmarksGame.Fasta_1:MakeCumulative(BenchmarksGame.Fasta_1+Frequency[])
          -3 (-1.91% of base) : 168725.dasm - Helper:NewInnerArrayExplicit(int,float,System.String,System.String):InnerArrayExplicit
          -2 (-0.77% of base) : 241128.dasm - Vector4Test:VectorArray(float):int

Top method regressions (percentages):
         259 (102.37% of base) : 213032.dasm - ArrayMarshal:IsCorrect(ArrayMarshal+S2[],ArrayMarshal+S2[]):bool
         216 (91.14% of base) : 251496.dasm - VectorMathTests.Program:sum(System.Numerics.Vector4[]):float
         276 (85.98% of base) : 194632.dasm - EMFloat:SetupCPUEmFloatArrays(EMFloat+InternalFPF[],EMFloat+InternalFPF[],EMFloat+InternalFPF[],int)
          49 (74.24% of base) : 81558.dasm - Test:Check(int)
         249 (66.58% of base) : 167322.dasm - Internal.IL.EcmaMethodIL:GetExceptionRegions():Internal.IL.ILExceptionRegion[]:this
         314 (65.42% of base) : 194633.dasm - EMFloat:DoEmFloatIteration(EMFloat+InternalFPF[],EMFloat+InternalFPF[],EMFloat+InternalFPF[],int,int):long
         123 (60.89% of base) : 246188.dasm - ToBoxOrNotToBox.Program:PerfTest1(int,int)
         151 (52.61% of base) : 213030.dasm - ArrayMarshal:NewS2arr(int,int,int,short,ushort,ubyte,byte,short,ushort,long,long,float,double):ArrayMarshal+S2[]
          28 (31.11% of base) : 228715.dasm - SciMark2.FFT:inverse(System.Double[])
          89 (27.73% of base) : 167364.dasm - Internal.IL.InstantiatedMethodIL:GetLocals():Internal.TypeSystem.LocalVariableDefinition[]:this
         310 (26.12% of base) : 169017.dasm - Helper:ValidateInnerArraySequential(InnerArraySequential,InnerArraySequential,System.String):bool
         310 (26.12% of base) : 168630.dasm - Helper:ValidateInnerArraySequential(InnerArraySequential,InnerArraySequential,System.String):bool
         310 (26.12% of base) : 168802.dasm - Helper:ValidateInnerArraySequential(InnerArraySequential,InnerArraySequential,System.String):bool
         310 (26.12% of base) : 169110.dasm - Helper:ValidateInnerArraySequential(InnerArraySequential,InnerArraySequential,System.String):bool
         310 (26.12% of base) : 168724.dasm - Helper:ValidateInnerArraySequential(InnerArraySequential,InnerArraySequential,System.String):bool
         310 (26.12% of base) : 168920.dasm - Helper:ValidateInnerArraySequential(InnerArraySequential,InnerArraySequential,System.String):bool
         174 (20.67% of base) : 249196.dasm - SimpleArray_01.Test:BadMatrixMul1()
         158 (19.90% of base) : 253494.dasm - MatrixMul.Test:MatrixMul()
         141 (16.34% of base) : 249197.dasm - SimpleArray_01.Test:BadMatrixMul2()
         267 (16.11% of base) : 168730.dasm - Helper:ValidateOUTER3(OUTER3,OUTER3,System.String):bool

Top method improvements (percentages):
         -26 (-10.36% of base) : 166707.dasm - Internal.TypeSystem.TypeSystemHelpers:RequiresSlotUnification(Internal.TypeSystem.MethodDesc):bool
          -3 (-4.76% of base) : 239163.dasm - BenchmarksGame.Fasta_1:MakeCumulative(BenchmarksGame.Fasta_1+Frequency[])
         -13 (-3.06% of base) : 248646.dasm - BenchmarksGame.SpectralNorm_1:MultiplyAv(int,System.Double[],System.Double[]):this
          -3 (-2.75% of base) : 168918.dasm - Helper:NewInnerArraySequential(int,float,System.String):InnerArraySequential
          -3 (-2.75% of base) : 168800.dasm - Helper:NewInnerArraySequential(int,float,System.String):InnerArraySequential
          -3 (-2.75% of base) : 168628.dasm - Helper:NewInnerArraySequential(int,float,System.String):InnerArraySequential
          -3 (-2.75% of base) : 168722.dasm - Helper:NewInnerArraySequential(int,float,System.String):InnerArraySequential
         -10 (-2.35% of base) : 248647.dasm - BenchmarksGame.SpectralNorm_1:MultiplyAtv(int,System.Double[],System.Double[]):this
          -3 (-1.91% of base) : 168634.dasm - Helper:NewOUTER3(int,float,System.String,System.String):OUTER3
          -3 (-1.91% of base) : 168803.dasm - Helper:NewInnerArrayExplicit(int,float,System.String,System.String):InnerArrayExplicit
          -3 (-1.91% of base) : 168631.dasm - Helper:NewInnerArrayExplicit(int,float,System.String,System.String):InnerArrayExplicit
          -3 (-1.91% of base) : 168921.dasm - Helper:NewInnerArrayExplicit(int,float,System.String,System.String):InnerArrayExplicit
          -3 (-1.91% of base) : 168806.dasm - Helper:NewOUTER3(int,float,System.String,System.String):OUTER3
          -3 (-1.91% of base) : 168924.dasm - Helper:NewOUTER3(int,float,System.String,System.String):OUTER3
          -3 (-1.91% of base) : 168728.dasm - Helper:NewOUTER3(int,float,System.String,System.String):OUTER3
          -3 (-1.91% of base) : 168725.dasm - Helper:NewInnerArrayExplicit(int,float,System.String,System.String):InnerArrayExplicit
          -3 (-0.99% of base) : 241130.dasm - Vector3Test:VectorArray(float):int
          -2 (-0.77% of base) : 241128.dasm - Vector4Test:VectorArray(float):int
          -5 (-0.69% of base) : 166775.dasm - Internal.TypeSystem.MetadataVirtualMethodAlgorithm:ResolveInterfaceMethodToDefaultImplementationOnType(Internal.TypeSystem.MethodDesc,Internal.TypeSystem.MetadataType,byref):int
          -4 (-0.35% of base) : 194691.dasm - LUDecomp:build_problem(System.Double[][],int,System.Double[])

70 total methods with Code Size differences (20 improved, 50 regressed), 0 unchanged.

```

</details>

--------------------------------------------------------------------------------

```

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 66954
Total bytes of diff: 74145
Total bytes of delta: 7191 (10.74% of base)
Total relative delta: 20.86
    diff is a regression.
    relative diff is a regression.
```
<details>

<summary>Detail diffs</summary>

```

Top file regressions (bytes):
         528 : 2571.dasm (72.53% of base)
         450 : 25232.dasm (15.59% of base)
         293 : 92711.dasm (50.96% of base)
         274 : 73747.dasm (53.83% of base)
         271 : 171367.dasm (17.96% of base)
         241 : 204928.dasm (60.10% of base)
         224 : 171366.dasm (17.39% of base)
         188 : 21977.dasm (12.56% of base)
         171 : 181569.dasm (71.25% of base)
         168 : 75937.dasm (12.19% of base)
         162 : 44518.dasm (114.89% of base)
         160 : 151231.dasm (44.08% of base)
         155 : 95335.dasm (7.05% of base)
         152 : 84491.dasm (77.95% of base)
         139 : 216480.dasm (25.88% of base)
         139 : 45298.dasm (46.96% of base)
         138 : 73748.dasm (66.03% of base)
         134 : 181566.dasm (54.92% of base)
         134 : 52201.dasm (29.39% of base)
         131 : 22122.dasm (15.45% of base)

Top file improvements (bytes):
         -37 : 73754.dasm (-0.81% of base)
         -36 : 24021.dasm (-10.14% of base)
         -32 : 24016.dasm (-9.61% of base)
         -20 : 192694.dasm (-7.14% of base)
         -16 : 161256.dasm (-6.20% of base)
         -16 : 216474.dasm (-1.03% of base)
         -11 : 173459.dasm (-4.78% of base)
         -10 : 179730.dasm (-1.86% of base)
         -10 : 149598.dasm (-1.34% of base)
          -9 : 150742.dasm (-7.14% of base)
          -8 : 85767.dasm (-7.02% of base)
          -8 : 174207.dasm (-0.52% of base)
          -6 : 10430.dasm (-3.66% of base)
          -6 : 174026.dasm (-1.29% of base)
          -6 : 174027.dasm (-1.36% of base)
          -5 : 93729.dasm (-0.40% of base)
          -5 : 203938.dasm (-1.65% of base)
          -4 : 150744.dasm (-0.31% of base)
          -3 : 173392.dasm (-0.47% of base)
          -3 : 174233.dasm (-0.09% of base)

103 total files with Code Size differences (33 improved, 70 regressed), 8 unchanged.

Top method regressions (bytes):
         528 (72.53% of base) : 2571.dasm - Microsoft.CodeAnalysis.CSharp.Symbols.Metadata.PE.PEPropertySymbol:GetParameters(Microsoft.CodeAnalysis.CSharp.Symbols.Metadata.PE.PEModuleSymbol,Microsoft.CodeAnalysis.CSharp.Symbols.Metadata.PE.PEPropertySymbol,Microsoft.CodeAnalysis.ParamInfo`1[Microsoft.CodeAnalysis.CSharp.Symbols.TypeSymbol][],Microsoft.CodeAnalysis.ParamInfo`1[Microsoft.CodeAnalysis.CSharp.Symbols.TypeSymbol][],byref):System.Collections.Immutable.ImmutableArray`1[Microsoft.CodeAnalysis.CSharp.Symbols.ParameterSymbol]
         450 (15.59% of base) : 25232.dasm - System.Diagnostics.Tracing.EventProvider:WriteEvent(byref,long,long,long,System.Object[]):bool:this
         293 (50.96% of base) : 92711.dasm - System.Xml.Xsl.IlGen.XmlILVisitor:VisitChoice(System.Xml.Xsl.Qil.QilChoice):System.Xml.Xsl.Qil.QilNode:this
         274 (53.83% of base) : 73747.dasm - System.Data.Common.DbDataAdapter:UpdatedRowStatusErrors(System.Data.Common.RowUpdatedEventArgs,System.Data.Common.DbDataAdapter+BatchCommandInfo[],int):int:this
         271 (17.96% of base) : 171367.dasm - BatchBlockTargetCore:RetrievePostponedItemsNonGreedy(bool):this
         241 (60.10% of base) : 204928.dasm - System.Net.WebSockets.WebSocketBuffer:ValidateNativeBuffers(int,int,Interop+WebSocket+Buffer[],int):this
         224 (17.39% of base) : 171366.dasm - BatchBlockTargetCore:RetrievePostponedItemsGreedyBounded(bool):this
         188 (12.56% of base) : 21977.dasm - Microsoft.CodeAnalysis.CSharp.Binder:BindArrayCreationWithInitializer(Microsoft.CodeAnalysis.DiagnosticBag,Microsoft.CodeAnalysis.CSharp.Syntax.ExpressionSyntax,Microsoft.CodeAnalysis.CSharp.Syntax.InitializerExpressionSyntax,Microsoft.CodeAnalysis.CSharp.Symbols.ArrayTypeSymbol,System.Collections.Immutable.ImmutableArray`1[Microsoft.CodeAnalysis.CSharp.BoundExpression],System.Collections.Immutable.ImmutableArray`1[Microsoft.CodeAnalysis.CSharp.BoundExpression]):Microsoft.CodeAnalysis.CSharp.BoundArrayCreation:this
         171 (71.25% of base) : 181569.dasm - System.Reflection.TypeLoading.Ecma.EcmaCustomAttributeHelpers:ToApiForm(System.Collections.Generic.IList`1[System.Reflection.Metadata.CustomAttributeTypedArgument`1[System.Reflection.TypeLoading.RoType]]):System.Collections.Generic.IList`1[System.Reflection.CustomAttributeTypedArgument]
         168 (12.19% of base) : 75937.dasm - System.Data.Select:CreateIndex():this
         162 (114.89% of base) : 44518.dasm - System.Collections.Generic.NullableEqualityComparer`1:IndexOf(System.Nullable`1[System.Int32][],System.Nullable`1[System.Int32],int,int):int:this
         160 (44.08% of base) : 151231.dasm - Microsoft.CodeAnalysis.MetadataDecoder`5:DoPropertySignaturesMatch(Microsoft.CodeAnalysis.ParamInfo`1[System.__Canon][],Microsoft.CodeAnalysis.ParamInfo`1[System.__Canon][],bool,bool,bool):bool:this
         155 ( 7.05% of base) : 95335.dasm - System.Xml.Xsl.Xslt.XsltInput:GetAttributes(System.Xml.Xsl.Xslt.XsltInput+XsltAttribute[]):System.Xml.Xsl.Xslt.XsltInput+ContextInfo:this
         152 (77.95% of base) : 84491.dasm - System.Speech.Internal.Synthesis.EngineSiteSapi:System.Speech.Internal.Synthesis.ISpEngineSite.AddEvents(System.Speech.Internal.Synthesis.SpeechEventSapi[],int):this
         139 (25.88% of base) : 216480.dasm - System.Runtime.Caching.ExpiresBucket:Expand():this
         139 (46.96% of base) : 45298.dasm - AttributeSorter:Sort():this
         138 (66.03% of base) : 73748.dasm - System.Data.Common.DbDataAdapter:UpdatedRowStatusContinue(System.Data.Common.RowUpdatedEventArgs,System.Data.Common.DbDataAdapter+BatchCommandInfo[],int):int:this
         134 (54.92% of base) : 181566.dasm - System.Reflection.TypeLoading.Ecma.EcmaCustomAttributeHelpers:ToApiForm(System.Collections.Generic.IList`1[System.Reflection.Metadata.CustomAttributeNamedArgument`1[System.Reflection.TypeLoading.RoType]],System.Type):System.Collections.Generic.IList`1[System.Reflection.CustomAttributeNamedArgument]
         134 (29.39% of base) : 52201.dasm - System.Data.OleDb.OleDbCommand:ApplyParameterBindings(System.Data.Common.UnsafeNativeMethods+ICommandWithParameters,System.Data.OleDb.tagDBPARAMBINDINFO[]):this
         131 (15.45% of base) : 22122.dasm - Microsoft.CodeAnalysis.CSharp.Binder:GetParamArrayArgument(Microsoft.CodeAnalysis.CSharp.Symbols.ParameterSymbol,System.Collections.Immutable.ImmutableArray`1[Microsoft.CodeAnalysis.TypedConstant],int,int,Microsoft.CodeAnalysis.CSharp.Conversions):Microsoft.CodeAnalysis.TypedConstant

Top method improvements (bytes):
         -37 (-0.81% of base) : 73754.dasm - System.Data.Common.DbDataAdapter:Update(System.Data.DataRow[],System.Data.Common.DataTableMapping):int:this
         -36 (-10.14% of base) : 24021.dasm - System.Collections.Generic.GenericEqualityComparer`1:IndexOf(System.__Canon[],System.__Canon,int,int):int:this
         -32 (-9.61% of base) : 24016.dasm - System.Collections.Generic.ObjectEqualityComparer`1:IndexOf(System.__Canon[],System.__Canon,int,int):int:this
         -20 (-7.14% of base) : 192694.dasm - Internal.Cryptography.Helpers:FixupKeyParity(System.Byte[]):System.Byte[]
         -16 (-6.20% of base) : 161256.dasm - System.Drawing.Drawing2D.PathGradientBrush:set_SurroundColors(System.Drawing.Color[]):this
         -16 (-1.03% of base) : 216474.dasm - System.Runtime.Caching.ExpiresBucket:FlushExpiredItems(System.DateTime,bool):int:this
         -11 (-4.78% of base) : 173459.dasm - Internal.TypeSystem.TypeSystemHelpers:RequiresSlotUnification(Internal.TypeSystem.MethodDesc):bool
         -10 (-1.86% of base) : 179730.dasm - System.Security.Cryptography.Pkcs.SignedCms:AddCertificate(System.Security.Cryptography.X509Certificates.X509Certificate2):this
         -10 (-1.34% of base) : 149598.dasm - Microsoft.CodeAnalysis.VersionHelper:TryParse(System.String,bool,ushort,byref):bool
          -9 (-7.14% of base) : 150742.dasm - Microsoft.CodeAnalysis.CommonReferenceManager`2:CheckCircularReference(System.Collections.Generic.IReadOnlyList`1[Microsoft.CodeAnalysis.CommonReferenceManager`2+AssemblyReferenceBinding[System.__Canon, System.__Canon][]]):bool
          -8 (-7.02% of base) : 85767.dasm - System.Reflection.Internal.ObjectPool`1:Allocate():System.__Canon:this
          -8 (-0.52% of base) : 174207.dasm - Internal.IL.ILStackHelper:ComputeMaxStack(Internal.IL.MethodIL):int
          -6 (-3.66% of base) : 10430.dasm - Microsoft.CodeAnalysis.CSharp.Syntax.InternalSyntax.SyntaxList:List(Microsoft.CodeAnalysis.CSharp.Syntax.InternalSyntax.CSharpSyntaxNode[],int):Microsoft.CodeAnalysis.CSharp.Syntax.InternalSyntax.CSharpSyntaxNode
          -6 (-1.29% of base) : 174026.dasm - Internal.TypeSystem.DefType:ComputeStaticFieldLayout(int):this
          -6 (-1.36% of base) : 174027.dasm - Internal.TypeSystem.DefType:ComputeInstanceLayout(int):this
          -5 (-0.40% of base) : 93729.dasm - System.Xml.Xsl.Runtime.XmlQueryStaticData:GetObjectData(byref,byref):this
          -5 (-1.65% of base) : 203938.dasm - Internal.Cryptography.Pal.ChainPal:GetChainStatusInformation(int):System.Security.Cryptography.X509Certificates.X509ChainStatus[]
          -4 (-0.31% of base) : 150744.dasm - Microsoft.CodeAnalysis.CommonReferenceManager`2:ReuseAssemblySymbolsWithNoPiaLocalTypes(Microsoft.CodeAnalysis.CommonReferenceManager`2+BoundInputAssembly[System.__Canon, System.__Canon][],System.__Canon[],System.Collections.Immutable.ImmutableArray`1[Microsoft.CodeAnalysis.CommonReferenceManager`2+AssemblyData[System.__Canon, System.__Canon]],int):bool:this
          -3 (-0.47% of base) : 173392.dasm - Internal.TypeSystem.MetadataVirtualMethodAlgorithm:ResolveInterfaceMethodToDefaultImplementationOnType(Internal.TypeSystem.MethodDesc,Internal.TypeSystem.MetadataType,byref):int
          -3 (-0.09% of base) : 174233.dasm - Internal.IL.MethodILDebugView:get_Disassembly():System.String:this

Top method regressions (percentages):
         162 (114.89% of base) : 44518.dasm - System.Collections.Generic.NullableEqualityComparer`1:IndexOf(System.Nullable`1[System.Int32][],System.Nullable`1[System.Int32],int,int):int:this
         116 (89.23% of base) : 75940.dasm - System.Data.Select:CompareClosestCandidateIndexDesc(System.Data.IndexField[]):int:this
         152 (77.95% of base) : 84491.dasm - System.Speech.Internal.Synthesis.EngineSiteSapi:System.Speech.Internal.Synthesis.ISpEngineSite.AddEvents(System.Speech.Internal.Synthesis.SpeechEventSapi[],int):this
         528 (72.53% of base) : 2571.dasm - Microsoft.CodeAnalysis.CSharp.Symbols.Metadata.PE.PEPropertySymbol:GetParameters(Microsoft.CodeAnalysis.CSharp.Symbols.Metadata.PE.PEModuleSymbol,Microsoft.CodeAnalysis.CSharp.Symbols.Metadata.PE.PEPropertySymbol,Microsoft.CodeAnalysis.ParamInfo`1[Microsoft.CodeAnalysis.CSharp.Symbols.TypeSymbol][],Microsoft.CodeAnalysis.ParamInfo`1[Microsoft.CodeAnalysis.CSharp.Symbols.TypeSymbol][],byref):System.Collections.Immutable.ImmutableArray`1[Microsoft.CodeAnalysis.CSharp.Symbols.ParameterSymbol]
         171 (71.25% of base) : 181569.dasm - System.Reflection.TypeLoading.Ecma.EcmaCustomAttributeHelpers:ToApiForm(System.Collections.Generic.IList`1[System.Reflection.Metadata.CustomAttributeTypedArgument`1[System.Reflection.TypeLoading.RoType]]):System.Collections.Generic.IList`1[System.Reflection.CustomAttributeTypedArgument]
         138 (66.03% of base) : 73748.dasm - System.Data.Common.DbDataAdapter:UpdatedRowStatusContinue(System.Data.Common.RowUpdatedEventArgs,System.Data.Common.DbDataAdapter+BatchCommandInfo[],int):int:this
          63 (61.76% of base) : 204826.dasm - System.Net.WebSockets.WebSocketProtocolComponent:MarshalHttpHeaders(long,int):Interop+WebSocket+HttpHeader[]
         241 (60.10% of base) : 204928.dasm - System.Net.WebSockets.WebSocketBuffer:ValidateNativeBuffers(int,int,Interop+WebSocket+Buffer[],int):this
          51 (60.00% of base) : 73746.dasm - System.Data.Common.DbDataAdapter:UpdatedRowStatusSkip(System.Data.Common.DbDataAdapter+BatchCommandInfo[],int):int:this
         130 (58.82% of base) : 182039.dasm - System.Reflection.TypeLoading.CustomAttributeHelpers:CloneForApiReturn(System.Collections.Generic.IList`1[System.Reflection.CustomAttributeNamedArgument]):System.Collections.ObjectModel.ReadOnlyCollection`1[System.Reflection.CustomAttributeNamedArgument]
         107 (58.47% of base) : 43851.dasm - System.Collections.Generic.Dictionary`2:CopyTo(System.Collections.Generic.KeyValuePair`2[System.UInt64, System.Char][],int):this
          93 (58.13% of base) : 44836.dasm - System.Collections.Generic.GenericEqualityComparer`1:IndexOf(System.ValueTuple`3[System.IntPtr, System.__Canon, System.Int32][],System.ValueTuple`3[System.IntPtr, System.__Canon, System.Int32],int,int):int:this
         114 (57.00% of base) : 182040.dasm - System.Reflection.TypeLoading.CustomAttributeHelpers:CloneForApiReturn(System.Collections.Generic.IList`1[System.Reflection.CustomAttributeTypedArgument]):System.Collections.ObjectModel.ReadOnlyCollection`1[System.Reflection.CustomAttributeTypedArgument]
          97 (55.43% of base) : 44834.dasm - System.Collections.Generic.EqualityComparer`1:IndexOf(System.Resources.ResourceLocator[],System.Resources.ResourceLocator,int,int):int:this
          95 (55.23% of base) : 44715.dasm - ValueCollection:CopyTo(System.Char[],int):this
         134 (54.92% of base) : 181566.dasm - System.Reflection.TypeLoading.Ecma.EcmaCustomAttributeHelpers:ToApiForm(System.Collections.Generic.IList`1[System.Reflection.Metadata.CustomAttributeNamedArgument`1[System.Reflection.TypeLoading.RoType]],System.Type):System.Collections.Generic.IList`1[System.Reflection.CustomAttributeNamedArgument]
         274 (53.83% of base) : 73747.dasm - System.Data.Common.DbDataAdapter:UpdatedRowStatusErrors(System.Data.Common.RowUpdatedEventArgs,System.Data.Common.DbDataAdapter+BatchCommandInfo[],int):int:this
         118 (51.30% of base) : 23975.dasm - System.Collections.Generic.Dictionary`2:CopyTo(System.Collections.Generic.KeyValuePair`2[System.__Canon, System.__Canon][],int):this
          63 (51.22% of base) : 179690.dasm - System.Security.Cryptography.Pkcs.SignerInfo:FindAttributeIndexByOid(System.Security.Cryptography.Asn1.AttributeAsn[],System.Security.Cryptography.Oid,int):int
         293 (50.96% of base) : 92711.dasm - System.Xml.Xsl.IlGen.XmlILVisitor:VisitChoice(System.Xml.Xsl.Qil.QilChoice):System.Xml.Xsl.Qil.QilNode:this

Top method improvements (percentages):
         -36 (-10.14% of base) : 24021.dasm - System.Collections.Generic.GenericEqualityComparer`1:IndexOf(System.__Canon[],System.__Canon,int,int):int:this
         -32 (-9.61% of base) : 24016.dasm - System.Collections.Generic.ObjectEqualityComparer`1:IndexOf(System.__Canon[],System.__Canon,int,int):int:this
         -20 (-7.14% of base) : 192694.dasm - Internal.Cryptography.Helpers:FixupKeyParity(System.Byte[]):System.Byte[]
          -9 (-7.14% of base) : 150742.dasm - Microsoft.CodeAnalysis.CommonReferenceManager`2:CheckCircularReference(System.Collections.Generic.IReadOnlyList`1[Microsoft.CodeAnalysis.CommonReferenceManager`2+AssemblyReferenceBinding[System.__Canon, System.__Canon][]]):bool
          -8 (-7.02% of base) : 85767.dasm - System.Reflection.Internal.ObjectPool`1:Allocate():System.__Canon:this
         -16 (-6.20% of base) : 161256.dasm - System.Drawing.Drawing2D.PathGradientBrush:set_SurroundColors(System.Drawing.Color[]):this
         -11 (-4.78% of base) : 173459.dasm - Internal.TypeSystem.TypeSystemHelpers:RequiresSlotUnification(Internal.TypeSystem.MethodDesc):bool
          -6 (-3.66% of base) : 10430.dasm - Microsoft.CodeAnalysis.CSharp.Syntax.InternalSyntax.SyntaxList:List(Microsoft.CodeAnalysis.CSharp.Syntax.InternalSyntax.CSharpSyntaxNode[],int):Microsoft.CodeAnalysis.CSharp.Syntax.InternalSyntax.CSharpSyntaxNode
          -2 (-2.78% of base) : 33665.dasm - MultiElementAsyncLocalValueMap:TryGetValue(System.Threading.IAsyncLocal,byref):bool:this
          -2 (-2.67% of base) : 193636.dasm - System.Net.ContextFlagsAdapterPal:GetInteropFromContextFlagsPal(int):int
          -2 (-2.67% of base) : 83190.dasm - System.Net.ContextFlagsAdapterPal:GetInteropFromContextFlagsPal(int):int
          -2 (-2.67% of base) : 215902.dasm - System.Net.ContextFlagsAdapterPal:GetInteropFromContextFlagsPal(int):int
          -2 (-2.56% of base) : 205146.dasm - System.Net.ContextFlagsAdapterPal:GetInteropFromContextFlagsPal(int):int
         -10 (-1.86% of base) : 179730.dasm - System.Security.Cryptography.Pkcs.SignedCms:AddCertificate(System.Security.Cryptography.X509Certificates.X509Certificate2):this
          -5 (-1.65% of base) : 203938.dasm - Internal.Cryptography.Pal.ChainPal:GetChainStatusInformation(int):System.Security.Cryptography.X509Certificates.X509ChainStatus[]
          -6 (-1.36% of base) : 174027.dasm - Internal.TypeSystem.DefType:ComputeInstanceLayout(int):this
          -1 (-1.35% of base) : 215903.dasm - System.Net.ContextFlagsAdapterPal:GetContextFlagsPalFromInterop(int):int
          -1 (-1.35% of base) : 83191.dasm - System.Net.ContextFlagsAdapterPal:GetContextFlagsPalFromInterop(int):int
          -1 (-1.35% of base) : 193637.dasm - System.Net.ContextFlagsAdapterPal:GetContextFlagsPalFromInterop(int):int
         -10 (-1.34% of base) : 149598.dasm - Microsoft.CodeAnalysis.VersionHelper:TryParse(System.String,bool,ushort,byref):bool

103 total methods with Code Size differences (33 improved, 70 regressed), 8 unchanged.

```

</details>

--------------------------------------------------------------------------------

```

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 70371
Total bytes of diff: 77796
Total bytes of delta: 7425 (10.55% of base)
Total relative delta: 25.59
    diff is a regression.
    relative diff is a regression.
```
<details>

<summary>Detail diffs</summary>

```

Top file regressions (bytes):
         491 : 45068.dasm (69.55% of base)
         310 : 145953.dasm (43.79% of base)
         299 : 203675.dasm (61.40% of base)
         260 : 117169.dasm (43.12% of base)
         249 : 160923.dasm (66.58% of base)
         216 : 220005.dasm (74.23% of base)
         184 : 20289.dasm (127.78% of base)
         163 : 152884.dasm (76.53% of base)
         160 : 20380.dasm (21.22% of base)
         160 : 20410.dasm (70.18% of base)
         158 : 40560.dasm (15.24% of base)
         156 : 115022.dasm (11.76% of base)
         156 : 132472.dasm (41.71% of base)
         154 : 20309.dasm (105.48% of base)
         147 : 41852.dasm (76.17% of base)
         144 : 20362.dasm (50.35% of base)
         144 : 40912.dasm (41.14% of base)
         140 : 214346.dasm (24.39% of base)
         140 : 214409.dasm (24.39% of base)
         139 : 117168.dasm (73.54% of base)

Top file improvements (bytes):
         -71 : 208247.dasm (-6.07% of base)
         -42 : 117208.dasm (-0.83% of base)
         -26 : 161794.dasm (-10.36% of base)
         -23 : 20296.dasm (-9.24% of base)
         -23 : 20312.dasm (-9.24% of base)
         -23 : 20302.dasm (-9.39% of base)
         -23 : 20299.dasm (-9.16% of base)
         -22 : 20270.dasm (-13.17% of base)
         -22 : 20276.dasm (-13.17% of base)
         -22 : 20306.dasm (-6.43% of base)
         -20 : 216496.dasm (-6.94% of base)
         -17 : 148574.dasm (-0.33% of base)
         -15 : 49464.dasm (-0.54% of base)
         -15 : 8645.dasm (-2.91% of base)
         -11 : 35759.dasm (-6.25% of base)
         -10 : 20287.dasm (-7.04% of base)
          -8 : 151645.dasm (-7.69% of base)
          -5 : 144804.dasm (-0.35% of base)
          -5 : 221018.dasm (-1.40% of base)
          -5 : 161876.dasm (-0.70% of base)

123 total files with Code Size differences (36 improved, 87 regressed), 5 unchanged.

Top method regressions (bytes):
         491 (69.55% of base) : 45068.dasm - Microsoft.CodeAnalysis.CSharp.Symbols.Metadata.PE.PEPropertySymbol:GetParameters(Microsoft.CodeAnalysis.CSharp.Symbols.Metadata.PE.PEModuleSymbol,Microsoft.CodeAnalysis.CSharp.Symbols.Metadata.PE.PEPropertySymbol,Microsoft.CodeAnalysis.ParamInfo`1[Microsoft.CodeAnalysis.CSharp.Symbols.TypeSymbol][],Microsoft.CodeAnalysis.ParamInfo`1[Microsoft.CodeAnalysis.CSharp.Symbols.TypeSymbol][],byref):System.Collections.Immutable.ImmutableArray`1[[Microsoft.CodeAnalysis.CSharp.Symbols.ParameterSymbol, Microsoft.CodeAnalysis.CSharp, Version=1.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]
         310 (43.79% of base) : 145953.dasm - System.Xml.Xsl.IlGen.XmlILVisitor:VisitChoice(System.Xml.Xsl.Qil.QilChoice):System.Xml.Xsl.Qil.QilNode:this
         299 (61.40% of base) : 203675.dasm - System.Net.WebSockets.WebSocketBuffer:ValidateNativeBuffers(int,int,Interop+WebSocket+Buffer[],int):this
         260 (43.12% of base) : 117169.dasm - System.Data.Common.DbDataAdapter:UpdatedRowStatusErrors(System.Data.Common.RowUpdatedEventArgs,System.Data.Common.DbDataAdapter+BatchCommandInfo[],int):int:this
         249 (66.58% of base) : 160923.dasm - Internal.IL.EcmaMethodIL:GetExceptionRegions():Internal.IL.ILExceptionRegion[]:this
         216 (74.23% of base) : 220005.dasm - System.Security.Cryptography.Pkcs.SignerInfo:FindAttributeIndexByOid(System.Security.Cryptography.Asn1.AttributeAsn[],System.Security.Cryptography.Oid,int):int
         184 (127.78% of base) : 20289.dasm - System.Collections.Generic.NullableEqualityComparer`1[Byte][System.Byte]:IndexOf(System.Nullable`1[System.Byte][],System.Nullable`1[Byte],int,int):int:this
         163 (76.53% of base) : 152884.dasm - System.Speech.Internal.Synthesis.EngineSiteSapi:System.Speech.Internal.Synthesis.ISpEngineSite.AddEvents(System.Speech.Internal.Synthesis.SpeechEventSapi[],int):this
         160 (21.22% of base) : 20380.dasm - System.Collections.Generic.Dictionary`2[Byte,Nullable`1][System.Byte,System.Nullable`1[System.Int32]]:System.Collections.ICollection.CopyTo(System.Array,int):this
         160 (70.18% of base) : 20410.dasm - System.Collections.Generic.Dictionary`2[Byte,Nullable`1][System.Byte,System.Nullable`1[System.Int32]]:CopyTo(System.Collections.Generic.KeyValuePair`2[System.Byte,System.Nullable`1[System.Int32]][],int):this
         158 (15.24% of base) : 40560.dasm - Microsoft.CodeAnalysis.CSharp.Emit.CSharpDefinitionMap:CreateLocalSlotMap(Microsoft.CodeAnalysis.Emit.EditAndContinueMethodDebugInformation,System.Collections.Immutable.ImmutableArray`1[[Microsoft.CodeAnalysis.LocalInfo`1[[Microsoft.CodeAnalysis.CSharp.Symbols.TypeSymbol, Microsoft.CodeAnalysis.CSharp, Version=1.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]], Microsoft.CodeAnalysis, Version=1.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]):System.Collections.Immutable.ImmutableArray`1[EncLocalInfo]
         156 (11.76% of base) : 115022.dasm - System.Data.Select:CreateIndex():this
         156 (41.71% of base) : 132472.dasm - AttributeSorter:Sort():this
         154 (105.48% of base) : 20309.dasm - System.Collections.Generic.ObjectEqualityComparer`1[Vector`1][System.Numerics.Vector`1[System.Single]]:IndexOf(System.Numerics.Vector`1[System.Single][],System.Numerics.Vector`1[Single],int,int):int:this
         147 (76.17% of base) : 41852.dasm - Microsoft.CodeAnalysis.CSharp.Symbols.AnonymousTypeDescriptor:Equals(Microsoft.CodeAnalysis.CSharp.Symbols.AnonymousTypeDescriptor,bool,bool):bool:this
         144 (50.35% of base) : 20362.dasm - System.Collections.Generic.Dictionary`2[__Canon,Nullable`1][System.__Canon,System.Nullable`1[System.Int32]]:CopyTo(System.Collections.Generic.KeyValuePair`2[System.__Canon,System.Nullable`1[System.Int32]][],int):this
         144 (41.14% of base) : 40912.dasm - Microsoft.CodeAnalysis.CSharp.Symbols.AnonymousTypeManager:IsSameType(Microsoft.CodeAnalysis.CSharp.Symbols.TypeSymbol,Microsoft.CodeAnalysis.CSharp.Symbols.TypeSymbol,bool,bool):bool
         140 (24.39% of base) : 214346.dasm - System.Runtime.Caching.ExpiresBucket:Expand():this
         140 (24.39% of base) : 214409.dasm - System.Runtime.Caching.UsageBucket:Expand():this
         139 (73.54% of base) : 117168.dasm - System.Data.Common.DbDataAdapter:UpdatedRowStatusContinue(System.Data.Common.RowUpdatedEventArgs,System.Data.Common.DbDataAdapter+BatchCommandInfo[],int):int:this

Top method improvements (bytes):
         -71 (-6.07% of base) : 208247.dasm - System.Net.Security.SslStreamCertificateContext:.ctor(System.Security.Cryptography.X509Certificates.X509Certificate2,System.Security.Cryptography.X509Certificates.X509Certificate2[],System.Net.Security.SslCertificateTrust):this
         -42 (-0.83% of base) : 117208.dasm - System.Data.Common.DbDataAdapter:Update(System.Data.DataRow[],System.Data.Common.DataTableMapping):int:this
         -26 (-10.36% of base) : 161794.dasm - Internal.TypeSystem.TypeSystemHelpers:RequiresSlotUnification(Internal.TypeSystem.MethodDesc):bool
         -23 (-9.24% of base) : 20296.dasm - System.Collections.Generic.ObjectEqualityComparer`1[Byte][System.Byte]:IndexOf(System.Byte[],ubyte,int,int):int:this
         -23 (-9.24% of base) : 20312.dasm - System.Collections.Generic.ObjectEqualityComparer`1[Int64][System.Int64]:IndexOf(System.Int64[],long,int,int):int:this
         -23 (-9.39% of base) : 20302.dasm - System.Collections.Generic.ObjectEqualityComparer`1[Int32][System.Int32]:IndexOf(System.Int32[],int,int,int):int:this
         -23 (-9.16% of base) : 20299.dasm - System.Collections.Generic.ObjectEqualityComparer`1[Int16][System.Int16]:IndexOf(System.Int16[],short,int,int):int:this
         -22 (-13.17% of base) : 20270.dasm - System.Collections.Generic.GenericEqualityComparer`1[Byte][System.Byte]:IndexOf(System.Byte[],ubyte,int,int):int:this
         -22 (-13.17% of base) : 20276.dasm - System.Collections.Generic.GenericEqualityComparer`1[Int16][System.Int16]:IndexOf(System.Int16[],short,int,int):int:this
         -22 (-6.43% of base) : 20306.dasm - System.Collections.Generic.ObjectEqualityComparer`1[Double][System.Double]:IndexOf(System.Double[],double,int,int):int:this
         -20 (-6.94% of base) : 216496.dasm - Internal.Cryptography.Helpers:FixupKeyParity(System.Byte[]):System.Byte[]
         -17 (-0.33% of base) : 148574.dasm - System.Reflection.PortableExecutable.PEBuilder:WritePEHeader(System.Reflection.Metadata.BlobBuilder,System.Reflection.PortableExecutable.PEDirectoriesBuilder,System.Collections.Immutable.ImmutableArray`1[SerializedSection]):this
         -15 (-0.54% of base) : 49464.dasm - Microsoft.CodeAnalysis.VisualBasic.IteratorAndAsyncCaptureWalker:Analyze(Microsoft.CodeAnalysis.VisualBasic.FlowAnalysisInfo,Microsoft.CodeAnalysis.DiagnosticBag):Result
         -15 (-2.91% of base) : 8645.dasm - Microsoft.FSharp.Collections.ArrayModule:Zip(System.Byte[],System.Nullable`1[System.Int32][]):System.Tuple`2[System.Byte,System.Nullable`1[System.Int32]][]
         -11 (-6.25% of base) : 35759.dasm - Microsoft.CodeAnalysis.CSharp.Syntax.InternalSyntax.SyntaxList:List(Microsoft.CodeAnalysis.CSharp.Syntax.InternalSyntax.CSharpSyntaxNode[],int):Microsoft.CodeAnalysis.CSharp.Syntax.InternalSyntax.CSharpSyntaxNode
         -10 (-7.04% of base) : 20287.dasm - System.Collections.Generic.GenericEqualityComparer`1[Int64][System.Int64]:IndexOf(System.Int64[],long,int,int):int:this
          -8 (-7.69% of base) : 151645.dasm - System.Reflection.Internal.ObjectPool`1[__Canon][System.__Canon]:Allocate():System.__Canon:this
          -5 (-0.35% of base) : 144804.dasm - System.Xml.Xsl.Runtime.XmlQueryStaticData:GetObjectData(byref,byref):this
          -5 (-1.40% of base) : 221018.dasm - Internal.Cryptography.Pal.ChainPal:GetChainStatusInformation(int):System.Security.Cryptography.X509Certificates.X509ChainStatus[]
          -5 (-0.70% of base) : 161876.dasm - Internal.TypeSystem.MetadataVirtualMethodAlgorithm:ResolveInterfaceMethodToDefaultImplementationOnType(Internal.TypeSystem.MethodDesc,Internal.TypeSystem.MetadataType,byref):int

Top method regressions (percentages):
         184 (127.78% of base) : 20289.dasm - System.Collections.Generic.NullableEqualityComparer`1[Byte][System.Byte]:IndexOf(System.Nullable`1[System.Byte][],System.Nullable`1[Byte],int,int):int:this
         154 (105.48% of base) : 20309.dasm - System.Collections.Generic.ObjectEqualityComparer`1[Vector`1][System.Numerics.Vector`1[System.Single]]:IndexOf(System.Numerics.Vector`1[System.Single][],System.Numerics.Vector`1[Single],int,int):int:this
         108 (91.53% of base) : 115019.dasm - System.Data.Select:CompareClosestCandidateIndexDesc(System.Data.IndexField[]):int:this
         122 (81.88% of base) : 41851.dasm - Microsoft.CodeAnalysis.CSharp.Symbols.AnonymousTypeDescriptor:Equals(Microsoft.CodeAnalysis.CSharp.Symbols.AnonymousTypeDescriptor):bool:this
         163 (76.53% of base) : 152884.dasm - System.Speech.Internal.Synthesis.EngineSiteSapi:System.Speech.Internal.Synthesis.ISpEngineSite.AddEvents(System.Speech.Internal.Synthesis.SpeechEventSapi[],int):this
         147 (76.17% of base) : 41852.dasm - Microsoft.CodeAnalysis.CSharp.Symbols.AnonymousTypeDescriptor:Equals(Microsoft.CodeAnalysis.CSharp.Symbols.AnonymousTypeDescriptor,bool,bool):bool:this
          82 (74.55% of base) : 20283.dasm - System.Collections.Generic.GenericEqualityComparer`1[Vector`1][System.Numerics.Vector`1[System.Single]]:IndexOf(System.Numerics.Vector`1[System.Single][],System.Numerics.Vector`1[Single],int,int):int:this
         216 (74.23% of base) : 220005.dasm - System.Security.Cryptography.Pkcs.SignerInfo:FindAttributeIndexByOid(System.Security.Cryptography.Asn1.AttributeAsn[],System.Security.Cryptography.Oid,int):int
         139 (73.54% of base) : 117168.da…

* Simplify setting GTF_IND_NONFAULTING

3 years agoexclude UTF8 string marshallers from cg2 (#55624)
Manish Godse [Thu, 15 Jul 2021 03:22:41 +0000 (20:22 -0700)]
exclude UTF8 string marshallers from cg2 (#55624)

* exclude UTF8 and Unicode string marshallers from cg2

* keep unicodestringmarshaller

The non-pinned cases which are not supported will throw

* excluding one non-r2r case

All calls to InteropHelpers should now be under !READYTORUN

3 years ago[sgen] Transition to GC Unsafe in mono_gc_wait_for_bridge_processing (#55681)
Aleksey Kliger (λgeek) [Thu, 15 Jul 2021 03:12:52 +0000 (23:12 -0400)]
[sgen] Transition to GC Unsafe in mono_gc_wait_for_bridge_processing (#55681)

* [sgen] Transition to GC Unsafe in mono_gc_wait_for_bridge_processing

Mark it as an external only API.  In the runtime, use
mono_gc_wait_for_bridge_processing_internal.

3 years agoSimplify File.WriteAllTextAsync (#55644)
Stephen Toub [Thu, 15 Jul 2021 02:41:10 +0000 (22:41 -0400)]
Simplify File.WriteAllTextAsync (#55644)

Avoid the unnecessary ArrayPool usage and extra layer of buffering.

3 years agorework SocketsHttpHandler request queue handling for HTTP/1.1 and HTTP/2 (#53851)
Geoff Kizer [Thu, 15 Jul 2021 01:49:39 +0000 (18:49 -0700)]
rework SocketsHttpHandler request queue handling for HTTP/1.1 and HTTP/2 (#53851)

* rework SocketsHttpHandler request queue handling for HTTP/1.1 and HTTP/2

Co-authored-by: Geoffrey Kizer <geoffrek@windows.microsoft.com>
3 years agoHandle getting the address of an RVA static correctly in a composite image (#55301)
David Wrighton [Thu, 15 Jul 2021 01:04:02 +0000 (18:04 -0700)]
Handle getting the address of an RVA static correctly in a composite image (#55301)

* Handle getting the address of an RVA static correctly in a composite image
- Since composite images have the original RVA statics in the original files, use the value from there
- This required re-enabling the ability of getFieldAddress to return an indirection
- And adding some new processing for the fixup as needed
* Silence pointless assert
- There is an assert around incorrect handling of byref pointers, that isn't right. It fails for various issues with the Unsafe.* apis under jit stress, and this change makes it occur during one of our regular builds. As this is just an assert firing when it isn't appropriate, I'm disabling the warning as suggested by the JIT team.

3 years agoUse XmlWriter.Create instead of XmlTextWriter (#54949)
Steve Molloy [Thu, 15 Jul 2021 01:01:07 +0000 (18:01 -0700)]
Use XmlWriter.Create instead of XmlTextWriter (#54949)

* Use a different XmlWriter which will check for invalid characters like null.

* Bring our XmlReader use into the 21st century as well.

* Update src/libraries/System.Private.Xml/src/System/Xml/Serialization/XmlSerializer.cs

Co-authored-by: Stephen Toub <stoub@microsoft.com>
* Update src/libraries/System.Private.Xml/src/System/Xml/Serialization/XmlSerializer.cs

Co-authored-by: Stephen Toub <stoub@microsoft.com>
* Update src/libraries/System.Private.Xml/src/System/Xml/Serialization/XmlSerializer.cs

Co-authored-by: Stephen Toub <stoub@microsoft.com>
* Don't need to specify options that are defaults on XmlWriter.

Co-authored-by: Stephen Toub <stoub@microsoft.com>
3 years agoSurgical fix for bad assertion generation (#55626)
SingleAccretion [Thu, 15 Jul 2021 00:37:14 +0000 (03:37 +0300)]
Surgical fix for bad assertion generation (#55626)

* Add a test

* Surgical fix for bad assertion generation

Say we have a cast like this: CAST(uint <- long).
What value does this tree compute?
[int.MinValue..int.MaxValue] - IR operates on signed TYP_INTs.
But assertion prop generated [0..uint.MaxValue] for it.

The confusion created by this "how to interpret TYP_UINT" question
caused a bug where for the assertion generated for the above cast,
in the form of [0..uint.MaxValue], propagation could remove
a checked cast in the form of CAST_OVF(uint < int).

The proper fix is to generate proper ranges for such casts.

The surgical fix proposed here is to always treat casts to TYP_UINT
as if they were to TYP_INT. This is conservative, but always correct.
The generated assertion is useless of course, but that makes this a
zero-diff change.

* Add a comment explaining the quirk

3 years agoRemove unnecessary reflection in Environment.GetFolderPathCore.Unix.cs (#55677)
Alexander Köplinger [Thu, 15 Jul 2021 00:18:08 +0000 (02:18 +0200)]
Remove unnecessary reflection in Environment.GetFolderPathCore.Unix.cs (#55677)

System.IO.Directory was moved into CoreLib with https://github.com/dotnet/runtime/pull/53231 so we can call it directly now.

3 years agoAdd CollectionsMarshal.GetValueRefOrAddDefault (#54611)
Sergio Pedri [Thu, 15 Jul 2021 00:02:16 +0000 (02:02 +0200)]
Add CollectionsMarshal.GetValueRefOrAddDefault (#54611)

3 years agoProcess.Start() failure should include path (#46417)
Bastian Schmidt [Wed, 14 Jul 2021 23:47:40 +0000 (01:47 +0200)]
Process.Start() failure should include path (#46417)

* Adding ProcessStartException

* Reverting ProcessStartException

* First version

* Fixing merge issue

* Using interop call instead of intermediate exception to get error msg

* Fixing typo

* Change checks for exception message

* Update src/libraries/System.Diagnostics.Process/src/System/Diagnostics/Process.cs

Co-authored-by: Adam Sitnik <adam.sitnik@gmail.com>
* Update src/libraries/System.Diagnostics.Process/src/System/Diagnostics/Process.Unix.cs

Co-authored-by: Adam Sitnik <adam.sitnik@gmail.com>
* Using common method to create exception and updating error message

* Fixing merge mistake

* Using AssertExtensions.ThrowsContains

* Fixing code for unix

* Address PR feedback

* Apply suggestions from code review

Co-authored-by: Stephen Toub <stoub@microsoft.com>
* Fix ErrorInfo type reference

Co-authored-by: Adam Sitnik <adam.sitnik@gmail.com>
Co-authored-by: Jeff Handley <jeff.handley@microsoft.com>
Co-authored-by: Jeff Handley <jeffhandley@users.noreply.github.com>
Co-authored-by: Stephen Toub <stoub@microsoft.com>
3 years agoDon't validate signature for _VTblGap* methods (#55616)
Elinor Fung [Wed, 14 Jul 2021 23:30:31 +0000 (16:30 -0700)]
Don't validate signature for _VTblGap* methods (#55616)

3 years agoFix building S.S.Cryptography.Native with cmake 3.6.2
Kevin Jones [Wed, 14 Jul 2021 22:06:29 +0000 (18:06 -0400)]
Fix building S.S.Cryptography.Native with cmake 3.6.2

This uses our add_linker_flag function for adding linker flags instead
of add_link_options which is only available in newer cmake versions.

3 years ago"==0" optimization in Boolean logic #13573 (#49548)
Julie Lee [Wed, 14 Jul 2021 21:53:09 +0000 (14:53 -0700)]
"==0" optimization in Boolean logic #13573 (#49548)

* Equals to 0 optimization in Boolean logic

* Limit bool optimization to Integral return type only

* Use the updated flowList:setEdgeWeights method with the 3rd parameter

* Skip bool optimization for cases that require NOT transformation

* Skip bool optimization when the third block GT_RETURN is not CNT_INT int

* format patch

* Added more bool optimization cases

* format patch

* Refactored setting fold type and comparison type to fix jitstress error

* format patch

* Refactored common codes for conditional block and return block boolean optimizations

* format patch

* Unit test changed to remove EH handling and add return value checks

* Unit test: add back test cases for ANDing and NE cases

* Made OptBoolsDsc struct to pass it off to the helper methods.

* format patch

* Changed to substructure OptTestInfo within OptBoolsDisc

* Cleaned up tree variables in OptBoolsDsc struct

* Moved some methods for Boolean Optimization to OptBoolsDsc struct

* Moved all private methods for Boolean Optimization to OptBoolsDsc struct

* Boolean Optimization: Handled code review feedback

* Optimize bools: hoisted jump destination check to optOptimizeBools() and added test cases

* format patch

* Moved initialization to OptBoolsDsc constructor

* format patch

Co-authored-by: Julie Lee <jeonlee@microsoft.com>
3 years agoAdd property ordering to source gen (#55662)
Steve Harter [Wed, 14 Jul 2021 21:32:40 +0000 (16:32 -0500)]
Add property ordering to source gen (#55662)

3 years agoAdd tests for generic types/values with the Marshal APIs (#55533)
Jeremy Koritzinsky [Wed, 14 Jul 2021 20:40:34 +0000 (13:40 -0700)]
Add tests for generic types/values with the Marshal APIs (#55533)

3 years agoRemove a few duplicated S.R.InteropServices tests (#55650)
Stephen Toub [Wed, 14 Jul 2021 19:44:14 +0000 (15:44 -0400)]
Remove a few duplicated S.R.InteropServices tests (#55650)

3 years agoRemove char[] allocation from UniqueId.ToString() (#55652)
Stephen Toub [Wed, 14 Jul 2021 19:42:40 +0000 (15:42 -0400)]
Remove char[] allocation from UniqueId.ToString() (#55652)

3 years agoUpdate comments on RequiresAssemblyFiles (#55675)
Tlakaelel Axayakatl Ceja [Wed, 14 Jul 2021 19:23:32 +0000 (12:23 -0700)]
Update comments on RequiresAssemblyFiles (#55675)

The setter of the Message property in RequiresAssemblyFiles was removed, updating the documentation to reflect that change

3 years agoRequire CFB8 for persisted CNG keys in CFB mode
Kevin Jones [Wed, 14 Jul 2021 19:22:10 +0000 (15:22 -0400)]
Require CFB8 for persisted CNG keys in CFB mode

This changes AesCng and TripleDESCng to require the feedback size to be
set to '8' when in CFB mode and using a persisted CNG key.

Prior to this change, BasicSymmetricCipherNCrypt ignored the feedback
size which resulted in CFB8 always being used, even if the FeedbackSize
was set to another value. However, when padding was applied, the padding
size would be padded to the feedback size. In the case of AesCng, this
would mean it would be encrypted with CFB8 and padded as if it were
CFB128.

This changes the implementation so that the feedback size is required
to be set to 8 for persisted keys. No change is made for ephemeral keys.

3 years agoremove Steve as the os-mac-os-x owner (#55671)
Jeff Schwartz [Wed, 14 Jul 2021 19:15:55 +0000 (12:15 -0700)]
remove Steve as the os-mac-os-x owner (#55671)

3 years agoUnify Requires Attribute (#55622)
Tlakaelel Axayakatl Ceja [Wed, 14 Jul 2021 19:09:16 +0000 (12:09 -0700)]
Unify Requires Attribute (#55622)

Add an overload to RequiresAssemblyFiles to be able to have the same user experience as if using RequiresUnreferencedCode

3 years agoOverride the APM methods on AsyncWindowsFileStreamStrategy. (#55203)
Theodore Tsirpanis [Wed, 14 Jul 2021 19:01:43 +0000 (22:01 +0300)]
Override the APM methods on AsyncWindowsFileStreamStrategy. (#55203)

* Override the APM methods on AsyncWindowsFileStreamStrategy.

Closes #55172.

* Address PR feedback.

* Update src/libraries/System.Private.CoreLib/src/System/IO/Strategies/AsyncWindowsFileStreamStrategy.cs

* Update AsyncWindowsFileStreamStrategy.cs

Co-authored-by: Stephen Toub <stoub@microsoft.com>
3 years agoDisable some System.Drawing.Common tests failing on Windows Mono (#55656)
Alexander Köplinger [Wed, 14 Jul 2021 18:51:25 +0000 (20:51 +0200)]
Disable some System.Drawing.Common tests failing on Windows Mono (#55656)

After https://github.com/dotnet/runtime/pull/54884 these tests started failing on Mono on Windows, see https://github.com/dotnet/runtime/issues/55655.

3 years ago[wasm][debugger] Implement support to DebuggerDisplay attribute (#55524)
Thays Grazia [Wed, 14 Jul 2021 18:24:33 +0000 (11:24 -0700)]
[wasm][debugger] Implement support to DebuggerDisplay attribute (#55524)

* Support DebuggerDisplay attribute on type.

* Implementing DebuggerDisplay calling methods.

* Apply suggestions from code review

Co-authored-by: Larry Ewing <lewing@microsoft.com>
* Fixing snake case.

* Changing snake case.

Co-authored-by: Larry Ewing <lewing@microsoft.com>
3 years agoHTTP/3 GET Aborted stress scenario fix (#55582)
Natalia Kondratyeva [Wed, 14 Jul 2021 18:11:16 +0000 (20:11 +0200)]
HTTP/3 GET Aborted stress scenario fix (#55582)

This adds checks for HTTP/3 specific exceptions to GET Aborted scenario

3 years agoImplement JitInfo API (#55046)
John Salem [Wed, 14 Jul 2021 17:47:10 +0000 (10:47 -0700)]
Implement JitInfo API (#55046)

3 years agoPlace the CMake command line cache file in the intermediates dir instead of the outpu...
Jeremy Koritzinsky [Wed, 14 Jul 2021 17:44:24 +0000 (10:44 -0700)]
Place the CMake command line cache file in the intermediates dir instead of the output dir (#55587)

Fixes an issue where deleting the intermediates folder locally would get the build in a bad state where the command-line check would be up to date but the CMake files would not be generated.

3 years agoUse GitHub issue form for API suggestions (#55659)
Immo Landwerth [Wed, 14 Jul 2021 17:41:46 +0000 (10:41 -0700)]
Use GitHub issue form for API suggestions (#55659)

3 years agoCorrectly skip PosixSignalRegistrationTests on mobile (#55643)
Alexander Köplinger [Wed, 14 Jul 2021 17:04:48 +0000 (19:04 +0200)]
Correctly skip PosixSignalRegistrationTests on mobile (#55643)

https://github.com/dotnet/runtime/pull/55569 didn't fix the issue since xunit retrieves the MemberData and checks for non-empty *before* evaluating the ConditionalTheory condition.

3 years agoRaise the max size poolable by ArrayPool (#55621)
Stephen Toub [Wed, 14 Jul 2021 15:33:50 +0000 (11:33 -0400)]
Raise the max size poolable by ArrayPool (#55621)

We previously set an arbitrary cut-off of 2MB max array size. That was before we would trim arrays in response to memory pressure.  This now raises the limit as high as we can while maintaining the current power-of-two-based scheme.

3 years agoenable working websocket subprotocol test
Pavel Savara [Wed, 14 Jul 2021 15:10:20 +0000 (17:10 +0200)]
enable working websocket subprotocol test

3 years agoMigrate various parts of the bindings code to use roots (#55530)
Katelyn Gadd [Wed, 14 Jul 2021 14:54:04 +0000 (07:54 -0700)]
Migrate various parts of the bindings code to use roots (#55530)

We have a lot of code that passes raw pointers to managed objects around when they should really be using roots instead (i.e. root.value) so that if the GC relocates the object, they won't be using the old address. This PR migrates a bunch of that code so that it uses root objects.

A lot of code remains that does use raw objects, but I read over all of it and the cases appear to be safe because they immediately return it (or return it without calling any other functions).

3 years ago[wasm] Run `Wasm.Build.Tests` against workloads (#54451)
Ankit Jain [Wed, 14 Jul 2021 14:47:03 +0000 (10:47 -0400)]
[wasm] Run `Wasm.Build.Tests` against workloads (#54451)

Co-authored-by: Larry Ewing <lewing@microsoft.com>
3 years agoTurn on loc PRs (#54293)
Jon Fortescue [Wed, 14 Jul 2021 14:26:52 +0000 (07:26 -0700)]
Turn on loc PRs (#54293)

* Turn on loc PRs

* oops

Co-authored-by: Jeremy Koritzinsky <jkoritzinsky@gmail.com>
* Keep OneLocBuild running only in main

Co-authored-by: Jeremy Koritzinsky <jkoritzinsky@gmail.com>
3 years agoDisable Http2_MultipleConnectionsEnabled_ConnectionLimitNotReached_ConcurrentRequests...
Alexander Nikolaev [Wed, 14 Jul 2021 14:05:27 +0000 (16:05 +0200)]
Disable Http2_MultipleConnectionsEnabled_ConnectionLimitNotReached_ConcurrentRequestsSuccessfullyHandled

Reverts #55572. The test is still failing.

3 years ago[QUIC] Cosmetic changes to Read pipeline (#55591)
Natalia Kondratyeva [Wed, 14 Jul 2021 14:00:44 +0000 (16:00 +0200)]
[QUIC] Cosmetic changes to Read pipeline (#55591)

Follow-up for NITs and cosmetic changes from #55505

3 years ago[mono][wasm] Mark memcpy LLVM instructions as volatile when they are used to copy...
Zoltan Varga [Wed, 14 Jul 2021 13:45:04 +0000 (09:45 -0400)]
[mono][wasm] Mark memcpy LLVM instructions as volatile when they are used to copy (#55598)

valuetypes containing references. This is needed to make sure llvm keeps the valuetypes
on the C stack for GC tracking.

Fixes random crashes when running the System.Collections.NonGeneric testsuite.

3 years agoAdd ArgumentNullException.ThrowIfNull (#55594)
Stephen Toub [Wed, 14 Jul 2021 13:12:09 +0000 (09:12 -0400)]
Add ArgumentNullException.ThrowIfNull (#55594)

3 years ago[mono][wasm] Avoid compiling llvm bitcode files with -emit-llvm. (#55630)
Zoltan Varga [Wed, 14 Jul 2021 12:53:09 +0000 (08:53 -0400)]
[mono][wasm] Avoid compiling llvm bitcode files with -emit-llvm. (#55630)

It causes the output to be a bitcode file as well, which is
passed to the emscripten link step, which will compile it
to wasm sequentially, slowing down linking.

Fixes https://github.com/dotnet/runtime/issues/54935.

3 years agoremove superfluous comment (#55634)
Eirik Tsarpalis [Wed, 14 Jul 2021 12:32:27 +0000 (15:32 +0300)]
remove superfluous comment (#55634)

Fix #55389

3 years ago[wasm] [debugger] Support method calls (#55458)
Thays Grazia [Wed, 14 Jul 2021 12:13:46 +0000 (05:13 -0700)]
[wasm] [debugger] Support method calls  (#55458)

* Implement method calls and method calls with simple parameters.

* removing useless change.

* Support const char.
Support object.

* Adding more tests as suggested by @pavelsavara.

* Adding a test calling a method that returns void and change an attribute value.

* Changing what @pavelsavara suggested.

* Fix merge.

3 years ago[debugger] Fix debugging after hot reloading (#55599)
Thays Grazia [Wed, 14 Jul 2021 12:13:32 +0000 (05:13 -0700)]
[debugger] Fix debugging after hot reloading (#55599)

* Fix deug after hotreload.

* do not change mono.proj

* fix formatting.

* Remove extra space.

3 years agoInliner: Extend IL limit for profiled call-sites, allow inlining for switches. (...
Egor Bogatov [Wed, 14 Jul 2021 11:01:14 +0000 (14:01 +0300)]
Inliner: Extend IL limit for profiled call-sites, allow inlining for switches. (#55478)

3 years agoDiagnosticSourceEventSource supports base class properties (#55613)
Noah Falk [Wed, 14 Jul 2021 10:29:04 +0000 (03:29 -0700)]
DiagnosticSourceEventSource supports base class properties (#55613)

Fixes #41300

Previously DiagnosticSourceEventSource would only iterate and recognize properties that were declared on the most derived type.
Now it can capture properties that were inherited from a base class too.

3 years ago[mono] Fix race during mono_image_storage_open (#55201)
Ulrich Weigand [Wed, 14 Jul 2021 09:52:27 +0000 (11:52 +0200)]
[mono] Fix race during mono_image_storage_open (#55201)

3 years ago[mono] Add wrapper info for native func wrappers. (#55602)
Zoltan Varga [Wed, 14 Jul 2021 09:07:37 +0000 (05:07 -0400)]
[mono] Add wrapper info for native func wrappers. (#55602)

Fixes https://github.com/dotnet/runtime/issues/55567.

3 years agoH/3 and Quic AppContext switch (#55332)
Marie Píchová [Wed, 14 Jul 2021 07:19:45 +0000 (09:19 +0200)]
H/3 and Quic AppContext switch (#55332)

* Renamed AllowDraftHttp3 to AllowHttp3AndQuic app context switch

* Usage of AllowHttp3AndQuic switch in S.N.Quic and enabling it in tests

* Renamed AppContext switch to Http3Support

3 years agoCompression.ZipFile support for Unix Permissions (#55531)
Eric Erhardt [Wed, 14 Jul 2021 04:14:24 +0000 (23:14 -0500)]
Compression.ZipFile support for Unix Permissions (#55531)

* Compression.ZipFile support for Unix Permissions

When running on Unix, capture the file's permissions on ZipFile Create and write the captured file permissions on ZipFile Extract.

Fix #1548

3 years ago[mono] Fix skipping of static methods during IMT table construction. (#55610)
Zoltan Varga [Wed, 14 Jul 2021 04:12:14 +0000 (00:12 -0400)]
[mono] Fix skipping of static methods during IMT table construction. (#55610)

Fixes https://github.com/dotnet/runtime/issues/55375.

3 years agoCombine System.Private.Xml TrimmingTests projects (#55606)
Eric Erhardt [Wed, 14 Jul 2021 03:14:39 +0000 (22:14 -0500)]
Combine System.Private.Xml TrimmingTests projects (#55606)

For some reason we have 2 of them, and only need 1.

3 years agofix name conflict with Configuration class (#55597)
Geoff Kizer [Wed, 14 Jul 2021 01:36:43 +0000 (18:36 -0700)]
fix name conflict with Configuration class (#55597)

Co-authored-by: Geoffrey Kizer <geoffrek@windows.microsoft.com>
3 years agoFinish migrating RSAOpenSsl from RSA* to EVP_PKEY*
Jeremy Barton [Wed, 14 Jul 2021 01:20:19 +0000 (18:20 -0700)]
Finish migrating RSAOpenSsl from RSA* to EVP_PKEY*

This change moves the RSAOpenSsl class (and the RSA.Create() internal class on Linux) to use EVP_PKEY
for the import and export operations, making the interaction with the underlying library based on
PKCS#8 PrivateKeyInfo and X.509 SubjectPublicKeyInfo key blobs.

A large portion of the code is just from splitting the key helpers files to not need all of the encrypted PKCS#8 support
in the System.Security.Cryptography.OpenSsl library, as the encrypted PKCS#8 <-> unencrypted PKCS#8 work provided
by the base classes is sufficient.

Once PKCS#8 and SPKI became the primary modes of interaction the spanified import and export routines for those got
overridden in RSAOpenSsl to avoid SPKI->RSAParameters->SPKI-style conversions.

This change completely eliminates SafeRsaHandle, and the only time that an `RSA*` is used at all is in the legacy RSAOpenSsl(IntPtr) constructor.

3 years agoDisable generic math (#55540)
Tanner Gooding [Wed, 14 Jul 2021 00:34:26 +0000 (17:34 -0700)]
Disable generic math (#55540)

3 years agoObsolete CryptoConfig.EncodeOID (#55592)
Kevin Jones [Wed, 14 Jul 2021 00:16:54 +0000 (20:16 -0400)]
Obsolete CryptoConfig.EncodeOID (#55592)

3 years agoAddress System.Net.Http.WinHttpHandler's nullable warnings targeting .NETCoreApp...
Huo Yaoyuan [Wed, 14 Jul 2021 00:11:58 +0000 (08:11 +0800)]
Address System.Net.Http.WinHttpHandler's nullable warnings targeting .NETCoreApp (#54995)

* Update nullability for WinHttpHandler

* Update project file

* Use ! for PtrToStringUni

* Move assertion of _sessionHandle

* Remove false assertion about RequestHandle.

3 years agoEnable Http2_MultipleConnectionsEnabled_ConnectionLimitNotReached_ConcurrentRequestsS...
Alexander Nikolaev [Wed, 14 Jul 2021 00:10:52 +0000 (02:10 +0200)]
Enable Http2_MultipleConnectionsEnabled_ConnectionLimitNotReached_ConcurrentRequestsSuccessfullyHandled (#55572)

* Enable Http2_MultipleConnectionsEnabled_ConnectionLimitNotReached_ConcurrentRequestsSuccessfullyHandled

* Update SocketsHttpHandlerTest.cs

3 years agoFix Task.WhenAny failure mode when passed ICollection of zero tasks (#55580)
Stephen Toub [Wed, 14 Jul 2021 00:10:24 +0000 (20:10 -0400)]
Fix Task.WhenAny failure mode when passed ICollection of zero tasks (#55580)

3 years agoConsume DistributedContextPropagator in DiagnosticsHandler (#55392)
Miha Zupan [Tue, 13 Jul 2021 23:44:57 +0000 (16:44 -0700)]
Consume DistributedContextPropagator in DiagnosticsHandler (#55392)

3 years agoAdd property ordering feature (#55586)
Steve Harter [Tue, 13 Jul 2021 22:40:28 +0000 (17:40 -0500)]
Add property ordering feature (#55586)

3 years agoReduce subtest count in Reflection (#55537)
Dan Moseley [Tue, 13 Jul 2021 22:33:32 +0000 (16:33 -0600)]
Reduce subtest count in Reflection (#55537)

* Reduce reflection subtest count

* typo

3 years agoDo PGO restore as part of PGO path lookup. (#55584)
Jeremy Koritzinsky [Tue, 13 Jul 2021 22:26:47 +0000 (15:26 -0700)]
Do PGO restore as part of PGO path lookup. (#55584)

3 years agoOpen types can exist as entries in interface map (#55372)
David Wrighton [Tue, 13 Jul 2021 22:25:10 +0000 (15:25 -0700)]
Open types can exist as entries in interface map (#55372)

* Open types can exist as entries in interface map
- While invalid via the ECMA spec, the runtime currently represents a type explicitly instantiated over its own generic type parameters via the open type MethodTable
- This is not strictly correct, as per the spec, these should be represented via an instantiated type, but changing that detail at this time is considered highly risky
- This conflicts with the perf optimization around partialy interface loading which uses the open type of an interface to represent a type instantiated in the curiously recurring fashion.
- The fix is to detect types instantiated over generic variables, and make them ineligible for the optimization, and to detect those cases where the optimization is ineligible, and revert back to the non-optimized behavior

Fixes #55323

3 years agoAvoid declaring an object cannot fit in a segment if we already have committed space...
Andrew Au [Tue, 13 Jul 2021 22:10:34 +0000 (15:10 -0700)]
Avoid declaring an object cannot fit in a segment if we already have committed space for it (#55585)

3 years agoRecognize MacCatalyst as a superset of iOS (#55550)
Jeff Handley [Tue, 13 Jul 2021 21:33:41 +0000 (14:33 -0700)]
Recognize MacCatalyst as a superset of iOS (#55550)

Recognize MacCatalyst as a superset of iOS and apply platform guard attributes that will inform the analyzer of the relationship.

3 years agoFix length check for Regex BOL FindFirstChar optimization (#55574)
Stephen Toub [Tue, 13 Jul 2021 21:10:18 +0000 (17:10 -0400)]
Fix length check for Regex BOL FindFirstChar optimization (#55574)

For a beginning-of-line anchor, in FindFirstChar we use IndexOf to quickly skip ahead to the next \n.  But we neglected to check to see whether that brought us past an explicitly specified end position.  This just adds the missing check.

3 years agoRemove IL2050 in System.Management (#54810)
Andrii Kurdiumov [Tue, 13 Jul 2021 20:47:02 +0000 (02:47 +0600)]
Remove IL2050 in System.Management (#54810)

* Remove IL2050 in System.Management
Remove unused functions which trigger IL2050
As per discussed in #54317

* Fix location of variables

3 years agoRemove IL205 warning for System.Data.Odbc (#54809)
Andrii Kurdiumov [Tue, 13 Jul 2021 20:44:03 +0000 (02:44 +0600)]
Remove IL205 warning for System.Data.Odbc (#54809)

Function which produce warning not used anywhere

3 years ago[mono] Fix loader incompatibility w.r.t. Resolving event (#54815)
Ulrich Weigand [Tue, 13 Jul 2021 20:42:47 +0000 (22:42 +0200)]
[mono] Fix loader incompatibility w.r.t. Resolving event (#54815)

* When loading a non-satellite assembly into a non-default ALC,
  invoke the Resolving event in the default ALC first.

* Fixes https://github.com/dotnet/runtime/issues/54814

3 years ago[QUIC] Move ByteMixingOrNativeAVE_MinimalFailingTest to OuterLoop (#55595)
Natalia Kondratyeva [Tue, 13 Jul 2021 20:38:24 +0000 (22:38 +0200)]
[QUIC] Move ByteMixingOrNativeAVE_MinimalFailingTest to OuterLoop (#55595)

Fixes #55588

3 years agoAdd runtime property HOSTFXR_PATH (#55369)
Mateo Torres-Ruiz [Tue, 13 Jul 2021 20:16:29 +0000 (13:16 -0700)]
Add runtime property HOSTFXR_PATH (#55369)

* Add property HOSTFXR_PATH

* Comment

* PR feedback

* Use get_own_module_path since we are on hostfxr

* Dispose FileStream

3 years agoRemove EventSourceActivity (#55575)
hrrrrustic [Tue, 13 Jul 2021 19:53:12 +0000 (22:53 +0300)]
Remove EventSourceActivity (#55575)

* remove file

* remove a few references to deleted file

* fix corelib

3 years agoSimplify PosixSignalRegistration implementation on Unix (#55552)
Stephen Toub [Tue, 13 Jul 2021 19:39:47 +0000 (15:39 -0400)]
Simplify PosixSignalRegistration implementation on Unix (#55552)

* Simplify PosixSignalRegistration implementation on Unix

Bring it onto the same scheme as the Windows implementation.

* Address PR feedback

* Delete more dead code

* Update PosixSignalRegistration.Unix.cs