[lld] r326453 - [PDB] Defer writing the build id until the rest of the PDB is written.

Zachary Turner via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 1 10:00:29 PST 2018

Author: zturner
Date: Thu Mar  1 10:00:29 2018
New Revision: 326453

URL: http://llvm.org/viewvc/llvm-project?rev=326453&view=rev
[PDB] Defer writing the build id until the rest of the PDB is written.

For now this is NFC, but this small refactor opens the door to
letting us embed a hash of the PDB in the build id field of the

Differential Revision: https://reviews.llvm.org/D43913


Modified: lld/trunk/COFF/PDB.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/COFF/PDB.cpp?rev=326453&r1=326452&r2=326453&view=diff
--- lld/trunk/COFF/PDB.cpp (original)
+++ lld/trunk/COFF/PDB.cpp Thu Mar  1 10:00:29 2018
@@ -1056,12 +1056,10 @@ void PDBLinker::initialize(const llvm::c
   // Add an Info stream.
   auto &InfoBuilder = Builder.getInfoBuilder();
-  InfoBuilder.setAge(BuildId.PDB70.Age);
   GUID uuid;
   memcpy(&uuid, &BuildId.PDB70.Signature, sizeof(uuid));
+  InfoBuilder.setAge(BuildId.PDB70.Age);
-  InfoBuilder.setSignature(time(nullptr));
   // Add an empty DBI stream.

More information about the llvm-commits mailing list