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

--- Comment #6 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jeff Law <[email protected]>:

https://gcc.gnu.org/g:d33d3552eb807d64d05f0732ff9003bfae706f03

commit r17-4703-gd33d3552eb807d64d05f0732ff9003bfae706f03
Author: Roger Sayle <[email protected]>
Date:   Sun Sep 27 14:39:45 2026 -0600

    [PR target/127267] Improve code on iq2000 port for AOR optabs and lowpart
IOR with 0x0

    I'm submitting this on Roger's behalf.

    After debugging the execution fails originally attributed to Roger's patch
for
    p127267, I'm of the opinion Roger's code is fine and that we've go some
kind of
    linker issue going on.  The details are in the BZ.

    Roger's patch tries to accomplish a few things.

    First it defines the aop optab to steer the iq2000 port to IOR rather than
PLUS
    when they're equiavlent.  That probably makes sense.  In the process the
patch
    improves the generated code for an IOR when the low bits are zero.  For the
    case of loading a constant, we just emit the LUI for the high part and
we're
    done.  In the case of an IOR against zero, it turns into a copy.

    His patch also fixes up an parenthesis error in SMALL_INT handling.

    This fixes the poor code generation noted in pr127267.  I suspect (but can
not
    confirm) that the 20040705-1 execution failure is likely the same kind of
    linker bug that I just chased down.  In fact, it makes any execution issues
on
    the iq2000 port suspect (and I've had a long time suspicion that something
    wasn't quite right on the iq2000 port given is sporadic failures.

            PR target/127267
    gcc/
            * config/iq2000/iq2000.h (SMALL_INT): Fix trivial parenthesis goof.
            * config/iq2000/iq2000.cc (iq2000_move_1word): Eliminate useless
            IOR with 0x0 operand.
            * config/iq2000/iq2000.md (aopsi3): New expander.
            (32 bit integer move splitter): Turn low part IOR into a copy when
            the constant is zero.

Reply via email to