aboutsummaryrefslogtreecommitdiff
path: root/test/MC/ELF/pic-diff.s
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2010-10-03 00:46:57 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2010-10-03 00:46:57 +0000
commit9d8b7555cde8b9722dd6f8dc77c627bae0718c67 (patch)
tree23ff50f123272db9a40efb7f0f9fb298572a4fe3 /test/MC/ELF/pic-diff.s
parent11bfe3e5bf5a7c37a9f665ba5e825e00a8837f2c (diff)
Implement a very basic PIC case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@115454 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/MC/ELF/pic-diff.s')
-rw-r--r--test/MC/ELF/pic-diff.s25
1 files changed, 25 insertions, 0 deletions
diff --git a/test/MC/ELF/pic-diff.s b/test/MC/ELF/pic-diff.s
new file mode 100644
index 0000000000..155754717a
--- /dev/null
+++ b/test/MC/ELF/pic-diff.s
@@ -0,0 +1,25 @@
+// RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -o - | elf-dump | FileCheck %s
+
+// CHECK: # Symbol 5
+// CHECK-NEXT: (('st_name', 5) # 'baz'
+// CHECK-NEXT: ('st_bind', 1)
+// CHECK-NEXT: ('st_type', 0)
+// CHECK-NEXT: ('st_other', 0)
+// CHECK-NEXT: ('st_shndx', 0)
+// CHECK-NEXT: ('st_value', 0)
+// CHECK-NEXT: ('st_size', 0)
+// CHECK-NEXT: ),
+
+// CHECK: ('_relocations', [
+// CHECK-NEXT: # Relocation 0
+// CHECK-NEXT: (('r_offset', 12)
+// CHECK-NEXT: ('r_sym', 5)
+// CHECK-NEXT: ('r_type', 2)
+// CHECK-NEXT: ('r_addend', 8)
+// CHECK-NEXT: ),
+// CHECK-NEXT: ])
+
+.zero 4
+foo:
+.zero 8
+.long baz - foo