Esempio n. 1
0
        public override Address GetAddress(ClrAppDomain appDomain)
        {
            if (_containingType == null)
                return 0;

            bool shared = _containingType.Shared;

            IDomainLocalModuleData data = null;
            if (shared)
            {
                Address id = _containingType.DesktopModule.ModuleId;
                data = _containingType.DesktopHeap.DesktopRuntime.GetDomainLocalModule(appDomain.Address, id);
                if (!IsInitialized(data))
                    return 0;
            }
            else
            {
                Address modAddr = _containingType.GetModuleAddress(appDomain);
                if (modAddr != 0)
                    data = _containingType.DesktopHeap.DesktopRuntime.GetDomainLocalModule(modAddr);
            }

            if (data == null)
                return 0;

            Address addr;
            if (DesktopRuntimeBase.IsPrimitive(ElementType))
                addr = data.NonGCStaticDataStart + _field.Offset;
            else
                addr = data.GCStaticDataStart + _field.Offset;

            return addr;
        }
Esempio n. 2
0
 internal DesktopAppDomain(DesktopRuntimeBase runtime, IAppDomainData data, string name)
 {
     _address = data.Address;
     _id      = data.Id;
     _name    = name;
     _runtime = runtime;
 }
Esempio n. 3
0
        private GCDesc FillGCDesc()
        {
            DesktopRuntimeBase runtime = DesktopHeap.DesktopRuntime;

            Debug.Assert(_constructedMT != 0, "Attempted to fill GC desc with a constructed (not real) type.");
            if (!runtime.ReadDword(_constructedMT - (ulong)IntPtr.Size, out int entries))
            {
                return(null);
            }

            // Get entries in map
            if (entries < 0)
            {
                entries = -entries;
            }

            int slots = 1 + entries * 2;

            byte[] buffer = new byte[slots * IntPtr.Size];
            if (!runtime.ReadMemory(_constructedMT - (ulong)(slots * IntPtr.Size), buffer, buffer.Length, out int read) || read != buffer.Length)
            {
                return(null);
            }

            // Construct the gc desc
            return(new GCDesc(buffer));
        }
Esempio n. 4
0
 internal MemoryRegion(DesktopRuntimeBase clr, ulong addr, ulong size, ClrMemoryRegionType type)
 {
     Address  = addr;
     Size     = size;
     _runtime = clr;
     Type     = type;
 }
Esempio n. 5
0
 public DesktopStackFrame(DesktopRuntimeBase runtime, ulong sp, string method)
 {
     m_sp        = sp;
     m_frameName = method;
     m_type      = ClrStackFrameType.Runtime;
     m_runtime   = runtime;
 }
Esempio n. 6
0
        internal static ClrMethod Create(DesktopRuntimeBase runtime, IMethodDescData mdData)
        {
            if (mdData == null)
                return null;

            DesktopModule module = runtime.GetModule(mdData.Module);
            return Create(runtime, module != null ? module.GetMetadataImport() : null, mdData);
        }
Esempio n. 7
0
 public DesktopStackFrame(DesktopRuntimeBase runtime, ulong sp, string method, ClrMethod innerMethod)
 {
     _runtime   = runtime;
     _sp        = sp;
     _frameName = method ?? "Unknown";
     _type      = ClrStackFrameType.Runtime;
     _method    = innerMethod;
 }
Esempio n. 8
0
 internal DesktopAppDomain(DesktopRuntimeBase runtime, IAppDomainData data, string name)
 {
     _address = data.Address;
     _id = data.Id;
     _name = name;
     _internalId = s_internalId++;
     _runtime = runtime;
 }
Esempio n. 9
0
 internal MemoryRegion(DesktopRuntimeBase clr, ulong addr, ulong size, ClrMemoryRegionType type, ClrAppDomain domain)
 {
     Address           = addr;
     Size              = size;
     _runtime          = clr;
     Type              = type;
     _domainModuleHeap = domain.Address;
 }
Esempio n. 10
0
        internal static ClrMethod Create(DesktopRuntimeBase runtime, IMethodDescData mdData)
        {
            if (mdData == null)
                return null;

            DesktopModule module = runtime.GetModule(mdData.Module);
            return Create(runtime, module != null ? module.GetMetadataImport() : null, mdData);
        }
Esempio n. 11
0
 internal DesktopAppDomain(DesktopRuntimeBase runtime, IAppDomainData data, string name)
 {
     _address   = data.Address;
     Id         = data.Id;
     Name       = name;
     InternalId = s_internalId++;
     _runtime   = runtime;
 }
Esempio n. 12
0
 internal DesktopAppDomain(DesktopRuntimeBase runtime, IAppDomainData data, string name)
 {
     m_address    = data.Address;
     m_id         = data.Id;
     m_name       = name;
     m_internalId = s_internalId++;
     m_runtime    = runtime;
 }
Esempio n. 13
0
        public DesktopStackFrame(DesktopRuntimeBase runtime, ulong sp, ulong md)
        {
            _runtime   = runtime;
            _sp        = sp;
            _frameName = _runtime.GetNameForMD(md) ?? "Unknown";
            _type      = ClrStackFrameType.Runtime;

            InitMethod(md);
        }
Esempio n. 14
0
 internal MemoryRegion(DesktopRuntimeBase clr, ulong addr, ulong size, ClrMemoryRegionType type, uint heap, GCSegmentType seg)
 {
     Address           = addr;
     Size              = size;
     _runtime          = clr;
     Type              = type;
     _domainModuleHeap = heap;
     _segmentType      = seg;
 }
Esempio n. 15
0
        public DesktopStackFrame(DesktopRuntimeBase runtime, ulong ip, ulong sp, ulong md)
        {
            _runtime = runtime;
            _ip = ip;
            _sp = sp;
            _frameName = _runtime.GetNameForMD(md) ?? "Unknown";
            _type = ClrStackFrameType.ManagedMethod;

            InitMethod(md);
        }
Esempio n. 16
0
        public override Address GetAddress(ClrAppDomain appDomain, ClrThread thread)
        {
            if (_type == null)
                return 0;

            DesktopRuntimeBase runtime = _type.DesktopHeap.DesktopRuntime;
            IModuleData moduleData = runtime.GetModuleData(_field.Module);

            return runtime.GetThreadStaticPointer(thread.Address, (ClrElementType)_field.CorElementType, (uint)Offset, (uint)moduleData.ModuleId, _type.Shared);
        }
Esempio n. 17
0
 public DesktopStackFrame(DesktopRuntimeBase runtime, DesktopThread thread, byte[] context, ulong sp, string method, ClrMethod innerMethod)
 {
     _runtime     = runtime;
     _thread      = thread;
     _context     = context;
     StackPointer = sp;
     _frameName   = method ?? "Unknown";
     _type        = ClrStackFrameType.Runtime;
     _method      = innerMethod;
 }
Esempio n. 18
0
        public DesktopStackFrame(DesktopRuntimeBase runtime, DesktopThread thread, byte[] context, ulong sp, ulong md)
        {
            _runtime     = runtime;
            _thread      = thread;
            _context     = context;
            StackPointer = sp;
            _frameName   = _runtime.GetNameForMD(md) ?? "Unknown";
            _type        = ClrStackFrameType.Runtime;

            InitMethod(md);
        }
Esempio n. 19
0
        internal static ClrMethod Create(DesktopRuntimeBase runtime, IMethodDescData mdData)
        {
            if (mdData == null)
            {
                return(null);
            }

            DesktopModule module = runtime.GetModule(mdData.Module);

            return(Create(runtime, module?.GetMetadataImport(), mdData));
        }
Esempio n. 20
0
 public DesktopMethod(DesktopRuntimeBase runtime, ulong md, IMethodDescData mdData, MethodAttributes attrs)
 {
     m_runtime = runtime;
     m_sig = runtime.GetNameForMD(md);
     m_ip = mdData.NativeCodeAddr;
     m_jit = mdData.JITType;
     m_attrs = attrs;
     m_token = mdData.MDToken;
     var heap = (DesktopGCHeap)runtime.GetHeap();
     m_type = heap.GetGCHeapType(mdData.MethodTable, 0);
 }
Esempio n. 21
0
        public DesktopStackFrame(DesktopRuntimeBase runtime, DesktopThread thread, ulong ip, ulong sp, ulong md)
        {
            _runtime   = runtime;
            _thread    = thread;
            _ip        = ip;
            _sp        = sp;
            _frameName = _runtime.GetNameForMD(md) ?? "Unknown";
            _type      = ClrStackFrameType.ManagedMethod;

            InitMethod(md);
        }
Esempio n. 22
0
 public DesktopMethod(DesktopRuntimeBase runtime, ulong md, IMethodDescData mdData, MethodAttributes attrs)
 {
     _runtime = runtime;
     _sig = runtime.GetNameForMD(md);
     _ip = mdData.NativeCodeAddr;
     _jit = mdData.JITType;
     _attrs = attrs;
     _token = mdData.MDToken;
     var heap = runtime.GetHeap();
     _type = (DesktopHeapType)heap.GetTypeByMethodTable(mdData.MethodTable, 0);
 }
Esempio n. 23
0
        public override Address GetAddress(ClrAppDomain appDomain, ClrThread thread)
        {
            if (m_type == null)
            {
                return(0);
            }

            DesktopRuntimeBase runtime    = m_type.m_heap.m_runtime;
            IModuleData        moduleData = runtime.GetModuleData(m_field.Module);

            return(runtime.GetThreadStaticPointer(thread.Address, (ClrElementType)m_field.CorElementType, (uint)Offset, (uint)moduleData.ModuleId, m_type.Shared));
        }
Esempio n. 24
0
        public DesktopMethod(DesktopRuntimeBase runtime, ulong md, IMethodDescData mdData, MethodAttributes attrs)
        {
            m_runtime = runtime;
            m_sig     = runtime.GetNameForMD(md);
            m_ip      = mdData.NativeCodeAddr;
            m_jit     = mdData.JITType;
            m_attrs   = attrs;
            m_token   = mdData.MDToken;
            var heap = (DesktopGCHeap)runtime.GetHeap();

            m_type = heap.GetGCHeapType(mdData.MethodTable, 0);
        }
Esempio n. 25
0
 public DesktopThreadPool(DesktopRuntimeBase runtime, IThreadPoolData data)
 {
     m_runtime = runtime;
     m_totalThreads = data.TotalThreads;
     m_runningThreads = data.RunningThreads;
     m_idleThreads = data.IdleThreads;
     m_minThreads = data.MinThreads;
     m_maxThreads = data.MaxThreads;
     m_minCP = data.MinCP;
     m_maxCP = data.MaxCP;
     m_cpu = data.CPU;
     m_freeCP = data.NumFreeCP;
     m_maxFreeCP = data.MaxFreeCP;
 }
Esempio n. 26
0
 public DesktopThreadPool(DesktopRuntimeBase runtime, IThreadPoolData data)
 {
     _runtime                = runtime;
     TotalThreads            = data.TotalThreads;
     RunningThreads          = data.RunningThreads;
     IdleThreads             = data.IdleThreads;
     MinThreads              = data.MinThreads;
     MaxThreads              = data.MaxThreads;
     MinCompletionPorts      = data.MinCP;
     MaxCompletionPorts      = data.MaxCP;
     CpuUtilization          = data.CPU;
     FreeCompletionPortCount = data.NumFreeCP;
     MaxFreeCompletionPorts  = data.MaxFreeCP;
 }
Esempio n. 27
0
        public DesktopModule(DesktopRuntimeBase runtime, IModuleData data, string name, string assemblyName, ulong size)
            : base(runtime)
        {
            Revision      = runtime.Revision;
            _imageBase    = data.ImageBase;
            _assemblyName = assemblyName;
            _isPE         = data.IsPEFile;
            _reflection   = data.IsReflection || string.IsNullOrEmpty(name) || !name.Contains("\\");
            _name         = name;
            ModuleId      = data.ModuleId;
            _size         = size;

            _metadata = data.LegacyMetaDataImport as ICorDebug.IMetadataImport;
        }
Esempio n. 28
0
 public DesktopThreadPool(DesktopRuntimeBase runtime, IThreadPoolData data)
 {
     _runtime        = runtime;
     _totalThreads   = data.TotalThreads;
     _runningThreads = data.RunningThreads;
     _idleThreads    = data.IdleThreads;
     _minThreads     = data.MinThreads;
     _maxThreads     = data.MaxThreads;
     _minCP          = data.MinCP;
     _maxCP          = data.MaxCP;
     _cpu            = data.CPU;
     _freeCP         = data.NumFreeCP;
     _maxFreeCP      = data.MaxFreeCP;
 }
Esempio n. 29
0
        internal static DesktopMethod Create(DesktopRuntimeBase runtime, ICorDebug.IMetadataImport metadata, IMethodDescData mdData)
        {
            if (mdData == null)
            {
                return(null);
            }

            MethodAttributes attrs = 0;

            if (metadata?.GetMethodProps(mdData.MDToken, out int pClass, null, 0, out int methodLength, out attrs, out IntPtr blob, out uint blobLen, out uint codeRva, out uint implFlags) < 0)
            {
                attrs = 0;
            }

            return(new DesktopMethod(runtime, mdData.MethodDesc, mdData, attrs));
        }
Esempio n. 30
0
        public DesktopMethod(DesktopRuntimeBase runtime, ulong md, IMethodDescData mdData, MethodAttributes attrs)
        {
            _runtime        = runtime;
            _sig            = runtime.GetNameForMD(md);
            _ip             = mdData.NativeCodeAddr;
            CompilationType = mdData.JITType;
            _attrs          = attrs;
            _token          = mdData.MDToken;
            GCInfo          = mdData.GCInfo;
            ClrHeap heap = runtime.Heap;

            _type       = (DesktopHeapType)heap.GetTypeByMethodTable(mdData.MethodTable, 0);
            HotColdInfo = new HotColdRegions {
                HotStart = _ip, HotSize = mdData.HotSize, ColdStart = mdData.ColdStart, ColdSize = mdData.ColdSize
            };
        }
Esempio n. 31
0
        internal static DesktopMethod Create(DesktopRuntimeBase runtime, MetaDataImport metadata, IMethodDescData mdData)
        {
            if (mdData == null)
            {
                return(null);
            }

            MethodAttributes attrs = new MethodAttributes();

            if (metadata != null)
            {
                attrs = metadata.GetMethodAttributes((int)mdData.MDToken);
            }

            return(new DesktopMethod(runtime, mdData.MethodDesc, mdData, attrs));
        }
Esempio n. 32
0
        public override ulong GetAddress(ClrAppDomain appDomain)
        {
            if (_containingType == null)
            {
                return(0);
            }

            bool shared = _containingType.Shared;

            IDomainLocalModuleData data = null;

            if (shared)
            {
                ulong id = _containingType.DesktopModule.ModuleId;
                data = _containingType.DesktopHeap.DesktopRuntime.GetDomainLocalModule(appDomain.Address, id);
                if (!IsInitialized(data))
                {
                    return(0);
                }
            }
            else
            {
                ulong modAddr = _containingType.GetModuleAddress(appDomain);
                if (modAddr != 0)
                {
                    data = _containingType.DesktopHeap.DesktopRuntime.GetDomainLocalModule(modAddr);
                }
            }

            if (data == null)
            {
                return(0);
            }

            ulong addr;

            if (DesktopRuntimeBase.IsPrimitive(ElementType))
            {
                addr = data.NonGCStaticDataStart + _field.Offset;
            }
            else
            {
                addr = data.GCStaticDataStart + _field.Offset;
            }

            return(addr);
        }
Esempio n. 33
0
        internal static DesktopMethod Create(DesktopRuntimeBase runtime, ICorDebug.IMetadataImport metadata, IMethodDescData mdData)
        {
            if (mdData == null)
                return null;

            MethodAttributes attrs = (MethodAttributes)0;
            if (metadata != null)
            {
                int pClass, methodLength;
                uint blobLen, codeRva, implFlags;
                IntPtr blob;
                if (metadata.GetMethodProps(mdData.MDToken, out pClass, null, 0, out methodLength, out attrs, out blob, out blobLen, out codeRva, out implFlags) < 0)
                    attrs = (MethodAttributes)0;
            }

            return new DesktopMethod(runtime, mdData.MethodDesc, mdData, attrs);
        }
Esempio n. 34
0
 public DesktopModule(DesktopRuntimeBase runtime, ulong address, IModuleData data, string name, string assemblyName)
     : base(runtime)
 {
     _address        = address;
     Revision        = runtime.Revision;
     ImageBase       = data.ImageBase;
     AssemblyName    = assemblyName;
     _isPE           = data.IsPEFile;
     IsDynamic       = data.IsReflection || string.IsNullOrEmpty(name);
     _name           = name;
     ModuleId        = data.ModuleId;
     ModuleIndex     = data.ModuleIndex;
     MetadataAddress = data.MetdataStart;
     MetadataLength  = data.MetadataLength;
     AssemblyId      = data.Assembly;
     _size           = new Lazy <ulong>(() => runtime.GetModuleSize(address));
 }
Esempio n. 35
0
        internal static DesktopMethod Create(DesktopRuntimeBase runtime, IMetadata metadata, IMethodDescData mdData)
        {
            if (mdData == null)
                return null;

            MethodAttributes attrs = (MethodAttributes)0;
            if (metadata != null)
            {
                int pClass, methodLength;
                uint blobLen, codeRva, implFlags;
                IntPtr blob;
                if (metadata.GetMethodProps(mdData.MDToken, out pClass, null, 0, out methodLength, out attrs, out blob, out blobLen, out codeRva, out implFlags) < 0)
                    attrs = (MethodAttributes)0;
            }

            return new DesktopMethod(runtime, mdData.MethodDesc, mdData, attrs);
        }
Esempio n. 36
0
        public DesktopModule(DesktopRuntimeBase runtime, ulong address, IModuleData data, string name, string assemblyName, ulong size)
            : base(runtime)
        {
            _address         = address;
            Revision         = runtime.Revision;
            _imageBase       = data.ImageBase;
            _assemblyName    = assemblyName;
            _isPE            = data.IsPEFile;
            _reflection      = data.IsReflection || string.IsNullOrEmpty(name) || !name.Contains("\\");
            _name            = name;
            ModuleId         = data.ModuleId;
            ModuleIndex      = data.ModuleIndex;
            _metadataStart   = data.MetdataStart;
            _metadataLength  = data.MetadataLength;
            _assemblyAddress = data.Assembly;
            _size            = size;

            if (!runtime.DataReader.IsMinidump)
            {
                // This is very expensive in the minidump case, as we may be heading out to the symbol server or
                // reading multiple files from disk. Only optimistically fetch this data if we have full memory.
                _metadata = data.LegacyMetaDataImport as ICorDebug.IMetadataImport;
            }
            else
            {
                // If we are a minidump and metadata isn't mapped in, attempt to fetch this module from the symbol server
                // on a background thread.
#if !V2_SUPPORT
                if (_isPE && _metadataStart != 0 && _metadataLength > 0)
                {
                    int    read;
                    byte[] tmp = new byte[1];
                    if (!_runtime.DataReader.ReadMemory(_metadataStart, tmp, 1, out read) || read == 0)
                    {
                        int filesize, imagesize;
                        if (PEFile.TryGetIndexProperties(new ReadVirtualStream(_runtime.DataReader, (long)data.ImageBase, (long)size), true, out imagesize, out filesize))
                        {
                            _runtime.DataTarget.SymbolLocator.PrefetchBinary(Path.GetFileName(assemblyName), imagesize, filesize);
                        }
                    }
                }
#endif
            }
        }
Esempio n. 37
0
        public DesktopModule(DesktopRuntimeBase runtime, ulong address, IModuleData data, string name, string assemblyName, ulong size)
            : base(runtime)
        {
            Revision = runtime.Revision;
            _imageBase = data.ImageBase;
            _assemblyName = assemblyName;
            _isPE = data.IsPEFile;
            _reflection = data.IsReflection || string.IsNullOrEmpty(name) || !name.Contains("\\");
            _name = name;
            ModuleId = data.ModuleId;
            ModuleIndex = data.ModuleIndex;
            _metadataStart = data.MetdataStart;
            _metadataLength = data.MetadataLength;
            _assemblyAddress = data.Assembly;
            _size = size;

            if (!runtime.DataReader.IsMinidump)
            {
                // This is very expensive in the minidump case, as we may be heading out to the symbol server or
                // reading multiple files from disk. Only optimistically fetch this data if we have full memory.
                _metadata = data.LegacyMetaDataImport as ICorDebug.IMetadataImport;
            }
            else
            {
                // If we are a minidump and metadata isn't mapped in, attempt to fetch this module from the symbol server
                // on a background thread.
#if !V2_SUPPORT
                if (_isPE && _metadataStart != 0 && _metadataLength > 0)
                {
                    int read;
                    byte[] tmp = new byte[1];
                    if (!_runtime.DataReader.ReadMemory(_metadataStart, tmp, 1, out read) || read == 0)
                    {
                        int filesize, imagesize;
                        if (PEFile.TryGetIndexProperties(new ReadVirtualStream(_runtime.DataReader, (long)data.ImageBase, (long)size), true, out imagesize, out filesize))
                            _runtime.DataTarget.SymbolLocator.PrefetchBinary(Path.GetFileName(assemblyName), imagesize, filesize);
                    }
                }
#endif
            }
        }
Esempio n. 38
0
 internal MemoryRegion(DesktopRuntimeBase clr, ulong addr, ulong size, ClrMemoryRegionType type)
 {
     Address = addr;
     Size = size;
     _runtime = clr;
     Type = type;
 }
Esempio n. 39
0
        public DesktopStackFrame(DesktopRuntimeBase runtime, DesktopThread thread, ulong sp, ulong md)
        {
            _runtime = runtime;
            _thread = thread;
            _sp = sp;
            _frameName = _runtime.GetNameForMD(md) ?? "Unknown";
            _type = ClrStackFrameType.Runtime;

            InitMethod(md);
        }
Esempio n. 40
0
     public DesktopBaseModule(DesktopRuntimeBase runtime)
     {
         _runtime = runtime;
 }
Esempio n. 41
0
 public ErrorModule(DesktopRuntimeBase runtime)
     : base(runtime)
 {
 }
Esempio n. 42
0
 public HandleTableWalker(DesktopRuntimeBase dac)
 {
     m_runtime = dac;
     m_heap = dac.GetHeap();
     Handles = new List<ClrHandle>();
 }
Esempio n. 43
0
        internal override bool TraverseHeap(ulong heap, DesktopRuntimeBase.LoaderHeapTraverse callback)
        {
            byte[] input = new byte[sizeof(ulong) * 2];
            WriteValueToBuffer(heap, input, 0);
            WriteValueToBuffer(Marshal.GetFunctionPointerForDelegate(callback), input, sizeof(ulong));

            return Request(DacRequests.LOADERHEAP_TRAVERSE, input, null);
        }
Esempio n. 44
0
 public DesktopStackFrame(DesktopRuntimeBase runtime, ulong sp, string method, ClrMethod innerMethod)
 {
     _runtime = runtime;
     _sp = sp;
     _frameName = method ?? "Unknown";
     _type = ClrStackFrameType.Runtime;
     _method = innerMethod;
 }
Esempio n. 45
0
 public DesktopStackFrame(DesktopRuntimeBase runtime, ulong sp, string method, ClrMethod innerMethod)
 {
     m_sp = sp;
     m_frameName = method;
     m_type = ClrStackFrameType.Runtime;
     m_method = innerMethod;
     m_runtime = runtime;
 }
Esempio n. 46
0
 public DesktopStackFrame(DesktopRuntimeBase runtime, ulong ip, ulong sp, string method)
 {
     m_ip = ip;
     m_sp = sp;
     m_frameName = method;
     m_type = ClrStackFrameType.ManagedMethod;
     m_runtime = runtime;
 }
Esempio n. 47
0
        public DesktopModule(DesktopRuntimeBase runtime, ulong address, IModuleData data, string name, string assemblyName, ulong size)
        {
            Revision = runtime.Revision;
            _imageBase = data.ImageBase;
            _runtime = runtime;
            _assemblyName = assemblyName;
            _isPE = data.IsPEFile;
            _reflection = data.IsReflection || string.IsNullOrEmpty(name) || !name.Contains("\\");
            _name = name;
            ModuleId = data.ModuleId;
            ModuleIndex = data.ModuleIndex;
            _metadataStart = data.MetdataStart;
            _metadataLength = data.MetadataLength;
            _assemblyAddress = data.Assembly;
            _address = address;
            _size = size;

            // This is very expensive in the minidump case, as we may be heading out to the symbol server or
            // reading multiple files from disk. Only optimistically fetch this data if we have full memory.
            if (!runtime.DataReader.IsMinidump)
                _metadata = data.LegacyMetaDataImport as IMetadata;
        }
Esempio n. 48
0
 public AppDomainHeapWalker(DesktopRuntimeBase runtime)
 {
     mRuntime = runtime;
     mDelegate = new DesktopRuntimeBase.LoaderHeapTraverse(VisitOneHeap);
 }
Esempio n. 49
0
 internal MemoryRegion(DesktopRuntimeBase clr, ulong addr, ulong size, ClrMemoryRegionType type, ClrAppDomain domain)
 {
     Address = addr;
     Size = size;
     _runtime = clr;
     Type = type;
     _domainModuleHeap = domain.Address;
 }
Esempio n. 50
0
 internal override bool TraverseHeap(ulong heap, DesktopRuntimeBase.LoaderHeapTraverse callback)
 {
     bool res = _sos.TraverseLoaderHeap(heap, Marshal.GetFunctionPointerForDelegate(callback)) >= 0;
     GC.KeepAlive(callback);
     return res;
 }
Esempio n. 51
0
 internal MemoryRegion(DesktopRuntimeBase clr, ulong addr, ulong size, ClrMemoryRegionType type, uint heap, GCSegmentType seg)
 {
     Address = addr;
     Size = size;
     _runtime = clr;
     Type = type;
     _domainModuleHeap = heap;
     _segmentType = seg;
 }
Esempio n. 52
0
 internal LockInspection(DesktopGCHeap heap, DesktopRuntimeBase runtime)
 {
     _heap = heap;
     _runtime = runtime;
 }
Esempio n. 53
0
 internal override bool TraverseStubHeap(ulong appDomain, int type, DesktopRuntimeBase.LoaderHeapTraverse callback)
 {
     bool res = _sos.TraverseVirtCallStubHeap(appDomain, (uint)type, Marshal.GetFunctionPointerForDelegate(callback)) >= 0;
     GC.KeepAlive(callback);
     return res;
 }
Esempio n. 54
0
 internal DesktopThread(DesktopRuntimeBase clr, IThreadData thread, ulong address, bool finalizer)
     : base(thread, address, finalizer)
 {
     _runtime = clr;
 }