News for hackers. Stuff that matters.
Re:Breaking the Limits: How Folia Made 1,000 Player Minecraf... by zelos on Tuesday June 27, 2023 @07:53AM (#36491589)
For short lived objects, heap allocation is probably about as fast as allocating on the stack. By pooling you can end up moving objects out of the fast eden space into older generations.

I worked on optimising a java library a few years back and one of the bigger speed ups was removing all the object pooling code.

Re:Breaking the Limits: How Folia Made 1,000 Player Minecraf... by tjoff on Tuesday June 27, 2023 @08:14AM (#36491748)
But that means that the pools still use the GC? If so then I fully agree. But the point of a pool in my mind would be to reuse the memory rather than allocate+deallocate it.