Implement major new fastisel functionality: the matcher can now handle immediates...
[oota-llvm.git] / test / MC / ELF / relocation.s
index 546d89c1eca9fc3cfd60967b508697176bca5d43..4df09e13fce0d625b186f0dcc0ab00c59eb16564 100644 (file)
@@ -13,16 +13,14 @@ bar:
         leaq   foo@TLSGD(%rip), %rax    # R_X86_64_TLSGD
         leaq   foo@TPOFF(%rax), %rax    # R_X86_64_TPOFF32
         leaq   foo@TLSLD(%rip), %rdi    # R_X86_64_TLSLD
+        leaq   foo@dtpoff(%rax), %rcx   # R_X86_64_DTPOFF32
+        pushq    $bar
+        movq   foo(%rip), %rdx
+        leaq    foo-bar(%r14),%r14
 
-// CHECK:  # Section 0x00000001
-// CHECK: (('sh_name', 0x00000001) # '.text'
 
-// CHECK:   # Symbol 0x00000002
-// CHECK: (('st_name', 0x00000000) # ''
-// CHECK:  ('st_bind', 0x00000000)
-// CHECK   ('st_type', 0x00000003)
-// CHECK:  ('st_other', 0x00000000)
-// CHECK:  ('st_shndx', 0x00000001)
+// CHECK:  # Section 0x00000001
+// CHECK: (('sh_name', 0x00000006) # '.text'
 
 // CHECK: # Relocation 0x00000000
 // CHECK-NEXT:  (('r_offset', 0x00000001)
@@ -83,3 +81,34 @@ bar:
 // CHECK-NEXT:   ('r_sym', 0x00000006)
 // CHECK-NEXT:   ('r_type', 0x00000014)
 // CHECK-NEXT:   ('r_addend', 0xfffffffc)
+
+// CHECK:  # Relocation 0x0000000a
+// CHECK-NEXT:  (('r_offset', 0x00000049)
+// CHECK-NEXT:   ('r_sym', 0x00000006)
+// CHECK-NEXT:   ('r_type', 0x00000015)
+// CHECK-NEXT:   ('r_addend', 0x00000000)
+
+// CHECK: # Relocation 0x0000000b
+// CHECK-NEXT:  (('r_offset', 0x0000004e)
+// CHECK-NEXT:   ('r_sym', 0x00000002)
+// CHECK-NEXT:   ('r_type', 0x0000000b)
+// CHECK-NEXT:   ('r_addend', 0x00000000)
+
+// CHECK: # Relocation 0x0000000c
+// CHECK-NEXT: (('r_offset', 0x00000055)
+// CHECK-NEXT:  ('r_sym', 0x00000006)
+// CHECK-NEXT:  ('r_type', 0x00000002)
+// CHECK-NEXT:  ('r_addend', 0xfffffffc)
+
+// CHECK: # Relocation 0x0000000d
+// CHECK-NEXT: (('r_offset', 0x0000005c)
+// CHECK-NEXT:  ('r_sym', 0x00000006)
+// CHECK-NEXT:  ('r_type', 0x00000002)
+// CHECK-NEXT:  ('r_addend', 0x0000005c)
+
+// CHECK:   # Symbol 0x00000002
+// CHECK: (('st_name', 0x00000000) # ''
+// CHECK:  ('st_bind', 0x00000000)
+// CHECK:  ('st_type', 0x00000003)
+// CHECK:  ('st_other', 0x00000000)
+// CHECK:  ('st_shndx', 0x00000001)