aboutsummaryrefslogtreecommitdiff
path: root/test/Object/objdump-relocations.test
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2011-10-20 21:10:27 +0000
committerDimitry Andric <dim@FreeBSD.org>2011-10-20 21:10:27 +0000
commit30815c536baacc07e925f0aef23a5395883173dc (patch)
tree2cbcf22585e99f8a87d12d5ff94f392c0d266819 /test/Object/objdump-relocations.test
parent411bd29eea3c360d5b48a18a17b5e87f5671af0e (diff)
downloadsrc-30815c536baacc07e925f0aef23a5395883173dc.tar.gz
src-30815c536baacc07e925f0aef23a5395883173dc.zip
Vendor import of llvm release_30 branch r142614:vendor/llvm/llvm-r142614
Notes
Notes: svn path=/vendor/llvm/dist/; revision=226584 svn path=/vendor/llvm/llvm-r142614/; revision=226585; tag=vendor/llvm/llvm-r142614
Diffstat (limited to 'test/Object/objdump-relocations.test')
-rw-r--r--test/Object/objdump-relocations.test28
1 files changed, 28 insertions, 0 deletions
diff --git a/test/Object/objdump-relocations.test b/test/Object/objdump-relocations.test
new file mode 100644
index 000000000000..2dcdb432ef61
--- /dev/null
+++ b/test/Object/objdump-relocations.test
@@ -0,0 +1,28 @@
+RUN: llvm-objdump -r %p/TestObjectFiles/trivial-object-test.coff-i386 \
+RUN: | FileCheck %s -check-prefix COFF-i386
+RUN: llvm-objdump -r %p/TestObjectFiles/trivial-object-test.coff-x86-64 \
+RUN: | FileCheck %s -check-prefix COFF-x86-64
+RUN: llvm-objdump -r %p/TestObjectFiles/trivial-object-test.elf-i386 \
+RUN: | FileCheck %s -check-prefix ELF-i386
+RUN: llvm-objdump -r %p/TestObjectFiles/trivial-object-test.elf-x86-64 \
+RUN: | FileCheck %s -check-prefix ELF-x86-64
+
+COFF-i386: .text
+COFF-i386: IMAGE_REL_I386_DIR32 L_.str
+COFF-i386: IMAGE_REL_I386_REL32 _puts
+COFF-i386: IMAGE_REL_I386_REL32 _SomeOtherFunction
+
+COFF-x86-64: .text
+COFF-x86-64: IMAGE_REL_AMD64_REL32 L.str
+COFF-x86-64: IMAGE_REL_AMD64_REL32 puts
+COFF-x86-64: IMAGE_REL_AMD64_REL32 SomeOtherFunction
+
+ELF-i386: .text
+ELF-i386: R_386_32
+ELF-i386: R_386_PC32
+ELF-i386: R_386_PC32
+
+ELF-x86-64: .text
+ELF-x86-64: R_X86_64_32S .rodata.str1.1
+ELF-x86-64: R_X86_64_PC32 puts
+ELF-x86-64: R_X86_64_PC32 SomeOtherFunction