llvm-6502/lib/Transforms
Chandler Carruth ed1951e79f Fix an issue where SROA computed different results based on the relative
order of slices of the alloca which have exactly the same size and other
properties. This was found by a perniciously unstable sort
implementation used to flush out buggy uses of the algorithm.

The fundamental idea is that findCommonType should return the best
common type it can find across all of the slices in the range. There
were two bugs here previously:

1) We would accept an integer type smaller than a byte-width multiple,
   and if there were different bit-width integer types, we would accept
   the first one. This caused an actual failure in the testcase updated
   here when the sort order changed.
2) If we found a bad combination of types or a non-load, non-store use
   before an integer typed load or store we would bail, but if we found
   the integere typed load or store, we would use it. The correct
   behavior is to always use an integer typed operation which covers the
   partition if one exists.

While a clever debugging sort algorithm found problem #1 in our existing
test cases, I have no useful test case ideas for #2. I spotted in by
inspection when looking at this code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@195118 91177308-0d34-0410-b5e6-96231b3b80d8
2013-11-19 09:03:18 +00:00
..
Hello First check in. Modified a comment. 2013-09-27 07:36:10 +00:00
InstCombine Apply the InstCombine fptrunc sqrt optimization to llvm.sqrt 2013-11-16 21:29:08 +00:00
Instrumentation [ASan] Fix PR17867 - make sure ASan doesn't crash if use-after-scope and use-after-return are combined. 2013-11-18 14:53:55 +00:00
IPO Add a loop rerolling flag to the PassManagerBuilder 2013-11-17 16:02:50 +00:00
ObjCARC [objc-arc] Convert the one directional retain/release relation assert to a conditional check + fail. 2013-11-05 16:02:40 +00:00
Scalar Fix an issue where SROA computed different results based on the relative 2013-11-19 09:03:18 +00:00
Utils Add support for software expansion of 64-bit integer division instructions. 2013-11-19 06:54:19 +00:00
Vectorize LoopVectorizer: Extend the induction variable to a larger type 2013-11-18 13:14:32 +00:00
CMakeLists.txt Extracted ObjCARC.cpp into its own library libLLVMObjCARCOpts in preparation for refactoring the ARC Optimizer. 2013-01-28 01:35:51 +00:00
LLVMBuild.txt Extracted ObjCARC.cpp into its own library libLLVMObjCARCOpts in preparation for refactoring the ARC Optimizer. 2013-01-28 01:35:51 +00:00
Makefile Extracted ObjCARC.cpp into its own library libLLVMObjCARCOpts in preparation for refactoring the ARC Optimizer. 2013-01-28 01:35:51 +00:00