[llvm-commits] [llvm] r88762 - in /llvm/trunk/lib: CodeGen/AsmPrinter/AsmPrinter.cpp Target/PIC16/PIC16DebugInfo.cpp
Sanjiv Gupta
sanjiv.gupta at microchip.com
Fri Nov 13 23:22:25 PST 2009
Author: sgupta
Date: Sat Nov 14 01:22:25 2009
New Revision: 88762
URL: http://llvm.org/viewvc/llvm-project?rev=88762&view=rev
Log:
revert 88761 as it fails builds.
Modified:
llvm/trunk/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
llvm/trunk/lib/Target/PIC16/PIC16DebugInfo.cpp
Modified: llvm/trunk/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/AsmPrinter.cpp?rev=88762&r1=88761&r2=88762&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/AsmPrinter/AsmPrinter.cpp (original)
+++ llvm/trunk/lib/CodeGen/AsmPrinter/AsmPrinter.cpp Sat Nov 14 01:22:25 2009
@@ -138,7 +138,7 @@
if (MMI)
MMI->AnalyzeModule(M);
DW = getAnalysisIfAvailable<DwarfWriter>();
- if (DW && MAI->doesSupportDebugInformation())
+ if (DW)
DW->BeginModule(&M, MMI, O, this, MAI);
return false;
Modified: llvm/trunk/lib/Target/PIC16/PIC16DebugInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/PIC16/PIC16DebugInfo.cpp?rev=88762&r1=88761&r2=88762&view=diff
==============================================================================
--- llvm/trunk/lib/Target/PIC16/PIC16DebugInfo.cpp (original)
+++ llvm/trunk/lib/Target/PIC16/PIC16DebugInfo.cpp Sat Nov 14 01:22:25 2009
@@ -467,18 +467,12 @@
void PIC16DbgInfo::SwitchToCU(MDNode *CU) {
// Get the file path from CU.
DICompileUnit cu(CU);
- std::string FilePath = "";
- if (cu.getDirectory()) {
- std::string DirName = cu.getDirectory();
- FilePath = FilePath + DirName + "/";
- }
- if (cu.getFilename()) {
- std::string FileName = cu.getFilename();
- FilePath = FilePath + FileName;
- }
+ std::string DirName = cu.getDirectory();
+ std::string FileName = cu.getFilename();
+ std::string FilePath = DirName + "/" + FileName;
- // Nothing to do if source file is still same or it is empty.
- if ( FilePath == CurFile || FilePath == "") return;
+ // Nothing to do if source file is still same.
+ if ( FilePath == CurFile ) return;
// Else, close the current one and start a new.
if (CurFile != "") O << "\n\t.eof";
More information about the llvm-commits
mailing list