Skip to content

Commit 2163a76

Browse files
committed
Fix block_map_clear undefined when JIT=1
1 parent 459cf5c commit 2163a76

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/emulate.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,12 +190,14 @@ static uint32_t csr_csrrw(riscv_t *rv, uint32_t csr, uint32_t val)
190190

191191
*c = val;
192192

193+
#if !RV32_HAS(JIT)
193194
/*
194195
* guestOS's process might have same VA,
195196
* so block_map cannot be reused
196197
*/
197198
if (c == &rv->csr_satp)
198199
block_map_clear(rv);
200+
#endif
199201

200202
return out;
201203
}

0 commit comments

Comments
 (0)