Barrel length has little to do with accuracy. Barrel quality has everything to do with accuracy.

For a 308 I would not go shorter than 22 and I would lean towards 24-26.