summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Analysis/AliasAnalysisEvaluator.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Remove interprocedural-basic-aa and associated code. The AliasAnalysisDan Gohman2010-07-071-97/+37
| | | | | | | | | | | interface needs implementations to be consistent, so any code which wants to support different semantics must use a different interface. It's not currently worthwhile to add a new interface for this new concept. Document that AliasAnalysis doesn't support cross-function queries. llvm-svn: 107776
* Generalize AAEval so that it can be used both per-function andDan Gohman2010-06-281-38/+97
| | | | | | | interprocedurally. Note that as of this writing, existing alias analysis passes are not prepared to be used interprocedurally. llvm-svn: 107013
* clean up algorithm and remove operand order assumptionsGabor Greif2010-04-081-9/+24
| | | | llvm-svn: 100780
* There are two ways of checking for a given type, for example isa<PointerType>(T)Duncan Sands2010-02-161-3/+3
| | | | | | | and T->isPointerTy(). Convert most instances of the first form to the second form. Requested by Chris. llvm-svn: 96344
* Change dbgs() back to errs() as Chris requested.David Greene2009-12-231-22/+22
| | | | llvm-svn: 92073
* Convert debug messages to use dbgs(). Generally this meansDavid Greene2009-12-231-22/+23
| | | | | | s/errs/dbgs/g except for certain special cases. llvm-svn: 92026
* Remove includes of Support/Compiler.h that are no longer needed after theNick Lewycky2009-10-251-1/+0
| | | | | | VISIBILITY_HIDDEN removal. llvm-svn: 85043
* Remove VISIBILITY_HIDDEN from class/struct found inside anonymous namespaces.Nick Lewycky2009-10-251-1/+1
| | | | | | | Chris claims we should never have visibility_hidden inside any .cpp file but that's still not true even after this commit. llvm-svn: 85042
* Fix a missing newline, now that Value's operator<< doesn't add one of its own.Dan Gohman2009-08-261-1/+1
| | | | llvm-svn: 80096
* Use SetVector instead of std::set so that alias relations are tested andDan Gohman2009-08-261-8/+7
| | | | | | printed in a deterministic order. llvm-svn: 80095
* eliminate the std::ostream form of WriteAsOperand and update clients.Chris Lattner2009-08-231-6/+9
| | | | | | This also updates dominator related stuff. llvm-svn: 79825
* Make AliasAnalysis and related classes useDan Gohman2009-07-251-8/+6
| | | | | | getAnalysisIfAvailable<TargetData>(). llvm-svn: 77028
* More migration to raw_ostream, the water has dried up around the iostream hole.Daniel Dunbar2009-07-251-32/+32
| | | | | | | | | | - Some clients which used DOUT have moved to DEBUG. We are deprecating the "magic" DOUT behavior which avoided calling printing functions when the statement was disabled. In addition to being unnecessary magic, it had the downside of leaving code in -Asserts builds, and of hiding potentially unnecessary computations. llvm-svn: 77019
* simplify logic and get rid of the assumption that operand 0 is the calleeGabor Greif2009-03-241-3/+3
| | | | llvm-svn: 67642
* Tidy up several unbeseeming casts from pointer to intptr_t.Dan Gohman2008-09-041-1/+1
| | | | llvm-svn: 55779
* Clean up the use of static and anonymous namespaces. This turned upDan Gohman2008-05-131-14/+13
| | | | | | | several things that were neither in an anonymous namespace nor static but not intended to be global. llvm-svn: 51017
* Make several variable declarations static.Dan Gohman2008-05-061-9/+10
| | | | llvm-svn: 50696
* Restore isCFGOnly property of various analysis passes.Devang Patel2008-03-201-1/+1
| | | | llvm-svn: 48579
* PassInfo keep tracks whether a pass is an analysis pass or not.Devang Patel2008-03-191-2/+2
| | | | llvm-svn: 48554
* Do not use virtual function to identify an analysis pass.Devang Patel2008-03-191-4/+1
| | | | llvm-svn: 48520
* Identify Analysis pass.Devang Patel2008-03-181-0/+3
| | | | | | | Do not run analysis pass again if analysis info is still available. This fixes PR1441. llvm-svn: 48476
* Fix http://llvm.org/bugs/show_bug.cgi?id=2104 by ordering lexicographically ↵Gabor Greif2008-02-281-5/+12
| | | | | | what gets printed. Be const-correct in PrintResults and uninline it too llvm-svn: 47712
* Remove attribution from file headers, per discussion on llvmdev.Chris Lattner2007-12-291-2/+2
| | | | llvm-svn: 45418
* Executive summary: getTypeSize -> getTypeStoreSize / getABITypeSize.Duncan Sands2007-11-011-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The meaning of getTypeSize was not clear - clarifying it is important now that we have x86 long double and arbitrary precision integers. The issue with long double is that it requires 80 bits, and this is not a multiple of its alignment. This gives a primitive type for which getTypeSize differed from getABITypeSize. For arbitrary precision integers it is even worse: there is the minimum number of bits needed to hold the type (eg: 36 for an i36), the maximum number of bits that will be overwriten when storing the type (40 bits for i36) and the ABI size (i.e. the storage size rounded up to a multiple of the alignment; 64 bits for i36). This patch removes getTypeSize (not really - it is still there but deprecated to allow for a gradual transition). Instead there is: (1) getTypeSizeInBits - a number of bits that suffices to hold all values of the type. For a primitive type, this is the minimum number of bits. For an i36 this is 36 bits. For x86 long double it is 80. This corresponds to gcc's TYPE_PRECISION. (2) getTypeStoreSizeInBits - the maximum number of bits that is written when storing the type (or read when reading it). For an i36 this is 40 bits, for an x86 long double it is 80 bits. This is the size alias analysis is interested in (getTypeStoreSize returns the number of bytes). There doesn't seem to be anything corresponding to this in gcc. (3) getABITypeSizeInBits - this is getTypeStoreSizeInBits rounded up to a multiple of the alignment. For an i36 this is 64, for an x86 long double this is 96 or 128 depending on the OS. This is the spacing between consecutive elements when you form an array out of this type (getABITypeSize returns the number of bytes). This is TYPE_SIZE in gcc. Since successive elements in a SequentialType (arrays, pointers and vectors) need to be aligned, the spacing between them will be given by getABITypeSize. This means that the size of an array is the length times the getABITypeSize. It also means that GEP computations need to use getABITypeSize when computing offsets. Furthermore, if an alloca allocates several elements at once then these too need to be aligned, so the size of the alloca has to be the number of elements multiplied by getABITypeSize. Logically speaking this doesn't have to be the case when allocating just one element, but it is simpler to also use getABITypeSize in this case. So alloca's and mallocs should use getABITypeSize. Finally, since gcc's only notion of size is that given by getABITypeSize, if you want to output assembler etc the same as gcc then getABITypeSize is the size you want. Since a store will overwrite no more than getTypeStoreSize bytes, and a read will read no more than that many bytes, this is the notion of size appropriate for alias analysis calculations. In this patch I have corrected all type size uses except some of those in ScalarReplAggregates, lib/Codegen, lib/Target (the hard cases). I will get around to auditing these too at some point, but I could do with some help. Finally, I made one change which I think wise but others might consider pointless and suboptimal: in an unpacked struct the amount of space allocated for a field is now given by the ABI size rather than getTypeStoreSize. I did this because every other place that reserves memory for a type (eg: alloca) now uses getABITypeSize, and I didn't want to make an exception for unpacked structs, i.e. I did it to make things more uniform. This only effects structs containing long doubles and arbitrary precision integers. If someone wants to pack these types more tightly they can always use a packed struct. llvm-svn: 43620
* Fix typo in comment.Nick Lewycky2007-05-061-1/+1
| | | | llvm-svn: 36873
* Drop 'const'Devang Patel2007-05-031-2/+2
| | | | llvm-svn: 36662
* Use 'static const char' instead of 'static const int'.Devang Patel2007-05-021-2/+2
| | | | | | | Due to darwin gcc bug, one version of darwin linker coalesces static const int, which defauts PassID based pass identification. llvm-svn: 36652
* Do not use typeinfo to identify pass in pass manager.Devang Patel2007-05-011-0/+4
| | | | llvm-svn: 36632
* Make classes in anonymous namespaces use VISIBILITY_HIDDEN to help reduceReid Spencer2007-02-051-1/+2
| | | | | | LLVM's footprint and speed up linking. llvm-svn: 33941
* Removed more <iostream> includesBill Wendling2006-12-071-4/+3
| | | | llvm-svn: 32321
* Changed llvm_ostream et all to OStream. llvm_cerr, llvm_cout, llvm_null, areBill Wendling2006-12-071-26/+26
| | | | | | now cerr, cout, and NullStream resp. llvm-svn: 32298
* Remove the 'printname' argument to WriteAsOperand. It is always true, andChris Lattner2006-12-061-3/+3
| | | | | | passing false would make the asmprinter fail anyway. llvm-svn: 32264
* Removed some of the iostream #includes. Moved towards converting to usingBill Wendling2006-11-281-22/+22
| | | | | | llvm streams llvm-svn: 31983
* eliminate RegisterOpt. It does the same thing as RegisterPass.Chris Lattner2006-08-271-1/+1
| | | | llvm-svn: 29925
* Remove trailing whitespaceMisha Brukman2005-04-211-17/+17
| | | | llvm-svn: 21416
* there is no point comparing against null pointer.Chris Lattner2005-03-291-2/+3
| | | | llvm-svn: 20925
* Factor out percentage printing into its own function. Make two changes toChris Lattner2005-03-261-14/+19
| | | | | | | | the function: print more precision XX.X% instead of XX%, and cast to ULL before scaling by 100/1000 to avoid wrap around for large numbers of queries (such as occur for 253.perlbmk and 176.gcc) llvm-svn: 20872
* Interchange this loop so that we test all pointers against one call siteChris Lattner2005-03-261-10/+11
| | | | | | | before moving on to the next call site. This will be a more efficient way to compute the mod/ref set for AA implementations like DSA. llvm-svn: 20866
* Do not include the Function* for direct call/invoke instructions in theChris Lattner2005-03-171-1/+6
| | | | | | alias evaluation. Clients really don't care. llvm-svn: 20664
* This mega patch converts us from using Function::a{iterator|begin|end} toChris Lattner2005-03-151-1/+1
| | | | | | | | using Function::arg_{iterator|begin|end}. Likewise Module::g* -> Module::global_*. This patch is contributed by Gabor Greif, thanks! llvm-svn: 20597
* Add even more missing createXxxPass functions.Jeff Cohen2005-01-081-0/+3
| | | | llvm-svn: 19402
* When evaluating an AA, pass in size infoChris Lattner2004-11-261-28/+38
| | | | llvm-svn: 18264
* Changes For Bug 352Reid Spencer2004-09-011-1/+1
| | | | | | | | Move include/Config and include/Support into include/llvm/Config, include/llvm/ADT and include/llvm/Support. From here on out, all LLVM public header files must be under include/llvm/. llvm-svn: 16137
* Fix #includes of i*.h => Instructions.h as per PR403.Misha Brukman2004-07-291-2/+1
| | | | llvm-svn: 15334
* Fix incorrect computation of mod/ref sets. Do not ask for mod/ref informationChris Lattner2004-07-171-21/+29
| | | | | | for objects of size 0. llvm-svn: 14908
* Print modref information in a useful way.Chris Lattner2004-07-171-4/+14
| | | | llvm-svn: 14907
* Cleanups: fold two loops into oneChris Lattner2004-07-171-3/+9
| | | | | | New features: -print-all-alias-modref-info option, print more info llvm-svn: 14906
* Add #include <iostream> since Value.h does not #include it any more.Reid Spencer2004-07-041-0/+2
| | | | llvm-svn: 14622
* Changes to fix up the inst_iterator to pass to boost iterator checks. ThisChris Lattner2004-04-271-4/+4
| | | | | | patch was graciously contributed by Vladimir Prus. llvm-svn: 13185
* Simplify code to process CallSites (thanks to Chris).Misha Brukman2004-03-121-4/+2
| | | | llvm-svn: 12334
OpenPOWER on IntegriCloud