Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I'm curious as to who uses a garbage collector in C. It seems like if you're using C, you probably are in a situation where you want as close control of that kind of stuff as possible (short of assembly).


GCC and Mono use it internally, I believe.

It's a very conservative garbage collector at the end of the day. It can be tweaked so as to be completely bare bones, and the performance impact is very benign. Rather, memory consumption is its weakness.


The same thing can be said about malloc. It's a matter of degree, and different projects have (sometimes subtly) different requirements.


Expanding - in particular, Boehm seems to only run collections on allocations. If your code is structured such that you don't allocate during periods when you need more precise control (already a good idea, if you are using malloc!) then this won't have an impact.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: