This is the mail archive of the binutils-cvs@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]

[binutils-gdb/binutils-2_30-branch] Remove unnecessary power9 group terminating nop


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=10d2f8bcf800b24d495e48c7c53bfb908376e759

commit 10d2f8bcf800b24d495e48c7c53bfb908376e759
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Mar 8 10:17:41 2018 +1030

    Remove unnecessary power9 group terminating nop
    
    Power9 doesn't have a group terminating nop, so we may as well emit a
    normal nop for power9.  Not that it matters a great deal, I believe
    ori 2,2,0 will be treated exactly as ori 0,0,0 by the hardware.
    
    	* config/tc-ppc.c (ppc_handle_align): Don't emit a group
    	terminating nop for power9.
    
    (cherry picked from commit 3fea0c3b3fe53ea805f1289ec9ff5e785024362f)

Diff:
---
 gas/ChangeLog       |  7 +++++++
 gas/config/tc-ppc.c | 18 ++++++++----------
 2 files changed, 15 insertions(+), 10 deletions(-)

diff --git a/gas/ChangeLog b/gas/ChangeLog
index 16660ac..2210d16 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,10 @@
+2018-03-21  Alan Modra  <amodra@gmail.com>
+
+	Apply from master
+	2018-03-08  Alan Modra  <amodra@gmail.com>
+	* config/tc-ppc.c (ppc_handle_align): Don't emit a group
+	terminating nop for power9.
+
 2018-02-28  Nick Clifton  <nickc@redhat.com>
 
 	* po/ru.po: Updated Russian translation.
diff --git a/gas/config/tc-ppc.c b/gas/config/tc-ppc.c
index 35da05c..dbd0295 100644
--- a/gas/config/tc-ppc.c
+++ b/gas/config/tc-ppc.c
@@ -6556,14 +6556,13 @@ ppc_handle_align (struct frag *fragP)
 
       if ((ppc_cpu & PPC_OPCODE_POWER6) != 0
 	  || (ppc_cpu & PPC_OPCODE_POWER7) != 0
-	  || (ppc_cpu & PPC_OPCODE_POWER8) != 0
-	  || (ppc_cpu & PPC_OPCODE_POWER9) != 0)
+	  || (ppc_cpu & PPC_OPCODE_POWER8) != 0)
 	{
-	  /* For power6, power7, power8 and power9, we want the last nop to be
-	     a group terminating one.  Do this by inserting an rs_fill frag
-	     immediately after this one, with its address set to the last nop
-	     location.  This will automatically reduce the number of nops in
-	     the current frag by one.  */
+	  /* For power6, power7, and power8, we want the last nop to
+	     be a group terminating one.  Do this by inserting an
+	     rs_fill frag immediately after this one, with its address
+	     set to the last nop location.  This will automatically
+	     reduce the number of nops in the current frag by one.  */
 	  if (count > 4)
 	    {
 	      struct frag *group_nop = xmalloc (SIZEOF_STRUCT_FRAG + 4);
@@ -6578,14 +6577,13 @@ ppc_handle_align (struct frag *fragP)
 	    }
 
 	  if ((ppc_cpu & PPC_OPCODE_POWER7) != 0
-	      || (ppc_cpu & PPC_OPCODE_POWER8) != 0
-	      || (ppc_cpu & PPC_OPCODE_POWER9) != 0)
+	      || (ppc_cpu & PPC_OPCODE_POWER8) != 0)
 	    {
 	      if (ppc_cpu & PPC_OPCODE_E500MC)
 		/* e500mc group terminating nop: "ori 0,0,0".  */
 		md_number_to_chars (dest, 0x60000000, 4);
 	      else
-		/* power7/power8/power9 group terminating nop: "ori 2,2,0".  */
+		/* power7/power8 group terminating nop: "ori 2,2,0".  */
 		md_number_to_chars (dest, 0x60420000, 4);
 	    }
 	  else


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