1 # Copyright (C) 2012-2018 Free Software Foundation, Inc.
3 # This program is free software; you can redistribute it and/or modify
4 # it under the terms of the GNU General Public License as published by
5 # the Free Software Foundation; either version 3 of the License, or
6 # (at your option) any later version.
8 # This program is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 # GNU General Public License for more details.
13 # You should have received a copy of the GNU General Public License
14 # along with this program; if not, write to the Free Software
15 # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
20 proc gas_64_check { } {
24 set status [gas_host_run "$NM $NMFLAGS --help" ""]
25 return [regexp "targets:.*x86-64" [lindex $status 1]];
28 proc gas_32_check { } {
32 set status [gas_host_run "$NM $NMFLAGS --help" ""]
33 return [regexp "targets:.*i386" [lindex $status 1]];
36 if [expr ([istarget "i*86-*-*"] || [istarget "x86_64-*-*"]) && [gas_32_check]] then {
39 set old_ASFLAGS "$ASFLAGS"
40 set ASFLAGS "$ASFLAGS --32"
42 run_list_test "float" "-al -mmnemonic=att"
43 run_list_test "general" "-al --listing-lhs-width=2"
44 run_list_test "inval" "-al"
45 run_list_test "inval-16" "-al"
46 run_list_test "segment" "-al"
47 run_list_test "inval-seg" "-al"
48 run_list_test "inval-reg" "-al"
49 run_list_test "modrm" "-al --listing-lhs-width=2"
51 run_dump_test "opcode"
52 run_dump_test "opcode-intel"
53 run_dump_test "opcode-suffix"
55 run_dump_test "intel-intel"
56 run_dump_test "intel16"
57 run_list_test "intelbad" ""
58 run_dump_test "intelok"
59 run_dump_test "prefix"
61 run_dump_test "katmai"
63 run_dump_test "movz32"
64 run_dump_test "relax-1"
65 run_dump_test "relax-2"
66 run_dump_test "ssemmx2"
71 run_dump_test "sib-intel"
73 run_dump_test "disp-intel"
74 run_dump_test "disp32"
76 run_dump_test "vmfunc"
78 run_dump_test "suffix"
79 run_dump_test "suffix-intel"
80 run_list_test "suffix-bad"
81 run_dump_test "immed32"
83 run_dump_test "divide"
84 run_dump_test "padlock"
86 run_list_test "cr-err" ""
89 run_dump_test "amdfam10"
92 run_dump_test "rep-suffix"
93 run_list_test "inval-rep" "-al"
94 run_dump_test "lock-1"
95 run_dump_test "lock-1-intel"
96 run_list_test "lockbad-1" "-al"
97 run_dump_test "long-1"
98 run_dump_test "long-1-intel"
101 run_dump_test "nops16-1"
102 run_dump_test "nops-1"
103 run_dump_test "nops-1-i386"
104 run_dump_test "nops-1-i386-i686"
105 run_dump_test "nops-1-i686"
106 run_dump_test "nops-1-k8"
107 run_dump_test "nops-1-core2"
108 run_dump_test "nops-2"
109 run_dump_test "nops-2-i386"
110 run_dump_test "nops-2-core2"
111 run_dump_test "nops-3"
112 run_dump_test "nops-3-i386"
113 run_dump_test "nops-3-i686"
114 run_dump_test "nops-4"
115 run_dump_test "nops-4-i386"
116 run_dump_test "nops-4-i686"
117 run_dump_test "nops-4a-i686"
118 run_dump_test "nops-5"
119 run_dump_test "nops-5-i686"
120 run_dump_test "nops-6"
121 run_dump_test "nops-7"
122 run_dump_test "addr16"
123 run_dump_test "addr32"
124 run_dump_test "sse4_1"
125 run_dump_test "sse4_1-intel"
126 run_dump_test "sse4_2"
127 run_dump_test "sse4_2-intel"
128 run_dump_test "crc32"
129 run_dump_test "crc32-intel"
130 run_list_test "inval-crc32" "-al"
132 run_dump_test "simd-intel"
133 run_dump_test "simd-suffix"
135 run_dump_test "mem-intel"
137 run_dump_test "reg-intel"
139 run_dump_test "i386-intel"
140 run_dump_test "compat"
141 run_dump_test "compat-intel"
142 run_dump_test "arch-1"
143 run_dump_test "arch-2"
144 run_dump_test "arch-3"
145 run_dump_test "arch-4"
146 run_dump_test "arch-5"
147 run_dump_test "arch-6"
148 run_dump_test "arch-7"
149 run_dump_test "arch-9"
150 run_dump_test "arch-10"
151 run_dump_test "arch-10-lzcnt"
152 run_dump_test "arch-10-prefetchw"
153 run_dump_test "arch-10-bdver1"
154 run_dump_test "arch-10-bdver2"
155 run_dump_test "arch-10-bdver3"
156 run_dump_test "arch-10-bdver4"
157 run_dump_test "arch-13-znver1"
158 run_dump_test "arch-13-znver2"
159 run_dump_test "arch-10-btver1"
160 run_dump_test "arch-10-btver2"
161 run_list_test "arch-10-1" "-march=generic32 -I${srcdir}/$subdir -al"
162 run_list_test "arch-10-2" "-march=i686 -I${srcdir}/$subdir -al"
163 run_list_test "arch-10-3" "-march=i686+mmx+sse4.2 -I${srcdir}/$subdir -al"
164 run_list_test "arch-10-4" "-march=i686+mmx+sse4+vmx+smx -I${srcdir}/$subdir -al"
165 run_dump_test "arch-11"
166 run_dump_test "arch-12"
167 run_dump_test "arch-13"
171 run_list_test "no87" "-al"
172 run_list_test "no87-2" "-march=i686+no87 -al"
173 run_list_test "no87-3" "-al"
174 run_list_test "stN" "-al"
176 run_list_test "nommx-1" "-al"
177 run_list_test "nommx-2" "-march=core+nommx -al"
178 run_list_test "nommx-3" "-march=+nommx -al"
179 run_list_test "nosse-1" "-al"
180 run_list_test "nosse-2" "-march=core+nosse -al"
181 run_list_test "nosse-3" "-march=+nosse -al"
182 run_list_test "nosse-4" "-al"
183 run_dump_test "nosse-5"
184 run_list_test "noavx-1" "-al"
185 run_list_test "noavx-2" "-march=+noavx -al"
186 run_list_test "noavx-3" "-al"
187 run_dump_test "noavx-4"
188 run_list_test "noavx512-1" "-al"
189 run_list_test "noavx512-2" "-al"
190 run_dump_test "noextreg"
191 run_dump_test "xmmhi32"
192 run_dump_test "xsave"
193 run_dump_test "xsave-intel"
195 run_dump_test "aes-intel"
196 run_dump_test "clmul"
197 run_dump_test "clmul-intel"
199 run_dump_test "avx-intel"
200 run_dump_test "avx-scalar"
201 run_dump_test "avx-scalar-intel"
202 run_dump_test "avx256int"
203 run_dump_test "avx256int-intel"
205 run_dump_test "avx2-intel"
206 run_dump_test "avx-gather"
207 run_dump_test "avx-gather-intel"
208 run_dump_test "avx512f"
209 run_dump_test "avx512f-intel"
210 run_dump_test "avx512f-opts"
211 run_dump_test "avx512f-opts-intel"
212 run_dump_test "avx512f-nondef"
213 run_list_test "avx512f-plain" "-al"
214 run_dump_test "avx512f-ymm"
215 run_dump_test "avx512cd"
216 run_dump_test "avx512cd-intel"
217 run_dump_test "avx512er"
218 run_dump_test "avx512er-intel"
219 run_dump_test "avx512pf"
220 run_dump_test "avx512pf-intel"
221 run_dump_test "evex-lig256"
222 run_dump_test "evex-lig512"
223 run_dump_test "evex-lig256-intel"
224 run_dump_test "evex-lig512-intel"
225 run_dump_test "evex-wig1"
226 run_dump_test "evex-wig1-intel"
227 run_dump_test "evex-no-scale-32"
228 run_dump_test "sse2avx"
229 run_list_test "inval-avx" "-al"
230 run_list_test "inval-avx512f" "-al"
231 run_dump_test "sse-check"
232 run_dump_test "sse-check-none"
233 run_dump_test "sse-check-warn"
234 run_list_test "sse-check-error" "-msse-check=error -I${srcdir}/$subdir -al"
235 run_dump_test "vgather-check"
236 run_dump_test "vgather-check-none"
237 run_dump_test "vgather-check-warn"
238 run_list_test "vgather-check-error" "-moperand-check=error -I${srcdir}/$subdir"
239 run_dump_test "sse-noavx"
240 run_dump_test "movbe"
241 run_dump_test "movbe-intel"
242 run_list_test "inval-movbe" "-al"
244 run_dump_test "ept-intel"
245 run_list_test "inval-ept" "-al"
246 run_dump_test "invpcid"
247 run_dump_test "invpcid-intel"
248 run_list_test "inval-invpcid" "-al"
249 run_dump_test "arch-avx-1"
250 run_list_test "arch-avx-1-1" "-march=generic32+avx -I${srcdir}/$subdir -al"
251 run_list_test "arch-avx-1-2" "-march=generic32+aes -I${srcdir}/$subdir -al"
252 run_list_test "arch-avx-1-3" "-march=generic32+pclmul -I${srcdir}/$subdir -al"
253 run_list_test "arch-avx-1-4" "-march=generic32+avx+aes -I${srcdir}/$subdir -al"
254 run_list_test "arch-avx-1-5" "-march=generic32+avx+pclmul -I${srcdir}/$subdir -al"
255 run_list_test "arch-avx-1-6" "-march=generic32+aes+pclmul -I${srcdir}/$subdir -al"
256 run_list_test "arch-avx-1-7" "-march=generic32+gfni -I${srcdir}/$subdir -al"
257 run_list_test "arch-avx-1-8" "-march=generic32+avx+gfni -I${srcdir}/$subdir -al"
259 run_dump_test "opts-intel"
260 run_dump_test "sse2avx-opts"
261 run_dump_test "sse2avx-opts-intel"
263 run_dump_test "bmi2-intel"
265 run_dump_test "fma-intel"
266 run_dump_test "fma-scalar"
267 run_dump_test "fma-scalar-intel"
269 run_dump_test "hle-intel"
270 run_list_test "hlebad" "-al"
272 run_dump_test "rtm-intel"
276 run_dump_test "xop32reg"
278 run_dump_test "bmi-intel"
280 run_dump_test "tbm-intel"
282 run_dump_test "f16c-intel"
284 run_dump_test "fsgs-intel"
285 run_dump_test "rdrnd"
286 run_dump_test "rdrnd-intel"
287 run_dump_test "bundle"
288 run_dump_test "bundle-lock"
289 run_dump_test "bundle-bad"
291 run_dump_test "adx-intel"
292 run_dump_test "rdseed"
293 run_dump_test "rdseed-intel"
294 run_dump_test "prefetch"
295 run_dump_test "prefetch-intel"
298 run_list_test "mpx-inval-1" "-al"
299 run_list_test "mpx-inval-2" "-al"
300 run_dump_test "mpx-add-bnd-prefix"
301 run_list_test "bnd" "-al"
303 run_dump_test "clflushopt"
304 run_dump_test "clflushopt-intel"
305 run_dump_test "xsavec"
306 run_dump_test "xsavec-intel"
307 run_dump_test "xsaves"
308 run_dump_test "xsaves-intel"
309 run_dump_test "prefetchwt1"
310 run_dump_test "prefetchwt1-intel"
312 run_dump_test "avx512f_vl-intel"
313 run_dump_test "avx512f_vl-opts-intel"
314 run_dump_test "avx512f_vl-opts"
315 run_dump_test "avx512f_vl-wig1-intel"
316 run_dump_test "avx512f_vl-wig1"
317 run_dump_test "avx512f_vl"
318 run_dump_test "avx512cd_vl-intel"
319 run_dump_test "avx512cd_vl"
320 run_dump_test "avx512bw-intel"
321 run_dump_test "avx512bw-opts-intel"
322 run_dump_test "avx512bw-opts"
323 run_dump_test "avx512bw-wig1-intel"
324 run_dump_test "avx512bw-wig1"
325 run_dump_test "avx512bw"
326 run_dump_test "avx512bw_vl-intel"
327 run_dump_test "avx512bw_vl-opts-intel"
328 run_dump_test "avx512bw_vl-opts"
329 run_dump_test "avx512bw_vl-wig1-intel"
330 run_dump_test "avx512bw_vl-wig1"
331 run_dump_test "avx512bw_vl"
332 run_dump_test "avx512dq-intel"
333 run_dump_test "avx512dq"
334 run_dump_test "avx512dq_vl-intel"
335 run_dump_test "avx512dq_vl"
336 run_dump_test "omit-lock-yes"
337 run_dump_test "omit-lock-no"
338 run_dump_test "fence-as-lock-add-yes"
339 run_dump_test "fence-as-lock-add-no"
340 run_dump_test "avx512dq-rcigrd-intel"
341 run_dump_test "avx512dq-rcigrd"
342 run_dump_test "avx512dq-rcigrne-intel"
343 run_dump_test "avx512dq-rcigrne"
344 run_dump_test "avx512dq-rcigru-intel"
345 run_dump_test "avx512dq-rcigru"
346 run_dump_test "avx512dq-rcigrz-intel"
347 run_dump_test "avx512dq-rcigrz"
348 run_dump_test "avx512er-rcigrd-intel"
349 run_dump_test "avx512er-rcigrd"
350 run_dump_test "avx512er-rcigrne-intel"
351 run_dump_test "avx512er-rcigrne"
352 run_dump_test "avx512er-rcigru-intel"
353 run_dump_test "avx512er-rcigru"
354 run_dump_test "avx512er-rcigrz-intel"
355 run_dump_test "avx512er-rcigrz"
356 run_dump_test "avx512f-rcigrd-intel"
357 run_dump_test "avx512f-rcigrd"
358 run_dump_test "avx512f-rcigrne-intel"
359 run_dump_test "avx512f-rcigrne"
360 run_dump_test "avx512f-rcigru-intel"
361 run_dump_test "avx512f-rcigru"
362 run_dump_test "avx512f-rcigrz-intel"
363 run_dump_test "avx512f-rcigrz"
365 run_dump_test "clwb-intel"
366 run_dump_test "avx512ifma"
367 run_dump_test "avx512ifma-intel"
368 run_dump_test "avx512ifma_vl"
369 run_dump_test "avx512ifma_vl-intel"
370 run_dump_test "avx512vbmi"
371 run_dump_test "avx512vbmi-intel"
372 run_dump_test "avx512vbmi_vl"
373 run_dump_test "avx512vbmi_vl-intel"
374 run_dump_test "avx512_4fmaps"
375 run_dump_test "avx512_4fmaps-intel"
376 run_list_test "avx512_4fmaps-warn"
377 run_dump_test "avx512_4vnniw"
378 run_dump_test "avx512_4vnniw-intel"
379 run_dump_test "avx512_vpopcntdq"
380 run_dump_test "avx512_vpopcntdq-intel"
381 run_dump_test "avx512vbmi2"
382 run_dump_test "avx512vbmi2-intel"
383 run_dump_test "avx512vbmi2_vl"
384 run_dump_test "avx512vbmi2_vl-intel"
385 run_dump_test "avx512f_gfni"
386 run_dump_test "avx512f_gfni-intel"
387 run_dump_test "avx512vl_gfni"
388 run_dump_test "avx512vl_gfni-intel"
389 run_dump_test "avx512f_vaes"
390 run_dump_test "avx512f_vaes-intel"
391 run_dump_test "avx512f_vaes-wig1"
392 run_dump_test "avx512f_vaes-wig1-intel"
393 run_dump_test "avx512vl_vaes"
394 run_dump_test "avx512vl_vaes-intel"
395 run_dump_test "avx512vl_vaes-wig1"
396 run_dump_test "avx512vl_vaes-wig1-intel"
397 run_dump_test "avx512f_vpclmulqdq"
398 run_dump_test "avx512f_vpclmulqdq-intel"
399 run_dump_test "avx512f_vpclmulqdq-wig1"
400 run_dump_test "avx512f_vpclmulqdq-wig1-intel"
401 run_dump_test "avx512vl_vpclmulqdq"
402 run_dump_test "avx512vl_vpclmulqdq-intel"
403 run_dump_test "avx512vl_vpclmulqdq-wig1"
404 run_dump_test "avx512vl_vpclmulqdq-wig1-intel"
405 run_dump_test "avx512vnni"
406 run_dump_test "avx512vnni-intel"
407 run_dump_test "avx512vnni_vl"
408 run_dump_test "avx512vnni_vl-intel"
409 run_dump_test "avx512bitalg"
410 run_dump_test "avx512bitalg-intel"
411 run_dump_test "avx512bitalg_vl"
412 run_dump_test "avx512bitalg_vl-intel"
413 run_dump_test "clzero"
414 run_dump_test "disassem"
415 run_dump_test "mwaitx-bdver4"
416 run_list_test "mwaitx-reg"
417 run_dump_test "ospke"
418 run_dump_test "rdpid"
419 run_dump_test "rdpid-intel"
420 run_dump_test "ptwrite"
421 run_dump_test "ptwrite-intel"
423 run_dump_test "gfni-intel"
425 run_dump_test "vaes-intel"
426 run_dump_test "vpclmulqdq"
427 run_dump_test "vpclmulqdq-intel"
428 run_dump_test "wbnoinvd"
429 run_dump_test "wbnoinvd-intel"
430 run_dump_test "pconfig"
431 run_dump_test "pconfig-intel"
432 run_dump_test "waitpkg"
433 run_dump_test "waitpkg-intel"
434 run_dump_test "cldemote"
435 run_dump_test "cldemote-intel"
436 run_dump_test "movdir"
437 run_dump_test "movdir-intel"
438 run_list_test "movdir64b-reg"
439 run_list_test "avx512vl-1" "-al"
440 run_list_test "avx512vl-2" "-al"
441 run_list_test "avx512vl-plain" "-al"
442 run_dump_test "fpu-bad"
444 run_dump_test "cet-intel"
445 run_list_test "cet-ibt-inval"
446 run_list_test "cet-shstk-inval"
447 run_dump_test "pseudos"
448 run_dump_test "notrack"
449 run_dump_test "notrack-intel"
450 run_list_test "notrackbad" "-al"
451 run_dump_test "align-1a"
452 run_dump_test "align-1b"
453 run_list_test "inval-pseudo" "-al"
454 run_dump_test "nop-1"
455 run_dump_test "nop-2"
456 run_dump_test "optimize-1"
457 run_dump_test "optimize-2"
458 run_dump_test "optimize-3"
459 run_dump_test "optimize-4"
460 run_dump_test "optimize-5"
462 # These tests require support for 8 and 16 bit relocs,
463 # so we only run them for ELF and COFF targets.
464 if {[is_elf_format] || [istarget "*-*-coff*"]} then {
465 run_dump_test "reloc"
466 run_dump_test "jump16"
467 run_list_test "white" "-al --listing-lhs-width=3"
469 # These tests should in theory work for PE targets as well,
470 # but the relocs we currently produce are slightly different
471 # from those produced for ELF/COFF based toolchains.
472 # So for now we ignore PE targets.
473 run_dump_test "absrel"
474 if {[istarget "*-*-coff*"]} then {
475 run_dump_test "pcrel"
480 if [is_elf_format] then {
481 # PIC is only supported on ELF targets.
482 run_dump_test "intelpic"
484 run_dump_test "pcrel-elf"
485 run_dump_test "relax"
486 run_dump_test "gotpc"
488 run_dump_test "tlspic"
489 run_dump_test "tlsnopic"
491 run_dump_test "reloc32"
492 run_list_test "reloc32" "--defsym _bad_=1"
493 run_dump_test "intel-got32"
494 run_dump_test "intel-movs32"
495 run_list_test "inval-equ-1" "-al"
496 run_list_test "inval-equ-2" "-al"
497 run_dump_test "ifunc"
498 run_list_test "ifunc-2"
499 run_dump_test "ifunc-3"
500 run_list_test "l1om-inval" "-march=l1om --32"
501 run_list_test "k1om-inval" "-march=k1om --32"
502 run_dump_test "localpic"
503 run_dump_test "debug1"
505 run_dump_test "dw2-compress-2"
506 run_dump_test "dw2-compressed-2"
508 run_dump_test "bad-size"
510 run_dump_test "size-1"
511 run_dump_test "size-2"
512 run_dump_test "size-3"
513 run_dump_test "size-4"
517 run_dump_test "relax-3"
518 run_dump_test "relax-4"
521 run_dump_test "got-no-relax"
523 run_dump_test "addend"
524 run_dump_test "nop-3"
525 run_dump_test "nop-4"
526 run_dump_test "nop-5"
527 run_dump_test "nop-6"
529 if { [gas_64_check] } then {
530 run_dump_test "att-regs"
531 run_dump_test "intel-regs"
532 run_dump_test "mixed-mode-reloc32"
533 run_dump_test "code64"
535 run_list_test "code64-inval" "-I${srcdir}/$subdir -al"
538 if {![istarget "*-*-nacl*"]} then {
539 run_dump_test "iamcu-1"
540 run_dump_test "iamcu-2"
541 run_dump_test "iamcu-3"
542 run_dump_test "iamcu-4"
543 run_dump_test "iamcu-5"
544 run_list_test "iamcu-inval-1" "-march=iamcu -al"
548 # This is a PE specific test.
549 if { [istarget "*-*-cygwin*"] || [istarget "*-*-pe"]
550 || [istarget "*-*-mingw*"]
552 run_dump_test "secrel"
555 # Miscellaneous tests.
556 run_dump_test "pr12589-1"
558 set ASFLAGS "$old_ASFLAGS"
562 if [expr [istarget "i*86-*-*"] || [istarget "x86_64-*-*"]] then {
563 if {![istarget "i*86-*-elfiamcu"] && [gas_64_check]} then {
564 run_dump_test "intel-expr"
565 run_dump_test "string-ok"
567 run_list_test "string-bad" ""
568 run_list_test "reg-bad" ""
569 run_list_test "space1" "-al"
570 run_list_test "xmmword" ""
572 run_dump_test pr19498
573 run_list_test "nop-bad-1" ""
574 run_list_test "unspec" ""
575 if [is_elf_format] then {
576 run_list_test_stdin "list-1" "-al"
577 run_list_test_stdin "list-2" "-al"
578 run_list_test_stdin "list-3" "-al"
579 run_dump_test "dw2-compress-1"
580 run_dump_test "dw2-compress-3a"
581 run_dump_test "dw2-compress-3b"
582 run_dump_test "dw2-compressed-1"
583 run_dump_test "dw2-compressed-3a"
584 run_dump_test "dw2-compressed-3b"
588 if [expr ([istarget "i*86-*-*"] || [istarget "x86_64-*-*"]) && [gas_64_check]] then {
591 set old_ASFLAGS "$ASFLAGS"
592 set ASFLAGS "$ASFLAGS --64 --defsym x86_64=1 --strip-local-absolute"
594 run_dump_test "x86_64"
595 run_dump_test "x86_64-intel"
596 run_dump_test "x86-64-addr32"
597 run_dump_test "x86-64-addr32-intel"
598 run_dump_test "x86-64-opcode"
599 run_dump_test "x86-64-intel64"
600 if { ! [istarget "*-*-*cygwin*"] && ![istarget "*-*-mingw*"] } then {
601 run_dump_test "x86-64-pcrel"
602 run_dump_test "x86-64-disassem"
604 run_dump_test "x86-64-w64-pcrel"
606 run_dump_test "x86-64-rip"
607 run_dump_test "x86-64-rip-intel"
608 run_dump_test "x86-64-stack"
609 run_dump_test "x86-64-stack-intel"
610 run_dump_test "x86-64-stack-suffix"
611 run_list_test "x86-64-inval" "-al"
612 run_list_test "x86-64-segment" "-al"
613 run_dump_test "x86-64-segovr"
614 run_list_test "x86-64-inval-seg" "-al"
615 run_dump_test "x86-64-branch"
616 run_dump_test "movz64"
617 run_dump_test "x86-64-relax-1"
618 run_dump_test "svme64"
619 run_dump_test "x86-64-amdfam10"
620 run_dump_test "x86-64-vmx"
621 run_dump_test "x86-64-vmfunc"
622 run_dump_test "immed64"
623 run_dump_test "x86-64-sse3"
624 run_dump_test "x86-64-crx"
625 run_dump_test "x86-64-crx-suffix"
626 run_dump_test "x86-64-drx"
627 run_dump_test "x86-64-drx-suffix"
628 run_dump_test "x86-64-cdr"
629 run_dump_test "x86-64-ssse3"
630 run_dump_test "x86-64-rep"
631 run_dump_test "x86-64-rep-suffix"
632 run_list_test "x86-64-inval-rep" "-al"
633 run_dump_test "x86-64-lock-1"
634 run_dump_test "x86-64-lock-1-intel"
635 run_list_test "x86-64-lockbad-1" "-al"
636 run_dump_test "x86-64-long-1"
637 run_dump_test "x86-64-long-1-intel"
638 run_dump_test "x86-64-cbw"
639 run_dump_test "x86-64-cbw-intel"
640 run_dump_test "x86-64-io"
641 run_dump_test "x86-64-io-intel"
642 run_dump_test "x86-64-io-suffix"
643 run_dump_test "x86-64-gidt"
644 run_dump_test "x86-64-nops"
645 run_dump_test "x86-64-nops-1"
646 run_dump_test "x86-64-nops-1-g64"
647 run_dump_test "x86-64-nops-1-k8"
648 run_dump_test "x86-64-nops-1-core2"
649 run_dump_test "x86-64-nops-1-pentium"
650 run_dump_test "x86-64-nops-2"
651 run_dump_test "x86-64-nops-3"
652 run_dump_test "x86-64-nops-4"
653 run_dump_test "x86-64-nops-4-core2"
654 run_dump_test "x86-64-nops-4-k8"
655 run_dump_test "x86-64-nops-5"
656 run_dump_test "x86-64-nops-5-k8"
657 run_dump_test "x86-64-nops-7"
658 run_list_test "cvtsi2sX"
659 run_dump_test "x86-64-sse4_1"
660 run_dump_test "x86-64-sse4_1-intel"
661 run_dump_test "x86-64-sse4_2"
662 run_dump_test "x86-64-sse4_2-intel"
663 run_dump_test "x86-64-crc32"
664 run_dump_test "x86-64-crc32-intel"
665 run_list_test "x86-64-inval-crc32" "-al"
666 run_dump_test "x86-64-simd"
667 run_dump_test "x86-64-simd-intel"
668 run_dump_test "x86-64-simd-suffix"
669 run_dump_test "x86-64-mem"
670 run_dump_test "x86-64-mem-intel"
671 run_dump_test "x86-64-reg"
672 run_list_test "x86-64-reg-bad" "-al"
673 run_dump_test "x86-64-reg-intel"
674 run_dump_test "x86-64-sib"
675 run_dump_test "x86-64-sib-intel"
676 run_dump_test "x86-64-disp"
677 run_dump_test "x86-64-disp-intel"
678 run_dump_test "intel-movs64"
679 run_dump_test "x86-64-disp32"
681 run_list_test "x86-64-specific-reg"
682 run_list_test "suffix-bad"
683 run_list_test "x86-64-suffix-bad"
684 run_list_test "unspec64" ""
685 run_dump_test "x86-64-fxsave"
686 run_dump_test "x86-64-fxsave-intel"
687 run_dump_test "x86-64-arch-1"
688 run_dump_test "x86-64-arch-2"
689 run_dump_test "x86-64-arch-3"
690 run_dump_test "x86-64-arch-2-lzcnt"
691 run_dump_test "x86-64-arch-2-prefetchw"
692 run_dump_test "x86-64-arch-2-bdver1"
693 run_dump_test "x86-64-arch-2-bdver2"
694 run_dump_test "x86-64-arch-2-bdver3"
695 run_dump_test "x86-64-arch-2-bdver4"
696 run_dump_test "x86-64-arch-3-znver1"
697 run_dump_test "x86-64-arch-3-znver2"
698 run_dump_test "x86-64-arch-2-btver1"
699 run_dump_test "x86-64-arch-2-btver2"
700 run_list_test "x86-64-arch-2-1" "-march=generic64 -I${srcdir}/$subdir -al"
701 run_list_test "x86-64-arch-2-2" "-march=generic64+cx16 -I${srcdir}/$subdir -al"
702 run_dump_test "xmmhi64"
703 run_dump_test "x86-64-xsave"
704 run_dump_test "x86-64-xsave-intel"
705 run_dump_test "x86-64-aes"
706 run_dump_test "x86-64-aes-intel"
707 run_dump_test "x86-64-clmul"
708 run_dump_test "x86-64-clmul-intel"
709 run_dump_test "x86-64-avx"
710 run_dump_test "x86-64-avx-intel"
711 run_dump_test "x86-64-avx-scalar"
712 run_dump_test "x86-64-avx-scalar-intel"
713 run_dump_test "x86-64-avx256int"
714 run_dump_test "x86-64-avx_gfni"
715 run_dump_test "x86-64-avx_gfni-intel"
716 run_dump_test "x86-64-avx256int-intel"
717 run_dump_test "x86-64-avx2"
718 run_dump_test "x86-64-avx2-intel"
719 run_dump_test "x86-64-avx-gather"
720 run_dump_test "x86-64-avx-gather-intel"
721 run_dump_test "x86-64-avx512f"
722 run_dump_test "x86-64-avx512f-intel"
723 run_dump_test "x86-64-avx512f-opts"
724 run_dump_test "x86-64-avx512f-opts-intel"
725 run_dump_test "x86-64-avx512f-nondef"
726 run_dump_test "x86-64-avx512cd"
727 run_dump_test "x86-64-avx512cd-intel"
728 run_dump_test "x86-64-avx512er"
729 run_dump_test "x86-64-avx512er-intel"
730 run_dump_test "x86-64-avx512pf"
731 run_dump_test "x86-64-avx512pf-intel"
732 run_dump_test "x86-64-evex-lig256"
733 run_dump_test "x86-64-evex-lig512"
734 run_dump_test "x86-64-evex-lig256-intel"
735 run_dump_test "x86-64-evex-lig512-intel"
736 run_dump_test "x86-64-evex-wig1"
737 run_dump_test "x86-64-evex-wig1-intel"
738 run_dump_test "evex-no-scale-64"
739 run_dump_test "x86-64-sse2avx"
740 run_list_test "x86-64-inval-avx" "-al"
741 run_list_test "x86-64-inval-avx512f" "-al"
742 run_dump_test "x86-64-sse-check"
743 run_dump_test "x86-64-sse-check-none"
744 run_dump_test "x86-64-sse-check-warn"
745 run_list_test "x86-64-sse-check-error" "-msse-check=error -I${srcdir}/$subdir -al"
746 run_dump_test "x86-64-vgather-check"
747 run_dump_test "x86-64-vgather-check-none"
748 run_dump_test "x86-64-vgather-check-warn"
749 run_list_test "x86-64-vgather-check-error" "-moperand-check=error -I${srcdir}/$subdir"
750 run_dump_test "x86-64-sse-noavx"
751 run_dump_test "x86-64-movbe"
752 run_dump_test "x86-64-movbe-intel"
753 run_list_test "x86-64-inval-movbe" "-al"
754 run_dump_test "x86-64-ept"
755 run_dump_test "x86-64-ept-intel"
756 run_list_test "x86-64-inval-ept" "-al"
757 run_dump_test "x86-64-invpcid"
758 run_dump_test "x86-64-invpcid-intel"
759 run_list_test "x86-64-inval-invpcid" "-al"
760 run_dump_test "x86-64-opts"
761 run_dump_test "x86-64-opts-intel"
762 run_dump_test "x86-64-sse2avx-opts"
763 run_dump_test "x86-64-sse2avx-opts-intel"
764 run_dump_test "x86-64-avx-swap"
765 run_dump_test "x86-64-avx-swap-intel"
766 run_dump_test "x86-64-bmi2"
767 run_dump_test "x86-64-bmi2-intel"
768 run_dump_test "x86-64-fma"
769 run_dump_test "x86-64-fma-intel"
770 run_dump_test "x86-64-fma-scalar"
771 run_dump_test "x86-64-fma-scalar-intel"
772 run_dump_test "x86-64-hle"
773 run_dump_test "x86-64-hle-intel"
774 run_list_test "x86-64-hlebad" "-al"
775 run_dump_test "x86-64-rtm"
776 run_dump_test "x86-64-rtm-intel"
777 run_dump_test "x86-64-fma4"
778 run_dump_test "x86-64-lwp"
779 run_dump_test "x86-64-xop"
780 run_dump_test "x86-64-bmi"
781 run_dump_test "x86-64-bmi-intel"
782 run_dump_test "x86-64-tbm"
783 run_dump_test "x86-64-tbm-intel"
784 run_dump_test "x86-64-f16c"
785 run_dump_test "x86-64-f16c-intel"
786 run_dump_test "x86-64-fsgs"
787 run_dump_test "x86-64-fsgs-intel"
788 run_dump_test "x86-64-rdrnd"
789 run_dump_test "x86-64-rdrnd-intel"
790 run_dump_test "x86-64-bundle"
791 run_dump_test "x86-64-adx"
792 run_dump_test "x86-64-adx-intel"
793 run_dump_test "x86-64-rdseed"
794 run_dump_test "x86-64-rdseed-intel"
795 run_dump_test "x86-64-prefetch"
796 run_dump_test "x86-64-prefetch-intel"
797 run_dump_test "x86-64-smap"
798 run_dump_test "x86-64-mpx"
799 run_list_test "x86-64-mpx-inval-1" "-al"
800 run_list_test "x86-64-mpx-inval-2" "-al"
801 run_dump_test "x86-64-mpx-addr32"
802 run_dump_test "x86-64-mpx-add-bnd-prefix"
803 run_dump_test "x86-64-sha"
804 run_dump_test "x86-64-clflushopt"
805 run_dump_test "x86-64-clflushopt-intel"
806 run_dump_test "x86-64-xsavec"
807 run_dump_test "x86-64-xsavec-intel"
808 run_dump_test "x86-64-xsaves"
809 run_dump_test "x86-64-xsaves-intel"
810 run_dump_test "x86-64-prefetchwt1"
811 run_dump_test "x86-64-prefetchwt1-intel"
812 run_dump_test "x86-64-se1"
813 run_dump_test "x86-64-equ"
814 run_dump_test "x86-64-avx512f_vl-intel"
815 run_dump_test "x86-64-avx512f_vl-opts-intel"
816 run_dump_test "x86-64-avx512f_vl-opts"
817 run_dump_test "x86-64-avx512f_vl-wig1-intel"
818 run_dump_test "x86-64-avx512f_vl-wig1"
819 run_dump_test "x86-64-avx512f_vl"
820 run_dump_test "x86-64-avx512cd_vl-intel"
821 run_dump_test "x86-64-avx512cd_vl"
822 run_dump_test "x86-64-avx512bw-intel"
823 run_dump_test "x86-64-avx512bw-opts-intel"
824 run_dump_test "x86-64-avx512bw-opts"
825 run_dump_test "x86-64-avx512bw-wig1-intel"
826 run_dump_test "x86-64-avx512bw-wig1"
827 run_dump_test "x86-64-avx512bw"
828 run_dump_test "x86-64-avx512bw_vl-intel"
829 run_dump_test "x86-64-avx512bw_vl-opts-intel"
830 run_dump_test "x86-64-avx512bw_vl-opts"
831 run_dump_test "x86-64-avx512bw_vl-wig1-intel"
832 run_dump_test "x86-64-avx512bw_vl-wig1"
833 run_dump_test "x86-64-avx512bw_vl"
834 run_dump_test "x86-64-avx512dq-intel"
835 run_dump_test "x86-64-avx512dq"
836 run_dump_test "x86-64-avx512dq_vl-intel"
837 run_dump_test "x86-64-avx512dq_vl"
838 run_dump_test "x86-64-suffix"
839 run_dump_test "x86-64-suffix-intel"
840 run_dump_test "x86-64-avx512dq-rcigrd-intel"
841 run_dump_test "x86-64-avx512dq-rcigrd"
842 run_dump_test "x86-64-avx512dq-rcigrne-intel"
843 run_dump_test "x86-64-avx512dq-rcigrne"
844 run_dump_test "x86-64-avx512dq-rcigru-intel"
845 run_dump_test "x86-64-avx512dq-rcigru"
846 run_dump_test "x86-64-avx512dq-rcigrz-intel"
847 run_dump_test "x86-64-avx512dq-rcigrz"
848 run_dump_test "x86-64-avx512er-rcigrd-intel"
849 run_dump_test "x86-64-avx512er-rcigrd"
850 run_dump_test "x86-64-avx512er-rcigrne-intel"
851 run_dump_test "x86-64-avx512er-rcigrne"
852 run_dump_test "x86-64-avx512er-rcigru-intel"
853 run_dump_test "x86-64-avx512er-rcigru"
854 run_dump_test "x86-64-avx512er-rcigrz-intel"
855 run_dump_test "x86-64-avx512er-rcigrz"
856 run_dump_test "x86-64-avx512f-rcigrd-intel"
857 run_dump_test "x86-64-avx512f-rcigrd"
858 run_dump_test "x86-64-avx512f-rcigrne-intel"
859 run_dump_test "x86-64-avx512f-rcigrne"
860 run_dump_test "x86-64-avx512f-rcigru-intel"
861 run_dump_test "x86-64-avx512f-rcigru"
862 run_dump_test "x86-64-avx512f-rcigrz-intel"
863 run_dump_test "x86-64-avx512f-rcigrz"
864 run_dump_test "x86-64-clwb"
865 run_dump_test "x86-64-clwb-intel"
866 run_dump_test "x86-64-avx512ifma"
867 run_dump_test "x86-64-avx512ifma-intel"
868 run_dump_test "x86-64-avx512ifma_vl"
869 run_dump_test "x86-64-avx512ifma_vl-intel"
870 run_dump_test "x86-64-avx512vbmi"
871 run_dump_test "x86-64-avx512vbmi-intel"
872 run_dump_test "x86-64-avx512vbmi_vl"
873 run_dump_test "x86-64-avx512vbmi_vl-intel"
874 run_dump_test "x86-64-avx512_4fmaps"
875 run_dump_test "x86-64-avx512_4fmaps-intel"
876 run_list_test "x86-64-avx512_4fmaps-warn"
877 run_dump_test "x86-64-avx512_4vnniw"
878 run_dump_test "x86-64-avx512_4vnniw-intel"
879 run_dump_test "x86-64-avx512_vpopcntdq"
880 run_dump_test "x86-64-avx512_vpopcntdq-intel"
881 run_dump_test "x86-64-avx512vbmi2"
882 run_dump_test "x86-64-avx512vbmi2-intel"
883 run_dump_test "x86-64-avx512vbmi2_vl"
884 run_dump_test "x86-64-avx512vbmi2_vl-intel"
885 run_dump_test "x86-64-avx512f_gfni"
886 run_dump_test "x86-64-avx512f_gfni-intel"
887 run_dump_test "x86-64-avx512vl_gfni"
888 run_dump_test "x86-64-avx512vl_gfni-intel"
889 run_dump_test "x86-64-avx512f_vaes"
890 run_dump_test "x86-64-avx512f_vaes-intel"
891 run_dump_test "x86-64-avx512f_vaes-wig1"
892 run_dump_test "x86-64-avx512f_vaes-wig1-intel"
893 run_dump_test "x86-64-avx512vl_vaes"
894 run_dump_test "x86-64-avx512vl_vaes-intel"
895 run_dump_test "x86-64-avx512vl_vaes-wig1"
896 run_dump_test "x86-64-avx512vl_vaes-wig1-intel"
897 run_dump_test "x86-64-avx512f_vpclmulqdq"
898 run_dump_test "x86-64-avx512f_vpclmulqdq-intel"
899 run_dump_test "x86-64-avx512f_vpclmulqdq-wig1"
900 run_dump_test "x86-64-avx512f_vpclmulqdq-wig1-intel"
901 run_dump_test "x86-64-avx512vl_vpclmulqdq"
902 run_dump_test "x86-64-avx512vl_vpclmulqdq-intel"
903 run_dump_test "x86-64-avx512vl_vpclmulqdq-wig1"
904 run_dump_test "x86-64-avx512vl_vpclmulqdq-wig1-intel"
905 run_dump_test "x86-64-avx512vnni"
906 run_dump_test "x86-64-avx512vnni-intel"
907 run_dump_test "x86-64-avx512vnni_vl"
908 run_dump_test "x86-64-avx512vnni_vl-intel"
909 run_dump_test "x86-64-avx512bitalg"
910 run_dump_test "x86-64-avx512bitalg-intel"
911 run_dump_test "x86-64-avx512bitalg_vl"
912 run_dump_test "x86-64-avx512bitalg_vl-intel"
913 run_dump_test "x86-64-clzero"
914 run_dump_test "x86-64-mwaitx-bdver4"
915 run_list_test "x86-64-mwaitx-reg"
916 run_dump_test "x86-64-ospke"
917 run_dump_test "x86-64-rdpid"
918 run_dump_test "x86-64-rdpid-intel"
919 run_dump_test "x86-64-ptwrite"
920 run_dump_test "x86-64-ptwrite-intel"
921 run_dump_test "x86-64-gfni"
922 run_dump_test "x86-64-gfni-intel"
923 run_dump_test "x86-64-vaes"
924 run_dump_test "x86-64-vaes-intel"
925 run_dump_test "x86-64-vpclmulqdq"
926 run_dump_test "x86-64-vpclmulqdq-intel"
927 run_dump_test "x86-64-wbnoinvd"
928 run_dump_test "x86-64-wbnoinvd-intel"
929 run_dump_test "x86-64-pconfig"
930 run_dump_test "x86-64-pconfig-intel"
931 run_dump_test "x86-64-waitpkg"
932 run_dump_test "x86-64-waitpkg-intel"
933 run_dump_test "x86-64-cldemote"
934 run_dump_test "x86-64-cldemote-intel"
935 run_dump_test "x86-64-movdir"
936 run_dump_test "x86-64-movdir-intel"
937 run_list_test "x86-64-movdir64b-reg"
938 run_dump_test "x86-64-fence-as-lock-add-yes"
939 run_dump_test "x86-64-fence-as-lock-add-no"
940 run_dump_test "x86-64-pr20141"
941 run_list_test "x86-64-avx512vl-1" "-al"
942 run_list_test "x86-64-avx512vl-2" "-al"
943 run_dump_test "x86-64-opcode-bad"
944 run_dump_test "x86-64-cet"
945 run_dump_test "x86-64-cet-intel"
946 run_list_test "x86-64-cet-ibt-inval"
947 run_list_test "x86-64-cet-shstk-inval"
948 run_dump_test "x86-64-pseudos"
949 run_dump_test "x86-64-notrack"
950 run_dump_test "x86-64-notrack-intel"
951 run_list_test "x86-64-notrackbad" "-al"
952 run_dump_test "x86-64-movd"
953 run_dump_test "x86-64-movd-intel"
954 run_dump_test "x86-64-nop-1"
955 run_dump_test "x86-64-nop-2"
956 run_dump_test "x86-64-optimize-1"
957 run_dump_test "x86-64-optimize-2"
958 run_dump_test "x86-64-optimize-3"
959 run_dump_test "x86-64-optimize-4"
960 run_dump_test "x86-64-optimize-5"
961 run_dump_test "x86-64-optimize-6"
963 if { ![istarget "*-*-aix*"]
964 && ![istarget "*-*-beos*"]
965 && ![istarget "*-*-*bsd*"]
966 && ![istarget "*-*-chaos*"]
967 && ![istarget "*-*-kaos*"]
968 && ![istarget "*-*-lynx*"]
969 && ![istarget "*-*-moss*"]
970 && ![istarget "*-*-nto-qnx*"]
971 && ![istarget "*-*-rtems*"]
972 && ![istarget "*-*-sco*"]
973 && ![istarget "*-*-solaris*"]
974 && ![istarget "*-*-sysv*"] } then {
979 if [is_elf_format] then {
980 # Verify that @unwind works.
981 run_dump_test "x86-64-unwind"
983 run_dump_test "reloc64"
984 run_list_test "reloc64" "--defsym _bad_=1"
985 run_dump_test "mixed-mode-reloc64"
986 run_dump_test "x86-64-ifunc"
987 run_dump_test "x86-64-opcode-inval"
988 run_dump_test "x86-64-opcode-inval-intel"
989 run_dump_test "intel-got64"
992 run_dump_test "x86-64-localpic"
993 run_dump_test "debug1"
994 run_dump_test "x86-64-mpx-branch-1"
995 run_dump_test "x86-64-mpx-branch-2"
997 run_dump_test "x86-64-dw2-compress-2"
998 run_dump_test "x86-64-dw2-compressed-2"
1000 run_dump_test "x86-64-size-1"
1001 run_dump_test "x86-64-size-2"
1002 run_dump_test "x86-64-size-3"
1003 run_dump_test "x86-64-size-4"
1004 run_dump_test "x86-64-size-5"
1005 run_list_test "x86-64-size-inval-1" "-al"
1007 run_dump_test "x86-64-relax-2"
1008 run_dump_test "x86-64-relax-3"
1010 run_dump_test "x86-64-jump"
1011 run_dump_test "x86-64-branch-2"
1012 run_list_test "x86-64-branch-3" "-al -mintel64"
1013 run_list_test "x86-64-branch-4" "-al -mintel64"
1015 run_dump_test "x86-64-gotpcrel"
1016 run_dump_test "x86-64-gotpcrel-no-relax"
1018 run_dump_test "x86-64-addend"
1019 run_dump_test "x86-64-nop-3"
1020 run_dump_test "x86-64-nop-4"
1021 run_dump_test "x86-64-nop-5"
1022 run_dump_test "x86-64-nop-6"
1025 set ASFLAGS "$old_ASFLAGS"