[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v9 18/24] target/arm: Rebuild hflags at CPSR writes
From: |
Richard Henderson |
Subject: |
[PATCH v9 18/24] target/arm: Rebuild hflags at CPSR writes |
Date: |
Wed, 23 Oct 2019 11:00:51 -0400 |
Continue setting, but not relying upon, env->hflags.
Reviewed-by: Alex Bennée <address@hidden>
Signed-off-by: Richard Henderson <address@hidden>
---
target/arm/op_helper.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/target/arm/op_helper.c b/target/arm/op_helper.c
index ccc2cecb46..b529d6c1bf 100644
--- a/target/arm/op_helper.c
+++ b/target/arm/op_helper.c
@@ -224,6 +224,7 @@ uint32_t HELPER(usat16)(CPUARMState *env, uint32_t x,
uint32_t shift)
void HELPER(setend)(CPUARMState *env)
{
env->uncached_cpsr ^= CPSR_E;
+ arm_rebuild_hflags(env);
}
/* Function checks whether WFx (WFI/WFE) instructions are set up to be trapped.
@@ -387,6 +388,8 @@ uint32_t HELPER(cpsr_read)(CPUARMState *env)
void HELPER(cpsr_write)(CPUARMState *env, uint32_t val, uint32_t mask)
{
cpsr_write(env, val, mask, CPSRWriteByInstr);
+ /* TODO: Not all cpsr bits are relevant to hflags. */
+ arm_rebuild_hflags(env);
}
/* Write the CPSR for a 32-bit exception return */
--
2.17.1
- [PATCH v9 04/24] target/arm: Split arm_cpu_data_is_big_endian, (continued)
- [PATCH v9 04/24] target/arm: Split arm_cpu_data_is_big_endian, Richard Henderson, 2019/10/23
- [PATCH v9 13/24] target/arm: Split out arm_mmu_idx_el, Richard Henderson, 2019/10/23
- [PATCH v9 07/24] target/arm: Split out rebuild_hflags_a32, Richard Henderson, 2019/10/23
- [PATCH v9 22/24] linux-user/aarch64: Rebuild hflags for TARGET_WORDS_BIGENDIAN, Richard Henderson, 2019/10/23
- [PATCH v9 09/24] target/arm: Hoist XSCALE_CPAR, VECLEN, VECSTRIDE in cpu_get_tb_cpu_state, Richard Henderson, 2019/10/23
- [PATCH v9 17/24] target/arm: Rebuild hflags at MSR writes, Richard Henderson, 2019/10/23
- [PATCH v9 12/24] target/arm: Add arm_rebuild_hflags, Richard Henderson, 2019/10/23
- [PATCH v9 19/24] target/arm: Rebuild hflags at Xscale SCTLR writes, Richard Henderson, 2019/10/23
- [PATCH v9 14/24] target/arm: Hoist store to cs_base in cpu_get_tb_cpu_state, Richard Henderson, 2019/10/23
- [PATCH v9 05/24] target/arm: Split out rebuild_hflags_m32, Richard Henderson, 2019/10/23
- [PATCH v9 18/24] target/arm: Rebuild hflags at CPSR writes,
Richard Henderson <=
- [PATCH v9 10/24] target/arm: Simplify set of PSTATE_SS in cpu_get_tb_cpu_state, Richard Henderson, 2019/10/23
- [PATCH v9 23/24] linux-user/arm: Rebuild hflags for TARGET_WORDS_BIGENDIAN, Richard Henderson, 2019/10/23
- [PATCH v9 15/24] target/arm: Add HELPER(rebuild_hflags_{a32, a64, m32}), Richard Henderson, 2019/10/23
- [PATCH v9 02/24] target/arm: Split out rebuild_hflags_a64, Richard Henderson, 2019/10/23
- [PATCH v9 08/24] target/arm: Split out rebuild_hflags_aprofile, Richard Henderson, 2019/10/23
- [PATCH v9 01/24] target/arm: Split out rebuild_hflags_common, Richard Henderson, 2019/10/23
- [PATCH v9 21/24] target/arm: Rebuild hflags for M-profile NVIC, Richard Henderson, 2019/10/23
- [PATCH v9 24/24] target/arm: Rely on hflags correct in cpu_get_tb_cpu_state, Richard Henderson, 2019/10/23
- [PATCH v9 16/24] target/arm: Rebuild hflags at EL changes, Richard Henderson, 2019/10/23
- [PATCH v9 20/24] target/arm: Rebuild hflags for M-profile, Richard Henderson, 2019/10/23