https://gcc.gnu.org/bugzilla/show_bug.cgi?id=127367
Zhongyao Chen <chenzhongyao.hit at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |chenzhongyao.hit at gmail dot
com
--- Comment #2 from Zhongyao Chen <chenzhongyao.hit at gmail dot com> ---
the issue is gone using -fno-ext-dce, so confirm this is an ext-dce issue.
Looking at the dump right before ext-dce, the call takes a TImode argument in
a0:a1:
(insn 14 (set (reg:DI 152) (ashiftrt:DI (reg:DI 135 [t]) (const_int 63))))
(insn 17 (set (reg:DI 155) (ashift:DI (reg:DI 152) (const_int 32))))
(insn 18 (set (reg:DI 154) (lshiftrt:DI (reg:DI 155) (const_int 32))))
(insn 23 (set (reg:DI 11 a1) (reg:DI 154)))
(call_insn 24 ...
(expr_list (use (reg:TI 10 a0)) ...))
But ext-dce think a1 is dead and delete the zero-extension:
Processing insn:
18: r154:DI=r155:DI 0>>0x20
Trying to simplify pattern:
(lshiftrt:DI (reg:DI 155) (const_int 32 [0x20]))
Successfully transformed to:
(set (reg:DI 154) (reg:DI 152)) <----------------- wrong
deleting insn with uid = 18.
Patch is in flight.