https://gcc.gnu.org/bugzilla/show_bug.cgi?id=126184
--- Comment #5 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Kyrylo Tkachov <[email protected]>: https://gcc.gnu.org/g:7b4d5b42a78859b30c9b48fa0a426effbbd71ff7 commit r17-2698-g7b4d5b42a78859b30c9b48fa0a426effbbd71ff7 Author: Kyrylo Tkachov <[email protected]> Date: Wed Jul 22 16:45:16 2026 +0200 ifcvt: Reject hard-register destinations in multiple sets [PR126184] noce_convert_multiple_sets keys its dependency information by destination register number. Hard registers can have overlapping definitions in different modes. An exact RTL replacement cannot represent the value from a partial or mode-changing definition. Reject hard-register destinations in the block eligibility check. Assert the resulting pseudo-only invariant when dependency information is initialized. Add an RTL execution test with mixed-mode hard-register definitions. It verifies that the block remains unconverted. Bootstrapped and regtested on aarch64-none-linux-gnu and x86_64-pc-linux-gnu. gcc/ChangeLog: PR rtl-optimization/126184 * ifcvt.cc (init_noce_multiple_sets_info): Assert that destinations are pseudos. (bb_ok_for_noce_convert_multiple_sets): Reject hard-register destinations. gcc/testsuite/ChangeLog: PR rtl-optimization/126184 * gcc.target/aarch64/pr126184-2.c: New test. Signed-off-by: Kyrylo Tkachov <[email protected]>
