Форум: "Система";
Текущий архив: 2002.04.22;
Скачать: [xml.tar.bz2];
ВнизКак програмно узнать сколько занимает памяти чужое приложение? Найти похожие ветки
← →
VuDZ (2002-01-27 10:07) [10]люди, вы знаете о такой весчи як МСДН?
GetProcessMemoryInfo
The GetProcessMemoryInfo function retrieves information about the memory usage of the specified process in the PROCESS_MEMORY_COUNTERS structure.
BOOL GetProcessMemoryInfo(
HANDLE Process, // handle to process
PPROCESS_MEMORY_COUNTERS ppsmemCounters, // buffer
DWORD cb // size of buffer
);
Parameters
Process
[in] Handle to the process.
ppsmemCounters
[out] Pointer to the PROCESS_MEMORY_COUNTERS structure that receives information about the memory usage of the process.
cb
[in] Specifies the size, in bytes, of the PROCESS_MEMORY_COUNTERS structure.
The PROCESS_MEMORY_COUNTERS structure contains the memory statistics for a process.
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;
typedef PROCESS_MEMORY_COUNTERS *PPROCESS_MEMORY_COUNTERS;
Members
cb
The size of the structure, in bytes.
PageFaultCount
The number of page faults.
PeakWorkingSetSize
The peak working set size.
WorkingSetSize
The current working set size.
QuotaPeakPagedPoolUsage
The peak paged pool usage.
QuotaPagedPoolUsage
The current paged pool usage.
QuotaPeakNonPagedPoolUsage
The peak nonpaged pool usage.
QuotaNonPagedPoolUsage
The current nonpaged pool usage.
PagefileUsage
The current pagefile usage.
PeakPagefileUsage
The peak pagefile usage.
toolhelp, toolhelp... проще надо быть...
Страницы: 1 вся ветка
Форум: "Система";
Текущий архив: 2002.04.22;
Скачать: [xml.tar.bz2];
Память: 0.44 MB
Время: 0.007 c