3 ms·
Yes! I suspect (but I don't know for sure) that C# has the highest performance sealing of all the VM-based languages with a tracing garbage collector. structs,
by mohaneds 4y ago
Yes! I suspect (but I don't know for sure) that C# has the highest performance sealing of all the VM-based languages with a tracing garbage collector. structs, Span<T> and ReadOnlySpan<T> for type-safe access to contiguous regions of memory allow us to do a lot without touching the heap. C# also has hardware intrinsics for non-cross platform SIMD instructions if you're interested in that kind of thing.
- kaba0 4y agoPerhaps it can be manually optimized the best indeed, but the JVM still has a better GC if I’m not mistaken. Value types are indeed very cool, and I really hope they will get implemented sooner on the Java side as well. Just as a note, Java recently got a SIMD API as well.
- mohaneds 4y agoYou're right; Java has ZGC, a best-in-class garbage collector with average pause times of 50 microseconds while still having great throughput. https://malloc.se/blog/zgc-jdk16#:~:text=With%20concurrent%20thread%2Dstack%20scanning,max%20pause%20times%20of%20~500%C2%B5s https://malloc.se/blog/zgc-jdk16#:~:text=With%20concurrent%2...