IDkmGPUMemoryOperation.ReadMemory 方法

定义

读取目标 GPU 进程的内存。 方法在 DkmGPUComputeThread 上,因为它可能读取线程本地内存、组共享内存或全局内存。

public:
 int ReadMemory(Microsoft::VisualStudio::Debugger::GPU::DkmGPUComputeThread ^ computeThread, System::UInt64 address, System::UInt64 instructionPointer, Microsoft::VisualStudio::Debugger::DkmReadMemoryFlags flags, cli::array <System::Byte> ^ buffer);
public int ReadMemory (Microsoft.VisualStudio.Debugger.GPU.DkmGPUComputeThread computeThread, ulong address, ulong instructionPointer, Microsoft.VisualStudio.Debugger.DkmReadMemoryFlags flags, byte[] buffer);
abstract member ReadMemory : Microsoft.VisualStudio.Debugger.GPU.DkmGPUComputeThread * uint64 * uint64 * Microsoft.VisualStudio.Debugger.DkmReadMemoryFlags * byte[] -> int
Public Function ReadMemory (computeThread As DkmGPUComputeThread, address As ULong, instructionPointer As ULong, flags As DkmReadMemoryFlags, buffer As Byte()) As Integer

参数

computeThread
DkmGPUComputeThread

中DkmGPUComputeThread 表示在 GPU 目标进程中运行的计算线程。

address
UInt64

中从中读取目标 GPU 进程的内存的地址。

instructionPointer
UInt64

中指令指针,将地址解析为注册位置。

flags
DkmReadMemoryFlags

中控制 DkmProcess ReadMemory 和 DkmProcess 的行为的标志。

buffer
Byte[]

[In,Out]接收目标进程的地址空间中的内容的缓冲区。 失败时,此缓冲区内容是未指定的。

返回

Int32

弄指示从目标 GPU 进程中读取的字节数。 如果 DkmReadMemoryFlags,则在成功时,此值将始终与输入大小完全相同。 如果指定 DkmReadMemoryFlags,则在成功时,此值将大于零。

适用于