summaryrefslogtreecommitdiffstats
path: root/llvm/lib/VMCore/Function.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Push LLVMContexts through the IntegerType APIs.Owen Anderson2009-08-131-1/+1
| | | | llvm-svn: 78948
* Rename MVT to EVT, in preparation for splitting SimpleValueType out into its ↵Owen Anderson2009-08-101-2/+2
| | | | | | own struct type. llvm-svn: 78610
* Move types back to the 2.5 API.Owen Anderson2009-07-291-1/+1
| | | | llvm-svn: 77516
* Initial update to VMCore to use Twines for string arguments.Daniel Dunbar2009-07-251-2/+2
| | | | | | | - The only meat here is in Value.{h,cpp} the rest is essential 'const std::string &' -> 'const Twine &'. llvm-svn: 77048
* Get rid of the Pass+Context magic.Owen Anderson2009-07-221-4/+2
| | | | llvm-svn: 76702
* LLVMContext-ification.Owen Anderson2009-07-071-3/+6
| | | | llvm-svn: 74973
* Have scoped mutexes take referenes instead of pointers.Owen Anderson2009-07-071-4/+4
| | | | llvm-svn: 74931
* "LLVMContext* " --> "LLVMContext *"Owen Anderson2009-07-061-1/+1
| | | | llvm-svn: 74878
* More LLVMContext-ification.Owen Anderson2009-07-051-2/+2
| | | | llvm-svn: 74807
* Add an accessor to Function so that Passes can easily get access to the context.Owen Anderson2009-07-021-0/+6
| | | | llvm-svn: 74714
* Simplify.Owen Anderson2009-06-181-15/+7
| | | | llvm-svn: 73723
* Move Threading.[h|cpp] from Support to System.Owen Anderson2009-06-181-1/+1
| | | | llvm-svn: 73707
* Reapply r73647 in a non-broken form.Owen Anderson2009-06-171-15/+25
| | | | llvm-svn: 73662
* Protect the GC table in Function.cppOwen Anderson2009-06-171-19/+25
| | | | llvm-svn: 73647
* Implement and use new method Function::hasAddressTaken().Jay Foad2009-06-101-0/+11
| | | | llvm-svn: 73164
* further simplifications arising from peruse of the more declarative interfaceGabor Greif2009-03-071-7/+0
| | | | llvm-svn: 66333
* Another sentinel optimization. This one should alwaysGabor Greif2009-03-011-7/+0
| | | | | | be a win, since almost every interesting function has at least one Argument. llvm-svn: 65778
* Reuse a technique (pioneered for BasicBlocks) of superposing ilist withGabor Greif2009-03-011-7/+0
| | | | | | | | | | | | its sentinel. This is quite a win when a function really has a basic block. When the function is just a declaration (and stays so) the old way did not allocate a sentinel. So this change is most beneficial when the ratio of function definition to declaration is high. I.e. linkers etc. Incidentally these are the most resource demanding applications, so I expect that the reduced malloc traffic, locality and space savings outweigh the cost of addition of two pointers to Function. llvm-svn: 65776
* Added support to have TableGen provide information if an intrinsic (coreMon P Wang2009-02-241-0/+10
| | | | | | or target) can be overloaded or not. llvm-svn: 65404
* Reapply 63765. Patches for clang and llvm-gcc to follow.Dale Johannesen2009-02-051-5/+7
| | | | llvm-svn: 63812
* Reverting 63765. This broke the build of both clangDale Johannesen2009-02-041-7/+5
| | | | | | and llvm-gcc. llvm-svn: 63786
* New feature: add support for target intrinsics being defined in theNate Begeman2009-02-041-5/+7
| | | | | | | | | target directories themselves. This also means that VMCore no longer needs to know about every target's list of intrinsics. Future work will include converting the PowerPC target to this interface as an example implementation. llvm-svn: 63765
* make tblgen emit the entire Intrinsic::getAttributes method, Chris Lattner2009-01-121-10/+1
| | | | | | not a random piece of it. No functionality change. llvm-svn: 62066
* Tidy up #includes, deleting a bunch of unnecessary #includes.Dan Gohman2009-01-051-1/+0
| | | | llvm-svn: 61715
* tighten up return type checkChris Lattner2009-01-051-4/+2
| | | | llvm-svn: 61677
* Don't analyze arguments already marked 'nocapture'.Duncan Sands2008-12-311-0/+7
| | | | llvm-svn: 61532
* Now Attributes are divided in three groupsDevang Patel2008-09-261-1/+1
| | | | | | | | | | | | | - return attributes - inreg, zext and sext - parameter attributes - function attributes - nounwind, readonly, readnone, noreturn Return attributes use 0 as the index. Function attributes use ~0U as the index. This patch requires corresponding changes in llvm-gcc and clang. llvm-svn: 56704
* Large mechanical patch.Devang Patel2008-09-251-20/+20
| | | | | | | | | | | | | | | s/ParamAttr/Attribute/g s/PAList/AttrList/g s/FnAttributeWithIndex/AttributeWithIndex/g s/FnAttr/Attribute/g This sets the stage - to implement function notes as function attributes and - to distinguish between function attributes and return value attributes. This requires corresponding changes in llvm-gcc and clang. llvm-svn: 56622
* s/ParamAttrsWithIndex/FnAttributeWithIndex/gDevang Patel2008-09-241-1/+1
| | | | llvm-svn: 56535
* s/ParameterAttributes/Attributes/gDevang Patel2008-09-231-5/+5
| | | | llvm-svn: 56513
* Use parameter attribute store (soon to be renamed) forDevang Patel2008-09-231-1/+0
| | | | | | Function Notes also. Function notes are stored at index ~0. llvm-svn: 56511
* Initialize function notes.Devang Patel2008-09-021-0/+2
| | | | llvm-svn: 55645
* Rename some GC classes so that their roll will hopefully be clearer.Gordon Henriksen2008-08-171-30/+32
| | | | | | | | | | | | | | | | | | In particular, Collector was confusing to implementors. Several thought that this compile-time class was the place to implement their runtime GC heap. Of course, it doesn't even exist at runtime. Specifically, the renames are: Collector -> GCStrategy CollectorMetadata -> GCFunctionInfo CollectorModuleMetadata -> GCModuleInfo CollectorRegistry -> GCRegistry Function::getCollector -> getGC (setGC, hasGC, clearGC) Several accessors and nested types have also been renamed to be consistent. These changes should be obvious. llvm-svn: 54899
* Added support for overloading intrinsics (atomics) based on pointersMon P Wang2008-07-301-2/+7
| | | | | | | to different address spaces. This alters the naming scheme for those intrinsics, e.g., atomic.load.add.i32 => atomic.load.add.i32.p0i32 llvm-svn: 54195
* Add some helpers for manipulating functionDuncan Sands2008-07-081-13/+7
| | | | | | parameter attributes. llvm-svn: 53228
* Wrap MVT::ValueType in a struct to get type safetyDuncan Sands2008-06-061-1/+1
| | | | | | | | | | | | | | | | and better control the abstraction. Rename the type to MVT. To update out-of-tree patches, the main thing to do is to rename MVT::ValueType to MVT, and rewrite expressions like MVT::getSizeInBits(VT) in the form VT.getSizeInBits(). Use VT.getSimpleVT() to extract a MVT::SimpleValueType for use in switch statements (you will get an assert failure if VT is an extended value type - these shouldn't exist after type legalization). This results in a small speedup of codegen and no new testsuite failures (x86-64 linux). llvm-svn: 52044
* Factor code to copy global value attributes likeDuncan Sands2008-05-261-0/+12
| | | | | | | | | | | | | | | the section or the visibility from one global value to another: copyAttributesFrom. This is particularly useful for duplicating functions: previously this was done by explicitly copying each attribute in turn at each place where a new function was created out of an old one, with the result that obscure attributes were regularly forgotten (like the collector or the section). Hopefully now everything is uniform and nothing is forgotten. llvm-svn: 51567
* Add functions to enable adding a single attribute to a function andEric Christopher2008-05-161-0/+6
| | | | | | its associated call site. llvm-svn: 51204
* Fix a bunch of 80col violations that arose from the Create API change. Tweak ↵Gabor Greif2008-05-151-1/+2
| | | | | | makefile targets to find these better. llvm-svn: 51143
* Make StripPointerCast a common function (should we mak it method of Value ↵Anton Korobeynikov2008-05-061-24/+0
| | | | | | instead?) llvm-svn: 50775
* Expose parameter attributes via C bindings.Gordon Henriksen2008-04-281-0/+11
| | | | | | Patch by Anders Johnsen! llvm-svn: 50360
* Convenience method for setting the nounwindDuncan Sands2008-04-081-0/+9
| | | | | | attribute for a function. llvm-svn: 49373
* Make sure that intrinsics automagically get theDuncan Sands2008-04-071-3/+5
| | | | | | | right parameter attributes no matter how they are obtained. llvm-svn: 49335
* API changes for class Use size reduction, wave 1.Gabor Greif2008-04-061-1/+1
| | | | | | | | Specifically, introduction of XXX::Create methods for Users that have a potentially variable number of Uses. llvm-svn: 49277
* move a bunch of trivial methods to be inline.Chris Lattner2008-03-131-36/+0
| | | | llvm-svn: 48326
* Reimplement the parameter attributes support, phase #1. hilights:Chris Lattner2008-03-121-31/+6
| | | | | | | | | | | | | | | | | | | | | | | 1. There is now a "PAListPtr" class, which is a smart pointer around the underlying uniqued parameter attribute list object, and manages its refcount. It is now impossible to mess up the refcount. 2. PAListPtr is now the main interface to the underlying object, and the underlying object is now completely opaque. 3. Implementation details like SmallVector and FoldingSet are now no longer part of the interface. 4. You can create a PAListPtr with an arbitrary sequence of ParamAttrsWithIndex's, no need to make a SmallVector of a specific size (you can just use an array or scalar or vector if you wish). 5. All the client code that had to check for a null pointer before dereferencing the pointer is simplified to just access the PAListPtr directly. 6. The interfaces for adding attrs to a list and removing them is a bit simpler. Phase #2 will rename some stuff (e.g. PAListPtr) and do other less invasive changes. llvm-svn: 48289
* s/isReturnStruct()/hasStructRetAttr()/gDevang Patel2008-03-031-4/+4
| | | | llvm-svn: 47857
* If a function uses multive values in ret instruction then itDevang Patel2008-03-031-1/+2
| | | | | | is returning a struct value. llvm-svn: 47848
* Split ParameterAttributes.h, putting the complicatedDale Johannesen2008-02-221-1/+1
| | | | | | | stuff into ParamAttrsList.h. Per feedback from ParamAttrs changes. llvm-svn: 47504
* Pass alignment on ByVal parameters, from FE, allDale Johannesen2008-02-221-0/+5
| | | | | | the way through. It is now used for codegen. llvm-svn: 47484
OpenPOWER on IntegriCloud