https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108703

Vladimir Makarov <vmakarov at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |vmakarov at gcc dot gnu.org

--- Comment #3 from Vladimir Makarov <vmakarov at gcc dot gnu.org> ---
Here is my analysis of the problem/

Before IRA we already have:

(insn 10 7 11 2 (set (reg:HI 33 %f1)
        (reg:HI 35 %f3)) "/home/vmakarov/testcase.c":8:3 114 {*movhi_insn}
     (expr_list:REG_EQUAL (const_int 13107 [0x3333])
        (nil)))

LRA considers the insn is correct and does not check constraints as it
is simple move and its cost is 2.  This is standard convention for ignoring
constraints since the very early versions of reload pass.  And as I remember,
it is described somewhere in GCC documentation.

I think we should avoid to generate such insn from the start because
ignoring the reload convention will result in many unexpected
consequences where LRA speed slowdown probably would be a minor negative
consequence.

Reply via email to