]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
opcodes: microblaze: Fix bit masking bug
authorNeal Frager <neal.frager@amd.com>
Thu, 19 Oct 2023 11:37:40 +0000 (12:37 +0100)
committerMichael J. Eager <eager@eagercon.com>
Fri, 20 Oct 2023 00:59:06 +0000 (17:59 -0700)
commit2d1777b530d7832db5d8d7017378354c28816554
treeafb934c520d01495eef0b82641f0c7d47d089ed9
parent4781e165dc9e8b8f3c0ba40825c620e88e6ae103
opcodes: microblaze: Fix bit masking bug

There is currently a bug in the bit masking for the barrel shift
instructions because the bit mask is not including all of the
register bits which must be zero.  With this patch, the disassembler
can be sure that the 32-bit value is indeed a barrel shift instruction
and not a data value in memory.

This fix can be verified by assembling and disassembling the following:

.text
.long 0x65005f5f

With this patch, the bug is fixed, and the objdump will know that
0x65005f5f is not a barrel shift instruction.

Signed-off-by: Neal Frager <neal.frager@amd.com>
Signed-off-by: Michael J. Eager <eager@eagercon.com>
gas/testsuite/gas/microblaze/allinsn.d
opcodes/microblaze-dis.c
opcodes/microblaze-opc.h