From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Mosberger Date: Wed, 28 Nov 2001 18:25:58 +0000 Subject: Re: [Linux-ia64] unaligned access? Message-Id: List-Id: References: In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-ia64@vger.kernel.org >>>>> On Wed, 28 Nov 2001 09:37:51 -0800, "Pereira, D LailaX E" said: >> HI While running the following code, define >> WRITE_CAUSED_SIGBUS_or_SEGV \ (((*(unsigned >> long*)scp->sc_ip)>>21)&1) .... if (WRITE_CAUSED_SIGBUS_or_SEGV){ >> ........ } else { ......... } >> I get the following error on the "if " statement: >> stress.udp(31438): unaligned access to >> 0x4000000000003541,ip=0x4000000000015fc1 Please let me know what >> is wrong with the macro: define WRITE_CAUSED_SIGBUS_or_SEGV \ >> (((*(unsigned long*)scp->sc_ip)>>21)&1) The least significant two bits of sc_ip encode the slot number. You need to take those bits into account when reading an instruction from a bundle. --david