Optimizing for small arrays