Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[arm64] JIT: Enable CSE/hoisting for "arrayBase + elementOffset" #61293

Merged
merged 22 commits into from
Nov 10, 2021

Conversation

EgorBo
Copy link
Member

@EgorBo EgorBo commented Nov 7, 2021

Closes #35618, #34810

Usually, for a typical array access we create the following tree

arrRef + (index + elemOffset)

which is basically invariant1 + (X + invariant2), if we change it to:

(arrRef + elemOffset) + index

I assume it's safe from GC's point of view, both ADDs are byref and within the objects

we'll be able to hoist/CSE the invariant part arrRef + elemOffset on arm/arm64. We don't really need it on XArch because it will be handled by a more powerful addressing mode such as mov r9d, dword ptr [rdx+4*r9+16].
So, essentially, this PR changes morphing of GT_INDEX like this:

image

UPD Also, this PR folds LEA(BFIZ) into load/store with scale and sign/zero extension.

Example:

int Test(int[] array, int i, int j) 
    => array[i] + array[j];

int Sum(int[] array)
{
    int sum = 0;
    foreach (int item in array)
        sum += item;
    return sum;
}

codegen diff:

; Method Tests:Test(System.Int32[],int,int):int:this
G_M15096_IG01:
            stp     fp, lr, [sp,#-16]!
            mov     fp, sp
G_M15096_IG02:
            ldr     w0, [x1,#8]
            cmp     w2, w0
            bhs     G_M15096_IG04
-           ubfiz   x2, x2, #2, #32
            add     x2, x2, #16
-           ldr     w2, [x1, x2]
+           ldr     w2, [x1, w2, UXTW #2]
            cmp     w3, w0
            bhs     G_M15096_IG04
-           ubfiz   x0, x3, #2, #32
-           add     x0, x0, #16     ;; CSE'd
-           ldr     w0, [x1, x0]
+           ldr     w0, [x1, w3, UXTW #2]
            add     w0, w2, w0
G_M15096_IG03:
            ldp     fp, lr, [sp],#16
            ret     lr
G_M15096_IG04:
            bl      CORINFO_HELP_RNGCHKFAIL
            bkpt    
-; Total bytes of code: 72
+; Total bytes of code: 60


; Method Tests:Sum(System.Int32[]):int:this
G_M56165_IG01:
            stp     fp, lr, [sp,#-16]!
            mov     fp, sp
G_M56165_IG02:
            mov     w0, wzr
            mov     w2, wzr
            ldr     w3, [x1,#8]
            cmp     w3, #0
            ble     G_M56165_IG04
+           add     x1, x1, #16    ;; 'baseRef + elemOffset' is hoisted
G_M56165_IG03:
-           ubfiz   x4, x2, #2, #32
-           add     x4, x4, #16
-           ldr     w4, [x1, x4]    ;; -2 4byte instructions from the loop body, it has now a perfect codegen
+           ldr     w4, [x1, w2, UXTW #2]
            add     w0, w0, w4
            add     w2, w2, #1
            cmp     w3, w2
            bgt     G_M56165_IG03
G_M56165_IG04:
            ldp     fp, lr, [sp],#16
            ret     lr
-; Total bytes of code: 64
+; Total bytes of code: 60

Benchmark: "Sum all elements in an array":

[Benchmark]
[ArgumentsSource(nameof(TestData))]
public int Sum(int[] array)
{
    int sum = 0;
    foreach (int t in array)
        sum += t;
    return sum;
}

Benchmark results on Apple M1 arm64:

                             | Method |         array |     Mean |    Error |
                             |------- |-------------- |---------:|---------:|
Main without #61045 + #61035 |    Sum | Int32[100000] | 60,08 us | 0.015 us | .NET 6.0 codegen
                Current Main |    Sum | Int32[100000] | 53.78 us | 0.007 us |
                     This PR |    Sum | Int32[100000] | 32.61 us | 0.082 us | ~2x faster than .NET 6.0 here

^ tested with and without loop-alignment

Codegen diff:

Diffs are big but in both - and + directions:

benchmarks.run.windows.arm64.checked.mch:


Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 7603860 (overridden on cmd)
Total bytes of diff: 7582960 (overridden on cmd)
Total bytes of delta: -20900 (-0.27 % of base)
    diff is an improvement.
    relative diff is an improvement.
Detail diffs


Top file regressions (bytes):
          48 : 1745.dasm (2.82% of base)
          48 : 3317.dasm (2.86% of base)
          48 : 6982.dasm (2.12% of base)
          36 : 829.dasm (3.00% of base)
          32 : 19120.dasm (8.33% of base)
          28 : 8405.dasm (2.06% of base)
          24 : 21759.dasm (1.59% of base)
          24 : 18601.dasm (7.79% of base)
          24 : 6662.dasm (6.00% of base)
          24 : 14412.dasm (1.42% of base)
          24 : 8565.dasm (2.90% of base)
          20 : 1037.dasm (4.46% of base)
          16 : 11927.dasm (3.10% of base)
          16 : 2104.dasm (1.38% of base)
          16 : 416.dasm (2.35% of base)
          16 : 6641.dasm (1.98% of base)
          16 : 1734.dasm (2.20% of base)
          12 : 12997.dasm (0.54% of base)
          12 : 16129.dasm (5.88% of base)
          12 : 3046.dasm (3.37% of base)

Top file improvements (bytes):
        -660 : 3506.dasm (-6.48% of base)
        -520 : 19287.dasm (-8.86% of base)
        -512 : 12906.dasm (-12.77% of base)
        -508 : 23202.dasm (-8.34% of base)
        -504 : 15238.dasm (-8.21% of base)
        -500 : 13550.dasm (-2.09% of base)
        -484 : 21964.dasm (-8.85% of base)
        -436 : 14847.dasm (-11.83% of base)
        -344 : 2494.dasm (-1.85% of base)
        -324 : 1245.dasm (-4.29% of base)
        -324 : 2715.dasm (-3.20% of base)
        -324 : 11506.dasm (-3.20% of base)
        -248 : 19341.dasm (-4.62% of base)
        -248 : 21403.dasm (-2.68% of base)
        -244 : 6643.dasm (-1.40% of base)
        -240 : 12513.dasm (-5.37% of base)
        -236 : 2714.dasm (-2.38% of base)
        -236 : 22578.dasm (-2.41% of base)
        -220 : 18295.dasm (-3.24% of base)
        -220 : 11505.dasm (-3.13% of base)

1220 total files with Code Size differences (1136 improved, 84 regressed), 368 unchanged.

Top method regressions (bytes):
          48 ( 2.82% of base) : 1745.dasm - System.Reflection.Emit.MethodBuilder:CreateMethodBodyHelper(System.Reflection.Emit.ILGenerator):this
          48 ( 2.12% of base) : 6982.dasm - System.Runtime.Serialization.Formatters.Binary.ObjectWriter:WriteArray(System.Runtime.Serialization.Formatters.Binary.WriteObjectInfo,System.Runtime.Serialization.Formatters.Binary.NameInfo,System.Runtime.Serialization.Formatters.Binary.WriteObjectInfo):this
          48 ( 2.86% of base) : 3317.dasm - System.Xml.XmlConvert:EncodeName(System.String,bool,bool):System.String
          36 ( 3.00% of base) : 829.dasm - System.Sha1ForNonSecretPurposes:Finish(System.Span`1[Byte]):this
          32 ( 8.33% of base) : 19120.dasm - System.Collections.Concurrent.ConcurrentBag`1[Int32][System.Int32]:ToArray():System.Int32[]:this
          28 ( 2.06% of base) : 8405.dasm - System.Diagnostics.StackFrameHelper:InitializeSourceInfo(int,bool,System.Exception):this
          24 ( 7.79% of base) : 18601.dasm - Benchstone.BenchI.AddArray:Test():bool:this
          24 ( 1.42% of base) : 14412.dasm - MessagePack.Formatters.MicroBenchmarks_Serializers_CollectionsOfPrimitivesFormatter1:Deserialize(System.Byte[],int,MessagePack.IFormatterResolver,byref):MicroBenchmarks.Serializers.CollectionsOfPrimitives:this
          24 ( 1.59% of base) : 21759.dasm - System.Buffers.Text.Utf8Formatter:TryFormat(System.Decimal,System.Span`1[Byte],byref,System.Buffers.StandardFormat):bool
          24 ( 6.00% of base) : 6662.dasm - System.Text.RegularExpressions.RegexCompiler:Goto(int):this
          24 ( 2.90% of base) : 8565.dasm - Utf8Json.JsonSerializer:Deserialize(System.IO.Stream,Utf8Json.IJsonFormatterResolver):System.__Canon
          20 ( 4.46% of base) : 1037.dasm - System.TimeZoneInfo:TryConvertIanaIdToWindowsId(System.String,bool,byref):bool
          16 ( 3.10% of base) : 11927.dasm - Benchstone.BenchI.XposMatrix:Inner(System.Int32[][],int)
          16 ( 1.38% of base) : 2104.dasm - System.DefaultBinder:FindMostSpecific(System.Reflection.ParameterInfo[],System.Int32[],System.Type,System.Reflection.ParameterInfo[],System.Int32[],System.Type,System.Type[],System.Object[]):int
          16 ( 2.35% of base) : 416.dasm - System.Reflection.Associates:AssignAssociates(int,System.RuntimeType,System.RuntimeType):System.Reflection.RuntimeMethodInfo
          16 ( 2.20% of base) : 1734.dasm - System.Reflection.Emit.__ExceptionInfo:MarkHelper(int,int,System.Type,int):this
          16 ( 1.98% of base) : 6641.dasm - System.Text.RegularExpressions.RegexCompiler:GenerateForwardSection():this
          12 ( 1.86% of base) : 20019.dasm - Benchstone.BenchI.Array2:Bench(int):bool
          12 ( 2.11% of base) : 20022.dasm - Benchstone.BenchI.Array2:VerifyCopy(System.Int32[][][],System.Int32[][][]):bool
          12 ( 1.03% of base) : 10242.dasm - EMFloat:AddSubInternalFPF(ubyte,byref,byref,byref)

Top method improvements (bytes):
        -660 (-6.48% of base) : 3506.dasm - System.Text.RegularExpressions.RegexInterpreter:Go():this
        -520 (-8.86% of base) : 19287.dasm - DynamicClass:Regex4_Go(System.Text.RegularExpressions.RegexRunner)
        -512 (-12.77% of base) : 12906.dasm - DynamicClass:Regex3_Go(System.Text.RegularExpressions.RegexRunner)
        -508 (-8.34% of base) : 23202.dasm - DynamicClass:Regex1_Go(System.Text.RegularExpressions.RegexRunner)
        -504 (-8.21% of base) : 15238.dasm - DynamicClass:Regex4_Go(System.Text.RegularExpressions.RegexRunner)
        -500 (-2.09% of base) : 13550.dasm - DynamicClass:_DynamicMethod0(System.IO.TextWriter,MicroBenchmarks.Serializers.MyEventsListerItem,int)
        -484 (-8.85% of base) : 21964.dasm - DynamicClass:Regex1_Go(System.Text.RegularExpressions.RegexRunner)
        -436 (-11.83% of base) : 14847.dasm - DynamicClass:Regex3_Go(System.Text.RegularExpressions.RegexRunner)
        -344 (-1.85% of base) : 2494.dasm - DynamicClass:_DynamicMethod0(System.IO.TextWriter,MicroBenchmarks.Serializers.IndexViewModel,int)
        -324 (-3.20% of base) : 11506.dasm - Jil.Deserialize.Methods:ParseISO8601Date(System.IO.TextReader,System.Char[],int,int):System.DateTime
        -324 (-3.20% of base) : 2715.dasm - Jil.Deserialize.Methods:ParseISO8601DateThunkReader(byref,System.Char[],int,int):System.DateTime
        -324 (-4.29% of base) : 1245.dasm - System.Text.RegularExpressions.RegexWriter:EmitFragment(int,System.Text.RegularExpressions.RegexNode,int):this
        -248 (-2.68% of base) : 21403.dasm - DynamicClass:Regex2_Go(System.Text.RegularExpressions.RegexRunner)
        -248 (-4.62% of base) : 19341.dasm - Utf8Json.Formatters.ISO8601DateTimeFormatter:Deserialize(byref,Utf8Json.IJsonFormatterResolver):System.DateTime:this
        -244 (-1.40% of base) : 6643.dasm - System.Text.RegularExpressions.RegexCompiler:GenerateOneCode():this
        -240 (-5.37% of base) : 12513.dasm - Utf8Json.Formatters.ISO8601DateTimeOffsetFormatter:Deserialize(byref,Utf8Json.IJsonFormatterResolver):System.DateTimeOffset:this
        -236 (-2.41% of base) : 22578.dasm - Jil.Deserialize.Methods:_ReadISO8601DateThunkReader(byref,System.Char[]):System.DateTime
        -236 (-2.38% of base) : 2714.dasm - Jil.Deserialize.Methods:_ReadISO8601DateWithOffsetThunkReader(byref,System.Char[]):System.DateTimeOffset
        -220 (-3.24% of base) : 18295.dasm - Jil.Deserialize.Methods:_ReadISO8601Date(System.IO.TextReader,System.Char[]):System.DateTime
        -220 (-3.13% of base) : 11505.dasm - Jil.Deserialize.Methods:_ReadISO8601DateWithOffset(System.IO.TextReader,System.Char[]):System.DateTimeOffset

Top method regressions (percentages):
          32 ( 8.33% of base) : 19120.dasm - System.Collections.Concurrent.ConcurrentBag`1[Int32][System.Int32]:ToArray():System.Int32[]:this
          24 ( 7.79% of base) : 18601.dasm - Benchstone.BenchI.AddArray:Test():bool:this
          12 ( 7.50% of base) : 14104.dasm - System.Collections.CreateAddAndClear`1[Int32][System.Int32]:Array():System.Int32[]:this
          24 ( 6.00% of base) : 6662.dasm - System.Text.RegularExpressions.RegexCompiler:Goto(int):this
          12 ( 5.88% of base) : 16129.dasm - Microsoft.CodeAnalysis.Collections.ByteSequenceComparer:Equals(System.Collections.Immutable.ImmutableArray`1[Byte],System.Collections.Immutable.ImmutableArray`1[Byte]):bool
          12 ( 5.88% of base) : 17988.dasm - System.Reflection.Internal.ByteSequenceComparer:Equals(System.Collections.Immutable.ImmutableArray`1[Byte],System.Collections.Immutable.ImmutableArray`1[Byte]):bool
          12 ( 5.17% of base) : 5864.dasm - SslCredKey:Equals(SslCredKey):bool:this
          12 ( 4.48% of base) : 5945.dasm - System.Security.Cryptography.Primitives.Tests.Performance.Perf_FixedTimeEquals:Setup(System.String,System.String):this
          20 ( 4.46% of base) : 1037.dasm - System.TimeZoneInfo:TryConvertIanaIdToWindowsId(System.String,bool,byref):bool
           8 ( 4.35% of base) : 6659.dasm - System.Text.RegularExpressions.RegexCompiler:TrackUnique(int):this
           8 ( 4.00% of base) : 9847.dasm - System.Reflection.Metadata.MetadataReader:CombineRowCounts(System.Int32[],System.Int32[],ubyte):System.Int32[]
          12 ( 4.00% of base) : 2564.dasm - System.RuntimeTypeHandle:CopyRuntimeTypeHandles(System.Type[],byref):System.IntPtr[]
          12 ( 3.85% of base) : 9862.dasm - System.Diagnostics.StackFrame:.ctor(System.Diagnostics.StackFrameHelper,int,bool):this
           8 ( 3.77% of base) : 4816.dasm - ListPartition`1[Char][System.Char]:ToArray():System.Char[]:this
          12 ( 3.70% of base) : 6980.dasm - System.Collections.HashHelpers:GetPrime(int):int
          12 ( 3.70% of base) : 6.dasm - System.Collections.HashHelpers:GetPrime(int):int
           4 ( 3.57% of base) : 10237.dasm - EMFloat:memmove(byref,byref)
          12 ( 3.37% of base) : 3046.dasm - Newtonsoft.Json.DefaultJsonNameTable:Add(System.String):System.String:this
           4 ( 3.33% of base) : 11430.dasm - EMFloatClass:memmove(InternalFPF,InternalFPF)
           8 ( 3.33% of base) : 20974.dasm - SelectIListIterator`2[Int32,Int32][System.Int32,System.Int32]:ToArray():System.Int32[]:this

Top method improvements (percentages):
         -60 (-20.00% of base) : 20833.dasm - Benchstone.BenchI.BubbleSort2:Test():bool:this
         -20 (-17.24% of base) : 12447.dasm - System.Text.RegularExpressions.RegexInterpreter:TrackPush(int,int):this
        -176 (-17.12% of base) : 13511.dasm - IDEAEncryption:de_key_idea(System.Char[],System.Char[])
         -20 (-16.67% of base) : 14479.dasm - System.Text.RegularExpressions.RegexInterpreter:TrackPush2(int,int):this
         -92 (-15.75% of base) : 6845.dasm - Benchstone.BenchI.HeapSort:Inner(System.Int32[],int)
         -32 (-15.69% of base) : 8335.dasm - V8.Crypto.Arcfour:next():int:this
         -52 (-15.48% of base) : 14989.dasm - Span.Sorting:TestQuickSortArray(System.Int32[],int,int)
         -24 (-15.00% of base) : 2375.dasm - <>c__DisplayClass14_0:<_ReadFieldOperands>b__0(int):int:this
         -40 (-13.70% of base) : 14518.dasm - Parser:Parse4Dig(int,byref):bool:this
         -40 (-13.51% of base) : 6150.dasm - Newtonsoft.Json.Utilities.DateTimeParser:Parse4Digit(int,byref):bool:this
         -24 (-13.33% of base) : 19671.dasm - Benchstone.BenchI.Array1:VerifySort(System.Int32[]):bool
         -12 (-13.04% of base) : 3510.dasm - System.Text.RegularExpressions.RegexInterpreter:TrackPush(int):this
        -512 (-12.77% of base) : 12906.dasm - DynamicClass:Regex3_Go(System.Text.RegularExpressions.RegexRunner)
         -24 (-12.50% of base) : 9549.dasm - System.Net.Internals.SocketAddress:CopyAddressSizeIntoBuffer():this
         -12 (-12.50% of base) : 15559.dasm - System.Text.RegularExpressions.RegexInterpreter:TrackPush2(int):this
         -12 (-12.50% of base) : 7516.dasm - System.Xml.XmlException:BuildCharExceptionArgs(System.String,int):System.String[]
         -24 (-12.24% of base) : 20517.dasm - Benchstone.BenchI.BubbleSort:VerifySort(System.Int32[],int):bool
        -436 (-11.83% of base) : 14847.dasm - DynamicClass:Regex3_Go(System.Text.RegularExpressions.RegexRunner)
         -52 (-11.50% of base) : 11618.dasm - System.SpanHelpers:LastIndexOf(byref,int,int):int
         -52 (-11.21% of base) : 10989.dasm - System.SpanHelpers:LastIndexOf(byref,ushort,int):int

1220 total methods with Code Size differences (1136 improved, 84 regressed), 368 unchanged.


coreclr_tests.pmi.windows.arm64.checked.mch:


Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 165345900 (overridden on cmd)
Total bytes of diff: 165319844 (overridden on cmd)
Total bytes of delta: -26056 (-0.02 % of base)
    diff is an improvement.
    relative diff is an improvement.
Detail diffs


Top file regressions (bytes):
         104 : 239428.dasm (2.61% of base)
          68 : 167158.dasm (9.04% of base)
          68 : 100367.dasm (8.99% of base)
          68 : 101273.dasm (9.04% of base)
          68 : 166934.dasm (9.09% of base)
          68 : 166744.dasm (9.04% of base)
          68 : 167347.dasm (9.09% of base)
          68 : 100446.dasm (9.04% of base)
          68 : 101196.dasm (8.99% of base)
          68 : 166823.dasm (9.09% of base)
          68 : 101385.dasm (9.04% of base)
          68 : 100557.dasm (9.04% of base)
          68 : 167235.dasm (9.09% of base)
          64 : 100560.dasm (10.74% of base)
          64 : 101356.dasm (10.74% of base)
          64 : 101433.dasm (10.74% of base)
          64 : 166952.dasm (10.74% of base)
          64 : 166965.dasm (8.51% of base)
          64 : 166968.dasm (8.51% of base)
          64 : 100465.dasm (8.33% of base)

Top file improvements (bytes):
       -1548 : 242531.dasm (-14.79% of base)
        -664 : 94.dasm (-6.53% of base)
        -560 : 234600.dasm (-3.52% of base)
        -556 : 234597.dasm (-3.50% of base)
        -544 : 189301.dasm (-18.63% of base)
        -544 : 189050.dasm (-18.63% of base)
        -544 : 188745.dasm (-18.63% of base)
        -448 : 189025.dasm (-17.55% of base)
        -448 : 189276.dasm (-17.55% of base)
        -448 : 188720.dasm (-17.55% of base)
        -324 : 62.dasm (-4.29% of base)
        -300 : 189046.dasm (-14.85% of base)
        -300 : 189297.dasm (-14.85% of base)
        -300 : 188741.dasm (-14.85% of base)
        -252 : 189024.dasm (-13.82% of base)
        -252 : 189275.dasm (-13.82% of base)
        -252 : 188719.dasm (-13.82% of base)
        -196 : 189049.dasm (-18.15% of base)
        -196 : 189300.dasm (-18.15% of base)
        -196 : 188744.dasm (-18.15% of base)

5575 total files with Code Size differences (4500 improved, 1075 regressed), 1309 unchanged.

Top method regressions (bytes):
         104 ( 2.61% of base) : 239428.dasm - Co1245GetBytes_double:runTest():bool:this
          68 ( 9.09% of base) : 166934.dasm - testout1:Sub_Funclet_207():int
          68 ( 9.09% of base) : 167347.dasm - testout1:Sub_Funclet_207():int
          68 ( 9.04% of base) : 101385.dasm - testout1:Sub_Funclet_207():int
          68 ( 9.04% of base) : 100557.dasm - testout1:Sub_Funclet_207():int
          68 ( 9.04% of base) : 101273.dasm - testout1:Sub_Funclet_287():int
          68 ( 9.04% of base) : 100446.dasm - testout1:Sub_Funclet_287():int
          68 ( 9.09% of base) : 166823.dasm - testout1:Sub_Funclet_287():int
          68 ( 9.09% of base) : 167235.dasm - testout1:Sub_Funclet_287():int
          68 ( 9.04% of base) : 167158.dasm - testout1:Sub_Funclet_399():int
          68 ( 8.99% of base) : 100367.dasm - testout1:Sub_Funclet_399():int
          68 ( 9.04% of base) : 166744.dasm - testout1:Sub_Funclet_399():int
          68 ( 8.99% of base) : 101196.dasm - testout1:Sub_Funclet_399():int
          64 (10.74% of base) : 167029.dasm - testout1:Sub_Funclet_111():int
          64 ( 9.41% of base) : 102268.dasm - testout1:Sub_Funclet_111():int
          64 (10.67% of base) : 100652.dasm - testout1:Sub_Funclet_111():int
          64 ( 9.47% of base) : 167841.dasm - testout1:Sub_Funclet_111():int
          64 (10.53% of base) : 100655.dasm - testout1:Sub_Funclet_114():int
          64 ( 9.30% of base) : 102271.dasm - testout1:Sub_Funclet_114():int
          64 (10.60% of base) : 167032.dasm - testout1:Sub_Funclet_114():int

Top method improvements (bytes):
       -1548 (-14.79% of base) : 242531.dasm - SimpleArray_01.Test:Test1()
        -664 (-6.53% of base) : 94.dasm - System.Text.RegularExpressions.RegexInterpreter:Go():this
        -560 (-3.52% of base) : 234600.dasm - StrAccess2:Main():int
        -556 (-3.50% of base) : 234597.dasm - StrAccess2:Main():int
        -544 (-18.63% of base) : 189301.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetHexadecaDataPoint(int):System.ValueTuple`8[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`1]:this
        -544 (-18.63% of base) : 189050.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetHexadecaDataPoint(int):System.ValueTuple`8[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`1]:this
        -544 (-18.63% of base) : 188745.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetHexadecaDataPoint(int):System.ValueTuple`8[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`1]:this
        -448 (-17.55% of base) : 189025.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodSixteenOfAll`2[Byte,Int64]):bool:this
        -448 (-17.55% of base) : 189276.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodSixteenOfAll`2[Byte,Int64]):bool:this
        -448 (-17.55% of base) : 188720.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodSixteenOfAll`2[Byte,Int64]):bool:this
        -324 (-4.29% of base) : 62.dasm - System.Text.RegularExpressions.RegexWriter:EmitFragment(int,System.Text.RegularExpressions.RegexNode,int):this
        -300 (-14.85% of base) : 189046.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetCheckMethodSixteen4DataPoint(int):System.ValueTuple`6[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -300 (-14.85% of base) : 189297.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetCheckMethodSixteen4DataPoint(int):System.ValueTuple`6[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -300 (-14.85% of base) : 188741.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetCheckMethodSixteen4DataPoint(int):System.ValueTuple`6[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -252 (-13.82% of base) : 189024.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckPackSaturate(IntelHardwareIntrinsicTest.CheckMethodSixteen`2[Byte,Int64]):bool:this
        -252 (-13.82% of base) : 189275.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckPackSaturate(IntelHardwareIntrinsicTest.CheckMethodSixteen`2[Byte,Int64]):bool:this
        -252 (-13.82% of base) : 188719.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckPackSaturate(IntelHardwareIntrinsicTest.CheckMethodSixteen`2[Byte,Int64]):bool:this
        -196 (-7.69% of base) : 191680.dasm - AssignRect:second_assignments(System.Int32[,],System.Int16[,])
        -196 (-18.15% of base) : 189049.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetOcta88DataPoint(int):System.ValueTuple`4[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -196 (-18.15% of base) : 189300.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetOcta88DataPoint(int):System.ValueTuple`4[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this

Top method regressions (percentages):
          52 (15.66% of base) : 167440.dasm - testout1:Sub_Funclet_111():int
          52 (15.66% of base) : 167048.dasm - testout1:Sub_Funclet_79():int
          52 (15.66% of base) : 167424.dasm - testout1:Sub_Funclet_95():int
          52 (15.48% of base) : 101478.dasm - testout1:Sub_Funclet_111():int
          52 (15.48% of base) : 167443.dasm - testout1:Sub_Funclet_114():int
          52 (15.48% of base) : 167174.dasm - testout1:Sub_Funclet_354():int
          52 (15.48% of base) : 100671.dasm - testout1:Sub_Funclet_79():int
          52 (15.48% of base) : 167470.dasm - testout1:Sub_Funclet_82():int
          52 (15.48% of base) : 101462.dasm - testout1:Sub_Funclet_95():int
          52 (15.48% of base) : 167427.dasm - testout1:Sub_Funclet_98():int
          52 (15.29% of base) : 101481.dasm - testout1:Sub_Funclet_114():int
          52 (15.29% of base) : 167809.dasm - testout1:Sub_Funclet_143():int
          52 (15.29% of base) : 167613.dasm - testout1:Sub_Funclet_319():int
          52 (15.29% of base) : 167203.dasm - testout1:Sub_Funclet_319():int
          52 (15.29% of base) : 101212.dasm - testout1:Sub_Funclet_354():int
          52 (15.29% of base) : 167584.dasm - testout1:Sub_Funclet_354():int
          52 (15.29% of base) : 101508.dasm - testout1:Sub_Funclet_82():int
          52 (15.29% of base) : 101465.dasm - testout1:Sub_Funclet_98():int
          52 (15.12% of base) : 102236.dasm - testout1:Sub_Funclet_143():int
          52 (15.12% of base) : 101241.dasm - testout1:Sub_Funclet_319():int

Top method improvements (percentages):
         -60 (-21.13% of base) : 253147.dasm - Benchstone.BenchI.BubbleSort2:Bench():bool
        -544 (-18.63% of base) : 189301.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetHexadecaDataPoint(int):System.ValueTuple`8[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`1]:this
        -544 (-18.63% of base) : 189050.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetHexadecaDataPoint(int):System.ValueTuple`8[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`1]:this
        -544 (-18.63% of base) : 188745.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetHexadecaDataPoint(int):System.ValueTuple`8[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`1]:this
        -196 (-18.15% of base) : 189049.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetOcta88DataPoint(int):System.ValueTuple`4[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -196 (-18.15% of base) : 189300.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetOcta88DataPoint(int):System.ValueTuple`4[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -196 (-18.15% of base) : 188744.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetOcta88DataPoint(int):System.ValueTuple`4[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -448 (-17.55% of base) : 189025.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodSixteenOfAll`2[Byte,Int64]):bool:this
        -448 (-17.55% of base) : 189276.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodSixteenOfAll`2[Byte,Int64]):bool:this
        -448 (-17.55% of base) : 188720.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodSixteenOfAll`2[Byte,Int64]):bool:this
        -176 (-17.12% of base) : 191740.dasm - IDEAEncryption:de_key_idea(System.Char[],System.Char[])
         -92 (-15.75% of base) : 253126.dasm - Benchstone.BenchI.HeapSort:Inner(System.Int32[],int)
         -32 (-15.69% of base) : 218958.dasm - V8.Crypto.Arcfour:next():int:this
         -52 (-15.48% of base) : 218785.dasm - Span.SpanBench:TestQuickSortArray(System.Int32[],int,int)
         -12 (-15.00% of base) : 120787.dasm - JIT.HardwareIntrinsics.Arm.Helpers:AddPairwiseWidening(System.Int16[],int):int
         -12 (-15.00% of base) : 129310.dasm - JIT.HardwareIntrinsics.Arm.Helpers:AddPairwiseWidening(System.Int16[],int):int
         -12 (-15.00% of base) : 175043.dasm - JIT.HardwareIntrinsics.Arm.Helpers:AddPairwiseWidening(System.Int16[],int):int
         -12 (-15.00% of base) : 179759.dasm - JIT.HardwareIntrinsics.Arm.Helpers:AddPairwiseWidening(System.Int16[],int):int
         -12 (-15.00% of base) : 185916.dasm - JIT.HardwareIntrinsics.Arm.Helpers:AddPairwiseWidening(System.Int16[],int):int
         -12 (-15.00% of base) : 172310.dasm - JIT.HardwareIntrinsics.Arm.Helpers:AddPairwiseWidening(System.Int16[],int):int

5575 total methods with Code Size differences (4500 improved, 1075 regressed), 1309 unchanged.


libraries.crossgen2.windows.arm64.checked.mch:


Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 51752168 (overridden on cmd)
Total bytes of diff: 51718316 (overridden on cmd)
Total bytes of delta: -33852 (-0.07 % of base)
    diff is an improvement.
    relative diff is an improvement.
Detail diffs


Top file regressions (bytes):
          52 : 152304.dasm (1.72% of base)
          52 : 176886.dasm (1.89% of base)
          52 : 52935.dasm (1.56% of base)
          48 : 62973.dasm (2.41% of base)
          44 : 56894.dasm (4.37% of base)
          40 : 50715.dasm (4.72% of base)
          40 : 207810.dasm (0.74% of base)
          40 : 191694.dasm (34.48% of base)
          28 : 60814.dasm (1.72% of base)
          28 : 210039.dasm (5.34% of base)
          28 : 57374.dasm (9.59% of base)
          28 : 169928.dasm (1.34% of base)
          24 : 126981.dasm (1.43% of base)
          24 : 72390.dasm (3.33% of base)
          24 : 203421.dasm (1.92% of base)
          20 : 220105.dasm (1.27% of base)
          20 : 176779.dasm (4.24% of base)
          20 : 199662.dasm (1.15% of base)
          20 : 165747.dasm (1.29% of base)
          20 : 117447.dasm (2.81% of base)

Top file improvements (bytes):
        -672 : 122317.dasm (-13.29% of base)
        -524 : 194617.dasm (-5.36% of base)
        -348 : 124789.dasm (-11.97% of base)
        -348 : 124957.dasm (-13.45% of base)
        -304 : 124942.dasm (-12.12% of base)
        -304 : 124771.dasm (-10.75% of base)
        -276 : 194411.dasm (-3.46% of base)
        -252 : 194285.dasm (-0.90% of base)
        -252 : 169762.dasm (-13.82% of base)
        -228 : 124769.dasm (-11.18% of base)
        -228 : 124938.dasm (-15.32% of base)
        -188 : 151581.dasm (-0.68% of base)
        -152 : 74518.dasm (-2.90% of base)
        -152 : 182290.dasm (-3.04% of base)
        -140 : 124751.dasm (-9.62% of base)
        -140 : 124927.dasm (-12.46% of base)
        -128 : 128968.dasm (-12.45% of base)
        -128 : 129063.dasm (-19.51% of base)
        -128 : 87315.dasm (-8.74% of base)
        -124 : 195000.dasm (-2.50% of base)

3343 total files with Code Size differences (3003 improved, 340 regressed), 1088 unchanged.

Top method regressions (bytes):
          52 ( 1.56% of base) : 52935.dasm - Microsoft.CodeAnalysis.COFFResourceReader:ReadWin32ResourcesFromCOFF(System.IO.Stream):Microsoft.Cci.ResourceSection
          52 ( 1.72% of base) : 152304.dasm - Microsoft.VisualBasic.CompilerServices.LateBinding:LateIndexSet(System.Object,System.Object[],System.String[])
          52 ( 1.89% of base) : 176886.dasm - System.Runtime.Serialization.Formatters.Binary.ObjectWriter:WriteArray(System.Runtime.Serialization.Formatters.Binary.WriteObjectInfo,System.Runtime.Serialization.Formatters.Binary.NameInfo,System.Runtime.Serialization.Formatters.Binary.WriteObjectInfo):this
          48 ( 2.41% of base) : 62973.dasm - System.Reflection.Emit.MethodBuilder:CreateMethodBodyHelper(System.Reflection.Emit.ILGenerator):this
          44 ( 4.37% of base) : 56894.dasm - Newtonsoft.Json.Serialization.JsonSerializerInternalWriter:SerializeMultidimensionalArray(Newtonsoft.Json.JsonWriter,System.Array,Newtonsoft.Json.Serialization.JsonArrayContract,Newtonsoft.Json.Serialization.JsonProperty,int,System.Int32[]):this
          40 ( 0.74% of base) : 207810.dasm - Internal.TypeSystem.MetadataFieldLayoutAlgorithm:ComputeAutoFieldLayout(Internal.TypeSystem.MetadataType,int):Internal.TypeSystem.ComputedInstanceFieldLayout:this
          40 ( 4.72% of base) : 50715.dasm - Microsoft.CodeAnalysis.Text.SourceText:ContentEqualsImpl(Microsoft.CodeAnalysis.Text.SourceText):bool:this
          40 (34.48% of base) : 191694.dasm - System.Net.WebClient:ByteArrayHasPrefix(System.Byte[],System.Byte[]):bool
          28 ( 1.34% of base) : 169928.dasm - Microsoft.CSharp.RuntimeBinder.Errors.ErrorHandling:Error(int,Microsoft.CSharp.RuntimeBinder.Errors.ErrArg[]):Microsoft.CSharp.RuntimeBinder.RuntimeBinderException
          28 ( 9.59% of base) : 57374.dasm - Newtonsoft.Json.Utilities.MiscellaneousUtils:ByteArrayCompare(System.Byte[],System.Byte[]):int
          28 ( 5.34% of base) : 210039.dasm - System.Configuration.MgmtConfigurationRecord:CheckPreamble(System.Byte[],System.Configuration.XmlUtilWriter,System.Byte[]):this
          28 ( 1.72% of base) : 60814.dasm - System.Diagnostics.StackFrameHelper:InitializeSourceInfo(int,bool,System.Exception):this
          24 ( 1.92% of base) : 203421.dasm - System.Reflection.Metadata.Ecma335.MetadataAggregator:CalculateHeapSizes(System.Collections.Generic.IReadOnlyList`1[System.Int32],System.Collections.Generic.IReadOnlyList`1[System.Reflection.Metadata.MetadataReader]):System.Collections.Immutable.ImmutableArray`1[System.Collections.Immutable.ImmutableArray`1[System.Int32]]
          24 ( 3.33% of base) : 72390.dasm - System.TimeZoneInfo:TryConvertWindowsIdToIanaId(System.String,System.String,bool,byref):bool
          24 ( 1.43% of base) : 126981.dasm - System.Xml.XmlTextReaderImpl:ParseElementContentAsync():System.Threading.Tasks.Task`1[System.Boolean]:this
          20 ( 6.25% of base) : 167348.dasm - Internal.Cryptography.Helpers:FixupKeyParity(System.Byte[]):System.Byte[]
          20 ( 1.29% of base) : 165747.dasm - System.Collections.Concurrent.ConcurrentDictionary`2:GrowTable(System.Collections.Concurrent.ConcurrentDictionary`2+Tables[System.__Canon, System.__Canon]):this
          20 ( 1.27% of base) : 220105.dasm - System.Diagnostics.EventLogInternal:InternalWriteEvent(int,ushort,int,System.String[],System.Byte[],System.String):this
          20 ( 4.24% of base) : 176779.dasm - System.DomainNameHelper:IdnEquivalent(System.String):System.String
          20 ( 1.15% of base) : 199662.dasm - System.ServiceProcess.ServiceController:Start(System.String[]):this

Top method improvements (bytes):
        -672 (-13.29% of base) : 122317.dasm - System.Xml.Schema.XmlSchemaInference:InferSimpleType(System.String,byref):int
        -524 (-5.36% of base) : 194617.dasm - System.Text.RegularExpressions.RegexInterpreter:Go():this
        -348 (-11.97% of base) : 124789.dasm - <ScanSubsetContentAsync>d__174:MoveNext():this
        -348 (-13.45% of base) : 124957.dasm - System.Xml.DtdParser:ScanSubsetContent():int:this
        -304 (-10.75% of base) : 124771.dasm - <ScanAttlist2Async>d__183:MoveNext():this
        -304 (-12.12% of base) : 124942.dasm - System.Xml.DtdParser:ScanAttlist2():int:this
        -276 (-3.46% of base) : 194411.dasm - System.Text.RegularExpressions.RegexWriter:EmitFragment(int,System.Text.RegularExpressions.RegexNode,int):this
        -252 (-0.90% of base) : 194285.dasm - System.Text.RegularExpressions.RegexCompiler:GenerateOneCode():this
        -252 (-13.82% of base) : 169762.dasm - Xunit.Sdk.Sha1Digest:ProcessBlock():this
        -228 (-11.18% of base) : 124769.dasm - <ScanAttlist6Async>d__184:MoveNext():this
        -228 (-15.32% of base) : 124938.dasm - System.Xml.DtdParser:ScanAttlist6():int:this
        -188 (-0.68% of base) : 151581.dasm - Microsoft.VisualBasic.CompilerServices.VBBinder:BindToMethod(int,System.Reflection.MethodBase[],byref,System.Reflection.ParameterModifier[],System.Globalization.CultureInfo,System.String[],byref):System.Reflection.MethodBase:this
        -152 (-3.04% of base) : 182290.dasm - Number:NumberToStringFormat(byref,byref,System.ReadOnlySpan`1[System.Char],System.Globalization.NumberFormatInfo)
        -152 (-2.90% of base) : 74518.dasm - System.Number:NumberToStringFormat(byref,byref,System.ReadOnlySpan`1[System.Char],System.Globalization.NumberFormatInfo)
        -140 (-9.62% of base) : 124751.dasm - <ScanCondSection1Async>d__193:MoveNext():this
        -140 (-12.46% of base) : 124927.dasm - System.Xml.DtdParser:ScanCondSection1():int:this
        -128 (-12.45% of base) : 128968.dasm - <WriteCDataAsync>d__109:MoveNext():this
        -128 (-8.74% of base) : 87315.dasm - System.Xml.UniqueId:UnsafeParse(long,int):this
        -128 (-19.51% of base) : 129063.dasm - System.Xml.XmlEncodedRawTextWriter:WriteCData(System.String):this
        -124 (-2.50% of base) : 195000.dasm - System.Text.RegularExpressions.Symbolic.SymbolicRegexMatcher`1:FindFinalStatePosition(System.String,int,int,int,byref,byref):int:this

Top method regressions (percentages):
          40 (34.48% of base) : 191694.dasm - System.Net.WebClient:ByteArrayHasPrefix(System.Byte[],System.Byte[]):bool
          28 ( 9.59% of base) : 57374.dasm - Newtonsoft.Json.Utilities.MiscellaneousUtils:ByteArrayCompare(System.Byte[],System.Byte[]):int
          16 ( 7.14% of base) : 193949.dasm - System.Text.RegularExpressions.Symbolic.BV:op_BitwiseAnd(System.Text.RegularExpressions.Symbolic.BV,System.Text.RegularExpressions.Symbolic.BV):System.Text.RegularExpressions.Symbolic.BV
          16 ( 7.14% of base) : 193948.dasm - System.Text.RegularExpressions.Symbolic.BV:op_BitwiseOr(System.Text.RegularExpressions.Symbolic.BV,System.Text.RegularExpressions.Symbolic.BV):System.Text.RegularExpressions.Symbolic.BV
          16 ( 7.14% of base) : 193922.dasm - System.Text.RegularExpressions.Symbolic.BVAlgebra:And(System.Text.RegularExpressions.Symbolic.BV,System.Text.RegularExpressions.Symbolic.BV):System.Text.RegularExpressions.Symbolic.BV:this
          16 ( 7.14% of base) : 193919.dasm - System.Text.RegularExpressions.Symbolic.BVAlgebra:Or(System.Text.RegularExpressions.Symbolic.BV,System.Text.RegularExpressions.Symbolic.BV):System.Text.RegularExpressions.Symbolic.BV:this
          12 ( 6.52% of base) : 19567.dasm - Microsoft.Diagnostics.Symbols.SourceFile:ArrayEquals(System.Byte[],System.Byte[]):bool
          12 ( 6.38% of base) : 187336.dasm - Microsoft.Extensions.FileProviders.Physical.PollingWildCardChangeToken:ArrayEquals(System.Byte[],System.Byte[]):bool
          20 ( 6.25% of base) : 167348.dasm - Internal.Cryptography.Helpers:FixupKeyParity(System.Byte[]):System.Byte[]
          12 ( 6.25% of base) : 124372.dasm - System.Xml.Schema.DatatypeImplementation:Compare(System.Byte[],System.Byte[]):int:this
          12 ( 6.00% of base) : 192892.dasm - System.DirectoryServices.ActiveDirectory.ActiveDirectorySchedule:.ctor(System.Boolean[]):this
          12 ( 5.88% of base) : 116075.dasm - ILCompiler.DependencyAnalysis.ReadyToRun.ByteArrayComparer:Equals(System.Byte[],System.Byte[]):bool:this
          16 ( 5.80% of base) : 53506.dasm - Microsoft.CodeAnalysis.CommandLineParser:RemoveTrailingSpacesAndDots(System.String):System.String
          12 ( 5.77% of base) : 206951.dasm - Internal.Cryptography.Helpers:ContentsEqual(System.Byte[],System.Byte[]):bool
          16 ( 5.71% of base) : 175796.dasm - System.DirectoryServices.AccountManagement.SidList:.ctor(System.DirectoryServices.AccountManagement.UnsafeNativeMethods+SID_AND_ATTR[]):this
           8 ( 5.71% of base) : 194550.dasm - System.Text.RegularExpressions.RegexParser:Escape(System.String):System.String
          12 ( 5.66% of base) : 50281.dasm - Microsoft.CodeAnalysis.Collections.ByteSequenceComparer:Equals(System.Byte[],System.Byte[]):bool
          12 ( 5.66% of base) : 203365.dasm - System.Reflection.Internal.ByteSequenceComparer:Equals(System.Byte[],System.Byte[]):bool
          12 ( 5.56% of base) : 197637.dasm - System.Security.AccessControl.CommonAcl:AceOpaquesMatch(System.Security.AccessControl.QualifiedAce,System.Security.AccessControl.QualifiedAce):bool
          12 ( 5.56% of base) : 194397.dasm - System.Text.RegularExpressions.RegexCompiler:AddGoto(int):int:this

Top method improvements (percentages):
         -40 (-20.00% of base) : 129121.dasm - System.Xml.HtmlEncodedRawTextWriter:OutputRestAmps():this
        -128 (-19.51% of base) : 129063.dasm - System.Xml.XmlEncodedRawTextWriter:WriteCData(System.String):this
         -28 (-18.42% of base) : 194642.dasm - System.Text.RegularExpressions.RegexInterpreter:TrackPush(int,int,int):this
         -20 (-15.62% of base) : 194643.dasm - System.Text.RegularExpressions.RegexInterpreter:TrackPush(int,int):this
         -16 (-15.38% of base) : 157838.dasm - System.Linq.Parallel.FixedMaxHeap`1:Swap(int,int):this
        -228 (-15.32% of base) : 124938.dasm - System.Xml.DtdParser:ScanAttlist6():int:this
         -20 (-15.15% of base) : 194640.dasm - System.Text.RegularExpressions.RegexInterpreter:TrackPush2(int,int):this
         -52 (-14.94% of base) : 124919.dasm - System.Xml.DtdParser:EatPublicKeyword():bool:this
         -52 (-14.94% of base) : 124918.dasm - System.Xml.DtdParser:EatSystemKeyword():bool:this
         -60 (-14.71% of base) : 129062.dasm - System.Xml.XmlEncodedRawTextWriter:WriteComment(System.String):this
          -4 (-14.29% of base) : 75455.dasm - System.DateTimeRawInfo:GetNumber(int):int:this
         -44 (-14.10% of base) : 1229.dasm - Microsoft.Diagnostics.Tracing.Ctf.CtfMetadataLegacyParser:FindCloseBrace(System.String,int):int
        -252 (-13.82% of base) : 169762.dasm - Xunit.Sdk.Sha1Digest:ProcessBlock():this
        -120 (-13.70% of base) : 127108.dasm - System.Xml.XmlTextReaderImpl:ParseNamedCharRefInline(int,bool,System.Text.StringBuilder):int:this
         -24 (-13.64% of base) : 54409.dasm - Microsoft.Cci.MetadataWriter:ReadInt32(System.Collections.Immutable.ImmutableArray`1[System.Byte],int):int
         -24 (-13.64% of base) : 48379.dasm - PublicKeyDecoder:ToUInt32(System.Collections.Immutable.ImmutableArray`1[System.Byte],int):int
        -348 (-13.45% of base) : 124957.dasm - System.Xml.DtdParser:ScanSubsetContent():int:this
        -672 (-13.29% of base) : 122317.dasm - System.Xml.Schema.XmlSchemaInference:InferSimpleType(System.String,byref):int
         -40 (-13.16% of base) : 122405.dasm - Parser:Parse4Dig(int,byref):bool:this
         -80 (-13.16% of base) : 128853.dasm - System.Xml.XmlUtf8RawTextWriter:WriteCData(System.String):this

3343 total methods with Code Size differences (3003 improved, 340 regressed), 1088 unchanged.


libraries.pmi.windows.arm64.checked.mch:


Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 51211268 (overridden on cmd)
Total bytes of diff: 51114988 (overridden on cmd)
Total bytes of delta: -96280 (-0.19 % of base)
    diff is an improvement.
    relative diff is an improvement.
Detail diffs


Top file regressions (bytes):
          56 : 161922.dasm (7.14% of base)
          52 : 212400.dasm (2.11% of base)
          48 : 149928.dasm (1.95% of base)
          48 : 124065.dasm (2.92% of base)
          40 : 193300.dasm (7.81% of base)
          40 : 203157.dasm (34.48% of base)
          40 : 155695.dasm (10.99% of base)
          36 : 9317.dasm (5.70% of base)
          36 : 9319.dasm (4.84% of base)
          36 : 9321.dasm (5.11% of base)
          36 : 9323.dasm (9.89% of base)
          36 : 9083.dasm (10.71% of base)
          36 : 145523.dasm (1.34% of base)
          32 : 156445.dasm (8.70% of base)
          32 : 164263.dasm (10.39% of base)
          32 : 164876.dasm (2.67% of base)
          32 : 168398.dasm (5.97% of base)
          32 : 181825.dasm (2.03% of base)
          32 : 205688.dasm (10.39% of base)
          28 : 74951.dasm (9.72% of base)

Top file improvements (bytes):
        -684 : 130305.dasm (-13.13% of base)
        -664 : 94.dasm (-6.53% of base)
        -348 : 127693.dasm (-14.01% of base)
        -336 : 127798.dasm (-12.30% of base)
        -324 : 62.dasm (-4.29% of base)
        -308 : 150656.dasm (-1.29% of base)
        -304 : 127708.dasm (-12.73% of base)
        -300 : 127816.dasm (-11.35% of base)
        -252 : 236122.dasm (-14.00% of base)
        -252 : 224756.dasm (-1.41% of base)
        -228 : 127712.dasm (-15.75% of base)
        -220 : 127818.dasm (-10.96% of base)
        -160 : 100386.dasm (-4.07% of base)
        -160 : 94515.dasm (-3.59% of base)
        -156 : 211618.dasm (-3.49% of base)
        -156 : 93329.dasm (-3.95% of base)
        -152 : 100373.dasm (-4.16% of base)
        -148 : 100435.dasm (-4.19% of base)
        -148 : 100364.dasm (-4.17% of base)
        -144 : 99195.dasm (-4.27% of base)

5932 total files with Code Size differences (5552 improved, 380 regressed), 2049 unchanged.

Top method regressions (bytes):
          56 ( 7.14% of base) : 161922.dasm - System.Collections.Generic.SortedSet`1[Byte][System.Byte]:OnDeserialization(System.Object):this
          52 ( 2.11% of base) : 212400.dasm - System.Runtime.Serialization.Formatters.Binary.ObjectWriter:WriteArray(System.Runtime.Serialization.Formatters.Binary.WriteObjectInfo,System.Runtime.Serialization.Formatters.Binary.NameInfo,System.Runtime.Serialization.Formatters.Binary.WriteObjectInfo):this
          48 ( 1.95% of base) : 149928.dasm - Microsoft.VisualBasic.CompilerServices.LateBinding:LateIndexSet(System.Object,System.Object[],System.String[])
          48 ( 2.92% of base) : 124065.dasm - System.Xml.XmlConvert:EncodeName(System.String,bool,bool):System.String
          40 ( 7.81% of base) : 193300.dasm - AppendPrependN`1[Byte][System.Byte]:ToArray():System.Byte[]:this
          40 (10.99% of base) : 155695.dasm - System.Collections.Concurrent.ConcurrentBag`1[Byte][System.Byte]:ToArray():System.Byte[]:this
          40 (34.48% of base) : 203157.dasm - System.Net.WebClient:ByteArrayHasPrefix(System.Byte[],System.Byte[]):bool
          36 ( 1.34% of base) : 145523.dasm - Microsoft.CSharp.RuntimeBinder.Errors.ErrorHandling:Error(int,Microsoft.CSharp.RuntimeBinder.Errors.ErrArg[]):Microsoft.CSharp.RuntimeBinder.RuntimeBinderException
          36 ( 5.70% of base) : 9317.dasm - Microsoft.FSharp.Collections.ArrayModule:splitAt$cont@130(int,System.Byte[],Microsoft.FSharp.Core.Unit):System.Tuple`2[[System.Byte[], System.Private.CoreLib, Version=7.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Byte[], System.Private.CoreLib, Version=7.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]
          36 ( 4.84% of base) : 9319.dasm - Microsoft.FSharp.Collections.ArrayModule:SplitAt(int,System.Byte[]):System.Tuple`2[[System.Byte[], System.Private.CoreLib, Version=7.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Byte[], System.Private.CoreLib, Version=7.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]
          36 ( 5.11% of base) : 9321.dasm - Microsoft.FSharp.Collections.ArrayModule:Take(int,System.Byte[]):System.Byte[]
          36 ( 9.89% of base) : 9323.dasm - Microsoft.FSharp.Collections.ArrayModule:TakeWhile(Microsoft.FSharp.Core.FSharpFunc`2[Byte,Boolean],System.Byte[]):System.Byte[]
          36 (10.71% of base) : 9083.dasm - Microsoft.FSharp.Collections.ArrayModule:Truncate(int,System.Byte[]):System.Byte[]
          32 (10.39% of base) : 164263.dasm - Microsoft.Internal.Collections.CollectionServices:IsArrayEqual(System.Byte[],System.Byte[]):bool
          32 ( 5.97% of base) : 168398.dasm - System.Configuration.MgmtConfigurationRecord:CheckPreamble(System.Byte[],System.Configuration.XmlUtilWriter,System.Byte[]):this
          32 ( 2.67% of base) : 164876.dasm - System.Drawing.ColorConverterCommon:ConvertFromString(System.String,System.Globalization.CultureInfo):System.Drawing.Color
          32 ( 2.03% of base) : 181825.dasm - System.Drawing.ColorConverterCommon:ConvertFromString(System.String,System.Globalization.CultureInfo):System.Drawing.Color
          32 ( 8.70% of base) : 156445.dasm - System.Linq.ImmutableArrayExtensions:SequenceEqual(System.Collections.Immutable.ImmutableArray`1[Byte],System.Collections.Immutable.ImmutableArray`1[Byte],System.Collections.Generic.IEqualityComparer`1[Byte]):bool
          32 (10.39% of base) : 205688.dasm - System.Reflection.Context.CollectionServices:CompareArrays(System.Byte[],System.Byte[]):bool
          28 ( 9.72% of base) : 74951.dasm - Microsoft.Cci.ContentId:FromHash(System.Collections.Immutable.ImmutableArray`1[Byte]):Microsoft.Cci.ContentId

Top method improvements (bytes):
        -684 (-13.13% of base) : 130305.dasm - System.Xml.Schema.XmlSchemaInference:InferSimpleType(System.String,byref):int
        -664 (-6.53% of base) : 94.dasm - System.Text.RegularExpressions.RegexInterpreter:Go():this
        -348 (-14.01% of base) : 127693.dasm - System.Xml.DtdParser:ScanSubsetContent():int:this
        -336 (-12.30% of base) : 127798.dasm - <ScanSubsetContentAsync>d__174:MoveNext():this
        -324 (-4.29% of base) : 62.dasm - System.Text.RegularExpressions.RegexWriter:EmitFragment(int,System.Text.RegularExpressions.RegexNode,int):this
        -308 (-1.29% of base) : 150656.dasm - Microsoft.VisualBasic.CompilerServices.VBBinder:BindToMethod(int,System.Reflection.MethodBase[],byref,System.Reflection.ParameterModifier[],System.Globalization.CultureInfo,System.String[],byref):System.Reflection.MethodBase:this
        -304 (-12.73% of base) : 127708.dasm - System.Xml.DtdParser:ScanAttlist2():int:this
        -300 (-11.35% of base) : 127816.dasm - <ScanAttlist2Async>d__183:MoveNext():this
        -252 (-1.41% of base) : 224756.dasm - System.Text.RegularExpressions.RegexCompiler:GenerateOneCode():this
        -252 (-14.00% of base) : 236122.dasm - Xunit.Sdk.Sha1Digest:ProcessBlock():this
        -228 (-15.75% of base) : 127712.dasm - System.Xml.DtdParser:ScanAttlist6():int:this
        -220 (-10.96% of base) : 127818.dasm - <ScanAttlist6Async>d__184:MoveNext():this
        -160 (-4.07% of base) : 100386.dasm - Microsoft.Diagnostics.Tracing.Parsers.ApplicationServer.Multidata6TemplateHATraceData:ToXml(System.Text.StringBuilder):System.Text.StringBuilder:this
        -160 (-3.59% of base) : 94515.dasm - Microsoft.Diagnostics.Tracing.Parsers.Kernel.MemoryProcessMemInfoTraceData:ToXml(System.Text.StringBuilder):System.Text.StringBuilder:this
        -156 (-3.95% of base) : 93329.dasm - Microsoft.Diagnostics.Tracing.Parsers.MicrosoftWindowsTCPIP.TcpGlobalParametersArgs:ToXml(System.Text.StringBuilder):System.Text.StringBuilder:this
        -156 (-3.49% of base) : 211618.dasm - Number:NumberToStringFormat(byref,byref,System.ReadOnlySpan`1[Char],System.Globalization.NumberFormatInfo)
        -152 (-4.16% of base) : 100373.dasm - Microsoft.Diagnostics.Tracing.Parsers.ApplicationServer.Multidata3TemplateHATraceData:ToXml(System.Text.StringBuilder):System.Text.StringBuilder:this
        -148 (-4.19% of base) : 100435.dasm - Microsoft.Diagnostics.Tracing.Parsers.ApplicationServer.Multidata13TemplateHATraceData:ToXml(System.Text.StringBuilder):System.Text.StringBuilder:this
        -148 (-4.17% of base) : 100364.dasm - Microsoft.Diagnostics.Tracing.Parsers.ApplicationServer.Multidata4TemplateHATraceData:ToXml(System.Text.StringBuilder):System.Text.StringBuilder:this
        -144 (-4.23% of base) : 100347.dasm - Microsoft.Diagnostics.Tracing.Parsers.ApplicationServer.Multidata10TemplateHATraceData:ToXml(System.Text.StringBuilder):System.Text.StringBuilder:this

Top method regressions (percentages):
          40 (34.48% of base) : 203157.dasm - System.Net.WebClient:ByteArrayHasPrefix(System.Byte[],System.Byte[]):bool
          28 (11.11% of base) : 117595.dasm - System.Xml.XmlConverter:StripWhitespace(System.String):System.String
          40 (10.99% of base) : 155695.dasm - System.Collections.Concurrent.ConcurrentBag`1[Byte][System.Byte]:ToArray():System.Byte[]:this
          36 (10.71% of base) : 9083.dasm - Microsoft.FSharp.Collections.ArrayModule:Truncate(int,System.Byte[]):System.Byte[]
          32 (10.39% of base) : 164263.dasm - Microsoft.Internal.Collections.CollectionServices:IsArrayEqual(System.Byte[],System.Byte[]):bool
          32 (10.39% of base) : 205688.dasm - System.Reflection.Context.CollectionServices:CompareArrays(System.Byte[],System.Byte[]):bool
          36 ( 9.89% of base) : 9323.dasm - Microsoft.FSharp.Collections.ArrayModule:TakeWhile(Microsoft.FSharp.Core.FSharpFunc`2[Byte,Boolean],System.Byte[]):System.Byte[]
          28 ( 9.72% of base) : 74951.dasm - Microsoft.Cci.ContentId:FromHash(System.Collections.Immutable.ImmutableArray`1[Byte]):Microsoft.Cci.ContentId
          20 ( 9.09% of base) : 104690.dasm - Newtonsoft.Json.Utilities.MiscellaneousUtils:ByteArrayCompare(System.Byte[],System.Byte[]):int
          32 ( 8.70% of base) : 156445.dasm - System.Linq.ImmutableArrayExtensions:SequenceEqual(System.Collections.Immutable.ImmutableArray`1[Byte],System.Collections.Immutable.ImmutableArray`1[Byte],System.Collections.Generic.IEqualityComparer`1[Byte]):bool
          16 ( 8.00% of base) : 225435.dasm - System.Text.RegularExpressions.Symbolic.BV:op_BitwiseAnd(System.Text.RegularExpressions.Symbolic.BV,System.Text.RegularExpressions.Symbolic.BV):System.Text.RegularExpressions.Symbolic.BV
          16 ( 8.00% of base) : 225436.dasm - System.Text.RegularExpressions.Symbolic.BV:op_BitwiseOr(System.Text.RegularExpressions.Symbolic.BV,System.Text.RegularExpressions.Symbolic.BV):System.Text.RegularExpressions.Symbolic.BV
          16 ( 8.00% of base) : 225467.dasm - System.Text.RegularExpressions.Symbolic.BVAlgebra:And(System.Text.RegularExpressions.Symbolic.BV,System.Text.RegularExpressions.Symbolic.BV):System.Text.RegularExpressions.Symbolic.BV:this
          16 ( 8.00% of base) : 225470.dasm - System.Text.RegularExpressions.Symbolic.BVAlgebra:Or(System.Text.RegularExpressions.Symbolic.BV,System.Text.RegularExpressions.Symbolic.BV):System.Text.RegularExpressions.Symbolic.BV:this
          40 ( 7.81% of base) : 193300.dasm - AppendPrependN`1[Byte][System.Byte]:ToArray():System.Byte[]:this
          12 ( 7.50% of base) : 224833.dasm - System.Text.RegularExpressions.RegexCompiler:AddGoto(int):int:this
          56 ( 7.14% of base) : 161922.dasm - System.Collections.Generic.SortedSet`1[Byte][System.Byte]:OnDeserialization(System.Object):this
          12 ( 6.98% of base) : 25644.dasm - Microsoft.CodeAnalysis.CSharp.DocumentationCommentCompiler:FindMultiLineCommentPattern(System.String):System.String
          12 ( 6.98% of base) : 83875.dasm - Microsoft.Diagnostics.Symbols.SourceFile:ArrayEquals(System.Byte[],System.Byte[]):bool
          12 ( 6.82% of base) : 76007.dasm - Microsoft.CodeAnalysis.ArrayElement`1[Byte][System.Byte]:MakeArray(Microsoft.CodeAnalysis.ArrayElement`1[System.Byte][]):System.Byte[]

Top method improvements (percentages):
         -40 (-21.28% of base) : 123360.dasm - System.Xml.HtmlEncodedRawTextWriter:OutputRestAmps():this
         -28 (-20.00% of base) : 224532.dasm - System.Text.RegularExpressions.RegexInterpreter:TrackPush(int,int,int):this
        -128 (-18.39% of base) : 123505.dasm - System.Xml.XmlEncodedRawTextWriter:WriteCData(System.String):this
         -16 (-17.39% of base) : 191546.dasm - System.Linq.Parallel.FixedMaxHeap`1[Byte][System.Byte]:Swap(int,int):this
         -20 (-17.24% of base) : 224531.dasm - System.Text.RegularExpressions.RegexInterpreter:TrackPush(int,int):this
         -20 (-16.67% of base) : 224534.dasm - System.Text.RegularExpressions.RegexInterpreter:TrackPush2(int,int):this
        -228 (-15.75% of base) : 127712.dasm - System.Xml.DtdParser:ScanAttlist6():int:this
         -44 (-14.67% of base) : 101825.dasm - Microsoft.Diagnostics.Tracing.Ctf.CtfMetadataLegacyParser:FindCloseBrace(System.String,int):int
         -64 (-14.55% of base) : 123506.dasm - System.Xml.XmlEncodedRawTextWriter:WriteComment(System.String):this
         -52 (-14.44% of base) : 110471.dasm - System.Data.Select:Sort(int,int):this
        -120 (-14.08% of base) : 125466.dasm - System.Xml.XmlTextReaderImpl:ParseNamedCharRefInline(int,bool,System.Text.StringBuilder):int:this
        -348 (-14.01% of base) : 127693.dasm - System.Xml.DtdParser:ScanSubsetContent():int:this
        -252 (-14.00% of base) : 236122.dasm - Xunit.Sdk.Sha1Digest:ProcessBlock():this
         -16 (-13.79% of base) : 123532.dasm - <>c:<WriteStartAttributeAsync>b__103_0(System.Xml.XmlEncodedRawTextWriter):this
         -16 (-13.79% of base) : 112076.dasm - System.Data.Common.CharStorage:Compare(int,int):int:this
         -16 (-13.79% of base) : 112859.dasm - System.Data.Common.Int16Storage:Compare(int,int):int:this
         -16 (-13.79% of base) : 113057.dasm - System.Data.Common.UInt16Storage:Compare(int,int):int:this
         -16 (-13.79% of base) : 123491.dasm - System.Xml.XmlEncodedRawTextWriter:WriteStartAttribute_SetInAttribute():this
         -40 (-13.70% of base) : 130220.dasm - Parser:Parse4Dig(int,byref):bool:this
         -80 (-13.70% of base) : 123728.dasm - System.Xml.XmlUtf8RawTextWriter:WriteCData(System.String):this

5932 total methods with Code Size differences (5552 improved, 380 regressed), 2049 unchanged.


libraries_tests.pmi.windows.arm64.checked.mch:


Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 116768772 (overridden on cmd)
Total bytes of diff: 116728516 (overridden on cmd)
Total bytes of delta: -40256 (-0.03 % of base)
    diff is an improvement.
    relative diff is an improvement.
Detail diffs


Top file regressions (bytes):
         124 : 23577.dasm (2.45% of base)
         124 : 23583.dasm (2.44% of base)
         124 : 23589.dasm (2.45% of base)
         124 : 23595.dasm (2.44% of base)
         124 : 23604.dasm (2.44% of base)
         124 : 23610.dasm (2.45% of base)
         124 : 23616.dasm (2.45% of base)
         124 : 23622.dasm (2.44% of base)
         124 : 23694.dasm (2.44% of base)
         124 : 23529.dasm (2.44% of base)
         124 : 23535.dasm (2.44% of base)
         124 : 23541.dasm (2.44% of base)
         124 : 23553.dasm (2.44% of base)
         124 : 23559.dasm (2.44% of base)
         124 : 23565.dasm (2.44% of base)
         124 : 23571.dasm (2.44% of base)
         100 : 23547.dasm (1.55% of base)
          96 : 187243.dasm (4.77% of base)
          76 : 19812.dasm (3.56% of base)
          72 : 290472.dasm (2.98% of base)

Top file improvements (bytes):
        -664 : 94.dasm (-6.53% of base)
        -332 : 201220.dasm (-8.51% of base)
        -324 : 332397.dasm (-4.29% of base)
        -324 : 62.dasm (-4.29% of base)
        -144 : 118819.dasm (-4.96% of base)
        -140 : 332423.dasm (-0.68% of base)
        -124 : 131944.dasm (-8.18% of base)
        -116 : 118818.dasm (-4.68% of base)
        -108 : 223100.dasm (-7.44% of base)
         -96 : 332344.dasm (-2.93% of base)
         -96 : 178189.dasm (-10.81% of base)
         -92 : 332226.dasm (-6.01% of base)
         -88 : 332167.dasm (-9.17% of base)
         -80 : 168719.dasm (-2.80% of base)
         -80 : 168720.dasm (-2.38% of base)
         -76 : 142106.dasm (-0.08% of base)
         -72 : 118676.dasm (-5.33% of base)
         -68 : 300276.dasm (-6.34% of base)
         -64 : 168350.dasm (-2.89% of base)
         -64 : 168351.dasm (-2.69% of base)

6352 total files with Code Size differences (5573 improved, 779 regressed), 1768 unchanged.

Top method regressions (bytes):
         124 ( 2.44% of base) : 23694.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.add001.add001.Test:MainMethod():int
         124 ( 2.44% of base) : 23622.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.devide001.devide001.Test:MainMethod():int
         124 ( 2.45% of base) : 23616.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.equal001.equal001.Test:MainMethod():int
         124 ( 2.45% of base) : 23610.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.greater001.greater001.Test:MainMethod():int
         124 ( 2.44% of base) : 23604.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.greaterequal001.greaterequal001.Test:MainMethod():int
         124 ( 2.44% of base) : 23595.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.leftshift001.leftshift001.Test:MainMethod():int
         124 ( 2.45% of base) : 23589.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.less001.less001.Test:MainMethod():int
         124 ( 2.44% of base) : 23583.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.lessequal001.lessequal001.Test:MainMethod():int
         124 ( 2.45% of base) : 23577.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.logicaland001.logicaland001.Test:MainMethod():int
         124 ( 2.44% of base) : 23571.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.logicalor001.logicalor001.Test:MainMethod():int
         124 ( 2.44% of base) : 23565.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.logicalxor001.logicalxor001.Test:MainMethod():int
         124 ( 2.44% of base) : 23559.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.multi001.multi001.Test:MainMethod():int
         124 ( 2.44% of base) : 23553.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.notequal001.notequal001.Test:MainMethod():int
         124 ( 2.44% of base) : 23541.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.remainder001.remainder001.Test:MainMethod():int
         124 ( 2.44% of base) : 23535.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.rightshift001.rightshift001.Test:MainMethod():int
         124 ( 2.44% of base) : 23529.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.sub001.sub001.Test:MainMethod():int
         100 ( 1.55% of base) : 23547.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.or001.or001.Test:MainMethod():int
          96 ( 4.77% of base) : 187243.dasm - System.Tests.StringTests:EndsWithNoMatch_StringComparison()
          76 ( 3.56% of base) : 19812.dasm - System.Collections.Tests.LinkedList_Generic_Tests`1[Byte][System.Byte]:FindLast_T():this
          72 ( 2.98% of base) : 290472.dasm - System.IO.Ports.Tests.Read_char_int_int:Read_ResizeBuffer():this

Top method improvements (bytes):
        -664 (-6.53% of base) : 94.dasm - System.Text.RegularExpressions.RegexInterpreter:Go():this
        -332 (-8.51% of base) : 201220.dasm - RegexTestNamespace.RegexRunnerTestClass:Go():this
        -324 (-4.29% of base) : 332397.dasm - System.Text.RegularExpressions.RegexWriter:EmitFragment(int,System.Text.RegularExpressions.RegexNode,int):this
        -324 (-4.29% of base) : 62.dasm - System.Text.RegularExpressions.RegexWriter:EmitFragment(int,System.Text.RegularExpressions.RegexNode,int):this
        -144 (-4.96% of base) : 118819.dasm - Microsoft.Build.Evaluation.ExpressionShredder:GetReferencedItemNamesAndMetadata(System.String,int,int,byref,int)
        -140 (-0.68% of base) : 332423.dasm - System.Text.RegularExpressions.Generator.RegexGenerator:<EmitCompleteGo>g__EmitOneCode|11_2(System.String,byref)
        -124 (-8.18% of base) : 131944.dasm - Microsoft.Diagnostics.Runtime.Desktop.DesktopHeapType:FixGenericsWorker(System.String,int,int,System.Text.StringBuilder):int
        -116 (-4.68% of base) : 118818.dasm - Microsoft.Build.Evaluation.ExpressionShredder:GetReferencedItemExpressions(System.String,int,int):System.Collections.Generic.List`1[[Microsoft.Build.Evaluation.ExpressionShredder+ItemExpressionCapture, Microsoft.Build, Version=15.1.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a]]
        -108 (-7.44% of base) : 223100.dasm - DiffPlex.Differ:CalculateEditLength(System.Int32[],int,int,System.Int32[],int,int,System.Int32[],System.Int32[]):DiffPlex.Model.EditLengthResult
         -96 (-10.81% of base) : 178189.dasm - DigestResponse:GetNextValue(System.String,int,bool,byref):System.String:this
         -96 (-2.93% of base) : 332344.dasm - System.Text.RegularExpressions.RegexParser:ScanGroupOpen():System.Text.RegularExpressions.RegexNode:this
         -92 (-6.01% of base) : 332226.dasm - System.Text.RegularExpressions.RegexCode:OpcodeDescription(int,System.Int32[],System.String[]):System.String
         -88 (-9.17% of base) : 332167.dasm - System.Text.RegularExpressions.RegexBoyerMoore:.ctor(System.String,bool,bool,System.Globalization.CultureInfo):this
         -80 (-2.80% of base) : 168719.dasm - System.Linq.Tests.TakeTests:MutableSource():this
         -80 (-2.38% of base) : 168720.dasm - System.Linq.Tests.TakeTests:MutableSourceNotList():this
         -76 (-0.08% of base) : 142106.dasm - <ValidateIdentifiers_Invalid_TestData>d__2:MoveNext():bool:this
         -72 (-5.33% of base) : 118676.dasm - Microsoft.Build.Evaluation.Scanner:Advance():bool:this
         -68 (-6.34% of base) : 300276.dasm - System.IPv6AddressHelper:Parse(System.ReadOnlySpan`1[Char],System.Span`1[UInt16],int,byref)
         -64 (-2.68% of base) : 242194.dasm - Microsoft.DotNet.ProjectModel.FileSystemGlobbing.Internal.Patterns.PatternBuilder:Build(System.String):Microsoft.DotNet.ProjectModel.FileSystemGlobbing.Internal.IPattern:this
         -64 (-2.89% of base) : 168350.dasm - System.Linq.Tests.SelectTests:Select_SourceIsListSkipTakeCount():this

Top method regressions (percentages):
          24 (10.00% of base) : 1595.dasm - Roslyn.Utilities.PathUtilities:PathsEqual(System.String,System.String,int):bool
          28 ( 8.43% of base) : 307752.dasm - System.Numerics.Tests.GenericVectorTests:TestDotProduct():this
          28 ( 7.95% of base) : 3578.dasm - Microsoft.CodeAnalysis.ImmutableArrayExtensions:SequenceEqual(System.Collections.Immutable.ImmutableArray`1[Byte],System.Collections.Immutable.ImmutableArray`1[Byte],System.Nullable`1[Int32],System.Func`4[Byte,Byte,Nullable`1,Boolean]):bool
           8 ( 7.69% of base) : 1055.dasm - Roslyn.Utilities.ObjectReader:ReadInt8ArrayElements(System.SByte[]):System.SByte[]:this
          12 ( 7.50% of base) : 308494.dasm - System.Numerics.Tests.Util:AllEqual(System.Byte[],System.Byte[]):bool
          12 ( 7.50% of base) : 308493.dasm - System.Numerics.Tests.Util:AnyEqual(System.Byte[],System.Byte[]):bool
          12 ( 7.32% of base) : 193092.dasm - System.Security.Cryptography.Encryption.TripleDes.Tests.TripleDesTests:RemoveDesParityBits(System.Byte[]):System.Byte[]
          40 ( 7.25% of base) : 115886.dasm - Microsoft.Build.Shared.FileUtilities:PathsEqual(System.String,System.String):bool
          40 ( 7.25% of base) : 238332.dasm - Microsoft.Build.Shared.FileUtilities:PathsEqual(System.String,System.String):bool
          40 ( 7.25% of base) : 122227.dasm - Microsoft.Build.Shared.FileUtilities:PathsEqual(System.String,System.String):bool
          12 ( 6.98% of base) : 153990.dasm - BasicEventSourceTests.TestsWriteEvent:Equal(System.Byte[],System.Byte[]):bool
          12 ( 6.98% of base) : 338690.dasm - System.Transactions.Tests.NonMsdtcPromoterTests:PromotedTokensMatch(System.Byte[],System.Byte[]):bool
          12 ( 6.82% of base) : 251089.dasm - Microsoft.VisualStudio.Composition.Utilities:EqualsByValue(System.Collections.Immutable.ImmutableArray`1[Byte],System.Collections.Immutable.ImmutableArray`1[Byte]):bool
          12 ( 6.67% of base) : 224173.dasm - ImTools.ArrayTools:Copy(System.Byte[]):System.Byte[]
          12 ( 6.67% of base) : 284829.dasm - System.IO.Compression.Tests.ZipFileTestBase:ArraysEqual(System.Byte[],System.Byte[]):bool
          12 ( 6.67% of base) : 285293.dasm - System.IO.Compression.Tests.ZipFileTestBase:ArraysEqual(System.Byte[],System.Byte[]):bool
           8 ( 6.67% of base) : 100111.dasm - System.Text.Json.Serialization.Tests.StreamTests:GetArr_TypedElements(int):System.Byte[]
           8 ( 6.45% of base) : 167542.dasm - System.Linq.Tests.EnumerableTests:Repeat(System.Func`2[Int32,Byte],int):System.Byte[]
          12 ( 6.25% of base) : 251288.dasm - BufferComparer:Equals(System.Byte[],System.Byte[]):bool:this
          12 ( 6.25% of base) : 3620.dasm - Microsoft.CodeAnalysis.ImmutableArrayExtensions:All(System.Collections.Immutable.ImmutableArray`1[Byte],System.Func`3[Byte,Nullable`1,Boolean],System.Nullable`1[Int32]):bool

Top method improvements (percentages):
         -16 (-16.67% of base) : 112477.dasm - Piles@527-4:Invoke(int,int):Microsoft.FSharp.Core.Unit:this
         -16 (-16.67% of base) : 112412.dasm - Shuffle@437-5[Byte][System.Byte]:Invoke(int,int):Microsoft.FSharp.Core.Unit:this
         -16 (-16.67% of base) : 112394.dasm - shuffleInPlace@426-3[Byte][System.Byte]:Invoke(int,int):Microsoft.FSharp.Core.Unit:this
         -56 (-15.38% of base) : 133225.dasm - Microsoft.Diagnostics.Runtime.Utilities.Pdb.BitAccess:ReadInt64(byref):this
         -16 (-14.29% of base) : 22692.dasm - <>c__DisplayClass16_1[__Canon][System.__Canon]:<GetRangeValidations>b__0():System.Object:this
         -16 (-14.29% of base) : 22693.dasm - <>c__DisplayClass16_1[Byte][System.Byte]:<GetRangeValidations>b__0():System.Object:this
         -16 (-14.29% of base) : 22694.dasm - <>c__DisplayClass16_2[__Canon][System.__Canon]:<GetRangeValidations>b__1():System.Object:this
         -16 (-14.29% of base) : 22695.dasm - <>c__DisplayClass16_2[Byte][System.Byte]:<GetRangeValidations>b__1():System.Object:this
         -52 (-14.29% of base) : 118981.dasm - Microsoft.Build.Internal.Utilities:ContainsNoTagsOtherThanComments(System.String,int):bool
         -24 (-13.95% of base) : 315605.dasm - BR:ReadInt32():int:this
         -16 (-13.33% of base) : 202361.dasm - <>c__DisplayClass14_0:<NamedBlocksInclusionsExpected>b__0(ushort):bool:this
         -12 (-13.04% of base) : 97.dasm - System.Text.RegularExpressions.RegexInterpreter:TrackPush(int):this
         -24 (-12.77% of base) : 133224.dasm - Microsoft.Diagnostics.Runtime.Utilities.Pdb.BitAccess:ReadInt32(byref):this
         -20 (-12.50% of base) : 298243.dasm - System.Net.Mime.MailBnfHelper:IsFWSAt(System.String,int):bool
         -24 (-12.50% of base) : 300731.dasm - System.Net.SocketAddress:CopyAddressSizeIntoBuffer():this
         -24 (-12.50% of base) : 300440.dasm - System.Net.SocketAddress:CopyAddressSizeIntoBuffer():this
         -28 (-11.67% of base) : 238449.dasm - Microsoft.Build.Shared.FileMatcher:HasMisplacedRecursiveOperator(System.String):bool
         -28 (-11.67% of base) : 116026.dasm - Microsoft.Build.Shared.FileMatcher:HasMisplacedRecursiveOperator(System.String):bool
         -28 (-11.67% of base) : 122216.dasm - Microsoft.Build.Shared.FileMatcher:HasMisplacedRecursiveOperator(System.String):bool
         -56 (-11.48% of base) : 217495.dasm - System.Data.SqlClient.TdsParser:WriteLong(long,System.Data.SqlClient.TdsParserStateObject):this

6352 total methods with Code Size differences (5573 improved, 779 regressed), 1768 unchanged.


some diffs we weren't able to fold cloned loops because of it, e.g. for:

private static bool Test(byte[] prefix, byte[] byteArray)
{
    if (prefix == null || byteArray == null || prefix.Length > byteArray.Length)
        return false;
    for (int i = 0; i < prefix.Length; i++)
    {
        if (prefix[i] != byteArray[i])
            return false;
    }
    return true;
}

^ diff: https://www.diffchecker.com/oUPb1br3
We clone the loop in both my PR and Main, but in Main we then are able to drop it, but not it "PR" due to that CSE of ADD. Both loops don't have bound checks. Btw, number of bl CORINFO_HELP_RNGCHKFAIL is the same in base and diff diffs so I assume this PR doesn't regress bound check elimination.

A couple of size-regression examples:
https://www.diffchecker.com/VkGHhEin
https://www.diffchecker.com/nOuaRBkO
https://www.diffchecker.com/LDIAWDHY

improvements:
https://www.diffchecker.com/zxoJy9vQ

@dotnet-issue-labeler dotnet-issue-labeler bot added the area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI label Nov 7, 2021
@ghost
Copy link

ghost commented Nov 7, 2021

Tagging subscribers to this area: @JulieLeeMSFT
See info in area-owners.md if you want to be subscribed.

Issue Details

Usually, for a typical array access we create arrRef + (index + elemOffset) tree which is basically invariant1 + (X + invariant2), if we change it to (arrRef + elemOffset) + index we'll be able to hoist/CSE the invariant part arrRef + elemOffset, Example:

int Test(int[] array, int i, int j) 
    => array[i] + array[j];

int Sum(int[] array)
{
    int sum = 0;
    foreach (int item in array)
        sum += item;
    return sum;
}

codegen diff:

; Method Tests:Test(System.Int32[],int,int):int:this
G_M15096_IG01:
            stp     fp, lr, [sp,#-16]!
            mov     fp, sp
G_M15096_IG02:
            ldr     w0, [x1,#8]
            cmp     w2, w0
            bhs     G_M15096_IG04
+           add     x1, x1, #16
            ubfiz   x2, x2, #2, #32
-           add     x2, x2, #16
            ldr     w2, [x1, x2]
            cmp     w3, w0
            bhs     G_M15096_IG04
            ubfiz   x0, x3, #2, #32
-           add     x0, x0, #16
            ldr     w0, [x1, x0]
            add     w0, w2, w0
G_M15096_IG03:
            ldp     fp, lr, [sp],#16
            ret     lr
G_M15096_IG04:
            bl      CORINFO_HELP_RNGCHKFAIL
            bkpt    
-; Total bytes of code: 72
+; Total bytes of code: 68


; Method Tests:Sum(System.Int32[]):int:this
G_M56165_IG01:
            stp     fp, lr, [sp,#-16]!
            mov     fp, sp
G_M56165_IG02:
            mov     w0, wzr
            mov     w2, wzr
            ldr     w3, [x1,#8]
            cmp     w3, #0
            ble     G_M56165_IG04
+           add     x1, x1, #16
G_M56165_IG03:
            ubfiz   x4, x2, #2, #32
-           add     x4, x4, #16
            ldr     w4, [x1, x4]
            add     w0, w0, w4
            add     w2, w2, #1
            cmp     w3, w2
            bgt     G_M56165_IG03
G_M56165_IG04:
            ldp     fp, lr, [sp],#16
            ret     lr
; Total bytes of code: 64

In Tests.Sum it made loop body smaller.

Diffs:

coreclr_tests.pmi.Linux.arm64.checked.mch:


Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 165343072 (overridden on cmd)
Total bytes of diff: 165275312 (overridden on cmd)
Total bytes of delta: -67760 (-0.04 % of base)
    diff is an improvement.
    relative diff is an improvement.
Detail diffs


Top file regressions (bytes):
         168 : 245100.dasm (4.19% of base)
          92 : 195092.dasm (1.85% of base)
          88 : 243719.dasm (6.71% of base)
          80 : 187917.dasm (6.27% of base)
          80 : 187942.dasm (6.15% of base)
          80 : 192069.dasm (6.27% of base)
          80 : 192094.dasm (6.15% of base)
          80 : 188051.dasm (6.27% of base)
          80 : 188076.dasm (6.15% of base)
          76 : 247310.dasm (4.44% of base)
          72 : 252198.dasm (1.64% of base)
          68 : 144070.dasm (8.99% of base)
          68 : 144149.dasm (9.04% of base)
          68 : 144257.dasm (9.04% of base)
          68 : 192254.dasm (9.24% of base)
          68 : 208087.dasm (9.04% of base)
          68 : 208164.dasm (9.09% of base)
          68 : 126695.dasm (9.04% of base)
          68 : 163268.dasm (9.04% of base)
          68 : 208267.dasm (9.09% of base)

Top file improvements (bytes):
        -760 : 245095.dasm (-7.26% of base)
        -544 : 187914.dasm (-18.63% of base)
        -544 : 192066.dasm (-18.63% of base)
        -544 : 188048.dasm (-18.63% of base)
        -396 : 187889.dasm (-15.52% of base)
        -396 : 192041.dasm (-15.52% of base)
        -396 : 188023.dasm (-15.52% of base)
        -300 : 187910.dasm (-14.85% of base)
        -300 : 192062.dasm (-14.85% of base)
        -300 : 188044.dasm (-14.85% of base)
        -228 : 192040.dasm (-12.50% of base)
        -228 : 187888.dasm (-12.50% of base)
        -228 : 188022.dasm (-12.50% of base)
        -196 : 187913.dasm (-18.15% of base)
        -196 : 192065.dasm (-18.15% of base)
        -196 : 188047.dasm (-18.15% of base)
        -172 : 219860.dasm (-5.19% of base)
        -156 : 192292.dasm (-4.50% of base)
        -148 : 192039.dasm (-12.46% of base)
        -148 : 187887.dasm (-12.46% of base)

25688 total files with Code Size differences (22097 improved, 3591 regressed), 4787 unchanged.

Top method regressions (bytes):
         168 ( 4.19% of base) : 245100.dasm - Co1245GetBytes_double:runTest():bool:this
          92 ( 1.85% of base) : 195092.dasm - Internal.TypeSystem.MetadataFieldLayoutAlgorithm:ComputeAutoFieldLayout(Internal.TypeSystem.MetadataType,int):Internal.TypeSystem.ComputedInstanceFieldLayout:this
          88 ( 6.71% of base) : 243719.dasm - Benchstone.BenchF.LLoops:Init():this
          80 ( 6.15% of base) : 187942.dasm - IntelHardwareIntrinsicTest.TestTableScalarSse2`2[Byte,Int64][System.Byte,System.Int64]:Initialize(int):this
          80 ( 6.15% of base) : 192094.dasm - IntelHardwareIntrinsicTest.TestTableScalarSse2`2[Byte,Int64][System.Byte,System.Int64]:Initialize(int):this
          80 ( 6.15% of base) : 188076.dasm - IntelHardwareIntrinsicTest.TestTableScalarSse2`2[Byte,Int64][System.Byte,System.Int64]:Initialize(int):this
          80 ( 6.27% of base) : 187917.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:Initialize(int):this
          80 ( 6.27% of base) : 192069.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:Initialize(int):this
          80 ( 6.27% of base) : 188051.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:Initialize(int):this
          76 ( 4.44% of base) : 247310.dasm - AutoGen.Program:Func1(AutoGen.VType1,long,int,AutoGen.VType2):AutoGen.VType1:this
          72 ( 1.64% of base) : 252198.dasm - Test:Main():int
          68 ( 9.24% of base) : 192254.dasm - EMFloatClass:Run():double:this
          68 ( 9.04% of base) : 144257.dasm - testout1:Sub_Funclet_207():int
          68 ( 9.04% of base) : 126695.dasm - testout1:Sub_Funclet_207():int
          68 ( 9.09% of base) : 208267.dasm - testout1:Sub_Funclet_207():int
          68 ( 9.09% of base) : 163458.dasm - testout1:Sub_Funclet_207():int
          68 ( 9.04% of base) : 144149.dasm - testout1:Sub_Funclet_287():int
          68 ( 9.09% of base) : 208164.dasm - testout1:Sub_Funclet_287():int
          68 ( 9.09% of base) : 163347.dasm - testout1:Sub_Funclet_287():int
          68 ( 9.04% of base) : 126583.dasm - testout1:Sub_Funclet_287():int

Top method improvements (bytes):
        -760 (-7.26% of base) : 245095.dasm - SimpleArray_01.Test:Test1()
        -544 (-18.63% of base) : 187914.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetHexadecaDataPoint(int):System.ValueTuple`8[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`1]:this
        -544 (-18.63% of base) : 192066.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetHexadecaDataPoint(int):System.ValueTuple`8[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`1]:this
        -544 (-18.63% of base) : 188048.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetHexadecaDataPoint(int):System.ValueTuple`8[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`1]:this
        -396 (-15.52% of base) : 187889.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodSixteenOfAll`2[Byte,Int64]):bool:this
        -396 (-15.52% of base) : 192041.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodSixteenOfAll`2[Byte,Int64]):bool:this
        -396 (-15.52% of base) : 188023.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodSixteenOfAll`2[Byte,Int64]):bool:this
        -300 (-14.85% of base) : 187910.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetCheckMethodSixteen4DataPoint(int):System.ValueTuple`6[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -300 (-14.85% of base) : 192062.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetCheckMethodSixteen4DataPoint(int):System.ValueTuple`6[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -300 (-14.85% of base) : 188044.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetCheckMethodSixteen4DataPoint(int):System.ValueTuple`6[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -228 (-12.50% of base) : 192040.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckPackSaturate(IntelHardwareIntrinsicTest.CheckMethodSixteen`2[Byte,Int64]):bool:this
        -228 (-12.50% of base) : 187888.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckPackSaturate(IntelHardwareIntrinsicTest.CheckMethodSixteen`2[Byte,Int64]):bool:this
        -228 (-12.50% of base) : 188022.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckPackSaturate(IntelHardwareIntrinsicTest.CheckMethodSixteen`2[Byte,Int64]):bool:this
        -196 (-18.15% of base) : 187913.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetOcta88DataPoint(int):System.ValueTuple`4[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -196 (-18.15% of base) : 192065.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetOcta88DataPoint(int):System.ValueTuple`4[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -196 (-18.15% of base) : 188047.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetOcta88DataPoint(int):System.ValueTuple`4[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -172 (-5.19% of base) : 219860.dasm - JIT.HardwareIntrinsics.X86.SimpleBinaryOpTest__MultipleSumAbsoluteDifferences:ValidateResult(System.Byte[],System.Byte[],ubyte,System.UInt16[],System.String):this
        -156 (-4.50% of base) : 192292.dasm - LUDecomp:ludcmp(System.Double[][],int,System.Int32[],byref):int
        -148 (-12.46% of base) : 192039.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodEightOfTEightOfU`2[Byte,Int64]):bool:this
        -148 (-12.46% of base) : 187887.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodEightOfTEightOfU`2[Byte,Int64]):bool:this

Top method regressions (percentages):
          52 (15.66% of base) : 208360.dasm - testout1:Sub_Funclet_111():int
          52 (15.66% of base) : 163572.dasm - testout1:Sub_Funclet_79():int
          52 (15.66% of base) : 208344.dasm - testout1:Sub_Funclet_95():int
          52 (15.48% of base) : 126791.dasm - testout1:Sub_Funclet_111():int
          52 (15.48% of base) : 208363.dasm - testout1:Sub_Funclet_114():int
          52 (15.48% of base) : 208103.dasm - testout1:Sub_Funclet_354():int
          52 (15.48% of base) : 126853.dasm - testout1:Sub_Funclet_47():int
          52 (15.48% of base) : 200428.dasm - testout1:Sub_Funclet_82():int
          52 (15.48% of base) : 126775.dasm - testout1:Sub_Funclet_95():int
          52 (15.48% of base) : 208347.dasm - testout1:Sub_Funclet_98():int
          52 (15.29% of base) : 126794.dasm - testout1:Sub_Funclet_114():int
          52 (15.29% of base) : 200366.dasm - testout1:Sub_Funclet_143():int
          52 (15.29% of base) : 208132.dasm - testout1:Sub_Funclet_319():int
          52 (15.29% of base) : 200161.dasm - testout1:Sub_Funclet_319():int
          52 (15.29% of base) : 200132.dasm - testout1:Sub_Funclet_354():int
          52 (15.29% of base) : 126522.dasm - testout1:Sub_Funclet_354():int
          52 (15.29% of base) : 126824.dasm - testout1:Sub_Funclet_82():int
          52 (15.29% of base) : 126778.dasm - testout1:Sub_Funclet_98():int
          52 (15.12% of base) : 154646.dasm - testout1:Sub_Funclet_143():int
          52 (15.12% of base) : 154450.dasm - testout1:Sub_Funclet_319():int

Top method improvements (percentages):
        -544 (-18.63% of base) : 187914.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetHexadecaDataPoint(int):System.ValueTuple`8[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`1]:this
        -544 (-18.63% of base) : 192066.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetHexadecaDataPoint(int):System.ValueTuple`8[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`1]:this
        -544 (-18.63% of base) : 188048.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetHexadecaDataPoint(int):System.ValueTuple`8[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`1]:this
        -196 (-18.15% of base) : 187913.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetOcta88DataPoint(int):System.ValueTuple`4[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -196 (-18.15% of base) : 192065.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetOcta88DataPoint(int):System.ValueTuple`4[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -196 (-18.15% of base) : 188047.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetOcta88DataPoint(int):System.ValueTuple`4[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
          -4 (-16.67% of base) : 5306.dasm - JIT.HardwareIntrinsics.Arm.Helpers:BitwiseClear(int,int):int
          -4 (-16.67% of base) : 5313.dasm - JIT.HardwareIntrinsics.Arm.Helpers:BitwiseClear(int,int):int
          -4 (-16.67% of base) : 5256.dasm - JIT.HardwareIntrinsics.Arm.Helpers:BitwiseClear(long,long):long
          -4 (-16.67% of base) : 5263.dasm - JIT.HardwareIntrinsics.Arm.Helpers:BitwiseClear(long,long):long
        -396 (-15.52% of base) : 187889.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodSixteenOfAll`2[Byte,Int64]):bool:this
        -396 (-15.52% of base) : 192041.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodSixteenOfAll`2[Byte,Int64]):bool:this
        -396 (-15.52% of base) : 188023.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:CheckUnpack(IntelHardwareIntrinsicTest.CheckMethodSixteenOfAll`2[Byte,Int64]):bool:this
        -300 (-14.85% of base) : 187910.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetCheckMethodSixteen4DataPoint(int):System.ValueTuple`6[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -300 (-14.85% of base) : 192062.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetCheckMethodSixteen4DataPoint(int):System.ValueTuple`6[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
        -300 (-14.85% of base) : 188044.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetCheckMethodSixteen4DataPoint(int):System.ValueTuple`6[ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8,ValueTuple`8]:this
         -28 (-13.73% of base) : 216197.dasm - V8.Crypto.Arcfour:next():int:this
         -24 (-13.33% of base) : 195863.dasm - Internal.IL.ILDisassembler:ReadILUInt32():int:this
        -112 (-12.61% of base) : 187909.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetCheckMethodSix4DataPoint(int):System.ValueTuple`4[ValueTuple`4,ValueTuple`4,ValueTuple`8,ValueTuple`8]:this
        -112 (-12.61% of base) : 192061.dasm - IntelHardwareIntrinsicTest.TestTableSse2`2[Byte,Int64][System.Byte,System.Int64]:GetCheckMethodSix4DataPoint(int):System.ValueTuple`4[ValueTuple`4,ValueTuple`4,ValueTuple`8,ValueTuple`8]:this

25688 total methods with Code Size differences (22097 improved, 3591 regressed), 4787 unchanged.


libraries.crossgen2.Linux.arm64.checked.mch:


Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 48375348 (overridden on cmd)
Total bytes of diff: 48375336 (overridden on cmd)
Total bytes of delta: -12 (-0.00 % of base)
    diff is an improvement.
    relative diff is an improvement.
Detail diffs


Top file regressions (bytes):
         440 : 94655.dasm (5.40% of base)
         264 : 97660.dasm (5.19% of base)
         256 : 94651.dasm (4.73% of base)
         212 : 82984.dasm (1.68% of base)
         212 : 103822.dasm (10.15% of base)
         116 : 82982.dasm (5.09% of base)
         112 : 166830.dasm (3.78% of base)
         100 : 188372.dasm (2.99% of base)
          92 : 92381.dasm (1.67% of base)
          92 : 24749.dasm (1.71% of base)
          92 : 113982.dasm (3.36% of base)
          92 : 97646.dasm (1.23% of base)
          92 : 24520.dasm (6.87% of base)
          80 : 166829.dasm (2.92% of base)
          80 : 160745.dasm (0.51% of base)
          80 : 70362.dasm (4.02% of base)
          76 : 91104.dasm (2.32% of base)
          76 : 84230.dasm (4.32% of base)
          72 : 139011.dasm (4.39% of base)
          68 : 36525.dasm (4.08% of base)

Top file improvements (bytes):
        -368 : 118049.dasm (-7.28% of base)
        -228 : 120709.dasm (-8.81% of base)
        -228 : 120541.dasm (-7.84% of base)
        -184 : 120694.dasm (-7.34% of base)
        -184 : 120523.dasm (-6.51% of base)
        -172 : 205506.dasm (-9.33% of base)
        -152 : 120690.dasm (-10.22% of base)
        -152 : 120521.dasm (-7.45% of base)
        -128 : 28972.dasm (-7.03% of base)
         -92 : 65546.dasm (-0.94% of base)
         -88 : 120679.dasm (-7.83% of base)
         -88 : 120503.dasm (-6.04% of base)
         -84 : 120877.dasm (-16.94% of base)
         -80 : 124822.dasm (-12.20% of base)
         -80 : 124612.dasm (-13.16% of base)
         -80 : 97664.dasm (-7.12% of base)
         -80 : 97665.dasm (-7.12% of base)
         -80 : 124727.dasm (-7.78% of base)
         -80 : 124520.dasm (-8.10% of base)
         -72 : 94656.dasm (-5.79% of base)

3433 total files with Code Size differences (1878 improved, 1555 regressed), 6389 unchanged.

Top method regressions (bytes):
         440 ( 5.40% of base) : 94655.dasm - System.Data.RBTree`1:RBInsert(int,int,int,int,bool):int:this
         264 ( 5.19% of base) : 97660.dasm - System.Data.RBTree`1:RBDeleteX(int,int,int):int:this
         256 ( 4.73% of base) : 94651.dasm - System.Data.RBTree`1:RBDeleteX(int,int,int):int:this
         212 (10.15% of base) : 103822.dasm - Microsoft.CSharp.RuntimeBinder.Errors.ErrorHandling:Error(int,Microsoft.CSharp.RuntimeBinder.Errors.ErrArg[]):Microsoft.CSharp.RuntimeBinder.RuntimeBinderException
         212 ( 1.68% of base) : 82984.dasm - System.DefaultBinder:BindToMethod(int,System.Reflection.MethodBase[],byref,System.Reflection.ParameterModifier[],System.Globalization.CultureInfo,System.String[],byref):System.Reflection.MethodBase:this
         116 ( 5.09% of base) : 82982.dasm - System.DefaultBinder:SelectMethod(int,System.Reflection.MethodBase[],System.Type[],System.Reflection.ParameterModifier[]):System.Reflection.MethodBase:this
         112 ( 3.78% of base) : 166830.dasm - System.DefaultBinder:SelectMethod(int,System.Reflection.MethodBase[],System.Type[],System.Reflection.ParameterModifier[]):System.Reflection.MethodBase:this
         100 ( 2.99% of base) : 188372.dasm - ProxyBuilder:AddMethodImpl(System.Reflection.MethodInfo,int):System.Reflection.Emit.MethodBuilder:this
          92 ( 1.71% of base) : 24749.dasm - Internal.TypeSystem.MetadataFieldLayoutAlgorithm:ComputeAutoFieldLayout(Internal.TypeSystem.MetadataType,int):Internal.TypeSystem.ComputedInstanceFieldLayout:this
          92 ( 6.87% of base) : 24520.dasm - Internal.TypeSystem.RuntimeDeterminedTypeUtilities:ConvertInstantiationToSharedRuntimeForm(Internal.TypeSystem.Instantiation,Internal.TypeSystem.Instantiation,byref):Internal.TypeSystem.Instantiation
          92 ( 1.67% of base) : 92381.dasm - System.Data.Common.DbDataAdapter:Update(System.Data.DataRow[],System.Data.Common.DataTableMapping):int:this
          92 ( 1.23% of base) : 97646.dasm - System.Data.RBTree`1:RBInsert(int,int,int,int,bool):int:this
          92 ( 3.36% of base) : 113982.dasm - System.Xml.Serialization.TempAssembly:GenerateRefEmitAssembly(System.Xml.Serialization.XmlMapping[],System.Type[],System.String):System.Reflection.Assembly
          80 ( 0.51% of base) : 160745.dasm - Microsoft.CodeAnalysis.VisualBasic.Binder:ReportOverloadResolutionFailureForASingleCandidate(Microsoft.CodeAnalysis.VisualBasic.VisualBasicSyntaxNode,Microsoft.CodeAnalysis.Location,int,byref,System.Collections.Immutable.ImmutableArray`1[Microsoft.CodeAnalysis.VisualBasic.BoundExpression],System.Collections.Immutable.ImmutableArray`1[System.String],bool,bool,bool,bool,Microsoft.CodeAnalysis.DiagnosticBag,Microsoft.CodeAnalysis.VisualBasic.Symbol,bool,Microsoft.CodeAnalysis.VisualBasic.VisualBasicSyntaxNode,Microsoft.CodeAnalysis.VisualBasic.Symbol):this
          80 ( 2.92% of base) : 166829.dasm - System.DefaultBinder:SelectProperty(int,System.Reflection.PropertyInfo[],System.Type,System.Type[],System.Reflection.ParameterModifier[]):System.Reflection.PropertyInfo:this
          80 ( 4.02% of base) : 70362.dasm - System.Reflection.Emit.MethodBuilder:CreateMethodBodyHelper(System.Reflection.Emit.ILGenerator):this
          76 ( 2.32% of base) : 91104.dasm - Microsoft.VisualBasic.CompilerServices.OverloadResolution:CanMatchArguments(Microsoft.VisualBasic.CompilerServices.Symbols+Method,System.Object[],System.String[],System.Type[],bool,System.Collections.Generic.List`1[System.String]):bool
          76 ( 4.32% of base) : 84230.dasm - System.Type:FindMembers(int,int,System.Reflection.MemberFilter,System.Object):System.Reflection.MemberInfo[]:this
          72 ( 4.39% of base) : 139011.dasm - ReferenceManager:SetupReferencesForRetargetingAssembly(Microsoft.CodeAnalysis.CommonReferenceManager`2+BoundInputAssembly[Microsoft.CodeAnalysis.VisualBasic.VisualBasicCompilation, Microsoft.CodeAnalysis.VisualBasic.Symbols.AssemblySymbol][],int,byref,Microsoft.CodeAnalysis.VisualBasic.Symbols.SourceAssemblySymbol)
          68 ( 4.08% of base) : 36525.dasm - ReferenceManager:SetupReferencesForRetargetingAssembly(Microsoft.CodeAnalysis.CommonReferenceManager`2+BoundInputAssembly[Microsoft.CodeAnalysis.CSharp.CSharpCompilation, Microsoft.CodeAnalysis.CSharp.Symbols.AssemblySymbol][],int,byref,Microsoft.CodeAnalysis.CSharp.Symbols.SourceAssemblySymbol)

Top method improvements (bytes):
        -368 (-7.28% of base) : 118049.dasm - System.Xml.Schema.XmlSchemaInference:InferSimpleType(System.String,byref):int
        -228 (-7.84% of base) : 120541.dasm - <ScanSubsetContentAsync>d__174:MoveNext():this
        -228 (-8.81% of base) : 120709.dasm - System.Xml.DtdParser:ScanSubsetContent():int:this
        -184 (-6.51% of base) : 120523.dasm - <ScanAttlist2Async>d__183:MoveNext():this
        -184 (-7.34% of base) : 120694.dasm - System.Xml.DtdParser:ScanAttlist2():int:this
        -172 (-9.33% of base) : 205506.dasm - Xunit.Sdk.Sha1Digest:ProcessBlock():this
        -152 (-7.45% of base) : 120521.dasm - <ScanAttlist6Async>d__184:MoveNext():this
        -152 (-10.22% of base) : 120690.dasm - System.Xml.DtdParser:ScanAttlist6():int:this
        -128 (-7.03% of base) : 28972.dasm - Filter:populateMask(Microsoft.FSharp.Core.FSharpFunc`2[System.__Canon, System.Boolean],System.__Canon[],System.UInt32[]):int
         -92 (-0.94% of base) : 65546.dasm - System.Text.RegularExpressions.RegexInterpreter:Go():this
         -88 (-6.04% of base) : 120503.dasm - <ScanCondSection1Async>d__193:MoveNext():this
         -88 (-7.83% of base) : 120679.dasm - System.Xml.DtdParser:ScanCondSection1():int:this
         -84 (-16.94% of base) : 120877.dasm - System.Xml.XmlNodeReaderNavigator:InitDecAttr():this
         -80 (-7.78% of base) : 124727.dasm - <WriteCDataAsync>d__109:MoveNext():this
         -80 (-8.10% of base) : 124520.dasm - <WriteCDataAsync>d__98:MoveNext():this
         -80 (-7.12% of base) : 97665.dasm - System.Data.RBTree`1:LeftRotate(int,int,int):int:this
         -80 (-7.12% of base) : 97664.dasm - System.Data.RBTree`1:RightRotate(int,int,int):int:this
         -80 (-12.20% of base) : 124822.dasm - System.Xml.XmlEncodedRawTextWriter:WriteCData(System.String):this
         -80 (-13.16% of base) : 124612.dasm - System.Xml.XmlUtf8RawTextWriter:WriteCData(System.String):this
         -72 (-5.79% of base) : 94657.dasm - System.Data.RBTree`1:LeftRotate(int,int,int):int:this

Top method regressions (percentages):
          40 (34.48% of base) : 172020.dasm - System.Net.WebClient:ByteArrayHasPrefix(System.Byte[],System.Byte[]):bool
          16 (16.67% of base) : 65010.dasm - System.Text.RegularExpressions.Symbolic.SymbolicRegexInfo:Or(System.Text.RegularExpressions.Symbolic.SymbolicRegexInfo[]):System.Text.RegularExpressions.Symbolic.SymbolicRegexInfo
          16 (13.79% of base) : 65009.dasm - System.Text.RegularExpressions.Symbolic.SymbolicRegexInfo:And(System.Text.RegularExpressions.Symbolic.SymbolicRegexInfo[]):System.Text.RegularExpressions.Symbolic.SymbolicRegexInfo
          24 (12.50% of base) : 104919.dasm - Microsoft.CSharp.RuntimeBinder.RuntimeBinderExtensions:GetIndexerName(System.Type):System.String
         212 (10.15% of base) : 103822.dasm - Microsoft.CSharp.RuntimeBinder.Errors.ErrorHandling:Error(int,Microsoft.CSharp.RuntimeBinder.Errors.ErrArg[]):Microsoft.CSharp.RuntimeBinder.RuntimeBinderException
          40 (10.10% of base) : 203815.dasm - ConstructorMatcher:Match(System.Object[]):int:this
          40 ( 9.62% of base) : 171669.dasm - System.Linq.ImmutableArrayExtensions:SequenceEqual(System.Collections.Immutable.ImmutableArray`1[System.__Canon],System.Collections.Immutable.ImmutableArray`1[System.__Canon],System.Collections.Generic.IEqualityComparer`1[System.__Canon]):bool
          28 ( 9.59% of base) : 133875.dasm - Newtonsoft.Json.Utilities.MiscellaneousUtils:ByteArrayCompare(System.Byte[],System.Byte[]):int
          24 ( 9.09% of base) : 155825.dasm - Microsoft.CodeAnalysis.VisualBasic.CodeGen.CodeGenerator:EmitSwitch(System.Collections.Immutable.ImmutableArray`1[Microsoft.CodeAnalysis.VisualBasic.BoundGotoStatement]):this
          36 ( 9.00% of base) : 78152.dasm - System.Globalization.CalendricalCalculationsHelper:EphemerisCorrection(double):double
          28 ( 8.97% of base) : 77600.dasm - System.Globalization.DateTimeFormatInfoScanner:EqualStringArrays(System.String[],System.String[]):bool
          28 ( 8.64% of base) : 24021.dasm - InstantiatedMethodKeyHashtable:CompareKeyToValue(Internal.TypeSystem.TypeSystemContext+InstantiatedMethodKey,Internal.TypeSystem.InstantiatedMethod):bool:this
          28 ( 8.64% of base) : 24020.dasm - InstantiatedMethodKeyHashtable:CompareValueToValue(Internal.TypeSystem.InstantiatedMethod,Internal.TypeSystem.InstantiatedMethod):bool:this
          12 ( 8.57% of base) : 85321.dasm - System.Delegate:Combine(System.Delegate[]):System.Delegate
          12 ( 8.57% of base) : 65471.dasm - System.Text.RegularExpressions.RegexParser:Escape(System.String):System.String
          28 ( 8.54% of base) : 24026.dasm - InstantiatedTypeKeyHashtable:CompareKeyToValue(Internal.TypeSystem.TypeSystemContext+InstantiatedTypeKey,Internal.TypeSystem.InstantiatedType):bool:this
          28 ( 8.43% of base) : 24025.dasm - InstantiatedTypeKeyHashtable:CompareValueToValue(Internal.TypeSystem.InstantiatedType,Internal.TypeSystem.InstantiatedType):bool:this
          24 ( 8.33% of base) : 195639.dasm - Microsoft.Internal.Collections.CollectionServices:IsArrayEqual(System.__Canon[],System.__Canon[]):bool
          24 ( 8.33% of base) : 209137.dasm - System.Reflection.Context.CollectionServices:CompareArrays(System.__Canon[],System.__Canon[]):bool
           4 ( 8.33% of base) : 117820.dasm - System.Xml.Xsl.XmlQueryType:get_MaybeEmpty():bool:this

Top method improvements (percentages):
         -44 (-23.40% of base) : 35963.dasm - WithThreeChildren:CopyTo(Microsoft.CodeAnalysis.ArrayElement`1[Microsoft.CodeAnalysis.CSharp.Syntax.InternalSyntax.CSharpSyntaxNode][],int):this
         -44 (-23.40% of base) : 138504.dasm - WithThreeChildren:CopyTo(Microsoft.CodeAnalysis.ArrayElement`1[Microsoft.CodeAnalysis.VisualBasic.Syntax.InternalSyntax.VisualBasicSyntaxNode][],int):this
         -28 (-20.00% of base) : 35956.dasm - WithTwoChildren:CopyTo(Microsoft.CodeAnalysis.ArrayElement`1[Microsoft.CodeAnalysis.CSharp.Syntax.InternalSyntax.CSharpSyntaxNode][],int):this
         -28 (-20.00% of base) : 138514.dasm - WithTwoChildren:CopyTo(Microsoft.CodeAnalysis.ArrayElement`1[Microsoft.CodeAnalysis.VisualBasic.Syntax.InternalSyntax.VisualBasicSyntaxNode][],int):this
         -20 (-18.52% of base) : 91807.dasm - System.Data.Common.SqlBinaryStorage:Copy(int,int):this
         -20 (-18.52% of base) : 91907.dasm - System.Data.Common.SqlGuidStorage:Copy(int,int):this
         -56 (-17.50% of base) : 120873.dasm - System.Xml.XmlNodeReaderNavigator:InitDocTypeAttr():this
         -84 (-16.94% of base) : 120877.dasm - System.Xml.XmlNodeReaderNavigator:InitDecAttr():this
         -28 (-16.28% of base) : 63330.dasm - Microsoft.CodeAnalysis.CachingIdentityFactory`2:Add(System.__Canon,System.__Canon):this
         -16 (-15.38% of base) : 58579.dasm - Roslyn.Utilities.ObjectPool`1:FreeSlow(System.__Canon):this
         -16 (-15.38% of base) : 180582.dasm - System.Linq.Parallel.FixedMaxHeap`1:Swap(int,int):this
         -16 (-15.38% of base) : 128575.dasm - System.Reflection.Internal.ObjectPool`1:Free(System.__Canon):this
         -32 (-14.55% of base) : 91664.dasm - FixedExistanceList:MoveToFront(int):this
          -4 (-14.29% of base) : 2340.dasm - Microsoft.Diagnostics.Tracing.Ctf.IntHelpers:AlignDown(int,int):int
          -4 (-14.29% of base) : 64851.dasm - System.Text.RegularExpressions.Symbolic.BV64Algebra:Not(long):long:this
         -24 (-13.64% of base) : 64083.dasm - Microsoft.Cci.MetadataWriter:ReadInt32(System.Collections.Immutable.ImmutableArray`1[System.Byte],int):int
         -24 (-13.64% of base) : 58075.dasm - PublicKeyDecoder:ToUInt32(System.Collections.Immutable.ImmutableArray`1[System.Byte],int):int
         -80 (-13.16% of base) : 124612.dasm - System.Xml.XmlUtf8RawTextWriter:WriteCData(System.String):this
         -20 (-12.82% of base) : 19324.dasm - Microsoft.Diagnostics.Tracing.StackSources.CustomExtensions:ConcatListsOfLists(System.Collections.Generic.IEnumerable`1[System.__Canon][]):System.Collections.Generic.IEnumerable`1[System.__Canon]
         -32 (-12.70% of base) : 91669.dasm - FixedList:MoveToFront(int):this

3433 total methods with Code Size differences (1878 improved, 1555 regressed), 6389 unchanged.


libraries.pmi.Linux.arm64.checked.mch:


Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 47153752 (overridden on cmd)
Total bytes of diff: 47155648 (overridden on cmd)
Total bytes of delta: 1896 (0.00 % of base)
    diff is a regression.
    relative diff is an improvement.
Detail diffs


Top file regressions (bytes):
         392 : 73915.dasm (4.87% of base)
         264 : 73980.dasm (5.32% of base)
         256 : 73919.dasm (4.87% of base)
         200 : 222262.dasm (7.47% of base)
         128 : 73976.dasm (1.75% of base)
         120 : 71870.dasm (5.40% of base)
         108 : 104310.dasm (0.46% of base)
         108 : 184978.dasm (4.15% of base)
         104 : 50309.dasm (4.33% of base)
         100 : 118584.dasm (3.75% of base)
          88 : 156371.dasm (2.70% of base)
          84 : 169998.dasm (1.68% of base)
          76 : 107959.dasm (4.62% of base)
          76 : 50432.dasm (9.22% of base)
          76 : 184979.dasm (3.02% of base)
          72 : 45472.dasm (0.48% of base)
          68 : 220827.dasm (2.31% of base)
          64 : 116759.dasm (4.16% of base)
          64 : 113623.dasm (1.87% of base)
          64 : 175705.dasm (7.17% of base)

Top file improvements (bytes):
        -360 : 114215.dasm (-6.92% of base)
        -228 : 111599.dasm (-9.18% of base)
        -216 : 111704.dasm (-7.91% of base)
        -184 : 111614.dasm (-7.71% of base)
        -180 : 111722.dasm (-6.81% of base)
        -172 : 175776.dasm (-9.45% of base)
        -152 : 111618.dasm (-10.50% of base)
        -144 : 111724.dasm (-7.17% of base)
        -132 : 12863.dasm (-7.88% of base)
        -132 : 12864.dasm (-7.88% of base)
        -116 : 140.dasm (-1.14% of base)
         -92 : 51704.dasm (-3.41% of base)
         -88 : 111565.dasm (-8.59% of base)
         -88 : 111742.dasm (-6.88% of base)
         -80 : 107621.dasm (-13.70% of base)
         -80 : 107652.dasm (-8.30% of base)
         -80 : 107431.dasm (-7.55% of base)
         -80 : 107398.dasm (-11.49% of base)
         -80 : 73974.dasm (-7.19% of base)
         -80 : 73975.dasm (-7.19% of base)

4086 total files with Code Size differences (2275 improved, 1811 regressed), 11827 unchanged.

Top method regressions (bytes):
         392 ( 4.87% of base) : 73915.dasm - System.Data.RBTree`1[__Canon][System.__Canon]:RBInsert(int,int,int,int,bool):int:this
         264 ( 5.32% of base) : 73980.dasm - System.Data.RBTree`1[Byte][System.Byte]:RBDeleteX(int,int,int):int:this
         256 ( 4.87% of base) : 73919.dasm - System.Data.RBTree`1[__Canon][System.__Canon]:RBDeleteX(int,int,int):int:this
         200 ( 7.47% of base) : 222262.dasm - Microsoft.CSharp.RuntimeBinder.Errors.ErrorHandling:Error(int,Microsoft.CSharp.RuntimeBinder.Errors.ErrArg[]):Microsoft.CSharp.RuntimeBinder.RuntimeBinderException
         128 ( 1.75% of base) : 73976.dasm - System.Data.RBTree`1[Byte][System.Byte]:RBInsert(int,int,int,int,bool):int:this
         120 ( 5.40% of base) : 71870.dasm - System.Data.XSDSchema:HandleSimpleContentColumn(System.String,System.Data.DataTable,bool,System.Xml.XmlAttribute[],bool):this
         108 ( 0.46% of base) : 104310.dasm - Microsoft.VisualBasic.CompilerServices.VBBinder:BindToMethod(int,System.Reflection.MethodBase[],byref,System.Reflection.ParameterModifier[],System.Globalization.CultureInfo,System.String[],byref):System.Reflection.MethodBase:this
         108 ( 4.15% of base) : 184978.dasm - System.DefaultBinder:SelectMethod(int,System.Reflection.MethodBase[],System.Type[],System.Reflection.ParameterModifier[]):System.Reflection.MethodBase:this
         104 ( 4.33% of base) : 50309.dasm - Microsoft.CodeAnalysis.VisualBasic.Symbols.TypeSubstitution:PrivateAdjustForConstruct(Microsoft.CodeAnalysis.ArrayBuilder`1[[System.Collections.Generic.KeyValuePair`2[[Microsoft.CodeAnalysis.VisualBasic.Symbols.TypeParameterSymbol, Microsoft.CodeAnalysis.VisualBasic, Version=1.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35],[Microsoft.CodeAnalysis.VisualBasic.Symbols.TypeWithModifiers, Microsoft.CodeAnalysis.VisualBasic, Version=1.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]], System.Private.CoreLib, Version=7.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]],Microsoft.CodeAnalysis.VisualBasic.Symbols.TypeSubstitution,Microsoft.CodeAnalysis.VisualBasic.Symbols.TypeSubstitution):bool
         100 ( 3.75% of base) : 118584.dasm - System.Xml.Serialization.TempAssembly:GenerateRefEmitAssembly(System.Xml.Serialization.XmlMapping[],System.Type[],System.String):System.Reflection.Assembly
          88 ( 2.70% of base) : 156371.dasm - System.DirectoryServices.Protocols.BerConverter:Encode(System.String,System.Object[]):System.Byte[]
          84 ( 1.68% of base) : 169998.dasm - Internal.TypeSystem.MetadataFieldLayoutAlgorithm:ComputeAutoFieldLayout(Internal.TypeSystem.MetadataType,int):Internal.TypeSystem.ComputedInstanceFieldLayout:this
          76 ( 9.22% of base) : 50432.dasm - Microsoft.CodeAnalysis.VisualBasic.Symbols.TypeSymbolExtensions:IsSameTypeIgnoringCustomModifiers(Microsoft.CodeAnalysis.VisualBasic.Symbols.TypeSymbol,Microsoft.CodeAnalysis.VisualBasic.Symbols.TypeSymbol):bool
          76 ( 3.02% of base) : 184979.dasm - System.DefaultBinder:SelectProperty(int,System.Reflection.PropertyInfo[],System.Type,System.Type[],System.Reflection.ParameterModifier[]):System.Reflection.PropertyInfo:this
          76 ( 4.62% of base) : 107959.dasm - System.Xml.XmlConvert:EncodeName(System.String,bool,bool):System.String
          72 ( 0.48% of base) : 45472.dasm - Microsoft.CodeAnalysis.VisualBasic.Binder:ReportOverloadResolutionFailureForASingleCandidate(Microsoft.CodeAnalysis.VisualBasic.VisualBasicSyntaxNode,Microsoft.CodeAnalysis.Location,int,byref,System.Collections.Immutable.ImmutableArray`1[[Microsoft.CodeAnalysis.VisualBasic.BoundExpression, Microsoft.CodeAnalysis.VisualBasic, Version=1.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]],System.Collections.Immutable.ImmutableArray`1[[System.String, System.Private.CoreLib, Version=7.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]],bool,bool,bool,bool,Microsoft.CodeAnalysis.DiagnosticBag,Microsoft.CodeAnalysis.VisualBasic.Symbol,bool,Microsoft.CodeAnalysis.VisualBasic.VisualBasicSyntaxNode,Microsoft.CodeAnalysis.VisualBasic.Symbol):this
          68 ( 2.31% of base) : 220827.dasm - ProxyBuilder:AddMethodImpl(System.Reflection.MethodInfo,int):System.Reflection.Emit.MethodBuilder:this
          64 ( 5.05% of base) : 70422.dasm - InferenceGraph:InferTypeArgumentsFromArgument(Microsoft.CodeAnalysis.VisualBasic.VisualBasicSyntaxNode,Microsoft.CodeAnalysis.VisualBasic.Symbols.TypeSymbol,bool,Microsoft.CodeAnalysis.VisualBasic.Symbols.TypeSymbol,Microsoft.CodeAnalysis.VisualBasic.Symbols.ParameterSymbol,int,int):bool:this
          64 ( 1.62% of base) : 25154.dasm - Microsoft.CodeAnalysis.CSharp.TypeUnification:CanUnifyHelper(Microsoft.CodeAnalysis.CSharp.Symbols.TypeWithModifiers,Microsoft.CodeAnalysis.CSharp.Symbols.TypeWithModifiers,byref):bool
          64 ( 1.87% of base) : 113623.dasm - System.Xml.Schema.XmlSchemaValidator:EndElementIdentityConstraints(System.Object,System.String,System.Xml.Schema.XmlSchemaDatatype):this

Top method improvements (bytes):
        -360 (-6.92% of base) : 114215.dasm - System.Xml.Schema.XmlSchemaInference:InferSimpleType(System.String,byref):int
        -228 (-9.18% of base) : 111599.dasm - System.Xml.DtdParser:ScanSubsetContent():int:this
        -216 (-7.91% of base) : 111704.dasm - <ScanSubsetContentAsync>d__174:MoveNext():this
        -184 (-7.71% of base) : 111614.dasm - System.Xml.DtdParser:ScanAttlist2():int:this
        -180 (-6.81% of base) : 111722.dasm - <ScanAttlist2Async>d__183:MoveNext():this
        -172 (-9.45% of base) : 175776.dasm - Xunit.Sdk.Sha1Digest:ProcessBlock():this
        -152 (-10.50% of base) : 111618.dasm - System.Xml.DtdParser:ScanAttlist6():int:this
        -144 (-7.17% of base) : 111724.dasm - <ScanAttlist6Async>d__184:MoveNext():this
        -132 (-7.88% of base) : 12863.dasm - Filter:populateMask(Microsoft.FSharp.Core.FSharpFunc`2[__Canon,Boolean],System.__Canon[],System.UInt32[]):int
        -132 (-7.88% of base) : 12864.dasm - Filter:populateMask(Microsoft.FSharp.Core.FSharpFunc`2[Byte,Boolean],System.Byte[],System.UInt32[]):int
        -116 (-1.14% of base) : 140.dasm - System.Text.RegularExpressions.RegexInterpreter:Go():this
         -92 (-3.41% of base) : 51704.dasm - Microsoft.CodeAnalysis.VisualBasic.Emit.PEModuleBuilder:GetExportedTypes(Microsoft.CodeAnalysis.Emit.EmitContext):System.Collections.Generic.IEnumerable`1[[Microsoft.Cci.ITypeReference, Microsoft.CodeAnalysis, Version=1.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]:this
         -88 (-6.88% of base) : 111742.dasm - <ScanCondSection1Async>d__193:MoveNext():this
         -88 (-8.59% of base) : 111565.dasm - System.Xml.DtdParser:ScanCondSection1():int:this
         -80 (-7.55% of base) : 107431.dasm - <WriteCDataAsync>d__109:MoveNext():this
         -80 (-8.30% of base) : 107652.dasm - <WriteCDataAsync>d__98:MoveNext():this
         -80 (-7.19% of base) : 73974.dasm - System.Data.RBTree`1[Byte][System.Byte]:LeftRotate(int,int,int):int:this
         -80 (-7.19% of base) : 73975.dasm - System.Data.RBTree`1[Byte][System.Byte]:RightRotate(int,int,int):int:this
         -80 (-11.49% of base) : 107398.dasm - System.Xml.XmlEncodedRawTextWriter:WriteCData(System.String):this
         -80 (-13.70% of base) : 107621.dasm - System.Xml.XmlUtf8RawTextWriter:WriteCData(System.String):this

Top method regressions (percentages):
          40 (34.48% of base) : 215127.dasm - System.Net.WebClient:ByteArrayHasPrefix(System.Byte[],System.Byte[]):bool
          32 (30.77% of base) : 1214.dasm - System.Text.RegularExpressions.Symbolic.SymbolicRegexInfo:And(System.Text.RegularExpressions.Symbolic.SymbolicRegexInfo[]):System.Text.RegularExpressions.Symbolic.SymbolicRegexInfo
          16 (19.05% of base) : 1213.dasm - System.Text.RegularExpressions.Symbolic.SymbolicRegexInfo:Or(System.Text.RegularExpressions.Symbolic.SymbolicRegexInfo[]):System.Text.RegularExpressions.Symbolic.SymbolicRegexInfo
          16 (18.18% of base) : 105066.dasm - <PrivateImplementationDetails>:ComputeStringHash(System.String):int
          16 (18.18% of base) : 67789.dasm - <PrivateImplementationDetails>:ComputeStringHash(System.String):int
          40 (17.54% of base) : 44859.dasm - Microsoft.CodeAnalysis.VisualBasic.AbstractRegionDataFlowPass:CreateLocalSymbolForVariables(System.Collections.Immutable.ImmutableArray`1[[Microsoft.CodeAnalysis.VisualBasic.BoundLocalDeclaration, Microsoft.CodeAnalysis.VisualBasic, Version=1.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]):Microsoft.CodeAnalysis.VisualBasic.Symbols.LocalSymbol:this
          16 (16.67% of base) : 221742.dasm - Microsoft.CSharp.RuntimeBinder.Semantics.MethodOrPropertySymbol:HasOptionalParameters():bool:this
          24 (16.22% of base) : 221165.dasm - Microsoft.CSharp.RuntimeBinder.RuntimeBinderExtensions:GetIndexerName(System.Type):System.String
          48 (16.22% of base) : 175701.dasm - Xunit.Sdk.TypeUtility:ResolveGenericDisplay(Xunit.Abstractions.ITypeInfo[]):System.String
          40 (13.89% of base) : 135210.dasm - Microsoft.Cci.ContentId:FromHash(System.Collections.Immutable.ImmutableArray`1[Byte]):Microsoft.Cci.ContentId
          12 (13.04% of base) : 165864.dasm - System.Net.Security.SslApplicationProtocol:GetHashCode():int:this
          32 (12.70% of base) : 151172.dasm - System.Xml.XmlConverter:StripWhitespace(System.String):System.String
          44 (12.64% of base) : 12523.dasm - Microsoft.FSharp.Collections.ArrayModule:Truncate(int,System.Byte[]):System.Byte[]
          24 (12.50% of base) : 12747.dasm - Microsoft.FSharp.Collections.ArrayModule:concatArrays(System.Byte[][]):System.Byte[]
          16 (12.12% of base) : 103641.dasm - Microsoft.VisualBasic.CompilerServices.NewLateBinding:ResetCopyback(System.Boolean[])
          20 (11.90% of base) : 74308.dasm - System.Data.UniqueConstraint:Create(System.String,System.Data.DataColumn[]):this
          44 (11.70% of base) : 12759.dasm - Microsoft.FSharp.Collections.ArrayModule:TakeWhile(Microsoft.FSharp.Core.FSharpFunc`2[Byte,Boolean],System.Byte[]):System.Byte[]
          40 (11.36% of base) : 217612.dasm - ConstructorMatcher:Match(System.Object[]):int:this
          16 (11.11% of base) : 104032.dasm - Microsoft.VisualBasic.CompilerServices.Symbols:Implements(System.Type,System.Type):bool
          40 (10.87% of base) : 198072.dasm - System.Linq.ImmutableArrayExtensions:SequenceEqual(System.Collections.Immutable.ImmutableArray`1[__Canon],System.Collections.Immutable.ImmutableArray`1[__Canon],System.Collections.Generic.IEqualityComparer`1[__Canon]):bool

Top method improvements (percentages):
         -16 (-17.39% of base) : 181300.dasm - System.Linq.Parallel.FixedMaxHeap`1[Byte][System.Byte]:Swap(int,int):this
         -32 (-15.38% of base) : 103344.dasm - FixedExistanceList:MoveToFront(int):this
          -4 (-14.29% of base) : 138032.dasm - Microsoft.CodeAnalysis.SymbolDisplayFormat:RemoveKindOptions(int):Microsoft.CodeAnalysis.SymbolDisplayFormat:this
          -4 (-14.29% of base) : 138029.dasm - Microsoft.CodeAnalysis.SymbolDisplayFormat:RemoveMemberOptions(int):Microsoft.CodeAnalysis.SymbolDisplayFormat:this
          -4 (-14.29% of base) : 138001.dasm - Microsoft.CodeAnalysis.SymbolDisplayFormat:RemoveParameterOptions(int):Microsoft.CodeAnalysis.SymbolDisplayFormat:this
          -4 (-14.29% of base) : 95531.dasm - Microsoft.Diagnostics.Tracing.Ctf.IntHelpers:AlignDown(int,int):int
         -20 (-14.29% of base) : 78882.dasm - Microsoft.Diagnostics.Tracing.StackSources.CustomExtensions:ConcatListsOfLists(System.__Canon[]):System.Collections.Generic.IEnumerable`1[__Canon]
          -4 (-14.29% of base) : 1485.dasm - System.Text.RegularExpressions.Symbolic.BV64Algebra:Not(long):long:this
         -80 (-13.70% of base) : 107621.dasm - System.Xml.XmlUtf8RawTextWriter:WriteCData(System.String):this
         -32 (-13.33% of base) : 103339.dasm - FixedList:MoveToFront(int):this
         -24 (-13.33% of base) : 169245.dasm - Internal.IL.ILDisassembler:ReadILUInt32():int:this
         -24 (-12.77% of base) : 107252.dasm - System.Xml.HtmlEncodedRawTextWriter:OutputRestAmps():this
         -24 (-12.77% of base) : 107281.dasm - System.Xml.HtmlUtf8RawTextWriter:OutputRestAmps():this
          -4 (-12.50% of base) : 175773.dasm - Xunit.Sdk.Sha1Digest:F(int,int,int):int
         -40 (-12.20% of base) : 107622.dasm - System.Xml.XmlUtf8RawTextWriter:WriteComment(System.String):this
         -16 (-12.12% of base) : 181289.dasm - System.Linq.Parallel.FixedMaxHeap`1[__Canon][System.__Canon]:Swap(int,int):this
         -76 (-11.80% of base) : 175771.dasm - Xunit.Sdk.Sha1Digest:DoFinal(System.Byte[],int):int:this
         -32 (-11.76% of base) : 192650.dasm - R2RDump.Disassembler:IsIntel2ByteIndirectJumpPCRelativeInstruction(int,byref):bool:this
         -80 (-11.49% of base) : 107398.dasm - System.Xml.XmlEncodedRawTextWriter:WriteCData(System.String):this
         -28 (-11.48% of base) : 175743.dasm - Xunit.Sdk.Pack:UInt64_To_BE(long,System.Byte[],int)

4086 total methods with Code Size differences (2275 improved, 1811 regressed), 11827 unchanged.


libraries_tests.pmi.Linux.arm64.checked.mch:


Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 112325332 (overridden on cmd)
Total bytes of diff: 112335540 (overridden on cmd)
Total bytes of delta: 10208 (0.01 % of base)
    diff is a regression.
    relative diff is an improvement.
Detail diffs


Top file regressions (bytes):
         336 : 325837.dasm (3.85% of base)
         308 : 212790.dasm (3.22% of base)
         136 : 289626.dasm (4.56% of base)
         120 : 221878.dasm (4.81% of base)
         120 : 5859.dasm (2.36% of base)
         120 : 5865.dasm (2.36% of base)
         120 : 5871.dasm (2.36% of base)
         120 : 5883.dasm (2.36% of base)
         120 : 5889.dasm (2.36% of base)
         120 : 5895.dasm (2.36% of base)
         120 : 5901.dasm (2.36% of base)
         120 : 5907.dasm (2.37% of base)
         120 : 5913.dasm (2.36% of base)
         120 : 5919.dasm (2.37% of base)
         120 : 5925.dasm (2.36% of base)
         120 : 5934.dasm (2.36% of base)
         120 : 5940.dasm (2.37% of base)
         120 : 5946.dasm (2.37% of base)
         120 : 5952.dasm (2.36% of base)
         120 : 6024.dasm (2.36% of base)

Top file improvements (bytes):
        -116 : 140.dasm (-1.14% of base)
         -92 : 115276.dasm (-2.34% of base)
         -92 : 213671.dasm (-2.36% of base)
         -56 : 211858.dasm (-11.48% of base)
         -56 : 181472.dasm (-11.48% of base)
         -48 : 211902.dasm (-2.65% of base)
         -48 : 181513.dasm (-2.65% of base)
         -44 : 115279.dasm (-1.56% of base)
         -44 : 48078.dasm (-5.98% of base)
         -44 : 48079.dasm (-5.61% of base)
         -44 : 299024.dasm (-3.03% of base)
         -44 : 140730.dasm (-4.95% of base)
         -44 : 125264.dasm (-3.25% of base)
         -40 : 187785.dasm (-5.38% of base)
         -40 : 187795.dasm (-5.38% of base)
         -40 : 187829.dasm (-5.38% of base)
         -40 : 187872.dasm (-5.38% of base)
         -40 : 211769.dasm (-0.64% of base)
         -40 : 187759.dasm (-5.38% of base)
         -40 : 181381.dasm (-0.64% of base)

6080 total files with Code Size differences (3459 improved, 2621 regressed), 10939 unchanged.

Top method regressions (bytes):
         336 ( 3.85% of base) : 325837.dasm - System.Xml.Tests.ToTypeTests:TestValid(System.Object[],System.Object[],System.String,System.String[]):int:this
         308 ( 3.22% of base) : 212790.dasm - System.Numerics.Tests.ToStringTest:RunRegionSpecificStandardFormatToStringTests()
         136 ( 4.56% of base) : 289626.dasm - System.Reflection.Emit.Tests.DynamicILInfoTests:Test_GenericMethod():this
         120 ( 2.36% of base) : 6024.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.add001.add001.Test:MainMethod():int
         120 ( 2.36% of base) : 5952.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.devide001.devide001.Test:MainMethod():int
         120 ( 2.37% of base) : 5946.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.equal001.equal001.Test:MainMethod():int
         120 ( 2.37% of base) : 5940.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.greater001.greater001.Test:MainMethod():int
         120 ( 2.36% of base) : 5934.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.greaterequal001.greaterequal001.Test:MainMethod():int
         120 ( 2.36% of base) : 5925.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.leftshift001.leftshift001.Test:MainMethod():int
         120 ( 2.37% of base) : 5919.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.less001.less001.Test:MainMethod():int
         120 ( 2.36% of base) : 5913.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.lessequal001.lessequal001.Test:MainMethod():int
         120 ( 2.37% of base) : 5907.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.logicaland001.logicaland001.Test:MainMethod():int
         120 ( 2.36% of base) : 5901.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.logicalor001.logicalor001.Test:MainMethod():int
         120 ( 2.36% of base) : 5895.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.logicalxor001.logicalxor001.Test:MainMethod():int
         120 ( 2.36% of base) : 5889.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.multi001.multi001.Test:MainMethod():int
         120 ( 2.36% of base) : 5883.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.notequal001.notequal001.Test:MainMethod():int
         120 ( 2.36% of base) : 5871.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.remainder001.remainder001.Test:MainMethod():int
         120 ( 2.36% of base) : 5865.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.rightshift001.rightshift001.Test:MainMethod():int
         120 ( 2.36% of base) : 5859.dasm - ManagedTests.DynamicCSharp.Conformance.dynamic.statements.IndexerOperator.Binary.sub001.sub001.Test:MainMethod():int
         120 ( 4.81% of base) : 221878.dasm - Microsoft.Build.Tasks.AssemblyResolution:CompileSearchPaths(Microsoft.Build.Framework.IBuildEngine,System.String[],System.String[],int,System.String[],Microsoft.Build.Shared.FileExists,Microsoft.Build.Tasks.GetAssemblyName,Microsoft.Build.Tasks.InstalledAssemblies,Microsoft.Build.Tasks.GetAssemblyRuntimeVersion,System.Version,Microsoft.Build.Tasks.GetAssemblyPathInGac,Microsoft.Build.Utilities.TaskLoggingHelper):Microsoft.Build.Tasks.Resolver[]

Top method improvements (bytes):
        -116 (-1.14% of base) : 140.dasm - System.Text.RegularExpressions.RegexInterpreter:Go():this
         -92 (-2.36% of base) : 213671.dasm - RegexTestNamespace.RegexRunnerTestClass:Go():this
         -92 (-2.34% of base) : 115276.dasm - System.Reflection.Metadata.Tests.MetadataReaderTests:ValidateAssemblyRefTable():this
         -56 (-11.48% of base) : 211858.dasm - System.Data.SqlClient.TdsParser:WriteLong(long,System.Data.SqlClient.TdsParserStateObject):this
         -56 (-11.48% of base) : 181472.dasm - System.Data.SqlClient.TdsParser:WriteLong(long,System.Data.SqlClient.TdsParserStateObject):this
         -48 (-2.65% of base) : 211902.dasm - System.Data.SqlClient.TdsParser:SendPreLoginHandshake(System.Byte[],bool):this
         -48 (-2.65% of base) : 181513.dasm - System.Data.SqlClient.TdsParser:SendPreLoginHandshake(System.Byte[],bool):this
         -44 (-3.03% of base) : 299024.dasm - DiffPlex.Differ:CalculateEditLength(System.Int32[],int,int,System.Int32[],int,int,System.Int32[],System.Int32[]):DiffPlex.Model.EditLengthResult
         -44 (-4.95% of base) : 140730.dasm - DigestResponse:GetNextValue(System.String,int,bool,byref):System.String:this
         -44 (-3.25% of base) : 125264.dasm - Microsoft.Build.Evaluation.Scanner:Advance():bool:this
         -44 (-5.61% of base) : 48079.dasm - System.Linq.Expressions.Tests.BinaryCoalesceTests:CheckGenericWithClassAndNewRestrictionCoalesceHelper(bool)
         -44 (-5.98% of base) : 48078.dasm - System.Linq.Expressions.Tests.BinaryCoalesceTests:CheckGenericWithClassRestrictionCoalesceHelper(bool)
         -44 (-1.56% of base) : 115279.dasm - System.Reflection.Metadata.Tests.MetadataReaderTests:ValidateModuleRefTableAndFileTableManaged():this
         -40 (-1.62% of base) : 125405.dasm - Microsoft.Build.Evaluation.ExpressionShredder:GetReferencedItemExpressions(System.String,int,int):System.Collections.Generic.List`1[[Microsoft.Build.Evaluation.ExpressionShredder+ItemExpressionCapture, Microsoft.Build, Version=15.1.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a]]
         -40 (-0.64% of base) : 211769.dasm - System.Data.SqlClient.TdsParser:WriteSmiTypeInfo(Microsoft.SqlServer.Server.SmiExtendedMetaData,System.Data.SqlClient.TdsParserStateObject):this
         -40 (-0.64% of base) : 181381.dasm - System.Data.SqlClient.TdsParser:WriteSmiTypeInfo(Microsoft.SqlServer.Server.SmiExtendedMetaData,System.Data.SqlClient.TdsParserStateObject):this
         -40 (-5.38% of base) : 187872.dasm - System.Drawing.Tests.RegionTests:Complement_Region_Success(System.Drawing.Region,System.Drawing.RectangleF[],System.Drawing.RectangleF[]):this
         -40 (-5.38% of base) : 187829.dasm - System.Drawing.Tests.RegionTests:Exclude_Region_Success(System.Drawing.Region,System.Drawing.RectangleF[],System.Drawing.RectangleF[]):this
         -40 (-5.38% of base) : 187795.dasm - System.Drawing.Tests.RegionTests:Intersect_Region_Success(System.Drawing.Region,System.Drawing.RectangleF[],System.Drawing.RectangleF[]):this
         -40 (-5.38% of base) : 187759.dasm - System.Drawing.Tests.RegionTests:Union_Region_Success(System.Drawing.Region,System.Drawing.RectangleF[],System.Drawing.RectangleF[]):this

Top method regressions (percentages):
          16 (19.05% of base) : 268834.dasm - Castle.DynamicProxy.Generators.Emitters.ArgumentsUtil:InitializeArgumentsByPosition(Castle.DynamicProxy.Generators.Emitters.SimpleAST.ArgumentReference[],bool)
          16 (18.18% of base) : 230798.dasm - <PrivateImplementationDetails>:ComputeStringHash(System.String):int
          28 (17.50% of base) : 273838.dasm - System.Numerics.Tests.Util:AllEqual(System.Byte[],System.Byte[]):bool
          28 (17.50% of base) : 273837.dasm - System.Numerics.Tests.Util:AnyEqual(System.Byte[],System.Byte[]):bool
          12 (14.29% of base) : 205326.dasm - AnagramEqualityComparer:GetHashCode(System.String):int:this
          12 (14.29% of base) : 266770.dasm - AnagramEqualityComparer:GetHashCode(System.String):int:this
          12 (13.04% of base) : 328862.dasm - System.Net.Security.SslApplicationProtocol:GetHashCode():int:this
          24 (12.77% of base) : 332855.dasm - <>c__DisplayClass2_0:<RunSimpleParallelDoTest>b__0():this
          24 (12.50% of base) : 301211.dasm - BufferComparer:Equals(System.Byte[],System.Byte[]):bool:this
          12 (12.50% of base) : 129317.dasm - FnvHash64:GetHashCode(System.String):long
          48 (12.00% of base) : 258192.dasm - ConstructorMatcher:Match(System.Object[]):int:this
          36 (11.25% of base) : 265085.dasm - Grace.Data.Immutable.ImmutableArray`1[__Canon][System.__Canon]:Equals(Grace.Data.Immutable.ImmutableArray`1[__Canon],Grace.Data.Immutable.ImmutableArray`1[__Canon]):bool:this
          24 (10.71% of base) : 77615.dasm - Microsoft.CodeAnalysis.SyntaxTreeExtensions:FindFirstDifference(System.String,System.String):int
          48 (10.53% of base) : 282909.dasm - <>c__DisplayClass289_0:<sqlite3_exec>b__0(System.Object,System.IntPtr[],System.IntPtr[]):int:this
          16 (10.53% of base) : 180204.dasm - System.Data.SqlClient.SqlCommandSet:BuildStoredProcedureName(System.Text.StringBuilder,System.String)
          16 (10.53% of base) : 210624.dasm - System.Data.SqlClient.SqlCommandSet:BuildStoredProcedureName(System.Text.StringBuilder,System.String)
          20 (10.20% of base) : 45512.dasm - System.Runtime.Serialization.Formatters.Tests.EqualityHelpers:ArraysAreEqual(System.Byte[],System.Byte[]):bool
          32 (10.13% of base) : 337023.dasm - Unity.Utility.Prime:GetPrime(int):int
          20 (10.00% of base) : 160286.dasm - FastExpressionCompiler.LightExpression.TypeTools:AreTypesTheSame(System.Type[],System.Type[]):bool
          24 (10.00% of base) : 75707.dasm - Roslyn.Utilities.PathUtilities:PathsEqual(System.String,System.String,int):bool

Top method improvements (percentages):
          -4 (-16.67% of base) : 83947.dasm - Microsoft.CodeAnalysis.Editing.DeclarationModifiers:op_Subtraction(Microsoft.CodeAnalysis.Editing.DeclarationModifiers,Microsoft.CodeAnalysis.Editing.DeclarationModifiers):Microsoft.CodeAnalysis.Editing.DeclarationModifiers
          -4 (-16.67% of base) : 82994.dasm - Microsoft.CodeAnalysis.Formatting.FormattingExtensions:RemoveFlag(int,int):int
         -16 (-16.67% of base) : 147699.dasm - Piles@527-4:Invoke(int,int):Microsoft.FSharp.Core.Unit:this
         -16 (-16.67% of base) : 147635.dasm - Shuffle@437-5[Byte][System.Byte]:Invoke(int,int):Microsoft.FSharp.Core.Unit:this
         -16 (-16.67% of base) : 147617.dasm - shuffleInPlace@426-3[Byte][System.Byte]:Invoke(int,int):Microsoft.FSharp.Core.Unit:this
          -4 (-16.67% of base) : 273790.dasm - System.Numerics.Tests.Util:AndNot(int,int):int
          -4 (-16.67% of base) : 273793.dasm - System.Numerics.Tests.Util:AndNot(long,long):long
         -24 (-13.95% of base) : 115536.dasm - BR:ReadInt32():int:this
          -4 (-12.50% of base) : 86123.dasm - HashBucket[__Canon,Nullable`1][System.__Canon,System.Nullable`1[System.Int32]]:RemoveBit(int,int):int
          -4 (-12.50% of base) : 86136.dasm - HashBucket[Byte,Nullable`1][System.Byte,System.Nullable`1[System.Int32]]:RemoveBit(int,int):int
         -24 (-12.50% of base) : 268045.dasm - System.Net.SocketAddress:CopyAddressSizeIntoBuffer():this
         -24 (-12.50% of base) : 249595.dasm - System.Net.SocketAddress:CopyAddressSizeIntoBuffer():this
         -56 (-11.48% of base) : 211858.dasm - System.Data.SqlClient.TdsParser:WriteLong(long,System.Data.SqlClient.TdsParserStateObject):this
         -56 (-11.48% of base) : 181472.dasm - System.Data.SqlClient.TdsParser:WriteLong(long,System.Data.SqlClient.TdsParserStateObject):this
          -4 (-11.11% of base) : 273789.dasm - System.Numerics.Tests.Util:AndNot(short,short):short
          -4 (-11.11% of base) : 273788.dasm - System.Numerics.Tests.Util:AndNot(ubyte,ubyte):ubyte
          -4 (-9.09% of base) : 83927.dasm - Microsoft.CodeAnalysis.Editing.DeclarationModifiers:SetFlag(int,int,bool):int
         -12 (-8.57% of base) : 147633.dasm - Shuffle@437-5[__Canon][System.__Canon]:Invoke(int,int):Microsoft.FSharp.Core.Unit:this
         -12 (-8.57% of base) : 147615.dasm - shuffleInPlace@426-3[__Canon][System.__Canon]:Invoke(int,int):Microsoft.FSharp.Core.Unit:this
          -8 (-8.33% of base) : 80002.dasm - Microsoft.CodeAnalysis.PooledObjects.ObjectPool`1[__Canon][System.__Canon]:FreeSlow(System.__Canon):this

6080 total methods with Code Size differences (3459 improved, 2621 regressed), 10939 unchanged.



Overall it's a size regression due to additional CSEs, I noticed in some diffs we weren't even able to fold cloned loops because of it, e.g. for:
```csharp
private static bool Test(byte[] prefix, byte[] byteArray)
{
    if (prefix == null || byteArray == null || prefix.Length > byteArray.Length)
        return false;
    for (int i = 0; i < prefix.Length; i++)
    {
        if (prefix[i] != byteArray[i])
            return false;
    }
    return true;
}

^ diff: https://www.diffchecker.com/oUPb1br3
We clone the loop in both my PR and Main, but in Main we then are able to drop it, but not it "PR" due to that CSE of ADD. Both loops don't have bound checks. Btw, number of bl CORINFO_HELP_RNGCHKFAIL is the same in base and diff diffs so I assume this PR doesn't regress bound check elimination.

A couple of size-regression examples:
https://www.diffchecker.com/VkGHhEin
https://www.diffchecker.com/nOuaRBkO

improvements:
https://www.diffchecker.com/zxoJy9vQ

Author: EgorBo
Assignees: -
Labels:

area-CodeGen-coreclr

Milestone: -

@EgorBo
Copy link
Member Author

EgorBo commented Nov 7, 2021

CopyArray benchmark from here #61045 (comment) got additional improvements

Baseline:

Method src dst Mean
CopyArray Int32[100000] Int32[100000] 54,131.14 ns

#61045 + #61035:

Method src dst Mean
CopyArray Int32[100000] Int32[100000] 36,413.37 ns

This PR:

Method src dst Mean
CopyArray Int32[100000] Int32[100000] 31,712.23 ns

41.4% faster than the baseline

@EgorBo
Copy link
Member Author

EgorBo commented Nov 7, 2021

/azp run Fuzzlyn, runtime-coreclr outerloop, runtime-coreclr gcstress0x3-gcstress0xc

@dotnet dotnet deleted a comment from azure-pipelines bot Nov 8, 2021
@EgorBo
Copy link
Member Author

EgorBo commented Nov 8, 2021

/azp run Fuzzlyn, runtime-coreclr outerloop

@EgorBo
Copy link
Member Author

EgorBo commented Nov 8, 2021

@dotnet/jit-contrib PTAL

@azure-pipelines
Copy link

Azure Pipelines successfully started running 2 pipeline(s).

@kunalspathak
Copy link
Member

@EgorBo - It might be good to post PerfScore diff as well, will be good to understand if there is lot of regression in it. Also, do you mind posting the diffs for benchmark collection?

@kunalspathak
Copy link
Member

From the diffs, it looks like most of them are also coming from loop alignment. Might be worth turning loop alignment off for baseline/test to see the real code size impact.

@EgorBo
Copy link
Member Author

EgorBo commented Nov 8, 2021

@EgorBo - It might be good to post PerfScore diff as well, will be good to understand if there is lot of regression in it. Also, do you mind posting the diffs for benchmark collection?

How do I ask superpmi to generate perfscore btw?

diffs for benchmark collection

it looks like it's not available for altjit mode I am running spmi under (I wasn't able to run spmi on my apple-m1)

@SingleAccretion
Copy link
Contributor

How do I ask superpmi to generate perfscore btw?

FWIW, I usually just cd into the directory SPMI created for diffs and jit-analyze -b base -d diff -m PerfScore directly.

@kunalspathak
Copy link
Member

kunalspathak commented Nov 8, 2021

it looks like it's not available for altjit mode I am running spmi under (I wasn't able to run spmi on my apple-m1)

It is only available for windows arm64.

D:\git\runtime>python src\coreclr\scripts\superpmi.py list-collections -target_arch arm64
================ Logging to E:\spmi\superpmi.364.log
Using JIT/EE Version from jiteeversionguid.h: 3df3e3ec-b1f6-4e6d-8439-2e7f3f7fa2ac
SuperPMI list-collections

5 collections for 3df3e3ec-b1f6-4e6d-8439-2e7f3f7fa2ac/windows/arm64/

https://clrjit2.blob.core.windows.net/superpmi/collections/3df3e3ec-b1f6-4e6d-8439-2e7f3f7fa2ac/windows/arm64/benchmarks.run.windows.arm64.checked.mch.zip
https://clrjit2.blob.core.windows.net/superpmi/collections/3df3e3ec-b1f6-4e6d-8439-2e7f3f7fa2ac/windows/arm64/coreclr_tests.pmi.windows.arm64.checked.mch.zip
https://clrjit2.blob.core.windows.net/superpmi/collections/3df3e3ec-b1f6-4e6d-8439-2e7f3f7fa2ac/windows/arm64/libraries.crossgen2.windows.arm64.checked.mch.zip
https://clrjit2.blob.core.windows.net/superpmi/collections/3df3e3ec-b1f6-4e6d-8439-2e7f3f7fa2ac/windows/arm64/libraries.pmi.windows.arm64.checked.mch.zip
https://clrjit2.blob.core.windows.net/superpmi/collections/3df3e3ec-b1f6-4e6d-8439-2e7f3f7fa2ac/windows/arm64/libraries_tests.pmi.windows.arm64.checked.mch.zip

You can use windows collection by passing -target_os windows -target_arch arm64 to the superpmi.py.

Copy link
Member

@BruceForstall BruceForstall left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like very good results.

A few minor questions.

src/coreclr/jit/morph.cpp Outdated Show resolved Hide resolved
src/coreclr/jit/morph.cpp Outdated Show resolved Hide resolved
src/coreclr/jit/morph.cpp Outdated Show resolved Hide resolved
@BruceForstall
Copy link
Member

You should probably trigger jitstress, and also gcstress0xc to validate our assumption that GC will be happy with this new form of byref

@EgorBo
Copy link
Member Author

EgorBo commented Nov 9, 2021

Regression example:

private static int[] _goto;

private static int Test(int destpos)
{
    _goto[destpos] = AddBacktrackNote();
    return _goto[destpos];
}

Here index is invariant and _goto arrayref is not (it can be changed in AddBacktrackNote) so in this case the default "arrRef + (index + elemOffset)" shape works better as we will be able to do CSE for (index + elemOffset). Unfortunately, it's not possible to detect patterns like this early in morph. Naïve approaches like "if index is lvParam" don't really work well.
So I'm suggesting we merge it as is and look at regressions in dotnet/performance on perf triage meetings (if there will be a lot of them - address them or revert the commit completely).

E.g. we can pick the shape based on heuristics:

  1. Current block has BBF_BACKWARD_JUMP
  2. ArrayRef or Index are parameters
  3. Loop body has calls
    etc..

A possible solution is a sort of tree re-association phase during CSE/LoopHoisting/VN e.g.
(invarian1 + x) + invariant2 --reassoc--> (invariant1 + invariant2) + x

@EgorBo
Copy link
Member Author

EgorBo commented Nov 9, 2021

/azp list

@EgorBo
Copy link
Member Author

EgorBo commented Nov 9, 2021

/azp run runtime-coreclr jitstress, runtime-coreclr gcstress0x3-gcstress0xc

@azure-pipelines
Copy link

Azure Pipelines successfully started running 2 pipeline(s).

@EgorBo
Copy link
Member Author

EgorBo commented Nov 9, 2021

@BruceForstall does it look good now? gcstress test failures are timeouts in Vector64_ro/Vector128_ro/Vector256_ro tests which are huge, I guess we might want to disable them for gcstress.

@EgorBo - It might be good to post PerfScore diff as well, will be good to understand if there is lot of regression in it. Also, do you mind posting the diffs for benchmark collection?

I added the Benchmarks collection to the list (-20kb diff). PerfScore diffs can be found here https://gist.github.com/EgorBo/7ed76fb5bb5a38cc56bae20306b8e080

Thoughts on reducing regressions in follow up PRs are here: #61293 (comment)

@kunalspathak
Copy link
Member

PerfScore diffs can be found here https://gist.github.com/EgorBo/7ed76fb5bb5a38cc56bae20306b8e080

Thanks! There are quite some benchmarks that regressed. Do they fall under same category that you listed an example of?

Top method regressions (PerfScoreUnits):
     1750.98 ( 1.82% of base) : 3379.dasm - System.Reflection.Emit.CustomAttributeBuilder:.ctor(System.Reflection.ConstructorInfo,System.Object[],System.Reflection.PropertyInfo[],System.Object[],System.Reflection.FieldInfo[],System.Object[]):this
     1048.40 ( 3.10% of base) : 16191.dasm - Microsoft.CodeAnalysis.CommonReferenceManager`2[__Canon,__Canon][System.__Canon,System.__Canon]:ReuseAssemblySymbols(Microsoft.CodeAnalysis.CommonReferenceManager`2+BoundInputAssembly[System.__Canon,System.__Canon][],System.__Canon[],System.Collections.Immutable.ImmutableArray`1[__Canon],int):this
      415.12 (10.04% of base) : 1003.dasm - JetStream.Statistics:findOptimalSegmentationInternal(System.Single[][],System.Int32[][],System.Double[],JetStream.SampleVarianceUpperTriangularMatrix,int)
      364.16 ( 5.26% of base) : 20019.dasm - Benchstone.BenchI.Array2:Bench(int):bool
      337.20 ( 4.43% of base) : 23223.dasm - Benchstone.BenchF.LLoops:Init():this
      292.90 (14.08% of base) : 4690.dasm - System.Drawing.Imaging.ImageCodecInfo:ConvertFromMemory(long,int):System.Drawing.Imaging.ImageCodecInfo[]
      277.17 ( 2.97% of base) : 1915.dasm - System.DefaultBinder:BindToMethod(int,System.Reflection.MethodBase[],byref,System.Reflection.ParameterModifier[],System.Globalization.CultureInfo,System.String[],byref):System.Reflection.MethodBase:this
      223.74 (12.76% of base) : 1283.dasm - System.DefaultBinder:SelectMethod(int,System.Reflection.MethodBase[],System.Type[],System.Reflection.ParameterModifier[]):System.Reflection.MethodBase:this
      180.12 ( 6.93% of base) : 14874.dasm - LUDecomp:Run():double:this
      162.05 ( 4.30% of base) : 12999.dasm - MessagePack.Formatters.MicroBenchmarks_Serializers_MyEventsListerItemTaskFormatter3:Deserialize(System.Byte[],int,MessagePack.IFormatterResolver,byref):MicroBenchmarks.Serializers.MyEventsListerItemTask:this
      137.12 ( 7.09% of base) : 1745.dasm - System.Reflection.Emit.MethodBuilder:CreateMethodBodyHelper(System.Reflection.Emit.ILGenerator):this
      133.00 ( 2.48% of base) : 1141.dasm - ProtoBuf.Meta.MetaType:ResolveTupleConstructor(System.Type,byref):System.Reflection.ConstructorInfo
      129.60 ( 1.50% of base) : 16691.dasm - Microsoft.CodeAnalysis.CSharp.Symbols.SourceNamedTypeSymbol:MakeTypeParameters(Microsoft.CodeAnalysis.DiagnosticBag):System.Collections.Immutable.ImmutableArray`1[[Microsoft.CodeAnalysis.CSharp.Symbols.TypeParameterSymbol, Microsoft.CodeAnalysis.CSharp, Version=2.10.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]:this
       93.74 ( 4.71% of base) : 20022.dasm - Benchstone.BenchI.Array2:VerifyCopy(System.Int32[][][],System.Int32[][][]):bool
       82.00 ( 1.46% of base) : 13932.dasm - NeuralJagged:read_data_file():this
       79.20 ( 3.91% of base) : 13941.dasm - NeuralJagged:move_wt_changes()
       74.10 (11.71% of base) : 11425.dasm - EMFloatClass:Run():double:this
       72.00 (10.69% of base) : 22951.dasm - ConstructorMatcher:Match(System.Object[]):int:this
       62.40 ( 3.31% of base) : 13948.dasm - NeuralJagged:adjust_mid_wts(int)
       62.25 ( 7.46% of base) : 3540.dasm - System.Xml.Serialization.TypeScope:Popu

@EgorBo
Copy link
Member Author

EgorBo commented Nov 9, 2021

@kunalspathak I changed the code slighty, what I've done is basically converted ifdef-else into normal if-else and enabled that new shape (arrRef + elemOffset) + index only for primitive types, it significantly improved diffs, e.g. Benchmarks collections was:
1332 improved, 365 regressed
now:
1136 improved, 84 regressed

Most of the benchmarks you listed got fixed, BenchI.AddArray is still a size regression but overall it looks like a perf improvement actually: https://www.diffchecker.com/Msv0RBMs (less code in loops)

New diffs: https://gist.github.com/EgorBo/dd3b682f69ce2a530a8019c0e8bf46b2

@EgorBo EgorBo merged commit e5eafc9 into dotnet:main Nov 10, 2021
@EgorBo
Copy link
Member Author

EgorBo commented Nov 11, 2021

arm64 improvements dotnet/perf-autofiling-issues#2248

@DrewScoggins
Copy link
Member

DrewScoggins commented Nov 19, 2021

@AndyAyersMS
Copy link
Member

More improvements: dotnet/perf-autofiling-issues#2406

@AndyAyersMS
Copy link
Member

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Code inefficiencies in loop array indexing
6 participants