From 0067be51e9436c5bbd961a4f54c10dbd50c491ea Mon Sep 17 00:00:00 2001 From: Alan Modra Date: Sat, 11 May 2019 09:42:00 +0930 Subject: [PATCH] PowerPC objdump -Mraw * ppc-dis.c (print_insn_powerpc) Don't skip optional operands when -Mraw is in effect. --- opcodes/ChangeLog | 5 +++++ opcodes/ppc-dis.c | 8 +++++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog index 331932cb397..aa78ea96d5a 100644 --- a/opcodes/ChangeLog +++ b/opcodes/ChangeLog @@ -1,3 +1,8 @@ +2019-05-11 Alan Modra + + * ppc-dis.c (print_insn_powerpc) Don't skip optional operands + when -Mraw is in effect. + 2019-05-09 Matthew Malcomson * aarch64-dis-2.c: Regenerate. diff --git a/opcodes/ppc-dis.c b/opcodes/ppc-dis.c index d9ae42a3d08..e9e3b3621a7 100644 --- a/opcodes/ppc-dis.c +++ b/opcodes/ppc-dis.c @@ -749,9 +749,11 @@ print_insn_powerpc (bfd_vma memaddr, operand = powerpc_operands + *opindex; - /* If all of the optional operands have the value zero, - then don't print any of them. */ - if ((operand->flags & PPC_OPERAND_OPTIONAL) != 0) + /* If all of the optional operands past this one have their + default value, then don't print any of them. Except in + raw mode, print them all. */ + if ((operand->flags & PPC_OPERAND_OPTIONAL) != 0 + && (dialect & PPC_OPCODE_RAW) == 0) { if (!skip_optional) skip_optional = skip_optional_operands (opindex, insn, dialect); -- 2.30.2