Jakob Stoklund Olesen 864c8702ba Also combine zext/sext into selects for ARM.
This turns common i1 patterns into predicated instructions:

  (add (zext cc), x) -> (select cc (add x, 1), x)
  (add (sext cc), x) -> (select cc (add x, -1), x)

For a function like:

  unsigned f(unsigned s, int x) {
    return s + (x>0);
  }

We now produce:

  cmp r1, #0
  it  gt
  addgt.w r0, r0, #1

Instead of:

  movs  r2, #0
  cmp r1, #0
  it  gt
  movgt r2, #1
  add r0, r2

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@162177 91177308-0d34-0410-b5e6-96231b3b80d8
2012-08-18 21:25:22 +00:00
..
2012-04-10 03:15:42 +00:00
2012-06-11 08:07:26 +00:00
2012-02-28 02:08:50 +00:00
2012-06-15 21:32:12 +00:00
2011-12-19 23:26:44 +00:00
2011-12-19 23:26:44 +00:00
2012-04-16 20:56:42 +00:00
2012-04-16 20:56:42 +00:00
2011-11-14 18:03:05 +00:00
2011-11-29 23:09:16 +00:00
2011-11-29 23:09:16 +00:00
2011-04-01 03:36:33 +00:00
2011-07-26 20:49:44 +00:00