[ARM] Better OR's for MVE compares
[llvm-core.git] / test / MC / Mips / macro-li.s.s
blob01eb3646211fb95f5bfc453f3244897cafd3e6f6
1 # RUN: llvm-mc %s -triple=mipsel-unknown-linux -show-encoding -target-abi=o32 | FileCheck %s --check-prefixes=ALL,O32-N32-NO-PIC
2 # RUN: llvm-mc %s -triple=mipsel-unknown-linux -show-encoding -target-abi=o32 -position-independent | FileCheck %s --check-prefixes=ALL,O32-N32-PIC
3 # RUN: llvm-mc %s -triple=mipsel-unknown-linux -show-encoding -mcpu=mips64 -target-abi=n32 | FileCheck %s --check-prefixes=ALL,O32-N32-NO-PIC
4 # RUN: llvm-mc %s -triple=mipsel-unknown-linux -show-encoding -mcpu=mips64 -target-abi=n32 -position-independent | FileCheck %s --check-prefixes=ALL,O32-N32-PIC
5 # RUN: llvm-mc %s -triple=mipsel-unknown-linux -show-encoding -mcpu=mips64 -target-abi=n64 | FileCheck %s --check-prefixes=ALL,N64-NO-PIC
6 # RUN: llvm-mc %s -triple=mipsel-unknown-linux -show-encoding -mcpu=mips64 -target-abi=n64 -position-independent | FileCheck %s --check-prefixes=ALL,N64-PIC
8 li.s $4, 0
9 # ALL: addiu $4, $zero, 0 # encoding: [0x00,0x00,0x04,0x24]
11 li.s $4, 0.0
12 # ALL: addiu $4, $zero, 0 # encoding: [0x00,0x00,0x04,0x24]
14 li.s $4, 1.12345
15 # ALL: lui $4, 16271 # encoding: [0x8f,0x3f,0x04,0x3c]
16 # ALL: ori $4, $4, 52534 # encoding: [0x36,0xcd,0x84,0x34]
18 li.s $4, 1
19 # ALL: lui $4, 16256 # encoding: [0x80,0x3f,0x04,0x3c]
21 li.s $4, 1.0
22 # ALL: lui $4, 16256 # encoding: [0x80,0x3f,0x04,0x3c]
24 li.s $4, 12345678910
25 # ALL: lui $4, 20535 # encoding: [0x37,0x50,0x04,0x3c]
26 # ALL: ori $4, $4, 63239 # encoding: [0x07,0xf7,0x84,0x34]
28 li.s $4, 12345678910.0
29 # ALL: lui $4, 20535 # encoding: [0x37,0x50,0x04,0x3c]
30 # ALL: ori $4, $4, 63239 # encoding: [0x07,0xf7,0x84,0x34]
32 li.s $4, 0.4
33 # ALL: lui $4, 16076 # encoding: [0xcc,0x3e,0x04,0x3c]
34 # ALL: ori $4, $4, 52429 # encoding: [0xcd,0xcc,0x84,0x34]
36 li.s $4, 1.5
37 # ALL: lui $4, 16320 # encoding: [0xc0,0x3f,0x04,0x3c]
39 li.s $4, 12345678910.12345678910
40 # ALL: lui $4, 20535 # encoding: [0x37,0x50,0x04,0x3c]
41 # ALL: ori $4, $4, 63239 # encoding: [0x07,0xf7,0x84,0x34]
43 li.s $4, 12345678910123456789.12345678910
44 # ALL: lui $4, 24363 # encoding: [0x2b,0x5f,0x04,0x3c]
45 # ALL: ori $4, $4, 21674 # encoding: [0xaa,0x54,0x84,0x34]
47 li.s $f4, 0
48 # ALL: addiu $1, $zero, 0 # encoding: [0x00,0x00,0x01,0x24]
49 # ALL: mtc1 $1, $f4 # encoding: [0x00,0x20,0x81,0x44]
51 li.s $f4, 0.0
52 # ALL: addiu $1, $zero, 0 # encoding: [0x00,0x00,0x01,0x24]
53 # ALL: mtc1 $1, $f4 # encoding: [0x00,0x20,0x81,0x44]
55 li.s $f4, 1.12345
56 # ALL: .section .rodata,"a",@progbits
57 # ALL: [[LABEL:\$tmp[0-9]+]]:
58 # ALL: .4byte 1066388790
59 # ALL: .text
60 # O32-N32-PIC: lw $1, %got([[LABEL]])($gp) # encoding: [A,A,0x81,0x8f]
61 # O32-N32-PIC: # fixup A - offset: 0, value: %got([[LABEL]]), kind: fixup_Mips_GOT
62 # O32-N32-NO-PIC: lui $1, %hi([[LABEL]]) # encoding: [A,A,0x01,0x3c]
63 # O32-N32-NO-PIC: # fixup A - offset: 0, value: %hi([[LABEL]]), kind: fixup_Mips_HI16
64 # N64-PIC: ld $1, %got([[LABEL]])($gp) # encoding: [A,A,0x81,0xdf]
65 # N64-PIC: # fixup A - offset: 0, value: %got([[LABEL]]), kind: fixup_Mips_GOT
66 # N64-NO-PIC: lui $1, %highest([[LABEL]]) # encoding: [A,A,0x01,0x3c]
67 # N64-NO-PIC: # fixup A - offset: 0, value: %highest([[LABEL]]), kind: fixup_Mips_HIGHEST
68 # N64-NO-PIC: daddiu $1, $1, %higher([[LABEL]]) # encoding: [A,A,0x21,0x64]
69 # N64-NO-PIC: # fixup A - offset: 0, value: %higher([[LABEL]]), kind: fixup_Mips_HIGHER
70 # N64-NO-PIC: dsll $1, $1, 16 # encoding: [0x38,0x0c,0x01,0x00]
71 # N64-NO-PIC: daddiu $1, $1, %hi([[LABEL]]) # encoding: [A,A,0x21,0x64]
72 # N64-NO-PIC: # fixup A - offset: 0, value: %hi([[LABEL]]), kind: fixup_Mips_HI16
73 # N64-NO-PIC: dsll $1, $1, 16 # encoding: [0x38,0x0c,0x01,0x00]
74 # ALL: lwc1 $f4, %lo([[LABEL]])($1) # encoding: [A,A,0x24,0xc4]
75 # ALL: # fixup A - offset: 0, value: %lo([[LABEL]]), kind: fixup_Mips_LO16
77 li.s $f4, 1
78 # ALL: lui $1, 16256 # encoding: [0x80,0x3f,0x01,0x3c]
79 # ALL: mtc1 $1, $f4 # encoding: [0x00,0x20,0x81,0x44]
81 li.s $f4, 1.0
82 # ALL: lui $1, 16256 # encoding: [0x80,0x3f,0x01,0x3c]
83 # ALL: mtc1 $1, $f4 # encoding: [0x00,0x20,0x81,0x44]
85 li.s $f4, 12345678910
86 # ALL: .section .rodata,"a",@progbits
87 # ALL: [[LABEL:\$tmp[0-9]+]]:
88 # ALL: .4byte 1345844999
89 # ALL: .text
90 # O32-N32-PIC: lw $1, %got([[LABEL]])($gp) # encoding: [A,A,0x81,0x8f]
91 # O32-N32-PIC: # fixup A - offset: 0, value: %got([[LABEL]]), kind: fixup_Mips_GOT
92 # O32-N32-NO-PIC: lui $1, %hi([[LABEL]]) # encoding: [A,A,0x01,0x3c]
93 # O32-N32-NO-PIC: # fixup A - offset: 0, value: %hi([[LABEL]]), kind: fixup_Mips_HI16
94 # N64-PIC: ld $1, %got([[LABEL]])($gp) # encoding: [A,A,0x81,0xdf]
95 # N64-PIC: # fixup A - offset: 0, value: %got([[LABEL]]), kind: fixup_Mips_GOT
96 # N64-NO-PIC: lui $1, %highest([[LABEL]]) # encoding: [A,A,0x01,0x3c]
97 # N64-NO-PIC: # fixup A - offset: 0, value: %highest([[LABEL]]), kind: fixup_Mips_HIGHEST
98 # N64-NO-PIC: daddiu $1, $1, %higher([[LABEL]]) # encoding: [A,A,0x21,0x64]
99 # N64-NO-PIC: # fixup A - offset: 0, value: %higher([[LABEL]]), kind: fixup_Mips_HIGHER
100 # N64-NO-PIC: dsll $1, $1, 16 # encoding: [0x38,0x0c,0x01,0x00]
101 # N64-NO-PIC: daddiu $1, $1, %hi([[LABEL]]) # encoding: [A,A,0x21,0x64]
102 # N64-NO-PIC: # fixup A - offset: 0, value: %hi([[LABEL]]), kind: fixup_Mips_HI16
103 # N64-NO-PIC: dsll $1, $1, 16 # encoding: [0x38,0x0c,0x01,0x00]
104 # ALL: lwc1 $f4, %lo([[LABEL]])($1) # encoding: [A,A,0x24,0xc4]
105 # ALL: # fixup A - offset: 0, value: %lo([[LABEL]]), kind: fixup_Mips_LO16
107 li.s $f4, 12345678910.0
108 # ALL: .section .rodata,"a",@progbits
109 # ALL: [[LABEL:\$tmp[0-9]+]]:
110 # ALL: .4byte 1345844999
111 # ALL: .text
112 # O32-N32-PIC: lw $1, %got([[LABEL]])($gp) # encoding: [A,A,0x81,0x8f]
113 # O32-N32-PIC: # fixup A - offset: 0, value: %got([[LABEL]]), kind: fixup_Mips_GOT
114 # O32-N32-NO-PIC: lui $1, %hi([[LABEL]]) # encoding: [A,A,0x01,0x3c]
115 # O32-N32-NO-PIC: # fixup A - offset: 0, value: %hi([[LABEL]]), kind: fixup_Mips_HI16
116 # N64-PIC: ld $1, %got([[LABEL]])($gp) # encoding: [A,A,0x81,0xdf]
117 # N64-PIC: # fixup A - offset: 0, value: %got([[LABEL]]), kind: fixup_Mips_GOT
118 # N64-NO-PIC: lui $1, %highest([[LABEL]]) # encoding: [A,A,0x01,0x3c]
119 # N64-NO-PIC: # fixup A - offset: 0, value: %highest([[LABEL]]), kind: fixup_Mips_HIGHEST
120 # N64-NO-PIC: daddiu $1, $1, %higher([[LABEL]]) # encoding: [A,A,0x21,0x64]
121 # N64-NO-PIC: # fixup A - offset: 0, value: %higher([[LABEL]]), kind: fixup_Mips_HIGHER
122 # N64-NO-PIC: dsll $1, $1, 16 # encoding: [0x38,0x0c,0x01,0x00]
123 # N64-NO-PIC: daddiu $1, $1, %hi([[LABEL]]) # encoding: [A,A,0x21,0x64]
124 # N64-NO-PIC: # fixup A - offset: 0, value: %hi([[LABEL]]), kind: fixup_Mips_HI16
125 # N64-NO-PIC: dsll $1, $1, 16 # encoding: [0x38,0x0c,0x01,0x00]
126 # ALL: lwc1 $f4, %lo([[LABEL]])($1) # encoding: [A,A,0x24,0xc4]
127 # ALL: # fixup A - offset: 0, value: %lo([[LABEL]]), kind: fixup_Mips_LO16
130 li.s $f4, 0.4
131 # ALL: .section .rodata,"a",@progbits
132 # ALL: [[LABEL:\$tmp[0-9]+]]:
133 # ALL: .4byte 1053609165
134 # ALL: .text
135 # O32-N32-PIC: lw $1, %got([[LABEL]])($gp) # encoding: [A,A,0x81,0x8f]
136 # O32-N32-PIC: # fixup A - offset: 0, value: %got([[LABEL]]), kind: fixup_Mips_GOT
137 # O32-N32-NO-PIC: lui $1, %hi([[LABEL]]) # encoding: [A,A,0x01,0x3c]
138 # O32-N32-NO-PIC: # fixup A - offset: 0, value: %hi([[LABEL]]), kind: fixup_Mips_HI16
139 # N64-PIC: ld $1, %got([[LABEL]])($gp) # encoding: [A,A,0x81,0xdf]
140 # N64-PIC: # fixup A - offset: 0, value: %got([[LABEL]]), kind: fixup_Mips_GOT
141 # N64-NO-PIC: lui $1, %highest([[LABEL]]) # encoding: [A,A,0x01,0x3c]
142 # N64-NO-PIC: # fixup A - offset: 0, value: %highest([[LABEL]]), kind: fixup_Mips_HIGHEST
143 # N64-NO-PIC: daddiu $1, $1, %higher([[LABEL]]) # encoding: [A,A,0x21,0x64]
144 # N64-NO-PIC: # fixup A - offset: 0, value: %higher([[LABEL]]), kind: fixup_Mips_HIGHER
145 # N64-NO-PIC: dsll $1, $1, 16 # encoding: [0x38,0x0c,0x01,0x00]
146 # N64-NO-PIC: daddiu $1, $1, %hi([[LABEL]]) # encoding: [A,A,0x21,0x64]
147 # N64-NO-PIC: # fixup A - offset: 0, value: %hi([[LABEL]]), kind: fixup_Mips_HI16
148 # N64-NO-PIC: dsll $1, $1, 16 # encoding: [0x38,0x0c,0x01,0x00]
149 # ALL: lwc1 $f4, %lo([[LABEL]])($1) # encoding: [A,A,0x24,0xc4]
150 # ALL: # fixup A - offset: 0, value: %lo([[LABEL]]), kind: fixup_Mips_LO16
152 li.s $f4, 1.5
153 # ALL: lui $1, 16320 # encoding: [0xc0,0x3f,0x01,0x3c]
154 # ALL: mtc1 $1, $f4 # encoding: [0x00,0x20,0x81,0x44]
156 li.s $f4, 12345678910.12345678910
157 # ALL: .section .rodata,"a",@progbits
158 # ALL: [[LABEL:\$tmp[0-9]+]]:
159 # ALL: .4byte 1345844999
160 # ALL: .text
161 # O32-N32-PIC: lw $1, %got([[LABEL]])($gp) # encoding: [A,A,0x81,0x8f]
162 # O32-N32-PIC: # fixup A - offset: 0, value: %got([[LABEL]]), kind: fixup_Mips_GOT
163 # O32-N32-NO-PIC: lui $1, %hi([[LABEL]]) # encoding: [A,A,0x01,0x3c]
164 # O32-N32-NO-PIC: # fixup A - offset: 0, value: %hi([[LABEL]]), kind: fixup_Mips_HI16
165 # N64-PIC: ld $1, %got([[LABEL]])($gp) # encoding: [A,A,0x81,0xdf]
166 # N64-PIC: # fixup A - offset: 0, value: %got([[LABEL]]), kind: fixup_Mips_GOT
167 # N64-NO-PIC: lui $1, %highest([[LABEL]]) # encoding: [A,A,0x01,0x3c]
168 # N64-NO-PIC: # fixup A - offset: 0, value: %highest([[LABEL]]), kind: fixup_Mips_HIGHEST
169 # N64-NO-PIC: daddiu $1, $1, %higher([[LABEL]]) # encoding: [A,A,0x21,0x64]
170 # N64-NO-PIC: # fixup A - offset: 0, value: %higher([[LABEL]]), kind: fixup_Mips_HIGHER
171 # N64-NO-PIC: dsll $1, $1, 16 # encoding: [0x38,0x0c,0x01,0x00]
172 # N64-NO-PIC: daddiu $1, $1, %hi([[LABEL]]) # encoding: [A,A,0x21,0x64]
173 # N64-NO-PIC: # fixup A - offset: 0, value: %hi([[LABEL]]), kind: fixup_Mips_HI16
174 # N64-NO-PIC: dsll $1, $1, 16 # encoding: [0x38,0x0c,0x01,0x00]
175 # ALL: lwc1 $f4, %lo([[LABEL]])($1) # encoding: [A,A,0x24,0xc4]
176 # ALL: # fixup A - offset: 0, value: %lo([[LABEL]]), kind: fixup_Mips_LO16
178 li.s $f4, 12345678910123456789.12345678910
179 # ALL: .section .rodata,"a",@progbits
180 # ALL: [[LABEL:\$tmp[0-9]+]]:
181 # ALL: .4byte 1596675242
182 # ALL: .text
183 # O32-N32-PIC: lw $1, %got([[LABEL]])($gp) # encoding: [A,A,0x81,0x8f]
184 # O32-N32-PIC: # fixup A - offset: 0, value: %got([[LABEL]]), kind: fixup_Mips_GOT
185 # O32-N32-NO-PIC: lui $1, %hi([[LABEL]]) # encoding: [A,A,0x01,0x3c]
186 # O32-N32-NO-PIC: # fixup A - offset: 0, value: %hi([[LABEL]]), kind: fixup_Mips_HI16
187 # N64-PIC: ld $1, %got([[LABEL]])($gp) # encoding: [A,A,0x81,0xdf]
188 # N64-PIC: # fixup A - offset: 0, value: %got([[LABEL]]), kind: fixup_Mips_GOT
189 # N64-NO-PIC: lui $1, %highest([[LABEL]]) # encoding: [A,A,0x01,0x3c]
190 # N64-NO-PIC: # fixup A - offset: 0, value: %highest([[LABEL]]), kind: fixup_Mips_HIGHEST
191 # N64-NO-PIC: daddiu $1, $1, %higher([[LABEL]]) # encoding: [A,A,0x21,0x64]
192 # N64-NO-PIC: # fixup A - offset: 0, value: %higher([[LABEL]]), kind: fixup_Mips_HIGHER
193 # N64-NO-PIC: dsll $1, $1, 16 # encoding: [0x38,0x0c,0x01,0x00]
194 # N64-NO-PIC: daddiu $1, $1, %hi([[LABEL]]) # encoding: [A,A,0x21,0x64]
195 # N64-NO-PIC: # fixup A - offset: 0, value: %hi([[LABEL]]), kind: fixup_Mips_HI16
196 # N64-NO-PIC: dsll $1, $1, 16 # encoding: [0x38,0x0c,0x01,0x00]
197 # ALL: lwc1 $f4, %lo([[LABEL]])($1) # encoding: [A,A,0x24,0xc4]
198 # ALL: # fixup A - offset: 0, value: %lo([[LABEL]]), kind: fixup_Mips_LO16