forked from OSchip/llvm-project
111 lines
3.1 KiB
Plaintext
111 lines
3.1 KiB
Plaintext
# RUN: lld-core %s | FileCheck %s
|
|
|
|
#
|
|
# Test that shared library symbols preserve their attributes and merge properly
|
|
#
|
|
|
|
---
|
|
atoms:
|
|
- name: foo1
|
|
definition: shared-library
|
|
load-name: libc.so
|
|
|
|
- name: foo2
|
|
definition: shared-library
|
|
load-name: libc.so
|
|
|
|
- name: bar1
|
|
definition: shared-library
|
|
load-name: libc.so
|
|
can-be-null: at-runtime
|
|
|
|
- name: bar2
|
|
definition: shared-library
|
|
load-name: libc.so
|
|
can-be-null: at-runtime
|
|
|
|
- name: mismatchNull1
|
|
definition: shared-library
|
|
load-name: libc.so
|
|
can-be-null: at-runtime
|
|
|
|
- name: mismatchNull2
|
|
definition: shared-library
|
|
load-name: libc.so
|
|
|
|
- name: mismatchload1
|
|
definition: shared-library
|
|
load-name: liba.so
|
|
|
|
- name: mismatchload2
|
|
definition: shared-library
|
|
load-name: libb.so
|
|
|
|
---
|
|
atoms:
|
|
- name: foo2
|
|
definition: shared-library
|
|
load-name: libc.so
|
|
|
|
- name: foo3
|
|
definition: shared-library
|
|
load-name: libc.so
|
|
|
|
- name: bar2
|
|
definition: shared-library
|
|
load-name: libc.so
|
|
can-be-null: at-runtime
|
|
|
|
- name: bar3
|
|
definition: shared-library
|
|
load-name: libc.so
|
|
can-be-null: at-runtime
|
|
|
|
- name: mismatchNull1
|
|
definition: shared-library
|
|
load-name: libc.so
|
|
|
|
- name: mismatchNull2
|
|
definition: shared-library
|
|
load-name: libc.so
|
|
can-be-null: at-runtime
|
|
|
|
- name: mismatchload1
|
|
definition: shared-library
|
|
load-name: libb.so
|
|
|
|
- name: mismatchload2
|
|
definition: shared-library
|
|
load-name: liba.so
|
|
|
|
...
|
|
|
|
# CHECK: name: foo1
|
|
# CHECK: definition: shared-library
|
|
# CHECK: name: foo2
|
|
# CHECK: definition: shared-library
|
|
# CHECK: name: bar1
|
|
# CHECK: definition: shared-library
|
|
# CHECK: can-be-null: at-runtime
|
|
# CHECK: name: bar2
|
|
# CHECK: definition: shared-library
|
|
# CHECK: can-be-null: at-runtime
|
|
# CHECK: name: mismatchNull1
|
|
# CHECK: definition: shared-library
|
|
# CHECK: can-be-null: at-runtime
|
|
# CHECK: name: mismatchNull2
|
|
# CHECK: definition: shared-library
|
|
# CHECK-NOT: can-be-null: at-runtime
|
|
# CHECK: name: mismatchload1
|
|
# CHECK: definition: shared-library
|
|
# CHECK: load-name: liba.so
|
|
# CHECK: name: mismatchload2
|
|
# CHECK: definition: shared-library
|
|
# CHECK: load-name: libb.so
|
|
# CHECK: name: foo3
|
|
# CHECK: definition: shared-library
|
|
# CHECK: name: bar3
|
|
# CHECK: definition: shared-library
|
|
# CHECK: can-be-null: at-runtime
|
|
# CHECK: ...
|