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

Move the "do not zero-extend setcc" optimization to lower #53778

Merged
merged 4 commits into from
Jul 13, 2021

Conversation

SingleAccretion
Copy link
Contributor

@SingleAccretion SingleAccretion commented Jun 6, 2021

It is XARCH-specific and moving it eliminates questionable code that is trying to compensate for CSE changing the store. Also removes a case where a node that actually produces TYP_INT has a small type in HIR.

Also, use strongly-typed trees (and related helpers) for the lowering functions that deal with GT_STOREIND to improve the clarity of code.

I was not looking for CQ improvements with this change, but there were, apparently, some cases that morph missed:

Windows x64 diffs
Running asm diffs of benchmarks.run.windows.x64.checked.mch

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 624
Total bytes of diff: 605
Total bytes of delta: -19 (-3.04% of base)
    diff is an improvement.


Top file improvements (bytes):
         -16 : 26199.dasm (-2.72% of base)
          -3 : 2478.dasm (-8.33% of base)

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

Top method improvements (bytes):
         -16 (-2.72% of base) - Benchstone.BenchI.NDhrystone:Proc0()
          -3 (-8.33% of base) - Utf8Json.Internal.UnsafeMemory:.cctor()

Top method improvements (percentages):
          -3 (-8.33% of base) - Utf8Json.Internal.UnsafeMemory:.cctor()
         -16 (-2.72% of base) - Benchstone.BenchI.NDhrystone:Proc0()

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

Running asm diffs of coreclr_tests.pmi.windows.x64.checked.mch

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 4897
Total bytes of diff: 4837
Total bytes of delta: -60 (-1.23% of base)
    diff is an improvement.


Top file improvements (bytes):
          -6 : 253256.dasm (-2.37% of base)
          -3 : 239999.dasm (-3.30% of base)
          -3 : 83958.dasm (-0.79% of base)
          -3 : 240000.dasm (-2.63% of base)
          -3 : 242054.dasm (-8.57% of base)
          -3 : 239996.dasm (-3.26% of base)
          -3 : 251116.dasm (-0.71% of base)
          -3 : 239966.dasm (-3.26% of base)
          -3 : 83952.dasm (-0.68% of base)
          -3 : 239021.dasm (-0.53% of base)
          -3 : 83956.dasm (-0.74% of base)
          -3 : 85847.dasm (-5.45% of base)
          -3 : 239995.dasm (-3.30% of base)
          -3 : 83955.dasm (-0.71% of base)
          -3 : 83959.dasm (-0.87% of base)
          -3 : 239998.dasm (-4.17% of base)
          -3 : 83719.dasm (-0.71% of base)
          -3 : 239997.dasm (-2.16% of base)
          -3 : 83951.dasm (-0.65% of base)

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

Top method improvements (bytes):
          -6 (-2.37% of base) - ParallelCrash:Main(System.String[]):int
          -3 (-3.30% of base) - OneStructOneInt:.ctor(OneInt):this
          -3 (-0.79% of base) - LocallocTest:unwindTest1()
          -3 (-2.63% of base) - OneStructOneRtTH:.ctor(OneRtTH):this
          -3 (-8.57% of base) - OVFTest:.cctor()
          -3 (-3.26% of base) - OneBool:.ctor(bool):this
          -3 (-0.71% of base) - Test:Main(System.String[]):int
          -3 (-3.26% of base) - OneString:.ctor(System.String):this
          -3 (-0.68% of base) - LocallocTest:unwindTest2(int,int,int,int,int,int,int,int,int):this
          -3 (-0.53% of base) - Benchstone.BenchI.NDhrystone:Proc0()
          -3 (-0.74% of base) - LocallocTest:unwindTest2(int,int,int,int,int,int,int,int,int):this
          -3 (-5.45% of base) - TestClass:sel():bool
          -3 (-3.30% of base) - OneInt:.ctor(int):this
          -3 (-0.71% of base) - LocallocTest:unwindTest1()
          -3 (-0.87% of base) - LocallocTest:unwindTest2(int,int,int,int,int,int,int,int,int):this
          -3 (-4.17% of base) - OneStructOneString:.ctor(OneString):this
          -3 (-0.71% of base) - ILGEN_0x57cc69ce:Method_0x183df1b1():int
          -3 (-2.16% of base) - OneRtTH:.ctor(System.RuntimeTypeHandle):this
          -3 (-0.65% of base) - LocallocTest:unwindTest1()

Top method improvements (percentages):
          -3 (-8.57% of base) - OVFTest:.cctor()
          -3 (-5.45% of base) - TestClass:sel():bool
          -3 (-4.17% of base) - OneStructOneString:.ctor(OneString):this
          -3 (-3.30% of base) - OneStructOneInt:.ctor(OneInt):this
          -3 (-3.30% of base) - OneInt:.ctor(int):this
          -3 (-3.26% of base) - OneBool:.ctor(bool):this
          -3 (-3.26% of base) - OneString:.ctor(System.String):this
          -3 (-2.63% of base) - OneStructOneRtTH:.ctor(OneRtTH):this
          -6 (-2.37% of base) - ParallelCrash:Main(System.String[]):int
          -3 (-2.16% of base) - OneRtTH:.ctor(System.RuntimeTypeHandle):this
          -3 (-0.87% of base) - LocallocTest:unwindTest2(int,int,int,int,int,int,int,int,int):this
          -3 (-0.79% of base) - LocallocTest:unwindTest1()
          -3 (-0.74% of base) - LocallocTest:unwindTest2(int,int,int,int,int,int,int,int,int):this
          -3 (-0.71% of base) - Test:Main(System.String[]):int
          -3 (-0.71% of base) - LocallocTest:unwindTest1()
          -3 (-0.71% of base) - ILGEN_0x57cc69ce:Method_0x183df1b1():int
          -3 (-0.68% of base) - LocallocTest:unwindTest2(int,int,int,int,int,int,int,int,int):this
          -3 (-0.65% of base) - LocallocTest:unwindTest1()
          -3 (-0.53% of base) - Benchstone.BenchI.NDhrystone:Proc0()

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

Running asm diffs of libraries.crossgen.windows.x64.checked.mch

Running asm diffs of libraries.crossgen2.windows.x64.checked.mch

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 163
Total bytes of diff: 160
Total bytes of delta: -3 (-1.84% of base)
    diff is an improvement.


Top file improvements (bytes):
          -3 : 131232.dasm (-1.84% of base)

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

Top method improvements (bytes):
          -3 (-1.84% of base) - BitArrayEnumeratorSimple:MoveNext():bool:this

Top method improvements (percentages):
          -3 (-1.84% of base) - BitArrayEnumeratorSimple:MoveNext():bool:this

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

Running asm diffs of libraries.pmi.windows.x64.checked.mch

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 4762
Total bytes of diff: 4744
Total bytes of delta: -18 (-0.38% of base)
    diff is an improvement.


Top file improvements (bytes):
          -3 : 215927.dasm (-2.94% of base)
          -3 : 166865.dasm (-0.62% of base)
          -3 : 166023.dasm (-0.08% of base)
          -3 : 176854.dasm (-8.33% of base)
          -3 : 155365.dasm (-1.67% of base)
          -3 : 215926.dasm (-2.94% of base)

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

Top method improvements (bytes):
          -3 (-2.94% of base) - System.Security.Cryptography.Xml.SignedXmlDebugLog:get_VerboseLoggingEnabled():bool
          -3 (-0.62% of base) - System.Data.Common.ADP:.cctor()
          -3 (-0.08% of base) - System.Data.OleDb.ODB:.cctor()
          -3 (-8.33% of base) - System.IO.Compression.ZipArchiveEntry:.cctor()
          -3 (-1.67% of base) - BitArrayEnumeratorSimple:MoveNext():bool:this
          -3 (-2.94% of base) - System.Security.Cryptography.Xml.SignedXmlDebugLog:get_InformationLoggingEnabled():bool

Top method improvements (percentages):
          -3 (-8.33% of base) - System.IO.Compression.ZipArchiveEntry:.cctor()
          -3 (-2.94% of base) - System.Security.Cryptography.Xml.SignedXmlDebugLog:get_VerboseLoggingEnabled():bool
          -3 (-2.94% of base) - System.Security.Cryptography.Xml.SignedXmlDebugLog:get_InformationLoggingEnabled():bool
          -3 (-1.67% of base) - BitArrayEnumeratorSimple:MoveNext():bool:this
          -3 (-0.62% of base) - System.Data.Common.ADP:.cctor()
          -3 (-0.08% of base) - System.Data.OleDb.ODB:.cctor()

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

Running asm diffs of libraries_tests.pmi.windows.x64.checked.mch

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 4647
Total bytes of diff: 4497
Total bytes of delta: -150 (-3.23% of base)
    diff is an improvement.


Top file improvements (bytes):
          -9 : 2587.dasm (-5.45% of base)
          -9 : 2601.dasm (-4.13% of base)
          -6 : 117781.dasm (-4.51% of base)
          -3 : 190531.dasm (-8.57% of base)
          -3 : 199520.dasm (-6.12% of base)
          -3 : 219914.dasm (-8.57% of base)
          -3 : 224218.dasm (-8.57% of base)
          -3 : 26189.dasm (-3.30% of base)
          -3 : 296193.dasm (-8.57% of base)
          -3 : 5051.dasm (-5.36% of base)
          -3 : 120465.dasm (-3.41% of base)
          -3 : 218435.dasm (-8.57% of base)
          -3 : 291444.dasm (-8.57% of base)
          -3 : 309112.dasm (-8.57% of base)
          -3 : 93739.dasm (-0.65% of base)
          -3 : 117774.dasm (-4.84% of base)
          -3 : 2030.dasm (-1.04% of base)
          -3 : 221066.dasm (-8.57% of base)
          -3 : 24160.dasm (-0.63% of base)
          -3 : 26212.dasm (-3.45% of base)

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

Top method improvements (bytes):
          -9 (-5.45% of base) - Microsoft.Build.Internal.Utilities:RefreshInternalEnvironmentValues()
          -9 (-4.13% of base) - Microsoft.Build.Internal.Utilities:.cctor()
          -6 (-4.51% of base) - Microsoft.Build.Tasks.Copy:.cctor()
          -3 (-8.57% of base) - System.Net.Tests.HttpListenerContextTests:.cctor()
          -3 (-6.12% of base) - System.Security.Cryptography.X509Certificates.Tests.Common.RevocationResponder:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-3.30% of base) - <>c__DisplayClass4_0:<Get_InvalidIndex_ThrowsArgumentOutOfRangeException>b__1():System.Object:this
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-5.36% of base) - Microsoft.Build.BackEnd.Logging.TargetLoggingContext:.cctor()
          -3 (-3.41% of base) - Microsoft.Build.Shared.ErrorUtilities:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-0.65% of base) - System.Text.Json.Tests.Utf8JsonWriterTests:.cctor()
          -3 (-4.84% of base) - Microsoft.Build.Tasks.Copy:RefreshInternalEnvironmentValues()
          -3 (-1.04% of base) - Microsoft.Build.Evaluation.Project:.cctor()
          -3 (-8.57% of base) - System.Security.Cryptography.Pkcs.EnvelopedCmsTests.Tests.DecryptTests:.cctor()
          -3 (-0.63% of base) - System.Collections.Tests.BitArray_GetSetTests:GetEnumerator(System.Boolean[])
          -3 (-3.45% of base) - <>c__DisplayClass13_0:<Length_Set>b__0():System.Object:this

Top method improvements (percentages):
          -3 (-8.57% of base) - System.Net.Tests.HttpListenerContextTests:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - System.Security.Cryptography.Pkcs.EnvelopedCmsTests.Tests.DecryptTests:.cctor()
          -3 (-8.57% of base) - System.Net.Tests.HttpListenerWebSocketTests:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.57% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.33% of base) - System.Text.Json.Serialization.Tests.WriteValueTests:.cctor()
          -3 (-8.33% of base) - System.Composition.TypedParts.Tests.ReflectionTests:.cctor()

45 total methods with Code Size differences (45 improved, 0 regressed), 0 unchanged.
Windows x86 diffs
Running asm diffs of benchmarks.run.windows.x86.checked.mch

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 447
Total bytes of diff: 444
Total bytes of delta: -3 (-0.67% of base)
    diff is an improvement.


Top file improvements (bytes):
          -3 : 2466.dasm (-12.50% of base)

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

Top method improvements (bytes):
          -3 (-12.50% of base) - Utf8Json.Internal.UnsafeMemory:.cctor()

Top method improvements (percentages):
          -3 (-12.50% of base) - Utf8Json.Internal.UnsafeMemory:.cctor()

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

Running asm diffs of coreclr_tests.pmi.windows.x86.checked.mch

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 3573
Total bytes of diff: 3503
Total bytes of delta: -70 (-1.96% of base)
    diff is an improvement.


Top file improvements (bytes):
          -7 : 83941.dasm (-2.15% of base)
          -7 : 83945.dasm (-2.39% of base)
          -7 : 83948.dasm (-2.68% of base)
          -6 : 252844.dasm (-3.09% of base)
          -3 : 239630.dasm (-4.41% of base)
          -3 : 83708.dasm (-0.76% of base)
          -3 : 239600.dasm (-4.69% of base)
          -3 : 85834.dasm (-7.32% of base)
          -3 : 239631.dasm (-2.86% of base)
          -3 : 250711.dasm (-0.96% of base)
          -3 : 239629.dasm (-4.48% of base)
          -3 : 239632.dasm (-5.56% of base)
          -3 : 241687.dasm (-13.04% of base)
          -3 : 83947.dasm (-1.28% of base)
          -3 : 238800.dasm (-0.74% of base)
          -3 : 83940.dasm (-0.99% of base)
          -3 : 239633.dasm (-4.48% of base)
          -3 : 83944.dasm (-1.10% of base)
          -1 : 239634.dasm (-1.16% of base)

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

Top method improvements (bytes):
          -7 (-2.15% of base) - LocallocTest:unwindTest2(int,int,int,int,int,int,int,int,int):this
          -7 (-2.39% of base) - LocallocTest:unwindTest2(int,int,int,int,int,int,int,int,int):this
          -7 (-2.68% of base) - LocallocTest:unwindTest2(int,int,int,int,int,int,int,int,int):this
          -6 (-3.09% of base) - ParallelCrash:Main(System.String[]):int
          -3 (-4.41% of base) - OneBool:.ctor(bool):this
          -3 (-0.76% of base) - ILGEN_0x57cc69ce:Method_0x183df1b1():int
          -3 (-4.69% of base) - OneString:.ctor(System.String):this
          -3 (-7.32% of base) - TestClass:sel():bool
          -3 (-2.86% of base) - OneRtTH:.ctor(System.RuntimeTypeHandle):this
          -3 (-0.96% of base) - Test:Main(System.String[]):int
          -3 (-4.48% of base) - OneInt:.ctor(int):this
          -3 (-5.56% of base) - OneStructOneString:.ctor(OneString):this
          -3 (-13.04% of base) - OVFTest:.cctor()
          -3 (-1.28% of base) - LocallocTest:unwindTest1()
          -3 (-0.74% of base) - Benchstone.BenchI.NDhrystone:Proc0()
          -3 (-0.99% of base) - LocallocTest:unwindTest1()
          -3 (-4.48% of base) - OneStructOneInt:.ctor(OneInt):this
          -3 (-1.10% of base) - LocallocTest:unwindTest1()
          -1 (-1.16% of base) - OneStructOneRtTH:.ctor(OneRtTH):this

Top method improvements (percentages):
          -3 (-13.04% of base) - OVFTest:.cctor()
          -3 (-7.32% of base) - TestClass:sel():bool
          -3 (-5.56% of base) - OneStructOneString:.ctor(OneString):this
          -3 (-4.69% of base) - OneString:.ctor(System.String):this
          -3 (-4.48% of base) - OneInt:.ctor(int):this
          -3 (-4.48% of base) - OneStructOneInt:.ctor(OneInt):this
          -3 (-4.41% of base) - OneBool:.ctor(bool):this
          -6 (-3.09% of base) - ParallelCrash:Main(System.String[]):int
          -3 (-2.86% of base) - OneRtTH:.ctor(System.RuntimeTypeHandle):this
          -7 (-2.68% of base) - LocallocTest:unwindTest2(int,int,int,int,int,int,int,int,int):this
          -7 (-2.39% of base) - LocallocTest:unwindTest2(int,int,int,int,int,int,int,int,int):this
          -7 (-2.15% of base) - LocallocTest:unwindTest2(int,int,int,int,int,int,int,int,int):this
          -3 (-1.28% of base) - LocallocTest:unwindTest1()
          -1 (-1.16% of base) - OneStructOneRtTH:.ctor(OneRtTH):this
          -3 (-1.10% of base) - LocallocTest:unwindTest1()
          -3 (-0.99% of base) - LocallocTest:unwindTest1()
          -3 (-0.96% of base) - Test:Main(System.String[]):int
          -3 (-0.76% of base) - ILGEN_0x57cc69ce:Method_0x183df1b1():int
          -3 (-0.74% of base) - Benchstone.BenchI.NDhrystone:Proc0()

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

Running asm diffs of libraries.crossgen.windows.x86.checked.mch

Running asm diffs of libraries.crossgen2.windows.x86.checked.mch

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 141
Total bytes of diff: 138
Total bytes of delta: -3 (-2.13% of base)
    diff is an improvement.


Top file improvements (bytes):
          -3 : 201795.dasm (-2.13% of base)

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

Top method improvements (bytes):
          -3 (-2.13% of base) - BitArrayEnumeratorSimple:MoveNext():bool:this

Top method improvements (percentages):
          -3 (-2.13% of base) - BitArrayEnumeratorSimple:MoveNext():bool:this

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

Running asm diffs of libraries.pmi.windows.x86.checked.mch

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 3515
Total bytes of diff: 3497
Total bytes of delta: -18 (-0.51% of base)
    diff is an improvement.


Top file improvements (bytes):
          -3 : 121617.dasm (-0.74% of base)
          -3 : 181737.dasm (-2.01% of base)
          -3 : 120761.dasm (-0.11% of base)
          -3 : 217941.dasm (-3.61% of base)
          -3 : 217942.dasm (-3.61% of base)
          -3 : 191973.dasm (-12.50% of base)

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

Top method improvements (bytes):
          -3 (-0.74% of base) - System.Data.Common.ADP:.cctor()
          -3 (-2.01% of base) - BitArrayEnumeratorSimple:MoveNext():bool:this
          -3 (-0.11% of base) - System.Data.OleDb.ODB:.cctor()
          -3 (-3.61% of base) - System.Security.Cryptography.Xml.SignedXmlDebugLog:get_InformationLoggingEnabled():bool
          -3 (-3.61% of base) - System.Security.Cryptography.Xml.SignedXmlDebugLog:get_VerboseLoggingEnabled():bool
          -3 (-12.50% of base) - System.IO.Compression.ZipArchiveEntry:.cctor()

Top method improvements (percentages):
          -3 (-12.50% of base) - System.IO.Compression.ZipArchiveEntry:.cctor()
          -3 (-3.61% of base) - System.Security.Cryptography.Xml.SignedXmlDebugLog:get_InformationLoggingEnabled():bool
          -3 (-3.61% of base) - System.Security.Cryptography.Xml.SignedXmlDebugLog:get_VerboseLoggingEnabled():bool
          -3 (-2.01% of base) - BitArrayEnumeratorSimple:MoveNext():bool:this
          -3 (-0.74% of base) - System.Data.Common.ADP:.cctor()
          -3 (-0.11% of base) - System.Data.OleDb.ODB:.cctor()

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

Running asm diffs of libraries_tests.pmi.windows.x86.checked.mch

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 3486
Total bytes of diff: 3336
Total bytes of delta: -150 (-4.30% of base)
    diff is an improvement.


Top file improvements (bytes):
          -9 : 2590.dasm (-5.56% of base)
          -9 : 2576.dasm (-6.87% of base)
          -6 : 116942.dasm (-5.61% of base)
          -3 : 119626.dasm (-5.08% of base)
          -3 : 197149.dasm (-13.04% of base)
          -3 : 198571.dasm (-10.34% of base)
          -3 : 217414.dasm (-13.04% of base)
          -3 : 221681.dasm (-8.33% of base)
          -3 : 24072.dasm (-0.72% of base)
          -3 : 26093.dasm (-3.95% of base)
          -3 : 26116.dasm (-4.11% of base)
          -3 : 307409.dasm (-13.04% of base)
          -3 : 307838.dasm (-13.04% of base)
          -3 : 118779.dasm (-5.08% of base)
          -3 : 296390.dasm (-13.04% of base)
          -3 : 194302.dasm (-13.04% of base)
          -3 : 2020.dasm (-1.47% of base)
          -3 : 218893.dasm (-13.04% of base)
          -3 : 220710.dasm (-13.04% of base)
          -3 : 223197.dasm (-13.04% of base)

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

Top method improvements (bytes):
          -9 (-5.56% of base) - Microsoft.Build.Internal.Utilities:.cctor()
          -9 (-6.87% of base) - Microsoft.Build.Internal.Utilities:RefreshInternalEnvironmentValues()
          -6 (-5.61% of base) - Microsoft.Build.Tasks.Copy:.cctor()
          -3 (-5.08% of base) - Microsoft.Build.Shared.ErrorUtilities:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-10.34% of base) - System.Security.Cryptography.X509Certificates.Tests.Common.RevocationResponder:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-8.33% of base) - System.Security.Cryptography.X509Certificates.Tests.TestEnvironmentConfiguration:.cctor()
          -3 (-0.72% of base) - System.Collections.Tests.BitArray_GetSetTests:GetEnumerator(System.Boolean[])
          -3 (-3.95% of base) - <>c__DisplayClass4_0:<Get_InvalidIndex_ThrowsArgumentOutOfRangeException>b__1():System.Object:this
          -3 (-4.11% of base) - <>c__DisplayClass13_0:<Length_Set>b__0():System.Object:this
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-5.08% of base) - Microsoft.Build.Shared.ErrorUtilities:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-1.47% of base) - Microsoft.Build.Evaluation.Project:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()

Top method improvements (percentages):
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - System.Net.Tests.HttpListenerWebSocketTests:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - System.Security.Cryptography.Pkcs.EnvelopedCmsTests.Tests.DecryptTests:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - Test.Cryptography.PlatformSupport:.cctor()
          -3 (-13.04% of base) - System.Net.Tests.HttpListenerContextTests:.cctor()
          -3 (-12.50% of base) - System.Tests.GCTests:.cctor()
          -3 (-12.50% of base) - System.Composition.TypedParts.Tests.ReflectionTests:.cctor()

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

As expected, this is a no-diff change for ARMARCH - verified via replaying linux-arm and linux-arm64 collections.

Depending on the merge order, this might conflict with #53667 (that's fine, just mentioning it for completeness).

@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 Jun 6, 2021
It is XARCH-specific and moving it eliminates questionable code
that is trying to compensate for CSE changing the store.
@SingleAccretion SingleAccretion marked this pull request as ready for review June 6, 2021 05:38
@SingleAccretion
Copy link
Contributor Author

cc @sandreenko, @kunalspathak

@kunalspathak
Copy link
Member

Any changes in libraries.pmi for xarch/armarch?

@SingleAccretion
Copy link
Contributor Author

SingleAccretion commented Jun 7, 2021

For XARCH, x64 (also see above):

Running asm diffs of libraries.pmi.windows.x64.checked.mch

Summary of Code Size diffs:
(Lower is better)

Total bytes of base: 4762
Total bytes of diff: 4744
Total bytes of delta: -18 (-0.38% of base)
    diff is an improvement.


Top file improvements (bytes):
          -3 : 215927.dasm (-2.94% of base)
          -3 : 166865.dasm (-0.62% of base)
          -3 : 166023.dasm (-0.08% of base)
          -3 : 176854.dasm (-8.33% of base)
          -3 : 155365.dasm (-1.67% of base)
          -3 : 215926.dasm (-2.94% of base)

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

Top method improvements (bytes):
          -3 (-2.94% of base) - System.Security.Cryptography.Xml.SignedXmlDebugLog:get_VerboseLoggingEnabled():bool
          -3 (-0.62% of base) - System.Data.Common.ADP:.cctor()
          -3 (-0.08% of base) - System.Data.OleDb.ODB:.cctor()
          -3 (-8.33% of base) - System.IO.Compression.ZipArchiveEntry:.cctor()
          -3 (-1.67% of base) - BitArrayEnumeratorSimple:MoveNext():bool:this
          -3 (-2.94% of base) - System.Security.Cryptography.Xml.SignedXmlDebugLog:get_InformationLoggingEnabled():bool

Top method improvements (percentages):
          -3 (-8.33% of base) - System.IO.Compression.ZipArchiveEntry:.cctor()
          -3 (-2.94% of base) - System.Security.Cryptography.Xml.SignedXmlDebugLog:get_VerboseLoggingEnabled():bool
          -3 (-2.94% of base) - System.Security.Cryptography.Xml.SignedXmlDebugLog:get_InformationLoggingEnabled():bool
          -3 (-1.67% of base) - BitArrayEnumeratorSimple:MoveNext():bool:this
          -3 (-0.62% of base) - System.Data.Common.ADP:.cctor()
          -3 (-0.08% of base) - System.Data.OleDb.ODB:.cctor()

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

No diffs for ARMARCH as expected.

@JulieLeeMSFT
Copy link
Member

@kunalspathak @dotnet/jit-contrib PTAL.

Copy link
Member

@kunalspathak kunalspathak left a comment

Choose a reason for hiding this comment

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

LGTM. I am re-running the failed jobs just to be sure.

@kunalspathak kunalspathak merged commit d021b56 into dotnet:main Jul 13, 2021
@SingleAccretion SingleAccretion deleted the Move-Relop-Opt-To-Lower branch July 13, 2021 16:49
@ghost ghost locked as resolved and limited conversation to collaborators Aug 12, 2021
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.

3 participants