https://gcc.gnu.org/bugzilla/show_bug.cgi?id=122760
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jakub at gcc dot gnu.org,
| |redi at gcc dot gnu.org
--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
https://wg21.link/P3309R3 paper makes load etc. constexpr for C++26, so when
that paper is implemented in GCC, this will work.
All we need is I think to decide how to implement that, whether by adding if
consteval variants into all the bodies, or handling all the needed __atomic_*
and maybe __sync_* builtins during constexpr evaluation.
And a separate question is whether __atomic_* should be folded by the
middle-end in some cases (such as when trying to atomically load something that
has to live in .rodata).