3 ms·
If you need hard realtime, go is not an appropriate solution. For a start you should expect occasional GC pauses on the order of tens of milliseconds, with no
by btilly 13y ago
If you need hard realtime, go is not an appropriate solution. For a start you should expect occasional GC pauses on the order of tens of milliseconds, with no upper bound if you're using a lot of memory.
That said, go actually can come close to C on sustained throughput. (On some benchmarks, naive go programs beat naive C, but usually go is somewhat slower.) You can interoperate with C using cgo, and there is no penalty. (It may not work with all go compilers.) If you want to interoperate with C++ then see http://www.swig.org/Doc2.0/Go.html http://www.swig.org/Doc2.0/Go.html for the best solution. I believe that there is a performance penalty there.