Produce a R_386_PLT32 when needed. Moved the default cases of switches to the
[oota-llvm.git] / test / MC / ELF / relocation-386.s
1 // RUN: llvm-mc -filetype=obj -triple i386-pc-linux-gnu %s -o - | elf-dump | FileCheck  %s
2
3 // Test that we produce the correct relocation types and that the relocation
4 // to .Lfoo uses the symbol and not the section.
5
6
7 // CHECK:      # Symbol 1
8 // CHECK-NEXT: (('st_name', 5) # '.Lfoo'
9
10 // CHECK:      # Relocation 0
11 // CHECK-NEXT: (('r_offset', 2)
12 // CHECK-NEXT:  ('r_sym', 1)
13 // CHECK-NEXT:  ('r_type', 9)
14 // CHECK-NEXT: ),
15 // CHECK-NEXT:  # Relocation 1
16 // CHECK-NEXT: (('r_offset',
17 // CHECK-NEXT:  ('r_sym',
18 // CHECK-NEXT:  ('r_type', 4)
19
20         .text
21 bar:
22         leal    .Lfoo@GOTOFF(%ebx), %eax
23
24         .global bar2
25 bar2:
26         calll   bar2@PLT
27
28         .section        .rodata.str1.16,"aMS",@progbits,1
29 .Lfoo:
30         .asciz   "bool llvm::llvm_start_multithreaded()"