diff options
| -rw-r--r-- | llvm/include/llvm/CodeGen/DwarfWriter.h | 3 | ||||
| -rw-r--r-- | llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp | 6 | ||||
| -rw-r--r-- | llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 5 | 
3 files changed, 2 insertions, 12 deletions
diff --git a/llvm/include/llvm/CodeGen/DwarfWriter.h b/llvm/include/llvm/CodeGen/DwarfWriter.h index 19601a4d9c9..7c9ada8305d 100644 --- a/llvm/include/llvm/CodeGen/DwarfWriter.h +++ b/llvm/include/llvm/CodeGen/DwarfWriter.h @@ -97,9 +97,6 @@ public:    ///    void RecordVariable(GlobalVariable *GV, unsigned FrameIndex); -  /// hasDebugInfo - Return true if debug info intrinsics are seen in  -  /// this module. -  bool hasDebugInfo();  }; diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp b/llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp index 675ae983f70..0687fd899c0 100644 --- a/llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp +++ b/llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp @@ -4990,9 +4990,3 @@ unsigned DwarfWriter::getRecordSourceLineCount() {  void DwarfWriter::RecordVariable(GlobalVariable *GV, unsigned FrameIndex) {    DD->RecordVariable(GV, FrameIndex);  } - -/// hasDebugInfo - Return true if debug info intrinsics are seen in  -/// this module. -bool DwarfWriter::hasDebugInfo() { -  return DD && DD->ShouldEmitDwarf(); -} diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp index 65a3e07b044..324b07025e0 100644 --- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp @@ -23,7 +23,6 @@  #include "llvm/CodeGen/MachineConstantPool.h"  #include "llvm/CodeGen/MachineFrameInfo.h"  #include "llvm/CodeGen/MachineModuleInfo.h" -#include "llvm/CodeGen/DwarfWriter.h"  #include "llvm/CodeGen/PseudoSourceValue.h"  #include "llvm/Target/TargetRegisterInfo.h"  #include "llvm/Target/TargetData.h" @@ -2041,8 +2040,8 @@ bool SelectionDAG::isVerifiedDebugInfoDesc(SDValue Op) const {    if (GA->getOffset() != 0) return false;    GlobalVariable *GV = dyn_cast<GlobalVariable>(GA->getGlobal());    if (!GV) return false; -  DwarfWriter *DW = getDwarfWriter(); -  return DW && DW->hasDebugInfo(); +  MachineModuleInfo *MMI = getMachineModuleInfo(); +  return MMI && MMI->hasDebugInfo() && MMI->isVerified(GV);  }  | 

