[Patch] Implementation of n3793 <experimental/optional>
Luc Danton
lucdanton@free.fr
Sun Nov 3 00:39:00 GMT 2013
On 2013-11-02 23:31, Paolo Carlini wrote:
>
> In general we are very careful with code bloat, but free functions which just forward to other functions should be definiyely inline, otherwise typically at widely used optimization levels like -O2 users get suboptimal performance for no reason. But please feel free to experiment and report your findings on the mailing list!
>
> Paolo
>
>
>
After review, the free functions that only ever forward to something
else and are not implicitly inline appear to be that
__constexpr_addressof overload and non-member swap. Here's a patch
(against master) that marks them inline, all tests pass. I briefly and
casually attempted to notice any effect, but to be honest in my smallish
testcases GCC appeared to already see through everything.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: optional-inline.patch
Type: text/x-patch
Size: 1168 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/libstdc++/attachments/20131103/68f4feb6/attachment.bin>
More information about the Libstdc++
mailing list