Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(138)

Side by Side Diff: tests_lit/llvm2ice_tests/globalinit.pnacl.ll

Issue 469973002: Emit .local before .comm to make llvm-mc happy. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « tests_lit/llvm2ice_tests/convert.ll ('k') | tests_lit/llvm2ice_tests/nacl-atomic-fence-all.ll » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 ; Test of global initializers. 1 ; Test of global initializers.
2 2
3 ; RUN: %llvm2ice --verbose inst %s | FileCheck %s 3 ; RUN: %llvm2ice --verbose inst %s | FileCheck %s
4 ; RUIN: %llvm2ice --verbose none %s \ 4 ; RUN: %llvm2ice --verbose none %s \
5 ; RUIN: | llvm-mc -triple=i686-none-nacl -x86-asm-syntax=intel -filetype=obj 5 ; RUN: | llvm-mc -triple=i686-none-nacl -x86-asm-syntax=intel -filetype=obj
6 ; RUN: %llvm2ice --verbose none %s | FileCheck --check-prefix=ERRORS %s 6 ; RUN: %llvm2ice --verbose none %s | FileCheck --check-prefix=ERRORS %s
7 ; RUN: %llvm2iceinsts %s | %szdiff %s | FileCheck --check-prefix=DUMP %s 7 ; RUN: %llvm2iceinsts %s | %szdiff %s | FileCheck --check-prefix=DUMP %s
8 8
9 @PrimitiveInit = internal global [4 x i8] c"\1B\00\00\00", align 4 9 @PrimitiveInit = internal global [4 x i8] c"\1B\00\00\00", align 4
10 ; CHECK: .data 10 ; CHECK: .data
11 ; CHECK-NEXT: .local
11 ; CHECK-NEXT: .align 4 12 ; CHECK-NEXT: .align 4
12 ; CHECK-NEXT: PrimitiveInit: 13 ; CHECK-NEXT: PrimitiveInit:
13 ; CHECK-NEXT: .byte 14 ; CHECK-NEXT: .byte
14 ; CHECK: .size PrimitiveInit, 4 15 ; CHECK: .size PrimitiveInit, 4
15 16
16 @PrimitiveInitConst = internal constant [4 x i8] c"\0D\00\00\00", align 4 17 @PrimitiveInitConst = internal constant [4 x i8] c"\0D\00\00\00", align 4
17 ; CHECK: .section .rodata,"a",@progbits 18 ; CHECK: .section .rodata,"a",@progbits
19 ; CHECK-NEXT: .local
18 ; CHECK-NEXT: .align 4 20 ; CHECK-NEXT: .align 4
19 ; CHECK-NEXT: PrimitiveInitConst: 21 ; CHECK-NEXT: PrimitiveInitConst:
20 ; CHECK-NEXT: .byte 22 ; CHECK-NEXT: .byte
21 ; CHECK: .size PrimitiveInitConst, 4 23 ; CHECK: .size PrimitiveInitConst, 4
22 24
23 @ArrayInit = internal global [20 x i8] c"\0A\00\00\00\14\00\00\00\1E\00\00\00(\0 0\00\002\00\00\00", align 4 25 @ArrayInit = internal global [20 x i8] c"\0A\00\00\00\14\00\00\00\1E\00\00\00(\0 0\00\002\00\00\00", align 4
24 ; CHECK: .data 26 ; CHECK: .data
27 ; CHECK-NEXT: .local
25 ; CHECK-NEXT: .align 4 28 ; CHECK-NEXT: .align 4
26 ; CHECK-NEXT: ArrayInit: 29 ; CHECK-NEXT: ArrayInit:
27 ; CHECK-NEXT: .byte 30 ; CHECK-NEXT: .byte
28 ; CHECK: .size ArrayInit, 20 31 ; CHECK: .size ArrayInit, 20
29 32
30 @ArrayInitPartial = internal global [40 x i8] c"<\00\00\00F\00\00\00P\00\00\00Z\ 00\00\00d\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", align 4 33 @ArrayInitPartial = internal global [40 x i8] c"<\00\00\00F\00\00\00P\00\00\00Z\ 00\00\00d\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00\00", align 4
31 ; CHECK: .data 34 ; CHECK: .data
35 ; CHECK-NEXT: .local
32 ; CHECK-NEXT: .align 4 36 ; CHECK-NEXT: .align 4
33 ; CHECK-NEXT: ArrayInitPartial: 37 ; CHECK-NEXT: ArrayInitPartial:
34 ; CHECK-NEXT: .byte 38 ; CHECK-NEXT: .byte
35 ; CHECK: .size ArrayInitPartial, 40 39 ; CHECK: .size ArrayInitPartial, 40
36 40
37 @PrimitiveInitStatic = internal global [4 x i8] zeroinitializer, align 4 41 @PrimitiveInitStatic = internal global [4 x i8] zeroinitializer, align 4
38 ; CHECK: .data 42 ; CHECK: .data
43 ; CHECK-NEXT: .local PrimitiveInitStatic
39 ; CHECK-NEXT: .comm PrimitiveInitStatic, 4, 4 44 ; CHECK-NEXT: .comm PrimitiveInitStatic, 4, 4
40 ; CHECK-NEXT: .local PrimitiveInitStatic
41 45
42 @PrimitiveUninit = internal global [4 x i8] zeroinitializer, align 4 46 @PrimitiveUninit = internal global [4 x i8] zeroinitializer, align 4
43 ; CHECK: .data 47 ; CHECK: .data
48 ; CHECK-NEXT: .local PrimitiveUninit
44 ; CHECK-NEXT: .comm PrimitiveUninit, 4, 4 49 ; CHECK-NEXT: .comm PrimitiveUninit, 4, 4
45 ; CHECK-NEXT: .local PrimitiveUninit
46 50
47 @ArrayUninit = internal global [20 x i8] zeroinitializer, align 4 51 @ArrayUninit = internal global [20 x i8] zeroinitializer, align 4
48 ; CHECK: .data 52 ; CHECK: .data
53 ; CHECK-NEXT: .local ArrayUninit
49 ; CHECK-NEXT: .comm ArrayUninit, 20, 4 54 ; CHECK-NEXT: .comm ArrayUninit, 20, 4
50 ; CHECK-NEXT: .local ArrayUninit
51 55
52 @ArrayUninitConstDouble = internal constant [200 x i8] zeroinitializer, align 8 56 @ArrayUninitConstDouble = internal constant [200 x i8] zeroinitializer, align 8
53 ; CHECK: .section .rodata,"a",@progbits 57 ; CHECK: .section .rodata,"a",@progbits
58 ; CHECK-NEXT: .local
54 ; CHECK-NEXT: .align 8 59 ; CHECK-NEXT: .align 8
55 ; CHECK-NEXT: ArrayUninitConstDouble: 60 ; CHECK-NEXT: ArrayUninitConstDouble:
56 ; CHECK-NEXT: .zero 200 61 ; CHECK-NEXT: .zero 200
57 ; CHECK-NEXT: .size ArrayUninitConstDouble, 200 62 ; CHECK-NEXT: .size ArrayUninitConstDouble, 200
58 63
59 @ArrayUninitConstInt = internal constant [20 x i8] zeroinitializer, align 4 64 @ArrayUninitConstInt = internal constant [20 x i8] zeroinitializer, align 4
60 ; CHECK: .section .rodata,"a",@progbits 65 ; CHECK: .section .rodata,"a",@progbits
66 ; CHECK-NEXT: .local
61 ; CHECK-NEXT: .align 4 67 ; CHECK-NEXT: .align 4
62 ; CHECK-NEXT: ArrayUninitConstInt: 68 ; CHECK-NEXT: ArrayUninitConstInt:
63 ; CHECK-NEXT: .zero 20 69 ; CHECK-NEXT: .zero 20
64 ; CHECK-NEXT: .size ArrayUninitConstInt, 20 70 ; CHECK-NEXT: .size ArrayUninitConstInt, 20
65 71
66 @__init_array_start = internal constant [0 x i8] zeroinitializer, align 4 72 @__init_array_start = internal constant [0 x i8] zeroinitializer, align 4
67 @__fini_array_start = internal constant [0 x i8] zeroinitializer, align 4 73 @__fini_array_start = internal constant [0 x i8] zeroinitializer, align 4
68 @__tls_template_start = internal constant [0 x i8] zeroinitializer, align 8 74 @__tls_template_start = internal constant [0 x i8] zeroinitializer, align 8
69 @__tls_template_alignment = internal constant [4 x i8] c"\01\00\00\00", align 4 75 @__tls_template_alignment = internal constant [4 x i8] c"\01\00\00\00", align 4
70 76
(...skipping 25 matching lines...) Expand all
96 } 102 }
97 103
98 define internal i32 @nacl_tp_tls_offset(i32 %size) { 104 define internal i32 @nacl_tp_tls_offset(i32 %size) {
99 entry: 105 entry:
100 %result = sub i32 0, %size 106 %result = sub i32 0, %size
101 ret i32 %result 107 ret i32 %result
102 } 108 }
103 109
104 ; ERRORS-NOT: ICE translation error 110 ; ERRORS-NOT: ICE translation error
105 ; DUMP-NOT: SZ 111 ; DUMP-NOT: SZ
OLDNEW
« no previous file with comments | « tests_lit/llvm2ice_tests/convert.ll ('k') | tests_lit/llvm2ice_tests/nacl-atomic-fence-all.ll » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698