aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2009-01-13 21:25:00 +0000
committerDevang Patel <dpatel@apple.com>2009-01-13 21:25:00 +0000
commitbb8c5959c83504fbc438e6efade30fa4b70a25b6 (patch)
tree082805ac0be1d31ba812c68dd9d7f8cf92ec9755 /lib/CodeGen/AsmPrinter/DwarfWriter.cpp
parent4afe15b131c7cc5b97cd7934d71ec0119d3e2c5b (diff)
Use dwarf writer to decide whether the module has debug info or not.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@62184 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/AsmPrinter/DwarfWriter.cpp')
-rw-r--r--lib/CodeGen/AsmPrinter/DwarfWriter.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/CodeGen/AsmPrinter/DwarfWriter.cpp b/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
index 88c96baea8..d79e6aa778 100644
--- a/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
+++ b/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
@@ -4984,3 +4984,9 @@ unsigned DwarfWriter::RecordRegionEnd(GlobalVariable *V) {
unsigned DwarfWriter::getRecordSourceLineCount() {
return DD->getRecordSourceLineCount();
}
+
+/// hasDebugInfo - Return true if debug info intrinsics are seen in
+/// this module.
+bool DwarfWriter::hasDebugInfo() {
+ return DD && DD->ShouldEmitDwarf();
+}