If you need a multiplatform stack or ring buffer, CircularArray from androidx.collections is the way to go. I benchmarked it against ArrayDeque and it has identical performance on jvm and anywhere between 20-50% better performance on native platforms
p
Pau Marzo
12/02/2024, 6:23 PM
Even on jvm has still some improvement, definitely using it, are there more like this?