Closed hschreiber closed 9 months ago
I did one last attempt to factorize the code by letting the erase
inside the if-else. And the times look better now, as the difference with the median does not exceed 3% anymore (except for very small cases) and is most of the time below 1%. But I can't say if it is still too much?
This v3 should in principle generate the same code as master for flat_map, the difference in the benchmark is probably noise. My hope was to replace if constexpr
with erase_if
, if we cannot do that and have to keep quite a bit of if constexpr
, my motivation reduces. Still, the v3 looks ok if you like that version. You could mention in the comment about erase_if that it does have a runtime cost, so we remember that it may not be such a good idea.
Fix for Issue #979.
All options have
static const bool stable_simplex_handles = true
to test with github all other platforms. They need of course to be removed before merging.