You pad each counter so that it's on a separate cache line. https://lmax-exchange.github.io/disruptor/ goes into detail on the false sharing problem.
(A+ and full marks on recognizing that that's a central problem.)
(A+ and full marks on recognizing that that's a central problem.)