X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=include%2Fllvm%2FIR%2FMetadata.h;h=94b24f4e288e05c059558a55b7bf1ea7c1a046c1;hb=d16725c31fbb40fcbf0cdf68b2b417ba445c5140;hp=8af014ac461ef55b4af4bd8f0471b7405c1abe63;hpb=2a5fda92b4ed2ddbaa03e1e6bb2107d8fe7f2cea;p=oota-llvm.git diff --git a/include/llvm/IR/Metadata.h b/include/llvm/IR/Metadata.h index 8af014ac461..94b24f4e288 100644 --- a/include/llvm/IR/Metadata.h +++ b/include/llvm/IR/Metadata.h @@ -76,6 +76,7 @@ public: DILexicalBlockKind, DILexicalBlockFileKind, DINamespaceKind, + DIModuleKind, DITemplateTypeParameterKind, DITemplateValueParameterKind, DIGlobalVariableKind, @@ -125,9 +126,10 @@ public: /// If \c M is provided, metadata nodes will be numbered canonically; /// otherwise, pointer addresses are substituted. /// @{ - void print(raw_ostream &OS, const Module *M = nullptr) const; - void print(raw_ostream &OS, ModuleSlotTracker &MST, - const Module *M = nullptr) const; + void print(raw_ostream &OS, const Module *M = nullptr, + bool IsForDebug = false) const; + void print(raw_ostream &OS, ModuleSlotTracker &MST, const Module *M = nullptr, + bool IsForDebug = false) const; /// @} /// \brief Print as operand. @@ -571,10 +573,12 @@ struct AAMDNodes { template<> struct DenseMapInfo { static inline AAMDNodes getEmptyKey() { - return AAMDNodes(DenseMapInfo::getEmptyKey(), 0, 0); + return AAMDNodes(DenseMapInfo::getEmptyKey(), + nullptr, nullptr); } static inline AAMDNodes getTombstoneKey() { - return AAMDNodes(DenseMapInfo::getTombstoneKey(), 0, 0); + return AAMDNodes(DenseMapInfo::getTombstoneKey(), + nullptr, nullptr); } static unsigned getHashValue(const AAMDNodes &Val) { return DenseMapInfo::getHashValue(Val.TBAA) ^ @@ -880,6 +884,7 @@ protected: void storeDistinctInContext(); template static T *storeImpl(T *N, StorageType Storage, StoreT &Store); + template static T *storeImpl(T *N, StorageType Storage); private: void handleChangedOperand(void *Ref, Metadata *New); @@ -1192,7 +1197,7 @@ public: void addOperand(MDNode *M); void setOperand(unsigned I, MDNode *New); StringRef getName() const; - void print(raw_ostream &ROS) const; + void print(raw_ostream &ROS, bool IsForDebug = false) const; void dump() const; // --------------------------------------------------------------------------- @@ -1216,4 +1221,4 @@ public: } // end llvm namespace -#endif +#endif // LLVM_IR_METADATA_H