https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100956
--- Comment #2 from Matt Bentley ---
Thank you - I'm aware GCC might optimize it out (and failed to test with
GCC10), at least in O2 mode, but other compilers might not, hence the code.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100956
Bug ID: 100956
Summary: Unused variable warnings ignore "if constexpr" blocks
where variables are conditionally used
Product: gcc
Version: 9.2.0
Status: UNCONFIRMED
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96750
--- Comment #6 from Matt Bentley ---
Created attachment 49278
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=49278=edit
Demonstration of code which doesn't trigger the performance anomaly.
plf_colony_fast.h does not trigger the problem,
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96750
--- Comment #5 from Matt Bentley ---
If anyone out there is interested in working on this,
I found the smallest change possible to create the same performance as GCC8-
it is literally eliminating one branch possibility in one function