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]

Re: PATCH for CSE



  In message <199807012334.QAA25625@smtp.earthlink.net>you write:
  > 
  > Here's a patch that improves execution time by a factor of three, for
  > one loop I've been looking at.  It reduces instruction count by a
  > similar factor, partly by enabling other optimizations.
  > 
  > When we had something like:
  > 
  >   (SET (REG 1) (ADDRESSOF (REG 2)))
  > 
  >   (SET (MEM (REG 1)) (REG 3))
  > 
  > CSE's find_best_addr decided that REG1 was a great address because it
  > was already in a register, and (ADDRESSOF (REG 2))) was lousy because
  > it had a higer ADDRESS_COST.  This patch introduces a new macro, for
  > use only in CSE because after that point ADDRESSOFs are purged, which
  > favors (ADDRESSOF (REG)).  That allows other mechanisms in CSE to
  > simplify (MEM (ADDRESSOF (REG 2))) to just plain REG 2.
  > 
  > Jeff, OK?
I think this patch is basically OK once your CSE ADDRESSOF bugfix patch is
applied.

I believe I mentioned eariler, you need to provide a definition of 
CSE_ADDRESS_COST when ADDRESS_COST is not defined.

Jeff


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