Repairs

[profiler]
Memory usage: real: 12582912, emalloc: 10095064
Code ProfilerTimeCntEmallocRealMem