Hexagon: add PC alignment check and exception
authorMatheus Tavares Bernardino <quic_mathbern@quicinc.com>
Fri, 3 May 2024 16:53:15 +0000 (13:53 -0300)
committerBrian Cain <bcain@quicinc.com>
Sun, 9 Jun 2024 00:48:50 +0000 (17:48 -0700)
commite1b526f1d86b7c51b97227989b9ba2925cc53069
tree2eca193f6709a5e6f894fbe1483e45fb0f1c76b5
parenta1852002c7509569eaaedb783925f34350fe0a84
Hexagon: add PC alignment check and exception

The Hexagon Programmer's Reference Manual says that the exception 0x1e
should be raised upon an unaligned program counter. Let's implement that
and also add some tests.

Signed-off-by: Matheus Tavares Bernardino <quic_mathbern@quicinc.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Taylor Simpson <ltaylorsimpson@gmail.com>
Reviewed-by: Brian Cain <bcain@quicinc.com>
Message-Id: <277b7aeda2c717a96d4dde936b3ac77707cb6517.1714755107.git.quic_mathbern@quicinc.com>
Signed-off-by: Brian Cain <bcain@quicinc.com>
linux-user/hexagon/cpu_loop.c
target/hexagon/cpu.h
target/hexagon/cpu_bits.h
target/hexagon/macros.h
target/hexagon/op_helper.c
tests/tcg/hexagon/Makefile.target
tests/tcg/hexagon/unaligned_pc.c [new file with mode: 0644]