4 ms·
JVM GC development has seen an upswing in the last few years, one of the most interesting new GCs are ZGC that show impressive numbers, delivers less than 10 ms
by walkingolof 7y ago
JVM GC development has seen an upswing in the last few years, one of the most interesting new GCs are ZGC that show impressive numbers, delivers less than 10 ms pause times for any heap size, often than 1 ms for many applications, while having impressive throughput numbers. Another interesting adoption to the containerized world we live in is that GCs recently started to frequently return memory to the OS when not being used.
If you want to read more about these new GCs, this is a great post:
https://blog.plan99.net/modern-garbage-collection-part-2-1c88847abcfd https://blog.plan99.net/modern-garbage-collection-part-2-1c8...
- kjeetgill 7y agoDon't forget Shenandoah headed by G1's lead Christine Flood! I don't know enough to compare it to ZGC but it's an exciting time in Java's GC lineup.
- lightgreen 7y agoThey promised low latency in G1, then they promised low latency in Shenandoah, now they promised it in ZGC. Okay. What JVM really really needs for performance is value types: a lot of GC problems will simply not exist with value types. Project Valhalla started five (!) years ago, and they are still working on it. JVM could also use multiple heaps per process (so multiple GCs could run independently not affecting other heap execution and GC). There were talks about it years ago, but nobody is working on it AFAIU.
- kjeetgill 7y agoI always had good experiences with G1 generally. ZGC and Shenandoah are Oracle and Redhat's respective projects with similar goals. I like the options and activies around GC all personally.
- peterashford 7y agoG1 has low latency. And as someone who programs c# for a living: I DO NOT WANT value types.
- tom_mellior 7y agoInteresting, could you expand a bit? From what I have seem the proposal for Java seems useful.
- peterashford 7y agoIn the c# I dislike the extra mental load of having to work out which rules apply to the lexical thing I see being manipulated in the code. If I see references being assigned in Java I can tell that that's the case just by looking at the code. In c# I have to see the definition of the objects to tell what semantics are being expressed by the syntax. Likewise, with properties in c# a straightforward field assignment can be pretty much anything which means again, innocent looking code can be misleading and the only way to know is to read the definitions. Java is simpler to read and I value that.
- burtonator 7y ago> Another interesting adoption to the containerized world we live in is that GCs recently started to frequently return memory to the OS when not being used. I'm wondering if there are any security implications here. Like a container could figure out the workload of another container probablistically. Thinking out loud here but sometimes these side channels are leaky.