Java's Memory Use Is a Feature, Not a Bug
Java is memory efficient [audio]

In this Ask the Architect episode of the Inside Java Podcast, recorded at JavaOne 2026, Nicolai Parlog talks with Ron Pressler, Java Architect at Oracle, about why Java's memory usage is often misunderstood. Pressler argues that Java's willingness to use more memory is a deliberate trade-off that results in fewer CPU cycles, made possible by its moving garbage collectors. He challenges the notion of memory efficiency, suggesting that leaving available memory unused is wasteful when it could speed up program execution.
But what's the point in leaving available memory on the table if using it makes your program run faster?
- indolering
For a definition of "efficient" that isn't shared by anyone else. This isn't a new rationale either, but a well known trade-off involved with JIT compilation and garbage collection. It's the reason Chrome "hogs" memory and Firefox is perceived as slow: they make different resource usage tradeoffs.
It will be interesting to see if the current memory crunch will impact this calculus going forward.
- njitbew
> But what's the point in leaving available memory on the table if using it makes your program run faster? Efficient use of that resource wouldn't be to leave it untapped but to use it to speed up the program.
What’s the point of having a host with available memory? In today’s clouds, couldn’t you just downsize the host, and save on cost?
- nitwit005
I agree with all the general principles, but the details of Java do matter here. There is a reason they're working hard on Project Valhalla: https://openjdk.org/projects/valhalla/