summaryrefslogtreecommitdiff
path: root/test/ELF/Inputs
diff options
context:
space:
mode:
Diffstat (limited to 'test/ELF/Inputs')
-rw-r--r--test/ELF/Inputs/amdgpu-kernel-0.s6
-rw-r--r--test/ELF/Inputs/amdgpu-kernel-1.s6
-rw-r--r--test/ELF/Inputs/amdgpu-kernel-2.obin0 -> 408 bytes
-rw-r--r--test/ELF/Inputs/copy-rel-abs.s13
-rw-r--r--test/ELF/Inputs/copy-rel-large.s4
-rw-r--r--test/ELF/Inputs/copy-rel-pie.s1
-rw-r--r--test/ELF/Inputs/corrupt-version-reference.sobin0 -> 134272 bytes
-rw-r--r--test/ELF/Inputs/dynamic-list-weak-archive.s2
-rw-r--r--test/ELF/Inputs/eh-frame.s3
-rw-r--r--test/ELF/Inputs/gc-sections-shared.s3
-rw-r--r--test/ELF/Inputs/gc-sections-shared2.s3
-rwxr-xr-xtest/ELF/Inputs/local-symbol-in-dso.sobin0 -> 5128 bytes
-rw-r--r--test/ELF/Inputs/map-file5.s23
-rw-r--r--test/ELF/Inputs/mips-micro.s12
-rw-r--r--test/ELF/Inputs/shared3.s2
-rw-r--r--test/ELF/Inputs/undefined-error.s1
-rw-r--r--test/ELF/Inputs/verdef-defaultver.s3
-rwxr-xr-xtest/ELF/Inputs/verneed.so.sh58
-rw-r--r--test/ELF/Inputs/verneed1.s32
-rwxr-xr-xtest/ELF/Inputs/verneed1.sobin2632 -> 0 bytes
-rw-r--r--test/ELF/Inputs/verneed2.s5
-rwxr-xr-xtest/ELF/Inputs/verneed2.sobin2200 -> 0 bytes
-rw-r--r--test/ELF/Inputs/weak-undef-lazy.s3
-rw-r--r--test/ELF/Inputs/wrap-no-real.s3
-rw-r--r--test/ELF/Inputs/wrap-no-real2.s2
-rw-r--r--test/ELF/Inputs/wrap.s5
26 files changed, 130 insertions, 60 deletions
diff --git a/test/ELF/Inputs/amdgpu-kernel-0.s b/test/ELF/Inputs/amdgpu-kernel-0.s
new file mode 100644
index 0000000000000..1567c3fda10f9
--- /dev/null
+++ b/test/ELF/Inputs/amdgpu-kernel-0.s
@@ -0,0 +1,6 @@
+.text
+.globl kernel_0
+.align 64
+.amdgpu_hsa_kernel kernel_0
+kernel_0:
+ s_endpgm
diff --git a/test/ELF/Inputs/amdgpu-kernel-1.s b/test/ELF/Inputs/amdgpu-kernel-1.s
new file mode 100644
index 0000000000000..7fb520bfbe325
--- /dev/null
+++ b/test/ELF/Inputs/amdgpu-kernel-1.s
@@ -0,0 +1,6 @@
+.text
+.globl kernel_1
+.align 64
+.amdgpu_hsa_kernel kernel_1
+kernel_1:
+ s_endpgm
diff --git a/test/ELF/Inputs/amdgpu-kernel-2.o b/test/ELF/Inputs/amdgpu-kernel-2.o
new file mode 100644
index 0000000000000..fa76151f8976b
--- /dev/null
+++ b/test/ELF/Inputs/amdgpu-kernel-2.o
Binary files differ
diff --git a/test/ELF/Inputs/copy-rel-abs.s b/test/ELF/Inputs/copy-rel-abs.s
new file mode 100644
index 0000000000000..66d08807b9c90
--- /dev/null
+++ b/test/ELF/Inputs/copy-rel-abs.s
@@ -0,0 +1,13 @@
+ .global foo
+ .type foo, @object
+ .size foo, 4
+foo:
+ .weak bar
+ .type bar, @object
+ .size bar, 4
+bar:
+ .long 42
+
+ .weak zed
+ .type zed, @object
+ zed = 0x1000
diff --git a/test/ELF/Inputs/copy-rel-large.s b/test/ELF/Inputs/copy-rel-large.s
new file mode 100644
index 0000000000000..8786a2fa1a3fc
--- /dev/null
+++ b/test/ELF/Inputs/copy-rel-large.s
@@ -0,0 +1,4 @@
+ .global foo
+ .type foo, @object
+foo:
+ .size foo, 0x100000001
diff --git a/test/ELF/Inputs/copy-rel-pie.s b/test/ELF/Inputs/copy-rel-pie.s
index 6dac01ddec624..b3345ceea6720 100644
--- a/test/ELF/Inputs/copy-rel-pie.s
+++ b/test/ELF/Inputs/copy-rel-pie.s
@@ -9,3 +9,4 @@ foo:
.global bar
.type bar, @function
bar:
+retq
diff --git a/test/ELF/Inputs/corrupt-version-reference.so b/test/ELF/Inputs/corrupt-version-reference.so
new file mode 100644
index 0000000000000..ef6adc6a026cf
--- /dev/null
+++ b/test/ELF/Inputs/corrupt-version-reference.so
Binary files differ
diff --git a/test/ELF/Inputs/dynamic-list-weak-archive.s b/test/ELF/Inputs/dynamic-list-weak-archive.s
new file mode 100644
index 0000000000000..dd28fcbd5255b
--- /dev/null
+++ b/test/ELF/Inputs/dynamic-list-weak-archive.s
@@ -0,0 +1,2 @@
+.globl foo
+foo:
diff --git a/test/ELF/Inputs/eh-frame.s b/test/ELF/Inputs/eh-frame.s
new file mode 100644
index 0000000000000..0aa4008b7b2c4
--- /dev/null
+++ b/test/ELF/Inputs/eh-frame.s
@@ -0,0 +1,3 @@
+.cfi_startproc
+.cfi_def_cfa_offset 32
+.cfi_endproc
diff --git a/test/ELF/Inputs/gc-sections-shared.s b/test/ELF/Inputs/gc-sections-shared.s
new file mode 100644
index 0000000000000..e7017f5664111
--- /dev/null
+++ b/test/ELF/Inputs/gc-sections-shared.s
@@ -0,0 +1,3 @@
+.global baz
+.type baz, @function
+baz:
diff --git a/test/ELF/Inputs/gc-sections-shared2.s b/test/ELF/Inputs/gc-sections-shared2.s
new file mode 100644
index 0000000000000..fb69c0e218fba
--- /dev/null
+++ b/test/ELF/Inputs/gc-sections-shared2.s
@@ -0,0 +1,3 @@
+.global qux
+.type qux, @function
+qux:
diff --git a/test/ELF/Inputs/local-symbol-in-dso.so b/test/ELF/Inputs/local-symbol-in-dso.so
new file mode 100755
index 0000000000000..5062a7aeead2e
--- /dev/null
+++ b/test/ELF/Inputs/local-symbol-in-dso.so
Binary files differ
diff --git a/test/ELF/Inputs/map-file5.s b/test/ELF/Inputs/map-file5.s
new file mode 100644
index 0000000000000..2a89b4c7f6f5a
--- /dev/null
+++ b/test/ELF/Inputs/map-file5.s
@@ -0,0 +1,23 @@
+.bss
+.type sharedFoo,@object
+.globl sharedFoo
+sharedFoo:
+.long 0
+.size sharedFoo, 4
+
+.type sharedBar,@object
+.globl sharedBar
+sharedBar:
+.quad 0
+.size sharedBar, 8
+
+.text
+.globl sharedFunc1
+.type sharedFunc1,@function
+sharedFunc1:
+ nop
+
+.globl sharedFunc2
+.type sharedFunc2,@function
+sharedFunc2:
+ nop
diff --git a/test/ELF/Inputs/mips-micro.s b/test/ELF/Inputs/mips-micro.s
new file mode 100644
index 0000000000000..0d0b11f6fdb20
--- /dev/null
+++ b/test/ELF/Inputs/mips-micro.s
@@ -0,0 +1,12 @@
+ .text
+ .set micromips
+ .global foo
+ .type foo,@function
+foo:
+ nop
+
+ .set nomicromips
+ .global bar
+ .type bar,@function
+bar:
+ nop
diff --git a/test/ELF/Inputs/shared3.s b/test/ELF/Inputs/shared3.s
index d1f6ffea13326..e7017f5664111 100644
--- a/test/ELF/Inputs/shared3.s
+++ b/test/ELF/Inputs/shared3.s
@@ -1,3 +1,3 @@
.global baz
-.type barz, @function
+.type baz, @function
baz:
diff --git a/test/ELF/Inputs/undefined-error.s b/test/ELF/Inputs/undefined-error.s
new file mode 100644
index 0000000000000..84ac4f1213612
--- /dev/null
+++ b/test/ELF/Inputs/undefined-error.s
@@ -0,0 +1 @@
+callq fmod@PLT
diff --git a/test/ELF/Inputs/verdef-defaultver.s b/test/ELF/Inputs/verdef-defaultver.s
index 6664d62c90f59..d9e7f3829f322 100644
--- a/test/ELF/Inputs/verdef-defaultver.s
+++ b/test/ELF/Inputs/verdef-defaultver.s
@@ -1,4 +1,7 @@
+.global b@V1
b@V1 = b_1
+
+.global b@@V2
b@@V2 = b_2
.globl a
diff --git a/test/ELF/Inputs/verneed.so.sh b/test/ELF/Inputs/verneed.so.sh
deleted file mode 100755
index 3423f678e47aa..0000000000000
--- a/test/ELF/Inputs/verneed.so.sh
+++ /dev/null
@@ -1,58 +0,0 @@
-#!/bin/sh -eu
-
-# This script was used to produce the verneed{1,2}.so files.
-
-tmp=$(mktemp -d)
-
-echo "v1 {}; v2 {}; v3 {}; { local: *; };" > $tmp/verneed.script
-
-cat > $tmp/verneed1.s <<eof
-.globl f1_v1
-f1_v1:
-ret
-
-.globl f1_v2
-f1_v2:
-ret
-
-.globl f1_v3
-f1_v3:
-ret
-
-.symver f1_v1, f1@v1
-.symver f1_v2, f1@v2
-.symver f1_v3, f1@@v3
-
-.globl f2_v1
-f2_v1:
-ret
-
-.globl f2_v2
-f2_v2:
-ret
-
-.symver f2_v1, f2@v1
-.symver f2_v2, f2@@v2
-
-.globl f3_v1
-f3_v1:
-ret
-
-.symver f3_v1, f3@v1
-eof
-
-as -o $tmp/verneed1.o $tmp/verneed1.s
-ld.gold -shared -o verneed1.so $tmp/verneed1.o --version-script $tmp/verneed.script -soname verneed1.so.0
-
-cat > $tmp/verneed2.s <<eof
-.globl g1_v1
-g1_v1:
-ret
-
-.symver g1_v1, g1@@v1
-eof
-
-as -o $tmp/verneed2.o $tmp/verneed2.s
-ld.gold -shared -o verneed2.so $tmp/verneed2.o --version-script $tmp/verneed.script -soname verneed2.so.0
-
-rm -rf $tmp
diff --git a/test/ELF/Inputs/verneed1.s b/test/ELF/Inputs/verneed1.s
new file mode 100644
index 0000000000000..a342d7dd797fd
--- /dev/null
+++ b/test/ELF/Inputs/verneed1.s
@@ -0,0 +1,32 @@
+.globl f1_v1
+f1_v1:
+ret
+
+.globl f1_v2
+f1_v2:
+ret
+
+.globl f1_v3
+f1_v3:
+ret
+
+.symver f1_v1, f1@v1
+.symver f1_v2, f1@v2
+.symver f1_v3, f1@@v3
+
+.globl f2_v1
+f2_v1:
+ret
+
+.globl f2_v2
+f2_v2:
+ret
+
+.symver f2_v1, f2@v1
+.symver f2_v2, f2@@v2
+
+.globl f3_v1
+f3_v1:
+ret
+
+.symver f3_v1, f3@v1
diff --git a/test/ELF/Inputs/verneed1.so b/test/ELF/Inputs/verneed1.so
deleted file mode 100755
index 744852b9660a7..0000000000000
--- a/test/ELF/Inputs/verneed1.so
+++ /dev/null
Binary files differ
diff --git a/test/ELF/Inputs/verneed2.s b/test/ELF/Inputs/verneed2.s
new file mode 100644
index 0000000000000..1b46de6880b15
--- /dev/null
+++ b/test/ELF/Inputs/verneed2.s
@@ -0,0 +1,5 @@
+.globl g1_v1
+g1_v1:
+ret
+
+.symver g1_v1, g1@@v1
diff --git a/test/ELF/Inputs/verneed2.so b/test/ELF/Inputs/verneed2.so
deleted file mode 100755
index ba6c05ee6b1ca..0000000000000
--- a/test/ELF/Inputs/verneed2.so
+++ /dev/null
Binary files differ
diff --git a/test/ELF/Inputs/weak-undef-lazy.s b/test/ELF/Inputs/weak-undef-lazy.s
new file mode 100644
index 0000000000000..c77477315156f
--- /dev/null
+++ b/test/ELF/Inputs/weak-undef-lazy.s
@@ -0,0 +1,3 @@
+.global foobar
+foobar:
+ nop
diff --git a/test/ELF/Inputs/wrap-no-real.s b/test/ELF/Inputs/wrap-no-real.s
new file mode 100644
index 0000000000000..2fd1bcc6bc29a
--- /dev/null
+++ b/test/ELF/Inputs/wrap-no-real.s
@@ -0,0 +1,3 @@
+.globl foo, __wrap_foo
+foo = 0x11000
+__wrap_foo = 0x11010
diff --git a/test/ELF/Inputs/wrap-no-real2.s b/test/ELF/Inputs/wrap-no-real2.s
new file mode 100644
index 0000000000000..dbcb0889b965c
--- /dev/null
+++ b/test/ELF/Inputs/wrap-no-real2.s
@@ -0,0 +1,2 @@
+.globl __real_foo
+__real_foo = 0x11020
diff --git a/test/ELF/Inputs/wrap.s b/test/ELF/Inputs/wrap.s
index 584e27033d5cd..e0765196606b3 100644
--- a/test/ELF/Inputs/wrap.s
+++ b/test/ELF/Inputs/wrap.s
@@ -1,4 +1,7 @@
-.globl foo, __wrap_foo, __real_foo
+.global foo
+.weak __wrap_foo
+.protected __wrap_foo
+.global __real_foo
foo = 0x11000
__wrap_foo = 0x11010
__real_foo = 0x11020