Core: Fixed MemoryProfile issue with USEMALLOC

git-svn-id: svn://ultimatepp.org/upp/trunk@6725 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2014-01-06 16:27:59 +00:00
parent 89dae538d9
commit dbeee1a7e9
2 changed files with 3 additions and 11 deletions

View file

@ -536,17 +536,7 @@ inline void MemoryIgnoreLeaksBegin() {}
inline void MemoryIgnoreLeaksEnd() {}
struct MemoryProfile {
int allocated[1024];
int fragmented[1024];
int freepages;
int large_count;
int large_size[4096];
int large_total;
int large_free_count;
int large_free_size[4096];
int large_free_total;
MemoryProfile() { memset(this, 0, sizeof(MemoryProfile)); }
int empty__;
};
inline MemoryProfile *PeakMemoryProfile() { return NULL; }

View file

@ -287,6 +287,7 @@ void LogStream::_Put(const void *data, dword size)
String AsString(const MemoryProfile& mem)
{
String text;
#ifdef UPP_HEAP
int acount = 0;
size_t asize = 0;
int fcount = 0;
@ -313,6 +314,7 @@ String AsString(const MemoryProfile& mem)
<< ", total size " << 64 * mem.large_empty << " KB\n";
text << "Big block count " << mem.big_count
<< ", total size " << int(mem.big_size >> 10) << " KB\n";
#endif
return text;
}