summaryrefslogtreecommitdiffstats
path: root/llvm/lib/VMCore/Metadata.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Oops! Fix bug introduced in my recent cleanup change. Thanks to Tobias GrosserNick Lewycky2009-11-271-1/+1
| | | | | | for pointing this out. llvm-svn: 90015
* Fix typo spotted by Gabor Greif.Nick Lewycky2009-11-261-3/+3
| | | | llvm-svn: 89976
* Clean up file, no functionality change.Nick Lewycky2009-11-261-24/+11
| | | | llvm-svn: 89974
* Do not use StringRef in DebugInfo interface. Devang Patel2009-11-121-0/+11
| | | | | | | This allows StringRef to skip controversial if(str) check in constructor. Buildbots, wait for corresponding clang and llvm-gcc FE check-ins! llvm-svn: 86914
* Fix DenseMap iterator constness.Jeffrey Yasskin2009-11-101-2/+2
| | | | | | | | | | | | | | | | | | | This patch forbids implicit conversion of DenseMap::const_iterator to DenseMap::iterator which was possible because DenseMapIterator inherited (publicly) from DenseMapConstIterator. Conversion the other way around is now allowed as one may expect. The template DenseMapConstIterator is removed and the template parameter IsConst which specifies whether the iterator is constant is added to DenseMapIterator. Actually IsConst parameter is not necessary since the constness can be determined from KeyT but this is not relevant to the fix and can be addressed later. Patch by Victor Zverovich! llvm-svn: 86636
* Do not use expensive sort(). Devang Patel2009-10-261-4/+6
| | | | llvm-svn: 85130
* Hide MetadataContext implementation details.Devang Patel2009-10-221-32/+169
| | | | llvm-svn: 84886
* Fix getMDs() interface such that it does not expose implementation details.Devang Patel2009-10-221-5/+7
| | | | llvm-svn: 84885
* Using TrackingVH instead of WeakVH or WeakMetadataVH.Devang Patel2009-10-221-7/+5
| | | | llvm-svn: 84884
* Sort handler names to ensure deterministic behavior.Devang Patel2009-10-221-2/+3
| | | | llvm-svn: 84878
* Fix getHandlerNames() interface. Now it populate clinet supplied small ↵Devang Patel2009-10-221-3/+6
| | | | | | vector with handler names. llvm-svn: 84820
* Use StringRef to construct MDString.Devang Patel2009-10-221-1/+2
| | | | llvm-svn: 84811
* Remove meaningless const.Devang Patel2009-10-221-4/+4
| | | | | | Pass StringRef by value. llvm-svn: 84804
* Derive metadata hierarchy from Value instead of User.Devang Patel2009-10-211-70/+6
| | | | llvm-svn: 84801
* Fix thinko noticed by Chris.Benjamin Kramer2009-10-211-1/+1
| | | | llvm-svn: 84797
* Remove pointless return; at end of function.Benjamin Kramer2009-10-211-3/+0
| | | | llvm-svn: 84794
* Simplify code. No intended functionality change.Benjamin Kramer2009-10-211-12/+6
| | | | llvm-svn: 84790
* Use StringRef.Devang Patel2009-10-211-4/+5
| | | | llvm-svn: 84786
* Do not use SmallVector to store MDNode elements.Devang Patel2009-10-211-7/+10
| | | | llvm-svn: 84784
* Incorporate various suggestions Chris gave during metadata review.Devang Patel2009-10-211-30/+16
| | | | | | | | | | - i < getNumElements() instead of getNumElements() > i - Make setParent() private - Fix use of resizeOperands - Reset HasMetadata bit after removing all metadata attached to an instruction - Efficient use of iterators llvm-svn: 84765
* Cosmetic changes.Devang Patel2009-10-201-9/+9
| | | | | | | | s/validName/isValidName/g s/with an Instruction/to an Instruction/g s/RegisterMDKind/registerMDKind/g llvm-svn: 84689
* Banish ConstantsLock. It's serving no purpose other than slowing things downOwen Anderson2009-10-191-18/+6
| | | | | | at the moment. llvm-svn: 84529
* various cleanups.Chris Lattner2009-10-191-30/+31
| | | | llvm-svn: 84471
* Add copyMD to copy metadata from one instruction to another instruction.Devang Patel2009-10-141-0/+15
| | | | llvm-svn: 84113
* Copy metadata when value is RAUW'd. It is debatable whether this is the ↵Devang Patel2009-10-131-0/+12
| | | | | | right approach for custom metadata data in general. However, right now the only custom data user, "dbg", expects this behavior while FE is constructing llvm IR with debug info. llvm-svn: 83977
* Lookup handler name only when assertions are enabled.Devang Patel2009-09-291-2/+2
| | | | llvm-svn: 83114
* Add removeMD().Devang Patel2009-09-291-15/+33
| | | | llvm-svn: 83107
* Only one custom meadata of each kind can be attached with an instruction.Devang Patel2009-09-291-9/+19
| | | | llvm-svn: 83105
* Use assertion instead of early exit to catch malformed custom metadata store.Devang Patel2009-09-291-5/+3
| | | | llvm-svn: 83102
* Parse custom metadata attached with an instruction.Devang Patel2009-09-291-0/+23
| | | | llvm-svn: 83033
* s/class Metadata/class MetadataContext/gDevang Patel2009-09-281-8/+8
| | | | llvm-svn: 83019
* Do not use global typedef for MDKindID.Devang Patel2009-09-281-5/+5
| | | | llvm-svn: 83016
* Do not leave behind metadata while cloning an instruction.Devang Patel2009-09-231-0/+17
| | | | llvm-svn: 82638
* Write and read metadata attachments.Devang Patel2009-09-181-0/+6
| | | | llvm-svn: 82259
* Print debug info attached with an instruction.Devang Patel2009-09-161-0/+9
| | | | llvm-svn: 82075
* Add llvm::Metadata to manage metadata used in a context. Devang Patel2009-09-161-0/+72
| | | | | | This interface will be used to attach metadata with an instruction. llvm-svn: 82060
* Take lock before removing a node from MDNodeSet.Devang Patel2009-09-091-1/+5
| | | | llvm-svn: 81356
* Enable MDNode uniquing.Devang Patel2009-09-091-21/+1
| | | | llvm-svn: 81355
* Disable MDNode uniquing.Daniel Dunbar2009-09-071-1/+21
| | | | | | - Hopefully this unbreaks some llvm-gcc bootstraps. llvm-svn: 81141
* While replacing an MDNode elment, properly update MDNode's operand list. Devang Patel2009-09-041-0/+24
| | | | | | MDNode's operand list does not include all elements. llvm-svn: 81045
* Now Bitcode reader bug is fixed. Reapply 80839.Devang Patel2009-09-031-8/+90
| | | | | | | | Use CallbackVH, instead of WeakVH, to hold MDNode elements. Use FoldingSetNode to unique MDNodes in a context. Use CallbackVH hooks to update context's MDNodeSet appropriately. llvm-svn: 80868
* Revert 80839 for now. It causes test failures.Devang Patel2009-09-021-90/+8
| | | | llvm-svn: 80841
* Use CallbackVH, instead of WeakVH, to hold MDNode elements. Devang Patel2009-09-021-8/+90
| | | | | | | Use FoldingSetNode to unique MDNodes in a context. Use CallbackVH hooks to update context's MDNodeSet appropriately. llvm-svn: 80839
* For now disable MDNode uniquing. This fixes llvm-gcc bootstrap failure on ↵Devang Patel2009-09-011-11/+3
| | | | | | certain Mac OS X 10.5. I am working on a proper fix. llvm-svn: 80738
* Remove an entry from ValueMap before removing elements.Devang Patel2009-08-271-1/+1
| | | | llvm-svn: 80247
* Revert 79977. It causes llvm-gcc bootstrap failures on some platforms.Devang Patel2009-08-261-1/+1
| | | | llvm-svn: 80073
* Update DebugInfo interface to use metadata, instead of special named ↵Devang Patel2009-08-251-1/+1
| | | | | | | | llvm.dbg.... global variables, to encode debugging information in llvm IR. This is mostly a mechanical change that tests metadata support very well. This change speeds up llvm-gcc by more then 6% at "-O0 -g" (measured by compiling InstructionCombining.cpp!) llvm-svn: 79977
* Push LLVMContexts through the IntegerType APIs.Owen Anderson2009-08-131-7/+9
| | | | llvm-svn: 78948
* Link NamedMDNodes.Devang Patel2009-08-111-0/+9
| | | | llvm-svn: 78696
* Remove MDNode from ValueMap when MDNode is destroyed.Devang Patel2009-08-101-0/+9
| | | | llvm-svn: 78612
OpenPOWER on IntegriCloud