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]

Re: [PATCH] Update mtfsf and mtfsfi instructions to support new optional operands.


On Fri, May 18, 2007 at 10:37:48AM +0930, Alan Modra wrote:
> This appears to have introduced some gas testsuite failures.
> 
> FAIL: PowerPC test 2
> FAIL: BookE tests
> 
> Please fix.

Never mind, I'll fix it since the bug is trival to correct.

	* ppc-dis.c (print_insn_powerpc): Don't skip all operands
        after setting skip_optional.

Index: opcodes/ppc-dis.c
===================================================================
RCS file: /cvs/src/src/opcodes/ppc-dis.c,v
retrieving revision 1.27
diff -u -p -r1.27 ppc-dis.c
--- opcodes/ppc-dis.c	17 May 2007 00:52:14 -0000	1.27
+++ opcodes/ppc-dis.c	18 May 2007 01:27:47 -0000
@@ -271,12 +271,14 @@ print_insn_powerpc (bfd_vma memaddr,
 
 	  /* If all of the optional operands have the value zero,
 	     then don't print any of them.  */
-	  if (skip_optional < 0
-	      && (operand->flags & PPC_OPERAND_OPTIONAL) != 0)
-	    skip_optional = skip_optional_operands (opindex, insn, dialect);
-
-	  if (skip_optional > 0)
-	    continue;
+	  if ((operand->flags & PPC_OPERAND_OPTIONAL) != 0)
+	    {
+	      if (skip_optional < 0)
+		skip_optional = skip_optional_operands (opindex, insn,
+							dialect);
+	      if (skip_optional)
+		continue;
+	    }
 
 	  value = operand_value_powerpc (operand, insn, dialect);
 
-- 
Alan Modra
IBM OzLabs - Linux Technology Centre


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