209 references to HasInstantiation
crossgen2 (1)
Program.cs (1)
837
if (method.
HasInstantiation
)
ilc (1)
Program.cs (1)
813
if (method.
HasInstantiation
)
ILCompiler.Compiler (111)
Compiler\Compilation.cs (1)
483
Debug.Assert(calledMethod.
HasInstantiation
&& calledMethod.IsVirtual);
Compiler\CompilerTypeSystemContext.InterfaceThunks.cs (1)
74
Debug.Assert(!targetMethod.
HasInstantiation
);
Compiler\Dataflow\GenericArgumentDataFlow.cs (1)
154
if (method.
HasInstantiation
)
Compiler\Dataflow\InterproceduralState.cs (1)
94
if (methodIL.OwningMethod.
HasInstantiation
|| methodIL.OwningMethod.OwningType.HasInstantiation)
Compiler\Dataflow\ReflectionMethodBodyScanner.cs (1)
447
if (!method.Signature.IsStatic && !method.
HasInstantiation
&& !method.IsConstructor && !method.OwningType.IsValueType)
Compiler\DelegateCreationInfo.cs (3)
76
return _targetKind == TargetKind.VTableLookup || (_targetKind == TargetKind.Dispatch && !TargetMethod.
HasInstantiation
);
121
return factory.GenericLookup.ConstrainedMethodUse(_targetMethod, _constrainedType, directCall: !_targetMethod.
HasInstantiation
);
246
if (targetMethod.
HasInstantiation
)
Compiler\DependencyAnalysis\CodeBasedDependencyAlgorithm.cs (1)
72
return method.
HasInstantiation
|| method.OwningType.HasInstantiation;
Compiler\DependencyAnalysis\DispatchCellNode.cs (2)
30
Debug.Assert(targetMethod.
HasInstantiation
|| targetMethod.OwningType.IsInterface);
83
if (_targetMethod.
HasInstantiation
)
Compiler\DependencyAnalysis\DispatchCellSectionNode.cs (2)
51
protected override bool ShouldEmitCell(DispatchCellNode cell) => !cell.TargetMethod.
HasInstantiation
;
61
protected override bool ShouldEmitCell(DispatchCellNode cell) => cell.TargetMethod.
HasInstantiation
;
Compiler\DependencyAnalysis\EETypeNode.cs (7)
116
if (method.
HasInstantiation
)
146
if (!method.
HasInstantiation
)
303
if (!method.IsAbstract && !method.
HasInstantiation
)
374
if (decl.
HasInstantiation
)
452
if (interfaceMethod.
HasInstantiation
)
573
if (method.
HasInstantiation
)
978
Debug.Assert(!declMethod.
HasInstantiation
);
Compiler\DependencyAnalysis\ExactMethodInstantiationsEntryNode.cs (1)
21
Debug.Assert(method.
HasInstantiation
);
Compiler\DependencyAnalysis\GenericDictionaryNode.cs (1)
277
Debug.Assert(owningMethod.
HasInstantiation
);
Compiler\DependencyAnalysis\GenericLookupResult.cs (4)
705
Debug.Assert(method.
HasInstantiation
|| method.OwningType.IsInterface);
753
return _method.
HasInstantiation
? factory.NativeLayout.GvmCellDictionarySlot(_method) : factory.NativeLayout.InterfaceCellDictionarySlot(_method);
1065
Debug.Assert(!_constrainedMethod.
HasInstantiation
|| !_directCall, "Direct call to constrained generic method isn't supported");
1074
if (!canonMethod.
HasInstantiation
&& !factory.VTable(canonMethod.OwningType).HasKnownVirtualMethodUse)
Compiler\DependencyAnalysis\GenericMethodsHashtableNode.cs (2)
53
Debug.Assert(method.
HasInstantiation
&& !method.IsCanonicalMethod(CanonicalFormKind.Any));
100
Debug.Assert(method.
HasInstantiation
&& !method.IsCanonicalMethod(CanonicalFormKind.Any));
Compiler\DependencyAnalysis\GenericMethodsTemplateMap.cs (1)
87
if (!method.
HasInstantiation
)
Compiler\DependencyAnalysis\GenericVirtualMethodImplNode.cs (1)
23
Debug.Assert(method.
HasInstantiation
);
Compiler\DependencyAnalysis\GvmDispatchCellInfoSectionNode.cs (1)
38
if (!node.TargetMethod.
HasInstantiation
)
Compiler\DependencyAnalysis\ILScanNodeFactory.cs (1)
49
if (method.IsCanonicalMethod(CanonicalFormKind.Specific) && !method.
HasInstantiation
)
Compiler\DependencyAnalysis\InterfaceDispatchCellInfoSectionNode.cs (1)
38
if (node.TargetMethod.
HasInstantiation
)
Compiler\DependencyAnalysis\NativeLayoutVertexNode.cs (15)
121
if (method.
HasInstantiation
&& !method.IsMethodDefinition)
143
if (_method.
HasInstantiation
&& !_method.IsMethodDefinition)
169
if (_method.
HasInstantiation
&& !_method.IsMethodDefinition)
644
Debug.Assert(method.
HasInstantiation
);
711
Debug.Assert(owningMethod.
HasInstantiation
);
727
Debug.Assert(owningMethod.
HasInstantiation
);
809
Debug.Assert(method.
HasInstantiation
);
1288
Debug.Assert(method.
HasInstantiation
);
1331
Debug.Assert(method.
HasInstantiation
);
1438
if (_method.IsVirtual && _method.
HasInstantiation
&& !_method.IsGenericMethodDefinition && !_method.OwningType.IsGenericDefinition)
1466
Debug.Assert(!_constrainedMethod.
HasInstantiation
|| !directCall);
1480
return (_constrainedMethod.
HasInstantiation
, _constrainedMethod.Signature.IsStatic) switch
1492
if (_constrainedMethod.
HasInstantiation
)
1519
if (_constrainedMethod.IsVirtual && _constrainedMethod.
HasInstantiation
)
1529
if (_constrainedMethod.
HasInstantiation
)
Compiler\DependencyAnalysis\ReadyToRunGenericHelperNode.cs (2)
44
|| (dictionaryOwner is MethodDesc method && method.
HasInstantiation
));
92
directCall: !((ConstrainedCallInfo)target).Method.
HasInstantiation
);
Compiler\DependencyAnalysis\ReflectionInvokeMapNode.cs (3)
72
if (method.
HasInstantiation
)
148
if (method.
HasInstantiation
)
153
bool goesThroughInstantiatingUnboxingThunk = method.OwningType.IsValueType && !method.Signature.IsStatic && !method.
HasInstantiation
;
Compiler\DependencyAnalysis\ReflectionVirtualInvokeMapNode.cs (2)
91
if (method.
HasInstantiation
)
179
if (method.
HasInstantiation
)
Compiler\DependencyAnalysis\RuntimeMethodHandleNode.cs (2)
24
Debug.Assert((targetMethod.
HasInstantiation
&& targetMethod.IsMethodDefinition)
54
&& _targetMethod.
HasInstantiation
&& _targetMethod.IsVirtual)
Compiler\DependencyAnalysis\ScannedMethodNode.cs (1)
90
public override bool InterestingForDynamicDependencyAnalysis => _method.
HasInstantiation
|| _method.OwningType.HasInstantiation;
Compiler\DependencyAnalysis\TypeGVMEntriesNode.cs (2)
84
if (!decl.
HasInstantiation
)
105
if (!method.
HasInstantiation
)
Compiler\DependencyAnalysis\VariantInterfaceMethodUseNode.cs (1)
38
Debug.Assert(!decl.
HasInstantiation
);
Compiler\DependencyAnalysis\VTableSliceNode.cs (3)
41
if (method.
HasInstantiation
)
197
Debug.Assert(!virtualMethod.
HasInstantiation
);
231
if (method.
HasInstantiation
)
Compiler\ILAssemblyGeneratingMethodDebugInfoProvider.cs (1)
73
if (owningMethod.
HasInstantiation
)
Compiler\ILScanner.cs (1)
486
if (node is IMethodBodyNode { Method.IsVirtual: true, Method.
HasInstantiation
: false } virtualMethodBody)
Compiler\LazyGenericsPolicy.cs (1)
22
if (method.
HasInstantiation
)
Compiler\LibraryRootProvider.cs (1)
55
if (method.IsAbstract || method.
HasInstantiation
)
Compiler\MetadataManager.cs (1)
974
if (methodToGenerateMetadataFor.
HasInstantiation
)
Compiler\MethodBodyDeduplicator.cs (1)
26
if (!_genericsOnly || method.
HasInstantiation
|| method.OwningType.HasInstantiation)
Compiler\MultiFileCompilationModuleGroup.cs (2)
47
if (method.
HasInstantiation
)
117
return owningType.IsDefType && !owningType.HasInstantiation && !method.
HasInstantiation
;
Compiler\RootingHelpers.cs (1)
56
if (method.
HasInstantiation
)
Compiler\RootingServiceProvider.cs (1)
39
if (canonMethod != method && method.
HasInstantiation
)
Compiler\TypePreinit.cs (1)
632
if (firstParameter != null && pointedMethod.
HasInstantiation
)
Compiler\UsageBasedInteropStubManager.cs (2)
31
if (method.
HasInstantiation
)
57
Debug.Assert(method.
HasInstantiation
);
Compiler\UsageBasedMetadataManager.cs (1)
520
if (method.
HasInstantiation
)
IL\ILImporter.Scanner.cs (4)
334
if (method.
HasInstantiation
|| method.OwningType.HasInstantiation)
788
if (targetMethod.
HasInstantiation
)
862
if (targetOfLookup.
HasInstantiation
)
1005
else if (method.
HasInstantiation
)
parent\parent\Common\Compiler\CompilerTypeSystemContext.Async.cs (4)
184
if (asyncVariantMethod.
HasInstantiation
&& !asyncVariantMethod.IsMethodDefinition)
203
if (taskReturningMethod.
HasInstantiation
&& !taskReturningMethod.IsMethodDefinition)
223
if (returnDroppingThunk.
HasInstantiation
&& !returnDroppingThunk.IsMethodDefinition)
255
if (asyncVariantMethod.
HasInstantiation
&& !asyncVariantMethod.IsMethodDefinition)
parent\parent\Common\Compiler\CompilerTypeSystemContext.BoxedTypes.cs (5)
58
Debug.Assert(!targetMethod.
HasInstantiation
);
80
Debug.Assert(!thunk.
HasInstantiation
);
113
if (thunk.
HasInstantiation
)
364
if (method.
HasInstantiation
)
577
if (methodToInstantiate.
HasInstantiation
)
parent\parent\Common\Compiler\Dataflow\MethodProxy.cs (2)
49
internal partial bool HasGenericParameters() => Method.
HasInstantiation
;
57
if (!methodDef.
HasInstantiation
)
parent\parent\Common\Compiler\DependencyAnalysis\GVMDependenciesNode.cs (1)
33
Debug.Assert(method.
HasInstantiation
);
parent\parent\Common\Compiler\DependencyAnalysis\VirtualMethodUseNode.cs (1)
39
Debug.Assert(!decl.
HasInstantiation
);
parent\parent\Common\Compiler\DevirtualizationManager.cs (3)
113
if (impl != null && originalDeclMethod.
HasInstantiation
)
162
if (originalDeclMethod.
HasInstantiation
)
202
if (impl != null && originalDeclMethod.
HasInstantiation
)
parent\parent\Common\Compiler\DisplayNameHelpers.cs (1)
76
if (method.
HasInstantiation
)
parent\parent\Common\Compiler\ProcessLinkerXmlBase.cs (1)
537
if (includeGenericParameters && meth.
HasInstantiation
)
parent\parent\Common\Compiler\TypeExtensions.cs (4)
46
(method.
HasInstantiation
|| method.Signature.IsStatic || method.ImplementationType.IsValueType || (method.ImplementationType.IsInterface && !method.IsAbstract));
55
return method.
HasInstantiation
&& method.IsSharedByGenericInstantiations;
66
!method.
HasInstantiation
;
75
!method.
HasInstantiation
&&
parent\parent\Common\TypeSystem\IL\NativeAotILProvider.cs (1)
108
if (method.Name == "CreateInstance"u8 && method.Signature.Length == 0 && method.
HasInstantiation
parent\parent\Common\TypeSystem\IL\Stubs\AsyncThunks.cs (2)
83
if (asyncMethod.
HasInstantiation
)
263
if (asyncVariantTarget.
HasInstantiation
)
parent\parent\Common\TypeSystem\IL\Stubs\InterlockedIntrinsics.cs (1)
26
if (method.
HasInstantiation
&& method.Name == "CompareExchange"u8)
parent\parent\Common\TypeSystem\MetadataEmitter\TypeSystemMetadataEmitter.cs (1)
304
if (method.
HasInstantiation
&& (method.GetMethodDefinition() != method))
src\runtime\src\coreclr\tools\Common\Compiler\GenericCycleDetection\GraphBuilder.cs (1)
266
if (!method.
HasInstantiation
)
src\runtime\src\coreclr\tools\Common\Compiler\GenericCycleDetection\GraphBuilder.MethodCall.cs (1)
21
if (!target.
HasInstantiation
)
ILCompiler.MetadataTransform (1)
ILCompiler\Metadata\Transform.Method.cs (1)
65
if (entity.
HasInstantiation
)
ILCompiler.ReadyToRun (67)
Compiler\DependencyAnalysis\InheritedVirtualMethodsNode.cs (4)
57
if (decl.
HasInstantiation
)
99
if (interfaceMethod.
HasInstantiation
|| interfaceMethod.Signature.IsStatic)
163
if (method.
HasInstantiation
)
174
if (interfaceMethod.
HasInstantiation
&& !interfaceMethod.IsAbstract)
Compiler\DependencyAnalysis\ReadyToRun\CopiedMethodILNode.cs (1)
77
if (method.
HasInstantiation
|| method.OwningType.HasInstantiation)
Compiler\DependencyAnalysis\ReadyToRun\DelegateCtorSignature.cs (1)
45
bool needsInstantiatingStub = _targetMethod.Method.
HasInstantiation
;
Compiler\DependencyAnalysis\ReadyToRun\InstanceEntryPointTableNode.cs (1)
120
Debug.Assert(method.Method.
HasInstantiation
|| method.Method.OwningType.HasInstantiation || method.Method.IsAsyncVariant() ||
Compiler\DependencyAnalysis\ReadyToRun\MethodFixupSignature.cs (4)
60
!Method.
HasInstantiation
&&
80
Method.
HasInstantiation
&&
100
!Method.
HasInstantiation
&&
141
if (!_method.Method.
HasInstantiation
&& !_method.Method.OwningType.HasInstantiation && !_method.Method.OwningType.IsArray)
Compiler\DependencyAnalysis\ReadyToRun\SignatureBuilder.cs (1)
474
if (method.Method.
HasInstantiation
&& !method.Method.IsGenericMethodDefinition)
Compiler\DependencyAnalysis\ReadyToRun\TypeValidationChecker.cs (3)
284
if (method.
HasInstantiation
)
293
if (method.
HasInstantiation
)
305
if (method.
HasInstantiation
&& method.IsRuntimeImplemented)
Compiler\DependencyAnalysis\ReadyToRunCodegenNodeFactory.cs (3)
181
MethodDesc thunk = targetMethod.IsSharedByGenericInstantiations && !targetMethod.
HasInstantiation
191
MethodDesc thunk = targetMethod.IsSharedByGenericInstantiations && !targetMethod.
HasInstantiation
269
Debug.Assert(!method.
HasInstantiation
);
Compiler\DependencyAnalysis\ReadyToRunSymbolNodeFactory.cs (1)
138
isInstantiatingStub: ctorKey.Method.Method.
HasInstantiation
,
Compiler\ExternalReferenceTokenManager.cs (1)
125
if (methodDesc.
HasInstantiation
|| methodDesc.OwningType.HasInstantiation)
Compiler\ReadyToRunCompilationModuleGroupBase.cs (2)
149
if (!method.
HasInstantiation
&& !method.OwningType.HasInstantiation)
466
if (!(method.
HasInstantiation
|| method.OwningType.HasInstantiation))
Compiler\ReadyToRunLibraryRootProvider.cs (1)
55
if (method.
HasInstantiation
)
Compiler\ReadyToRunTableManager.cs (1)
88
if (method.
HasInstantiation
|| method.OwningType.HasInstantiation || method.IsAsyncVariant() || method is AsyncResumptionStub ||
Compiler\ReadyToRunVisibilityRootProvider.cs (1)
97
if (method.
HasInstantiation
)
Compiler\ReadyToRunXmlRootProvider.cs (1)
137
if (method.
HasInstantiation
)
JitInterface\CorInfoImpl.ReadyToRun.cs (4)
1957
if (originalMethod.
HasInstantiation
&& IsGenericTooDeeplyNested(originalMethod.Instantiation))
2095
if (targetMethod.
HasInstantiation
)
2349
else if (targetMethod.
HasInstantiation
||
2498
if (callerMethod.
HasInstantiation
|| callerMethod.OwningType.HasInstantiation)
parent\parent\Common\Compiler\CompilerTypeSystemContext.Async.cs (4)
184
if (asyncVariantMethod.
HasInstantiation
&& !asyncVariantMethod.IsMethodDefinition)
203
if (taskReturningMethod.
HasInstantiation
&& !taskReturningMethod.IsMethodDefinition)
223
if (returnDroppingThunk.
HasInstantiation
&& !returnDroppingThunk.IsMethodDefinition)
255
if (asyncVariantMethod.
HasInstantiation
&& !asyncVariantMethod.IsMethodDefinition)
parent\parent\Common\Compiler\CompilerTypeSystemContext.BoxedTypes.cs (5)
58
Debug.Assert(!targetMethod.
HasInstantiation
);
80
Debug.Assert(!thunk.
HasInstantiation
);
113
if (thunk.
HasInstantiation
)
364
if (method.
HasInstantiation
)
577
if (methodToInstantiate.
HasInstantiation
)
parent\parent\Common\Compiler\Dataflow\MethodProxy.cs (2)
49
internal partial bool HasGenericParameters() => Method.
HasInstantiation
;
57
if (!methodDef.
HasInstantiation
)
parent\parent\Common\Compiler\DependencyAnalysis\GVMDependenciesNode.cs (1)
33
Debug.Assert(method.
HasInstantiation
);
parent\parent\Common\Compiler\DependencyAnalysis\VirtualMethodUseNode.cs (1)
39
Debug.Assert(!decl.
HasInstantiation
);
parent\parent\Common\Compiler\DevirtualizationManager.cs (3)
113
if (impl != null && originalDeclMethod.
HasInstantiation
)
162
if (originalDeclMethod.
HasInstantiation
)
202
if (impl != null && originalDeclMethod.
HasInstantiation
)
parent\parent\Common\Compiler\DisplayNameHelpers.cs (1)
76
if (method.
HasInstantiation
)
parent\parent\Common\Compiler\ProcessLinkerXmlBase.cs (1)
537
if (includeGenericParameters && meth.
HasInstantiation
)
parent\parent\Common\Compiler\TypeExtensions.cs (4)
46
(method.
HasInstantiation
|| method.Signature.IsStatic || method.ImplementationType.IsValueType || (method.ImplementationType.IsInterface && !method.IsAbstract));
55
return method.
HasInstantiation
&& method.IsSharedByGenericInstantiations;
66
!method.
HasInstantiation
;
75
!method.
HasInstantiation
&&
parent\parent\Common\JitInterface\CorInfoImpl.cs (8)
1099
return MethodBeingCompiled.
HasInstantiation
? (TypeSystemEntity)MethodBeingCompiled: (TypeSystemEntity)MethodBeingCompiled.OwningType;
1342
if (method.
HasInstantiation
)
1586
bool contextIsMethod = isArray || decl.
HasInstantiation
;
1916
Debug.Assert((methodContext.
HasInstantiation
&& !owningMethod.
HasInstantiation
) ||
1917
(!methodContext.
HasInstantiation
&& !owningMethod.
HasInstantiation
) ||
4885
if (!isFallbackBodyCompilation && (this.MethodBeingCompiled.
HasInstantiation
|| this.MethodBeingCompiled.OwningType.HasInstantiation)) // No generics involved
parent\parent\Common\TypeSystem\IL\Stubs\AsyncThunks.cs (2)
83
if (asyncMethod.
HasInstantiation
)
263
if (asyncVariantTarget.
HasInstantiation
)
parent\parent\Common\TypeSystem\IL\Stubs\InterlockedIntrinsics.cs (1)
26
if (method.
HasInstantiation
&& method.Name == "CompareExchange"u8)
parent\parent\Common\TypeSystem\MetadataEmitter\TypeSystemMetadataEmitter.cs (1)
304
if (method.
HasInstantiation
&& (method.GetMethodDefinition() != method))
PortableCallHelpers\InternalCallSignatureCollector.cs (1)
75
if (method.
HasInstantiation
|| method.OwningType.HasInstantiation)
src\runtime\src\coreclr\tools\Common\Compiler\GenericCycleDetection\GraphBuilder.cs (1)
266
if (!method.
HasInstantiation
)
src\runtime\src\coreclr\tools\Common\Compiler\GenericCycleDetection\GraphBuilder.MethodCall.cs (1)
21
if (!target.
HasInstantiation
)
ILCompiler.RyuJit (16)
Compiler\DependencyAnalysis\MethodCodeNode.cs (1)
58
public override bool InterestingForDynamicDependencyAnalysis => _method.
HasInstantiation
|| _method.OwningType.HasInstantiation;
Compiler\DependencyAnalysis\RyuJitNodeFactory.cs (1)
57
if (method.IsCanonicalMethod(CanonicalFormKind.Specific) && !method.
HasInstantiation
)
JitInterface\CorInfoImpl.RyuJit.cs (6)
437
if (targetOfLookup.
HasInstantiation
)
1181
if (method.
HasInstantiation
|| method.OwningType.HasInstantiation)
1298
if (targetMethod.
HasInstantiation
)
1315
!MethodBeingCompiled.
HasInstantiation
)
1414
if (lookupMethod.
HasInstantiation
)
1590
else if (targetMethod.
HasInstantiation
)
parent\parent\Common\JitInterface\CorInfoImpl.cs (8)
1099
return MethodBeingCompiled.
HasInstantiation
? (TypeSystemEntity)MethodBeingCompiled: (TypeSystemEntity)MethodBeingCompiled.OwningType;
1342
if (method.
HasInstantiation
)
1588
bool contextIsMethod = decl.
HasInstantiation
;
1916
Debug.Assert((methodContext.
HasInstantiation
&& !owningMethod.
HasInstantiation
) ||
1917
(!methodContext.
HasInstantiation
&& !owningMethod.
HasInstantiation
) ||
4885
if (!isFallbackBodyCompilation && (this.MethodBeingCompiled.
HasInstantiation
|| this.MethodBeingCompiled.OwningType.HasInstantiation)) // No generics involved
ILCompiler.TypeSystem (12)
parent\parent\Common\TypeSystem\Common\ConstructedTypeRewritingHelpers.cs (1)
169
if (!method.
HasInstantiation
)
parent\parent\Common\TypeSystem\Common\MethodDesc.cs (1)
754
return
HasInstantiation
&& IsMethodDefinition;
parent\parent\Common\TypeSystem\Common\TypeSystemConstraintsHelpers.cs (1)
214
if (!method.
HasInstantiation
)
parent\parent\Common\TypeSystem\Common\TypeSystemHelpers.cs (2)
132
if (!method.
HasInstantiation
&& !method.OwningType.HasInstantiation)
273
Debug.Assert(method.IsMethodDefinition && !method.
HasInstantiation
);
parent\parent\Common\TypeSystem\Common\Utilities\CSharpTypeNameFormatter.cs (1)
23
if (method.
HasInstantiation
)
parent\parent\Common\TypeSystem\IL\ILDisassembler.cs (1)
92
if (method.
HasInstantiation
)
parent\parent\Common\TypeSystem\IL\InstantiatedMethodIL.cs (1)
20
Debug.Assert(owningMethod.
HasInstantiation
|| owningMethod.OwningType.HasInstantiation);
parent\parent\Common\TypeSystem\IL\MethodILDebugView.cs (1)
38
if (owningMethod.
HasInstantiation
)
parent\parent\Common\TypeSystem\IL\UnsafeAccessors.cs (2)
407
if (targetMethod.
HasInstantiation
)
478
if (targetMaybe.
HasInstantiation
)
parent\parent\Common\TypeSystem\RuntimeDetermined\MethodDesc.RuntimeDetermined.cs (1)
28
if (result.
HasInstantiation
)