Skip to content

Commit da86f38

Browse files
committed
Fix compiler error with JIT when Zicsr is disabled
When using 'make ENABLE_Zicsr=0 ENABLE_JIT=1', the following error is observed: src/jit.c:1760:17: error: ‘do_csrrwi’ defined but not used [-Werror=unused-function] 1760 | static void do_##inst(struct jit_state *state UNUSED, riscv_t *rv UNUSED, \ | ^~~ src/rv32_jit.c:363:1: note: in expansion of macro ‘GEN’ 363 | GEN(csrrwi, {assert(NULL); | ^~~ This ensures csrrwi instructions are properly excluded from JIT code generation when the Zicsr extension is disabled.
1 parent 9a9ad89 commit da86f38

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/gen-jit-template.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
"csrrw",
1616
"csrrs",
1717
"csrrc",
18-
"csrrw",
18+
"csrrwi",
1919
"csrrsi",
2020
"csrrci"],
2121
"EXT_M": [

0 commit comments

Comments
 (0)