Boost logo

Boost :

Subject: Re: [boost] [outcome] How to drop the formal empty state
From: Niall Douglas (s_sourceforge_at_[hidden])
Date: 2017-05-27 22:14:50

>>> What does it mean tha "outcome is equally costly on T or E branches
>> chosen"?
>> Have a look at, specifically the disassembly.
>> As you'll note, the first possible state (empty) tends to be chosen by
>> the compiler as the most likely. That implies a 20 cycle branch
>> misprediction cost for each of the valued or errored states. So they are
>> equally costly, which is intentional.
> Would you not rather manually "predict" for the valued state?

Predictable latency for success or failure is a key design goal for
Outcome. If you want success to be preferred, choose Expected instead.


ned Productions Limited Consulting

Boost list run by bdawes at, gregod at, cpdaniel at, john at