Skip to content

Commit e5c308a

Browse files
authored
Merge pull request #440 from JDevlieghere/cherrypick/d9466653e4ddbde5e787ac8cdbe67c1f356a5f69
[llvm/dwarfdump] Use the architecture string to filter.
2 parents 7d46b86 + 7bdf787 commit e5c308a

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

llvm/test/tools/llvm-dwarfdump/AArch64/arch.ll

-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
; RUN: llc -O0 %s -filetype=obj -o %t.o
22
; RUN: llvm-dwarfdump -arch arm64 %t.o | FileCheck %s
3-
; RUN: llvm-dwarfdump -arch aarch64 %t.o | FileCheck %s
43
; RUN: llvm-dwarfdump -arch 0x0100000c %t.o | FileCheck %s
54
; CHECK: file format Mach-O arm64
65
;
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
Make sure that passing --arch armv7s only shows the armv7s slice and not the armv7 slice.
2+
3+
RUN: llvm-dwarfdump -arch armv7s %S/../dsymutil/Inputs/fat-test.arm.dylib | FileCheck %s
4+
CHECK-NOT: (armv7)

llvm/tools/llvm-dwarfdump/llvm-dwarfdump.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,7 @@ static bool filterArch(ObjectFile &Obj) {
271271
return true;
272272

273273
// Match as name.
274-
if (MachO->getArchTriple().getArch() == Triple(Arch).getArch())
274+
if (MachO->getArchTriple().getArchName() == Triple(Arch).getArchName())
275275
return true;
276276
}
277277
}

0 commit comments

Comments
 (0)