[PATCH] D148828: [lld-macho] Tweak the names we give to archive members
Jez Ng via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Apr 20 14:24:49 PDT 2023
This revision was automatically updated to reflect the committed changes.
Closed by commit rG9df7daa5ef91: [lld-macho] Tweak the names we give to archive members (authored by int3).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D148828/new/
https://reviews.llvm.org/D148828
Files:
lld/MachO/InputFiles.cpp
lld/test/MachO/lto-archivecollision.ll
Index: lld/test/MachO/lto-archivecollision.ll
===================================================================
--- lld/test/MachO/lto-archivecollision.ll
+++ lld/test/MachO/lto-archivecollision.ll
@@ -13,15 +13,15 @@
; RUN: %lld -save-temps %t/main.o %t/liba.a %t/libb.a -o %t/test
; RUN: FileCheck %s --check-prefix=DIFFERENT-ARCHIVES < %t/test.resolution.txt
-; SAME-ARCHIVE: libbar.abar.o[[#OFFSET:]]
-; SAME-ARCHIVE-NEXT: -r={{.*}}/libbar.abar.o[[#OFFSET:]],_foo,p
-; SAME-ARCHIVE-NEXT: libbar.abar.o[[#OTHEROFFSET:]]
-; SAME-ARCHIVE-NEXT: -r={{.*}}/libbar.abar.o[[#OTHEROFFSET:]],_bar,p
-
-; DIFFERENT-ARCHIVES: liba.abar.o[[#OFFSET:]]
-; DIFFERENT-ARCHIVES-NEXT: -r={{.*}}/liba.abar.o[[#OFFSET:]],_foo,p
-; DIFFERENT-ARCHIVES-NEXT: libb.abar.o[[#OTHEROFFSET:]]
-; DIFFERENT-ARCHIVES-NEXT: -r={{.*}}/libb.abar.o[[#OTHEROFFSET:]],_bar,p
+; SAME-ARCHIVE: libbar.a(bar.o)[[#OFFSET:]]
+; SAME-ARCHIVE-NEXT: -r={{.*}}/libbar.a(bar.o)[[#OFFSET:]],_foo,p
+; SAME-ARCHIVE-NEXT: libbar.a(bar.o)[[#OTHEROFFSET:]]
+; SAME-ARCHIVE-NEXT: -r={{.*}}/libbar.a(bar.o)[[#OTHEROFFSET:]],_bar,p
+
+; DIFFERENT-ARCHIVES: liba.a(bar.o)[[#OFFSET:]]
+; DIFFERENT-ARCHIVES-NEXT: -r={{.*}}/liba.a(bar.o)[[#OFFSET:]],_foo,p
+; DIFFERENT-ARCHIVES-NEXT: libb.a(bar.o)[[#OTHEROFFSET:]]
+; DIFFERENT-ARCHIVES-NEXT: -r={{.*}}/libb.a(bar.o)[[#OTHEROFFSET:]],_bar,p
;--- main.ll
Index: lld/MachO/InputFiles.cpp
===================================================================
--- lld/MachO/InputFiles.cpp
+++ lld/MachO/InputFiles.cpp
@@ -2207,10 +2207,9 @@
MemoryBufferRef mbref(mb.getBuffer(),
saver().save(archiveName.empty()
? path
- : archiveName +
- sys::path::filename(path) +
+ : archiveName + "(" +
+ sys::path::filename(path) + ")" +
utostr(offsetInArchive)));
-
obj = check(lto::InputFile::create(mbref));
if (lazy)
parseLazy();
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D148828.515485.patch
Type: text/x-patch
Size: 2126 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230420/16296ecb/attachment.bin>
More information about the llvm-commits
mailing list