probinson added a comment.

Looks generally straightforward.  I'd give other people a chance to chime in 
but I have only minor comments.

Comment at: lib/CodeGen/CGDebugInfo.cpp:411
     // If the location is not valid then use main input file.
-    return DBuilder.createFile(remapDIPath(TheCU->getFilename()),
-                               remapDIPath(TheCU->getDirectory()),
-                               TheCU->getFile()->getChecksumKind(),
-                               TheCU->getFile()->getChecksum());
+    return getOrCreateMainFile();
Looks like this simplification (replace two calls to createFile() with 
getOrCreateMainFile()) could be its own NFC commit and simplify this patch 

Comment at: lib/Driver/ToolChains/Clang.cpp:3021
+  if (Args.hasFlag(options::OPT_gembed_source, options::OPT_gno_embed_source, 
false)) {
+    // Source embedding is a DWARFv5 extension. By now we have checked if a
+    // DWARF version was stated explicitly, and have otherwise fallen back to
Maybe "is an extension to DWARF v5" to clarify it's not actually part of DWARF 

  rC Clang

cfe-commits mailing list

Reply via email to