[0]: https://mattwarren.org/2019/03/01/Is-CSharp-a-low-level-lang...
[0]: https://mattwarren.org/2019/03/01/Is-CSharp-a-low-level-lang...
C# allows to optimise memory allocation when that matters and to rely on the GC for less critical parts.
There does seem to be this odd semi-subconscious idea in the "GCs aren't appropriate for any high-performance" world that they intrinsically work by stopping the world for 50ms several times per second or something, but that does not have to be the case.
[1]: I actually have a number of servers in Go that run on about this schedule. If you eliminated 100% of my GC cost for these servers, I wouldn't care at all, or even notice.
Things work a bit differently for "modern" emulators, where the emulators recreate the kernel/OS at a high level. In these emulators, the games will call into the system, and the kernel will be expected to do all thats necessary for the call. In the high level approach, this means that if a call allocates, so does the emulator (edit: note that this is a simplified view, as both emulators map a 4GB page that they work in for the guest system memory, but theres still a ton of side allocations that happen "outside" of the guest kernel). There is a lot of work that goes on in this layer of emulation, and theres going to be objects that the emulator allocates and later destroys. Process tables, thread lists, scheduler information, timing events, kernel synchronization primitives like mutexs, and so on to name some. I'm not intimately familiar with Ryujinx to make any statements about how they handle GC of course, but its something that they'll need to take into consideration. That said, there's plenty of other things like JIT compilation, shader compilation, caches filling up, and on and on that all also cause micro stuttering, so its not uncommon for even C or C++ emulators to have annoying pauses too.
https://www.cs.rice.edu/~javaplt/411/15-spring/Readings/wils...
https://web.archive.org/web/20191108025442/http://home.pipel...
https://web.archive.org/web/20191008134612/http://home.pipel...
https://web.archive.org/web/20191231120253/http://home.pipel...
Real-time garbage collectors are a thing. Maybe not common, but they have existed for at least 20+ years.