Skip to content

Commit

Permalink
Add an extra test for archive symbol tables.
Browse files Browse the repository at this point in the history
The table should include only defined symbols.

llvm-svn: 303075
espindola committed May 15, 2017
1 parent 7d2f06a commit 04bf953
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions llvm/test/Object/X86/archive-symbol-table.s
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# RUN: llvm-mc %s -o %t.o -filetype=obj -triple=x86_64-pc-linux
# RUN: rm -f %t
# RUN: llvm-ar rcs %t %t.o
# RUN: llvm-nm -M %t | FileCheck %s

# Test that weak undefined symbols don't show up in the archive symbol
# table.

.global foo
foo:
.weak bar
.quad bar

# CHECK: Archive map
# CHECK-NEXT: foo in archive-symbol-table.s.tmp.o
# CHECK-NOT: in
# CHECK: archive-symbol-table.s.tmp.o
# CHECK-NEXT: w bar
# CHECK-NEXT: T foo

0 comments on commit 04bf953

Please sign in to comment.