标签: PROCESS_MEMORY_COUNTERS ProMem = {0};ProMem.cb = sizeof

时间:2021-08-17 06:00:51

标签:

PROCESS_MEMORY_COUNTERS ProMem = {0}; ProMem.cb = sizeof(PROCESS_MEMORY_COUNTERS); HANDLE hProcess = OpenProcess(PROCESS_QUERY_INFORMATION | PROCESS_VM_READ,FALSE,GetCurrentProcessId()); GetProcessMemoryInfo(hProcess,&ProMem,sizeof(ProMem)); CloseHandle(hProcess); typedef struct _PROCESS_MEMORY_COUNTERS { DWORD cb; DWORD PageFaultCount; SIZE_T PeakWorkingSetSize; SIZE_T WorkingSetSize; SIZE_T QuotaPeakPagedPoolUsage; SIZE_T QuotaPagedPoolUsage; SIZE_T QuotaPeakNonPagedPoolUsage; SIZE_T QuotaNonPagedPoolUsage; SIZE_T PagefileUsage; SIZE_T PeakPagefileUsage; } PROCESS_MEMORY_COUNTERS;

标签: PROCESS_MEMORY_COUNTERS ProMem = {0};ProMem.cb = sizeof

【API】获取当前进程的内存信息