https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115495
Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Ever confirmed|0 |1 Status|UNCONFIRMED |NEW Last reconfirmed| |2024-06-14 --- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Trying 25 -> 26: 25: r150:DI=r139:V16HI#0 0>>0x10 26: r151:DI=zero_extend(r150:DI#0) That is these 2 instructions: ``` (insn 25 24 26 2 (set (reg:DI 150) (lshiftrt:DI (subreg:DI (reg:V16HI 139 [ vect_cst__21 ]) 0) (const_int 16 [0x10]))) "/app/example.c":5:14 299 {lshrdi3} (nil)) (insn 26 25 34 2 (set (reg:DI 151) (zero_extend:DI (subreg:HI (reg:DI 150) 0))) "/app/example.c":5:14 121 {*zero_extendhidi2} (expr_list:REG_DEAD (reg:DI 150) (nil))) ``` The above rtl looks good as far as I know. It looks like get_best_extraction_insn is using V16HI there though which is where it goes wrong. Confirmed. This comes from the expanision of: ;; MEM <vector(16) short int> [(short int *)&a] = vect_cst__21; Which looks different for GCC 14.1.0 and much simplier.