llvm-6502/lib/Transforms
Shuxin Yang a09e18fcfa For rdar://12329730, last piece.
This change attempts to simplify (X^Y) -> X or Y in the user's context if we know that
only bits from X or Y are demanded.

  A minimized case is provided bellow. This change will simplify "t>>16" into "var1 >>16".

  =============================================================
  unsigned foo (unsigned val1, unsigned val2) {
    unsigned t = val1 ^ 1234;
    return (t >> 16) | t; // NOTE: t is used more than once.
  }
  =============================================================

  Note that if the "t" were used only once, the expression would be finally optimized as well.
However, with with this change, the optimization will take place earlier.

  Reviewed by Nadav, Thanks a lot!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@169317 91177308-0d34-0410-b5e6-96231b3b80d8
2012-12-04 22:15:32 +00:00
..
Hello Use the new script to sort the includes of every file under lib. 2012-12-03 16:50:05 +00:00
InstCombine For rdar://12329730, last piece. 2012-12-04 22:15:32 +00:00
Instrumentation Sort includes for all of the .h files under the 'lib' tree. These were 2012-12-04 07:12:27 +00:00
IPO Add 'using' declarations to suppress -Woverloaded-virtual warnings. 2012-12-04 05:41:27 +00:00
Scalar Add 'using' declarations to suppress -Woverloaded-virtual warnings. 2012-12-04 05:41:27 +00:00
Utils Use the new script to sort the includes of every file under lib. 2012-12-03 16:50:05 +00:00
Vectorize Add support for reduction variables when IF-conversion is enabled. 2012-12-04 18:17:33 +00:00
CMakeLists.txt Add a basic-block autovectorization pass. 2012-02-01 03:51:43 +00:00
LLVMBuild.txt Add a basic-block autovectorization pass. 2012-02-01 03:51:43 +00:00
Makefile Add a basic-block autovectorization pass. 2012-02-01 03:51:43 +00:00