summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Analysis/AliasAnalysis.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-051-3/+3
| | | | | | class. llvm-svn: 202945
* Make DataLayout a plain object, not a pass.Rafael Espindola2014-02-251-1/+2
| | | | | | | Instead, have a DataLayoutPass that holds one. This will allow parts of LLVM don't don't handle passes to also use DataLayout. llvm-svn: 202168
* Rename some member variables from TD to DL.Rafael Espindola2014-02-181-4/+4
| | | | | | TargetData was renamed DataLayout back in r165242. llvm-svn: 201581
* [cleanup] Move the Dominators.h and Verifier.h headers into the IRChandler Carruth2014-01-131-1/+1
| | | | | | | | | | | | | | | | | | directory. These passes are already defined in the IR library, and it doesn't make any sense to have the headers in Analysis. Long term, I think there is going to be a much better way to divide these matters. The dominators code should be fully separated into the abstract graph algorithm and have that put in Support where it becomes obvious that evn Clang's CFGBlock's can use it. Then the verifier can manually construct dominance information from the Support-driven interface while the Analysis library can provide a pass which both caches, reconstructs, and supports a nice update API. But those are very long term, and so I don't want to leave the really confusing structure until that day arrives. llvm-svn: 199082
* Re-sort all of the includes with ./utils/sort_includes.py so thatChandler Carruth2014-01-071-1/+1
| | | | | | | | | | subsequent changes are easier to review. About to fix some layering issues, and wanted to separate out the necessary churn. Also comment and sink the include of "Windows.h" in three .inc files to match the usage in Memory.inc. llvm-svn: 198685
* Reimplement isPotentiallyReachable to make nocapture deduction much stronger.Nick Lewycky2013-07-271-22/+3
| | | | | | | | | | Adds unit tests for it too. Split BasicBlockUtils into an analysis-half and a transforms-half, and put the analysis bits into a new Analysis/CFG.{h,cpp}. Promote isPotentiallyReachable into llvm::isPotentiallyReachable and move it into Analysis/CFG. llvm-svn: 187283
* Give 'hasPath' a longer but clearer name 'isPotentiallyReachable'. Also expandNick Lewycky2013-07-181-5/+7
| | | | | | | the comment. No functionality change. This change broken out of http://llvm-reviews.chandlerc.com/D996 . llvm-svn: 186558
* Eliminate trivial redundant loads across nocapture+readonly calls to uncapturedNick Lewycky2013-07-071-4/+11
| | | | | | pointer arguments. llvm-svn: 185776
* Make BasicAliasAnalysis recognize the fact a noalias argument cannot alias ↵Michael Kuperstein2013-05-281-0/+9
| | | | | | another argument, even if the other argument is not itself marked noalias. llvm-svn: 182755
* Move isKnownNonNull out of AliasAnalysis.h and into ValueTracking.cpp sinceDan Gohman2013-01-311-16/+0
| | | | | | | it isn't really an AliasAnalysis concept, and ValueTracking has similar things that it could plausibly share code with some day. llvm-svn: 174027
* Memory Dependence Analysis: fix a miscompile that uses DT to approxmiate theManman Ren2013-01-041-4/+34
| | | | | | | | | | | | reachablity. We conservatively approximate the reachability analysis by saying it is not reachable if there is a single path starting from "From" and the path does not reach "To". rdar://12801584 llvm-svn: 171512
* Move all of the header files which are involved in modelling the LLVM IRChandler Carruth2013-01-021-7/+7
| | | | | | | | | | | | | | | | | | | | | into their new header subdirectory: include/llvm/IR. This matches the directory structure of lib, and begins to correct a long standing point of file layout clutter in LLVM. There are still more header files to move here, but I wanted to handle them in separate commits to make tracking what files make sense at each layer easier. The only really questionable files here are the target intrinsic tablegen files. But that's a battle I'd rather not fight today. I've updated both CMake and Makefile build systems (I think, and my tests think, but I may have missed something). I've also re-sorted the includes throughout the project. I'll be committing updates to Clang, DragonEgg, and Polly momentarily. llvm-svn: 171366
* Rename the 'Attributes' class to 'Attribute'. It's going to represent a ↵Bill Wendling2012-12-191-1/+1
| | | | | | single attribute in the future. llvm-svn: 170502
* Use the new script to sort the includes of every file under lib.Chandler Carruth2012-12-031-4/+4
| | | | | | | | | | | | | | | | | Sooooo many of these had incorrect or strange main module includes. I have manually inspected all of these, and fixed the main module include to be the nearest plausible thing I could find. If you own or care about any of these source files, I encourage you to take some time and check that these edits were sensible. I can't have broken anything (I strictly added headers, and reordered them, never removed), but they may not be the headers you'd really like to identify as containing the API being implemented. Many forward declarations and missing includes were added to a header files to allow them to parse cleanly when included first. The main module rule does in fact have its merits. =] llvm-svn: 169131
* Use the attribute enums to query if a parameter has an attribute.Bill Wendling2012-10-091-1/+1
| | | | llvm-svn: 165550
* Move TargetData to DataLayout.Micah Villmow2012-10-081-3/+3
| | | | llvm-svn: 165402
* Use method to query for NoAlias attribute.Bill Wendling2012-10-041-1/+1
| | | | llvm-svn: 165211
* Make MemoryBuiltins aware of TargetLibraryInfo.Benjamin Kramer2012-08-291-0/+2
| | | | | | | | | | | | | | | | This disables malloc-specific optimization when -fno-builtin (or -ffreestanding) is specified. This has been a problem for a long time but became more severe with the recent memory builtin improvements. Since the memory builtin functions are used everywhere, this required passing TLI in many places. This means that functions that now have an optional TLI argument, like RecursivelyDeleteTriviallyDeadFunctions, won't remove dead mallocs anymore if the TLI argument is missing. I've updated most passes to do the right thing. Fixes PR13694 and probably others. llvm-svn: 162841
* Move the capture analysis from MemoryDependencyAnalysis to a more general placeChad Rosier2012-05-141-0/+83
| | | | | | | | | so that it can be reused in MemCpyOptimizer. This analysis is needed to remove an unnecessary memcpy when returning a struct into a local variable. rdar://11341081 PR12686 llvm-svn: 156776
* Move isKnownNonNull from private implementation detail of BasicAA to a publicNick Lewycky2012-02-251-0/+16
| | | | | | function that others can use, next to llvm::isIdentifiedObject. llvm-svn: 151446
* Enhance alias analysis for atomic instructions a bit. Upgrade a couple ↵Eli Friedman2011-09-261-0/+40
| | | | | | alias-analysis tests to the new atomic instructions. llvm-svn: 140557
* Misc analysis passes that need to be aware of atomic load/store.Eli Friedman2011-08-151-4/+4
| | | | llvm-svn: 137650
* land David Blaikie's patch to de-constify Type, with a few tweaks.Chris Lattner2011-07-181-1/+1
| | | | llvm-svn: 135375
* When analyzing functions known to only access argument pointees,Dan Gohman2011-04-271-9/+28
| | | | | | | | | only check arguments with pointer types. Update the documentation of IntrReadArgMem reflect this. While here, add support for TBAA tags on intrinsic calls. llvm-svn: 130317
* Stub out a new updating interface to AliasAnalysis, allowing stateful ↵Owen Anderson2011-01-031-0/+6
| | | | | | | | | analyses to be informed when a pointer value has potentially become escaping. Implementations can choose to either fall back to conservative responses for that value, or may recompute their analysis to accomodate the change. llvm-svn: 122777
* Make memcpyopt TBAA-aware.Dan Gohman2010-12-161-4/+10
| | | | llvm-svn: 121944
* getLocationForDest should work for memset as well.Chris Lattner2010-11-301-1/+1
| | | | llvm-svn: 120380
* add "getLocation" method to AliasAnalysis for getting the source andChris Lattner2010-11-211-0/+23
| | | | | | | | destination location of a memcpy/memmove. I'm not clear about whether TBAA works on these, so I'm leaving it out for now. Dan, please revisit this when convenient. llvm-svn: 119928
* Add helper functions for computing the Location of load, store,Dan Gohman2010-11-111-12/+21
| | | | | | and vaarg instructions. llvm-svn: 118845
* Add a doesAccessArgPointees helper function, and update code to useDan Gohman2010-11-101-22/+24
| | | | | | it, and to be consistent. llvm-svn: 118692
* Make ModRefBehavior a lattice. Use this to clean up AliasAnalysisDan Gohman2010-11-101-1/+1
| | | | | | chaining and simplify FunctionAttrs' GetModRefBehavior logic. llvm-svn: 118660
* Teach AliasAnalysis about AccessesArgumentsReadonly.Dan Gohman2010-11-091-6/+8
| | | | llvm-svn: 118621
* Extend the AliasAnalysis::pointsToConstantMemory interface to allow itDan Gohman2010-11-081-2/+3
| | | | | | | | | | | | to optionally look for constant or local (alloca) memory. Teach BasicAliasAnalysis::pointsToConstantMemory to look through Select and Phi nodes, and to support looking for local memory. Remove FunctionAttrs' PointsToLocalOrConstantMemory function, now that AliasAnalysis knows all the tricks that it knew. llvm-svn: 118412
* Delete getIntrinsicModRefBehavior. Clients can just use the normalDan Gohman2010-11-081-7/+0
| | | | | | | getModRefBehavior now, since it now understands intrinsics as well as normal functions. llvm-svn: 118411
* Update comments; BasicAA is no longer necessarily the end of the chain.Dan Gohman2010-10-251-3/+3
| | | | llvm-svn: 117268
* Reintroduce these asserts, now that BasicAA is a normal AliasAnalysis pass.Dan Gohman2010-10-251-6/+3
| | | | llvm-svn: 117266
* Move NoAA out of BasicAliasAnalysis.cpp into its own file, now thatDan Gohman2010-10-191-6/+0
| | | | | | | it doesn't have a special relationship with BasicAliasAnalysis anymore. llvm-svn: 116876
* Reapply r116831 and r116839, converting AliasAnalysis to useDan Gohman2010-10-191-1/+1
| | | | | | uint64_t, plus fixes for places I missed before. llvm-svn: 116875
* Revert r116831 and r116839, which are breaking selfhost builds.Dan Gohman2010-10-191-1/+1
| | | | llvm-svn: 116858
* Change AliasAnalysis and its clients to use uint64_t instead of unsignedDan Gohman2010-10-191-1/+1
| | | | | | for representing object sizes, for consistency with other parts of LLVM. llvm-svn: 116831
* Get rid of static constructors for pass registration. Instead, every pass ↵Owen Anderson2010-10-191-1/+1
| | | | | | | | | | | | | | | | | exposes an initializeMyPassFunction(), which must be called in the pass's constructor. This function uses static dependency declarations to recursively initialize the pass's dependencies. Clients that only create passes through the createFooPass() APIs will require no changes. Clients that want to use the CommandLine options for passes will need to manually call the appropriate initialization functions in PassInitialization.h before parsing commandline arguments. I have tested this with all standard configurations of clang and llvm-gcc on Darwin. It is possible that there are problems with the static dependencies that will only be visible with non-standard options. If you encounter any crash in pass registration/creation, please send the testcase to me directly. llvm-svn: 116820
* Consistently use AliasAnalysis::UnknownSize instead of hardcoding ~0u.Dan Gohman2010-10-191-1/+1
| | | | llvm-svn: 116815
* Analysis groups need to initialize their default implementations.Owen Anderson2010-10-131-1/+1
| | | | llvm-svn: 116441
* Now with fewer extraneous semicolons!Owen Anderson2010-10-071-1/+1
| | | | llvm-svn: 115996
* Hide analysis group registration behind a macro, just like pass registration.Owen Anderson2010-10-061-1/+1
| | | | llvm-svn: 115835
* Remove the experimental AliasAnalysis::getDependency interface, whichDan Gohman2010-09-141-254/+31
| | | | | | | | | | | isn't a good level of abstraction for memdep. Instead, generalize AliasAnalysis::alias and related interfaces with a new Location class for describing a memory location. For now, this is the same Pointer and Size as before, plus an additional field for a TBAA tag. Also, introduce a fixed MD_tbaa metadata tag kind. llvm-svn: 113858
* Extend the getDependence query with support for PHI translation.Dan Gohman2010-09-091-12/+49
| | | | llvm-svn: 113521
* Add a new experimental generalized dependence query interface toDan Gohman2010-09-081-0/+192
| | | | | | | | AliasAnalysis, and some code for implementing the new query on top of existing implementations by making standard alias and getModRefInfo queries. llvm-svn: 113329
* Implement a proper getModRefInfo for va_arg.Dan Gohman2010-08-061-0/+17
| | | | llvm-svn: 110458
* Be more conservative in the face of volatile.Dan Gohman2010-08-061-8/+8
| | | | llvm-svn: 110456
OpenPOWER on IntegriCloud