Please sign in to comment.
Create slice with predefined capacity
Each append caused a runtime.growslice since the slice had no initial capacity and so we had to grow the slice on appends. Since we know the capacity, we can make the slice with this info to avoid allocations
- Loading branch information...