llvm-6502/lib/Transforms/InstCombine
Shuxin Yang 7d72cf892e This change is to implement following rules under the condition C_A and/or C_R
---------------------------------------------------------------------------
 C_A: reassociation is allowed
 C_R: reciprocal of a constant C is appropriate, which means 
    - 1/C is exact, or 
    - reciprocal is allowed and 1/C is neither a special value nor a denormal.
 -----------------------------------------------------------------------------

 rule1:  (X/C1) / C2 => X / (C2*C1)  (if C_A)
                     => X * (1/(C2*C1))  (if C_A && C_R)
 rule 2:  X*C1 / C2 => X * (C1/C2)  if C_A
 rule 3: (X/Y)/Z = > X/(Y*Z)  (if C_A && at least one of Y and Z is symbolic value)
 rule 4: Z/(X/Y) = > (Z*Y)/X  (similar to rule3)

 rule 5: C1/(X*C2) => (C1/C2) / X (if C_A)
 rule 6: C1/(X/C2) => (C1*C2) / X (if C_A)
 rule 7: C1/(C2/X) => (C1/C2) * X (if C_A)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172488 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-14 22:48:41 +00:00
..
CMakeLists.txt llvm/lib: [CMake] Add explicit dependency to intrinsics_gen. 2012-06-24 13:32:01 +00:00
InstCombine.h Consider expression "0.0 - X" as the negation of X if 2013-01-09 00:13:41 +00:00
InstCombineAddSub.cpp Fix Casting Bug 2013-01-14 21:04:40 +00:00
InstCombineAndOrXor.cpp Move all of the header files which are involved in modelling the LLVM IR 2013-01-02 11:36:10 +00:00
InstCombineCalls.cpp Move all of the header files which are involved in modelling the LLVM IR 2013-01-02 11:36:10 +00:00
InstCombineCasts.cpp Fix typo in comment. 2013-01-14 20:56:10 +00:00
InstCombineCompares.cpp Move all of the header files which are involved in modelling the LLVM IR 2013-01-02 11:36:10 +00:00
InstCombineLoadStoreAlloca.cpp switch from pointer equality comparison to MDNode::getMostGenericTBAA 2013-01-05 16:44:07 +00:00
InstCombineMulDivRem.cpp This change is to implement following rules under the condition C_A and/or C_R 2013-01-14 22:48:41 +00:00
InstCombinePHI.cpp Move all of the header files which are involved in modelling the LLVM IR 2013-01-02 11:36:10 +00:00
InstCombineSelect.cpp Use the new script to sort the includes of every file under lib. 2012-12-03 16:50:05 +00:00
InstCombineShifts.cpp Move all of the header files which are involved in modelling the LLVM IR 2013-01-02 11:36:10 +00:00
InstCombineSimplifyDemanded.cpp Move all of the header files which are involved in modelling the LLVM IR 2013-01-02 11:36:10 +00:00
InstCombineVectorOps.cpp [InstCombine] Teach InstCombine how to handle an obfuscated splat. 2012-10-16 21:29:38 +00:00
InstCombineWorklist.h Move all of the header files which are involved in modelling the LLVM IR 2013-01-02 11:36:10 +00:00
InstructionCombining.cpp Consider expression "0.0 - X" as the negation of X if 2013-01-09 00:13:41 +00:00
LLVMBuild.txt LLVMBuild: Remove trailing newline, which irked me. 2011-12-12 19:48:00 +00:00
Makefile make -fno-rtti the default unless a directory builds with REQUIRES_RTTI. 2010-01-24 20:43:08 +00:00