Re:Measuring GC latencies in Haskell, OCaml, Racket
by jakevn on Monday December 05, 2016 @12:12PM
(#13106979)
And in Unity3d, the GC is actually very problematic. For complex games, you need to focus on zero-allocation or there will be noticeable pauses. (See Kerbal Space Program) Object pooling is the way to go here.
[ Parent
| on HN ]
Re:Measuring GC latencies in Haskell, OCaml, Racket
by nightski on Monday December 05, 2016 @02:13PM
(#13108323)
I don't know if "problematic" is the right word seeing as even with manual memory management you have to do the same techniques. The problem is with allocation/destruction in general within the core loop.
Re:Measuring GC latencies in Haskell, OCaml, Racket
by yoklov on Monday December 05, 2016 @05:17PM
(#13110262)
It's more problematic in languages that encourage allocation since you have to work more to avoid it.
I've done game development in C++, C#, and JS, and I had to worry about memory management far more in JS than in C# or C++, simply because even something as innocent as adding two vec3s requires you come up with a space for the result first, if you want to avoid gc hitches.
C#'s struct types help here, but it still has plenty of its features increase GC pressure.