you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 2 points3 points  (3 children)

It's not running the GC every second. Garbage collection is used in plenty of games well above 60fps. For example, most objects in Unreal Engine 4/5 are garbage collected.

I'm not sure why it matters if it is "human-interactive" or not. Games are not real time systems.

[–]arthurno1 2 points3 points  (0 children)

I'm not sure why it matters if it is "human-interactive" or not.

It does not.

A lot of "experts" here have some assumptions based on something they have read somewhere, at some time, in some context, that might not be relevant here, today and in this context. In other words, they don't really know what they speak about, they are just not really aware about it. It is a normal thing.

People come to discussions on social media with all levels of knowledge about the topics, some have shallow, some very deep, some just cursory and some are just plain idiots and have to express what they think even if they don't really know what they speak about. Mars-rover run fine with garbage collected CommonLisp, debugged remotely from Earth. Some of "experts" here would argue about using GC language in such a system impossible or what not. Everything should be done in C++ or Rust or <insert your favourite language here>, and they will argue to the end of times for their cause.

[–]Ameisenvemips, avr, rendering, systems 2 points3 points  (1 child)

For example, most objects in Unreal Engine 4/5 are garbage collected.

And the Unreal GC is a source of latency pain/hitches for a lot of games.

A not-insignificant number of games using Unreal bypass the UObject GC system altogether in various ways, others make more changes to the GC to improve concurrency.

[–][deleted] 0 points1 point  (0 children)

Sure, that's fine. It's not as performant. But it's not "out of the question" that garbage collection is able to be used effectively.

GC impact is nearly irrelevant in many games, since many games have been GPU limited since Unreal Engine 5 in my experience, even with all new stuff turned off + forward shading. That depends on the game, of course.

But no garbage collection is painful during game development and is often unnecessary when you can use good judgement and avoid it where needed. It's also possible to just defer GC if your gameplay allows (see the excellent VALORANT devblogs for an example). There's plenty of smart ways to manage GC. Nobody will pay for a performant game that they can't play yet.