public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
From: "Chen, Kenneth W" <kenneth.w.chen@intel.com>
To: linux-ia64@vger.kernel.org
Subject: [Linux-ia64] ia64 objdump bug for brl instruction
Date: Thu, 21 Nov 2002 19:20:28 +0000	[thread overview]
Message-ID: <marc-linux-ia64-105590709805467@msgid-missing> (raw)

We found a bug in ia64 objdump that brl instruction was decoded incorrectly.  The issue is that the mid 39 bit for the long immediate was incorrectly positioned and resulting in incorrect target branch address for branch long instruction.  This bug is on ia64 only.  The following patch fixes the issue. (note, it also fixes a spelling error as well :-).

- Ken

--- opcodes/ia64-dis.c.orig	Tue Mar 13 14:58:35 2001
+++ opcodes/ia64-dis.c	Thu Nov 21 11:16:43 2002
@@ -167,10 +167,10 @@
         }
       else if (odesc - elf64_ia64_operands == IA64_OPND_TGT64)
 	{
-	  /* 60-bit immedate for long branches.  */
+	  /* 60-bit immediate for long branches. */
 	  value = (((insn >> 13) & 0xfffff)
 		   | (((insn >> 36) & 1) << 59)
-		   | (slot[1] << 20)) << 4;
+		   | (((slot[1] >> 2) & 0x7fffffffffLL) << 20)) << 4;
 	}
       else
 	{



             reply	other threads:[~2002-11-21 19:20 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-11-21 19:20 Chen, Kenneth W [this message]
2002-11-25 20:00 ` [Linux-ia64] ia64 objdump bug for brl instruction Jim Wilson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=marc-linux-ia64-105590709805467@msgid-missing \
    --to=kenneth.w.chen@intel.com \
    --cc=linux-ia64@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox