1 write to _compilation
ILCompiler.RyuJit (1)
JitInterface\CorInfoImpl.RyuJit.cs (1)
46
_compilation
= compilation;
193 references to _compilation
ILCompiler.RyuJit (193)
JitInterface\CorInfoImpl.RyuJit.cs (113)
59
MethodDesc asyncResumptionStub =
_compilation
.TypeSystemContext.GetAsyncResumptionStub(MethodBeingCompiled,
_compilation
.TypeSystemContext.GeneratedAssembly.GetGlobalModuleType());
61
entryPoint = (void*)ObjectToHandle(
_compilation
.NodeFactory.MethodEntrypoint(asyncResumptionStub));
70
methodIL ??=
_compilation
.GetMethodIL(MethodBeingCompiled);
282
if (
_compilation
.NeedsRuntimeLookup(helperId, entity))
284
GenericDictionaryLookup genericLookup =
_compilation
.ComputeGenericLookup(callerHandle, helperId, entity);
338
ISymbolNode constLookup =
_compilation
.ComputeConstantLookup(helperId, entity);
361
pLookup = CreateConstLookupToSymbol(
_compilation
.NodeFactory.ReadyToRunHelper(helperId, type));
431
targetOfLookup =
_compilation
.TypeSystemContext.GetMethodForRuntimeDeterminedType(directMethod.GetTypicalMethodDefinition(), (RuntimeDeterminedType)constrainedType);
433
targetOfLookup =
_compilation
.TypeSystemContext.GetMethodForInstantiatedType(directMethod.GetTypicalMethodDefinition(), (InstantiatedType)constrainedType);
457
DelegateCreationInfo delegateInfo =
_compilation
.GetDelegateCtor(delegateTypeDesc, targetMethod, constrainedType, isLdvirtftn);
480
pLookup.constLookup = CreateConstLookupToSymbol(
_compilation
.NodeFactory.ReadyToRunHelper(ReadyToRunHelperId.DelegateCtor, delegateInfo));
631
return
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewFast"u8));
633
return
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewFinalizable"u8));
635
return
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewFastAlign8"u8));
637
return
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewFinalizableAlign8"u8));
639
return
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewFastMisalign"u8));
644
return
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewPtrArrayFast"u8));
646
return
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewArrayFastAlign8"u8));
648
return
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewArrayFast"u8));
651
return
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpStackProbe"u8));
654
return
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpGcPoll"u8));
789
return
_compilation
.NodeFactory.MethodEntrypoint(
_compilation
.NodeFactory.TypeSystemContext.GetCoreLibEntryPoint("System"u8, "Type"u8, "GetTypeFromMethodTable"u8, null));
791
return
_compilation
.NodeFactory.MethodEntrypoint(
_compilation
.NodeFactory.TypeSystemContext.GetCoreLibEntryPoint("Internal.Runtime.CompilerHelpers"u8, "SharedCodeHelpers"u8, "GetClassHandleFromMethodParam"u8, null));
797
if ((
_compilation
._compilationOptions & RyuJitCompilationOptions.ControlFlowGuardAnnotations) != 0
799
&&
_compilation
.NodeFactory.TypeSystemContext.Target.Architecture != TargetArchitecture.X86)
800
return
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpInterfaceDispatchGuarded"u8));
801
return
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpInterfaceDispatch"u8));
803
return
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpResolveInterfaceMethodFast"u8));
814
return
_compilation
.NodeFactory.ExternIndirectFunctionSymbol(new Utf8String("__guard_check_icall_fptr"u8));
816
return
_compilation
.NodeFactory.ExternIndirectFunctionSymbol(new Utf8String("__guard_dispatch_icall_fptr"u8));
824
JitHelper.GetEntryPoint(
_compilation
.TypeSystemContext, id, out mangledName, out methodDesc);
829
entryPoint =
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String(mangledName));
831
entryPoint =
_compilation
.NodeFactory.MethodEntrypoint(methodDesc);
848
pResult = CreateConstLookupToSymbol(
_compilation
.NodeFactory.MethodEntrypoint(method));
858
stringObject =
_compilation
.NodeFactory.SerializedStringObject("");
863
stringObject =
_compilation
.NodeFactory.SerializedStringObject((string)literal);
953
var typeSymbol =
_compilation
.NecessaryTypeSymbolIfPossible(type);
955
RelocType rel = (
_compilation
.NodeFactory.Target.IsWindows) ?
1058
_debugInfo =
_compilation
.GetDebugInfo(methodIL);
1066
return
_compilation
.NodeFactory.ReadyToRunHelperFromTypeLookup(helperId, helperArgument, callerHandle.OwningType);
1070
return
_compilation
.NodeFactory.ReadyToRunHelperFromDictionaryLookup(helperId, helperArgument, callerHandle);
1090
||
_compilation
.TypeSystemContext.IsGenericArrayInterfaceType(type))
1164
if (elementType.GetElementSize().AsInt ==
_compilation
.TypeSystemContext.Target.PointerSize)
1184
_compilation
.DetectGenericCycles(methodIL.OwningMethod, method);
1187
return
_compilation
.NodeFactory.MethodEntrypointOrTentativeMethod(method, isUnboxingThunk);
1274
_compilation
.NodeFactory.MetadataManager.NoteOverridingMethod(method, directMethod);
1362
canDevirt =
_compilation
.IsEffectivelySealed(targetMethod);
1409
lookupMethod =
_compilation
.TypeSystemContext.GetMethodForRuntimeDeterminedType(targetMethod.GetTypicalMethodDefinition(), (RuntimeDeterminedType)runtimeDeterminedConstrainedType);
1411
lookupMethod =
_compilation
.TypeSystemContext.GetMethodForInstantiatedType(targetMethod.GetTypicalMethodDefinition(), (InstantiatedType)runtimeDeterminedConstrainedType);
1471
CreateConstLookupToSymbol(
_compilation
.NodeFactory.FatFunctionPointer(targetMethod));
1484
targetMethod =
_compilation
.ExpandIntrinsicForCallsite(targetMethod, methodIL.OwningMethod);
1499
_compilation
.NodeFactory.StringAllocator(targetMethod)
1535
instParam =
_compilation
.NodeFactory.MethodGenericDictionary(concreteMethod);
1540
instParam =
_compilation
.NodeFactory.ConstructedTypeSymbol(concreteMethod.OwningType);
1577
if (!
_compilation
.NeedsRuntimeLookup(constrainedHelperId, constrainedCallInfo))
1597
MethodDesc targetOfLookup =
_compilation
.GetTargetOfGenericVirtualMethodCall((MethodDesc)GetRuntimeDeterminedObjectForToken(ref pResolvedToken));
1599
_compilation
.DetectGenericCycles(
1619
_compilation
.NodeFactory.DispatchCell(targetOfLookup
1652
_compilation
.NodeFactory.DispatchCell(targetMethod
1681
pResult->codePointerOrStubLookup.constLookup = CreateConstLookupToSymbol(
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("NYI_LDVIRTFTN"u8)));
1695
_compilation
.NodeFactory.ReadyToRunHelper(ReadyToRunHelperId.ResolveVirtualFunction, slotDefiningMethod));
1725
ISymbolNode typeHandleSymbol =
_compilation
.NecessaryTypeSymbolIfPossible(type);
1831
DictionaryLayoutNode contextLayout =
_compilation
.NodeFactory.GenericDictionaryLayout(
1840
helperId =
_compilation
.GetLdTokenHelperForType(td);
1857
RuntimeMethodHandleNode methodHandleSymbol =
_compilation
.NodeFactory.RuntimeMethodHandle(method);
1875
int pointerSize =
_compilation
.TypeSystemContext.Target.PointerSize;
1881
Debug.Assert(!methodDesc.CanMethodBeInSealedVTable(
_compilation
.NodeFactory));
1888
int slot = VirtualMethodSlotHelper.GetVirtualMethodSlot(
_compilation
.NodeFactory, methodDesc, owningType);
1894
if (
_compilation
.NeedsSlotUseTracking(owningType))
1895
(_additionalDependencies ??= new ILCompiler.DependencyAnalysisFramework.DependencyNodeCore<NodeFactory>.DependencyList()).Add(
_compilation
.NodeFactory.VirtualMethodUse(methodDesc), "Virtual method call");
1948
Utf8String externName = new Utf8String(
_compilation
.PInvokeILProvider.GetDirectCallExternName(md));
1949
externName =
_compilation
.NodeFactory.NameMangler.NodeMangler.ExternMethod(externName, md);
1951
pLookup = CreateConstLookupToSymbol(
_compilation
.NodeFactory.ExternFunctionSymbol(externName));
1958
*ppCookieVal = (IntPtr*)ObjectToHandle(
_compilation
.NodeFactory.ExternVariable(new Utf8String("__security_cookie"u8)));
1991
if (
_compilation
.HasLazyStaticConstructor(owningType) && !((MetadataType)owningType).IsBeforeFieldInit)
2011
MethodDesc stub =
_compilation
.PInvokeILProvider.GetCalliStub(
2024
if (
_compilation
.GetMethodIL(method) is Internal.IL.Stubs.PInvokeILStubMethodIL stub)
2048
if (
_compilation
.TypeSystemContext.Target.Architecture == TargetArchitecture.ARM)
2094
return (int*)ObjectToHandle(
_compilation
.NodeFactory.ExternVariable(new Utf8String("RhpTrapThreads"u8)));
2118
fieldOffset +=
_compilation
.NodeFactory.ThreadStaticBaseOffset(mt);
2132
ISymbolNode node =
_compilation
.GetFieldRvaData(field);
2137
if (
_compilation
.HasLazyStaticConstructor(field.OwningType))
2172
helper =
_compilation
.NodeFactory.ReadyToRunHelperFromTypeLookup(
2178
helper =
_compilation
.NodeFactory.ReadyToRunHelperFromDictionaryLookup(
2204
ISortableSymbolNode index =
_compilation
.NodeFactory.TypeThreadStaticIndex(field.OwningType);
2210
if (
_compilation
.HasLazyStaticConstructor(field.OwningType))
2228
baseAddr =
_compilation
.NodeFactory.TypeGCStaticsSymbol(field.OwningType);
2233
baseAddr =
_compilation
.NodeFactory.TypeNonGCStaticsSymbol(field.OwningType);
2237
if (
_compilation
.HasLazyStaticConstructor(field.OwningType))
2246
_compilation
.NodeFactory.ReadyToRunHelper(helperId, field.OwningType));
2255
if (
_compilation
.IsInitOnly(field))
2279
if (
_compilation
.TypeSystemContext.IsArrayVariantCastable(type))
2286
return !
_compilation
.CanReferenceConstructedTypeOrCanonicalFormOfType(type)
2287
&& (type == canonType || !
_compilation
.CanReferenceConstructedMethodTable(canonType));
2309
if (
_compilation
.IsEffectivelySealed(type))
2315
TypeDesc[] implClasses =
_compilation
.GetImplementingClasses(type);
2343
if (!field.IsThreadStatic &&
_compilation
.IsInitOnly(field) && field.OwningType is MetadataType owningType)
2350
PreinitializationManager preinitManager =
_compilation
.NodeFactory.PreinitializationManager;
2356
int targetPtrSize =
_compilation
.TypeSystemContext.Target.PointerSize;
2372
if (value.GetRawData(
_compilation
.NodeFactory, out object data))
2421
int strDataOffset =
_compilation
.TypeSystemContext.Target.PointerSize + sizeof(int); // 12 on 64bit
2448
return ObjectToHandle(
_compilation
.NecessaryRuntimeTypeIfPossible(type));
2474
addr.addr = (void*)ObjectToHandle(
_compilation
.NodeFactory.TypeNonGCStaticsSymbol(type));
2476
offset = -NonGCStaticsNode.GetClassConstructorContextSize(
_compilation
.NodeFactory.Target);
2486
addr.addr = (void*)ObjectToHandle(
_compilation
.NodeFactory.TypeGCStaticsSymbol(type));
2491
addr.addr = (void*)ObjectToHandle(
_compilation
.NodeFactory.TypeNonGCStaticsSymbol(type));
2499
pInfo->tlsIndexObject = CreateConstLookupToSymbol(
_compilation
.NodeFactory.ExternDataSymbol(new Utf8String("_tls_index"u8)));
2500
pInfo->tlsRootObject = CreateConstLookupToSymbol(
_compilation
.NodeFactory.TlsRoot);
2501
pInfo->threadStaticBaseSlow = CreateConstLookupToSymbol(
_compilation
.NodeFactory.HelperEntrypoint(HelperEntrypoint.GetInlinedThreadStaticBaseSlow));
2502
pInfo->tlsGetAddrFtnPtr = CreateConstLookupToSymbol(
_compilation
.NodeFactory.ExternFunctionSymbol(new Utf8String("__tls_get_addr"u8)));
parent\parent\Common\JitInterface\CorInfoImpl.cs (80)
188
get => field ??=
_compilation
.TypeSystemContext.SystemModule.GetType(
208
return
_compilation
.Logger;
431
if (
_compilation
.TypeSystemContext.Target.Architecture != TargetArchitecture.ARM64
432
&&
_compilation
.TypeSystemContext.Target.Architecture != TargetArchitecture.LoongArch64
433
&&
_compilation
.TypeSystemContext.Target.Architecture != TargetArchitecture.RiscV64)
473
_compilation
.NodeFactory.Target.MinimumFunctionAlignment :
474
_compilation
.NodeFactory.Target.OptimumFunctionAlignment;
602
CodeBasedDependencyAlgorithm.AddDependenciesDueToMethodCodePresence(ref _additionalDependencies,
_compilation
.NodeFactory, MethodBeingCompiled, methodIL);
662
return
_compilation
.TypeSystemContext.Target.PointerSize;
1022
if (
_compilation
.TypeSystemContext.Target.Architecture == TargetArchitecture.X86)
1162
if (
_compilation
.IsEffectivelySealed(method.GetUnboxedMethod()))
1167
if (
_compilation
.IsEffectivelySealed(method))
1315
method =
_compilation
.TypeSystemContext.GetMethodForInstantiatedType(method.GetTypicalMethodDefinition(), (InstantiatedType)type);
1341
MethodDesc instantiatedMethod =
_compilation
.TypeSystemContext.GetMethodForInstantiatedType(method.GetTypicalMethodDefinition(), instantiatedCtxType);
1344
instantiatedMethod =
_compilation
.TypeSystemContext.GetInstantiatedMethod(instantiatedMethod, method.Instantiation);
1353
if (!
_compilation
.CanInline(MethodBeingCompiled, method))
1357
MethodIL methodIL = method.IsUnboxingThunk() ? null :
_compilation
.GetMethodIL(method);
1396
var calleeIL =
_compilation
.GetMethodIL(calleeMethod);
1405
if (
_compilation
.CanInline(callerMethod, calleeMethod))
1429
var methodIL =
_compilation
.GetMethodIL(HandleToObject(ftn));
1475
decl =
_compilation
.TypeSystemContext.GetMethodForInstantiatedType(decl.GetTypicalMethodDefinition(), (InstantiatedType)ownerTypeDesc);
1479
MethodDesc originalImpl =
_compilation
.ResolveVirtualMethod(decl, objType, out info->detail);
1649
info->instParamLookup.constLookup = CreateConstLookupToSymbol(
_compilation
.NodeFactory.ConstructedTypeSymbol(originalImpl.OwningType));
1688
MethodILScope scope = jitInterface.
_compilation
.GetMethodIL(methodWithToken.Method);
1748
MetadataType placeholderType =
_compilation
.TypeSystemContext.SystemModule.GetType("System"u8, "SZGenericArrayEnumerator`1"u8, throwIfNotFound: false);
1952
result =
_compilation
.TypeSystemContext.GetAsyncVariantMethod((MethodDesc)result);
2027
_compilation
.TypeSystemContext.EnsureLoadableMethod(method);
2040
_compilation
.NodeFactory.MetadataManager.GetDependenciesDueToAccess(ref _additionalDependencies,
_compilation
.NodeFactory, (MethodIL)methodIL, method);
2046
?
_compilation
.TypeSystemContext.GetAsyncVariantMethod(method)
2077
_compilation
.TypeSystemContext.EnsureLoadableType(owningClass);
2081
_compilation
.NodeFactory.MetadataManager.GetDependenciesDueToAccess(ref _additionalDependencies,
_compilation
.NodeFactory, (MethodIL)methodIL, field);
2108
_compilation
.TypeSystemContext.EnsureLoadableType(type);
2147
if (
_compilation
.IsFatPointerCandidate(methodIL.OwningMethod, methodSig))
2176
return ObjectToHandle(
_compilation
.TypeSystemContext.GetWellKnownType(result));
2344
if (
_compilation
.IsEffectivelySealed(type))
2921
!
_compilation
.HasLazyStaticConstructor(type)
3021
return ObjectToHandle(
_compilation
.TypeSystemContext.GetWellKnownType(WellKnownType.Object));
3024
return ObjectToHandle(
_compilation
.TypeSystemContext.GetWellKnownType(WellKnownType.TypedReference));
3027
return ObjectToHandle(
_compilation
.TypeSystemContext.GetWellKnownType(WellKnownType.RuntimeTypeHandle));
3030
return ObjectToHandle(
_compilation
.TypeSystemContext.GetWellKnownType(WellKnownType.RuntimeFieldHandle));
3033
return ObjectToHandle(
_compilation
.TypeSystemContext.GetWellKnownType(WellKnownType.RuntimeMethodHandle));
3036
ThrowHelper.ThrowTypeLoadException("System", "RuntimeArgumentHandle",
_compilation
.TypeSystemContext.SystemModule);
3040
return ObjectToHandle(
_compilation
.TypeSystemContext.GetWellKnownType(WellKnownType.String));
3043
return ObjectToHandle(
_compilation
.TypeSystemContext.SystemModule.GetKnownType("System"u8, "RuntimeType"u8));
3046
return ObjectToHandle(
_compilation
.TypeSystemContext.SystemModule.GetKnownType("System.Numerics"u8, "Vector`1"u8));
3241
return
_compilation
.IsEffectivelySealed(type);
3355
return (void*)ObjectToHandle(
_compilation
.GetFieldRvaData(fd));
3637
if (
_compilation
.NodeFactory.Target.IsWasm)
3642
else if (
_compilation
.NodeFactory.Target.IsWindows)
3652
pEEInfoOut.osType = TargetToOs(
_compilation
.NodeFactory.Target);
3657
DefType continuation =
_compilation
.TypeSystemContext.ContinuationType;
3663
DefType asyncHelpers =
_compilation
.TypeSystemContext.SystemModule.GetKnownType("System.Runtime.CompilerServices"u8, "AsyncHelpers"u8);
3679
NodeFactory factory =
_compilation
.NodeFactory;
3690
WasmTypeNode typeNode =
_compilation
.NodeFactory.WasmTypeNode(typeArray);
3707
CompilerTypeSystemContext context =
_compilation
.TypeSystemContext;
3788
CompilerTypeSystemContext context =
_compilation
.TypeSystemContext;
3857
return ObjectToHandle(
_compilation
.TypeSystemContext.GetContinuationType(gcMapBuilder.ToGCMap()));
4007
HandleToObject(structHnd),
_compilation
.TypeSystemContext.Target.Architecture);
4291
=> (chunk.flags & CorJitAllocMemFlag.CORJIT_ALLOCMEM_HAS_POINTERS_TO_CODE) != 0 && !
_compilation
.TypeSystemContext.Target.IsWindows;
4430
var target =
_compilation
.TypeSystemContext.Target;
4736
switch (
_compilation
.TypeSystemContext.Target.Architecture)
4755
return (uint)node.GetAlignment(
_compilation
.NodeFactory);
4764
TargetArchitecture arch =
_compilation
.TypeSystemContext.Target.Architecture;
4831
return owningMetadataType.Module ==
_compilation
.TypeSystemContext.SystemModule;
4840
flags.InstructionSetFlags.Add(
_compilation
.InstructionSetSupport.OptimisticFlags);
4850
TargetArchitecture targetArchitecture =
_compilation
.TypeSystemContext.Target.Architecture;
4857
Debug.Assert(
_compilation
.InstructionSetSupport.IsInstructionSetSupported(InstructionSet.X86_X86Base));
4861
Debug.Assert(
_compilation
.InstructionSetSupport.IsInstructionSetSupported(InstructionSet.ARM64_AdvSimd));
4865
if (targetArchitecture == TargetArchitecture.ARM && !
_compilation
.TypeSystemContext.Target.IsWindows)
4920
|| (
_compilation
.TypeSystemContext.IsSpecialUnboxingThunk(this.MethodBeingCompiled) &&
_compilation
.TypeSystemContext.GetTargetOfSpecialUnboxingThunk(this.MethodBeingCompiled).IsAsyncCall())
4921
|| (
_compilation
.TypeSystemContext.IsDefaultInterfaceMethodImplementationInstantiationThunk(this.MethodBeingCompiled) &&
_compilation
.TypeSystemContext.GetTargetOfDefaultInterfaceMethodImplementationInstantiationThunk(this.MethodBeingCompiled).IsAsyncCall())
5029
PgoSchemaElem[] pgoResultsSchemas =
_compilation
.ProfileData[methodDesc]?.SchemaData;
5040
,
_compilation
.CanReferenceConstructedMethodTable
5135
instructionSet = InstructionSetFlags.ConvertToImpliedInstructionSetForVectorInstructionSets(
_compilation
.TypeSystemContext.Target.Architecture, instructionSet);
5137
Debug.Assert(!
_compilation
.InstructionSetSupport.NonSpecifiableFlags.HasInstructionSet(instructionSet));
5139
return supportEnabled ?
_compilation
.InstructionSetSupport.IsInstructionSetSupported(instructionSet) : false;