1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-15 16:20:17 +02:00

Remove RTL_ infix from macros

* libguile/programs.h (SCM_PROGRAM_P):
  (SCM_PROGRAM_CODE):
  (SCM_PROGRAM_FREE_VARIABLES):
  (SCM_PROGRAM_FREE_VARIABLE_REF):
  (SCM_PROGRAM_FREE_VARIABLE_SET):
  (SCM_PROGRAM_NUM_FREE_VARIABLES):
  (SCM_VALIDATE_PROGRAM): Remove RTL_ infix.

* libguile/continuations.c:
* libguile/continuations.h:
* libguile/control.c:
* libguile/foreign.c:
* libguile/frames.c:
* libguile/gsubr.c:
* libguile/gsubr.h:
* libguile/procprop.c:
* libguile/procs.c:
* libguile/programs.c:
* libguile/stacks.c:
* libguile/vm-engine.c: Adapt.
This commit is contained in:
Andy Wingo 2013-11-19 18:28:19 +01:00
parent e0755cd12a
commit d798a895cc
13 changed files with 63 additions and 63 deletions

View file

@ -77,7 +77,7 @@ make_continuation_trampoline (SCM contregs)
ret = scm_words (scm_tc7_program | (nfree << 16) | flags, nfree + 2); ret = scm_words (scm_tc7_program | (nfree << 16) | flags, nfree + 2);
SCM_SET_CELL_WORD_1 (ret, continuation_stub_code); SCM_SET_CELL_WORD_1 (ret, continuation_stub_code);
SCM_RTL_PROGRAM_FREE_VARIABLE_SET (ret, 0, contregs); SCM_PROGRAM_FREE_VARIABLE_SET (ret, 0, contregs);
return ret; return ret;
} }
@ -171,7 +171,7 @@ scm_i_continuation_to_frame (SCM continuation)
SCM contregs; SCM contregs;
scm_t_contregs *cont; scm_t_contregs *cont;
contregs = SCM_RTL_PROGRAM_FREE_VARIABLE_REF (continuation, 0); contregs = SCM_PROGRAM_FREE_VARIABLE_REF (continuation, 0);
cont = SCM_CONTREGS (contregs); cont = SCM_CONTREGS (contregs);
if (scm_is_true (cont->vm_cont)) if (scm_is_true (cont->vm_cont))

View file

@ -32,7 +32,7 @@
#define SCM_CONTINUATIONP(x) \ #define SCM_CONTINUATIONP(x) \
(SCM_RTL_PROGRAM_P (x) && SCM_PROGRAM_IS_CONTINUATION (x)) (SCM_PROGRAM_P (x) && SCM_PROGRAM_IS_CONTINUATION (x))
/* a continuation SCM is a non-immediate pointing to a heap cell with: /* a continuation SCM is a non-immediate pointing to a heap cell with:
word 0: bits 0-15: smob type tag: scm_tc16_continuation. word 0: bits 0-15: smob type tag: scm_tc16_continuation.

View file

@ -72,7 +72,7 @@ make_partial_continuation (SCM vm_cont)
ret = scm_words (scm_tc7_program | (nfree << 16) | flags, nfree + 2); ret = scm_words (scm_tc7_program | (nfree << 16) | flags, nfree + 2);
SCM_SET_CELL_WORD_1 (ret, compose_continuation_code); SCM_SET_CELL_WORD_1 (ret, compose_continuation_code);
SCM_RTL_PROGRAM_FREE_VARIABLE_SET (ret, 0, vm_cont); SCM_PROGRAM_FREE_VARIABLE_SET (ret, 0, vm_cont);
return ret; return ret;
} }

View file

@ -796,7 +796,7 @@ get_foreign_stub_code (unsigned int nargs)
int int
scm_i_foreign_arity (SCM foreign, int *req, int *opt, int *rest) scm_i_foreign_arity (SCM foreign, int *req, int *opt, int *rest)
{ {
const scm_t_uint32 *code = SCM_RTL_PROGRAM_CODE (foreign); const scm_t_uint32 *code = SCM_PROGRAM_CODE (foreign);
if (code < foreign_stub_code) if (code < foreign_stub_code)
return 0; return 0;
@ -823,8 +823,8 @@ cif_to_procedure (SCM cif, SCM func_ptr)
ret = scm_words (scm_tc7_program | (nfree << 16) | flags, nfree + 2); ret = scm_words (scm_tc7_program | (nfree << 16) | flags, nfree + 2);
SCM_SET_CELL_WORD_1 (ret, get_foreign_stub_code (c_cif->nargs)); SCM_SET_CELL_WORD_1 (ret, get_foreign_stub_code (c_cif->nargs));
SCM_RTL_PROGRAM_FREE_VARIABLE_SET (ret, 0, cif); SCM_PROGRAM_FREE_VARIABLE_SET (ret, 0, cif);
SCM_RTL_PROGRAM_FREE_VARIABLE_SET (ret, 1, func_ptr); SCM_PROGRAM_FREE_VARIABLE_SET (ret, 1, func_ptr);
return ret; return ret;
} }

View file

@ -252,7 +252,7 @@ SCM_DEFINE (scm_frame_previous, "frame-previous", 1, 0, 0,
SCM_VM_FRAME_OFFSET (frame)); SCM_VM_FRAME_OFFSET (frame));
proc = scm_frame_procedure (frame); proc = scm_frame_procedure (frame);
if (SCM_RTL_PROGRAM_P (proc) && SCM_PROGRAM_IS_BOOT (proc)) if (SCM_PROGRAM_P (proc) && SCM_PROGRAM_IS_BOOT (proc))
goto again; goto again;
else else
return frame; return frame;

View file

@ -241,10 +241,10 @@ create_subr (int define, const char *name,
ret = scm_words (scm_tc7_program | (nfree << 16) | flags, nfree + 2); ret = scm_words (scm_tc7_program | (nfree << 16) | flags, nfree + 2);
SCM_SET_CELL_WORD_1 (ret, get_subr_stub_code (nreq, nopt, rest)); SCM_SET_CELL_WORD_1 (ret, get_subr_stub_code (nreq, nopt, rest));
SCM_RTL_PROGRAM_FREE_VARIABLE_SET (ret, 0, scm_from_pointer (fcn, NULL)); SCM_PROGRAM_FREE_VARIABLE_SET (ret, 0, scm_from_pointer (fcn, NULL));
SCM_RTL_PROGRAM_FREE_VARIABLE_SET (ret, 1, sname); SCM_PROGRAM_FREE_VARIABLE_SET (ret, 1, sname);
if (generic_loc) if (generic_loc)
SCM_RTL_PROGRAM_FREE_VARIABLE_SET (ret, 2, SCM_PROGRAM_FREE_VARIABLE_SET (ret, 2,
scm_from_pointer (generic_loc, NULL)); scm_from_pointer (generic_loc, NULL));
if (define) if (define)
@ -259,7 +259,7 @@ create_subr (int define, const char *name,
int int
scm_i_primitive_arity (SCM prim, int *req, int *opt, int *rest) scm_i_primitive_arity (SCM prim, int *req, int *opt, int *rest)
{ {
const scm_t_uint32 *code = SCM_RTL_PROGRAM_CODE (prim); const scm_t_uint32 *code = SCM_PROGRAM_CODE (prim);
unsigned idx, nargs, base, next; unsigned idx, nargs, base, next;
if (code < subr_stub_code) if (code < subr_stub_code)
@ -289,7 +289,7 @@ scm_i_primitive_arity (SCM prim, int *req, int *opt, int *rest)
scm_t_uintptr scm_t_uintptr
scm_i_primitive_call_ip (SCM subr) scm_i_primitive_call_ip (SCM subr)
{ {
const scm_t_uint32 *code = SCM_RTL_PROGRAM_CODE (subr); const scm_t_uint32 *code = SCM_PROGRAM_CODE (subr);
/* A stub is 4 32-bit words long, or 16 bytes. The call will be one /* A stub is 4 32-bit words long, or 16 bytes. The call will be one
instruction, in either the fourth, third, or second word. Return a instruction, in either the fourth, third, or second word. Return a

View file

@ -36,18 +36,18 @@
/* Max number of args to the C procedure backing a gsubr */ /* Max number of args to the C procedure backing a gsubr */
#define SCM_GSUBR_MAX 10 #define SCM_GSUBR_MAX 10
#define SCM_PRIMITIVE_P(x) (SCM_RTL_PROGRAM_P (x) && SCM_PROGRAM_IS_PRIMITIVE (x)) #define SCM_PRIMITIVE_P(x) (SCM_PROGRAM_P (x) && SCM_PROGRAM_IS_PRIMITIVE (x))
#define SCM_PRIMITIVE_GENERIC_P(x) (SCM_RTL_PROGRAM_P (x) && SCM_PROGRAM_IS_PRIMITIVE_GENERIC (x)) #define SCM_PRIMITIVE_GENERIC_P(x) (SCM_PROGRAM_P (x) && SCM_PROGRAM_IS_PRIMITIVE_GENERIC (x))
#define SCM_SUBRF(x) \ #define SCM_SUBRF(x) \
((SCM (*) (void)) \ ((SCM (*) (void)) \
SCM_POINTER_VALUE (SCM_RTL_PROGRAM_FREE_VARIABLE_REF (x, 0))) SCM_POINTER_VALUE (SCM_PROGRAM_FREE_VARIABLE_REF (x, 0)))
#define SCM_SUBR_NAME(x) (SCM_RTL_PROGRAM_FREE_VARIABLE_REF (x, 1)) #define SCM_SUBR_NAME(x) (SCM_PROGRAM_FREE_VARIABLE_REF (x, 1))
#define SCM_SUBR_GENERIC(x) \ #define SCM_SUBR_GENERIC(x) \
((SCM *) SCM_POINTER_VALUE (SCM_RTL_PROGRAM_FREE_VARIABLE_REF (x, 2))) ((SCM *) SCM_POINTER_VALUE (SCM_PROGRAM_FREE_VARIABLE_REF (x, 2)))
#define SCM_SET_SUBR_GENERIC(x, g) \ #define SCM_SET_SUBR_GENERIC(x, g) \
(*SCM_SUBR_GENERIC (x) = (g)) (*SCM_SUBR_GENERIC (x) = (g))

View file

@ -61,7 +61,7 @@ scm_i_procedure_arity (SCM proc, int *req, int *opt, int *rest)
return 1; return 1;
} }
while (!SCM_RTL_PROGRAM_P (proc)) while (!SCM_PROGRAM_P (proc))
{ {
if (SCM_STRUCTP (proc)) if (SCM_STRUCTP (proc))
{ {
@ -146,7 +146,7 @@ SCM_DEFINE (scm_procedure_properties, "procedure-properties", 1, 0, 0,
if (scm_is_pair (user_props) && scm_is_true (scm_car (user_props))) if (scm_is_pair (user_props) && scm_is_true (scm_car (user_props)))
return scm_cdr (user_props); return scm_cdr (user_props);
if (SCM_RTL_PROGRAM_P (proc)) if (SCM_PROGRAM_P (proc))
ret = scm_i_rtl_program_properties (proc); ret = scm_i_rtl_program_properties (proc);
else else
ret = SCM_EOL; ret = SCM_EOL;
@ -258,7 +258,7 @@ SCM_DEFINE (scm_procedure_name, "procedure-name", 1, 0, 0,
return SCM_BOOL_F; return SCM_BOOL_F;
} }
if (SCM_RTL_PROGRAM_P (proc)) if (SCM_PROGRAM_P (proc))
return scm_i_rtl_program_name (proc); return scm_i_rtl_program_name (proc);
else if (SCM_STRUCTP (proc) && SCM_STRUCT_APPLICABLE_P (proc)) else if (SCM_STRUCTP (proc) && SCM_STRUCT_APPLICABLE_P (proc))
return scm_procedure_name (SCM_STRUCT_PROCEDURE (proc)); return scm_procedure_name (SCM_STRUCT_PROCEDURE (proc));
@ -295,7 +295,7 @@ SCM_DEFINE (scm_procedure_documentation, "procedure-documentation", 1, 0, 0,
return SCM_BOOL_F; return SCM_BOOL_F;
} }
if (SCM_RTL_PROGRAM_P (proc)) if (SCM_PROGRAM_P (proc))
return scm_i_rtl_program_documentation (proc); return scm_i_rtl_program_documentation (proc);
else else
return SCM_BOOL_F; return SCM_BOOL_F;

View file

@ -47,7 +47,7 @@ SCM_DEFINE (scm_procedure_p, "procedure?", 1, 0, 0,
"Return @code{#t} if @var{obj} is a procedure.") "Return @code{#t} if @var{obj} is a procedure.")
#define FUNC_NAME s_scm_procedure_p #define FUNC_NAME s_scm_procedure_p
{ {
return scm_from_bool (SCM_RTL_PROGRAM_P (obj) return scm_from_bool (SCM_PROGRAM_P (obj)
|| (SCM_STRUCTP (obj) && SCM_STRUCT_APPLICABLE_P (obj)) || (SCM_STRUCTP (obj) && SCM_STRUCT_APPLICABLE_P (obj))
|| (SCM_HAS_TYP7 (obj, scm_tc7_smob) || (SCM_HAS_TYP7 (obj, scm_tc7_smob)
&& SCM_SMOB_APPLICABLE_P (obj))); && SCM_SMOB_APPLICABLE_P (obj)));

View file

@ -65,9 +65,9 @@ SCM_DEFINE (scm_rtl_program_code, "rtl-program-code", 1, 0, 0,
"") "")
#define FUNC_NAME s_scm_rtl_program_code #define FUNC_NAME s_scm_rtl_program_code
{ {
SCM_VALIDATE_RTL_PROGRAM (1, program); SCM_VALIDATE_PROGRAM (1, program);
return scm_from_uintptr_t ((scm_t_uintptr) SCM_RTL_PROGRAM_CODE (program)); return scm_from_uintptr_t ((scm_t_uintptr) SCM_PROGRAM_CODE (program));
} }
#undef FUNC_NAME #undef FUNC_NAME
@ -150,7 +150,7 @@ scm_i_program_print (SCM program, SCM port, scm_print_state *pstate)
scm_puts_unlocked ("#<rtl-program ", port); scm_puts_unlocked ("#<rtl-program ", port);
scm_uintprint (SCM_UNPACK (program), 16, port); scm_uintprint (SCM_UNPACK (program), 16, port);
scm_putc_unlocked (' ', port); scm_putc_unlocked (' ', port);
scm_uintprint ((scm_t_uintptr) SCM_RTL_PROGRAM_CODE (program), 16, port); scm_uintprint ((scm_t_uintptr) SCM_PROGRAM_CODE (program), 16, port);
scm_putc_unlocked ('>', port); scm_putc_unlocked ('>', port);
} }
else else
@ -171,7 +171,7 @@ SCM_DEFINE (scm_rtl_program_p, "rtl-program?", 1, 0, 0,
"") "")
#define FUNC_NAME s_scm_rtl_program_p #define FUNC_NAME s_scm_rtl_program_p
{ {
return scm_from_bool (SCM_RTL_PROGRAM_P (obj)); return scm_from_bool (SCM_PROGRAM_P (obj));
} }
#undef FUNC_NAME #undef FUNC_NAME
@ -235,9 +235,9 @@ SCM_DEFINE (scm_program_num_free_variables, "program-num-free-variables", 1, 0,
"") "")
#define FUNC_NAME s_scm_program_num_free_variables #define FUNC_NAME s_scm_program_num_free_variables
{ {
SCM_VALIDATE_RTL_PROGRAM (1, program); SCM_VALIDATE_PROGRAM (1, program);
return scm_from_ulong (SCM_RTL_PROGRAM_NUM_FREE_VARIABLES (program)); return scm_from_ulong (SCM_PROGRAM_NUM_FREE_VARIABLES (program));
} }
#undef FUNC_NAME #undef FUNC_NAME
@ -248,11 +248,11 @@ SCM_DEFINE (scm_program_free_variable_ref, "program-free-variable-ref", 2, 0, 0,
{ {
unsigned long idx; unsigned long idx;
SCM_VALIDATE_RTL_PROGRAM (1, program); SCM_VALIDATE_PROGRAM (1, program);
SCM_VALIDATE_ULONG_COPY (2, i, idx); SCM_VALIDATE_ULONG_COPY (2, i, idx);
if (idx >= SCM_RTL_PROGRAM_NUM_FREE_VARIABLES (program)) if (idx >= SCM_PROGRAM_NUM_FREE_VARIABLES (program))
SCM_OUT_OF_RANGE (2, i); SCM_OUT_OF_RANGE (2, i);
return SCM_RTL_PROGRAM_FREE_VARIABLE_REF (program, idx); return SCM_PROGRAM_FREE_VARIABLE_REF (program, idx);
} }
#undef FUNC_NAME #undef FUNC_NAME
@ -263,11 +263,11 @@ SCM_DEFINE (scm_program_free_variable_set_x, "program-free-variable-set!", 3, 0,
{ {
unsigned long idx; unsigned long idx;
SCM_VALIDATE_RTL_PROGRAM (1, program); SCM_VALIDATE_PROGRAM (1, program);
SCM_VALIDATE_ULONG_COPY (2, i, idx); SCM_VALIDATE_ULONG_COPY (2, i, idx);
if (idx >= SCM_RTL_PROGRAM_NUM_FREE_VARIABLES (program)) if (idx >= SCM_PROGRAM_NUM_FREE_VARIABLES (program))
SCM_OUT_OF_RANGE (2, i); SCM_OUT_OF_RANGE (2, i);
SCM_RTL_PROGRAM_FREE_VARIABLE_SET (program, idx, x); SCM_PROGRAM_FREE_VARIABLE_SET (program, idx, x);
return SCM_UNSPECIFIED; return SCM_UNSPECIFIED;
} }
#undef FUNC_NAME #undef FUNC_NAME

View file

@ -25,13 +25,13 @@
* The new RTL programs. * The new RTL programs.
*/ */
#define SCM_RTL_PROGRAM_P(x) (SCM_HAS_TYP7 (x, scm_tc7_program)) #define SCM_PROGRAM_P(x) (SCM_HAS_TYP7 (x, scm_tc7_program))
#define SCM_RTL_PROGRAM_CODE(x) ((scm_t_uint32 *) SCM_CELL_WORD_1 (x)) #define SCM_PROGRAM_CODE(x) ((scm_t_uint32 *) SCM_CELL_WORD_1 (x))
#define SCM_RTL_PROGRAM_FREE_VARIABLES(x) (SCM_CELL_OBJECT_LOC (x, 2)) #define SCM_PROGRAM_FREE_VARIABLES(x) (SCM_CELL_OBJECT_LOC (x, 2))
#define SCM_RTL_PROGRAM_FREE_VARIABLE_REF(x,i) (SCM_RTL_PROGRAM_FREE_VARIABLES (x)[i]) #define SCM_PROGRAM_FREE_VARIABLE_REF(x,i) (SCM_PROGRAM_FREE_VARIABLES (x)[i])
#define SCM_RTL_PROGRAM_FREE_VARIABLE_SET(x,i,v) (SCM_RTL_PROGRAM_FREE_VARIABLES (x)[i]=(v)) #define SCM_PROGRAM_FREE_VARIABLE_SET(x,i,v) (SCM_PROGRAM_FREE_VARIABLES (x)[i]=(v))
#define SCM_RTL_PROGRAM_NUM_FREE_VARIABLES(x) (SCM_CELL_WORD_0 (x) >> 16) #define SCM_PROGRAM_NUM_FREE_VARIABLES(x) (SCM_CELL_WORD_0 (x) >> 16)
#define SCM_VALIDATE_RTL_PROGRAM(p,x) SCM_MAKE_VALIDATE (p, x, RTL_PROGRAM_P) #define SCM_VALIDATE_PROGRAM(p,x) SCM_MAKE_VALIDATE (p, x, PROGRAM_P)
static inline SCM static inline SCM
scm_i_make_rtl_program (const scm_t_uint32 *code) scm_i_make_rtl_program (const scm_t_uint32 *code)

View file

@ -276,7 +276,7 @@ SCM_DEFINE (scm_make_stack, "make-stack", 1, 0, 1,
/* FIXME: is this even possible? */ /* FIXME: is this even possible? */
if (scm_is_true (frame) if (scm_is_true (frame)
&& SCM_RTL_PROGRAM_P (scm_frame_procedure (frame)) && SCM_PROGRAM_P (scm_frame_procedure (frame))
&& SCM_PROGRAM_IS_BOOT (scm_frame_procedure (frame))) && SCM_PROGRAM_IS_BOOT (scm_frame_procedure (frame)))
frame = scm_frame_previous (frame); frame = scm_frame_previous (frame);

View file

@ -483,7 +483,7 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
} }
apply: apply:
while (!SCM_RTL_PROGRAM_P (SCM_FRAME_PROGRAM (fp))) while (!SCM_PROGRAM_P (SCM_FRAME_PROGRAM (fp)))
{ {
SCM proc = SCM_FRAME_PROGRAM (fp); SCM proc = SCM_FRAME_PROGRAM (fp);
@ -510,7 +510,7 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
} }
/* Let's go! */ /* Let's go! */
ip = SCM_RTL_PROGRAM_CODE (SCM_FRAME_PROGRAM (fp)); ip = SCM_PROGRAM_CODE (SCM_FRAME_PROGRAM (fp));
NEXT (0); NEXT (0);
BEGIN_DISPATCH_SWITCH; BEGIN_DISPATCH_SWITCH;
@ -584,10 +584,10 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
PUSH_CONTINUATION_HOOK (); PUSH_CONTINUATION_HOOK ();
APPLY_HOOK (); APPLY_HOOK ();
if (SCM_UNLIKELY (!SCM_RTL_PROGRAM_P (SCM_FRAME_PROGRAM (fp)))) if (SCM_UNLIKELY (!SCM_PROGRAM_P (SCM_FRAME_PROGRAM (fp))))
goto apply; goto apply;
ip = SCM_RTL_PROGRAM_CODE (SCM_FRAME_PROGRAM (fp)); ip = SCM_PROGRAM_CODE (SCM_FRAME_PROGRAM (fp));
NEXT (0); NEXT (0);
} }
@ -609,10 +609,10 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
APPLY_HOOK (); APPLY_HOOK ();
if (SCM_UNLIKELY (!SCM_RTL_PROGRAM_P (SCM_FRAME_PROGRAM (fp)))) if (SCM_UNLIKELY (!SCM_PROGRAM_P (SCM_FRAME_PROGRAM (fp))))
goto apply; goto apply;
ip = SCM_RTL_PROGRAM_CODE (SCM_FRAME_PROGRAM (fp)); ip = SCM_PROGRAM_CODE (SCM_FRAME_PROGRAM (fp));
NEXT (0); NEXT (0);
} }
@ -641,10 +641,10 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
APPLY_HOOK (); APPLY_HOOK ();
if (SCM_UNLIKELY (!SCM_RTL_PROGRAM_P (SCM_FRAME_PROGRAM (fp)))) if (SCM_UNLIKELY (!SCM_PROGRAM_P (SCM_FRAME_PROGRAM (fp))))
goto apply; goto apply;
ip = SCM_RTL_PROGRAM_CODE (SCM_FRAME_PROGRAM (fp)); ip = SCM_PROGRAM_CODE (SCM_FRAME_PROGRAM (fp));
NEXT (0); NEXT (0);
} }
@ -746,7 +746,7 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
SCM_UNPACK_RTL_24 (op, ptr_idx); SCM_UNPACK_RTL_24 (op, ptr_idx);
pointer = SCM_RTL_PROGRAM_FREE_VARIABLE_REF (LOCAL_REF (0), ptr_idx); pointer = SCM_PROGRAM_FREE_VARIABLE_REF (LOCAL_REF (0), ptr_idx);
subr = SCM_POINTER_VALUE (pointer); subr = SCM_POINTER_VALUE (pointer);
VM_HANDLE_INTERRUPTS; VM_HANDLE_INTERRUPTS;
@ -816,8 +816,8 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
SCM_UNPACK_RTL_12_12 (op, cif_idx, ptr_idx); SCM_UNPACK_RTL_12_12 (op, cif_idx, ptr_idx);
closure = LOCAL_REF (0); closure = LOCAL_REF (0);
cif = SCM_RTL_PROGRAM_FREE_VARIABLE_REF (closure, cif_idx); cif = SCM_PROGRAM_FREE_VARIABLE_REF (closure, cif_idx);
pointer = SCM_RTL_PROGRAM_FREE_VARIABLE_REF (closure, ptr_idx); pointer = SCM_PROGRAM_FREE_VARIABLE_REF (closure, ptr_idx);
SYNC_IP (); SYNC_IP ();
VM_HANDLE_INTERRUPTS; VM_HANDLE_INTERRUPTS;
@ -850,7 +850,7 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
SCM_UNPACK_RTL_24 (op, contregs_idx); SCM_UNPACK_RTL_24 (op, contregs_idx);
contregs = contregs =
SCM_RTL_PROGRAM_FREE_VARIABLE_REF (LOCAL_REF (0), contregs_idx); SCM_PROGRAM_FREE_VARIABLE_REF (LOCAL_REF (0), contregs_idx);
SYNC_IP (); SYNC_IP ();
scm_i_check_continuation (contregs); scm_i_check_continuation (contregs);
@ -878,7 +878,7 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
scm_t_uint32 cont_idx; scm_t_uint32 cont_idx;
SCM_UNPACK_RTL_24 (op, cont_idx); SCM_UNPACK_RTL_24 (op, cont_idx);
vmcont = SCM_RTL_PROGRAM_FREE_VARIABLE_REF (LOCAL_REF (0), cont_idx); vmcont = SCM_PROGRAM_FREE_VARIABLE_REF (LOCAL_REF (0), cont_idx);
SYNC_IP (); SYNC_IP ();
VM_ASSERT (SCM_VM_CONT_REWINDABLE_P (vmcont), VM_ASSERT (SCM_VM_CONT_REWINDABLE_P (vmcont),
@ -929,10 +929,10 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
APPLY_HOOK (); APPLY_HOOK ();
if (SCM_UNLIKELY (!SCM_RTL_PROGRAM_P (SCM_FRAME_PROGRAM (fp)))) if (SCM_UNLIKELY (!SCM_PROGRAM_P (SCM_FRAME_PROGRAM (fp))))
goto apply; goto apply;
ip = SCM_RTL_PROGRAM_CODE (SCM_FRAME_PROGRAM (fp)); ip = SCM_PROGRAM_CODE (SCM_FRAME_PROGRAM (fp));
NEXT (0); NEXT (0);
} }
@ -973,10 +973,10 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
APPLY_HOOK (); APPLY_HOOK ();
if (SCM_UNLIKELY (!SCM_RTL_PROGRAM_P (SCM_FRAME_PROGRAM (fp)))) if (SCM_UNLIKELY (!SCM_PROGRAM_P (SCM_FRAME_PROGRAM (fp))))
goto apply; goto apply;
ip = SCM_RTL_PROGRAM_CODE (SCM_FRAME_PROGRAM (fp)); ip = SCM_PROGRAM_CODE (SCM_FRAME_PROGRAM (fp));
NEXT (0); NEXT (0);
} }
else else
@ -1562,7 +1562,7 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
SCM_SET_CELL_WORD_1 (closure, ip + offset); SCM_SET_CELL_WORD_1 (closure, ip + offset);
// FIXME: Elide these initializations? // FIXME: Elide these initializations?
for (n = 0; n < nfree; n++) for (n = 0; n < nfree; n++)
SCM_RTL_PROGRAM_FREE_VARIABLE_SET (closure, n, SCM_BOOL_F); SCM_PROGRAM_FREE_VARIABLE_SET (closure, n, SCM_BOOL_F);
LOCAL_SET (dst, closure); LOCAL_SET (dst, closure);
NEXT (3); NEXT (3);
} }
@ -1578,7 +1578,7 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
SCM_UNPACK_RTL_12_12 (op, dst, src); SCM_UNPACK_RTL_12_12 (op, dst, src);
SCM_UNPACK_RTL_24 (ip[1], idx); SCM_UNPACK_RTL_24 (ip[1], idx);
/* CHECK_FREE_VARIABLE (src); */ /* CHECK_FREE_VARIABLE (src); */
LOCAL_SET (dst, SCM_RTL_PROGRAM_FREE_VARIABLE_REF (LOCAL_REF (src), idx)); LOCAL_SET (dst, SCM_PROGRAM_FREE_VARIABLE_REF (LOCAL_REF (src), idx));
NEXT (2); NEXT (2);
} }
@ -1593,7 +1593,7 @@ RTL_VM_NAME (SCM vm, SCM program, SCM *argv, size_t nargs_)
SCM_UNPACK_RTL_12_12 (op, dst, src); SCM_UNPACK_RTL_12_12 (op, dst, src);
SCM_UNPACK_RTL_24 (ip[1], idx); SCM_UNPACK_RTL_24 (ip[1], idx);
/* CHECK_FREE_VARIABLE (src); */ /* CHECK_FREE_VARIABLE (src); */
SCM_RTL_PROGRAM_FREE_VARIABLE_SET (LOCAL_REF (dst), idx, LOCAL_REF (src)); SCM_PROGRAM_FREE_VARIABLE_SET (LOCAL_REF (dst), idx, LOCAL_REF (src));
NEXT (2); NEXT (2);
} }