Want to create HUGE Vec<_> that fits half the memory: got failAborted

The other suggestions are very sane.

But if you really want to try to stuff all this in a vec, why not still try with_capacity and give it like 10GB? You might not be able to allocate exactly what you need, but allocating more than you need doesn't seem terrible given what you've shared about the problem.