[v2,4/5] opcodes/loongarch: do not print hex notation for signed immediates

Message ID 20221207133155.3052074-5-i.swmail@xen0n.name
State Accepted
Headers
Series LoongArch: colored disassembly and readability tweaks |

Checks

Context Check Description
snail/binutils-gdb-check success Github commit url

Commit Message

WANG Xuerui Dec. 7, 2022, 1:31 p.m. UTC
  From: WANG Xuerui <git@xen0n.name>

---
 opcodes/loongarch-dis.c | 8 +-------
 1 file changed, 1 insertion(+), 7 deletions(-)
  

Patch

diff --git a/opcodes/loongarch-dis.c b/opcodes/loongarch-dis.c
index 7ee18e14dd2..164069b2ede 100644
--- a/opcodes/loongarch-dis.c
+++ b/opcodes/loongarch-dis.c
@@ -177,13 +177,7 @@  dis_one_arg (char esc1, char esc2, const char *bit_field,
 	  style = dis_style_immediate;
 	  break;
 	}
-      if (imm == 0)
-	info->fprintf_styled_func (info->stream, style, "%d", imm);
-      else
-	{
-	  info->fprintf_styled_func (info->stream, style, "%d", imm);
-	  info->fprintf_styled_func (info->stream, dis_style_text, "(0x%x)", u_imm);
-	}
+      info->fprintf_styled_func (info->stream, style, "%d", imm);
       switch (esc2)
 	{
 	case 'b':