* [PATCH] Fix value_in_comment in print_insn_thumb32
@ 2017-04-30 16:03 Bernd Edlinger
0 siblings, 0 replies; only message in thread
From: Bernd Edlinger @ 2017-04-30 16:03 UTC (permalink / raw)
To: binutils; +Cc: Nick Clifton
[-- Attachment #1: Type: text/plain, Size: 437 bytes --]
Hi,
this was changed by commit db7b55faa1a11e632ddf57505c9bb64bc783471a
but in the wrong way, and this patch corrects it.
Originally value_in_comment was "off * 4 * U ? 1 : -1" and IMHO
the intention was to compute "off * 4 * (U ? 1 : -1)".
opcodes/
2017-04-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
* arm-dis.c (print_insn_thumb32): Fix value_in_comment.
could someone commit this for me?
Thanks
Bernd.
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: opcodes-arm-dis.diff --]
[-- Type: text/x-patch; name="opcodes-arm-dis.diff", Size: 774 bytes --]
diff --git a/opcodes/arm-dis.c b/opcodes/arm-dis.c
index a3e53db..a0a03ee 100644
--- a/opcodes/arm-dis.c
+++ b/opcodes/arm-dis.c
@@ -5733,7 +5733,7 @@ print_insn_thumb32 (bfd_vma pc, struct disassemble_info *info, long given)
if (off || !U)
{
func (stream, ", #%c%u", U ? '+' : '-', off * 4);
- value_in_comment = (off && U) ? 1 : -1;
+ value_in_comment = off * 4 * (U ? 1 : -1);
}
func (stream, "]");
if (W)
@@ -5745,7 +5745,7 @@ print_insn_thumb32 (bfd_vma pc, struct disassemble_info *info, long given)
if (W)
{
func (stream, "#%c%u", U ? '+' : '-', off * 4);
- value_in_comment = (off && U) ? 1 : -1;
+ value_in_comment = off * 4 * (U ? 1 : -1);
}
else
{
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2017-04-30 16:03 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-04-30 16:03 [PATCH] Fix value_in_comment in print_insn_thumb32 Bernd Edlinger
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).