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

This was almost exactly my experience when I wrote a network simulator in Go and tried to improve the performance. The gc pauses reached tens of seconds haha, I made a lot of garbage.

I'm not completely sure if this is true but I think that doing things in an "OO" style where for example, every different event was it's own type which satisfies the Event interface basically means that different events can't occupy an array together and that I think that each one may hold a pointer to some heap allocated memory, so you really can't optimise this away without ripping up the entire program.

Rather than do so, I ended up running my Sim on a server with >100 cores, it was single threaded but they would all spin up and chomp the GC, a beautiful sight.

Another factor is just the general lack of transparency or knowability of where and how objects occupy memory in these languages.

If memory management is likely to be a concern it is absolutely much easier in an environment where it is prioritized than one where it is ignored.



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

Search: