This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: RFA: make PLUS commutative by default


On Tue, Jul 05, 2005 at 01:04:43PM -0400, Andrew Pinski wrote:
> It is not just PA any more.  IIRC ia64 has the same issue too.

No, because ia64 doesn't use PLUS for this.

(define_insn "ptr_extend"
  [(set (match_operand:DI 0 "gr_register_operand" "=r")
        (unspec:DI [(match_operand:SI 1 "gr_register_operand" "r")]
                   UNSPEC_ADDP4))]
  ""
  "addp4 %0 = 0,%1"
  [(set_attr "itanium_class" "ialu")])

which, frankly, is the solution that PA ought to adopt as well.
There's no reason why they can't consider

  (mem (unspec [(reg 100) (reg 200)] ADDP4))

a valid address.


r~


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]