200 references to Size
ComSvcConfig (13)
ComAdminWrapper.cs (1)
349if (IntPtr.Size == 8)
SafeNativeMethods.cs (12)
74if (is64bit && IntPtr.Size == 8) // No worries we are trying to open up a 64 bit hive just return 76else if (is64bit && IntPtr.Size == 4) // we are running under wow get the 64 bit hive 78else if (!is64bit && IntPtr.Size == 8) // we are running in 64 bit but need to open a 32 bit hive 80else if (!is64bit && IntPtr.Size == 4) 94if (is64bit && IntPtr.Size == 8) // No worries we are trying to open up a 64 bit hive just return 96else if (is64bit && IntPtr.Size == 4) // we are running under wow get the 64 bit hive 98else if (!is64bit && IntPtr.Size == 8) // we are running in 64 bit but need to open a 32 bit hive 100else if (!is64bit && IntPtr.Size == 4) 108if (is64bit && IntPtr.Size == 8) // No worries we are trying to open up a 64 bit hive just return 110else if (is64bit && IntPtr.Size == 4) // we are running under wow get the 64 bit hive 112else if (!is64bit && IntPtr.Size == 8) // we are running in 64 bit but need to open a 32 bit hive 114else if (!is64bit && IntPtr.Size == 4)
mscorlib (23)
system\Collections\Concurrent\ConcurrentDictionary.cs (1)
165return IntPtr.Size == 8;
system\collections\concurrent\PartitionerStatic.cs (2)
1731Contract.Assert((DEFAULT_BYTES_PER_CHUNK % IntPtr.Size) == 0, "bytes per chunk should be a multiple of pointer size"); 1732chunkSize = (DEFAULT_BYTES_PER_CHUNK / IntPtr.Size);
System\Diagnostics\Eventing\TraceLogging\Statics.cs (3)
33public static readonly TraceLoggingDataType IntPtrType = IntPtr.Size == 8 36public static readonly TraceLoggingDataType UIntPtrType = IntPtr.Size == 8 39public static readonly TraceLoggingDataType HexIntPtrType = IntPtr.Size == 8
System\Diagnostics\Eventing\TraceLogging\TraceLoggingDataCollector.cs (2)
151DataCollector.ThreadInstance.AddScalar(&value, IntPtr.Size); 322DataCollector.ThreadInstance.AddArray(value, value == null ? 0 : value.Length, IntPtr.Size);
system\gc.cs (2)
150if( (4 == IntPtr.Size) && (bytesAllocated > Int32.MaxValue) ) { 166if( (4 == IntPtr.Size) && (bytesAllocated > Int32.MaxValue) ) {
system\intptr.cs (1)
82if (Size==4 && (l>Int32.MaxValue || l<Int32.MinValue)) {
system\number.cs (1)
362public static readonly Int32 NumberBufferBytes = 12 + ((NumberMaxDigits + 1) * 2) + IntPtr.Size;
system\runtime\interopservices\marshal.cs (1)
247if (IntPtr.Size == 8 && size == 4)
system\runtime\interopservices\safebuffer.cs (2)
106if (IntPtr.Size == 4 && numBytes > UInt32.MaxValue) 128if (IntPtr.Size == 4 && numElements * sizeOfEachElement > UInt32.MaxValue)
system\security\principal\windowsidentity.cs (1)
1072Contract.Assert(Marshal.SizeOf(typeof(Win32Native.KERB_S4U_LOGON)) % IntPtr.Size == 0, "Potential allignment issue setting up S4U logon buffer");
system\stubhelpers.cs (2)
1050vt = (IntPtr.Size == 4 ? VarEnum.VT_I4 : VarEnum.VT_I8); 1054vt = (IntPtr.Size == 4 ? VarEnum.VT_UI4 : VarEnum.VT_UI8);
system\threading\Tasks\ParallelLoopState.cs (3)
502if (IntPtr.Size >= 8) return rval; 557if (IntPtr.Size >= 8) return m_lowestBreakIteration; 570if (IntPtr.Size >= 8) return m_lowestBreakIteration;
system\threading\Tasks\ParallelRangeManager.cs (2)
119if (IntPtr.Size == 4 && _use32BitCurrentIndex) 265_use32BitCurrentIndex = IntPtr.Size == 4 && nRangeSize <= int.MaxValue;
PresentationFramework (3)
src\Framework\System\Windows\Standard\NativeMethods.cs (3)
3163if (8 == IntPtr.Size) 3438if (8 == IntPtr.Size) 3501if (8 == IntPtr.Size)
System (32)
compmod\microsoft\win32\UnsafeNativeMethods.cs (2)
97if (IntPtr.Size == 4) { 117if (IntPtr.Size == 4)
net\System\Net\_SSPIWrapper.cs (3)
522int nativeBlockSize = IntPtr.Size; 649nativeBuffer = new byte[IntPtr.Size]; 650if (IntPtr.Size == 4) // 32bit
net\System\Net\_Win32.cs (5)
11internal static int OverlappedInternalHighOffset = IntPtr.Size; 12internal static int OverlappedOffsetOffset = IntPtr.Size*2; 13internal static int OverlappedOffsetHighOffset = IntPtr.Size*2 + 4; 14internal static int OverlappedhEventOffset = IntPtr.Size*2 + 8; 15internal static int OverlappedSize = IntPtr.Size*3 + 8;
net\System\Net\Cache\HttpRequestCacheValidator.cs (1)
906if (IntPtr.Size == 4) {
net\System\Net\DNS.cs (2)
119currentArrayElement = IntPtrHelper.Add(currentArrayElement, IntPtr.Size); 153currentArrayElement = IntPtrHelper.Add(currentArrayElement, IntPtr.Size);
net\System\Net\Internal.cs (1)
1320cIssuers = *((uint*)(voidPtr + IntPtr.Size));
net\System\Net\SocketAddress.cs (7)
123m_Buffer = new byte[(size/IntPtr.Size+2)*IntPtr.Size];//sizeof DWORD 220m_Buffer[m_Buffer.Length-IntPtr.Size] = unchecked((byte)(m_Size)); 221m_Buffer[m_Buffer.Length-IntPtr.Size+1] = unchecked((byte)(m_Size >> 8)); 222m_Buffer[m_Buffer.Length-IntPtr.Size+2] = unchecked((byte)(m_Size >> 16)); 223m_Buffer[m_Buffer.Length-IntPtr.Size+3] = unchecked((byte)(m_Size >> 24)); 230return m_Buffer.Length-IntPtr.Size;
net\System\Net\WebSockets\WebSocketBuffer.cs (3)
36private static readonly int s_PropertyBufferSize = 2 * s_SizeOfUInt + s_SizeOfBool + IntPtr.Size; 148offset += IntPtr.Size; 179offset += IntPtr.Size;
net\System\Net\WebSockets\WebSocketProtocolComponent.cs (4)
795IntPtr lengthPtr = IntPtr.Add(httpHeaderPtr, IntPtr.Size); 818int valueOffset = 2 * IntPtr.Size; 819int lengthOffset = 3 * IntPtr.Size; 851int httpHeaderStructSize = 4 * IntPtr.Size;
net\System\URI.cs (1)
3622if (IntPtr.Size == 4) {
services\monitoring\system\diagnosticts\ProcessManager.cs (3)
588enumResult = NativeMethods.EnumProcessModules(processHandle, moduleHandlesArrayHandle.AddrOfPinnedObject(), moduleHandles.Length * IntPtr.Size, ref moduleCount); 640enumResult = NativeMethods.EnumProcessModules(processHandle, moduleHandlesArrayHandle.AddrOfPinnedObject(), moduleHandles.Length * IntPtr.Size, ref moduleCount); 656moduleCount /= IntPtr.Size;
System.Activities.Presentation (6)
Microsoft.Tools.Common\Microsoft\Tools\Common\Win32Interop.cs (3)
57if (IntPtr.Size == 4) 72if (IntPtr.Size == 8) 83if (IntPtr.Size == 8)
System.Activities.Presentation\System\Activities\Presentation\View\WindowExtensionMethods.cs (3)
18if (IntPtr.Size == 4) 33if (IntPtr.Size == 4) 68if (IntPtr.Size == 4)
System.AddIn (1)
System\Addin\Hosting\AddInProcess.cs (1)
317return System.IntPtr.Size == 4;
System.Core (10)
System\IO\MemoryMappedFiles\MemoryMappedFile.cs (4)
279if (IntPtr.Size == 4 && capacity > UInt32.MaxValue) { 345if (IntPtr.Size == 4 && capacity > UInt32.MaxValue) { 565if (IntPtr.Size == 4 && size > UInt32.MaxValue) { 598if (IntPtr.Size == 4 && size > UInt32.MaxValue) {
System\IO\MemoryMappedFiles\MemoryMappedView.cs (1)
98if (IntPtr.Size == 4 && nativeSize > UInt32.MaxValue) {
System\Linq\Parallel\Scheduling\Scheduling.cs (2)
102Contract.Assert((DEFAULT_BYTES_PER_CHUNK % IntPtr.Size) == 0, "bytes per chunk should be a multiple of pointer size"); 103chunkSize = (DEFAULT_BYTES_PER_CHUNK / IntPtr.Size);
System\Security\Cryptography\NCryptNative.cs (2)
1449int bufferSize = IntPtr.Size; 1454IntPtr.Size,
System\Security\Cryptography\X509Certificates\X509Native.cs (1)
59int cbData = IntPtr.Size;
System.Data (37)
cdf\src\NetFx40\Tools\Microsoft.Tools.Common\Microsoft\Tools\Common\Win32Interop.cs (3)
57if (IntPtr.Size == 4) 72if (IntPtr.Size == 8) 83if (IntPtr.Size == 8)
cdf\src\NetFx40\Tools\System.Activities.Presentation\System\Activities\Presentation\View\WindowExtensionMethods.cs (3)
18if (IntPtr.Size == 4) 33if (IntPtr.Size == 4) 68if (IntPtr.Size == 4)
fx\src\data\System\Data\Common\AdapterUtil.cs (1)
1855static internal readonly int PtrSize = IntPtr.Size;
fx\src\data\System\Data\Odbc\OdbcDataReader.cs (5)
2072buffer.PtrOffset(256, IntPtr.Size).Handle); 2141buffer.PtrOffset(256, IntPtr.Size).Handle); 2230IntPtr colnameActual = buffer.PtrOffset(colnameActualOffset, IntPtr.Size).Handle; 2231IntPtr indexActual = buffer.PtrOffset(indexActualOffset, IntPtr.Size).Handle; 2232IntPtr ordinalActual = buffer.PtrOffset(ordinalActualOffset, IntPtr.Size).Handle;
fx\src\data\System\Data\Odbc\OdbcParameter.cs (3)
686_preparedValueOffset = _preparedIntOffset + IntPtr.Size; 687parameterBufferSize += (cbParameterSize + IntPtr.Size); 705HandleRef intBuffer = parameterBuffer.PtrOffset(_preparedIntOffset, IntPtr.Size);
fx\src\data\System\Data\Odbc\OdbcParameterCollection.cs (2)
117parameterBufferSize = (parameterBufferSize + (IntPtr.Size-1)) & ~(IntPtr.Size-1); // align buffer;
fx\src\data\System\Data\OleDb\OleDbWrapper.cs (5)
41IntPtr method = Marshal.ReadIntPtr(vtable, 3 * IntPtr.Size); // GetDataSource is the 4'th vtable entry 121method = Marshal.ReadIntPtr(vtable, 3 * IntPtr.Size); // Initialize is the 4'th vtable entry 147method = Marshal.ReadIntPtr(vtable, 3 * IntPtr.Size); // CreateSession is the 4'th vtable entry 249method = Marshal.ReadIntPtr(vtable, 3 * IntPtr.Size); 280IntPtr method = Marshal.ReadIntPtr(vtable, 3 * IntPtr.Size);
fx\src\data\System\Data\OleDb\RowBinding.cs (6)
59Debug.Assert(_bindingCount * 3 * IntPtr.Size <= _dataLength, "_dataLength too small"); 228ValidateCheck(offset, 2*IntPtr.Size); 259ValidateCheck(offset, 2*IntPtr.Size); 364ValidateCheck(valueOffset, 2*IntPtr.Size); 376ValidateCheck(valueOffset, 2*IntPtr.Size); 540ValidateCheck(offset, IntPtr.Size);
fx\src\data\System\Data\ProviderBase\DbBuffer.cs (5)
286Debug.Assert(0 == offset%IntPtr.Size, "invalid alignment"); 307ValidateCheck(offset, IntPtr.Size); 518Debug.Assert(0 == offset%IntPtr.Size, "invalid alignment"); 537ValidateCheck(offset, IntPtr.Size); 538Debug.Assert(0 == offset%IntPtr.Size, "invalid alignment");
fx\src\data\System\Data\ProviderBase\DbConnectionPool.cs (4)
329internal PoolWaitHandles() : base(3*IntPtr.Size) { 351WriteIntPtr(SEMAPHORE_HANDLE*IntPtr.Size, _poolHandle.DangerousGetHandle()); 352WriteIntPtr(ERROR_HANDLE*IntPtr.Size, _errorHandle.DangerousGetHandle()); 353WriteIntPtr(CREATION_HANDLE*IntPtr.Size, _creationHandle.DangerousGetHandle());
System.Drawing (11)
commonui\System\Drawing\Advanced\GraphicsPath.cs (3)
309IntPtr memoryPathData = Marshal.AllocHGlobal(3*IntPtr.Size); 318Marshal.StructureToPtr(memoryPoints, (IntPtr)((long)memoryPathData+IntPtr.Size), false); 319Marshal.StructureToPtr(typesPtr, (IntPtr)((long)memoryPathData+2*IntPtr.Size), false);
commonui\System\Drawing\Icon.cs (2)
759if ((bestImageOffset % IntPtr.Size) != 0) { 905if (IntPtr.Size == 4) {
commonui\System\Drawing\Printing\PrinterSettings.cs (6)
225if (IntPtr.Size == 8) { 226sizeofstruct = (IntPtr.Size * 2) + (Marshal.SizeOf(typeof(int)) * 1) + PADDING_IA64; 229sizeofstruct = (IntPtr.Size * 2) + (Marshal.SizeOf(typeof(int)) * 1); 235sizeofstruct = (IntPtr.Size * 2) + (Marshal.SizeOf(typeof(int)) * 3); 853if (IntPtr.Size == 8) 909if (IntPtr.Size == 8)
System.IdentityModel (2)
System\IdentityModel\SspiWrapper.cs (2)
533int nativeBlockSize = IntPtr.Size; 661int nativeBlockSize = IntPtr.Size;
System.Management (2)
managementobject.cs (2)
1494ppwbemCallResult = Marshal.AllocHGlobal(IntPtr.Size); 1795ppwbemCallResult = Marshal.AllocHGlobal(IntPtr.Size);
System.Messaging (3)
System\Messaging\Interop\Restrictions.cs (2)
55Marshal.WriteIntPtr(restrictionStructure.GetNextValidPtr(16 + IntPtr.Size), (IntPtr)0); 121return 16 + (IntPtr.Size * 2);
System\Messaging\MessageQueue.cs (1)
2046IntPtr stringPointer = Marshal.ReadIntPtr((IntPtr)((long)basePointer + index * IntPtr.Size));
System.Runtime.Caching (1)
System\Caching\CacheMemoryMonitor.cs (1)
80bool is64bit = (IntPtr.Size == 8);
System.Security (1)
system\security\cryptography\pkcs\pkcsutils.cs (1)
834uint cbSize = (uint)IntPtr.Size;
System.ServiceModel (13)
System\ServiceModel\Channels\OverlappedContext.cs (1)
68(IntPtr.Size == 4 ? HandleOffsetFromOverlapped32 : HandleOffsetFromOverlapped64)));
System\ServiceModel\Channels\PnrpPeerResolver.cs (1)
1550Fx.Assert(start % IntPtr.Size == 0, "Invalid alignment!!");
System\ServiceModel\Channels\WebSocketHelper.cs (1)
44static readonly int PropertyBufferSize = ((2 * Marshal.SizeOf(typeof(uint))) + Marshal.SizeOf(typeof(bool))) + IntPtr.Size;
System\ServiceModel\ComIntegration\OuterProxyWrapper.cs (1)
53using (RegistryHandle regKey = RegistryHandle.GetCorrectBitnessHKLMSubkey((IntPtr.Size == 8), ServiceModelInstallStrings.WinFXRegistryKey))
System\ServiceModel\ComIntegration\SafeNativeMethods.cs (8)
638if (is64bit && IntPtr.Size == 8) // No worries we are trying to open up a 64 bit hive just return 640else if (is64bit && IntPtr.Size == 4) // we are running under wow get the 64 bit hive 642else if (!is64bit && IntPtr.Size == 8) // we are running in 64 bit but need to open a 32 bit hive 644else if (!is64bit && IntPtr.Size == 4) 657if (is64bit && IntPtr.Size == 8) // No worries we are trying to open up a 64 bit hive just return 659else if (is64bit && IntPtr.Size == 4) // we are running under wow get the 64 bit hive 661else if (!is64bit && IntPtr.Size == 8) // we are running in 64 bit but need to open a 32 bit hive 663else if (!is64bit && IntPtr.Size == 4)
System\ServiceModel\ComIntegration\TypeCacheManager.cs (1)
398using (RegistryHandle hkcr = RegistryHandle.GetBitnessHKCR(IntPtr.Size == 8 ? false : true))
System.Web (15)
Configuration\IdentitySection.cs (2)
236byte[] bOut = new byte[IntPtr.Size]; 248for (int iter = 0; iter < IntPtr.Size; iter++) {
Configuration\RemoteWebConfigurationHost.cs (1)
481if (IntPtr.Size == 8)
Hosting\ISAPIWorkerRequest.cs (3)
400_size = IntPtr.Size; 465byte[] bytes = new byte[2 * sizeof(long) + IntPtr.Size]; 475if (IntPtr.Size == 4) {
HttpWriter.cs (1)
34internal static readonly int INTEGRATED_MODE_BUFFER_SIZE = 16*1024 - 4*IntPtr.Size; // native buffer size for integrated mode
State\StateWorkerRequest.cs (3)
102Debug.Assert(_contentLength == IntPtr.Size); 406Debug.Assert(length == IntPtr.Size, "length == IntPtr.Size"); 411if (IntPtr.Size == 4) {
Util\altserialization.cs (4)
129if (IntPtr.Size == 4) { 133Debug.Assert(IntPtr.Size == 8); 250if (IntPtr.Size == 4) { 254Debug.Assert(IntPtr.Size == 8);
Util\SystemInfo.cs (1)
35if (IntPtr.Size == 4) {
System.Windows.Forms (17)
winforms\Managed\System\WinForms\AccessibleObject.cs (1)
3004int variantSize = 8 + (IntPtr.Size * 2);
winforms\Managed\System\WinForms\ComponentModel\COM2Interop\BaseCAMarshaler.cs (1)
123addr = Marshal.ReadIntPtr(caArrayAddress, i * IntPtr.Size);
winforms\Managed\System\WinForms\ComponentModel\COM2Interop\COM2Properties.cs (1)
389countOffset = Marshal.SizeOf(typeof(Guid)) + IntPtr.Size + 24;
winforms\Managed\System\WinForms\ImageList.cs (1)
647if (IntPtr.Size == 4) {
winforms\Managed\System\WinForms\MenuItem.cs (3)
928if (IntPtr.Size == 4) { 1014if (IntPtr.Size == 4) { 1052if (IntPtr.Size == 4) {
winforms\Managed\System\WinForms\Printing\PrintDialog.cs (1)
289if (IntPtr.Size == 4) {
winforms\Managed\System\WinForms\RichTextBox.cs (4)
3066if (IntPtr.Size == 8) { 3163if (IntPtr.Size == 8) { 3332if (IntPtr.Size == 8) { 3489if (IntPtr.Size == 8) {
winforms\Managed\System\WinForms\UnsafeNativeMethods.cs (5)
197if (IntPtr.Size == 4) 313if (IntPtr.Size == 4) { 1375if (IntPtr.Size == 4) 1397if (IntPtr.Size == 4) 1414if (IntPtr.Size == 4)
System.Workflow.Runtime (2)
DebugEngine\DebugControllerThread.cs (2)
63if (this.controllerThread.IsAlive && IntPtr.Size == 8) 164if (IntPtr.Size == 8)
UIAutomationClient (1)
MS\Internal\Automation\Misc.cs (1)
439if (IntPtr.Size == 4)
UIAutomationClientsideProviders (1)
MS\Win32\UnsafeNativeMethods.cs (1)
389if (IntPtr.Size == 4)
WindowsBase (6)
Shared\MS\Win32\UnsafeNativeMethodsOther.cs (6)
659if (IntPtr.Size == 4) 682if (IntPtr.Size == 4) 706if (IntPtr.Size == 4) 738if (IntPtr.Size == 4) 775if (IntPtr.Size == 4) 813if (IntPtr.Size == 4)