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

            Bug ID: 69501
           Summary: PowerPC rs6000_adjust_cost doesn't recognize
                    float/sign/zero extend memory operations
           Product: gcc
           Version: 6.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: meissner at gcc dot gnu.org
  Target Milestone: ---

I was chasing down another bug, when I happened to look at rs6000_adjust_cost
in rs6000.c.  In the REG_DEP_TRUE case of the switch statement, it tries to
separate a load from a narrower store.  However, if the load is an extend:

(sign_extend:DI (mem:SI ...))
(zero_extend:DI (mem:SI ...))
(float_extend:DF (mem:SF ...))

It will not recognize this, and bump up the cost by 14.  There might be other
places in the scheduling hooks where we miss opportunities with sign/zero
extension from memory.

Reply via email to