From 6f20c942c3dbc08d02f74e4d508e19f8617bc5e3 Mon Sep 17 00:00:00 2001 From: Faraz Shahbazker Date: Thu, 14 Jun 2018 21:34:49 +0100 Subject: MIPS: Add Global INValidate ASE support Add support for the Global INValidate Application Specific Extension for Release 6 of the MIPS Architecture. [1] "MIPS Architecture for Programmers Volume II-A: The MIPS32 Instruction Set Manual", Imagination Technologies Ltd., Document Number: MD00086, Revision 6.06, December 15, 2016, Section 3.2 "Alphabetical List of Instructions", pp. 187-191 bfd/ * elfxx-mips.c (print_mips_ases): Add GINV extension. binutils/ * readelf.c (print_mips_ases): Add GINV extension. gas/ * NEWS: Mention MIPS Global INValidate ASE support. * config/tc-mips.c (options): Add OPTION_GINV and OPTION_NO_GINV. (md_longopts): Likewise. (mips_ases): Define availability for GINV. (mips_convert_ase_flags): Map ASE_GINV to AFL_ASE_GINV. (md_show_usage): Add help for -mginv and -mno-ginv. * doc/as.texinfo: Document -mginv, -mno-ginv. * doc/c-mips.texi: Document -mginv, -mno-ginv, .set ginv and .set noginv. * testsuite/gas/mips/ase-errors-1.s: Add error checks for GINV ASE. * testsuite/gas/mips/ase-errors-2.s: Likewise. * testsuite/gas/mips/ase-errors-1.l: Likewise. * testsuite/gas/mips/ase-errors-2.l: Likewise. * testsuite/gas/mips/ginv.d: New test. * testsuite/gas/mips/ginv-err.d: New test. * testsuite/gas/mips/ginv-err.l: New test stderr output. * testsuite/gas/mips/ginv.s: New test source. * testsuite/gas/mips/ginv-err.s: New test source. * testsuite/gas/mips/mips.exp: Run the new tests. include/ * elf/mips.h (AFL_ASE_GINV, AFL_ASE_RESERVED1): New macros. (AFL_ASE_MASK): Update to include AFL_ASE_GINV. * opcode/mips.h: Document "+\" operand format. (ASE_GINV): New macro. opcodes/ * mips-dis.c (mips_arch_choices): Add GINV to mips32r6 and mips64r6 descriptors. (parse_mips_ase_option): Handle -Mginv option. (print_mips_disassembler_options): Document -Mginv. * mips-opc.c (decode_mips_operand) <+\>: New operand format. (GINV): New macro. (mips_opcodes): Define ginvi and ginvt. --- gas/doc/as.texinfo | 7 +++++++ gas/doc/c-mips.texi | 13 +++++++++++++ 2 files changed, 20 insertions(+) (limited to 'gas/doc') diff --git a/gas/doc/as.texinfo b/gas/doc/as.texinfo index 1c40a1e..493049c 100644 --- a/gas/doc/as.texinfo +++ b/gas/doc/as.texinfo @@ -423,6 +423,7 @@ gcc(1), ld(1), and the Info entries for @file{binutils} and @file{ld}. [@b{-mmt}] [@b{-mno-mt}] [@b{-mmcu}] [@b{-mno-mcu}] [@b{-mcrc}] [@b{-mno-crc}] + [@b{-mginv}] [@b{-mno-ginv}] [@b{-minsn32}] [@b{-mno-insn32}] [@b{-mfix7000}] [@b{-mno-fix7000}] [@b{-mfix-rm7000}] [@b{-mno-fix-rm7000}] @@ -1519,6 +1520,12 @@ Generate code for the MIPS cyclic redundancy check (CRC) Application Specific Extension. This tells the assembler to accept CRC instructions. @samp{-mno-crc} turns off this option. +@item -mginv +@itemx -mno-ginv +Generate code for the Global INValidate (GINV) Application Specific +Extension. This tells the assembler to accept GINV instructions. +@samp{-mno-ginv} turns off this option. + @item -minsn32 @itemx -mno-insn32 Only use 32-bit instruction encodings when generating code for the diff --git a/gas/doc/c-mips.texi b/gas/doc/c-mips.texi index 36997e9..9cbfaf2 100644 --- a/gas/doc/c-mips.texi +++ b/gas/doc/c-mips.texi @@ -240,6 +240,12 @@ Generate code for the cyclic redundancy check (CRC) Application Specific Extension. This tells the assembler to accept CRC instructions. @samp{-mno-crc} turns off this option. +@item -mginv +@itemx -mno-ginv +Generate code for the Global INValidate (GINV) Application Specific +Extension. This tells the assembler to accept GINV instructions. +@samp{-mno-ginv} turns off this option. + @item -minsn32 @itemx -mno-insn32 Only use 32-bit instruction encodings when generating code for the @@ -1124,6 +1130,13 @@ The directive @code{.set crc} makes the assembler accept instructions from the CRC Extension from that point on in the assembly. The @code{.set nocrc} directive prevents CRC instructions from being accepted. +@cindex MIPS Global INValidate (GINV) instruction generation override +@kindex @code{.set ginv} +@kindex @code{.set noginv} +The directive @code{.set ginv} makes the assembler accept instructions +from the GINV Extension from that point on in the assembly. The +@code{.set noginv} directive prevents GINV instructions from being accepted. + Traditional MIPS assemblers do not support these directives. @node MIPS Floating-Point -- cgit v1.1