Boost logo

Boost :

Subject: Re: [boost] Outcome v2
From: Niall Douglas (s_sourceforge_at_[hidden])
Date: 2017-07-13 19:51:36


>>>> A majority of peer review feedback didn't see the need for variant
>>>> storage. Eliminating it very significantly reduces the complexity of the
>>>> implementation, it's a big gain. I was able to SFINAE all the
>>>> constructors because of the compile time budget released by eliminating
>>>> the variant storage.
>>>
>>> If you're going to maintain strict no-value-plus-error semantics then
>>> union/variant storage makes sense, as otherwise you're wasting memory.
>>> I'm not sure why this would increase complexity.
>>
>> I did some benchmarking before making the change to non-variant storage,
>> and found a worst case performance loss of 3-6% depending on compiler.
>>
>
> Would you be willing to share some of these benchmarks? I've never
> benchmarked Noexcept, it would be interesting to see how it compares.

https://github.com/ned14/outcome/tree/master/benchmark

It would indeed be very interesting to see how much overhead TLS introduces.

Niall

-- 
ned Productions Limited Consulting
http://www.nedproductions.biz/ http://ie.linkedin.com/in/nialldouglas/

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk