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