rejetto forum

about getHeapStatus() message in delphi

Mars · 2 · 2790

0 Members and 1 Guest are viewing this topic.

Offline Mars

  • Operator
  • Tireless poster
  • *****
    • Posts: 2039
    • View Profile
if showMemUsageChk.checked then
  addPanel('Mem: '+dotted(getHeapStatus().TotalAllocated ));

[Pascal Avertissement] main.pas(9232): W1000 Symbole 'GetHeapStatus' désapprouvé

found this information:

It is recommended to use GlobalMemoryStatus from the Windows unit instead of GetHeapStatus. However, in systems with more than 2 GB memory, GlobalMemoryStatus returns erroneous results. Therefore, a newer Windows API function should be used: GlobalMemoryStatusEx

Offline rejetto

  • Administrator
  • Tireless poster
  • *****
    • Posts: 13308
    • View Profile
thank you mars.
sadly, after i worked to get GlobalMemoryStatusEx working, i noticed there's no equivalent to TotalAllocated.

i will have a look at GetMemoryManagerState when i have time
« Last Edit: May 17, 2009, 09:13:24 PM by rejetto »