diff options
author | Adrian Prantl <aprantl@apple.com> | 2015-09-22 23:26:43 +0000 |
---|---|---|
committer | Adrian Prantl <aprantl@apple.com> | 2015-09-22 23:26:43 +0000 |
commit | a5206ce72a7eb77ff9f99462bb69dd7e79243cd0 (patch) | |
tree | a489fbc47651da75cf1eb615dbbc3d066d549312 /clang/lib/Serialization/GeneratePCH.cpp | |
parent | adbd2b1f32ddc3fc9ee1726fe4f5c6fd3b51014d (diff) | |
download | bcm5719-llvm-a5206ce72a7eb77ff9f99462bb69dd7e79243cd0.tar.gz bcm5719-llvm-a5206ce72a7eb77ff9f99462bb69dd7e79243cd0.zip |
Module Debugging: Use the clang module signature as the module's dwo_id
when building a module. Clang already records the module signature when
building a skeleton CU to reference a clang module.
Matching the id in the skeleton with the one in the module allows a DWARF
consumer to verify that they found the correct version of the module
without them needing to know about the clang module format.
llvm-svn: 248345
Diffstat (limited to 'clang/lib/Serialization/GeneratePCH.cpp')
-rw-r--r-- | clang/lib/Serialization/GeneratePCH.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/Serialization/GeneratePCH.cpp b/clang/lib/Serialization/GeneratePCH.cpp index 08660bc9675..9de2fdb75a0 100644 --- a/clang/lib/Serialization/GeneratePCH.cpp +++ b/clang/lib/Serialization/GeneratePCH.cpp @@ -48,7 +48,8 @@ void PCHGenerator::HandleTranslationUnit(ASTContext &Ctx) { // Emit the PCH file to the Buffer. assert(SemaPtr && "No Sema?"); - Writer.WriteAST(*SemaPtr, OutputFile, Module, isysroot, hasErrors); + Buffer->Signature = + Writer.WriteAST(*SemaPtr, OutputFile, Module, isysroot, hasErrors); Buffer->IsComplete = true; } |