Files
clang-p2996/lld/test/core/dead-strip-basic.objtxt
Rafael Espindola c08ab8e6e4 Delete unnecessary generality in loadFile.
loadFile could load mulitple files just because yaml has a feature for
putting multiple documents in one file.

Designing a linker around what yaml can do seems like a bad idea to
me. This patch changes it to read a single file.

There are further improvements to be done to the api and they
will follow shortly.

llvm-svn: 235724
2015-04-24 15:51:45 +00:00

46 lines
1.1 KiB
Plaintext

# RUN: lld -core --dead-strip %s %p/Inputs/dead-strip-basic.objtxt %p/Inputs/dead-strip-basic2.objtxt | FileCheck -check-prefix=CHK1 %s
# RUN: lld -core %s %p/Inputs/dead-strip-basic.objtxt %p/Inputs/dead-strip-basic2.objtxt | FileCheck -check-prefix=CHK2 %s
#
# Test that -dead-strip removes unreachable code and data
# and that not using that option leaves them.
#
---
defined-atoms:
- name: entry
dead-strip: never
references:
- offset: 1
kind: pcrel32
target: bar
- offset: 6
kind: pcrel32
target: baz
- name: mydead1
scope: global
undefined-atoms:
- name: bar
- name: baz
...
# CHK1: name: entry
# CHK1-NOT: name: mydead1
# CHK1: name: bar
# CHK1-NOT: name: mydead2
# CHK1: name: baz
# CHK1-NOT: name: mydead3
# CHK1: ...
# CHK2: name: entry
# CHK2: name: mydead1
# CHK2: name: mydead2
# CHK2: name: bar
# CHK2: name: baz
# CHK2: name: mydead3
# CHK2: ...