Am 18.02.2013 13:40, schrieb Joseph Rushton Wakeling:
On 02/18/2013 11:35 AM, Benjamin Thaut wrote:
I wen't down this path already and I ended up not using the GC at all:

http://3d.benjamin-thaut.de/?p=20

But reading your blog post, it seems that the main problem was not GC in
the general sense, but the fact that for various functionality druntime
makes unnecessary allocations.  Deal with those, and with-GC D ought to
speed up a lot.  Or have I misunderstood what you wrote?

The main problem is that programming with a GC encourages programming with memory leaks. As the gc will take care of any leaked memory and you don't get any feedback about how much memory you actually allocate. Also even if you do manual pooling and use a GC you still pay a big performance impact because the GC will scan the pooled memory without actually freeing anything. But scanning takes time too. And those interrupts by the GC will be long enough to interrupt regular gameplay. D would at least need a incremental Mark & Sweep to be usable in games. But in my opinion a GC is not needed at all when developing games, it makes a lot of sense for other fields though.

--
Kind Regards
Benjamin Thaut

Reply via email to