OSNews article about C++09 degenerates into C++ vs. D discussion
Don Clugston
dac at nospam.com.au
Sun Nov 19 23:35:32 PST 2006
Walter Bright wrote:
> Dave wrote:
>> But the whole concern centers around two canards: a) GC is really slow
>> and b) malloc/free offer deterministic performance for real-time
>> appplications.
>>
>> I actually think that the best defense is dispelling those two myths.
>> a) for D will come in time and b) is just plain not true for general
>> purpose malloc/free implementations on modern operating systems.
>
> If you talk to the people who actually do real time software, they don't
> use malloc/free precisely because they are not deterministic. They
> preallocate all data.
I'd like to see a standard response on the website along these lines.
Something like:
FAQ:
Q.Isn't GC slow and non-deterministic?
A. Yes, but *all* dynamic memory management is slow and
non-deterministic. If you talk to the people who actually do real time
software, they don't use malloc/free precisely because they are not
deterministic. They preallocate all data.
However, the use of GC instead of malloc enables advanced language
constructs (especially, more powerful array syntax), which greatly
reduce the number of memory allocations which need to be made.
More information about the Digitalmars-d
mailing list