| OLD | NEW |
| 1 ; Test of global initializers. | 1 ; Test of global initializers. |
| 2 | 2 |
| 3 ; REQUIRES: allow_dump | 3 ; REQUIRES: allow_dump |
| 4 | 4 |
| 5 ; Test initializers with -filetype=asm. | 5 ; Test initializers with -filetype=asm. |
| 6 ; RUN: %if --need=target_X8632 --command %p2i --filetype=asm --target x8632 \ | 6 ; RUN: %if --need=target_X8632 --command %p2i --filetype=asm --target x8632 \ |
| 7 ; RUN: -i %s --args -O2 -allow-externally-defined-symbols \ | 7 ; RUN: -i %s --args -O2 -allow-externally-defined-symbols \ |
| 8 ; RUN: | %if --need=target_X8632 --command FileCheck %s | 8 ; RUN: | %if --need=target_X8632 --command FileCheck %s |
| 9 | 9 |
| 10 ; RUN: %if --need=target_ARM32 --command %p2i --filetype=asm --target arm32 \ | 10 ; RUN: %if --need=target_ARM32 --command %p2i --filetype=asm --target arm32 \ |
| 11 ; RUN: -i %s --args -O2 --skip-unimplemented \ | 11 ; RUN: -i %s --args -O2 \ |
| 12 ; RUN: -allow-externally-defined-symbols \ | 12 ; RUN: -allow-externally-defined-symbols \ |
| 13 ; RUN: | %if --need=target_ARM32 --command FileCheck %s | 13 ; RUN: | %if --need=target_ARM32 --command FileCheck %s |
| 14 | 14 |
| 15 ; Test instructions for materializing addresses. | 15 ; Test instructions for materializing addresses. |
| 16 ; RUN: %if --need=target_X8632 --command %p2i --filetype=asm --target x8632 \ | 16 ; RUN: %if --need=target_X8632 --command %p2i --filetype=asm --target x8632 \ |
| 17 ; RUN: -i %s --args -O2 -allow-externally-defined-symbols \ | 17 ; RUN: -i %s --args -O2 -allow-externally-defined-symbols \ |
| 18 ; RUN: | %if --need=target_X8632 --command FileCheck %s --check-prefix=X8632 | 18 ; RUN: | %if --need=target_X8632 --command FileCheck %s --check-prefix=X8632 |
| 19 | 19 |
| 20 ; Test instructions with -filetype=obj and try to cross reference instructions | 20 ; Test instructions with -filetype=obj and try to cross reference instructions |
| 21 ; w/ the symbol table. | 21 ; w/ the symbol table. |
| 22 ; RUN: %if --need=target_X8632 --command %p2i --assemble --disassemble \ | 22 ; RUN: %if --need=target_X8632 --command %p2i --assemble --disassemble \ |
| 23 ; RUN: --target x8632 -i %s --args --verbose none \ | 23 ; RUN: --target x8632 -i %s --args --verbose none \ |
| 24 ; RUN: -allow-externally-defined-symbols \ | 24 ; RUN: -allow-externally-defined-symbols \ |
| 25 ; RUN: | %if --need=target_X8632 --command FileCheck --check-prefix=IAS %s | 25 ; RUN: | %if --need=target_X8632 --command FileCheck --check-prefix=IAS %s |
| 26 | 26 |
| 27 ; RUN: %if --need=target_X8632 --command %p2i --assemble --disassemble \ | 27 ; RUN: %if --need=target_X8632 --command %p2i --assemble --disassemble \ |
| 28 ; RUN: --dis-flags=-t --target x8632 -i %s --args --verbose none \ | 28 ; RUN: --dis-flags=-t --target x8632 -i %s --args --verbose none \ |
| 29 ; RUN: -allow-externally-defined-symbols \ | 29 ; RUN: -allow-externally-defined-symbols \ |
| 30 ; RUN: | %if --need=target_X8632 --command FileCheck --check-prefix=SYMTAB %s | 30 ; RUN: | %if --need=target_X8632 --command FileCheck --check-prefix=SYMTAB %s |
| 31 | 31 |
| 32 ; This is not really IAS, but we can switch when that is implemented. | 32 ; This is not really IAS, but we can switch when that is implemented. |
| 33 ; For now we can at least see the instructions / relocations. | 33 ; For now we can at least see the instructions / relocations. |
| 34 ; RUN: %if --need=target_ARM32 --command %p2i --filetype=asm --assemble \ | 34 ; RUN: %if --need=target_ARM32 --command %p2i --filetype=asm --assemble \ |
| 35 ; RUN: --disassemble --target arm32 -i %s \ | 35 ; RUN: --disassemble --target arm32 -i %s \ |
| 36 ; RUN: --args --verbose none --skip-unimplemented \ | 36 ; RUN: --args --verbose none \ |
| 37 ; RUN: -allow-externally-defined-symbols \ | 37 ; RUN: -allow-externally-defined-symbols \ |
| 38 ; RUN: | %if --need=target_ARM32 --command FileCheck \ | 38 ; RUN: | %if --need=target_ARM32 --command FileCheck \ |
| 39 ; RUN: --check-prefix=IASARM32 %s | 39 ; RUN: --check-prefix=IASARM32 %s |
| 40 | 40 |
| 41 ; RUN: %if --need=target_ARM32 --command %p2i --filetype=asm --assemble \ | 41 ; RUN: %if --need=target_ARM32 --command %p2i --filetype=asm --assemble \ |
| 42 ; RUN: --disassemble --dis-flags=-t --target arm32 -i %s \ | 42 ; RUN: --disassemble --dis-flags=-t --target arm32 -i %s \ |
| 43 ; RUN: --args --verbose none --skip-unimplemented \ | 43 ; RUN: --args --verbose none \ |
| 44 ; RUN: -allow-externally-defined-symbols \ | 44 ; RUN: -allow-externally-defined-symbols \ |
| 45 ; RUN: | %if --need=target_ARM32 --command FileCheck --check-prefix=SYMTAB %s | 45 ; RUN: | %if --need=target_ARM32 --command FileCheck --check-prefix=SYMTAB %s |
| 46 | 46 |
| 47 define internal i32 @main(i32 %argc, i32 %argv) { | 47 define internal i32 @main(i32 %argc, i32 %argv) { |
| 48 entry: | 48 entry: |
| 49 %expanded1 = ptrtoint [4 x i8]* @PrimitiveInit to i32 | 49 %expanded1 = ptrtoint [4 x i8]* @PrimitiveInit to i32 |
| 50 call void @use(i32 %expanded1) | 50 call void @use(i32 %expanded1) |
| 51 %expanded3 = ptrtoint [4 x i8]* @PrimitiveInitConst to i32 | 51 %expanded3 = ptrtoint [4 x i8]* @PrimitiveInitConst to i32 |
| 52 call void @use(i32 %expanded3) | 52 call void @use(i32 %expanded3) |
| 53 %expanded5 = ptrtoint [4 x i8]* @PrimitiveInitStatic to i32 | 53 %expanded5 = ptrtoint [4 x i8]* @PrimitiveInitStatic to i32 |
| (...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 210 ; CHECK: .section .rodata,"a",%progbits | 210 ; CHECK: .section .rodata,"a",%progbits |
| 211 ; CHECK-NEXT: .p2align 2 | 211 ; CHECK-NEXT: .p2align 2 |
| 212 ; CHECK-NEXT: ArrayUninitConstInt: | 212 ; CHECK-NEXT: ArrayUninitConstInt: |
| 213 ; CHECK-NEXT: .zero 20 | 213 ; CHECK-NEXT: .zero 20 |
| 214 ; CHECK-NEXT: .size ArrayUninitConstInt, 20 | 214 ; CHECK-NEXT: .size ArrayUninitConstInt, 20 |
| 215 | 215 |
| 216 @__init_array_start = internal constant [0 x i8] zeroinitializer, align 4 | 216 @__init_array_start = internal constant [0 x i8] zeroinitializer, align 4 |
| 217 @__fini_array_start = internal constant [0 x i8] zeroinitializer, align 4 | 217 @__fini_array_start = internal constant [0 x i8] zeroinitializer, align 4 |
| 218 @__tls_template_start = internal constant [0 x i8] zeroinitializer, align 8 | 218 @__tls_template_start = internal constant [0 x i8] zeroinitializer, align 8 |
| 219 @__tls_template_alignment = internal constant [4 x i8] c"\01\00\00\00", align 4 | 219 @__tls_template_alignment = internal constant [4 x i8] c"\01\00\00\00", align 4 |
| OLD | NEW |