https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103449
--- Comment #6 from Martin Jambor <jamborm at gcc dot gnu.org> --- In my defense, even in my old code, in the call m_dead_ssa_debug_equiv.put (dead_ssa, *d) I would expect the load *d to be evaluated before the inline template function put is invoked and it feels strange that it isn't. Anyway, I have proposed your patch on the mailing list: https://gcc.gnu.org/pipermail/gcc-patches/2021-November/585665.html