summaryrefslogtreecommitdiffstats
path: root/llvm/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
commitca997988c3946808e0688354e055c898d2ea448f (patch)
tree10f4be8031dbe6ac6791f2c67a7e24529f1db697 /llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
parentd064502da3857a2de3c442d29c233cba08db4256 (diff)
downloadbcm5719-llvm-ca997988c3946808e0688354e055c898d2ea448f.tar.gz
bcm5719-llvm-ca997988c3946808e0688354e055c898d2ea448f.zip
Use dwarf writer to decide whether the module has debug info or not.
llvm-svn: 62184
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp')
-rw-r--r--llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp b/llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
index 88c96baea88..d79e6aa7783 100644
--- a/llvm/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
+++ b/llvm/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();
+}
OpenPOWER on IntegriCloud