3 ms·
You can allocate memory manually in Go and manage it yourself using Go's `unsafe` package, so there's an escape route once Go's GC became a limiting factor. Her
by czx4f4bd 4y ago
You can allocate memory manually in Go and manage it yourself using Go's `unsafe` package, so there's an escape route once Go's GC became a limiting factor. Here's a blog post about it in the context of Dgraph: https://dgraph.io/blog/post/manual-memory-management-golang-jemalloc/ https://dgraph.io/blog/post/manual-memory-management-golang-...
- notwokeno 4y agoThe real issue with go is (or was, I haven't messed with it for a few years) its un-optimized goroutine scheduler that makes channels slow if you start using them a lot.
- flagsrule 4y agoYes, refactoring from channels to atomic package can easily give 10x speedup. Sometimes we have to communicate by sharing memory :)