19 Oct
2016
19 Oct
'16
6 p.m.
On 10/19/16 20:51, Chris Glover wrote:
But, typically set or map is chosen precisely because there will be many items in the container, otherwise you would choose something else, like an unsorted array like structure. So, to me the case of optimising for the small size makes little sense.
I would say that it's likely the opposite - larger flat containers will have more expensive insert and erase. Flat containers are especially useful with small number of (small) elements because they are cache-friendly, and small size optimization makes perfect sense to improve that use case even further.