[Bug ipa/109914] --suggest-attribute=pure misdiagnoses static functions
hubicka at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Jul 29 14:03:56 GMT 2024
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109914
--- Comment #7 from Jan Hubicka <hubicka at gcc dot gnu.org> ---
The idea is to help developers to annotate i.e. binary tree search function,
which he clearly knows is always to be finite, but compiler can not prove it.
Intentional infinite loops with no side effects written in a convoluted ways
are almost never intentional, so almost always developer can add the pure
attribute based on his/her understanding of what the code really does.
More information about the Gcc-bugs
mailing list