File: _generated\42\Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13.cs
Web Access
Project: src\src\runtime\src\native\managed\cdac\Microsoft.Diagnostics.DataContractReader.Legacy\Microsoft.Diagnostics.DataContractReader.Legacy.csproj (Microsoft.Diagnostics.DataContractReader.Legacy)
// <auto-generated />
#pragma warning disable CS0612, CS0618, CS0649, CS1591

[global::System.Runtime.InteropServices.StructLayoutAttribute(global::System.Runtime.InteropServices.LayoutKind.Sequential)]
file unsafe struct InterfaceImplementationVtable
{
    public delegate* unmanaged[MemberFunction]<void*, global::System.Guid*, void**, int> QueryInterface_0;
    public delegate* unmanaged[MemberFunction]<void*, uint> AddRef_1;
    public delegate* unmanaged[MemberFunction]<void*, uint> Release_2;
    public delegate* unmanaged[MemberFunction]<global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch*, ulong, int, delegate* unmanaged<ulong, nuint, global::Microsoft.Diagnostics.DataContractReader.Legacy.Interop.BOOL, void> , int> TraverseLoaderHeap_3;
    public delegate* unmanaged[MemberFunction]<global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch*, ulong, global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress*, int> GetDomainLoaderAllocator_4;
    public delegate* unmanaged[MemberFunction]<global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch*, int, char**, int*, int> GetLoaderAllocatorHeapNames_5;
    public delegate* unmanaged[MemberFunction]<global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch*, ulong, int, global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress*, int*, int*, int> GetLoaderAllocatorHeaps_6;
    public delegate* unmanaged[MemberFunction]<global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch*, void**, int> GetHandleTableMemoryRegions_7;
    public delegate* unmanaged[MemberFunction]<global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch*, void**, int> GetGCBookkeepingMemoryRegions_8;
    public delegate* unmanaged[MemberFunction]<global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch*, void**, int> GetGCFreeRegions_9;
    public delegate* unmanaged[MemberFunction]<global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch*, int> LockedFlush_10;
}

file unsafe sealed class InterfaceInformation : global::System.Runtime.InteropServices.Marshalling.IIUnknownInterfaceType
{
    public static global::System.Guid Iid { get; } = new([237, 168, 118, 49, 123, 89, 84, 79, 167, 31, 131, 105, 92, 106, 140, 94]);
    public static void** ManagedVirtualMethodTable => (void**)global::System.Runtime.CompilerServices.Unsafe.AsPointer(in InterfaceImplementation.Vtable);
}

[global::System.Runtime.InteropServices.DynamicInterfaceCastableImplementationAttribute]
file unsafe interface InterfaceImplementation : global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13
{
    [global::System.Runtime.CompilerServices.FixedAddressValueTypeAttribute]
    public static readonly InterfaceImplementationVtable Vtable;

    static InterfaceImplementation()
    {
        global::System.Runtime.InteropServices.ComWrappers.GetIUnknownImpl(
            out *(nint*)&((InterfaceImplementationVtable*)global::System.Runtime.CompilerServices.Unsafe.AsPointer(ref Vtable))->QueryInterface_0,
            out *(nint*)&((InterfaceImplementationVtable*)global::System.Runtime.CompilerServices.Unsafe.AsPointer(ref Vtable))->AddRef_1,
            out *(nint*)&((InterfaceImplementationVtable*)global::System.Runtime.CompilerServices.Unsafe.AsPointer(ref Vtable))->Release_2);

        Vtable.TraverseLoaderHeap_3 = &ABI_TraverseLoaderHeap;
        Vtable.GetDomainLoaderAllocator_4 = &ABI_GetDomainLoaderAllocator;
        Vtable.GetLoaderAllocatorHeapNames_5 = &ABI_GetLoaderAllocatorHeapNames;
        Vtable.GetLoaderAllocatorHeaps_6 = &ABI_GetLoaderAllocatorHeaps;
        Vtable.GetHandleTableMemoryRegions_7 = &ABI_GetHandleTableMemoryRegions;
        Vtable.GetGCBookkeepingMemoryRegions_8 = &ABI_GetGCBookkeepingMemoryRegions;
        Vtable.GetGCFreeRegions_9 = &ABI_GetGCFreeRegions;
        Vtable.LockedFlush_10 = &ABI_LockedFlush;
    }

    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.Interop.ComInterfaceGenerator", "11.0.14.22804")]
    [global::System.Runtime.CompilerServices.SkipLocalsInitAttribute]
    int global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13.TraverseLoaderHeap(global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress loaderHeapAddr, int kind, delegate* unmanaged<ulong, nuint, global::Microsoft.Diagnostics.DataContractReader.Legacy.Interop.BOOL, void> pCallback)
    {
        var(__this, __vtable) = ((global::System.Runtime.InteropServices.Marshalling.IUnmanagedVirtualMethodTableProvider)this).GetVirtualMethodTableInfoForKey(typeof(global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13));
        var __target = ((delegate* unmanaged[MemberFunction]<void*, ulong, int, delegate* unmanaged<ulong, nuint, global::Microsoft.Diagnostics.DataContractReader.Legacy.Interop.BOOL, void> , int> )__vtable[3]);
        {
            ulong __loaderHeapAddr_native;
            int __retVal;
            // Marshal - Convert managed data to native data.
            __loaderHeapAddr_native = global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddressMarshaller.ConvertToUnmanaged(loaderHeapAddr);
            {
                __retVal = __target(__this, __loaderHeapAddr_native, kind, pCallback);
            }
    
            // NotifyForSuccessfulInvoke - Keep alive any managed objects that need to stay alive across the call.
            global::System.GC.KeepAlive(this);
            return __retVal;
        }
    }

    [global::System.Runtime.InteropServices.UnmanagedCallersOnlyAttribute(CallConvs = new[] { typeof(global::System.Runtime.CompilerServices.CallConvMemberFunction) })]
    internal static int ABI_TraverseLoaderHeap(global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch* __this_native, ulong __loaderHeapAddr_native, int kind, delegate* unmanaged<ulong, nuint, global::Microsoft.Diagnostics.DataContractReader.Legacy.Interop.BOOL, void> pCallback)
    {
        global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13 @this = default;
        global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress loaderHeapAddr = default;
        int __retVal = default;
        try
        {
            // Unmarshal - Convert native data to managed data.
            loaderHeapAddr = global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddressMarshaller.ConvertToManaged(__loaderHeapAddr_native);
            @this = global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch.GetInstance<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13>(__this_native);
            __retVal = @this.TraverseLoaderHeap(loaderHeapAddr, kind, pCallback);
        }
        catch (global::System.Exception __exception)
        {
            __retVal = global::System.Runtime.InteropServices.Marshalling.ExceptionAsHResultMarshaller<int>.ConvertToUnmanaged(__exception);
        }
    
        return __retVal;
    }

    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.Interop.ComInterfaceGenerator", "11.0.14.22804")]
    [global::System.Runtime.CompilerServices.SkipLocalsInitAttribute]
    int global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13.GetDomainLoaderAllocator(global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress domainAddress, global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress* pLoaderAllocator)
    {
        var(__this, __vtable) = ((global::System.Runtime.InteropServices.Marshalling.IUnmanagedVirtualMethodTableProvider)this).GetVirtualMethodTableInfoForKey(typeof(global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13));
        var __target = ((delegate* unmanaged[MemberFunction]<void*, ulong, global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress*, int> )__vtable[4]);
        {
            ulong __domainAddress_native;
            int __retVal;
            // Marshal - Convert managed data to native data.
            __domainAddress_native = global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddressMarshaller.ConvertToUnmanaged(domainAddress);
            {
                __retVal = __target(__this, __domainAddress_native, pLoaderAllocator);
            }
    
            // NotifyForSuccessfulInvoke - Keep alive any managed objects that need to stay alive across the call.
            global::System.GC.KeepAlive(this);
            return __retVal;
        }
    }

    [global::System.Runtime.InteropServices.UnmanagedCallersOnlyAttribute(CallConvs = new[] { typeof(global::System.Runtime.CompilerServices.CallConvMemberFunction) })]
    internal static int ABI_GetDomainLoaderAllocator(global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch* __this_native, ulong __domainAddress_native, global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress* pLoaderAllocator)
    {
        global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13 @this = default;
        global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress domainAddress = default;
        int __retVal = default;
        try
        {
            // Unmarshal - Convert native data to managed data.
            domainAddress = global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddressMarshaller.ConvertToManaged(__domainAddress_native);
            @this = global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch.GetInstance<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13>(__this_native);
            __retVal = @this.GetDomainLoaderAllocator(domainAddress, pLoaderAllocator);
        }
        catch (global::System.Exception __exception)
        {
            __retVal = global::System.Runtime.InteropServices.Marshalling.ExceptionAsHResultMarshaller<int>.ConvertToUnmanaged(__exception);
        }
    
        return __retVal;
    }

    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.Interop.ComInterfaceGenerator", "11.0.14.22804")]
    [global::System.Runtime.CompilerServices.SkipLocalsInitAttribute]
    int global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13.GetLoaderAllocatorHeapNames(int count, char** ppNames, int* pNeeded)
    {
        var(__this, __vtable) = ((global::System.Runtime.InteropServices.Marshalling.IUnmanagedVirtualMethodTableProvider)this).GetVirtualMethodTableInfoForKey(typeof(global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13));
        var __target = ((delegate* unmanaged[MemberFunction]<void*, int, char**, int*, int> )__vtable[5]);
        {
            int __retVal;
            {
                __retVal = __target(__this, count, ppNames, pNeeded);
            }
    
            // NotifyForSuccessfulInvoke - Keep alive any managed objects that need to stay alive across the call.
            global::System.GC.KeepAlive(this);
            return __retVal;
        }
    }

    [global::System.Runtime.InteropServices.UnmanagedCallersOnlyAttribute(CallConvs = new[] { typeof(global::System.Runtime.CompilerServices.CallConvMemberFunction) })]
    internal static int ABI_GetLoaderAllocatorHeapNames(global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch* __this_native, int count, char** ppNames, int* pNeeded)
    {
        global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13 @this = default;
        int __retVal = default;
        try
        {
            // Unmarshal - Convert native data to managed data.
            @this = global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch.GetInstance<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13>(__this_native);
            __retVal = @this.GetLoaderAllocatorHeapNames(count, ppNames, pNeeded);
        }
        catch (global::System.Exception __exception)
        {
            __retVal = global::System.Runtime.InteropServices.Marshalling.ExceptionAsHResultMarshaller<int>.ConvertToUnmanaged(__exception);
        }
    
        return __retVal;
    }

    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.Interop.ComInterfaceGenerator", "11.0.14.22804")]
    [global::System.Runtime.CompilerServices.SkipLocalsInitAttribute]
    int global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13.GetLoaderAllocatorHeaps(global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress loaderAllocator, int count, global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress* pLoaderHeaps, int* pKinds, int* pNeeded)
    {
        var(__this, __vtable) = ((global::System.Runtime.InteropServices.Marshalling.IUnmanagedVirtualMethodTableProvider)this).GetVirtualMethodTableInfoForKey(typeof(global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13));
        var __target = ((delegate* unmanaged[MemberFunction]<void*, ulong, int, global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress*, int*, int*, int> )__vtable[6]);
        {
            ulong __loaderAllocator_native;
            int __retVal;
            // Marshal - Convert managed data to native data.
            __loaderAllocator_native = global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddressMarshaller.ConvertToUnmanaged(loaderAllocator);
            {
                __retVal = __target(__this, __loaderAllocator_native, count, pLoaderHeaps, pKinds, pNeeded);
            }
    
            // NotifyForSuccessfulInvoke - Keep alive any managed objects that need to stay alive across the call.
            global::System.GC.KeepAlive(this);
            return __retVal;
        }
    }

    [global::System.Runtime.InteropServices.UnmanagedCallersOnlyAttribute(CallConvs = new[] { typeof(global::System.Runtime.CompilerServices.CallConvMemberFunction) })]
    internal static int ABI_GetLoaderAllocatorHeaps(global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch* __this_native, ulong __loaderAllocator_native, int count, global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress* pLoaderHeaps, int* pKinds, int* pNeeded)
    {
        global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13 @this = default;
        global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddress loaderAllocator = default;
        int __retVal = default;
        try
        {
            // Unmarshal - Convert native data to managed data.
            loaderAllocator = global::Microsoft.Diagnostics.DataContractReader.Legacy.ClrDataAddressMarshaller.ConvertToManaged(__loaderAllocator_native);
            @this = global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch.GetInstance<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13>(__this_native);
            __retVal = @this.GetLoaderAllocatorHeaps(loaderAllocator, count, pLoaderHeaps, pKinds, pNeeded);
        }
        catch (global::System.Exception __exception)
        {
            __retVal = global::System.Runtime.InteropServices.Marshalling.ExceptionAsHResultMarshaller<int>.ConvertToUnmanaged(__exception);
        }
    
        return __retVal;
    }

    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.Interop.ComInterfaceGenerator", "11.0.14.22804")]
    [global::System.Runtime.CompilerServices.SkipLocalsInitAttribute]
    int global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13.GetHandleTableMemoryRegions(global::Microsoft.Diagnostics.DataContractReader.Legacy.DacComNullableByRef<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMemoryEnum> ppEnum)
    {
        var(__this, __vtable) = ((global::System.Runtime.InteropServices.Marshalling.IUnmanagedVirtualMethodTableProvider)this).GetVirtualMethodTableInfoForKey(typeof(global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13));
        var __target = ((delegate* unmanaged[MemberFunction]<void*, void**, int> )__vtable[7]);
        {
            void** __ppEnum_native = default;
            int __retVal = default;
            // Setup - Perform required setup.
            global::Microsoft.Diagnostics.DataContractReader.Legacy.DacComNullableByRefMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMemoryEnum>.ManagedToUnmanaged __ppEnum_native__marshaller = new();
            try
            {
                // Marshal - Convert managed data to native data.
                __ppEnum_native__marshaller.FromManaged(ppEnum);
                {
                    // PinnedMarshal - Convert managed data to native data that requires the managed data to be pinned.
                    __ppEnum_native = __ppEnum_native__marshaller.ToUnmanaged();
                    __retVal = __target(__this, __ppEnum_native);
                }
    
                // NotifyForSuccessfulInvoke - Keep alive any managed objects that need to stay alive across the call.
                __ppEnum_native__marshaller.OnInvoked();
                global::System.GC.KeepAlive(this);
            }
            finally
            {
                // CleanupCallerAllocated - Perform cleanup of caller allocated resources.
                __ppEnum_native__marshaller.Free();
            }
    
            return __retVal;
        }
    }

    [global::System.Runtime.InteropServices.UnmanagedCallersOnlyAttribute(CallConvs = new[] { typeof(global::System.Runtime.CompilerServices.CallConvMemberFunction) })]
    internal static int ABI_GetHandleTableMemoryRegions(global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch* __this_native, void** __ppEnum_native)
    {
        global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13 @this = default;
        global::Microsoft.Diagnostics.DataContractReader.Legacy.DacComNullableByRef<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMemoryEnum> ppEnum = default;
        int __retVal = default;
        // Setup - Perform required setup.
        global::Microsoft.Diagnostics.DataContractReader.Legacy.DacComNullableByRefMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMemoryEnum>.UnmanagedToManaged __ppEnum_native__marshaller = new();
        try
        {
            // UnmarshalCapture - Capture the native data into marshaller instances in case conversion to managed data throws an exception.
            __ppEnum_native__marshaller.FromUnmanaged(__ppEnum_native);
            // Unmarshal - Convert native data to managed data.
            ppEnum = __ppEnum_native__marshaller.ToManaged();
            @this = global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch.GetInstance<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13>(__this_native);
            __retVal = @this.GetHandleTableMemoryRegions(ppEnum);
        }
        catch (global::System.Exception __exception)
        {
            __retVal = global::System.Runtime.InteropServices.Marshalling.ExceptionAsHResultMarshaller<int>.ConvertToUnmanaged(__exception);
        }
        finally
        {
            // CleanupCallerAllocated - Perform cleanup of caller allocated resources.
            __ppEnum_native__marshaller.Free();
        }
    
        return __retVal;
    }

    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.Interop.ComInterfaceGenerator", "11.0.14.22804")]
    [global::System.Runtime.CompilerServices.SkipLocalsInitAttribute]
    int global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13.GetGCBookkeepingMemoryRegions(global::Microsoft.Diagnostics.DataContractReader.Legacy.DacComNullableByRef<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMemoryEnum> ppEnum)
    {
        var(__this, __vtable) = ((global::System.Runtime.InteropServices.Marshalling.IUnmanagedVirtualMethodTableProvider)this).GetVirtualMethodTableInfoForKey(typeof(global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13));
        var __target = ((delegate* unmanaged[MemberFunction]<void*, void**, int> )__vtable[8]);
        {
            void** __ppEnum_native = default;
            int __retVal = default;
            // Setup - Perform required setup.
            global::Microsoft.Diagnostics.DataContractReader.Legacy.DacComNullableByRefMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMemoryEnum>.ManagedToUnmanaged __ppEnum_native__marshaller = new();
            try
            {
                // Marshal - Convert managed data to native data.
                __ppEnum_native__marshaller.FromManaged(ppEnum);
                {
                    // PinnedMarshal - Convert managed data to native data that requires the managed data to be pinned.
                    __ppEnum_native = __ppEnum_native__marshaller.ToUnmanaged();
                    __retVal = __target(__this, __ppEnum_native);
                }
    
                // NotifyForSuccessfulInvoke - Keep alive any managed objects that need to stay alive across the call.
                __ppEnum_native__marshaller.OnInvoked();
                global::System.GC.KeepAlive(this);
            }
            finally
            {
                // CleanupCallerAllocated - Perform cleanup of caller allocated resources.
                __ppEnum_native__marshaller.Free();
            }
    
            return __retVal;
        }
    }

    [global::System.Runtime.InteropServices.UnmanagedCallersOnlyAttribute(CallConvs = new[] { typeof(global::System.Runtime.CompilerServices.CallConvMemberFunction) })]
    internal static int ABI_GetGCBookkeepingMemoryRegions(global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch* __this_native, void** __ppEnum_native)
    {
        global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13 @this = default;
        global::Microsoft.Diagnostics.DataContractReader.Legacy.DacComNullableByRef<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMemoryEnum> ppEnum = default;
        int __retVal = default;
        // Setup - Perform required setup.
        global::Microsoft.Diagnostics.DataContractReader.Legacy.DacComNullableByRefMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMemoryEnum>.UnmanagedToManaged __ppEnum_native__marshaller = new();
        try
        {
            // UnmarshalCapture - Capture the native data into marshaller instances in case conversion to managed data throws an exception.
            __ppEnum_native__marshaller.FromUnmanaged(__ppEnum_native);
            // Unmarshal - Convert native data to managed data.
            ppEnum = __ppEnum_native__marshaller.ToManaged();
            @this = global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch.GetInstance<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13>(__this_native);
            __retVal = @this.GetGCBookkeepingMemoryRegions(ppEnum);
        }
        catch (global::System.Exception __exception)
        {
            __retVal = global::System.Runtime.InteropServices.Marshalling.ExceptionAsHResultMarshaller<int>.ConvertToUnmanaged(__exception);
        }
        finally
        {
            // CleanupCallerAllocated - Perform cleanup of caller allocated resources.
            __ppEnum_native__marshaller.Free();
        }
    
        return __retVal;
    }

    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.Interop.ComInterfaceGenerator", "11.0.14.22804")]
    [global::System.Runtime.CompilerServices.SkipLocalsInitAttribute]
    int global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13.GetGCFreeRegions(global::Microsoft.Diagnostics.DataContractReader.Legacy.DacComNullableByRef<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMemoryEnum> ppEnum)
    {
        var(__this, __vtable) = ((global::System.Runtime.InteropServices.Marshalling.IUnmanagedVirtualMethodTableProvider)this).GetVirtualMethodTableInfoForKey(typeof(global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13));
        var __target = ((delegate* unmanaged[MemberFunction]<void*, void**, int> )__vtable[9]);
        {
            void** __ppEnum_native = default;
            int __retVal = default;
            // Setup - Perform required setup.
            global::Microsoft.Diagnostics.DataContractReader.Legacy.DacComNullableByRefMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMemoryEnum>.ManagedToUnmanaged __ppEnum_native__marshaller = new();
            try
            {
                // Marshal - Convert managed data to native data.
                __ppEnum_native__marshaller.FromManaged(ppEnum);
                {
                    // PinnedMarshal - Convert managed data to native data that requires the managed data to be pinned.
                    __ppEnum_native = __ppEnum_native__marshaller.ToUnmanaged();
                    __retVal = __target(__this, __ppEnum_native);
                }
    
                // NotifyForSuccessfulInvoke - Keep alive any managed objects that need to stay alive across the call.
                __ppEnum_native__marshaller.OnInvoked();
                global::System.GC.KeepAlive(this);
            }
            finally
            {
                // CleanupCallerAllocated - Perform cleanup of caller allocated resources.
                __ppEnum_native__marshaller.Free();
            }
    
            return __retVal;
        }
    }

    [global::System.Runtime.InteropServices.UnmanagedCallersOnlyAttribute(CallConvs = new[] { typeof(global::System.Runtime.CompilerServices.CallConvMemberFunction) })]
    internal static int ABI_GetGCFreeRegions(global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch* __this_native, void** __ppEnum_native)
    {
        global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13 @this = default;
        global::Microsoft.Diagnostics.DataContractReader.Legacy.DacComNullableByRef<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMemoryEnum> ppEnum = default;
        int __retVal = default;
        // Setup - Perform required setup.
        global::Microsoft.Diagnostics.DataContractReader.Legacy.DacComNullableByRefMarshaller<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSMemoryEnum>.UnmanagedToManaged __ppEnum_native__marshaller = new();
        try
        {
            // UnmarshalCapture - Capture the native data into marshaller instances in case conversion to managed data throws an exception.
            __ppEnum_native__marshaller.FromUnmanaged(__ppEnum_native);
            // Unmarshal - Convert native data to managed data.
            ppEnum = __ppEnum_native__marshaller.ToManaged();
            @this = global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch.GetInstance<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13>(__this_native);
            __retVal = @this.GetGCFreeRegions(ppEnum);
        }
        catch (global::System.Exception __exception)
        {
            __retVal = global::System.Runtime.InteropServices.Marshalling.ExceptionAsHResultMarshaller<int>.ConvertToUnmanaged(__exception);
        }
        finally
        {
            // CleanupCallerAllocated - Perform cleanup of caller allocated resources.
            __ppEnum_native__marshaller.Free();
        }
    
        return __retVal;
    }

    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.Interop.ComInterfaceGenerator", "11.0.14.22804")]
    [global::System.Runtime.CompilerServices.SkipLocalsInitAttribute]
    int global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13.LockedFlush()
    {
        var(__this, __vtable) = ((global::System.Runtime.InteropServices.Marshalling.IUnmanagedVirtualMethodTableProvider)this).GetVirtualMethodTableInfoForKey(typeof(global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13));
        var __target = ((delegate* unmanaged[MemberFunction]<void*, int> )__vtable[10]);
        {
            int __retVal;
            {
                __retVal = __target(__this);
            }
    
            // NotifyForSuccessfulInvoke - Keep alive any managed objects that need to stay alive across the call.
            global::System.GC.KeepAlive(this);
            return __retVal;
        }
    }

    [global::System.Runtime.InteropServices.UnmanagedCallersOnlyAttribute(CallConvs = new[] { typeof(global::System.Runtime.CompilerServices.CallConvMemberFunction) })]
    internal static int ABI_LockedFlush(global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch* __this_native)
    {
        global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13 @this = default;
        int __retVal = default;
        try
        {
            // Unmarshal - Convert native data to managed data.
            @this = global::System.Runtime.InteropServices.ComWrappers.ComInterfaceDispatch.GetInstance<global::Microsoft.Diagnostics.DataContractReader.Legacy.ISOSDacInterface13>(__this_native);
            __retVal = @this.LockedFlush();
        }
        catch (global::System.Exception __exception)
        {
            __retVal = global::System.Runtime.InteropServices.Marshalling.ExceptionAsHResultMarshaller<int>.ConvertToUnmanaged(__exception);
        }
    
        return __retVal;
    }
}

namespace Microsoft.Diagnostics.DataContractReader.Legacy
{
    [global::System.Runtime.InteropServices.Marshalling.IUnknownDerivedAttribute<InterfaceInformation, InterfaceImplementation>]
    public unsafe partial interface ISOSDacInterface13
    {
    }
}