Nope, you&#x27;re thinking a one level too low in the stack.<p>The issue is that each object is a reference, and because it&#x27;s a reference it&#x27;s position in memory is by nature ambiguous(compacting GCs make this even worse by moving things around).<p>Until you can guarantee memory location you don&#x27;t know that the N+1 object you&#x27;re going to access is in the same cache line(or prefetched) and any sort of cache optimization is shot to hell. Only by knowing your standard execution flow and data set size can you write code that&#x27;s as efficient about cache misses as possible.<p>Hotspot only tends to focus on tight inner loops where the stuff I&#x27;m talking about involves looking at the larger program(and the structures you choose to put data into). Think Structure of Arrays(SoA) rather than Arrays of Structures(AoS). Possible to do in Java, but very painful.