This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[committed] Add argumentless MIPS16 ENTRY and EXIT entries


The MIPS16 "l" and "L" operand types are the only ones that can be empty[*].
These formats are used for the ENTRY and EXIT pseudo instructions,
which TBH I doubt anyone uses any more anyway.

It makes the rewrite easier if every operand needs to be nonempty,
so this patch adds separate argumentless entries for ENTRY and EXIT.
This also means that the disassembly output doesn't have trailing
whitespace in that case.

[*] The register list for MIPS16 SAVE and RESTORE can be empty,
    but there still needs to be a frame size.

Applied.

Richard


opcodes/
	* mips16-opc.c: Add entries for argumentless "entry" and "exit"
	instructions.

gas/testsuite/
	* gas/mips/mips16.d, gas/mips/mips16-64.d: Remove trailing whitespace
	from ENTRY and EXIT lines.

Index: opcodes/mips16-opc.c
===================================================================
--- opcodes/mips16-opc.c	2013-07-07 10:50:13.261280228 +0100
+++ opcodes/mips16-opc.c	2013-07-07 11:16:11.486983400 +0100
@@ -159,7 +159,9 @@ const struct mips_opcode mips16_opcodes[
 {"dsubu",   "y,j",	0, (int) M_DSUBU_I_2, INSN_MACRO, 0,	I1 },
 {"exit",    "L",	0xed09, 0xff1f, TRAP,		0,	I1 },
 {"exit",    "L",	0xee09, 0xff1f, TRAP,		0,	I1 },
+{"exit",    "",		0xef09, 0xffff, TRAP,		0,	I1 },
 {"exit",    "L",	0xef09, 0xff1f, TRAP,		0,	I1 },
+{"entry",   "",		0xe809, 0xffff, TRAP,		0,	I1 },
 {"entry",   "l",	0xe809, 0xf81f, TRAP,		0,	I1 },
 {"extend",  "e",	0xf000, 0xf800, 0,		0,	I1 },
 {"jalr",    "x",	0xe840, 0xf8ff, UBD|WR_31|RD_x,	0,	I1 },
Index: gas/testsuite/gas/mips/mips16.d
===================================================================
--- gas/testsuite/gas/mips/mips16.d	2013-07-07 10:31:50.990197797 +0100
+++ gas/testsuite/gas/mips/mips16.d	2013-07-07 11:16:11.488983417 +0100
@@ -667,12 +667,12 @@ Disassembly of section .text:
  84c:	1800 0000 	jal	0 <data1>
 			84c: R_MIPS16_26	extern
  850:	6500      	nop
- 852:	e809      	entry	
+ 852:	e809      	entry
  854:	e909      	entry	a0
  856:	eb49      	entry	a0-a2,s0
  858:	e8a9      	entry	s0-s1,ra
  85a:	e829      	entry	ra
- 85c:	ef09      	exit	
+ 85c:	ef09      	exit
  85e:	ef49      	exit	s0
  860:	efa9      	exit	s0-s1,ra
  862:	ef29      	exit	ra
Index: gas/testsuite/gas/mips/mips16-64.d
===================================================================
--- gas/testsuite/gas/mips/mips16-64.d	2013-07-07 10:31:50.990197797 +0100
+++ gas/testsuite/gas/mips/mips16-64.d	2013-07-07 11:16:11.487983408 +0100
@@ -670,12 +670,12 @@ Disassembly of section .text:
 			84c: R_MIPS_NONE	\*ABS\*
 			84c: R_MIPS_NONE	\*ABS\*
  850:	6500      	nop
- 852:	e809      	entry	
+ 852:	e809      	entry
  854:	e909      	entry	a0
  856:	eb49      	entry	a0-a2,s0
  858:	e8a9      	entry	s0-s1,ra
  85a:	e829      	entry	ra
- 85c:	ef09      	exit	
+ 85c:	ef09      	exit
  85e:	ef49      	exit	s0
  860:	efa9      	exit	s0-s1,ra
  862:	ef29      	exit	ra


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]