aboutsummaryrefslogtreecommitdiff
path: root/target/hppa
diff options
context:
space:
mode:
authorRichard Henderson <richard.henderson@linaro.org>2023-09-16 22:25:30 -0700
committerRichard Henderson <richard.henderson@linaro.org>2023-11-06 18:49:34 -0800
commitf25d316098dd52ac74adf9416713cfe68c72f66e (patch)
treeef782a20876efc2c3ef871adc04738d0750d5ede /target/hppa
parentc65c3ee16b6e5382a93e3ed28fccf2fa545794e8 (diff)
downloadqemu-f25d316098dd52ac74adf9416713cfe68c72f66e.zip
qemu-f25d316098dd52ac74adf9416713cfe68c72f66e.tar.gz
qemu-f25d316098dd52ac74adf9416713cfe68c72f66e.tar.bz2
target/hppa: Decode ADDB double-word
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'target/hppa')
-rw-r--r--target/hppa/translate.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/target/hppa/translate.c b/target/hppa/translate.c
index 7f767fe..1b4fa40 100644
--- a/target/hppa/translate.c
+++ b/target/hppa/translate.c
@@ -3143,6 +3143,17 @@ static bool do_addb(DisasContext *ctx, unsigned r, TCGv_reg in1,
DisasCond cond;
bool d = false;
+ /*
+ * For hppa64, the ADDB conditions change with PSW.W,
+ * dropping ZNV, SV, OD in favor of double-word EQ, LT, LE.
+ */
+ if (ctx->tb_flags & PSW_W) {
+ d = c >= 5;
+ if (d) {
+ c &= 3;
+ }
+ }
+
in2 = load_gpr(ctx, r);
dest = tcg_temp_new();
sv = NULL;