timmyjose wrote:
Thanks for the very comprehensive response! I think most of my doubts are cleared now. You're right though that I'm probably worrying too much about GC with my current use case.

i can tell you that i'm doing things like, for example, ZX Spectrum emulator and hobbyst videogames (everything in D, even low-level gfx), i never really cared about "avoiding GC", and i can maintain solid 35/50/60 FPS (depending of my needs) with my code.

i.e. that "GC-phobia" (i'm not talking about you specifiallly, of course, sorry) is mostly based on nothing. as GC will never fire "on it's own", and you can control it, avoiding GC is not unnecessary (except some very special cases, of course ;-). the key tech here (as usual) is to not allocate in tight loops, plan your memory discipline and such. nothing new for people used to systems languages. ;-)

sure, you can stop worrying about that and use D as some kind of scripting language too, and still have all the features like type checking. for things like IRC or email client i absolutely don't care about allocations (i.e. doing it left and right) and just letting GC to do it's work. my usual IRC client uptime is several monthes (after that it runs out of memory, but this is 'cause it never does any cleanup on it's data, keeping all logs and db in memory. i am too lazy to finish it. note that is it not a GC fault, it is my code. ;-).

Reply via email to