File tree Expand file tree Collapse file tree 2 files changed +19
-3
lines changed Expand file tree Collapse file tree 2 files changed +19
-3
lines changed Original file line number Diff line number Diff line change @@ -1215,9 +1215,11 @@ void Writer::createMiscChunks() {
12151215 // if we're ultimately not going to write CodeView data to the PDB.
12161216 buildId = make<CVDebugRecordChunk>(ctx);
12171217 debugRecords.emplace_back (COFF::IMAGE_DEBUG_TYPE_CODEVIEW, buildId);
1218- if (Symbol *buildidSym = ctx.symtab .findUnderscore (" __buildid" ))
1219- replaceSymbol<DefinedSynthetic>(buildidSym, buildidSym->getName (),
1220- buildId, 4 );
1218+ ctx.forEachSymtab ([&](SymbolTable &symtab) {
1219+ if (Symbol *buildidSym = symtab.findUnderscore (" __buildid" ))
1220+ replaceSymbol<DefinedSynthetic>(buildidSym, buildidSym->getName (),
1221+ buildId, 4 );
1222+ });
12211223 }
12221224
12231225 if (config->cetCompat ) {
Original file line number Diff line number Diff line change 1+ # REQUIRES: aarch64
2+ # RUN: llvm-mc -triple=aarch64-windows -filetype=obj -o %t-arm64.obj %s
3+ # RUN: llvm-mc -triple=arm64ec-windows -filetype=obj -o %t-arm64ec.obj %s
4+
5+ # RUN: lld-link -machine:arm64x -dll -noentry %t-arm64.obj %t-arm64ec.obj -debug -build-id -Brepro -out:%t.dll
6+ # RUN: llvm-readobj --hex-dump=.test %t.dll | FileCheck %s
7+ # CHECK: 0x180003000 3c100000 3c100000
8+
9+ .section .test ,"dr"
10+ .rva __buildid
11+
12+ .section .bss ,"bw" ,discard ,__buildid
13+ .global __buildid
14+ __buildid:
You can’t perform that action at this time.
0 commit comments