mirror of https://github.com/microsoft/clang.git
Debug Info: Set the MainFileName when generating -gmodules debug info for PCM.
Previously it was uninitialized and thus always defaulted to "<stdin>". This is mostly a cosmetic change that helps making the debug info more readable. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@308397 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
e3d7c4c2aa
commit
567034c312
|
@ -152,6 +152,9 @@ public:
|
|||
CodeGenOpts.CodeModel = "default";
|
||||
CodeGenOpts.ThreadModel = "single";
|
||||
CodeGenOpts.DebugTypeExtRefs = true;
|
||||
// When building a module MainFileName is the name of the modulemap file.
|
||||
CodeGenOpts.MainFileName =
|
||||
LangOpts.CurrentModule.empty() ? MainFileName : LangOpts.CurrentModule;
|
||||
CodeGenOpts.setDebugInfo(codegenoptions::FullDebugInfo);
|
||||
CodeGenOpts.setDebuggerTuning(CI.getCodeGenOpts().getDebuggerTuning());
|
||||
}
|
||||
|
|
|
@ -23,8 +23,10 @@
|
|||
@import DebugObjC;
|
||||
#endif
|
||||
|
||||
// CHECK: distinct !DICompileUnit(language: DW_LANG_ObjC
|
||||
// CHECK-SAME: isOptimized: false,
|
||||
// CHECK: distinct !DICompileUnit(language: DW_LANG_ObjC, file: ![[FILE:[0-9]+]],
|
||||
// CHECK-SAME: isOptimized: false
|
||||
|
||||
// CHECK: ![[FILE]] = !DIFile(filename: "{{DebugObjC|.*DebugObjC.h}}"
|
||||
|
||||
// CHECK: !DICompositeType(tag: DW_TAG_enumeration_type,
|
||||
// CHECK-SAME: scope: ![[MODULE:[0-9]+]],
|
||||
|
|
Loading…
Reference in New Issue