|
Boost : |
Subject: Re: [boost] [review] The review of Boost.DoubleEnded starts today: September 21 - September 30
From: Thorsten Ottosen (tottosen_at_[hidden])
Date: 2017-10-05 08:20:54
Den 05-10-2017 kl. 04:19 skrev degski via Boost:
> On 4 October 2017 at 23:48, Benedek Thaler via Boost <boost_at_[hidden]>
> wrote:
>
>> As expected, both devector and batch_deque highly outperforms std::vector
>> and queue in deserialization.
>>
>
> This sounds (to me) counterintuitive. Why is this the case?
Because they can avoid double initialization for some types. When using
std::vector, you have to either
A. reserve + load item to local object + push_back
B. resize + delegate to bulk operation in Boost.Serialization
The bulk operation is to prefer, but then requires redundant
initialization in resize.
kind regards
Thorsten
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk