https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114810
--- Comment #4 from Uroš Bizjak <ubizjak at gmail dot com> --- An interesting observation, when the insn is defined only with problematic alternative: (define_insn_and_split "*andn<dwi>3_doubleword_bmi" [(set (match_operand:<DWI> 0 "register_operand" "=&r") (and:<DWI> (not:<DWI> (match_operand:<DWI> 1 "register_operand" "r")) (match_operand:<DWI> 2 "nonimmediate_operand" "ro"))) (clobber (reg:CC FLAGS_REG))] the compilation succeeds, and a spill to memory is emitted: (insn 1170 65 1177 7 (set (mem/c:DI (plus:SI (reg/f:SI 6 bp) (const_int -168 [0xffffffffffffff58])) [71 %sfp+-144 S8 A64]) (reg:DI 0 ax [orig:217 _13 ] [217])) "pr114810.C":296:36 84 {*movdi_internal} (nil)) ... (insn 987 1154 1111 7 (parallel [ (set (reg:DI 3 bx [453]) (and:DI (not:DI (reg:DI 0 ax [452])) (mem/c:DI (plus:SI (reg/f:SI 6 bp) (const_int -168 [0xffffffffffffff58])) [71 %sfp+-144 S8 A64]))) (clobber (reg:CC 17 flags)) ]) "pr114810.C":296:6 703 {*andndi3_doubleword_bmi} (nil))