Skip to content

Commit 4291e4e

Browse files
committed
Fix compiler error when enabling JIT
When using make 'ENABLE_JIT=1', the following error is observed: src/jit.c:1760:17: error: ‘do_sret’ defined but not used [-Werror=unused-function] 1760 | static void do_##inst(struct jit_state *state UNUSED, riscv_t *rv UNUSED, \ | ^~~ Add "SYSTEM" to the EXT_LIST, which cause SERT to be add SKIP_LIST during template generation. The prevents the generatoin of unused JIT code for the SERT instruction. Fixes: fc0d878 ("Preliminary support for trap handling during block emulation")
1 parent 206100f commit 4291e4e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tools/gen-jit-template.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,9 @@
101101
"cflw",
102102
"cfsw",
103103
],
104+
"SYSTEM": ["sret"],
104105
}
105-
EXT_LIST = ["Zifencei", "Zicsr", "EXT_M", "EXT_A", "EXT_F", "EXT_C"]
106+
EXT_LIST = ["Zifencei", "Zicsr", "EXT_M", "EXT_A", "EXT_F", "EXT_C", "SYSTEM"]
106107
SKIP_LIST = []
107108
# check enabled extension in Makefile
108109

0 commit comments

Comments
 (0)