summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Rewrite the SDep class, and simplify some of the related code.Dan Gohman2008-12-0912-376/+526
| | | | | | | | | | | | | | | | | The Cost field is removed. It was only being used in a very limited way, to indicate when the scheduler should attempt to protect a live register, and it isn't really needed to do that. If we ever want the scheduler to start inserting copies in non-prohibitive situations, we'll have to rethink some things anyway. A Latency field is added. Instead of giving each node a single fixed latency, each edge can have its own latency. This will eventually be used to model various micro-architecture properties more accurately. The PointerIntPair class and an internal union are now used, which reduce the overall size. llvm-svn: 60806
* loosen up an assertion that isn't valid when called fromChris Lattner2008-12-092-1/+27
| | | | | | | invalidateCachedPointerInfo. Thanks to Bill for sending me a testcase. llvm-svn: 60805
* Minor code simplification.Dan Gohman2008-12-091-3/+3
| | | | llvm-svn: 60804
* Prevent bogus warning on unimplemented setter/getter when userFariborz Jahanian2008-12-093-0/+27
| | | | | | has added declaration of these methods in its @interface. llvm-svn: 60803
* Add sub/mul overflow intrinsics. This currently doesn't have aBill Wendling2008-12-0915-92/+332
| | | | | | | target-independent way of determining overflow on multiplication. It's very tricky. Patch by Zoltan Varga! llvm-svn: 60800
* Teach GVN to invalidate some memdep information when it does an RAUWChris Lattner2008-12-093-2/+41
| | | | | | | | | | | | | | | | | | | | | | | | of a pointer. This allows is to catch more equivalencies. For example, the type_lists_compatible_p function used to require two iterations of the gvn pass (!) to delete its 18 redundant loads because the first pass would CSE all the addressing computation cruft, which would unblock the second memdep/gvn passes from recognizing them. This change allows memdep/gvn to catch all 18 when run just once on the function (as is typical :) instead of just 3. On all of 403.gcc, this bumps up the # reundandancies found from: 63 gvn - Number of instructions PRE'd 153991 gvn - Number of instructions deleted 50069 gvn - Number of loads deleted to: 63 gvn - Number of instructions PRE'd 154137 gvn - Number of instructions deleted 50185 gvn - Number of loads deleted +120 loads deleted isn't bad. llvm-svn: 60799
* Fix PR3117: not all nodes being legalized. TheDuncan Sands2008-12-0910-209/+510
| | | | | | | | | | | | | | | | | | | | | | | essential problem was that the DAG can contain random unused nodes which were never analyzed. When remapping a value of a node being processed, such a node may become used and need to be analyzed; however due to operands being transformed during analysis the node may morph into a different one. Users of the morphing node need to be updated, and this wasn't happening. While there I added a bunch of documentation and sanity checks, so I (or some other poor soul) won't have to scratch their head over this stuff so long trying to remember how it was all supposed to work next time some obscure problem pops up! The extra sanity checking exposed a few places where invariants weren't being preserved, so those are fixed too. Since some of the sanity checking is expensive, I added a flag to turn it on. It is also turned on when building with ENABLE_EXPENSIVE_CHECKS=1. llvm-svn: 60797
* Have BasicStoreManager::getLValueElement() have logic similar to ↵Ted Kremenek2008-12-091-2/+37
| | | | | | BasicStoreManager::getLValueField() (i.e., don't just return the 'base' as the SVal) llvm-svn: 60795
* Teach BasicAA::getModRefInfo(CallSite, CallSite) someChris Lattner2008-12-094-22/+82
| | | | | | | | | | | | | | | | | | | | | | tricks based on readnone/readonly functions. Teach memdep to look past readonly calls when analyzing deps for a readonly call. This allows elimination of a few more calls from 403.gcc: before: 63 gvn - Number of instructions PRE'd 153986 gvn - Number of instructions deleted 50069 gvn - Number of loads deleted after: 63 gvn - Number of instructions PRE'd 153991 gvn - Number of instructions deleted 50069 gvn - Number of loads deleted 5 calls isn't much, but this adds plumbing for the next change. llvm-svn: 60794
* Add testcase for commit r60781.Steve Naroff2008-12-091-0/+95
| | | | llvm-svn: 60793
* Support for implementation of property in the case whereFariborz Jahanian2008-12-097-15/+101
| | | | | | | the synthesis is in an implementation of s subclass of a super class where the property has been declared. llvm-svn: 60792
* Kick out the proof-of-concept ASTOwner and replace it with ASTOwningResultSebastian Redl2008-12-0914-233/+133
| | | | llvm-svn: 60791
* Add preliminary CFG support for @throw. We basically treat it like a return ↵Ted Kremenek2008-12-091-1/+23
| | | | | | statement. llvm-svn: 60790
* In GRExprEngine treat @throw as an 'abort' that ends the current path. This ↵Ted Kremenek2008-12-091-0/+9
| | | | | | is a temporary solution. llvm-svn: 60789
* Fix a fixme: allow memdep to see past read-only calls when doingChris Lattner2008-12-091-4/+13
| | | | | | | | | | | | | load dependence queries. This allows GVN to eliminate a few more instructions on 403.gcc: 152598 gvn - Number of instructions deleted 49240 gvn - Number of loads deleted after: 153986 gvn - Number of instructions deleted 50069 gvn - Number of loads deleted llvm-svn: 60786
* rename getNonLocalDependency -> getNonLocalCallDependency, and removeChris Lattner2008-12-093-52/+26
| | | | | | pointer stuff from it, simplifying the code a bit. llvm-svn: 60783
* Lay the groundwork for converting the entire parser-sema chain to smart ↵Sebastian Redl2008-12-094-36/+402
| | | | | | pointers. llvm-svn: 60782
* Sema::ActOnMethodDeclaration(): Make sure we perform the default ↵Steve Naroff2008-12-091-2/+7
| | | | | | | | | function/array conversion for parameter types. This fixes <rdar://problem/6424064> checker on xcode: (possible bad AST) can the type of a method parameter really have "isFunctionType() == true"? and http://llvm.org/bugs/show_bug.cgi?id=2997. llvm-svn: 60781
* Switch GVN::processNonLocalLoad to using the new Chris Lattner2008-12-091-20/+11
| | | | | | | | | | | | MemDep::getNonLocalPointerDependency method. There are some open issues with this (missed optimizations) and plenty of future work, but this does allow GVN to eliminate *slightly* more loads (49246 vs 49033). Switching over now allows simplification of the other code path in memdep. llvm-svn: 60780
* random cleanups, no functionality change.Chris Lattner2008-12-091-14/+26
| | | | llvm-svn: 60779
* Fix a serious null termination bug found by David Chisnall!Chris Lattner2008-12-091-1/+1
| | | | llvm-svn: 60778
* xfail this for now.Evan Cheng2008-12-091-0/+1
| | | | llvm-svn: 60777
* Back out 60748 for now. It's breaking SPASS, 254.gap, and 464.h264ref.Evan Cheng2008-12-091-5/+1
| | | | llvm-svn: 60776
* Cosmetic changes.Evan Cheng2008-12-091-6/+8
| | | | llvm-svn: 60771
* remove unused varNuno Lopes2008-12-091-2/+0
| | | | llvm-svn: 60770
* Whitespace cleanups.Dan Gohman2008-12-091-12/+14
| | | | llvm-svn: 60769
* Remove Clang tests since clang is not installed on the buildbots.Mikhail Glushenkov2008-12-093-27/+0
| | | | llvm-svn: 60767
* Add some rudimentary tests for .Mikhail Glushenkov2008-12-093-0/+27
| | | | llvm-svn: 60766
* Man page typo fix.Mikhail Glushenkov2008-12-091-1/+1
| | | | llvm-svn: 60765
* Support -emit-llvm properly (with -S and -c).Mikhail Glushenkov2008-12-092-14/+27
| | | | llvm-svn: 60764
* Fill in C++ status table for expressions.Sebastian Redl2008-12-091-70/+251
| | | | llvm-svn: 60763
* Consistently use smart pointers for stmt and expr nodes in parser local ↵Sebastian Redl2008-12-0911-522/+530
| | | | | | variables. llvm-svn: 60761
* Fix <rdar://problem/6429113> clang ObjC rewriter: crash rewriting file with ↵Steve Naroff2008-12-092-6/+49
| | | | | | | | Blocks and properties More fancy footwork to cope with rewriting property 'setters'. llvm-svn: 60760
* initialize member variable.Zhongxing Xu2008-12-091-1/+1
| | | | llvm-svn: 60759
* Add utility method. Remove an unused method.Zhongxing Xu2008-12-092-2/+4
| | | | llvm-svn: 60758
* Handle a compiler warning.Duncan Sands2008-12-091-1/+1
| | | | llvm-svn: 60755
* fix typos gabor noticedChris Lattner2008-12-091-1/+1
| | | | llvm-svn: 60754
* Correct my English.Bill Wendling2008-12-091-8/+9
| | | | llvm-svn: 60753
* restructure the top level non-local ptr dep query to handle Chris Lattner2008-12-091-19/+26
| | | | | | | | the first block of a query specially. This makes the "complete query caching" subsystem more effective, avoiding predecessor queries. This speeds up GVN another 4%. llvm-svn: 60752
* rename getNonLocalPointerDepInternal -> getNonLocalPointerDepFromBBChris Lattner2008-12-092-71/+93
| | | | | | | and split its inner loop out into a new GetNonLocalInfoForBlock function. No functionality change. llvm-svn: 60751
* DisableGVCompilation should not abort on internal GlobalValue's.Evan Cheng2008-12-092-4/+5
| | | | llvm-svn: 60750
* In LegalizeOp, don't change the result type of CONVERT_RNDSAT when promotingMon P Wang2008-12-091-2/+2
| | | | | | one of its operand. llvm-svn: 60749
* It's easy to handle SLE/SGE when the loop has a unit stride.Nick Lewycky2008-12-092-1/+29
| | | | llvm-svn: 60748
* if we have two elements, insert both, don't use std::sort.Chris Lattner2008-12-091-3/+16
| | | | | | This speeds up the new GVN by another 3% llvm-svn: 60747
* If we're only adding one new element to 'Cache', insert it into its knownChris Lattner2008-12-091-1/+12
| | | | | | | position instead of using a full sort. This speeds up GVN by ~4% with the new memdep stuff. llvm-svn: 60746
* convert a couple other places that use pred_iterator to use the cachingChris Lattner2008-12-091-2/+4
| | | | | | pred iterator. llvm-svn: 60745
* newline at end of phileChris Lattner2008-12-091-1/+2
| | | | llvm-svn: 60744
* use hte new pred cache to speed up the new non-local memdepChris Lattner2008-12-092-14/+31
| | | | | | | queries. This speeds up GVN using the new queries (not yet checked in) by just over 10%. llvm-svn: 60743
* pred_iterator got a lot slower since use-diet landed. This is a Chris Lattner2008-12-091-0/+56
| | | | | | | really simple cache class for these queries. Hopefully this can be removed if pred_iterator speeds back up. llvm-svn: 60742
* CellSPU:Scott Michel2008-12-092-2/+2
| | | | | | | - Fix call.ll and call_indirect.ll expected results, now that it's using a different pre-register allocation scheduler. llvm-svn: 60741
OpenPOWER on IntegriCloud