4 instantiations of GCHandle
PresentationCore (1)
System.Private.CoreLib (3)
396 references to GCHandle
Microsoft.AspNetCore.Server.HttpSys (7)
Microsoft.AspNetCore.Server.IIS (15)
Microsoft.CodeAnalysis.CSharp.Workspaces.UnitTests (1)
Microsoft.CodeAnalysis.EditorFeatures.Test.Utilities (1)
Microsoft.CodeAnalysis.Test.Utilities (2)
Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests (1)
Microsoft.CodeAnalysis.VisualBasic.Workspaces.UnitTests (1)
Microsoft.ML.LightGbm (6)
Microsoft.ML.Mkl.Components (12)
SymSgdClassificationTrainer.cs (12)
341public GCHandle GcHandle;
346GcHandle = GCHandle.Alloc(Buffer, GCHandleType.Pinned);
487public void GiveArrayOfSize(int size, out GCHandle? outGcHandle, out int outArrayStartIndex)
663public bool GiveNextInstance(out InstanceProperties? prop, out GCHandle? indicesGcHandle, out int indicesStartIndex,
664out GCHandle? valuesGcHandle, out int valuesStartIndex)
736GCHandle stateGCHandle = default;
739stateGCHandle = GCHandle.Alloc(state, GCHandleType.Pinned);
863int numThreads, bool tuneNumLocIter, ref int numLocIter, float tolerance, bool needShuffle, bool shouldInitialize, GCHandle stateGCHandle, ChannelCallBack info)
878while (inputDataManager.GiveNextInstance(out InstanceProperties? prop, out GCHandle? indicesGcHandle, out int indicesStartIndex, out GCHandle? valuesGcHandle, out int valuesStartIndex))
917public static void MapBackWeightVector(Span<float> weightVector, GCHandle stateGCHandle)
926public static void DeallocateSequentially(GCHandle stateGCHandle)
Microsoft.ML.Vision (4)
Microsoft.NET.StringTools (2)
Microsoft.NET.StringTools.net35 (2)
Microsoft.VisualStudio.LanguageServices (5)
Microsoft.VisualStudio.LanguageServices.Test.Utilities2 (2)
mscorlib (1)
netstandard (1)
PresentationCore (23)
PresentationFramework (12)
Roslyn.Test.PdbUtilities (4)
System.Net.Quic (34)
System.Net.Requests (2)
System.Net.Security (12)
System.Net.Sockets (12)
System.Numerics.Tensors (2)
System.Private.CoreLib (146)
src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\ComWrappers.cs (25)
229return Unsafe.As<ManagedObjectWrapperHolder>(GCHandle.FromIntPtr(handle).Target);
373GCHandle.InternalFree(handle);
509if (refCountedHandle != IntPtr.Zero && GCHandle.InternalGet(refCountedHandle) != null)
539private GCHandle _proxyHandle;
540private GCHandle _proxyHandleTrackingResurrection;
585_proxyHandle = GCHandle.Alloc(comProxy, GCHandleType.Weak);
592_proxyHandleTrackingResurrection = GCHandle.Alloc(comProxy, GCHandleType.WeakTrackResurrection);
608internal GCHandle ProxyHandle => _proxyHandle;
661internal readonly GCHandle _nativeObjectWrapperWeakHandle;
693_nativeObjectWrapperWeakHandle = GCHandle.Alloc(this, GCHandleType.Weak);
1282private readonly Dictionary<IntPtr, GCHandle> _cache = [];
1296ref GCHandle rcwEntry = ref CollectionsMarshal.GetValueRefOrAddDefault(_cache, comPointer, out bool exists);
1301rcwEntry = GCHandle.Alloc(wrapper, GCHandleType.Weak);
1334if (_cache.TryGetValue(comPointer, out GCHandle existingHandle))
1360if (_cache.TryGetValue(comPointer, out GCHandle cachedRef)
1596internal sealed class GCHandleSet : IEnumerable<GCHandle>
1606public void Add(GCHandle handle)
1680public void Remove(GCHandle handle)
1709private static int GetBucket(GCHandle handle, int numBuckets)
1717IEnumerator<GCHandle> IEnumerable<GCHandle>.GetEnumerator() => GetEnumerator();
1719IEnumerator IEnumerable.GetEnumerator() => ((IEnumerable<GCHandle>)this).GetEnumerator();
1724public GCHandle _value;
1727public struct Enumerator : IEnumerator<GCHandle>
1742public GCHandle Current
System.Private.Windows.Core (19)
System.Reflection.Metadata (5)
System.Resources.Extensions (2)
System.Runtime (1)
System.Runtime.Caching (2)
System.Runtime.InteropServices (1)
System.Security.Cryptography (2)
System.Windows.Forms (22)
System.Windows.Forms.Primitives (4)
System.Windows.Forms.Primitives.TestUtilities (4)
System.Windows.Forms.TestUtilities (4)
TlsFeaturesObserve (6)
UIAutomationClient (8)
UIAutomationClientSideProviders (6)