| |
|
|
| again one tolles Codepiece of Andreas Miethe: CompileMarkSeparation'##############################################
'# Autor : ampsoft (Andreas Miethe) #
'# Datum : 11.02.2012 #
'# Thema : Speicher #
'# XProfan-Version : 8 #
'# ab Windows XP #
'##############################################
$H Windows.ph
STRUCT PROCESS_MEMORY_COUNTERS =\
lCb&,\
lPageFaultCount&,\
lPeakWorkingSetSize&,\
lWorkingSetSize&,\
lQuotaPeakPagedPoolUsage&,\
lQuotaPagedPoolUsage&,\
lQuotaPeakNonPagedPoolUsage&,\
lQuotaNonPagedPoolUsage&,\
lPagefileUsage&,\
lPeakPagefileUsage&,\
lPrivat&
CLS
Proc GetInfo
Declare PID&,hprocess&,PMC#
PID& = External("kernel32.dll","GetCurrentProcessId")
hProcess& = ~OpenProcess(~PROCESS_QUERY_INFORMATION | ~PROCESS_VM_READ,0,PID&)
Dim PMC#,PROCESS_MEMORY_COUNTERS
External("psapi.dll","GetProcessMemoryInfo",hProcess&,PMC#,Sizeof(PMC#))
Print Format$("PageFaultCount : ###,## KB",(PMC#.lPageFaultCount&)/1024)
Print
Print Format$("Arbeitssatz (Speicher) : ###,## KB",(PMC#.lWorkingSetSize&)/1024)
Print Format$("Arbeitssatz (Speicher Peak) : ###,## KB",(PMC#.lPeakWorkingSetSize&)/1024)
Print
Print Format$("PageFile : ###,## KB",(PMC#.lPageFileUsage&)/1024)
Print Format$("PeakPagefile : ###,## KB",(PMC#.lPeakPageFileUsage&)/1024)
Print Format$("QuotaPeakPagedPoolUsage : ###,## KB",(PMC#.lQuotaPeakPagedPoolUsage&)/1024)
Print Format$("QuotaPagedPoolUsage : ###,## KB",(PMC#.lQuotaPagedPoolUsage&)/1024)
Print Format$("QuotaPeakNonPagedPoolUsage : ###,## KB",(PMC#.lQuotaPeakNonPagedPoolUsage&)/1024)
Print Format$("QuotaNonPagedPoolUsage : ###,## KB",(PMC#.lQuotaNonPagedPoolUsage&)/1024)
Print Format$("Privat : ###,## KB",(PMC#.lPrivat&)/1024)
~Closehandle(hProcess&)
Dispose PMC#
EndProc
Declare Ende&
GetInfo()
Ende& =0
SetTimer 500
WhileNot ende&
WaitInput
If %wmtimer
Locate 0,0
GetInfo()
EndIf
EndWhile
Killtimer
=s4 href='./../../Function-References/XProfan/end/'>End
|
|
|
| |
|
|