Add comments from Eric's review of r204094.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204358 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
David Blaikie
2014-03-20 17:05:45 +00:00
parent 31bd14fc2d
commit b5a1fccdc5
2 changed files with 14 additions and 0 deletions

View File

@@ -688,6 +688,11 @@ DwarfCompileUnit *DwarfDebug::constructDwarfCompileUnit(DICompileUnit DIUnit) {
DwarfCompileUnit *NewCU = new DwarfCompileUnit(
InfoHolder.getUnits().size(), Die, DIUnit, Asm, this, &InfoHolder);
InfoHolder.addUnit(NewCU);
// LTO with assembly output shares a single line table amongst multiple CUs.
// To avoid the compilation directory being ambiguous, let the line table
// explicitly describe the directory of all files, never relying on the
// compilation directory.
if (!Asm->OutStreamer.hasRawTextSupport() || SingleCU)
Asm->OutStreamer.getContext().setMCLineTableCompilationDir(
NewCU->getUniqueID(), CompilationDir);