Remix.run Logo
pjmlp 4 hours ago

Even C requires discipline to write low latency code, if you think otherwise, you never used a profiler.

__s 2 hours ago | parent | next [-]

Yes. & in the end my experience has been that you can write low latency code with gc, but only by expending more effort than it'd take to use manual memory management

pjmlp 2 hours ago | parent [-]

First of all it depends on the language, what GC models it supports, and what are the performance SLAs.

Secondly if we are talking about something like real time audio, or sending the maximum amount of triangles per second, then there is zero memory management, the code should be allocation free across all the critical path, regardless of the language.

whaleofatw2022 18 minutes ago | parent [-]

Aka 'follow JSF guidelines that still apply to C and not just C++'.

I.e. all alloc should happen up front, functions should have predictable execution time, etc etc

madduci 3 hours ago | parent | prev [-]

And Compiler Explorer also