Lines Matching refs:Triple
18 Triple T; in TEST()
20 T = Triple(""); in TEST()
26 T = Triple("-"); in TEST()
32 T = Triple("--"); in TEST()
38 T = Triple("---"); in TEST()
44 T = Triple("----"); in TEST()
50 T = Triple("a"); in TEST()
56 T = Triple("a-b"); in TEST()
62 T = Triple("a-b-c"); in TEST()
68 T = Triple("a-b-c-d"); in TEST()
76 Triple T; in TEST()
78 T = Triple("i386-apple-darwin"); in TEST()
79 EXPECT_EQ(Triple::x86, T.getArch()); in TEST()
80 EXPECT_EQ(Triple::Apple, T.getVendor()); in TEST()
81 EXPECT_EQ(Triple::Darwin, T.getOS()); in TEST()
82 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
84 T = Triple("i386-pc-elfiamcu"); in TEST()
85 EXPECT_EQ(Triple::x86, T.getArch()); in TEST()
86 EXPECT_EQ(Triple::PC, T.getVendor()); in TEST()
87 EXPECT_EQ(Triple::ELFIAMCU, T.getOS()); in TEST()
88 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
90 T = Triple("x86_64-pc-linux-gnu"); in TEST()
91 EXPECT_EQ(Triple::x86_64, T.getArch()); in TEST()
92 EXPECT_EQ(Triple::PC, T.getVendor()); in TEST()
93 EXPECT_EQ(Triple::Linux, T.getOS()); in TEST()
94 EXPECT_EQ(Triple::GNU, T.getEnvironment()); in TEST()
96 T = Triple("x86_64-pc-linux-musl"); in TEST()
97 EXPECT_EQ(Triple::x86_64, T.getArch()); in TEST()
98 EXPECT_EQ(Triple::PC, T.getVendor()); in TEST()
99 EXPECT_EQ(Triple::Linux, T.getOS()); in TEST()
100 EXPECT_EQ(Triple::Musl, T.getEnvironment()); in TEST()
102 T = Triple("powerpc-bgp-linux"); in TEST()
103 EXPECT_EQ(Triple::ppc, T.getArch()); in TEST()
104 EXPECT_EQ(Triple::BGP, T.getVendor()); in TEST()
105 EXPECT_EQ(Triple::Linux, T.getOS()); in TEST()
106 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
108 T = Triple("powerpc-bgp-cnk"); in TEST()
109 EXPECT_EQ(Triple::ppc, T.getArch()); in TEST()
110 EXPECT_EQ(Triple::BGP, T.getVendor()); in TEST()
111 EXPECT_EQ(Triple::CNK, T.getOS()); in TEST()
112 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
114 T = Triple("powerpc64-bgq-linux"); in TEST()
115 EXPECT_EQ(Triple::ppc64, T.getArch()); in TEST()
116 EXPECT_EQ(Triple::BGQ, T.getVendor()); in TEST()
117 EXPECT_EQ(Triple::Linux, T.getOS()); in TEST()
118 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
120 T = Triple("powerpc-ibm-aix"); in TEST()
121 EXPECT_EQ(Triple::ppc, T.getArch()); in TEST()
122 EXPECT_EQ(Triple::IBM, T.getVendor()); in TEST()
123 EXPECT_EQ(Triple::AIX, T.getOS()); in TEST()
124 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
126 T = Triple("powerpc64-ibm-aix"); in TEST()
127 EXPECT_EQ(Triple::ppc64, T.getArch()); in TEST()
128 EXPECT_EQ(Triple::IBM, T.getVendor()); in TEST()
129 EXPECT_EQ(Triple::AIX, T.getOS()); in TEST()
130 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
132 T = Triple("powerpc-dunno-notsure"); in TEST()
133 EXPECT_EQ(Triple::ppc, T.getArch()); in TEST()
134 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
135 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
136 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
138 T = Triple("arm-none-none-eabi"); in TEST()
139 EXPECT_EQ(Triple::arm, T.getArch()); in TEST()
140 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
141 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
142 EXPECT_EQ(Triple::EABI, T.getEnvironment()); in TEST()
144 T = Triple("arm-none-linux-musleabi"); in TEST()
145 EXPECT_EQ(Triple::arm, T.getArch()); in TEST()
146 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
147 EXPECT_EQ(Triple::Linux, T.getOS()); in TEST()
148 EXPECT_EQ(Triple::MuslEABI, T.getEnvironment()); in TEST()
150 T = Triple("armv6hl-none-linux-gnueabi"); in TEST()
151 EXPECT_EQ(Triple::arm, T.getArch()); in TEST()
152 EXPECT_EQ(Triple::Linux, T.getOS()); in TEST()
153 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
154 EXPECT_EQ(Triple::GNUEABI, T.getEnvironment()); in TEST()
156 T = Triple("armv7hl-none-linux-gnueabi"); in TEST()
157 EXPECT_EQ(Triple::arm, T.getArch()); in TEST()
158 EXPECT_EQ(Triple::Linux, T.getOS()); in TEST()
159 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
160 EXPECT_EQ(Triple::GNUEABI, T.getEnvironment()); in TEST()
162 T = Triple("amdil-unknown-unknown"); in TEST()
163 EXPECT_EQ(Triple::amdil, T.getArch()); in TEST()
164 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
165 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
167 T = Triple("amdil64-unknown-unknown"); in TEST()
168 EXPECT_EQ(Triple::amdil64, T.getArch()); in TEST()
169 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
170 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
172 T = Triple("hsail-unknown-unknown"); in TEST()
173 EXPECT_EQ(Triple::hsail, T.getArch()); in TEST()
174 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
175 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
177 T = Triple("hsail64-unknown-unknown"); in TEST()
178 EXPECT_EQ(Triple::hsail64, T.getArch()); in TEST()
179 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
180 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
182 T = Triple("sparcel-unknown-unknown"); in TEST()
183 EXPECT_EQ(Triple::sparcel, T.getArch()); in TEST()
184 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
185 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
187 T = Triple("spir-unknown-unknown"); in TEST()
188 EXPECT_EQ(Triple::spir, T.getArch()); in TEST()
189 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
190 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
192 T = Triple("spir64-unknown-unknown"); in TEST()
193 EXPECT_EQ(Triple::spir64, T.getArch()); in TEST()
194 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
195 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
197 T = Triple("x86_64-unknown-cloudabi"); in TEST()
198 EXPECT_EQ(Triple::x86_64, T.getArch()); in TEST()
199 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
200 EXPECT_EQ(Triple::CloudABI, T.getOS()); in TEST()
201 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
203 T = Triple("wasm32-unknown-unknown"); in TEST()
204 EXPECT_EQ(Triple::wasm32, T.getArch()); in TEST()
205 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
206 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
207 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
209 T = Triple("wasm64-unknown-unknown"); in TEST()
210 EXPECT_EQ(Triple::wasm64, T.getArch()); in TEST()
211 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
212 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
213 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
215 T = Triple("avr-unknown-unknown"); in TEST()
216 EXPECT_EQ(Triple::avr, T.getArch()); in TEST()
217 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
218 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
219 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
221 T = Triple("avr"); in TEST()
222 EXPECT_EQ(Triple::avr, T.getArch()); in TEST()
223 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
224 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
225 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
227 T = Triple("lanai-unknown-unknown"); in TEST()
228 EXPECT_EQ(Triple::lanai, T.getArch()); in TEST()
229 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
230 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
231 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
233 T = Triple("lanai"); in TEST()
234 EXPECT_EQ(Triple::lanai, T.getArch()); in TEST()
235 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
236 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
237 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
239 T = Triple("amdgcn-mesa-mesa3d"); in TEST()
240 EXPECT_EQ(Triple::amdgcn, T.getArch()); in TEST()
241 EXPECT_EQ(Triple::Mesa, T.getVendor()); in TEST()
242 EXPECT_EQ(Triple::Mesa3D, T.getOS()); in TEST()
243 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
245 T = Triple("amdgcn-amd-amdhsa"); in TEST()
246 EXPECT_EQ(Triple::amdgcn, T.getArch()); in TEST()
247 EXPECT_EQ(Triple::AMD, T.getVendor()); in TEST()
248 EXPECT_EQ(Triple::AMDHSA, T.getOS()); in TEST()
249 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
251 T = Triple("huh"); in TEST()
252 EXPECT_EQ(Triple::UnknownArch, T.getArch()); in TEST()
267 EXPECT_EQ("", Triple::normalize("")); in TEST()
268 EXPECT_EQ("-", Triple::normalize("-")); in TEST()
269 EXPECT_EQ("--", Triple::normalize("--")); in TEST()
270 EXPECT_EQ("---", Triple::normalize("---")); in TEST()
271 EXPECT_EQ("----", Triple::normalize("----")); in TEST()
273 EXPECT_EQ("a", Triple::normalize("a")); in TEST()
274 EXPECT_EQ("a-b", Triple::normalize("a-b")); in TEST()
275 EXPECT_EQ("a-b-c", Triple::normalize("a-b-c")); in TEST()
276 EXPECT_EQ("a-b-c-d", Triple::normalize("a-b-c-d")); in TEST()
278 EXPECT_EQ("i386-b-c", Triple::normalize("i386-b-c")); in TEST()
279 EXPECT_EQ("i386-a-c", Triple::normalize("a-i386-c")); in TEST()
280 EXPECT_EQ("i386-a-b", Triple::normalize("a-b-i386")); in TEST()
281 EXPECT_EQ("i386-a-b-c", Triple::normalize("a-b-c-i386")); in TEST()
283 EXPECT_EQ("a-pc-c", Triple::normalize("a-pc-c")); in TEST()
284 EXPECT_EQ("-pc-b-c", Triple::normalize("pc-b-c")); in TEST()
285 EXPECT_EQ("a-pc-b", Triple::normalize("a-b-pc")); in TEST()
286 EXPECT_EQ("a-pc-b-c", Triple::normalize("a-b-c-pc")); in TEST()
288 EXPECT_EQ("a-b-linux", Triple::normalize("a-b-linux")); in TEST()
289 EXPECT_EQ("--linux-b-c", Triple::normalize("linux-b-c")); in TEST()
290 EXPECT_EQ("a--linux-c", Triple::normalize("a-linux-c")); in TEST()
292 EXPECT_EQ("i386-pc-a", Triple::normalize("a-pc-i386")); in TEST()
293 EXPECT_EQ("i386-pc-", Triple::normalize("-pc-i386")); in TEST()
294 EXPECT_EQ("-pc-linux-c", Triple::normalize("linux-pc-c")); in TEST()
295 EXPECT_EQ("-pc-linux", Triple::normalize("linux-pc-")); in TEST()
297 EXPECT_EQ("i386", Triple::normalize("i386")); in TEST()
298 EXPECT_EQ("-pc", Triple::normalize("pc")); in TEST()
299 EXPECT_EQ("--linux", Triple::normalize("linux")); in TEST()
301 EXPECT_EQ("x86_64--linux-gnu", Triple::normalize("x86_64-gnu-linux")); in TEST()
306 for (int Arch = 1+Triple::UnknownArch; Arch <= Triple::LastArchType; ++Arch) { in TEST()
307 C[0] = Triple::getArchTypeName(Triple::ArchType(Arch)); in TEST()
308 for (int Vendor = 1+Triple::UnknownVendor; Vendor <= Triple::LastVendorType; in TEST()
310 C[1] = Triple::getVendorTypeName(Triple::VendorType(Vendor)); in TEST()
311 for (int OS = 1+Triple::UnknownOS; OS <= Triple::LastOSType; ++OS) { in TEST()
312 if (OS == Triple::Win32) in TEST()
315 C[2] = Triple::getOSTypeName(Triple::OSType(OS)); in TEST()
318 EXPECT_EQ(E, Triple::normalize(Join(C[0], C[1], C[2]))); in TEST()
320 EXPECT_EQ(E, Triple::normalize(Join(C[0], C[2], C[1]))); in TEST()
321 EXPECT_EQ(E, Triple::normalize(Join(C[1], C[2], C[0]))); in TEST()
322 EXPECT_EQ(E, Triple::normalize(Join(C[1], C[0], C[2]))); in TEST()
323 EXPECT_EQ(E, Triple::normalize(Join(C[2], C[0], C[1]))); in TEST()
324 EXPECT_EQ(E, Triple::normalize(Join(C[2], C[1], C[0]))); in TEST()
326 for (int Env = 1 + Triple::UnknownEnvironment; Env <= Triple::LastEnvironmentType; in TEST()
328 C[3] = Triple::getEnvironmentTypeName(Triple::EnvironmentType(Env)); in TEST()
331 EXPECT_EQ(F, Triple::normalize(Join(C[0], C[1], C[2], C[3]))); in TEST()
333 EXPECT_EQ(F, Triple::normalize(Join(C[0], C[1], C[3], C[2]))); in TEST()
334 EXPECT_EQ(F, Triple::normalize(Join(C[0], C[2], C[3], C[1]))); in TEST()
335 EXPECT_EQ(F, Triple::normalize(Join(C[0], C[2], C[1], C[3]))); in TEST()
336 EXPECT_EQ(F, Triple::normalize(Join(C[0], C[3], C[1], C[2]))); in TEST()
337 EXPECT_EQ(F, Triple::normalize(Join(C[0], C[3], C[2], C[1]))); in TEST()
338 EXPECT_EQ(F, Triple::normalize(Join(C[1], C[2], C[3], C[0]))); in TEST()
339 EXPECT_EQ(F, Triple::normalize(Join(C[1], C[2], C[0], C[3]))); in TEST()
340 EXPECT_EQ(F, Triple::normalize(Join(C[1], C[3], C[0], C[2]))); in TEST()
341 EXPECT_EQ(F, Triple::normalize(Join(C[1], C[3], C[2], C[0]))); in TEST()
342 EXPECT_EQ(F, Triple::normalize(Join(C[1], C[0], C[2], C[3]))); in TEST()
343 EXPECT_EQ(F, Triple::normalize(Join(C[1], C[0], C[3], C[2]))); in TEST()
344 EXPECT_EQ(F, Triple::normalize(Join(C[2], C[3], C[0], C[1]))); in TEST()
345 EXPECT_EQ(F, Triple::normalize(Join(C[2], C[3], C[1], C[0]))); in TEST()
346 EXPECT_EQ(F, Triple::normalize(Join(C[2], C[0], C[1], C[3]))); in TEST()
347 EXPECT_EQ(F, Triple::normalize(Join(C[2], C[0], C[3], C[1]))); in TEST()
348 EXPECT_EQ(F, Triple::normalize(Join(C[2], C[1], C[3], C[0]))); in TEST()
349 EXPECT_EQ(F, Triple::normalize(Join(C[2], C[1], C[0], C[3]))); in TEST()
350 EXPECT_EQ(F, Triple::normalize(Join(C[3], C[0], C[1], C[2]))); in TEST()
351 EXPECT_EQ(F, Triple::normalize(Join(C[3], C[0], C[2], C[1]))); in TEST()
352 EXPECT_EQ(F, Triple::normalize(Join(C[3], C[1], C[2], C[0]))); in TEST()
353 EXPECT_EQ(F, Triple::normalize(Join(C[3], C[1], C[0], C[2]))); in TEST()
354 EXPECT_EQ(F, Triple::normalize(Join(C[3], C[2], C[0], C[1]))); in TEST()
355 EXPECT_EQ(F, Triple::normalize(Join(C[3], C[2], C[1], C[0]))); in TEST()
363 EXPECT_EQ("i386--windows-gnu", Triple::normalize("i386-mingw32")); // i386-pc-mingw32 in TEST()
364 EXPECT_EQ("x86_64--linux-gnu", Triple::normalize("x86_64-linux-gnu")); // x86_64-pc-linux-gnu in TEST()
365 EXPECT_EQ("i486--linux-gnu", Triple::normalize("i486-linux-gnu")); // i486-pc-linux-gnu in TEST()
366 EXPECT_EQ("i386-redhat-linux", Triple::normalize("i386-redhat-linux")); // i386-redhat-linux-gnu in TEST()
367 EXPECT_EQ("i686--linux", Triple::normalize("i686-linux")); // i686-pc-linux-gnu in TEST()
368 EXPECT_EQ("arm-none--eabi", Triple::normalize("arm-none-eabi")); // arm-none-eabi in TEST()
372 Triple T; in TEST()
373 EXPECT_EQ(Triple::UnknownArch, T.getArch()); in TEST()
374 EXPECT_EQ(Triple::UnknownVendor, T.getVendor()); in TEST()
375 EXPECT_EQ(Triple::UnknownOS, T.getOS()); in TEST()
376 EXPECT_EQ(Triple::UnknownEnvironment, T.getEnvironment()); in TEST()
379 EXPECT_EQ(Triple::x86, T.getArch()); in TEST()
383 EXPECT_EQ(Triple::x86, T.getArch()); in TEST()
384 EXPECT_EQ(Triple::PC, T.getVendor()); in TEST()
388 EXPECT_EQ(Triple::x86, T.getArch()); in TEST()
389 EXPECT_EQ(Triple::PC, T.getVendor()); in TEST()
390 EXPECT_EQ(Triple::Linux, T.getOS()); in TEST()
394 EXPECT_EQ(Triple::x86, T.getArch()); in TEST()
395 EXPECT_EQ(Triple::PC, T.getVendor()); in TEST()
396 EXPECT_EQ(Triple::Linux, T.getOS()); in TEST()
400 EXPECT_EQ(Triple::x86, T.getArch()); in TEST()
401 EXPECT_EQ(Triple::PC, T.getVendor()); in TEST()
402 EXPECT_EQ(Triple::FreeBSD, T.getOS()); in TEST()
406 EXPECT_EQ(Triple::x86, T.getArch()); in TEST()
407 EXPECT_EQ(Triple::PC, T.getVendor()); in TEST()
408 EXPECT_EQ(Triple::Darwin, T.getOS()); in TEST()
412 EXPECT_EQ(Triple::AMDOpenCL, T.getEnvironment()); in TEST()
416 Triple T; in TEST()
421 T.setArch(Triple::arm); in TEST()
426 T.setArch(Triple::hexagon); in TEST()
431 T.setArch(Triple::mips); in TEST()
436 T.setArch(Triple::mips64); in TEST()
441 T.setArch(Triple::msp430); in TEST()
446 T.setArch(Triple::ppc); in TEST()
451 T.setArch(Triple::ppc64); in TEST()
456 T.setArch(Triple::x86); in TEST()
461 T.setArch(Triple::x86_64); in TEST()
466 T.setArch(Triple::amdil); in TEST()
471 T.setArch(Triple::amdil64); in TEST()
476 T.setArch(Triple::hsail); in TEST()
481 T.setArch(Triple::hsail64); in TEST()
486 T.setArch(Triple::spir); in TEST()
491 T.setArch(Triple::spir64); in TEST()
496 T.setArch(Triple::sparc); in TEST()
501 T.setArch(Triple::sparcel); in TEST()
506 T.setArch(Triple::sparcv9); in TEST()
511 T.setArch(Triple::wasm32); in TEST()
516 T.setArch(Triple::wasm64); in TEST()
521 T.setArch(Triple::avr); in TEST()
526 T.setArch(Triple::lanai); in TEST()
533 Triple T; in TEST()
534 EXPECT_EQ(Triple::UnknownArch, T.get32BitArchVariant().getArch()); in TEST()
535 EXPECT_EQ(Triple::UnknownArch, T.get64BitArchVariant().getArch()); in TEST()
537 T.setArch(Triple::UnknownArch); in TEST()
538 EXPECT_EQ(Triple::UnknownArch, T.get32BitArchVariant().getArch()); in TEST()
539 EXPECT_EQ(Triple::UnknownArch, T.get64BitArchVariant().getArch()); in TEST()
541 T.setArch(Triple::mips); in TEST()
542 EXPECT_EQ(Triple::mips, T.get32BitArchVariant().getArch()); in TEST()
543 EXPECT_EQ(Triple::mips64, T.get64BitArchVariant().getArch()); in TEST()
545 T.setArch(Triple::mipsel); in TEST()
546 EXPECT_EQ(Triple::mipsel, T.get32BitArchVariant().getArch()); in TEST()
547 EXPECT_EQ(Triple::mips64el, T.get64BitArchVariant().getArch()); in TEST()
549 T.setArch(Triple::ppc); in TEST()
550 EXPECT_EQ(Triple::ppc, T.get32BitArchVariant().getArch()); in TEST()
551 EXPECT_EQ(Triple::ppc64, T.get64BitArchVariant().getArch()); in TEST()
553 T.setArch(Triple::nvptx); in TEST()
554 EXPECT_EQ(Triple::nvptx, T.get32BitArchVariant().getArch()); in TEST()
555 EXPECT_EQ(Triple::nvptx64, T.get64BitArchVariant().getArch()); in TEST()
557 T.setArch(Triple::sparc); in TEST()
558 EXPECT_EQ(Triple::sparc, T.get32BitArchVariant().getArch()); in TEST()
559 EXPECT_EQ(Triple::sparcv9, T.get64BitArchVariant().getArch()); in TEST()
561 T.setArch(Triple::x86); in TEST()
562 EXPECT_EQ(Triple::x86, T.get32BitArchVariant().getArch()); in TEST()
563 EXPECT_EQ(Triple::x86_64, T.get64BitArchVariant().getArch()); in TEST()
565 T.setArch(Triple::mips64); in TEST()
566 EXPECT_EQ(Triple::mips, T.get32BitArchVariant().getArch()); in TEST()
567 EXPECT_EQ(Triple::mips64, T.get64BitArchVariant().getArch()); in TEST()
569 T.setArch(Triple::mips64el); in TEST()
570 EXPECT_EQ(Triple::mipsel, T.get32BitArchVariant().getArch()); in TEST()
571 EXPECT_EQ(Triple::mips64el, T.get64BitArchVariant().getArch()); in TEST()
573 T.setArch(Triple::ppc64); in TEST()
574 EXPECT_EQ(Triple::ppc, T.get32BitArchVariant().getArch()); in TEST()
575 EXPECT_EQ(Triple::ppc64, T.get64BitArchVariant().getArch()); in TEST()
577 T.setArch(Triple::nvptx64); in TEST()
578 EXPECT_EQ(Triple::nvptx, T.get32BitArchVariant().getArch()); in TEST()
579 EXPECT_EQ(Triple::nvptx64, T.get64BitArchVariant().getArch()); in TEST()
581 T.setArch(Triple::sparcv9); in TEST()
582 EXPECT_EQ(Triple::sparc, T.get32BitArchVariant().getArch()); in TEST()
583 EXPECT_EQ(Triple::sparcv9, T.get64BitArchVariant().getArch()); in TEST()
585 T.setArch(Triple::x86_64); in TEST()
586 EXPECT_EQ(Triple::x86, T.get32BitArchVariant().getArch()); in TEST()
587 EXPECT_EQ(Triple::x86_64, T.get64BitArchVariant().getArch()); in TEST()
589 T.setArch(Triple::amdil); in TEST()
590 EXPECT_EQ(Triple::amdil, T.get32BitArchVariant().getArch()); in TEST()
591 EXPECT_EQ(Triple::amdil64, T.get64BitArchVariant().getArch()); in TEST()
593 T.setArch(Triple::amdil64); in TEST()
594 EXPECT_EQ(Triple::amdil, T.get32BitArchVariant().getArch()); in TEST()
595 EXPECT_EQ(Triple::amdil64, T.get64BitArchVariant().getArch()); in TEST()
597 T.setArch(Triple::hsail); in TEST()
598 EXPECT_EQ(Triple::hsail, T.get32BitArchVariant().getArch()); in TEST()
599 EXPECT_EQ(Triple::hsail64, T.get64BitArchVariant().getArch()); in TEST()
601 T.setArch(Triple::hsail64); in TEST()
602 EXPECT_EQ(Triple::hsail, T.get32BitArchVariant().getArch()); in TEST()
603 EXPECT_EQ(Triple::hsail64, T.get64BitArchVariant().getArch()); in TEST()
605 T.setArch(Triple::spir); in TEST()
606 EXPECT_EQ(Triple::spir, T.get32BitArchVariant().getArch()); in TEST()
607 EXPECT_EQ(Triple::spir64, T.get64BitArchVariant().getArch()); in TEST()
609 T.setArch(Triple::spir64); in TEST()
610 EXPECT_EQ(Triple::spir, T.get32BitArchVariant().getArch()); in TEST()
611 EXPECT_EQ(Triple::spir64, T.get64BitArchVariant().getArch()); in TEST()
613 T.setArch(Triple::wasm32); in TEST()
614 EXPECT_EQ(Triple::wasm32, T.get32BitArchVariant().getArch()); in TEST()
615 EXPECT_EQ(Triple::wasm64, T.get64BitArchVariant().getArch()); in TEST()
617 T.setArch(Triple::wasm64); in TEST()
618 EXPECT_EQ(Triple::wasm32, T.get32BitArchVariant().getArch()); in TEST()
619 EXPECT_EQ(Triple::wasm64, T.get64BitArchVariant().getArch()); in TEST()
623 Triple T; in TEST()
624 EXPECT_EQ(Triple::UnknownArch, T.getBigEndianArchVariant().getArch()); in TEST()
625 EXPECT_EQ(Triple::UnknownArch, T.getLittleEndianArchVariant().getArch()); in TEST()
627 T.setArch(Triple::UnknownArch); in TEST()
628 EXPECT_EQ(Triple::UnknownArch, T.getBigEndianArchVariant().getArch()); in TEST()
629 EXPECT_EQ(Triple::UnknownArch, T.getLittleEndianArchVariant().getArch()); in TEST()
631 T.setArch(Triple::aarch64_be); in TEST()
632 EXPECT_EQ(Triple::aarch64_be, T.getBigEndianArchVariant().getArch()); in TEST()
633 EXPECT_EQ(Triple::aarch64, T.getLittleEndianArchVariant().getArch()); in TEST()
635 T.setArch(Triple::aarch64); in TEST()
636 EXPECT_EQ(Triple::aarch64_be, T.getBigEndianArchVariant().getArch()); in TEST()
637 EXPECT_EQ(Triple::aarch64, T.getLittleEndianArchVariant().getArch()); in TEST()
639 T.setArch(Triple::armeb); in TEST()
640 EXPECT_EQ(Triple::armeb, T.getBigEndianArchVariant().getArch()); in TEST()
641 EXPECT_EQ(Triple::UnknownArch, T.getLittleEndianArchVariant().getArch()); in TEST()
643 T.setArch(Triple::arm); in TEST()
644 EXPECT_EQ(Triple::UnknownArch, T.getBigEndianArchVariant().getArch()); in TEST()
645 EXPECT_EQ(Triple::arm, T.getLittleEndianArchVariant().getArch()); in TEST()
646 T = Triple("arm"); in TEST()
648 T = Triple("thumb"); in TEST()
650 T = Triple("armeb"); in TEST()
652 T = Triple("thumbeb"); in TEST()
655 T.setArch(Triple::bpfeb); in TEST()
656 EXPECT_EQ(Triple::bpfeb, T.getBigEndianArchVariant().getArch()); in TEST()
657 EXPECT_EQ(Triple::bpfel, T.getLittleEndianArchVariant().getArch()); in TEST()
659 T.setArch(Triple::bpfel); in TEST()
660 EXPECT_EQ(Triple::bpfeb, T.getBigEndianArchVariant().getArch()); in TEST()
661 EXPECT_EQ(Triple::bpfel, T.getLittleEndianArchVariant().getArch()); in TEST()
663 T.setArch(Triple::mips64); in TEST()
664 EXPECT_EQ(Triple::mips64, T.getBigEndianArchVariant().getArch()); in TEST()
665 EXPECT_EQ(Triple::mips64el, T.getLittleEndianArchVariant().getArch()); in TEST()
667 T.setArch(Triple::mips64el); in TEST()
668 EXPECT_EQ(Triple::mips64, T.getBigEndianArchVariant().getArch()); in TEST()
669 EXPECT_EQ(Triple::mips64el, T.getLittleEndianArchVariant().getArch()); in TEST()
671 T.setArch(Triple::mips); in TEST()
672 EXPECT_EQ(Triple::mips, T.getBigEndianArchVariant().getArch()); in TEST()
673 EXPECT_EQ(Triple::mipsel, T.getLittleEndianArchVariant().getArch()); in TEST()
675 T.setArch(Triple::mipsel); in TEST()
676 EXPECT_EQ(Triple::mips, T.getBigEndianArchVariant().getArch()); in TEST()
677 EXPECT_EQ(Triple::mipsel, T.getLittleEndianArchVariant().getArch()); in TEST()
679 T.setArch(Triple::ppc); in TEST()
680 EXPECT_EQ(Triple::ppc, T.getBigEndianArchVariant().getArch()); in TEST()
681 EXPECT_EQ(Triple::UnknownArch, T.getLittleEndianArchVariant().getArch()); in TEST()
683 T.setArch(Triple::ppc64); in TEST()
684 EXPECT_EQ(Triple::ppc64, T.getBigEndianArchVariant().getArch()); in TEST()
685 EXPECT_EQ(Triple::ppc64le, T.getLittleEndianArchVariant().getArch()); in TEST()
687 T.setArch(Triple::ppc64le); in TEST()
688 EXPECT_EQ(Triple::ppc64, T.getBigEndianArchVariant().getArch()); in TEST()
689 EXPECT_EQ(Triple::ppc64le, T.getLittleEndianArchVariant().getArch()); in TEST()
691 T.setArch(Triple::sparc); in TEST()
692 EXPECT_EQ(Triple::sparc, T.getBigEndianArchVariant().getArch()); in TEST()
693 EXPECT_EQ(Triple::sparcel, T.getLittleEndianArchVariant().getArch()); in TEST()
695 T.setArch(Triple::sparcel); in TEST()
696 EXPECT_EQ(Triple::sparc, T.getBigEndianArchVariant().getArch()); in TEST()
697 EXPECT_EQ(Triple::sparcel, T.getLittleEndianArchVariant().getArch()); in TEST()
699 T.setArch(Triple::thumb); in TEST()
700 EXPECT_EQ(Triple::UnknownArch, T.getBigEndianArchVariant().getArch()); in TEST()
701 EXPECT_EQ(Triple::thumb, T.getLittleEndianArchVariant().getArch()); in TEST()
703 T.setArch(Triple::thumbeb); in TEST()
704 EXPECT_EQ(Triple::thumbeb, T.getBigEndianArchVariant().getArch()); in TEST()
705 EXPECT_EQ(Triple::UnknownArch, T.getLittleEndianArchVariant().getArch()); in TEST()
707 T.setArch(Triple::lanai); in TEST()
708 EXPECT_EQ(Triple::lanai, T.getBigEndianArchVariant().getArch()); in TEST()
709 EXPECT_EQ(Triple::UnknownArch, T.getLittleEndianArchVariant().getArch()); in TEST()
713 Triple T; in TEST()
716 T = Triple("i386-apple-darwin9"); in TEST()
731 T = Triple("x86_64-apple-darwin9"); in TEST()
746 T = Triple("x86_64-apple-macosx"); in TEST()
761 T = Triple("x86_64-apple-macosx10.7"); in TEST()
776 T = Triple("armv7-apple-ios"); in TEST()
791 T = Triple("armv7-apple-ios7.0"); in TEST()
808 EXPECT_EQ(Triple::ELF, Triple("i686-unknown-linux-gnu").getObjectFormat()); in TEST()
809 EXPECT_EQ(Triple::ELF, Triple("i686-unknown-freebsd").getObjectFormat()); in TEST()
810 EXPECT_EQ(Triple::ELF, Triple("i686-unknown-netbsd").getObjectFormat()); in TEST()
811 EXPECT_EQ(Triple::ELF, Triple("i686--win32-elf").getObjectFormat()); in TEST()
812 EXPECT_EQ(Triple::ELF, Triple("i686---elf").getObjectFormat()); in TEST()
814 EXPECT_EQ(Triple::MachO, Triple("i686-apple-macosx").getObjectFormat()); in TEST()
815 EXPECT_EQ(Triple::MachO, Triple("i686-apple-ios").getObjectFormat()); in TEST()
816 EXPECT_EQ(Triple::MachO, Triple("i686---macho").getObjectFormat()); in TEST()
818 EXPECT_EQ(Triple::COFF, Triple("i686--win32").getObjectFormat()); in TEST()
820 EXPECT_EQ(Triple::ELF, Triple("i686-pc-windows-msvc-elf").getObjectFormat()); in TEST()
821 EXPECT_EQ(Triple::ELF, Triple("i686-pc-cygwin-elf").getObjectFormat()); in TEST()
823 Triple MSVCNormalized(Triple::normalize("i686-pc-windows-msvc-elf")); in TEST()
824 EXPECT_EQ(Triple::ELF, MSVCNormalized.getObjectFormat()); in TEST()
826 Triple GNUWindowsNormalized(Triple::normalize("i686-pc-windows-gnu-elf")); in TEST()
827 EXPECT_EQ(Triple::ELF, GNUWindowsNormalized.getObjectFormat()); in TEST()
829 Triple CygnusNormalised(Triple::normalize("i686-pc-windows-cygnus-elf")); in TEST()
830 EXPECT_EQ(Triple::ELF, CygnusNormalised.getObjectFormat()); in TEST()
832 Triple CygwinNormalized(Triple::normalize("i686-pc-cygwin-elf")); in TEST()
833 EXPECT_EQ(Triple::ELF, CygwinNormalized.getObjectFormat()); in TEST()
835 Triple T = Triple(""); in TEST()
836 T.setObjectFormat(Triple::ELF); in TEST()
837 EXPECT_EQ(Triple::ELF, T.getObjectFormat()); in TEST()
841 EXPECT_EQ("i686-pc-windows-msvc", Triple::normalize("i686-pc-win32")); in TEST()
842 EXPECT_EQ("i686--windows-msvc", Triple::normalize("i686-win32")); in TEST()
843 EXPECT_EQ("i686-pc-windows-gnu", Triple::normalize("i686-pc-mingw32")); in TEST()
844 EXPECT_EQ("i686--windows-gnu", Triple::normalize("i686-mingw32")); in TEST()
845 EXPECT_EQ("i686-pc-windows-gnu", Triple::normalize("i686-pc-mingw32-w64")); in TEST()
846 EXPECT_EQ("i686--windows-gnu", Triple::normalize("i686-mingw32-w64")); in TEST()
847 EXPECT_EQ("i686-pc-windows-cygnus", Triple::normalize("i686-pc-cygwin")); in TEST()
848 EXPECT_EQ("i686--windows-cygnus", Triple::normalize("i686-cygwin")); in TEST()
850 EXPECT_EQ("x86_64-pc-windows-msvc", Triple::normalize("x86_64-pc-win32")); in TEST()
851 EXPECT_EQ("x86_64--windows-msvc", Triple::normalize("x86_64-win32")); in TEST()
852 EXPECT_EQ("x86_64-pc-windows-gnu", Triple::normalize("x86_64-pc-mingw32")); in TEST()
853 EXPECT_EQ("x86_64--windows-gnu", Triple::normalize("x86_64-mingw32")); in TEST()
854 EXPECT_EQ("x86_64-pc-windows-gnu", Triple::normalize("x86_64-pc-mingw32-w64")); in TEST()
855 EXPECT_EQ("x86_64--windows-gnu", Triple::normalize("x86_64-mingw32-w64")); in TEST()
857 EXPECT_EQ("i686-pc-windows-elf", Triple::normalize("i686-pc-win32-elf")); in TEST()
858 EXPECT_EQ("i686--windows-elf", Triple::normalize("i686-win32-elf")); in TEST()
859 EXPECT_EQ("i686-pc-windows-macho", Triple::normalize("i686-pc-win32-macho")); in TEST()
860 EXPECT_EQ("i686--windows-macho", Triple::normalize("i686-win32-macho")); in TEST()
862 EXPECT_EQ("x86_64-pc-windows-elf", Triple::normalize("x86_64-pc-win32-elf")); in TEST()
863 EXPECT_EQ("x86_64--windows-elf", Triple::normalize("x86_64-win32-elf")); in TEST()
864 EXPECT_EQ("x86_64-pc-windows-macho", Triple::normalize("x86_64-pc-win32-macho")); in TEST()
865 EXPECT_EQ("x86_64--windows-macho", Triple::normalize("x86_64-win32-macho")); in TEST()
868 Triple::normalize("i686-pc-windows-cygnus")); in TEST()
869 EXPECT_EQ("i686-pc-windows-gnu", Triple::normalize("i686-pc-windows-gnu")); in TEST()
870 EXPECT_EQ("i686-pc-windows-itanium", Triple::normalize("i686-pc-windows-itanium")); in TEST()
871 EXPECT_EQ("i686-pc-windows-msvc", Triple::normalize("i686-pc-windows-msvc")); in TEST()
873 EXPECT_EQ("i686-pc-windows-elf", Triple::normalize("i686-pc-windows-elf-elf")); in TEST()
879 llvm::Triple Triple("armv4-unknown-eabi"); in TEST() local
880 EXPECT_EQ("strongarm", Triple.getARMCPUForArch()); in TEST()
883 llvm::Triple Triple("armv4t-unknown-eabi"); in TEST() local
884 EXPECT_EQ("arm7tdmi", Triple.getARMCPUForArch()); in TEST()
887 llvm::Triple Triple("armv5-unknown-eabi"); in TEST() local
888 EXPECT_EQ("arm10tdmi", Triple.getARMCPUForArch()); in TEST()
891 llvm::Triple Triple("armv5t-unknown-eabi"); in TEST() local
892 EXPECT_EQ("arm10tdmi", Triple.getARMCPUForArch()); in TEST()
895 llvm::Triple Triple("armv5e-unknown-eabi"); in TEST() local
896 EXPECT_EQ("arm1022e", Triple.getARMCPUForArch()); in TEST()
899 llvm::Triple Triple("armv5tej-unknown-eabi"); in TEST() local
900 EXPECT_EQ("arm926ej-s", Triple.getARMCPUForArch()); in TEST()
903 llvm::Triple Triple("armv6-unknown-eabi"); in TEST() local
904 EXPECT_EQ("arm1136jf-s", Triple.getARMCPUForArch()); in TEST()
907 llvm::Triple Triple("armv6j-unknown-eabi"); in TEST() local
908 EXPECT_EQ("arm1136jf-s", Triple.getARMCPUForArch()); in TEST()
911 llvm::Triple Triple("armv6k-unknown-eabi"); in TEST() local
912 EXPECT_EQ("arm1176j-s", Triple.getARMCPUForArch()); in TEST()
915 llvm::Triple Triple("armv6kz-unknown-eabi"); in TEST() local
916 EXPECT_EQ("arm1176jzf-s", Triple.getARMCPUForArch()); in TEST()
919 llvm::Triple Triple("armv6zk-unknown-eabi"); in TEST() local
920 EXPECT_EQ("arm1176jzf-s", Triple.getARMCPUForArch()); in TEST()
923 llvm::Triple Triple("armv6t2-unknown-eabi"); in TEST() local
924 EXPECT_EQ("arm1156t2-s", Triple.getARMCPUForArch()); in TEST()
927 llvm::Triple Triple("armv6m-unknown-eabi"); in TEST() local
928 EXPECT_EQ("cortex-m0", Triple.getARMCPUForArch()); in TEST()
931 llvm::Triple Triple("armv7-unknown-eabi"); in TEST() local
932 EXPECT_EQ("cortex-a8", Triple.getARMCPUForArch()); in TEST()
935 llvm::Triple Triple("armv7a-unknown-eabi"); in TEST() local
936 EXPECT_EQ("cortex-a8", Triple.getARMCPUForArch()); in TEST()
939 llvm::Triple Triple("armv7m-unknown-eabi"); in TEST() local
940 EXPECT_EQ("cortex-m3", Triple.getARMCPUForArch()); in TEST()
943 llvm::Triple Triple("armv7r-unknown-eabi"); in TEST() local
944 EXPECT_EQ("cortex-r4", Triple.getARMCPUForArch()); in TEST()
947 llvm::Triple Triple("armv7r-unknown-eabi"); in TEST() local
948 EXPECT_EQ("cortex-r4", Triple.getARMCPUForArch()); in TEST()
951 llvm::Triple Triple("armv7r-unknown-eabi"); in TEST() local
952 EXPECT_EQ("cortex-r4", Triple.getARMCPUForArch()); in TEST()
955 llvm::Triple Triple("armv7r-unknown-eabi"); in TEST() local
956 EXPECT_EQ("cortex-r4", Triple.getARMCPUForArch()); in TEST()
959 llvm::Triple Triple("armv8a-unknown-eabi"); in TEST() local
960 EXPECT_EQ("cortex-a53", Triple.getARMCPUForArch()); in TEST()
963 llvm::Triple Triple("armv8.1a-unknown-eabi"); in TEST() local
964 EXPECT_EQ("generic", Triple.getARMCPUForArch()); in TEST()
968 llvm::Triple Triple("arm"); in TEST() local
969 EXPECT_EQ("cortex-a8", Triple.getARMCPUForArch("armv7-a")); in TEST()
972 llvm::Triple Triple("arm"); in TEST() local
973 EXPECT_EQ("cortex-m3", Triple.getARMCPUForArch("armv7-m")); in TEST()
976 llvm::Triple Triple("arm"); in TEST() local
977 EXPECT_EQ("cortex-a53", Triple.getARMCPUForArch("armv8")); in TEST()
980 llvm::Triple Triple("arm"); in TEST() local
981 EXPECT_EQ("cortex-a53", Triple.getARMCPUForArch("armv8-a")); in TEST()
985 llvm::Triple Triple("arm--nacl"); in TEST() local
986 EXPECT_EQ("cortex-a8", Triple.getARMCPUForArch()); in TEST()
989 llvm::Triple Triple("armv6-unknown-freebsd"); in TEST() local
990 EXPECT_EQ("arm1176jzf-s", Triple.getARMCPUForArch()); in TEST()
993 llvm::Triple Triple("thumbv6-unknown-freebsd"); in TEST() local
994 EXPECT_EQ("arm1176jzf-s", Triple.getARMCPUForArch()); in TEST()
997 llvm::Triple Triple("armebv6-unknown-freebsd"); in TEST() local
998 EXPECT_EQ("arm1176jzf-s", Triple.getARMCPUForArch()); in TEST()
1001 llvm::Triple Triple("arm--win32"); in TEST() local
1002 EXPECT_EQ("cortex-a9", Triple.getARMCPUForArch()); in TEST()
1006 llvm::Triple Triple("xscale-unknown-eabi"); in TEST() local
1007 EXPECT_EQ("xscale", Triple.getARMCPUForArch()); in TEST()
1010 llvm::Triple Triple("iwmmxt-unknown-eabi"); in TEST() local
1011 EXPECT_EQ("iwmmxt", Triple.getARMCPUForArch()); in TEST()
1014 llvm::Triple Triple("armv7s-apple-ios7"); in TEST() local
1015 EXPECT_EQ("swift", Triple.getARMCPUForArch()); in TEST()
1018 llvm::Triple Triple("armv7k-apple-ios9"); in TEST() local
1019 EXPECT_EQ("cortex-a7", Triple.getARMCPUForArch()); in TEST()
1022 llvm::Triple Triple("armv7k-apple-watchos3"); in TEST() local
1023 EXPECT_EQ("cortex-a7", Triple.getARMCPUForArch()); in TEST()
1026 llvm::Triple Triple("armv7k-apple-tvos9"); in TEST() local
1027 EXPECT_EQ("cortex-a7", Triple.getARMCPUForArch()); in TEST()
1030 llvm::Triple Triple("armv7em-apple-ios7"); in TEST() local
1031 EXPECT_EQ("cortex-m4", Triple.getARMCPUForArch()); in TEST()
1034 llvm::Triple Triple("armv7l-linux-gnueabihf"); in TEST() local
1035 EXPECT_EQ("cortex-a8", Triple.getARMCPUForArch()); in TEST()
1038 llvm::Triple Triple("armv6sm-apple-ios7"); in TEST() local
1039 EXPECT_EQ("cortex-m0", Triple.getARMCPUForArch()); in TEST()
1043 llvm::Triple Triple("armeb-none-eabi"); in TEST() local
1044 EXPECT_EQ("arm7tdmi", Triple.getARMCPUForArch()); in TEST()
1047 llvm::Triple Triple("armebeb-none-eabi"); in TEST() local
1048 EXPECT_EQ("", Triple.getARMCPUForArch()); in TEST()
1051 llvm::Triple Triple("armebv6eb-none-eabi"); in TEST() local
1052 EXPECT_EQ("", Triple.getARMCPUForArch()); in TEST()
1056 llvm::Triple Triple("armebv6-non-eabi"); in TEST() local
1057 EXPECT_EQ("arm1136jf-s", Triple.getARMCPUForArch()); in TEST()
1060 llvm::Triple Triple("armv6eb-none-eabi"); in TEST() local
1061 EXPECT_EQ("arm1136jf-s", Triple.getARMCPUForArch()); in TEST()
1065 llvm::Triple Triple("xscaleeb-none-eabi"); in TEST() local
1066 EXPECT_EQ("xscale", Triple.getARMCPUForArch()); in TEST()
1069 llvm::Triple Triple("armebxscale-none-eabi"); in TEST() local
1070 EXPECT_EQ("", Triple.getARMCPUForArch()); in TEST()
1075 EXPECT_EQ("armv6--netbsd-eabi", Triple::normalize("armv6-netbsd-eabi")); in TEST()
1076 EXPECT_EQ("armv7--netbsd-eabi", Triple::normalize("armv7-netbsd-eabi")); in TEST()
1077 EXPECT_EQ("armv6eb--netbsd-eabi", Triple::normalize("armv6eb-netbsd-eabi")); in TEST()
1078 EXPECT_EQ("armv7eb--netbsd-eabi", Triple::normalize("armv7eb-netbsd-eabi")); in TEST()
1079 EXPECT_EQ("armv6--netbsd-eabihf", Triple::normalize("armv6-netbsd-eabihf")); in TEST()
1080 EXPECT_EQ("armv7--netbsd-eabihf", Triple::normalize("armv7-netbsd-eabihf")); in TEST()
1081 EXPECT_EQ("armv6eb--netbsd-eabihf", Triple::normalize("armv6eb-netbsd-eabihf")); in TEST()
1082 EXPECT_EQ("armv7eb--netbsd-eabihf", Triple::normalize("armv7eb-netbsd-eabihf")); in TEST()
1084 Triple T; in TEST()
1085 T = Triple("armv6--netbsd-eabi"); in TEST()
1086 EXPECT_EQ(Triple::arm, T.getArch()); in TEST()
1087 T = Triple("armv6eb--netbsd-eabi"); in TEST()
1088 EXPECT_EQ(Triple::armeb, T.getArch()); in TEST()
1094 Triple T = Triple("arm"); in TEST()
1095 EXPECT_EQ(Triple::arm, T.getArch()); in TEST()
1098 Triple T = Triple("armv6t2"); in TEST()
1099 EXPECT_EQ(Triple::arm, T.getArch()); in TEST()
1102 Triple T = Triple("armv8"); in TEST()
1103 EXPECT_EQ(Triple::arm, T.getArch()); in TEST()
1106 Triple T = Triple("armeb"); in TEST()
1107 EXPECT_EQ(Triple::armeb, T.getArch()); in TEST()
1110 Triple T = Triple("armv5eb"); in TEST()
1111 EXPECT_EQ(Triple::armeb, T.getArch()); in TEST()
1114 Triple T = Triple("armebv7m"); in TEST()
1115 EXPECT_EQ(Triple::armeb, T.getArch()); in TEST()
1118 Triple T = Triple("armv7eb"); in TEST()
1119 EXPECT_EQ(Triple::armeb, T.getArch()); in TEST()
1123 Triple T = Triple("thumb"); in TEST()
1124 EXPECT_EQ(Triple::thumb, T.getArch()); in TEST()
1127 Triple T = Triple("thumbv7a"); in TEST()
1128 EXPECT_EQ(Triple::thumb, T.getArch()); in TEST()
1131 Triple T = Triple("thumbeb"); in TEST()
1132 EXPECT_EQ(Triple::thumbeb, T.getArch()); in TEST()
1135 Triple T = Triple("thumbv4teb"); in TEST()
1136 EXPECT_EQ(Triple::thumbeb, T.getArch()); in TEST()
1139 Triple T = Triple("thumbebv7"); in TEST()
1140 EXPECT_EQ(Triple::thumbeb, T.getArch()); in TEST()
1143 Triple T = Triple("armv6m"); in TEST()
1144 EXPECT_EQ(Triple::thumb, T.getArch()); in TEST()
1147 Triple T = Triple("thumbv2"); in TEST()
1148 EXPECT_EQ(Triple::UnknownArch, T.getArch()); in TEST()
1151 Triple T = Triple("thumbebv6eb"); in TEST()
1152 EXPECT_EQ(Triple::UnknownArch, T.getArch()); in TEST()
1156 Triple T = Triple("arm64"); in TEST()
1157 EXPECT_EQ(Triple::aarch64, T.getArch()); in TEST()
1160 Triple T = Triple("aarch64"); in TEST()
1161 EXPECT_EQ(Triple::aarch64, T.getArch()); in TEST()
1164 Triple T = Triple("aarch64_be"); in TEST()
1165 EXPECT_EQ(Triple::aarch64_be, T.getArch()); in TEST()
1168 Triple T = Triple("aarch64be"); in TEST()
1169 EXPECT_EQ(Triple::UnknownArch, T.getArch()); in TEST()
1172 Triple T = Triple("arm64be"); in TEST()
1173 EXPECT_EQ(Triple::UnknownArch, T.getArch()); in TEST()