summaryrefslogtreecommitdiff
path: root/opcodes/ppc-dis.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@bigpond.net.au>2004-03-16 00:58:43 +0000
committerAlan Modra <amodra@bigpond.net.au>2004-03-16 00:58:43 +0000
commitfdadb443022cc4eb0f643de85710d030624e2cfd (patch)
tree8f1eb9d5c2602008268aa8b98e02db72ce2e2366 /opcodes/ppc-dis.c
parente2f179b8a5facb05d4f8a6e9801dce7dec97e590 (diff)
downloadbinutils-redhat-fdadb443022cc4eb0f643de85710d030624e2cfd.tar.gz
opcodes/
* ppc-dis.c (print_insn_powerpc): Don't print tabs. Handle PPC_OPERANDS_GPR_0. * ppc-opc.c (RA0): Define. (RAQ, RAL, RAM, RAS, RSQ, RTQ, RSO): Use PPC_OPERAND_GPR_0. (RAOPT): Rename from RAO. Update all uses. (powerpc_opcodes): Use RA0 as appropriate. Add "lsdx", "lsdi", "stsdx", "stsdi", "lmd" and "stmd" insns. include/opcode/ * ppc.h (PPC_OPERAND_GPR_0): Define. Bump other operand defines. gas/testsuite/ Update gas/ppc/. ld/testsuite/ Update ld-powerpc/.
Diffstat (limited to 'opcodes/ppc-dis.c')
-rw-r--r--opcodes/ppc-dis.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/opcodes/ppc-dis.c b/opcodes/ppc-dis.c
index 76af4e7af1..4d48b9d4b7 100644
--- a/opcodes/ppc-dis.c
+++ b/opcodes/ppc-dis.c
@@ -1,5 +1,5 @@
/* ppc-dis.c -- Disassemble PowerPC instructions
- Copyright 1994, 1995, 2000, 2001, 2002, 2003
+ Copyright 1994, 1995, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support
@@ -191,9 +191,10 @@ print_insn_powerpc (bfd_vma memaddr,
continue;
/* The instruction is valid. */
- (*info->fprintf_func) (info->stream, "%s", opcode->name);
if (opcode->operands[0] != 0)
- (*info->fprintf_func) (info->stream, "\t");
+ (*info->fprintf_func) (info->stream, "%-7s ", opcode->name);
+ else
+ (*info->fprintf_func) (info->stream, "%s", opcode->name);
/* Now extract and print the operands. */
need_comma = 0;
@@ -235,7 +236,8 @@ print_insn_powerpc (bfd_vma memaddr,
}
/* Print the operand as directed by the flags. */
- if ((operand->flags & PPC_OPERAND_GPR) != 0)
+ if ((operand->flags & PPC_OPERAND_GPR) != 0
+ || ((operand->flags & PPC_OPERAND_GPR_0) != 0 && value != 0))
(*info->fprintf_func) (info->stream, "r%ld", value);
else if ((operand->flags & PPC_OPERAND_FPR) != 0)
(*info->fprintf_func) (info->stream, "f%ld", value);