diff options
author | Devang Patel <dpatel@apple.com> | 2009-01-20 19:22:03 +0000 |
---|---|---|
committer | Devang Patel <dpatel@apple.com> | 2009-01-20 19:22:03 +0000 |
commit | 2333409d0619208a66280028dac6f20ecd79008f (patch) | |
tree | 5807894bc92d2920252605bdac033d84eb6896a1 /llvm/lib | |
parent | 218c63017134d689ba772c55cfe2467f191b30e0 (diff) | |
download | bcm5719-llvm-2333409d0619208a66280028dac6f20ecd79008f.tar.gz bcm5719-llvm-2333409d0619208a66280028dac6f20ecd79008f.zip |
Need only one set of debug info versions enum.
llvm-svn: 62602
Diffstat (limited to 'llvm/lib')
-rw-r--r-- | llvm/lib/Analysis/DebugInfo.cpp | 4 | ||||
-rw-r--r-- | llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp | 8 |
2 files changed, 6 insertions, 6 deletions
diff --git a/llvm/lib/Analysis/DebugInfo.cpp b/llvm/lib/Analysis/DebugInfo.cpp index 98335ae2dcc..34ccd0a97cf 100644 --- a/llvm/lib/Analysis/DebugInfo.cpp +++ b/llvm/lib/Analysis/DebugInfo.cpp @@ -291,9 +291,9 @@ Constant *DIFactory::getCastToEmpty(DIDescriptor D) { } Constant *DIFactory::GetTagConstant(unsigned TAG) { - assert((TAG & DIDescriptor::VersionMask) == 0 && + assert((TAG & LLVMDebugVersionMask) == 0 && "Tag too large for debug encoding!"); - return ConstantInt::get(Type::Int32Ty, TAG | DIDescriptor::Version7); + return ConstantInt::get(Type::Int32Ty, TAG | LLVMDebugVersion); } Constant *DIFactory::GetStringConstant(const std::string &String) { diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp b/llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp index 88d8be10985..cbe8d7048b0 100644 --- a/llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp +++ b/llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp @@ -1559,7 +1559,7 @@ private: void AddSourceLine(DIE *Die, const DIVariable *V) { unsigned FileID = 0; unsigned Line = V->getLineNumber(); - if (V->getVersion() < DIDescriptor::Version7) { + if (V->getVersion() <= LLVMDebugVersion6) { // Version6 or earlier. Use compile unit info to get file id. CompileUnit *Unit = FindCompileUnit(V->getCompileUnit()); FileID = Unit->getID(); @@ -1578,7 +1578,7 @@ private: void AddSourceLine(DIE *Die, const DIGlobal *G) { unsigned FileID = 0; unsigned Line = G->getLineNumber(); - if (G->getVersion() < DIDescriptor::Version7) { + if (G->getVersion() < LLVMDebugVersion6) { // Version6 or earlier. Use compile unit info to get file id. CompileUnit *Unit = FindCompileUnit(G->getCompileUnit()); FileID = Unit->getID(); @@ -1595,7 +1595,7 @@ private: void AddSourceLine(DIE *Die, const DIType *Ty) { unsigned FileID = 0; unsigned Line = Ty->getLineNumber(); - if (Ty->getVersion() < DIDescriptor::Version7) { + if (Ty->getVersion() <= LLVMDebugVersion6) { // Version6 or earlier. Use compile unit info to get file id. CompileUnit *Unit = FindCompileUnit(Ty->getCompileUnit()); FileID = Unit->getID(); @@ -3046,7 +3046,7 @@ public: DIDescriptor DI(GV); // Check current version. Allow Version6 for now. unsigned Version = DI.getVersion(); - if (Version != DIDescriptor::Version7 && Version != DIDescriptor::Version6) + if (Version != LLVMDebugVersion && Version != LLVMDebugVersion6) return false; unsigned Tag = DI.getTag(); |