From d2808f909b1aca0e3c6d7be783198e657880c5ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20Strehovsk=C3=BD?= Date: Thu, 7 Aug 2025 10:57:12 +0200 Subject: [PATCH 1/7] Ensure we consider types with required constructors allocated ...even if there's no constructor. This was found in https://github.com/dotnet/runtime/pull/118060/files#r2247963234 but the test case I'm adding is also failing in .NET 9 and doesn't require an IL-only repro to hit. --- .../Compiler/Dataflow/ReflectionMarker.cs | 11 ++++++ .../MLKemCngTests.NotSupported.cs | 2 +- .../SmokeTests/Reflection/Reflection.cs | 37 +++++++++++++++++++ 3 files changed, 49 insertions(+), 1 deletion(-) diff --git a/src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Dataflow/ReflectionMarker.cs b/src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Dataflow/ReflectionMarker.cs index 056032d025bfe8..51adc07a362c6e 100644 --- a/src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Dataflow/ReflectionMarker.cs +++ b/src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Dataflow/ReflectionMarker.cs @@ -53,6 +53,12 @@ internal void MarkTypeForDynamicallyAccessedMembers(in MessageOrigin origin, Typ if (!_enabled) return; + // If we're keeping constructors, ensure the type is considered allocated even if we find no + // matching members below. This covers cases like structs or classes without any constructors. + if ((requiredMemberTypes & DynamicallyAccessedMemberTypes.AllConstructors) != 0 + && typeDefinition is not MetadataType { IsAbstract: true }) + MarkType(origin, typeDefinition, reason); + foreach (var member in typeDefinition.GetDynamicallyAccessedMembers(requiredMemberTypes, declaredOnly)) { MarkTypeSystemEntity(origin, member, reason, AccessKind.DynamicallyAccessedMembersMark); @@ -198,6 +204,11 @@ internal void MarkConstructorsOnType(in MessageOrigin origin, TypeDesc type, Fun if (!_enabled) return; + // Ensure the type is considered allocated even if we find no constructors below. + // This covers cases like structs or classes without any constructors. + if (type is not MetadataType { IsAbstract: true }) + MarkType(origin, type, reason); + foreach (var ctor in type.GetConstructorsOnType(filter, bindingFlags)) MarkMethod(origin, ctor, reason); } diff --git a/src/libraries/Common/tests/System/Security/Cryptography/MLKemCngTests.NotSupported.cs b/src/libraries/Common/tests/System/Security/Cryptography/MLKemCngTests.NotSupported.cs index fd29006249c75b..bdb64d4638eee6 100644 --- a/src/libraries/Common/tests/System/Security/Cryptography/MLKemCngTests.NotSupported.cs +++ b/src/libraries/Common/tests/System/Security/Cryptography/MLKemCngTests.NotSupported.cs @@ -10,7 +10,7 @@ namespace System.Security.Cryptography.Tests [PlatformSpecific(~TestPlatforms.Windows)] public sealed class MLKemCngNotSupportedTests { - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotBuiltWithAggressiveTrimming))] + [Fact] public static void MLKemCng_NotSupportedOnNonWindowsPlatforms() { // We cannot actually construct a CngKey on non-Windows platforms, so this cheats by just instantiating diff --git a/src/tests/nativeaot/SmokeTests/Reflection/Reflection.cs b/src/tests/nativeaot/SmokeTests/Reflection/Reflection.cs index a0ee00a5e7ac21..d8cee5e43850aa 100644 --- a/src/tests/nativeaot/SmokeTests/Reflection/Reflection.cs +++ b/src/tests/nativeaot/SmokeTests/Reflection/Reflection.cs @@ -76,6 +76,7 @@ private static int Main() Test105034Regression.Run(); TestMethodsNeededFromNativeLayout.Run(); TestFieldAndParamMetadata.Run(); + TestActivationWithoutConstructor.Run(); // // Mostly functionality tests @@ -859,6 +860,42 @@ public static void Run() } } + class TestActivationWithoutConstructor + { + static void Main() + { + { + object o = Activator.CreateInstance(typeof(StructForCreateInstanceDirect<>).MakeGenericType(GetTheType())); + if (!o.ToString().Contains(nameof(StructForCreateInstanceDirect<>))) + throw new Exception(); + } + + { + object o = CreateInstance(typeof(StructForCreateInstanceIndirect<>).MakeGenericType(GetTheType())); + if (!o.ToString().Contains(nameof(StructForCreateInstanceIndirect<>))) + throw new Exception(); + + static object CreateInstance([DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.PublicParameterlessConstructor)] Type t) + => Activator.CreateInstance(t); + } + + { + object o = RuntimeHelpers.GetUninitializedObject(typeof(StructForGetUninitializedObject<>).MakeGenericType(GetTheType())); + if (!o.ToString().Contains(nameof(StructForGetUninitializedObject<>))) + throw new Exception(); + } + + [MethodImpl(MethodImplOptions.NoInlining)] + static Type GetTheType() => typeof(Atom); + } + + class Atom; + + struct StructForCreateInstanceDirect where T : class; + struct StructForCreateInstanceIndirect where T : class; + struct StructForGetUninitializedObject where T : class; + } + class TestCreateDelegate { internal class Greeter From 55452d1c2b1aae07be8a7f8c2772760501329f8a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20Strehovsk=C3=BD?= Date: Thu, 7 Aug 2025 13:19:00 +0200 Subject: [PATCH 2/7] Try fixing some size regressions --- .../src/System/ValueType.cs | 4 +-- .../IL/ILImporter.Scanner.cs | 28 +++++++++++++++---- 2 files changed, 25 insertions(+), 7 deletions(-) diff --git a/src/coreclr/nativeaot/System.Private.CoreLib/src/System/ValueType.cs b/src/coreclr/nativeaot/System.Private.CoreLib/src/System/ValueType.cs index c19988c9bd6782..2406c5d9ffb9de 100644 --- a/src/coreclr/nativeaot/System.Private.CoreLib/src/System/ValueType.cs +++ b/src/coreclr/nativeaot/System.Private.CoreLib/src/System/ValueType.cs @@ -127,11 +127,11 @@ private unsafe void RegularGetValueTypeHashCode(ref HashCode hashCode, ref byte if (fieldType->ElementType == EETypeElementType.Single) { - hashCode.Add(Unsafe.As(ref fieldData)); + hashCode.Add(Unsafe.As(ref fieldData).GetHashCode()); } else if (fieldType->ElementType == EETypeElementType.Double) { - hashCode.Add(Unsafe.As(ref fieldData)); + hashCode.Add(Unsafe.As(ref fieldData).GetHashCode()); } else if (fieldType->IsPrimitive) { diff --git a/src/coreclr/tools/aot/ILCompiler.Compiler/IL/ILImporter.Scanner.cs b/src/coreclr/tools/aot/ILCompiler.Compiler/IL/ILImporter.Scanner.cs index 92e8126b482dd1..41acdfe21b68b3 100644 --- a/src/coreclr/tools/aot/ILCompiler.Compiler/IL/ILImporter.Scanner.cs +++ b/src/coreclr/tools/aot/ILCompiler.Compiler/IL/ILImporter.Scanner.cs @@ -959,6 +959,23 @@ private void ImportLdToken(int token) } } + // We might also be able to optimize this if this is typeof(Foo).IsValueType + if (helperId != ReadyToRunHelperId.NecessaryTypeHandle) + { + reader = new ILReader(_ilBytes, _currentOffset); + if (reader.HasNext + && reader.ReadILOpcode() == ILOpcode.call + && IsTypeGetTypeFromHandle((MethodDesc)_methodIL.GetObject(reader.ReadILToken()))) + { + if (reader.HasNext + && reader.ReadILOpcode() is ILOpcode.callvirt or ILOpcode.call + && _methodIL.GetObject(reader.ReadILToken()) is MethodDesc { Name: "get_IsValueType" or "get_IsEnum"}) + { + helperId = ReadyToRunHelperId.NecessaryTypeHandle; + } + } + } + _factory.MetadataManager.GetDependenciesDueToAccess(ref _dependencies, _factory, _methodIL, (TypeDesc)_canonMethodIL.GetObject(token)); _dependencies.Add(GetHelperEntrypoint(ReadyToRunHelper.GetRuntimeTypeHandle), "ldtoken"); @@ -1143,10 +1160,8 @@ private void ImportBox(int token) { var type = (TypeDesc)_methodIL.GetObject(token); - // There are some sequences of box with ByRefLike types that are allowed - // per the extension to the ECMA-335 specification. - // Everything else is invalid. - if (!type.IsRuntimeDeterminedType && type.IsByRefLike) + // Some box operations will trivially be eliminated during import + if (!type.IsRuntimeDeterminedType) { ILReader reader = new ILReader(_ilBytes, _currentOffset); ILOpcode nextOpcode = reader.ReadILOpcode(); @@ -1180,7 +1195,9 @@ private void ImportBox(int token) } } - ThrowHelper.ThrowInvalidProgramException(); + // If this is a byref-like type, only the above operations are permitted. + if (type.IsByRefLike) + ThrowHelper.ThrowInvalidProgramException(); } AddBoxingDependencies(type, "Box"); @@ -1353,6 +1370,7 @@ private void ImportConvert(WellKnownType wellKnownType, bool checkOverflow, bool { if (checkOverflow) { + // _dependencies.Add(GetHelperEntrypoint(ReadyToRunHelper.Dbl2IntOvf), "_dbl2intovf"); _dependencies.Add(GetHelperEntrypoint(ReadyToRunHelper.Dbl2UIntOvf), "_dbl2uintovf"); _dependencies.Add(GetHelperEntrypoint(ReadyToRunHelper.Dbl2LngOvf), "_dbl2lngovf"); From a53d01fdeb1877a46ce324c3f0d0513985683bc0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20Strehovsk=C3=BD?= Date: Thu, 7 Aug 2025 13:20:28 +0200 Subject: [PATCH 3/7] Update Reflection.cs --- src/tests/nativeaot/SmokeTests/Reflection/Reflection.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tests/nativeaot/SmokeTests/Reflection/Reflection.cs b/src/tests/nativeaot/SmokeTests/Reflection/Reflection.cs index d8cee5e43850aa..3ed21c3b6ab8d4 100644 --- a/src/tests/nativeaot/SmokeTests/Reflection/Reflection.cs +++ b/src/tests/nativeaot/SmokeTests/Reflection/Reflection.cs @@ -862,7 +862,7 @@ public static void Run() class TestActivationWithoutConstructor { - static void Main() + public static void Run() { { object o = Activator.CreateInstance(typeof(StructForCreateInstanceDirect<>).MakeGenericType(GetTheType())); From 66f1c565d1f6f49777e8edafc61114fccfe468ef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20Strehovsk=C3=BD?= Date: Thu, 7 Aug 2025 16:19:21 +0200 Subject: [PATCH 4/7] Update DeadCodeElimination.cs --- .../SmokeTests/TrimmingBehaviors/DeadCodeElimination.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tests/nativeaot/SmokeTests/TrimmingBehaviors/DeadCodeElimination.cs b/src/tests/nativeaot/SmokeTests/TrimmingBehaviors/DeadCodeElimination.cs index fa3417f7a78400..ba9e1b0f624b32 100644 --- a/src/tests/nativeaot/SmokeTests/TrimmingBehaviors/DeadCodeElimination.cs +++ b/src/tests/nativeaot/SmokeTests/TrimmingBehaviors/DeadCodeElimination.cs @@ -760,8 +760,8 @@ public static void Run() // We only expect to be able to get rid of it when optimizing #if !DEBUG ThrowIfPresent(typeof(TestBranchesInGenericCodeRemoval), nameof(Unused)); + ThrowIfPresent(typeof(TestBranchesInGenericCodeRemoval), nameof(Used)); #endif - ThrowIfNotPresent(typeof(TestBranchesInGenericCodeRemoval), nameof(Used)); ThrowIfPresent(typeof(TestBranchesInGenericCodeRemoval), nameof(UnusedFromVirtual)); ThrowIfNotPresent(typeof(TestBranchesInGenericCodeRemoval), nameof(UsedFromVirtual)); From 07c86a971399a823d9697b325a22060f220f0741 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20Strehovsk=C3=BD?= Date: Fri, 8 Aug 2025 06:54:47 +0200 Subject: [PATCH 5/7] Better fix --- .../Compiler/Dataflow/HandleCallAction.cs | 21 +++++++++++++------ .../Compiler/Dataflow/ReflectionMarker.cs | 11 ---------- .../MLKemCngTests.NotSupported.cs | 2 +- .../SmokeTests/Reflection/Reflection.cs | 19 +++++++++++++++++ 4 files changed, 35 insertions(+), 18 deletions(-) diff --git a/src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Dataflow/HandleCallAction.cs b/src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Dataflow/HandleCallAction.cs index 9c5927a7532c03..6f67e769dd3a1d 100644 --- a/src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Dataflow/HandleCallAction.cs +++ b/src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Dataflow/HandleCallAction.cs @@ -90,15 +90,24 @@ private partial bool TryHandleIntrinsic( } } } - else if (typeInstantiated.Instantiation.IsConstrainedToBeReferenceTypes()) - { - // This will always succeed thanks to the runtime type loader - } else { - triggersWarning = true; - } + if (typeInstantiated.Instantiation.IsConstrainedToBeReferenceTypes()) + { + // This will always succeed thanks to the runtime type loader + } + else + { + triggersWarning = true; + } + // This should technically be in the IsConstrainedToBeReferenceTypes branch above + // but we have trim warning suppressions in dotnet/runtime and elsewhere that rely on the implementation + // detail that reference type instantiations will work, even if the generic is not + // constrained to be a reference type. + // MarkType will try to come up with a reference type type loader template. + _reflectionMarker.MarkType(_diagnosticContext.Origin, typeInstantiated, "MakeGenericType"); + } } else if (value == NullValue.Instance) { diff --git a/src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Dataflow/ReflectionMarker.cs b/src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Dataflow/ReflectionMarker.cs index 51adc07a362c6e..056032d025bfe8 100644 --- a/src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Dataflow/ReflectionMarker.cs +++ b/src/coreclr/tools/aot/ILCompiler.Compiler/Compiler/Dataflow/ReflectionMarker.cs @@ -53,12 +53,6 @@ internal void MarkTypeForDynamicallyAccessedMembers(in MessageOrigin origin, Typ if (!_enabled) return; - // If we're keeping constructors, ensure the type is considered allocated even if we find no - // matching members below. This covers cases like structs or classes without any constructors. - if ((requiredMemberTypes & DynamicallyAccessedMemberTypes.AllConstructors) != 0 - && typeDefinition is not MetadataType { IsAbstract: true }) - MarkType(origin, typeDefinition, reason); - foreach (var member in typeDefinition.GetDynamicallyAccessedMembers(requiredMemberTypes, declaredOnly)) { MarkTypeSystemEntity(origin, member, reason, AccessKind.DynamicallyAccessedMembersMark); @@ -204,11 +198,6 @@ internal void MarkConstructorsOnType(in MessageOrigin origin, TypeDesc type, Fun if (!_enabled) return; - // Ensure the type is considered allocated even if we find no constructors below. - // This covers cases like structs or classes without any constructors. - if (type is not MetadataType { IsAbstract: true }) - MarkType(origin, type, reason); - foreach (var ctor in type.GetConstructorsOnType(filter, bindingFlags)) MarkMethod(origin, ctor, reason); } diff --git a/src/libraries/Common/tests/System/Security/Cryptography/MLKemCngTests.NotSupported.cs b/src/libraries/Common/tests/System/Security/Cryptography/MLKemCngTests.NotSupported.cs index bdb64d4638eee6..fd29006249c75b 100644 --- a/src/libraries/Common/tests/System/Security/Cryptography/MLKemCngTests.NotSupported.cs +++ b/src/libraries/Common/tests/System/Security/Cryptography/MLKemCngTests.NotSupported.cs @@ -10,7 +10,7 @@ namespace System.Security.Cryptography.Tests [PlatformSpecific(~TestPlatforms.Windows)] public sealed class MLKemCngNotSupportedTests { - [Fact] + [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotBuiltWithAggressiveTrimming))] public static void MLKemCng_NotSupportedOnNonWindowsPlatforms() { // We cannot actually construct a CngKey on non-Windows platforms, so this cheats by just instantiating diff --git a/src/tests/nativeaot/SmokeTests/Reflection/Reflection.cs b/src/tests/nativeaot/SmokeTests/Reflection/Reflection.cs index 3ed21c3b6ab8d4..10a21b4d59e236 100644 --- a/src/tests/nativeaot/SmokeTests/Reflection/Reflection.cs +++ b/src/tests/nativeaot/SmokeTests/Reflection/Reflection.cs @@ -77,6 +77,7 @@ private static int Main() TestMethodsNeededFromNativeLayout.Run(); TestFieldAndParamMetadata.Run(); TestActivationWithoutConstructor.Run(); + TestNestedMakeGeneric.Run(); // // Mostly functionality tests @@ -896,6 +897,24 @@ struct StructForCreateInstanceIndirect where T : class; struct StructForGetUninitializedObject where T : class; } + class TestNestedMakeGeneric + { + class Outie where T : class; + class Innie where T : class; + class Atom; + + public static void Run() + { + Type inner = typeof(Innie<>).MakeGenericType(GetAtom()); + Type outer = typeof(Outie<>).MakeGenericType(inner); + + Console.WriteLine(Activator.CreateInstance(outer)); + + [MethodImpl(MethodImplOptions.NoInlining)] + static Type GetAtom() => typeof(Atom); + } + } + class TestCreateDelegate { internal class Greeter From 7f929abba23707ba291cf63c85af950f258e0831 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20Strehovsk=C3=BD?= Date: Fri, 8 Aug 2025 06:55:10 +0200 Subject: [PATCH 6/7] Revert "Update DeadCodeElimination.cs" This reverts commit 90a821716fda557386b8d8fd8fc466040712084d. --- .../SmokeTests/TrimmingBehaviors/DeadCodeElimination.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tests/nativeaot/SmokeTests/TrimmingBehaviors/DeadCodeElimination.cs b/src/tests/nativeaot/SmokeTests/TrimmingBehaviors/DeadCodeElimination.cs index ba9e1b0f624b32..fa3417f7a78400 100644 --- a/src/tests/nativeaot/SmokeTests/TrimmingBehaviors/DeadCodeElimination.cs +++ b/src/tests/nativeaot/SmokeTests/TrimmingBehaviors/DeadCodeElimination.cs @@ -760,8 +760,8 @@ public static void Run() // We only expect to be able to get rid of it when optimizing #if !DEBUG ThrowIfPresent(typeof(TestBranchesInGenericCodeRemoval), nameof(Unused)); - ThrowIfPresent(typeof(TestBranchesInGenericCodeRemoval), nameof(Used)); #endif + ThrowIfNotPresent(typeof(TestBranchesInGenericCodeRemoval), nameof(Used)); ThrowIfPresent(typeof(TestBranchesInGenericCodeRemoval), nameof(UnusedFromVirtual)); ThrowIfNotPresent(typeof(TestBranchesInGenericCodeRemoval), nameof(UsedFromVirtual)); From b708834c762787f8bcb5013b36ae4ca00d8db453 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20Strehovsk=C3=BD?= Date: Fri, 8 Aug 2025 06:55:19 +0200 Subject: [PATCH 7/7] Revert "Try fixing some size regressions" This reverts commit e383966c8b01ed07abeb046ebc14a4ac624c9b74. --- .../src/System/ValueType.cs | 4 +-- .../IL/ILImporter.Scanner.cs | 28 ++++--------------- 2 files changed, 7 insertions(+), 25 deletions(-) diff --git a/src/coreclr/nativeaot/System.Private.CoreLib/src/System/ValueType.cs b/src/coreclr/nativeaot/System.Private.CoreLib/src/System/ValueType.cs index 2406c5d9ffb9de..c19988c9bd6782 100644 --- a/src/coreclr/nativeaot/System.Private.CoreLib/src/System/ValueType.cs +++ b/src/coreclr/nativeaot/System.Private.CoreLib/src/System/ValueType.cs @@ -127,11 +127,11 @@ private unsafe void RegularGetValueTypeHashCode(ref HashCode hashCode, ref byte if (fieldType->ElementType == EETypeElementType.Single) { - hashCode.Add(Unsafe.As(ref fieldData).GetHashCode()); + hashCode.Add(Unsafe.As(ref fieldData)); } else if (fieldType->ElementType == EETypeElementType.Double) { - hashCode.Add(Unsafe.As(ref fieldData).GetHashCode()); + hashCode.Add(Unsafe.As(ref fieldData)); } else if (fieldType->IsPrimitive) { diff --git a/src/coreclr/tools/aot/ILCompiler.Compiler/IL/ILImporter.Scanner.cs b/src/coreclr/tools/aot/ILCompiler.Compiler/IL/ILImporter.Scanner.cs index 41acdfe21b68b3..92e8126b482dd1 100644 --- a/src/coreclr/tools/aot/ILCompiler.Compiler/IL/ILImporter.Scanner.cs +++ b/src/coreclr/tools/aot/ILCompiler.Compiler/IL/ILImporter.Scanner.cs @@ -959,23 +959,6 @@ private void ImportLdToken(int token) } } - // We might also be able to optimize this if this is typeof(Foo).IsValueType - if (helperId != ReadyToRunHelperId.NecessaryTypeHandle) - { - reader = new ILReader(_ilBytes, _currentOffset); - if (reader.HasNext - && reader.ReadILOpcode() == ILOpcode.call - && IsTypeGetTypeFromHandle((MethodDesc)_methodIL.GetObject(reader.ReadILToken()))) - { - if (reader.HasNext - && reader.ReadILOpcode() is ILOpcode.callvirt or ILOpcode.call - && _methodIL.GetObject(reader.ReadILToken()) is MethodDesc { Name: "get_IsValueType" or "get_IsEnum"}) - { - helperId = ReadyToRunHelperId.NecessaryTypeHandle; - } - } - } - _factory.MetadataManager.GetDependenciesDueToAccess(ref _dependencies, _factory, _methodIL, (TypeDesc)_canonMethodIL.GetObject(token)); _dependencies.Add(GetHelperEntrypoint(ReadyToRunHelper.GetRuntimeTypeHandle), "ldtoken"); @@ -1160,8 +1143,10 @@ private void ImportBox(int token) { var type = (TypeDesc)_methodIL.GetObject(token); - // Some box operations will trivially be eliminated during import - if (!type.IsRuntimeDeterminedType) + // There are some sequences of box with ByRefLike types that are allowed + // per the extension to the ECMA-335 specification. + // Everything else is invalid. + if (!type.IsRuntimeDeterminedType && type.IsByRefLike) { ILReader reader = new ILReader(_ilBytes, _currentOffset); ILOpcode nextOpcode = reader.ReadILOpcode(); @@ -1195,9 +1180,7 @@ private void ImportBox(int token) } } - // If this is a byref-like type, only the above operations are permitted. - if (type.IsByRefLike) - ThrowHelper.ThrowInvalidProgramException(); + ThrowHelper.ThrowInvalidProgramException(); } AddBoxingDependencies(type, "Box"); @@ -1370,7 +1353,6 @@ private void ImportConvert(WellKnownType wellKnownType, bool checkOverflow, bool { if (checkOverflow) { - // _dependencies.Add(GetHelperEntrypoint(ReadyToRunHelper.Dbl2IntOvf), "_dbl2intovf"); _dependencies.Add(GetHelperEntrypoint(ReadyToRunHelper.Dbl2UIntOvf), "_dbl2uintovf"); _dependencies.Add(GetHelperEntrypoint(ReadyToRunHelper.Dbl2LngOvf), "_dbl2lngovf");