This is the mail archive of the gcc@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: approaches to carry-flag modelling in RTL


On 01/11/11 02:43, Hans-Peter Nilsson wrote:

Not obvious or maybe I was unclear as to what I alluded? In the below insn-bodies, "sub" is the insn that sets cc0 as a side-effect.

Supposed canonical form :

(parallel
  [(set cc_reg) (compare ...))
   (set destreg) (sub ...))])
and:
(parallel
  [(set destreg) (sub ...))
   (clobber cc_reg)])

But IMHO it'd be easier (for most values of "easier") to combine
both patterns with that non-existing mechanism (and no, I don't
count match_parallel) if we instead canonicalized on the CC_REG
set being the same as the clobber position:

(parallel
  [(set destreg) (sub ...))
   (set cc_reg) (compare ...))])
with:
(parallel
  [(set destreg) (sub ...))
   (clobber cc_reg)])

brgds, H-P


That is very strange because if you look into RX or MN10300, they all have the set REG_CC as the last in the parallel. I wonder if it has anything to do with the fact that in these backends the set of the REG_CC only shows up after reload.



-- PMatos


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