[lld] [LLD][COFF] Add -build-id flag to generate .buildid section. (PR #71433)

Martin Storsjö via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 9 03:09:19 PST 2023


mstorsjo wrote:

> Oh, I found a bug that it generates .buildid when it shouldn't. It's complicated on how those flags interacting with each other. After the fix, the output binary is identical to before when not generating pdb and with `/Brepro`. With PDB, the PDB content hash in debug directory are different which also happens on lld without any changes, maybe executable file name is part of the PDB hashing. (the only difference is executable names when comparing)

Oh, good catches! I think the code in Writer.cpp looks more straightforward/understandable in this case now as well.

https://github.com/llvm/llvm-project/pull/71433


More information about the llvm-commits mailing list