diff --git a/src/Makefile.dep b/src/Makefile.dep index 5d1238f6..89ac79e8 100644 --- a/src/Makefile.dep +++ b/src/Makefile.dep @@ -1,6 +1,6 @@ buildvm.o: buildvm.c buildvm.h lj_def.h lua.h luaconf.h lj_arch.h \ - lj_obj.h lj_gc.h lj_bc.h lj_ir.h lj_frame.h lj_dispatch.h lj_jit.h \ - lj_ccall.h luajit.h \ + lj_obj.h lj_gc.h lj_bc.h lj_ir.h lj_ircall.h lj_jit.h lj_frame.h \ + lj_dispatch.h lj_ccall.h luajit.h \ lj_traceerr.h buildvm_asm.o: buildvm_asm.c buildvm.h lj_def.h lua.h luaconf.h lj_arch.h \ lj_bc.h @@ -31,8 +31,8 @@ lib_io.o: lib_io.c lua.h luaconf.h lauxlib.h lualib.h lj_obj.h lj_def.h \ lj_libdef.h lib_jit.o: lib_jit.c lua.h luaconf.h lauxlib.h lualib.h lj_arch.h \ lj_obj.h lj_def.h lj_err.h lj_errmsg.h lj_str.h lj_tab.h lj_bc.h lj_ir.h \ - lj_jit.h lj_iropt.h lj_target.h lj_target_*.h lj_dispatch.h lj_vm.h \ - lj_vmevent.h lj_lib.h luajit.h lj_libdef.h + lj_jit.h lj_ircall.h lj_iropt.h lj_target.h lj_target_*.h \ + lj_dispatch.h lj_vm.h lj_vmevent.h lj_lib.h luajit.h lj_libdef.h lib_math.o: lib_math.c lua.h luaconf.h lauxlib.h lualib.h lj_obj.h \ lj_def.h lj_arch.h lj_lib.h lj_libdef.h lib_os.o: lib_os.c lua.h luaconf.h lauxlib.h lualib.h lj_obj.h lj_def.h \ @@ -52,8 +52,9 @@ lj_api.o: lj_api.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h lj_gc.h \ lj_traceerr.h lj_vm.h lj_lex.h lj_parse.h lj_asm.o: lj_asm.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h lj_gc.h \ lj_str.h lj_tab.h lj_frame.h lj_bc.h lj_ctype.h lj_ir.h lj_jit.h \ - lj_iropt.h lj_mcode.h lj_trace.h lj_dispatch.h lj_traceerr.h lj_snap.h \ - lj_asm.h lj_vm.h lj_target.h lj_target_*.h lj_emit_*.h lj_asm_*.h + lj_ircall.h lj_iropt.h lj_mcode.h lj_trace.h lj_dispatch.h lj_traceerr.h \ + lj_snap.h lj_asm.h lj_vm.h lj_target.h lj_target_*.h lj_emit_*.h \ + lj_asm_*.h lj_bc.o: lj_bc.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h lj_bc.h \ lj_bcdef.h lj_carith.o: lj_carith.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \ @@ -77,9 +78,9 @@ lj_cparse.o: lj_cparse.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \ lj_bc.h lj_vm.h lj_char.h lj_crecord.o: lj_crecord.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \ lj_err.h lj_errmsg.h lj_str.h lj_tab.h lj_frame.h lj_bc.h lj_ctype.h \ - lj_gc.h lj_cparse.h lj_cconv.h lj_clib.h lj_ir.h lj_jit.h lj_iropt.h \ - lj_trace.h lj_dispatch.h lj_traceerr.h lj_record.h lj_ffrecord.h \ - lj_crecord.h + lj_gc.h lj_cparse.h lj_cconv.h lj_clib.h lj_ir.h lj_jit.h lj_ircall.h \ + lj_iropt.h lj_trace.h lj_dispatch.h lj_traceerr.h lj_record.h \ + lj_ffrecord.h lj_crecord.h lj_ctype.o: lj_ctype.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \ lj_gc.h lj_err.h lj_errmsg.h lj_str.h lj_tab.h lj_ctype.h lj_dispatch.o: lj_dispatch.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \ @@ -91,8 +92,9 @@ lj_err.o: lj_err.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h lj_err.h \ lj_traceerr.h lj_vm.h lj_ffrecord.o: lj_ffrecord.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \ lj_err.h lj_errmsg.h lj_str.h lj_tab.h lj_frame.h lj_bc.h lj_ff.h \ - lj_ffdef.h lj_ir.h lj_jit.h lj_iropt.h lj_trace.h lj_dispatch.h \ - lj_traceerr.h lj_record.h lj_ffrecord.h lj_crecord.h lj_vm.h lj_recdef.h + lj_ffdef.h lj_ir.h lj_jit.h lj_ircall.h lj_iropt.h lj_trace.h \ + lj_dispatch.h lj_traceerr.h lj_record.h lj_ffrecord.h lj_crecord.h \ + lj_vm.h lj_recdef.h lj_func.o: lj_func.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h lj_gc.h \ lj_func.h lj_trace.h lj_jit.h lj_ir.h lj_dispatch.h lj_bc.h \ lj_traceerr.h lj_vm.h @@ -104,8 +106,9 @@ lj_gdbjit.o: lj_gdbjit.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \ lj_gc.h lj_err.h lj_errmsg.h lj_frame.h lj_bc.h lj_jit.h lj_ir.h \ lj_dispatch.h lj_ir.o: lj_ir.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h lj_gc.h \ - lj_str.h lj_tab.h lj_ir.h lj_jit.h lj_iropt.h lj_trace.h lj_dispatch.h \ - lj_bc.h lj_traceerr.h lj_ctype.h lj_cdata.h lj_carith.h lj_lib.h + lj_str.h lj_tab.h lj_ir.h lj_jit.h lj_ircall.h lj_iropt.h lj_trace.h \ + lj_dispatch.h lj_bc.h lj_traceerr.h lj_ctype.h lj_cdata.h lj_carith.h \ + lj_lib.h lj_lex.o: lj_lex.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h lj_gc.h \ lj_err.h lj_errmsg.h lj_str.h lj_tab.h lj_ctype.h lj_cdata.h lualib.h \ lj_state.h lj_lex.h lj_parse.h lj_char.h @@ -133,15 +136,15 @@ lj_opt_narrow.o: lj_opt_narrow.c lj_obj.h lua.h luaconf.h lj_def.h \ lj_arch.h lj_str.h lj_bc.h lj_ir.h lj_jit.h lj_iropt.h lj_trace.h \ lj_dispatch.h lj_traceerr.h lj_vm.h lj_opt_split.o: lj_opt_split.c lj_obj.h lua.h luaconf.h lj_def.h \ - lj_arch.h lj_err.h lj_errmsg.h lj_str.h lj_ir.h lj_jit.h lj_iropt.h \ - lj_vm.h + lj_arch.h lj_err.h lj_errmsg.h lj_str.h lj_ir.h lj_jit.h lj_ircall.h \ + lj_iropt.h lj_vm.h lj_parse.o: lj_parse.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \ lj_gc.h lj_err.h lj_errmsg.h lj_str.h lj_tab.h lj_func.h lj_state.h \ lj_bc.h lj_ctype.h lj_lex.h lj_parse.h lj_vm.h lj_vmevent.h lj_record.o: lj_record.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h \ lj_err.h lj_errmsg.h lj_str.h lj_tab.h lj_meta.h lj_frame.h lj_bc.h \ - lj_ff.h lj_ffdef.h lj_ir.h lj_jit.h lj_iropt.h lj_trace.h lj_dispatch.h \ - lj_traceerr.h lj_record.h lj_ffrecord.h lj_snap.h lj_vm.h + lj_ff.h lj_ffdef.h lj_ir.h lj_jit.h lj_ircall.h lj_iropt.h lj_trace.h \ + lj_dispatch.h lj_traceerr.h lj_record.h lj_ffrecord.h lj_snap.h lj_vm.h lj_snap.o: lj_snap.c lj_obj.h lua.h luaconf.h lj_def.h lj_arch.h lj_gc.h \ lj_state.h lj_frame.h lj_bc.h lj_ir.h lj_jit.h lj_iropt.h lj_trace.h \ lj_dispatch.h lj_traceerr.h lj_snap.h lj_target.h lj_target_*.h @@ -172,13 +175,13 @@ ljamalg.o: ljamalg.c lua.h luaconf.h lauxlib.h lj_gc.c lj_obj.h lj_def.h \ lj_alloc.h lj_dispatch.c luajit.h lj_vmevent.c lj_vmevent.h lj_api.c \ lj_parse.h lj_lex.c lualib.h lj_parse.c lj_ctype.c lj_cdata.c lj_cconv.h \ lj_cconv.c lj_ccall.c lj_ccall.h lj_carith.c lj_carith.h lj_clib.c \ - lj_clib.h lj_cparse.c lj_cparse.h lj_lib.c lj_lib.h lj_ir.c lj_iropt.h \ - lj_opt_mem.c lj_opt_fold.c lj_folddef.h lj_opt_narrow.c lj_opt_dce.c \ - lj_opt_loop.c lj_snap.h lj_opt_split.c lj_mcode.c lj_mcode.h lj_snap.c \ - lj_target.h lj_target_*.h lj_record.c lj_record.h lj_ffrecord.h \ - lj_crecord.c lj_crecord.h lj_ffrecord.c lj_recdef.h lj_asm.c lj_asm.h \ - lj_emit_*.h lj_asm_*.h lj_trace.c lj_gdbjit.h lj_gdbjit.c lj_alloc.c \ - lib_aux.c lib_base.c lj_libdef.h lib_math.c lib_string.c lib_table.c \ - lib_io.c lib_os.c lib_package.c lib_debug.c lib_bit.c lib_jit.c \ - lib_ffi.c lib_init.c + lj_clib.h lj_cparse.c lj_cparse.h lj_lib.c lj_lib.h lj_ir.c lj_ircall.h \ + lj_iropt.h lj_opt_mem.c lj_opt_fold.c lj_folddef.h lj_opt_narrow.c \ + lj_opt_dce.c lj_opt_loop.c lj_snap.h lj_opt_split.c lj_mcode.c \ + lj_mcode.h lj_snap.c lj_target.h lj_target_*.h lj_record.c lj_record.h \ + lj_ffrecord.h lj_crecord.c lj_crecord.h lj_ffrecord.c lj_recdef.h \ + lj_asm.c lj_asm.h lj_emit_*.h lj_asm_*.h lj_trace.c lj_gdbjit.h \ + lj_gdbjit.c lj_alloc.c lib_aux.c lib_base.c lj_libdef.h lib_math.c \ + lib_string.c lib_table.c lib_io.c lib_os.c lib_package.c lib_debug.c \ + lib_bit.c lib_jit.c lib_ffi.c lib_init.c luajit.o: luajit.c lua.h luaconf.h lauxlib.h lualib.h luajit.h lj_arch.h diff --git a/src/buildvm.c b/src/buildvm.c index 3a99c834..33f87a4b 100644 --- a/src/buildvm.c +++ b/src/buildvm.c @@ -19,6 +19,7 @@ #include "lj_gc.h" #include "lj_bc.h" #include "lj_ir.h" +#include "lj_ircall.h" #include "lj_frame.h" #include "lj_dispatch.h" #if LJ_HASFFI diff --git a/src/lib_jit.c b/src/lib_jit.c index 57837e1f..259a03e1 100644 --- a/src/lib_jit.c +++ b/src/lib_jit.c @@ -19,6 +19,7 @@ #if LJ_HASJIT #include "lj_ir.h" #include "lj_jit.h" +#include "lj_ircall.h" #include "lj_iropt.h" #include "lj_target.h" #endif diff --git a/src/lj_asm.c b/src/lj_asm.c index e2c14872..78f2484a 100644 --- a/src/lj_asm.c +++ b/src/lj_asm.c @@ -19,6 +19,7 @@ #endif #include "lj_ir.h" #include "lj_jit.h" +#include "lj_ircall.h" #include "lj_iropt.h" #include "lj_mcode.h" #include "lj_iropt.h" diff --git a/src/lj_crecord.c b/src/lj_crecord.c index 0b73f440..02e788aa 100644 --- a/src/lj_crecord.c +++ b/src/lj_crecord.c @@ -20,6 +20,7 @@ #include "lj_clib.h" #include "lj_ir.h" #include "lj_jit.h" +#include "lj_ircall.h" #include "lj_iropt.h" #include "lj_trace.h" #include "lj_record.h" diff --git a/src/lj_ffrecord.c b/src/lj_ffrecord.c index a3d18ff9..91d31b29 100644 --- a/src/lj_ffrecord.c +++ b/src/lj_ffrecord.c @@ -18,6 +18,7 @@ #include "lj_ff.h" #include "lj_ir.h" #include "lj_jit.h" +#include "lj_ircall.h" #include "lj_iropt.h" #include "lj_trace.h" #include "lj_record.h" diff --git a/src/lj_ir.c b/src/lj_ir.c index 94fe44b1..b7d1e7a7 100644 --- a/src/lj_ir.c +++ b/src/lj_ir.c @@ -19,6 +19,7 @@ #include "lj_tab.h" #include "lj_ir.h" #include "lj_jit.h" +#include "lj_ircall.h" #include "lj_iropt.h" #include "lj_trace.h" #if LJ_HASFFI diff --git a/src/lj_ir.h b/src/lj_ir.h index 5659ba73..1bc6c332 100644 --- a/src/lj_ir.h +++ b/src/lj_ir.h @@ -234,91 +234,6 @@ IRFLDEF(FLENUM) #define IRCONV_INDEX (2<flags & 0xff) /* Extract # of args. */ -#define CCI_NARGS_MAX 32 /* Max. # of args. */ - -#define CCI_OTSHIFT 16 -#define CCI_OPTYPE(ci) ((ci)->flags >> CCI_OTSHIFT) /* Get op/type. */ -#define CCI_OPSHIFT 24 -#define CCI_OP(ci) ((ci)->flags >> CCI_OPSHIFT) /* Get op. */ - -#define CCI_CALL_N (IR_CALLN << CCI_OPSHIFT) -#define CCI_CALL_L (IR_CALLL << CCI_OPSHIFT) -#define CCI_CALL_S (IR_CALLS << CCI_OPSHIFT) -#define CCI_CALL_FN (CCI_CALL_N|CCI_FASTCALL) -#define CCI_CALL_FL (CCI_CALL_L|CCI_FASTCALL) -#define CCI_CALL_FS (CCI_CALL_S|CCI_FASTCALL) - -/* C call info flags. */ -#define CCI_L 0x0100 /* Implicit L arg. */ -#define CCI_CASTU64 0x0200 /* Cast u64 result to number. */ -#define CCI_NOFPRCLOBBER 0x0400 /* Does not clobber any FPRs. */ -#define CCI_FASTCALL 0x0800 /* Fastcall convention. */ - -/* Function definitions for CALL* instructions. */ -#if LJ_HASFFI -#if LJ_32 -#define ARG2_64 4 /* Treat as 4 32 bit arguments. */ -#define IRCALLDEF_FFI32(_) \ - _(lj_carith_mul64, ARG2_64, N, I64, CCI_NOFPRCLOBBER) -#else -#define ARG2_64 2 -#define IRCALLDEF_FFI32(_) -#endif -#define IRCALLDEF_FFI(_) \ - IRCALLDEF_FFI32(_) \ - _(lj_carith_divi64, ARG2_64, N, I64, CCI_NOFPRCLOBBER) \ - _(lj_carith_divu64, ARG2_64, N, U64, CCI_NOFPRCLOBBER) \ - _(lj_carith_modi64, ARG2_64, N, I64, CCI_NOFPRCLOBBER) \ - _(lj_carith_modu64, ARG2_64, N, U64, CCI_NOFPRCLOBBER) \ - _(lj_carith_powi64, ARG2_64, N, I64, CCI_NOFPRCLOBBER) \ - _(lj_carith_powu64, ARG2_64, N, U64, CCI_NOFPRCLOBBER) \ - _(lj_cdata_setfin, 2, FN, P32, CCI_L) \ - _(strlen, 1, N, INTP, 0) \ - _(memcpy, 3, S, PTR, 0) \ - _(memset, 3, S, PTR, 0) -#else -#define IRCALLDEF_FFI(_) -#endif -#define IRCALLDEF(_) \ - _(lj_str_cmp, 2, FN, INT, CCI_NOFPRCLOBBER) \ - _(lj_str_new, 3, S, STR, CCI_L) \ - _(lj_str_tonum, 2, FN, INT, 0) \ - _(lj_str_fromint, 2, FN, STR, CCI_L) \ - _(lj_str_fromnum, 2, FN, STR, CCI_L) \ - _(lj_tab_new1, 2, FS, TAB, CCI_L) \ - _(lj_tab_dup, 2, FS, TAB, CCI_L) \ - _(lj_tab_newkey, 3, S, P32, CCI_L) \ - _(lj_tab_len, 1, FL, INT, 0) \ - _(lj_gc_step_jit, 2, FS, NIL, CCI_L) \ - _(lj_gc_barrieruv, 2, FS, NIL, 0) \ - _(lj_mem_newgco, 2, FS, P32, CCI_L) \ - _(lj_math_random_step, 1, FS, NUM, CCI_CASTU64|CCI_NOFPRCLOBBER) \ - IRCALLDEF_FFI(_) \ - _(sinh, 1, N, NUM, 0) \ - _(cosh, 1, N, NUM, 0) \ - _(tanh, 1, N, NUM, 0) \ - _(fputc, 2, S, INT, 0) \ - _(fwrite, 4, S, INT, 0) \ - _(fflush, 1, S, INT, 0) \ - \ - /* End of list. */ - -typedef enum { -#define IRCALLENUM(name, nargs, kind, type, flags) IRCALL_##name, -IRCALLDEF(IRCALLENUM) -#undef IRCALLENUM - IRCALL__MAX -} IRCallID; - -LJ_DATA const CCallInfo lj_ir_callinfo[IRCALL__MAX+1]; - /* -- IR operands --------------------------------------------------------- */ /* IR operand mode (2 bit). */ diff --git a/src/lj_ircall.h b/src/lj_ircall.h new file mode 100644 index 00000000..3131b15d --- /dev/null +++ b/src/lj_ircall.h @@ -0,0 +1,100 @@ +/* +** IR CALL* instruction definitions. +** Copyright (C) 2005-2011 Mike Pall. See Copyright Notice in luajit.h +*/ + +#ifndef _LJ_IRCALL_H +#define _LJ_IRCALL_H + +#include "lj_obj.h" +#include "lj_ir.h" +#include "lj_jit.h" + +/* C call info for CALL* instructions. */ +typedef struct CCallInfo { + ASMFunction func; /* Function pointer. */ + uint32_t flags; /* Number of arguments and flags. */ +} CCallInfo; + +#define CCI_NARGS(ci) ((ci)->flags & 0xff) /* Extract # of args. */ +#define CCI_NARGS_MAX 32 /* Max. # of args. */ + +#define CCI_OTSHIFT 16 +#define CCI_OPTYPE(ci) ((ci)->flags >> CCI_OTSHIFT) /* Get op/type. */ +#define CCI_OPSHIFT 24 +#define CCI_OP(ci) ((ci)->flags >> CCI_OPSHIFT) /* Get op. */ + +#define CCI_CALL_N (IR_CALLN << CCI_OPSHIFT) +#define CCI_CALL_L (IR_CALLL << CCI_OPSHIFT) +#define CCI_CALL_S (IR_CALLS << CCI_OPSHIFT) +#define CCI_CALL_FN (CCI_CALL_N|CCI_FASTCALL) +#define CCI_CALL_FL (CCI_CALL_L|CCI_FASTCALL) +#define CCI_CALL_FS (CCI_CALL_S|CCI_FASTCALL) + +/* C call info flags. */ +#define CCI_L 0x0100 /* Implicit L arg. */ +#define CCI_CASTU64 0x0200 /* Cast u64 result to number. */ +#define CCI_NOFPRCLOBBER 0x0400 /* Does not clobber any FPRs. */ +#define CCI_FASTCALL 0x0800 /* Fastcall convention. */ + +/* Function definitions for CALL* instructions. */ +#if LJ_HASFFI +#if LJ_32 +#define ARG2_64 4 /* Treat as 4 32 bit arguments. */ +#define IRCALLDEF_FFI32(_) \ + _(lj_carith_mul64, ARG2_64, N, I64, CCI_NOFPRCLOBBER) +#else +#define ARG2_64 2 +#define IRCALLDEF_FFI32(_) +#endif +#define IRCALLDEF_FFI(_) \ + IRCALLDEF_FFI32(_) \ + _(lj_carith_divi64, ARG2_64, N, I64, CCI_NOFPRCLOBBER) \ + _(lj_carith_divu64, ARG2_64, N, U64, CCI_NOFPRCLOBBER) \ + _(lj_carith_modi64, ARG2_64, N, I64, CCI_NOFPRCLOBBER) \ + _(lj_carith_modu64, ARG2_64, N, U64, CCI_NOFPRCLOBBER) \ + _(lj_carith_powi64, ARG2_64, N, I64, CCI_NOFPRCLOBBER) \ + _(lj_carith_powu64, ARG2_64, N, U64, CCI_NOFPRCLOBBER) \ + _(lj_cdata_setfin, 2, FN, P32, CCI_L) \ + _(strlen, 1, N, INTP, 0) \ + _(memcpy, 3, S, PTR, 0) \ + _(memset, 3, S, PTR, 0) +#else +#define IRCALLDEF_FFI(_) +#endif +#define IRCALLDEF(_) \ + _(lj_str_cmp, 2, FN, INT, CCI_NOFPRCLOBBER) \ + _(lj_str_new, 3, S, STR, CCI_L) \ + _(lj_str_tonum, 2, FN, INT, 0) \ + _(lj_str_fromint, 2, FN, STR, CCI_L) \ + _(lj_str_fromnum, 2, FN, STR, CCI_L) \ + _(lj_tab_new1, 2, FS, TAB, CCI_L) \ + _(lj_tab_dup, 2, FS, TAB, CCI_L) \ + _(lj_tab_newkey, 3, S, P32, CCI_L) \ + _(lj_tab_len, 1, FL, INT, 0) \ + _(lj_gc_step_jit, 2, FS, NIL, CCI_L) \ + _(lj_gc_barrieruv, 2, FS, NIL, 0) \ + _(lj_mem_newgco, 2, FS, P32, CCI_L) \ + _(lj_math_random_step, 1, FS, NUM, CCI_CASTU64|CCI_NOFPRCLOBBER) \ + IRCALLDEF_FFI(_) \ + _(sinh, 1, N, NUM, 0) \ + _(cosh, 1, N, NUM, 0) \ + _(tanh, 1, N, NUM, 0) \ + _(fputc, 2, S, INT, 0) \ + _(fwrite, 4, S, INT, 0) \ + _(fflush, 1, S, INT, 0) \ + \ + /* End of list. */ + +typedef enum { +#define IRCALLENUM(name, nargs, kind, type, flags) IRCALL_##name, +IRCALLDEF(IRCALLENUM) +#undef IRCALLENUM + IRCALL__MAX +} IRCallID; + +LJ_FUNC TRef lj_ir_call(jit_State *J, IRCallID id, ...); + +LJ_DATA const CCallInfo lj_ir_callinfo[IRCALL__MAX+1]; + +#endif diff --git a/src/lj_iropt.h b/src/lj_iropt.h index 82dc2e27..daba5296 100644 --- a/src/lj_iropt.h +++ b/src/lj_iropt.h @@ -15,7 +15,6 @@ /* IR emitter. */ LJ_FUNC void LJ_FASTCALL lj_ir_growtop(jit_State *J); LJ_FUNC TRef LJ_FASTCALL lj_ir_emit(jit_State *J); -LJ_FUNC TRef lj_ir_call(jit_State *J, IRCallID id, ...); /* Save current IR in J->fold.ins, but do not emit it (yet). */ static LJ_AINLINE void lj_ir_set_(jit_State *J, uint16_t ot, IRRef1 a, IRRef1 b) diff --git a/src/lj_opt_split.c b/src/lj_opt_split.c index e52ddfd4..2f8b1e9c 100644 --- a/src/lj_opt_split.c +++ b/src/lj_opt_split.c @@ -14,6 +14,7 @@ #include "lj_str.h" #include "lj_ir.h" #include "lj_jit.h" +#include "lj_ircall.h" #include "lj_iropt.h" #include "lj_vm.h" diff --git a/src/lj_record.c b/src/lj_record.c index e51d0b5a..91555a3b 100644 --- a/src/lj_record.c +++ b/src/lj_record.c @@ -19,6 +19,7 @@ #include "lj_ff.h" #include "lj_ir.h" #include "lj_jit.h" +#include "lj_ircall.h" #include "lj_iropt.h" #include "lj_trace.h" #include "lj_record.h"