summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Scalar/EarlyCSE.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Propagate TargetLibraryInfo throughout ConstantFolding.cpp and Chad Rosier2011-12-011-1/+6
| | | | | | | InstructionSimplify.cpp. Other fixups as needed. Part of rdar://10500969 llvm-svn: 145559
* Fix a couple hash functions so that they do not depend on undefined shifts. ↵Eli Friedman2011-10-121-2/+2
| | | | | | Based on patch by Ahmed Charles. llvm-svn: 141820
* Change a bunch of isVolatile() checks to check for atomic load/store as well.Eli Friedman2011-09-121-2/+2
| | | | | | | | No tests; these changes aren't really interesting in the sense that the logic is the same for volatile and atomic. I believe this completes all of the changes necessary for the optimizer to handle loads and stores correctly. I'm going to try and come up with some additional testing, though. llvm-svn: 139533
* Duncan deftly points out that readnone functions aren'tChris Lattner2011-01-031-1/+5
| | | | | | | invalidated by stores, so they can be handled as 'simple' operations. llvm-svn: 122785
* stength reduce my previous patch a bit. The only instructionsChris Lattner2011-01-031-6/+9
| | | | | | | | | | | that are allowed to have metadata operands are intrinsic calls, and the only ones that take metadata currently return void. Just reject all void instructions, which should not be value numbered anyway. To future proof things, add an assert to the getHashValue impl for calls to check that metadata operands aren't present. llvm-svn: 122759
* fix PR8895: metadata operands don't have a strong use of theirChris Lattner2011-01-031-4/+10
| | | | | | | | | | nested values, so they can change and drop to null, which can change the hash and cause havok. It turns out that it isn't a good idea to value number stuff with metadata operands anyway, so... don't. llvm-svn: 122758
* earlycse can do trivial with-a-block dead store Chris Lattner2011-01-031-6/+38
| | | | | | | elimination as well. This deletes 60 stores in 176.gcc that largely come from bitfield code. llvm-svn: 122736
* switch the load table to use a recycling bump pointer allocator,Chris Lattner2011-01-031-1/+4
| | | | | | speeding earlycse up by 6%. llvm-svn: 122733
* now that loads are in their own table, we can implementChris Lattner2011-01-031-1/+12
| | | | | | | store->load forwarding. This allows EarlyCSE to zap 600 more loads from 176.gcc. llvm-svn: 122732
* split loads and calls into separate tables. Loads are now just indexedChris Lattner2011-01-031-42/+74
| | | | | | by their pointer instead of using MemoryValue to wrap it. llvm-svn: 122731
* various cleanups, no functionality change.Chris Lattner2011-01-031-24/+19
| | | | llvm-svn: 122729
* Teach EarlyCSE to do trivial CSE of loads and read-only calls.Chris Lattner2011-01-031-22/+152
| | | | | | | On 176.gcc, this catches 13090 loads and calls, and increases the number of simple instructions CSE'd from 29658 to 36208. llvm-svn: 122727
* rename InstValue to SimpleValue, add some comments.Chris Lattner2011-01-031-26/+41
| | | | llvm-svn: 122725
* Allocate nodes for the scoped hash table from a recyling bump pointerChris Lattner2011-01-031-5/+9
| | | | | | allocator. This speeds up early cse by about 20% llvm-svn: 122723
* reduce redundancy in the hashing code and other misc cleanups.Chris Lattner2011-01-031-19/+23
| | | | llvm-svn: 122720
* fix some pastosChris Lattner2011-01-021-4/+4
| | | | llvm-svn: 122718
* add DEBUG and -stats output to earlycse.Chris Lattner2011-01-021-3/+35
| | | | | | Teach it to CSE the rest of the non-side-effecting instructions. llvm-svn: 122716
* Enhance earlycse to do CSE of casts, instsimplify and die.Chris Lattner2011-01-021-4/+141
| | | | | | Add a testcase. llvm-svn: 122715
* sketch out a new early cse pass. No functionality yet.Chris Lattner2011-01-021-0/+62
llvm-svn: 122713
OpenPOWER on IntegriCloud