<div dir="ltr"><div dir="ltr">On Sat, Dec 15, 2018 at 1:01 PM Martok <<a href="mailto:listbox@martoks-place.de">listbox@martoks-place.de</a>> wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
I just tested something, and I'm a surprised by how big the difference is.<br></blockquote><div><br></div><div>Should this really be surprising at all though? To me it seems obvious why that would be the case. Delphi the compiler (not the IDE) is not written in Pascal. It's written in a combination of C and C++. Thus, I would imagine that Delphi's *default* internal memory management system is more along the lines of what is done in FPC's cmem unit, which is well known to be objectively faster than FPC's default memory manager as FPC's default memory manager simply does not aim to be fast but rather to use the smallest amount of memory possible.</div><div><br></div><div>It seems to me like a clear cut issue of just deciding what the biggest priority is. If anything, it might make sense to implement a secondary-default memory manager for FPC that does not necessarily call C functions like malloc but *does* aim specifically for speed, and that could perhaps be made available either via a command-line flag or perhaps just by using a unit the same way cmem is.</div></div></div>