https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115836
--- Comment #14 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-13 branch has been updated by Uros Bizjak <u...@gcc.gnu.org>: https://gcc.gnu.org/g:cc47ad09e571016f498710fbd8a19f302c9004de commit r13-8903-gcc47ad09e571016f498710fbd8a19f302c9004de Author: Uros Bizjak <ubiz...@gmail.com> Date: Wed Jul 10 09:27:27 2024 +0200 middle-end: Fix stalled swapped condition code value [PR115836] emit_store_flag_1 calculates scode (swapped condition code) at the beginning of the function from the value of code variable. However, code variable may change before scode usage site, resulting in invalid stalled scode value. Move calculation of scode value just before its only usage site to avoid stalled scode value. PR middle-end/115836 gcc/ChangeLog: * expmed.cc (emit_store_flag_1): Move calculation of scode just before its only usage site. (cherry picked from commit 44933fdeb338e00c972e42224b9a83d3f8f6a757)