summaryrefslogtreecommitdiffstats
path: root/llvm/utils/TableGen/AsmWriterEmitter.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/utils/TableGen/AsmWriterEmitter.cpp')
-rw-r--r--llvm/utils/TableGen/AsmWriterEmitter.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/utils/TableGen/AsmWriterEmitter.cpp b/llvm/utils/TableGen/AsmWriterEmitter.cpp
index 4f810c1303c..4736cca77bd 100644
--- a/llvm/utils/TableGen/AsmWriterEmitter.cpp
+++ b/llvm/utils/TableGen/AsmWriterEmitter.cpp
@@ -640,7 +640,8 @@ void AsmWriterEmitter::run(std::ostream &O) {
}
O << "\";\n\n";
- O << " if (TAI->doesSupportDebugInformation()) {\n"
+ O << " if (TAI->doesSupportDebugInformation() &&\n"
+ << " DW->ShouldEmitDwarfDebug()) {\n"
<< " const MachineFunction *MF = MI->getParent()->getParent();\n"
<< " DebugLoc CurDL = MI->getDebugLoc();\n\n"
<< " if (!CurDL.isUnknown()) {\n"
OpenPOWER on IntegriCloud