llvm-6502/lib
Nadav Rotem 87255a431b Patch by Shuxin Yang <shuxin.llvm@gmail.com>.
Original message:

The attached is the fix to radar://11663049. The optimization can be outlined by following rules:

   (select (x != c), e, c) -> select (x != c), e, x),
   (select (x == c), c, e) -> select (x == c), x, e)
where the <c> is an integer constant.

 The reason for this change is that : on x86, conditional-move-from-constant needs two instructions;
however, conditional-move-from-register need only one instruction.

  While the LowerSELECT() sounds to be the most convenient place for this optimization, it turns out to be a bad place. The reason is that by replacing the constant <c> with a symbolic value, it obscure some instruction-combining opportunities which would otherwise be very easy to spot. For that reason, I have to postpone the change to last instruction-combining phase.

  The change passes the test of "make check-all -C <build-root/test" and "make -C project/test-suite/SingleSource".



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165661 91177308-0d34-0410-b5e6-96231b3b80d8
2012-10-10 21:31:55 +00:00
..
Analysis Use the attribute enums to query if a function has an attribute. 2012-10-09 21:49:51 +00:00
Archive Mark checkSignature const, and in turn stop casting away const from 2012-09-05 22:09:23 +00:00
AsmParser Use the enum value of the attributes when removing them from the attributes builder. 2012-10-09 09:17:28 +00:00
Bitcode Use method to query if there are attributes. 2012-10-04 07:19:46 +00:00
CodeGen Add in support for expansion of all of the comparison operations to the absolute minimum required set. This allows a backend to expand any arbitrary set of comparisons as long as a minimum set is supported. 2012-10-10 20:50:51 +00:00
DebugInfo Mark unimplemented copy constructors and copy assignment operators as LLVM_DELETED_FUNCTION. 2012-09-18 02:01:41 +00:00
ExecutionEngine Adding comments to clarify the reason for non-standard style in these files. 2012-10-10 01:48:52 +00:00
Linker Move the "findUsedStructTypes" functionality outside of the Module class. 2012-08-03 00:30:35 +00:00
MC Whitespace. 2012-10-09 20:15:02 +00:00
Object Cosmetic changes 2012-10-10 01:45:52 +00:00
Support Revert r165652: "Remove unnecessary RTTI from the build." 2012-10-10 20:50:36 +00:00
TableGen tblgen: Compile TableGen without RTTI. 2012-10-10 20:27:18 +00:00
Target Patch by Shuxin Yang <shuxin.llvm@gmail.com>. 2012-10-10 21:31:55 +00:00
Transforms Remove the final bits of Attributes being declared in the Attribute 2012-10-10 07:36:45 +00:00
VMCore Revert r165652: "Remove unnecessary RTTI from the build." 2012-10-10 20:50:36 +00:00
CMakeLists.txt
LLVMBuild.txt
Makefile