Commit Graph

3 Commits

Author SHA1 Message Date
David Blaikie 2c302a8dfa Update SystemZ/Large test generators to handle new gep IR syntax
llvm-svn: 230810
2015-02-27 23:29:39 +00:00
David Blaikie d7e13b0eb2 Update SystemZ/Large test generators to handle new load IR syntax
llvm-svn: 230809
2015-02-27 23:29:33 +00:00
Richard Sandiford c212125d27 [SystemZ] Use BRCT and BRCTG to eliminate add-&-compare sequences
This patch just uses a peephole test for "add; compare; branch" sequences
within a single block.  The IR optimizers already convert loops to
decrement-and-branch-on-nonzero form in some cases, so even this
simplistic test triggers many times during a clang bootstrap and
projects/test-suite run.  It looks like there are still cases where we
need to more strongly prefer branches on nonzero though.  E.g. I saw a
case where a loop that started out with a check for 0 ended up with a
check for -1.  I'll try to look at that sometime.

I ended up adding the Reference class because MachineInstr::readsRegister()
doesn't check for subregisters (by design, as far as I could tell).

llvm-svn: 187723
2013-08-05 11:23:46 +00:00