public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* [PATCH 06/20] MIPS/GAS: Remove useless trailing 0 from NOP requests
@ 2010-12-02 19:18 Maciej W. Rozycki
  0 siblings, 0 replies; only message in thread
From: Maciej W. Rozycki @ 2010-12-02 19:18 UTC (permalink / raw)
  To: Richard Sandiford; +Cc: Catherine Moore, binutils

Hi,

 In a couple of places throughout macro(), there is an unnecessary 
trailing 0 argument included in variadic macro_build() calls made to 
request a NOP instruction.  As an empty operand format specifier string is 
used no further arguments are processed by that function.

2010-12-02  Maciej W. Rozycki  <macro@codesourcery.com>

	gas/
	* config/tc-mips.c (macro): Remove a trailing 0 from NOP
	requests.

 OK to apply?

  Maciej

binutils-gas-mips-nop.diff
Index: binutils-fsf-trunk-quilt/gas/config/tc-mips.c
===================================================================
--- binutils-fsf-trunk-quilt.orig/gas/config/tc-mips.c	2010-12-01 21:05:50.000000000 +0000
+++ binutils-fsf-trunk-quilt/gas/config/tc-mips.c	2010-12-01 21:05:50.000000000 +0000
@@ -4854,7 +4854,7 @@ macro (struct mips_cl_insn *ip)
       expr1.X_add_number = 8;
       macro_build (&expr1, "bgez", "s,p", sreg);
       if (dreg == sreg)
-	macro_build (NULL, "nop", "", 0);
+	macro_build (NULL, "nop", "");
       else
 	move_register (dreg, sreg);
       macro_build (NULL, dbl ? "dsub" : "sub", "d,v,t", dreg, 0, sreg);
@@ -5005,7 +5005,7 @@ macro (struct mips_cl_insn *ip)
 	do_false:
 	  /* Result is always false.  */
 	  if (! likely)
-	    macro_build (NULL, "nop", "", 0);
+	    macro_build (NULL, "nop", "");
 	  else
 	    macro_build (&offset_expr, "bnel", "s,t,p", ZERO, ZERO);
 	  break;
@@ -5421,7 +5421,7 @@ macro (struct mips_cl_insn *ip)
 	{
 	  expr1.X_add_number = 8;
 	  macro_build (&expr1, "bne", "s,t,p", sreg, AT);
-	  macro_build (NULL, "nop", "", 0);
+	  macro_build (NULL, "nop", "");
 
 	  /* We want to close the noreorder block as soon as possible, so
 	     that later insns are available for delay slot filling.  */
@@ -7450,7 +7450,7 @@ macro (struct mips_cl_insn *ip)
 	{
 	  expr1.X_add_number = 8;
 	  macro_build (&expr1, "beq", "s,t,p", dreg, AT);
-	  macro_build (NULL, "nop", "", 0);
+	  macro_build (NULL, "nop", "");
 	  macro_build (NULL, "break", "c", 6);
 	}
       end_noreorder ();
@@ -7481,7 +7481,7 @@ macro (struct mips_cl_insn *ip)
 	{
 	  expr1.X_add_number = 8;
 	  macro_build (&expr1, "beq", "s,t,p", AT, ZERO);
-	  macro_build (NULL, "nop", "", 0);
+	  macro_build (NULL, "nop", "");
 	  macro_build (NULL, "break", "c", 6);
 	}
       end_noreorder ();

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2010-12-02 19:18 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-12-02 19:18 [PATCH 06/20] MIPS/GAS: Remove useless trailing 0 from NOP requests Maciej W. Rozycki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).