binutils-gdb/gdb/arch
Luis Machado 5382f97180 Fix shifting of negative value
When UBSan is enabled, I noticed runtime errors complaining of shifting
of negative numbers.

This patch fixes this by reusing existing macros from the ARM port.

It also removes unused macros from AArch64's port.

gdb/ChangeLog:

2020-12-04  Luis Machado  <luis.machado@linaro.org>

	* aarch64-tdep.c (submask, bit, bits): Remove.
	* arch/aarch64-insn.c (extract_signed_bitfield): Remove.
	(aarch64_decode_adr, aarch64_decode_b aarch64_decode_bcond)
	(aarch64_decode_cb, aarch64_decode_tb)
	(aarch64_decode_ldr_literal): Use sbits to extract a signed
	immediate.
	* arch/aarch64-insn.h (submask, bits, bit, sbits): New macros.
2020-12-04 11:17:00 -03:00
..
aarch32.c
aarch32.h
aarch64-insn.c Fix shifting of negative value 2020-12-04 11:17:00 -03:00
aarch64-insn.h Fix shifting of negative value 2020-12-04 11:17:00 -03:00
aarch64.c
aarch64.h
amd64.c
amd64.h
arc.c
arc.h
arm-get-next-pcs.c
arm-get-next-pcs.h
arm-linux.c
arm-linux.h
arm.c
arm.h
i386.c
i386.h
ppc-linux-common.c
ppc-linux-common.h
ppc-linux-tdesc.h
riscv.c
riscv.h
tic6x.c
tic6x.h
xtensa.h