Table of Contents

Interface IPinnedMemory

Namespace
Orleans.GpuBridge.Abstractions.Providers.Memory.Interfaces
Assembly
Orleans.GpuBridge.Abstractions.dll

Pinned host memory for efficient GPU transfers

public interface IPinnedMemory : IDisposable
Inherited Members

Properties

HostPointer

Host pointer to the pinned memory

nint HostPointer { get; }

Property Value

nint

SizeBytes

Size in bytes

long SizeBytes { get; }

Property Value

long

Methods

AsSpan()

Gets a span view of the memory

Span<byte> AsSpan()

Returns

Span<byte>

RegisterWithDeviceAsync(IComputeDevice, CancellationToken)

Registers this memory for use with a specific device

Task RegisterWithDeviceAsync(IComputeDevice device, CancellationToken cancellationToken = default)

Parameters

device IComputeDevice
cancellationToken CancellationToken

Returns

Task

UnregisterFromDeviceAsync(IComputeDevice, CancellationToken)

Unregisters this memory from a device

Task UnregisterFromDeviceAsync(IComputeDevice device, CancellationToken cancellationToken = default)

Parameters

device IComputeDevice
cancellationToken CancellationToken

Returns

Task