added spec preallocation for large batches