From c5384ad8645299543c53290aa548704dd08fc4a3 Mon Sep 17 00:00:00 2001 From: ChinYikMing Date: Sat, 2 Nov 2024 20:23:19 +0800 Subject: [PATCH] Fix block_map_clear undefined when JIT=1 --- src/emulate.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/emulate.c b/src/emulate.c index 21a9d1f9..bfe06e1d 100644 --- a/src/emulate.c +++ b/src/emulate.c @@ -190,12 +190,14 @@ static uint32_t csr_csrrw(riscv_t *rv, uint32_t csr, uint32_t val) *c = val; +#if !RV32_HAS(JIT) /* * guestOS's process might have same VA, * so block_map cannot be reused */ if (c == &rv->csr_satp) block_map_clear(rv); +#endif return out; }