312 references to IsValueType
ILCompiler.Compiler (141)
Compiler\Compilation.cs (2)
308if (type.IsValueType && type.GetParameterlessConstructor() == null) 366return type.IsValueType ? NodeFactory.ExactCallableAddress(ctor) : NodeFactory.CanonicalEntrypoint(ctor);
Compiler\CompilerTypeSystemContext.Aot.cs (3)
96(elementType.IsDefType && !elementType.IsValueType)) 137if (fieldType.IsValueType) 217else if (type.IsValueType)
Compiler\CompilerTypeSystemContext.GetFieldMethodOverrides.cs (2)
114Debug.Assert(type.IsValueType); 159Debug.Assert(Type.IsValueType);
Compiler\Dataflow\MethodBodyScanner.cs (1)
892isByRef |= param.IsImplicitThis && paramType.IsValueType;
Compiler\Dataflow\ReflectionMethodBodyScanner.cs (2)
406if (parameterType.IsValueType) 447if (!method.Signature.IsStatic && !method.HasInstantiation && !method.IsConstructor && !method.OwningType.IsValueType)
Compiler\DelegateCreationInfo.cs (1)
66return TargetMethod.OwningType.IsValueType && !TargetMethod.Signature.IsStatic;
Compiler\DependencyAnalysis\EETypeNode.cs (8)
404factory.TentativeMethodEntrypoint(canonImpl, impl.OwningType.IsValueType) : 405factory.MethodEntrypoint(canonImpl, impl.OwningType.IsValueType); 409factory.AddressTakenMethodEntrypoint(canonImpl, impl.OwningType.IsValueType), 844if (_type.IsArray && parameterType.IsValueType && !parameterType.IsNullable) 962bool isAsyncStateMachineValueType = implType.IsValueType 1022implSymbol = factory.TentativeMethodEntrypoint(canonImplMethod, implMethod.OwningType.IsValueType); 1024implSymbol = factory.AddressTakenMethodEntrypoint(canonImplMethod, implMethod.OwningType.IsValueType); 1026implSymbol = factory.MethodEntrypoint(canonImplMethod, implMethod.OwningType.IsValueType);
Compiler\DependencyAnalysis\ExactMethodInstantiationsNode.cs (2)
55bool getUnboxingStub = method.OwningType.IsValueType && !method.Signature.IsStatic; 108bool getUnboxingStub = method.OwningType.IsValueType && !method.Signature.IsStatic;
Compiler\DependencyAnalysis\GenericDictionaryNode.cs (3)
135if (arg.IsValueType || arg.GetDefaultConstructor() == null || !ConstructedEETypeNode.CreationAllowed(arg)) 224if (arg.IsValueType || arg.GetDefaultConstructor() == null || !ConstructedEETypeNode.CreationAllowed(arg)) 234if (arg.IsValueType || arg.GetDefaultConstructor() == null || !ConstructedEETypeNode.CreationAllowed(arg))
Compiler\DependencyAnalysis\GenericLookupResult.cs (2)
1018return instantiatedType.IsValueType ? factory.ExactCallableAddress(defaultCtor) : factory.CanonicalEntrypoint(defaultCtor); 1134Debug.Assert(instantiatedConstraintType.IsValueType || (instantiatedConstrainedMethod.OwningType.IsInterface && instantiatedConstrainedMethod.Signature.IsStatic));
Compiler\DependencyAnalysis\GenericVirtualMethodImplNode.cs (1)
51bool getUnboxingStub = _method.OwningType.IsValueType && !_method.Signature.IsStatic;
Compiler\DependencyAnalysis\ManagedDataDescriptorNode.cs (1)
133if (type.IsValueType)
Compiler\DependencyAnalysis\MetadataEETypeNode.cs (1)
48if (_type.IsValueType)
Compiler\DependencyAnalysis\NativeLayoutVertexNode.cs (2)
109public virtual bool IsUnboxingStub => _method.OwningType.IsValueType && !_method.Signature.IsStatic; 733if (owningType.IsSzArray || owningType.HasSameTypeDefinition(factory.ArrayOfTClass) || owningType.IsValueType || owningType.IsSealed())
Compiler\DependencyAnalysis\ReflectionInvokeMapNode.cs (3)
60if (method.OwningType.IsValueType && !method.Signature.IsStatic) 153bool goesThroughInstantiatingUnboxingThunk = method.OwningType.IsValueType && !method.Signature.IsStatic && !method.HasInstantiation; 193unboxingStub: method.OwningType.IsValueType && !method.Signature.IsStatic))));
Compiler\DependencyAnalysis\SealedVTableNode.cs (6)
139node = factory.AddressTakenMethodEntrypoint(implMethod.GetCanonMethodTarget(CanonicalFormKind.Specific), unboxingStub: !implMethod.Signature.IsStatic && declType.IsValueType); 141node = factory.MethodEntrypoint(implMethod.GetCanonMethodTarget(CanonicalFormKind.Specific), unboxingStub: !implMethod.Signature.IsStatic && declType.IsValueType); 199node = factory.AddressTakenMethodEntrypoint(targetMethod.GetCanonMethodTarget(CanonicalFormKind.Specific), unboxingStub: !targetMethod.Signature.IsStatic && declType.IsValueType); 201node = factory.MethodEntrypoint(targetMethod.GetCanonMethodTarget(CanonicalFormKind.Specific), unboxingStub: !targetMethod.Signature.IsStatic && declType.IsValueType); 234node = factory.AddressTakenMethodEntrypoint(canonImplMethod, unboxingStub: implMethod.OwningType.IsValueType && !implMethod.Signature.IsStatic); 236node = factory.MethodEntrypoint(canonImplMethod, unboxingStub: implMethod.OwningType.IsValueType && !implMethod.Signature.IsStatic);
Compiler\DependencyAnalysis\SerializedFrozenObjectNode.cs (1)
48: ((DefType)_data.Type).InstanceByteCount.AsInt + (_data.Type.IsValueType ? _data.Type.Context.Target.PointerSize : 0);
Compiler\DependencyAnalysis\TentativeInstanceMethodNode.cs (1)
28Debug.Assert(!methodNode.Method.OwningType.IsValueType);
Compiler\DependencyAnalysis\UnboxingStubNode.cs (1)
34Debug.Assert(target.OwningType.IsValueType);
Compiler\DependencyAnalysis\VariantInterfaceMethodUseNode.cs (4)
68if (!variantArgument.IsValueType 89(elementType.IsDefType && !elementType.IsValueType); 118if (!variantArgument.IsValueType 137(elementType.IsDefType && !elementType.IsValueType);
Compiler\JitHelper.cs (1)
357if (type.IsValueType)
Compiler\MetadataManager.cs (1)
708!method.Signature.IsStatic && method.OwningType.IsValueType);
Compiler\SubstitutedILProvider.cs (1)
1007"get_IsValueType" => type.IsValueType ? 1 : 0,
Compiler\TypePreinit.cs (19)
294|| (elementType.IsValueType && ((DefType)elementType).ContainsGCPointers))) 505&& (method.Signature.IsStatic || method.IsConstructor || owningType.IsValueType || owningType.IsInterface) // ECMA-335 I.8.9.5 528if (!owningType.IsValueType && (method.IsVirtual || methodParams[0] == null)) 641if (owningType.IsValueType) 679else if (fieldType.IsValueType && ((DefType)fieldType).ContainsGCPointers) 685} while (allGcPointersAreReadonly && (currentType = currentType.BaseType) != null && !currentType.IsValueType); 1688if (type.IsValueType) 1886Debug.Assert(locationType.IsValueType || locationType.IsPointer || locationType.IsFunctionPointer); 1917&& method.Instantiation[0].IsValueType) 1941retVal = ValueTypeValue.FromSByte(typeToCheckForValueType.TypeRepresented.IsValueType ? (sbyte)1 : (sbyte)0); 1986return method.OwningType.IsValueType ? method.OwningType.MakeByRefType() : method.OwningType; 2207if (!locationType.IsValueType 2330Debug.Assert(type.IsValueType || type.IsPointer || type.IsFunctionPointer); 2457if (!type.IsValueType 2624if (!type.IsValueType 3147if (!type.IsValueType 3540if (type.IsValueType) 3565if (!type.IsValueType || type.IsNullable) 3604if (Type.IsValueType)
Compiler\UnixNodeMangler.cs (2)
17Debug.Assert(type.IsValueType); 23Utf8String mangledJustTypeName = type.IsValueType
Compiler\UsageBasedMetadataManager.cs (1)
320if (elementType.IsValueType)
Compiler\UserDefinedTypeDescriptor.cs (7)
50Debug.Assert(type.IsValueType); 264if ((type.IsDefType && !type.IsValueType) || type.IsArray) 559IsStruct = type.IsValueType ? 1 : 0, 573if (type.HasBaseType && !type.IsValueType) 597bool hasInstanceFields = defType.IsValueType || NodeFactory.MetadataManager.HasConstructedEEType(defType); 661catch (TypeSystemException) when (!fieldType.IsValueType) 739LayoutInt instanceSize = defType.IsValueType ? defType.InstanceFieldSize : defType.InstanceByteCount;
Compiler\WindowsNodeMangler.cs (2)
31Debug.Assert(type.IsValueType); 37Utf8String mangledJustTypeName = type.IsValueType
IL\ILImporter.Scanner.cs (8)
141(_canonMethod.Signature.IsStatic || _canonMethod.IsConstructor || owningType.IsValueType || owningType.IsInterface)) 669_dependencies.Add(type.IsValueType ? _factory.ExactCallableAddress(ctor) : _factory.CanonicalEntrypoint(ctor), reason); 778else if (constrained.IsValueType) 853Debug.Assert(targetMethod.OwningType.IsValueType || targetMethod.Signature.IsStatic); 1108if (!awaiterType.IsValueType) 1255if (!type.IsValueType) 1585if (!type.IsValueType) 2046bool isValueTask = taskReturnType.IsValueType;
parent\parent\Common\Compiler\CompilerTypeSystemContext.BoxedTypes.cs (5)
61Debug.Assert(owningType.IsValueType); 88Debug.Assert(owningType.IsValueType); 265Debug.Assert(valuetype.IsValueType); 382Debug.Assert(targetMethod.OwningType.IsValueType); 495Debug.Assert(targetMethod.OwningType.IsValueType);
parent\parent\Common\Compiler\Dataflow\EcmaExtensions.cs (1)
77return method.OwningType.IsValueType ? ReferenceKind.Ref : ReferenceKind.None;
parent\parent\Common\Compiler\MethodExtensions.cs (1)
150!owningType.IsValueType && /* Value type instance methods take a ref to data */
parent\parent\Common\Compiler\TypeExtensions.cs (8)
46(method.HasInstantiation || method.Signature.IsStatic || method.ImplementationType.IsValueType || (method.ImplementationType.IsInterface && !method.IsAbstract)); 64return (method.Signature.IsStatic || method.ImplementationType.IsValueType || (method.ImplementationType.IsInterface && !method.IsAbstract)) && 77!method.ImplementationType.IsValueType && 496if (!constrainedType.IsValueType) 540if (method != null && !method.OwningType.IsValueType) 622if (!method.OwningType.IsValueType) 639&& !method.OwningType.IsValueType) 847return firstFieldElementType.IsValueType
parent\parent\Common\Internal\Runtime\EETypeBuilderHelpers.cs (3)
91if ((arrayElementType.IsValueType && ((DefType)arrayElementType).ContainsGCPointers) || arrayElementType.IsGCPointer) 136if (type.IsValueType) 221if (type.IsValueType && type != type.Context.UniversalCanonType)
parent\parent\Common\Internal\Runtime\GCDescEncoder.cs (1)
108int offs = defType.IsValueType ? builder.TargetPointerSize : 0;
parent\parent\Common\JitInterface\WasmLowering.cs (3)
60if (!(type.IsValueType && !type.IsPrimitive)) 119if (type.IsValueType && !type.IsPrimitive) 241if (type is not DefType || !type.IsValueType)
parent\parent\Common\TypeSystem\IL\DelegateInfo.cs (2)
171return firstParam.IsSignatureVariable || firstParam.IsValueType; 180return !firstParam.IsValueType;
parent\parent\Common\TypeSystem\IL\NativeAotILProvider.cs (2)
111&& activatedType.IsValueType 235Debug.Assert(elementType.IsValueType);
parent\parent\Common\TypeSystem\IL\Stubs\AsyncResumptionStub.cs (1)
61if (_targetMethod.OwningType.IsValueType)
parent\parent\Common\TypeSystem\IL\Stubs\AsyncThunks.cs (1)
28bool isValueTask = returnType.IsValueType;
parent\parent\Common\TypeSystem\IL\Stubs\ComparerIntrinsics.cs (3)
252Debug.Assert(type.IsValueType); 296Debug.Assert(fieldType.IsValueType); 342Debug.Assert(fieldType.IsValueType);
parent\parent\Common\TypeSystem\IL\Stubs\DynamicInvokeMethodThunk.cs (1)
69if (type.IsValueType)
parent\parent\Common\TypeSystem\IL\Stubs\GetFieldHelperMethodOverride.cs (5)
89if (_owningType.IsValueType && ComparerIntrinsics.CanCompareValueTypeBitsUntilOffset(_owningType, Context.GetWellKnownType(WellKnownType.Object).GetMethod("Equals"u8, null), out int lastFieldEndOffset)) 102ILToken rawDataToken = owningType.IsValueType ? default : 134if (!fieldTypeForOptimizationChecks.IsValueType) 153if (!owningType.IsValueType) 167if (!owningType.IsValueType
parent\parent\Common\TypeSystem\IL\Stubs\InterlockedIntrinsics.cs (1)
40if (!tType.IsValueType)
parent\parent\Common\TypeSystem\IL\Stubs\RuntimeHelpersIntrinsics.cs (1)
64else if (mdType.IsValueType)
parent\parent\Common\TypeSystem\IL\Stubs\StructMarshallingThunk.cs (2)
84ManagedType.IsValueType ? (TypeDesc)ManagedType.MakeByRefType() : ManagedType, 91ManagedType.IsValueType ? (TypeDesc)ManagedType.MakeByRefType() : ManagedType
parent\parent\Common\TypeSystem\Interop\IL\InlineArrayType.cs (1)
176Debug.Assert(elementType.IsValueType);
parent\parent\Common\TypeSystem\Interop\IL\MarshalHelpers.Aot.cs (1)
41if (!type.IsValueType)
parent\parent\Common\TypeSystem\Interop\IL\MarshalHelpers.cs (6)
239if (type.IsValueType && !type.IsPrimitive && !type.IsEnum && !isField 248if (type.IsValueType && 369else if (type.IsValueType) 517if (type.IsValueType && !type.IsPrimitive && !type.IsEnum && !isField 752else if (elementType.IsValueType) 932else if (underlyingType.IsValueType)
parent\parent\Common\TypeSystem\Interop\IL\Marshaller.Aot.cs (1)
1230if (ManagedType.IsValueType || ManagedType.IsPointer || ManagedType.IsFunctionPointer)
parent\parent\Common\TypeSystem\Interop\IL\Marshaller.cs (1)
291if (parameterType.IsValueType || parameterType.IsString || parameterType.IsPointer || parameterType.IsFunctionPointer)
parent\parent\Common\TypeSystem\MetadataEmitter\TypeSystemMetadataEmitter.cs (1)
475blobBuilder.WriteByte(type.IsValueType ? (byte)SignatureTypeKind.ValueType : (byte)SignatureTypeKind.Class);
ILCompiler.ReadyToRun (93)
Compiler\DependencyAnalysis\ReadyToRun\DevirtualizationManager.cs (1)
81if (firstTypeInImplTypeHierarchyNotInVersionBubble == null || implType.IsValueType || firstTypeInImplTypeHierarchyNotInVersionBubble.IsObject)
Compiler\DependencyAnalysis\ReadyToRun\FieldFixupSignature.cs (1)
51&& !_fieldWithToken.Field.OwningType.IsValueType)
Compiler\DependencyAnalysis\ReadyToRun\GCRefMapBuilder.cs (1)
196bool interior = method.OwningType.IsValueType && !isUnboxingStub;
Compiler\DependencyAnalysis\ReadyToRun\TypeFixupSignature.cs (2)
54Debug.Assert(_typeDesc.IsValueType); 75Debug.Assert(type.IsValueType);
Compiler\DependencyAnalysis\ReadyToRun\TypeHandle.cs (2)
41public bool IsValueType() { if (_isByRef) return false; return _type.IsValueType; } 162if ((typeOfEmbeddedField != null) && ((typeOfEmbeddedField.IsValueType) || (typeOfEmbeddedField.IsPointer)))
Compiler\DependencyAnalysis\ReadyToRun\TypeValidationChecker.cs (3)
261if (type.IsValueType) 431if (type.BaseType != null && !type.IsInterface && !type.IsValueType) 713if (typeDef.IsValueType || position == Internal.TypeSystem.GenericVariance.None)
Compiler\DependencyAnalysis\ReadyToRunCodegenNodeFactory.cs (1)
165&& method.OwningType.IsValueType
Compiler\R2RTypeExtensions.cs (1)
25if (!type.IsValueType)
Compiler\ReadyToRunCodegenCompilation.cs (2)
645if (!fieldType.IsValueType) 663Debug.Assert(!type.IsValueType);
Compiler\ReadyToRunCompilationModuleGroupBase.cs (5)
338if ((type.BaseType != null) && !type.BaseType.IsObject && !type.IsValueType) 350if (fieldType.IsValueType && 617if (metadataType.IsValueType) 665if (!metadataType.IsValueType) 680if (!type.IsValueType)
Compiler\ReadyToRunCompilerContext.cs (1)
170if (fieldType.IsValueType)
Compiler\ReadyToRunMetadataFieldLayoutAlgorithm.cs (3)
111else if (fieldType.IsValueType) 619if (type is { IsValueType: false, BaseType.IsSequentialLayout: true }) 627if (type is { IsValueType: false, BaseType.IsExplicitLayout: true })
IBC\IBCProfileParser.cs (1)
688if ((typ == CorElementType.ELEMENT_TYPE_VALUETYPE) != result.IsValueType)
IL\ReadyToRunILProvider.cs (1)
58if (type.IsValueType && type.GetParameterlessConstructor() == null)
JitInterface\CorInfoImpl.ReadyToRun.cs (12)
1707field.FieldType.IsValueType && 1770if (field.FieldType.IsValueType && field.HasGCStaticBase && !field.HasRva) 2057useInstantiatingStub = directMethod.OwningType.IsValueType; 2078else if (constrainedType.IsValueType) 2184devirt = targetMethod.OwningType.IsValueType || 2290DictionaryEntryKind entryKind = (constrainedType != null && (constrainedType.IsValueType || !isCallVirt) 2412if (type.IsValueType) 3058if ((td.IsValueType) && !md.Signature.IsStatic 3101if (!type.IsValueType) 3131if (pMT.IsValueType) 3150else if (pMT.IsValueType) 3762if (type.IsValueType && type.IsTypeDefEquivalent && !_compilation.CompilationModuleGroup.VersionsWithTypeReference(type))
parent\parent\Common\Compiler\CompilerTypeSystemContext.BoxedTypes.cs (5)
61Debug.Assert(owningType.IsValueType); 88Debug.Assert(owningType.IsValueType); 265Debug.Assert(valuetype.IsValueType); 382Debug.Assert(targetMethod.OwningType.IsValueType); 495Debug.Assert(targetMethod.OwningType.IsValueType);
parent\parent\Common\Compiler\Dataflow\EcmaExtensions.cs (1)
77return method.OwningType.IsValueType ? ReferenceKind.Ref : ReferenceKind.None;
parent\parent\Common\Compiler\MethodExtensions.cs (1)
150!owningType.IsValueType && /* Value type instance methods take a ref to data */
parent\parent\Common\Compiler\TypeExtensions.cs (8)
46(method.HasInstantiation || method.Signature.IsStatic || method.ImplementationType.IsValueType || (method.ImplementationType.IsInterface && !method.IsAbstract)); 64return (method.Signature.IsStatic || method.ImplementationType.IsValueType || (method.ImplementationType.IsInterface && !method.IsAbstract)) && 77!method.ImplementationType.IsValueType && 496if (!constrainedType.IsValueType) 540if (method != null && !method.OwningType.IsValueType) 622if (!method.OwningType.IsValueType) 639&& !method.OwningType.IsValueType) 847return firstFieldElementType.IsValueType
parent\parent\Common\JitInterface\CorInfoImpl.cs (16)
1020if (type.IsValueType) 1504bool unboxingStub = impl.OwningType.IsValueType; 1659if (!methodWithTokenDecl.Method.OwningType.IsValueType || !methodWithTokenImpl.Method.OwningType.IsValueType) 2288return HandleToObject(cls).IsValueType; 2316if (type.IsValueType) 2434Debug.Assert(!type.IsValueType); 2448Debug.Assert(!type.IsValueType); 2501if ((type.IsValueType) && (type.InstanceFieldAlignment.AsInt > 4)) 2558if (fieldType.IsValueType) 2618uint size = type.IsValueType ? getClassSize(cls) : getHeapClassSize(cls); 2860if (type is not MetadataType metadataType || !type.IsValueType) 2947else if (!md.IsConstructor && !typeToInit.IsValueType && !typeToInit.IsInterface) 2996if (!typeToInit.IsValueType && !typeToInit.IsInterface && !typeToInit.IsBeforeFieldInit) 3238if (type.IsValueType) 3705bool isValueTask = taskReturnType.IsValueType;
parent\parent\Common\JitInterface\SwiftPhysicalLowering.cs (2)
104protected override bool NeedsRecursiveLayout(TypeDesc fieldType) => fieldType.IsValueType && !fieldType.IsPrimitiveNumeric; 215if (!type.IsValueType || type is DefType { ContainsGCPointers: true })
parent\parent\Common\JitInterface\SystemVStructClassificator.cs (1)
74if (typeDesc.IsValueType && (typeSize <= CLR_SYSTEMV_MAX_STRUCT_BYTES_TO_PASS_IN_REGISTERS))
parent\parent\Common\JitInterface\UnboxingMethodDesc.cs (1)
25Debug.Assert(wrappedMethod.OwningType.IsValueType);
parent\parent\Common\JitInterface\WasmLowering.cs (3)
60if (!(type.IsValueType && !type.IsPrimitive)) 119if (type.IsValueType && !type.IsPrimitive) 241if (type is not DefType || !type.IsValueType)
parent\parent\Common\TypeSystem\IL\Stubs\AsyncResumptionStub.cs (1)
61if (_targetMethod.OwningType.IsValueType)
parent\parent\Common\TypeSystem\IL\Stubs\AsyncThunks.cs (1)
28bool isValueTask = returnType.IsValueType;
parent\parent\Common\TypeSystem\IL\Stubs\ComparerIntrinsics.cs (3)
252Debug.Assert(type.IsValueType); 296Debug.Assert(fieldType.IsValueType); 342Debug.Assert(fieldType.IsValueType);
parent\parent\Common\TypeSystem\IL\Stubs\InterlockedIntrinsics.cs (1)
40if (!tType.IsValueType)
parent\parent\Common\TypeSystem\IL\Stubs\RuntimeHelpersIntrinsics.cs (1)
64else if (mdType.IsValueType)
parent\parent\Common\TypeSystem\Interop\IL\MarshalHelpers.cs (6)
239if (type.IsValueType && !type.IsPrimitive && !type.IsEnum && !isField 248if (type.IsValueType && 369else if (type.IsValueType) 517if (type.IsValueType && !type.IsPrimitive && !type.IsEnum && !isField 752else if (elementType.IsValueType) 932else if (underlyingType.IsValueType)
parent\parent\Common\TypeSystem\Interop\IL\Marshaller.cs (1)
291if (parameterType.IsValueType || parameterType.IsString || parameterType.IsPointer || parameterType.IsFunctionPointer)
parent\parent\Common\TypeSystem\MetadataEmitter\TypeSystemMetadataEmitter.cs (1)
475blobBuilder.WriteByte(type.IsValueType ? (byte)SignatureTypeKind.ValueType : (byte)SignatureTypeKind.Class);
PortableCallHelpers\PInvokeTableGenerator.cs (3)
398if (!type.IsValueType || type.IsPrimitive || type.IsEnum || type is FunctionPointerType) 406if (!type.IsValueType || type.IsPointer || type.IsByRef || type is FunctionPointerType) 432if (!type.IsValueType || type.IsPointer || type is FunctionPointerType)
ILCompiler.RyuJit (23)
Compiler\DependencyAnalysis\MethodCodeNode.cs (1)
227varType = _method.OwningType.IsValueType ?
JitInterface\CorInfoImpl.RyuJit.cs (3)
426Debug.Assert(directMethod.OwningType.IsValueType || directMethod.Signature.IsStatic); 1144if (type.IsValueType) 1281else if (constrainedType.IsValueType)
parent\ILCompiler.Compiler\Compiler\JitHelper.cs (1)
357if (type.IsValueType)
parent\parent\Common\JitInterface\CorInfoImpl.cs (14)
1020if (type.IsValueType) 1504bool unboxingStub = impl.OwningType.IsValueType; 2288return HandleToObject(cls).IsValueType; 2316if (type.IsValueType) 2434Debug.Assert(!type.IsValueType); 2448Debug.Assert(!type.IsValueType); 2501if ((type.IsValueType) && (type.InstanceFieldAlignment.AsInt > 4)) 2558if (fieldType.IsValueType) 2618uint size = type.IsValueType ? getClassSize(cls) : getHeapClassSize(cls); 2860if (type is not MetadataType metadataType || !type.IsValueType) 2947else if (!md.IsConstructor && !typeToInit.IsValueType && !typeToInit.IsInterface) 2996if (!typeToInit.IsValueType && !typeToInit.IsInterface && !typeToInit.IsBeforeFieldInit) 3238if (type.IsValueType) 3705bool isValueTask = taskReturnType.IsValueType;
parent\parent\Common\JitInterface\SwiftPhysicalLowering.cs (2)
104protected override bool NeedsRecursiveLayout(TypeDesc fieldType) => fieldType.IsValueType && !fieldType.IsPrimitiveNumeric; 215if (!type.IsValueType || type is DefType { ContainsGCPointers: true })
parent\parent\Common\JitInterface\SystemVStructClassificator.cs (1)
74if (typeDesc.IsValueType && (typeSize <= CLR_SYSTEMV_MAX_STRUCT_BYTES_TO_PASS_IN_REGISTERS))
parent\parent\Common\JitInterface\UnboxingMethodDesc.cs (1)
25Debug.Assert(wrappedMethod.OwningType.IsValueType);
ILCompiler.TypeSystem (55)
parent\parent\Common\TypeSystem\Canon\StandardCanonicalizationAlgorithm.cs (1)
102if (!typeToConvert.IsValueType)
parent\parent\Common\TypeSystem\Canon\TypeDesc.Canon.cs (1)
90else if (this.IsValueType)
parent\parent\Common\TypeSystem\Common\CastingHelper.cs (2)
138bool isCastFromValueTypeToReferenceType = otherType.IsValueType && !thisType.IsValueType;
parent\parent\Common\TypeSystem\Common\CastingHelper.TypeEquivalence.cs (3)
159if ((type1.IsEnum != type2.IsEnum) || (type1.IsValueType != type2.IsValueType)) 168else if (type1.IsValueType)
parent\parent\Common\TypeSystem\Common\DefType.FieldLayout.cs (1)
585if (!IsValueType && HasBaseType && BaseType.ContainsGCPointers)
parent\parent\Common\TypeSystem\Common\ExplicitLayoutValidator.cs (2)
60else if (fieldType.IsValueType) 79if (!fieldType.IsValueType)
parent\parent\Common\TypeSystem\Common\FieldLayoutIntervalCalculator.cs (1)
70else if (fieldType.IsValueType)
parent\parent\Common\TypeSystem\Common\MetadataFieldLayoutAlgorithm.cs (19)
68if (!type.IsValueType && !type.IsAutoLayout) 209if (fieldType.IsByRef || (fieldType.IsValueType && ((DefType)fieldType).IsByRefLike)) 256if (fieldType.IsValueType) 316LayoutInt offsetBias = !type.IsValueType ? new LayoutInt(type.Context.Target.PointerSize) : LayoutInt.Zero; 371|| (fieldType.IsValueType && ((DefType)fieldType).ContainsGCPointers) 435LayoutInt offsetBias = !type.IsValueType ? new LayoutInt(type.Context.Target.PointerSize) : LayoutInt.Zero; 512if (type.ContainsGCPointers || type.IsByRefLike || !type.IsValueType) 601if (type.ContainsGCPointers || type.IsByRefLike || !type.IsValueType) 883if (!type.IsValueType && cumulativeInstanceFieldPos != LayoutInt.Zero && !type.Context.Target.SupportsAlign8) 1102return type.IsValueType && !type.IsPrimitive && !type.IsEnum; 1109if (!type.IsValueType && type.HasBaseType) 1149if (fieldType.IsValueType) 1204if (type.IsValueType && instanceSize == LayoutInt.Zero) 1211if (type.IsValueType) 1235if (type.IsValueType) 1261if (!type.IsValueType) 1280Debug.Assert(type.IsValueType); 1384if (!type.IsValueType) 1397if (!fieldType.IsValueType || fieldType.IsPrimitive)
parent\parent\Common\TypeSystem\Common\TypeDesc.TypeEquivalence.cs (2)
87if (!(IsInterface && (IsComImport || IsComEventInterface)) && !IsValueType && !IsDelegate) 129if (IsValueType)
parent\parent\Common\TypeSystem\Common\TypeSystemConstraintsHelpers.cs (6)
49if ((!instantiationParam.IsValueType || instantiationParam.IsNullable) 73if (instantiationParam.IsValueType && instantiatedType.IsValueType && !instantiationParam.IsEquivalentTo(instantiatedType)) 112if (constraint.IsValueType && !constraint.IsNullable) 116if (!constraint.IsValueType) 121if (constraint.IsValueType)
parent\parent\Common\TypeSystem\Common\TypeSystemContext.cs (1)
755if (!typeDefinition.IsValueType)
parent\parent\Common\TypeSystem\Common\TypeSystemHelpers.cs (3)
73if (type.IsValueType) 95return type.IsValueType || type.GetDefaultConstructor() != null; 415if (elementType.IsValueType)
parent\parent\Common\TypeSystem\Common\Utilities\GCPointerMap.Algorithm.cs (4)
26if (!type.IsValueType && type.HasBaseType) 52else if (fieldType.IsValueType) 89Debug.Assert(fieldType.IsValueType); 116else if (fieldType.IsValueType)
parent\parent\Common\TypeSystem\Ecma\EcmaSignatureEncoder.cs (2)
163encoder.GenericInstantiation(_entityHandleProvider.GetTypeDefOrRefHandleForTypeDesc(type.GetTypeDefinition()), type.Instantiation.Length, type.IsValueType); 170encoder.Type(_entityHandleProvider.GetTypeDefOrRefHandleForTypeDesc(type), type.IsValueType);
parent\parent\Common\TypeSystem\Ecma\EcmaType.cs (1)
220bool isValueType = IsValueType;
parent\parent\Common\TypeSystem\IL\ILDisassembler.cs (1)
453string prefix = type.IsValueType ? "valuetype " : "class ";
parent\parent\Common\TypeSystem\IL\UnsafeAccessors.cs (4)
100&& firstArgType.IsValueType 132&& firstArgType.IsValueType 539Debug.Assert(!replacementType.IsValueType); 591if (replacementType.IsValueType)
parent\parent\Common\TypeSystem\RuntimeDetermined\RuntimeDeterminedCanonicalizationAlgorithm.cs (1)
92if (!typeToConvert.IsValueType)