binutils-gdb/gas/testsuite/gas/s390/s390.exp
Dominik Vogt 7ecc513a44 Add support for extensions in the .machine pseudoop on S/390, e.g. ".machine zEC12+nohtm+vx"
gas	* doc/c-s390.texi: Add documentation.
	Add missing code markup.
	* config/tc-s390.c (current_flags): New static variable.
	(s390_parse_cpu): Parse cpu flags a la "+nohtm" etc.
	(s390_setup_opcodes): Use cpu flags to determine the set of opcodes.
	Fix indentation.
	(md_parse_option): Call s390_parse_cpu with the new signature.
	(s390_machine): Likewise.
	Keep track of current_flags.
	Simplify code a bit.
	undefine MAX_HISTORY at end of function.
	(s390_machinemode): undefine MAX_HISTORY at end of function.
	Update an error message.

tests	* gas/s390/s390.exp: Add new tests.
	* gas/s390/machine-parsing-1.s: New test file.
	* gas/s390/machine-parsing-1.l: Likewise.
	* gas/s390/machine-parsing-2.s: Likewise.
	* gas/s390/machine-parsing-2.l: Likewise.
	* gas/s390/machine-parsing-3.s: Likewise.
	* gas/s390/machine-parsing-3.l: Likewise.
	* gas/s390/machine-parsing-4.s: Likewise.
	* gas/s390/machine-parsing-4.l: Likewise.
	* gas/s390/machine-parsing-5.s: Likewise.
	* gas/s390/machine-parsing-5.l: Likewise.
	* gas/s390/machine-parsing-6.s: Likewise.
	* gas/s390/machine-parsing-6.l: Likewise.

opcode	* s390.h (S390_INSTR_FLAG_HTM): New flag.
	(S390_INSTR_FLAG_VX): New flag.
	(S390_INSTR_FLAG_FACILITY_MASK): New flag mask.

opcodes	* s390-mkopc.c (main): Parse htm and vx flag.
	* s390-opc.txt: Mark instructions from the hardware transactional
	memory and vector facilities with the "htm"/"vx" flag.
2015-09-29 13:22:07 +01:00

40 lines
1.6 KiB
Text

#
# s390/s390x tests
#
if [expr [istarget "s390-*-*"] || [istarget "s390x-*-*"]] then {
# s390x-ibm-tpf target does not support a 32-bit target.
if { ! [istarget "s390x-*-tpf*"] } then {
run_dump_test "esa-g5" "{as -m31}"
run_dump_test "esa-z900" "{as -m31} {as -march=z900}"
run_dump_test "esa-z990" "{as -m31} {as -march=z990}"
run_dump_test "esa-z9-109" "{as -m31} {as -march=z9-109}"
run_dump_test "esa-reloc" "{as -m31}"
run_dump_test "esa-operands" "{as -m31}"
}
# # PIC is only supported on ELF targets.
# if { ([istarget "*-*-elf*"] || [istarget "*-*-linux*"] ) } then {
# run_dump_test "s390pic"
# }
run_dump_test "zarch-z900" "{as -m64}"
run_dump_test "zarch-z990" "{as -m64} {as -march=z990}"
run_dump_test "zarch-z9-109" "{as -m64} {as -march=z9-109}"
run_list_test "zarch-z9-109-err" "-march=z9-109"
run_dump_test "zarch-z9-ec" "{as -m64} {as -march=z9-ec}"
run_dump_test "zarch-z10" "{as -m64} {as -march=z10}"
run_dump_test "zarch-z196" "{as -m64} {as -march=z196}"
run_dump_test "zarch-zEC12" "{as -m64} {as -march=zEC12}"
run_dump_test "zarch-z13" "{as -m64} {as -march=z13}"
run_dump_test "zarch-reloc" "{as -m64}"
run_dump_test "zarch-operands" "{as -m64} {as -march=z9-109}"
run_dump_test "zarch-machine" "{as -m64} {as -march=z900}"
run_list_test "machine-parsing-1" ""
run_list_test "machine-parsing-2" ""
run_list_test "machine-parsing-3" ""
run_list_test "machine-parsing-4" ""
run_list_test "machine-parsing-5" ""
run_list_test "machine-parsing-6" ""
}