|
1 |
| -// RUN: llvm-mc -triple=aarch64-none-linux-gnu -filetype=obj < %s | llvm-objdump -t - | FileCheck %s |
2 |
| - |
3 |
| - .text |
4 |
| - add w0, w0, w0 |
5 |
| - |
6 |
| -// .wibble should *not* inherit .text's mapping symbol. It's a completely different section. |
7 |
| - .section .wibble |
8 |
| - add w0, w0, w0 |
9 |
| - |
10 |
| -// A setion should be able to start with a $d |
11 |
| - .section .starts_data |
12 |
| - .word 42 |
13 |
| - |
14 |
| -// Changing back to .text should not emit a redundant $x |
15 |
| - .text |
16 |
| - add w0, w0, w0 |
17 |
| - |
18 |
| -// With all those constraints, we want: |
19 |
| -// + .text to have $x at 0 and no others |
20 |
| -// + .wibble to have $x at 0 |
21 |
| -// + .starts_data to have $d at 0 |
22 |
| - |
23 |
| - |
24 |
| -// CHECK: 0000000000000000 l .text 0000000000000000 $x |
25 |
| -// CHECK-NEXT: 0000000000000000 l .wibble 0000000000000000 $x |
26 |
| -// CHECK-NEXT: 0000000000000000 l .starts_data 0000000000000000 $d |
27 |
| -// CHECK-NOT: ${{[adtx]}} |
28 |
| - |
| 1 | +// RUN: llvm-mc -triple=aarch64 -filetype=obj %s | llvm-objdump -t - | FileCheck %s |
| 2 | + |
| 3 | +.section .text1,"ax" |
| 4 | +add w0, w0, w0 |
| 5 | + |
| 6 | +.text |
| 7 | +add w0, w0, w0 |
| 8 | +.word 42 |
| 9 | + |
| 10 | +.pushsection .data,"aw" |
| 11 | +.word 42 |
| 12 | +.popsection |
| 13 | + |
| 14 | +.text |
| 15 | +add w1, w1, w1 |
| 16 | + |
| 17 | +.section .text1,"ax" |
| 18 | +add w1, w1, w1 |
| 19 | + |
| 20 | +.text |
| 21 | +.word 42 |
| 22 | + |
| 23 | +.section .rodata,"a" |
| 24 | +.word 42 |
| 25 | +add w0, w0, w0 |
| 26 | + |
| 27 | +.ident "clang" |
| 28 | +.section ".note.GNU-stack","",@progbits |
| 29 | + |
| 30 | +// CHECK: SYMBOL TABLE: |
| 31 | +// CHECK-NEXT: 0000000000000000 l .text1 0000000000000000 $x.0 |
| 32 | +// CHECK-NEXT: 0000000000000000 l .text 0000000000000000 $x.1 |
| 33 | +// CHECK-NEXT: 0000000000000004 l .text 0000000000000000 $d.2 |
| 34 | +// CHECK-NEXT: 0000000000000000 l .data 0000000000000000 $d.3 |
| 35 | +// CHECK-NEXT: 0000000000000008 l .text 0000000000000000 $x.4 |
| 36 | +// CHECK-NEXT: 000000000000000c l .text 0000000000000000 $d.5 |
| 37 | +// CHECK-NEXT: 0000000000000000 l .rodata 0000000000000000 $d.6 |
| 38 | +// CHECK-NEXT: 0000000000000004 l .rodata 0000000000000000 $x.7 |
| 39 | +// CHECK-NEXT: 0000000000000000 l .comment 0000000000000000 $d.8 |
| 40 | +// CHECK-NOT: {{.}} |
0 commit comments