1 write to _compilation
ILCompiler.RyuJit (1)
JitInterface\CorInfoImpl.RyuJit.cs (1)
46_compilation = compilation;
194 references to _compilation
ILCompiler.RyuJit (194)
JitInterface\CorInfoImpl.RyuJit.cs (115)
59MethodDesc asyncResumptionStub = _compilation.TypeSystemContext.GetAsyncResumptionStub(MethodBeingCompiled, _compilation.TypeSystemContext.GeneratedAssembly.GetGlobalModuleType()); 61entryPoint = (void*)ObjectToHandle(_compilation.NodeFactory.MethodEntrypoint(asyncResumptionStub)); 70methodIL ??= _compilation.GetMethodIL(MethodBeingCompiled); 89IEETypeNode expectedeetype = _compilation.NecessaryTypeSymbolIfPossible(eetype.Type); 282if (_compilation.NeedsRuntimeLookup(helperId, entity)) 284GenericDictionaryLookup genericLookup = _compilation.ComputeGenericLookup(callerHandle, helperId, entity); 338ISymbolNode constLookup = _compilation.ComputeConstantLookup(helperId, entity); 361pLookup = CreateConstLookupToSymbol(_compilation.NodeFactory.ReadyToRunHelper(helperId, type)); 431targetOfLookup = _compilation.TypeSystemContext.GetMethodForRuntimeDeterminedType(directMethod.GetTypicalMethodDefinition(), (RuntimeDeterminedType)constrainedType); 433targetOfLookup = _compilation.TypeSystemContext.GetMethodForInstantiatedType(directMethod.GetTypicalMethodDefinition(), (InstantiatedType)constrainedType); 457DelegateCreationInfo delegateInfo = _compilation.GetDelegateCtor(delegateTypeDesc, targetMethod, constrainedType, isLdvirtftn); 480pLookup.constLookup = CreateConstLookupToSymbol(_compilation.NodeFactory.ReadyToRunHelper(ReadyToRunHelperId.DelegateCtor, delegateInfo)); 631return _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewFast"u8)); 633return _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewFinalizable"u8)); 635return _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewFastAlign8"u8)); 637return _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewFinalizableAlign8"u8)); 639return _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewFastMisalign"u8)); 644return _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewPtrArrayFast"u8)); 646return _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewArrayFastAlign8"u8)); 648return _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpNewArrayFast"u8)); 651return _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpStackProbe"u8)); 654return _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpGcPoll"u8)); 789return _compilation.NodeFactory.MethodEntrypoint(_compilation.NodeFactory.TypeSystemContext.GetCoreLibEntryPoint("System"u8, "Type"u8, "GetTypeFromMethodTable"u8, null)); 791return _compilation.NodeFactory.MethodEntrypoint(_compilation.NodeFactory.TypeSystemContext.GetCoreLibEntryPoint("Internal.Runtime.CompilerHelpers"u8, "SharedCodeHelpers"u8, "GetClassHandleFromMethodParam"u8, null)); 797if ((_compilation._compilationOptions & RyuJitCompilationOptions.ControlFlowGuardAnnotations) != 0 799&& _compilation.NodeFactory.TypeSystemContext.Target.Architecture != TargetArchitecture.X86) 800return _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpInterfaceDispatchGuarded"u8)); 801return _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpInterfaceDispatch"u8)); 803return _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("RhpResolveInterfaceMethodFast"u8)); 820return _compilation.NodeFactory.ExternIndirectFunctionSymbol(new Utf8String("__guard_check_icall_fptr"u8)); 822return _compilation.NodeFactory.ExternIndirectFunctionSymbol(new Utf8String("__guard_dispatch_icall_fptr"u8)); 830JitHelper.GetEntryPoint(_compilation.TypeSystemContext, id, out mangledName, out methodDesc); 835entryPoint = _compilation.NodeFactory.ExternFunctionSymbol(new Utf8String(mangledName)); 837entryPoint = _compilation.NodeFactory.MethodEntrypoint(methodDesc); 854pResult = CreateConstLookupToSymbol(_compilation.NodeFactory.MethodEntrypoint(method)); 864stringObject = _compilation.NodeFactory.SerializedStringObject(""); 869stringObject = _compilation.NodeFactory.SerializedStringObject((string)literal); 959var typeSymbol = _compilation.NecessaryTypeSymbolIfPossible(type); 961RelocType rel = (_compilation.NodeFactory.Target.IsWindows) ? 1064_debugInfo = _compilation.GetDebugInfo(methodIL); 1072return _compilation.NodeFactory.ReadyToRunHelperFromTypeLookup(helperId, helperArgument, callerHandle.OwningType); 1076return _compilation.NodeFactory.ReadyToRunHelperFromDictionaryLookup(helperId, helperArgument, callerHandle); 1096|| _compilation.TypeSystemContext.IsGenericArrayInterfaceType(type)) 1170if (elementType.GetElementSize().AsInt == _compilation.TypeSystemContext.Target.PointerSize) 1190_compilation.DetectGenericCycles(methodIL.OwningMethod, method); 1193return _compilation.NodeFactory.MethodEntrypointOrTentativeMethod(method, isUnboxingThunk); 1280_compilation.NodeFactory.MetadataManager.NoteOverridingMethod(method, directMethod); 1368canDevirt = _compilation.IsEffectivelySealed(targetMethod); 1415lookupMethod = _compilation.TypeSystemContext.GetMethodForRuntimeDeterminedType(targetMethod.GetTypicalMethodDefinition(), (RuntimeDeterminedType)runtimeDeterminedConstrainedType); 1417lookupMethod = _compilation.TypeSystemContext.GetMethodForInstantiatedType(targetMethod.GetTypicalMethodDefinition(), (InstantiatedType)runtimeDeterminedConstrainedType); 1477CreateConstLookupToSymbol(_compilation.NodeFactory.FatFunctionPointer(targetMethod)); 1490targetMethod = _compilation.ExpandIntrinsicForCallsite(targetMethod, methodIL.OwningMethod); 1505_compilation.NodeFactory.StringAllocator(targetMethod) 1541instParam = _compilation.NodeFactory.MethodGenericDictionary(concreteMethod); 1546instParam = _compilation.NodeFactory.ConstructedTypeSymbol(concreteMethod.OwningType); 1583if (!_compilation.NeedsRuntimeLookup(constrainedHelperId, constrainedCallInfo)) 1603MethodDesc targetOfLookup = _compilation.GetTargetOfGenericVirtualMethodCall((MethodDesc)GetRuntimeDeterminedObjectForToken(ref pResolvedToken)); 1605_compilation.DetectGenericCycles( 1625_compilation.NodeFactory.DispatchCell(targetOfLookup 1658_compilation.NodeFactory.DispatchCell(targetMethod 1687pResult->codePointerOrStubLookup.constLookup = CreateConstLookupToSymbol(_compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("NYI_LDVIRTFTN"u8))); 1701_compilation.NodeFactory.ReadyToRunHelper(ReadyToRunHelperId.ResolveVirtualFunction, slotDefiningMethod)); 1731ISymbolNode typeHandleSymbol = _compilation.NecessaryTypeSymbolIfPossible(type); 1837DictionaryLayoutNode contextLayout = _compilation.NodeFactory.GenericDictionaryLayout( 1846helperId = _compilation.GetLdTokenHelperForType(td); 1863RuntimeMethodHandleNode methodHandleSymbol = _compilation.NodeFactory.RuntimeMethodHandle(method); 1881int pointerSize = _compilation.TypeSystemContext.Target.PointerSize; 1887Debug.Assert(!methodDesc.CanMethodBeInSealedVTable(_compilation.NodeFactory)); 1894int slot = VirtualMethodSlotHelper.GetVirtualMethodSlot(_compilation.NodeFactory, methodDesc, owningType); 1900if (_compilation.NeedsSlotUseTracking(owningType)) 1901(_additionalDependencies ??= new ILCompiler.DependencyAnalysisFramework.DependencyNodeCore<NodeFactory>.DependencyList()).Add(_compilation.NodeFactory.VirtualMethodUse(methodDesc), "Virtual method call"); 1954Utf8String externName = new Utf8String(_compilation.PInvokeILProvider.GetDirectCallExternName(md)); 1955externName = _compilation.NodeFactory.NameMangler.NodeMangler.ExternMethod(externName, md); 1957pLookup = CreateConstLookupToSymbol(_compilation.NodeFactory.ExternFunctionSymbol(externName)); 1964*ppCookieVal = (IntPtr*)ObjectToHandle(_compilation.NodeFactory.ExternVariable(new Utf8String("__security_cookie"u8))); 1981MethodDesc stub = _compilation.PInvokeILProvider.GetCalliStub( 1997if (_compilation.HasLazyStaticConstructor(owningType) && !((MetadataType)owningType).IsBeforeFieldInit) 2017MethodDesc stub = _compilation.PInvokeILProvider.GetCalliStub( 2030if (_compilation.GetMethodIL(method) is Internal.IL.Stubs.PInvokeILStubMethodIL stub) 2054if (_compilation.TypeSystemContext.Target.Architecture == TargetArchitecture.ARM) 2100return (int*)ObjectToHandle(_compilation.NodeFactory.ExternVariable(new Utf8String("RhpTrapThreads"u8))); 2124fieldOffset += _compilation.NodeFactory.ThreadStaticBaseOffset(mt); 2138ISymbolNode node = _compilation.GetFieldRvaData(field); 2143if (_compilation.HasLazyStaticConstructor(field.OwningType)) 2178helper = _compilation.NodeFactory.ReadyToRunHelperFromTypeLookup( 2184helper = _compilation.NodeFactory.ReadyToRunHelperFromDictionaryLookup( 2210ISortableSymbolNode index = _compilation.NodeFactory.TypeThreadStaticIndex(field.OwningType); 2216if (_compilation.HasLazyStaticConstructor(field.OwningType)) 2234baseAddr = _compilation.NodeFactory.TypeGCStaticsSymbol(field.OwningType); 2239baseAddr = _compilation.NodeFactory.TypeNonGCStaticsSymbol(field.OwningType); 2243if (_compilation.HasLazyStaticConstructor(field.OwningType)) 2252_compilation.NodeFactory.ReadyToRunHelper(helperId, field.OwningType)); 2261if (_compilation.IsInitOnly(field)) 2285if (_compilation.TypeSystemContext.IsArrayVariantCastable(type)) 2292return !_compilation.CanReferenceConstructedTypeOrCanonicalFormOfType(type) 2293&& (type == canonType || !_compilation.CanReferenceConstructedMethodTable(canonType)); 2315if (_compilation.IsEffectivelySealed(type)) 2321TypeDesc[] implClasses = _compilation.GetImplementingClasses(type); 2349if (!field.IsThreadStatic && _compilation.IsInitOnly(field) && field.OwningType is MetadataType owningType) 2356PreinitializationManager preinitManager = _compilation.NodeFactory.PreinitializationManager; 2362int targetPtrSize = _compilation.TypeSystemContext.Target.PointerSize; 2378if (value.GetRawData(_compilation.NodeFactory, out object data)) 2427int strDataOffset = _compilation.TypeSystemContext.Target.PointerSize + sizeof(int); // 12 on 64bit 2454return ObjectToHandle(_compilation.NecessaryRuntimeTypeIfPossible(type)); 2480addr.addr = (void*)ObjectToHandle(_compilation.NodeFactory.TypeNonGCStaticsSymbol(type)); 2482offset = -NonGCStaticsNode.GetClassConstructorContextSize(_compilation.NodeFactory.Target); 2492addr.addr = (void*)ObjectToHandle(_compilation.NodeFactory.TypeGCStaticsSymbol(type)); 2497addr.addr = (void*)ObjectToHandle(_compilation.NodeFactory.TypeNonGCStaticsSymbol(type)); 2505pInfo->tlsIndexObject = CreateConstLookupToSymbol(_compilation.NodeFactory.ExternDataSymbol(new Utf8String("_tls_index"u8))); 2506pInfo->tlsRootObject = CreateConstLookupToSymbol(_compilation.NodeFactory.TlsRoot); 2507pInfo->threadStaticBaseSlow = CreateConstLookupToSymbol(_compilation.NodeFactory.HelperEntrypoint(HelperEntrypoint.GetInlinedThreadStaticBaseSlow)); 2508pInfo->tlsGetAddrFtnPtr = CreateConstLookupToSymbol(_compilation.NodeFactory.ExternFunctionSymbol(new Utf8String("__tls_get_addr"u8)));
src\runtime\src\coreclr\tools\Common\JitInterface\CorInfoImpl.cs (79)
188get => field ??= _compilation.TypeSystemContext.SystemModule.GetType( 208return _compilation.Logger; 431if (_compilation.TypeSystemContext.Target.Architecture != TargetArchitecture.ARM64 432&& _compilation.TypeSystemContext.Target.Architecture != TargetArchitecture.LoongArch64 433&& _compilation.TypeSystemContext.Target.Architecture != TargetArchitecture.RiscV64) 470_compilation.NodeFactory.Target.MinimumFunctionAlignment : 471_compilation.NodeFactory.Target.OptimumFunctionAlignment; 599CodeBasedDependencyAlgorithm.AddDependenciesDueToMethodCodePresence(ref _additionalDependencies, _compilation.NodeFactory, MethodBeingCompiled, methodIL); 659return _compilation.TypeSystemContext.Target.PointerSize; 1018if (_compilation.TypeSystemContext.Target.Architecture == TargetArchitecture.X86) 1158if (_compilation.IsEffectivelySealed(method.GetUnboxedMethod())) 1163if (_compilation.IsEffectivelySealed(method)) 1311method = _compilation.TypeSystemContext.GetMethodForInstantiatedType(method.GetTypicalMethodDefinition(), (InstantiatedType)type); 1337MethodDesc instantiatedMethod = _compilation.TypeSystemContext.GetMethodForInstantiatedType(method.GetTypicalMethodDefinition(), instantiatedCtxType); 1340instantiatedMethod = _compilation.TypeSystemContext.GetInstantiatedMethod(instantiatedMethod, method.Instantiation); 1349if (!_compilation.CanInline(MethodBeingCompiled, method)) 1353MethodIL methodIL = method.IsUnboxingThunk() ? null : _compilation.GetMethodIL(method); 1392var calleeIL = _compilation.GetMethodIL(calleeMethod); 1401if (_compilation.CanInline(callerMethod, calleeMethod)) 1425var methodIL = _compilation.GetMethodIL(HandleToObject(ftn)); 1471decl = _compilation.TypeSystemContext.GetMethodForInstantiatedType(decl.GetTypicalMethodDefinition(), (InstantiatedType)ownerTypeDesc); 1475MethodDesc originalImpl = _compilation.ResolveVirtualMethod(decl, objType, out info->detail); 1645info->instParamLookup.constLookup = CreateConstLookupToSymbol(_compilation.NodeFactory.ConstructedTypeSymbol(originalImpl.OwningType)); 1684MethodILScope scope = jitInterface._compilation.GetMethodIL(methodWithToken.Method); 1744MetadataType placeholderType = _compilation.TypeSystemContext.SystemModule.GetType("System"u8, "SZGenericArrayEnumerator`1"u8, throwIfNotFound: false); 1948result = _compilation.TypeSystemContext.GetAsyncVariantMethod((MethodDesc)result); 2023_compilation.TypeSystemContext.EnsureLoadableMethod(method); 2036_compilation.NodeFactory.MetadataManager.GetDependenciesDueToAccess(ref _additionalDependencies, _compilation.NodeFactory, (MethodIL)methodIL, method); 2042? _compilation.TypeSystemContext.GetAsyncVariantMethod(method) 2073_compilation.TypeSystemContext.EnsureLoadableType(owningClass); 2077_compilation.NodeFactory.MetadataManager.GetDependenciesDueToAccess(ref _additionalDependencies, _compilation.NodeFactory, (MethodIL)methodIL, field); 2104_compilation.TypeSystemContext.EnsureLoadableType(type); 2143if (_compilation.IsFatPointerCandidate(methodIL.OwningMethod, methodSig)) 2172return ObjectToHandle(_compilation.TypeSystemContext.GetWellKnownType(result)); 2340if (_compilation.IsEffectivelySealed(type)) 2917!_compilation.HasLazyStaticConstructor(type) 3017return ObjectToHandle(_compilation.TypeSystemContext.GetWellKnownType(WellKnownType.Object)); 3020return ObjectToHandle(_compilation.TypeSystemContext.GetWellKnownType(WellKnownType.TypedReference)); 3023return ObjectToHandle(_compilation.TypeSystemContext.GetWellKnownType(WellKnownType.RuntimeTypeHandle)); 3026return ObjectToHandle(_compilation.TypeSystemContext.GetWellKnownType(WellKnownType.RuntimeFieldHandle)); 3029return ObjectToHandle(_compilation.TypeSystemContext.GetWellKnownType(WellKnownType.RuntimeMethodHandle)); 3032ThrowHelper.ThrowTypeLoadException("System", "RuntimeArgumentHandle", _compilation.TypeSystemContext.SystemModule); 3036return ObjectToHandle(_compilation.TypeSystemContext.GetWellKnownType(WellKnownType.String)); 3039return ObjectToHandle(_compilation.TypeSystemContext.SystemModule.GetKnownType("System"u8, "RuntimeType"u8)); 3042return ObjectToHandle(_compilation.TypeSystemContext.SystemModule.GetKnownType("System.Numerics"u8, "Vector`1"u8)); 3237return _compilation.IsEffectivelySealed(type); 3351return (void*)ObjectToHandle(_compilation.GetFieldRvaData(fd)); 3633if (_compilation.NodeFactory.Target.IsWasm) 3638else if (_compilation.NodeFactory.Target.IsWindows) 3648pEEInfoOut.osType = TargetToOs(_compilation.NodeFactory.Target); 3653DefType continuation = _compilation.TypeSystemContext.ContinuationType; 3659DefType asyncHelpers = _compilation.TypeSystemContext.SystemModule.GetKnownType("System.Runtime.CompilerServices"u8, "AsyncHelpers"u8); 3675NodeFactory factory = _compilation.NodeFactory; 3694CompilerTypeSystemContext context = _compilation.TypeSystemContext; 3775CompilerTypeSystemContext context = _compilation.TypeSystemContext; 3844return ObjectToHandle(_compilation.TypeSystemContext.GetContinuationType(gcMapBuilder.ToGCMap())); 3994HandleToObject(structHnd), _compilation.TypeSystemContext.Target.Architecture); 4278=> (chunk.flags & CorJitAllocMemFlag.CORJIT_ALLOCMEM_HAS_POINTERS_TO_CODE) != 0 && !_compilation.TypeSystemContext.Target.IsWindows; 4417var target = _compilation.TypeSystemContext.Target; 4700switch (_compilation.TypeSystemContext.Target.Architecture) 4719return (uint)node.GetAlignment(_compilation.NodeFactory); 4728TargetArchitecture arch = _compilation.TypeSystemContext.Target.Architecture; 4795return owningMetadataType.Module == _compilation.TypeSystemContext.SystemModule; 4804flags.InstructionSetFlags.Add(_compilation.InstructionSetSupport.OptimisticFlags); 4814TargetArchitecture targetArchitecture = _compilation.TypeSystemContext.Target.Architecture; 4821Debug.Assert(_compilation.InstructionSetSupport.IsInstructionSetSupported(InstructionSet.X86_X86Base)); 4825Debug.Assert(_compilation.InstructionSetSupport.IsInstructionSetSupported(InstructionSet.ARM64_AdvSimd)); 4829if (targetArchitecture == TargetArchitecture.ARM && !_compilation.TypeSystemContext.Target.IsWindows) 4884|| (_compilation.TypeSystemContext.IsSpecialUnboxingThunk(this.MethodBeingCompiled) && _compilation.TypeSystemContext.GetTargetOfSpecialUnboxingThunk(this.MethodBeingCompiled).IsAsyncCall()) 4885|| (_compilation.TypeSystemContext.IsDefaultInterfaceMethodImplementationInstantiationThunk(this.MethodBeingCompiled) && _compilation.TypeSystemContext.GetTargetOfDefaultInterfaceMethodImplementationInstantiationThunk(this.MethodBeingCompiled).IsAsyncCall()) 4993PgoSchemaElem[] pgoResultsSchemas = _compilation.ProfileData[methodDesc]?.SchemaData; 5004, _compilation.CanReferenceConstructedMethodTable 5099instructionSet = InstructionSetFlags.ConvertToImpliedInstructionSetForVectorInstructionSets(_compilation.TypeSystemContext.Target.Architecture, instructionSet); 5101Debug.Assert(!_compilation.InstructionSetSupport.NonSpecifiableFlags.HasInstructionSet(instructionSet)); 5103return supportEnabled ? _compilation.InstructionSetSupport.IsInstructionSetSupported(instructionSet) : false;