mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-14 15:40:19 +02:00
remove code that manages the method cache
* libguile/goops.h (SCM_MCACHE_N_SPECIALIZED) (SCM_SET_MCACHE_N_SPECIALIZED, SCM_INITIAL_MCACHE_SIZE) (scm_make_method_cache, scm_memoize_method, scm_mcache_lookup_cmethod) (scm_mcache_compute_cmethod): * libguile/goops.c: Remove these procedures which managed the method cache. There's still a slot there but it's not initialized. The method cache is no longer necessary. * module/oop/goops/dispatch.scm (memoize-method!): Change to not take a "cache" argument. * libguile/eval.i.c: * libguile/vm-i-system.c: Remove dispatch via the method cache.
This commit is contained in:
parent
5bdea5bd3d
commit
9022ff183c
5 changed files with 2 additions and 231 deletions
|
@ -766,17 +766,6 @@ VM_DEFINE_INSTRUCTION (53, call, "call", 1, -1, 1)
|
|||
sp[-nargs] = SCM_STRUCT_PROCEDURE (x);
|
||||
goto vm_call;
|
||||
}
|
||||
if (SCM_STRUCTP (x) && SCM_OBJ_CLASS_FLAGS (x) & SCM_CLASSF_PURE_GENERIC)
|
||||
{
|
||||
SCM args = SCM_EOL;
|
||||
int n = nargs;
|
||||
SCM* walk = sp;
|
||||
SYNC_REGISTER ();
|
||||
while (n--)
|
||||
args = scm_cons (*walk--, args);
|
||||
*walk = scm_mcache_compute_cmethod (SCM_GENERIC_METHOD_CACHE (x), args);
|
||||
goto vm_call;
|
||||
}
|
||||
/*
|
||||
* Other interpreted or compiled call
|
||||
*/
|
||||
|
@ -855,17 +844,6 @@ VM_DEFINE_INSTRUCTION (54, goto_args, "goto/args", 1, -1, 1)
|
|||
sp[-nargs] = SCM_STRUCT_PROCEDURE (x);
|
||||
goto vm_goto_args;
|
||||
}
|
||||
if (SCM_STRUCTP (x) && SCM_OBJ_CLASS_FLAGS (x) & SCM_CLASSF_PURE_GENERIC)
|
||||
{
|
||||
SCM args = SCM_EOL;
|
||||
int n = nargs;
|
||||
SCM* walk = sp;
|
||||
SYNC_REGISTER ();
|
||||
while (n--)
|
||||
args = scm_cons (*walk--, args);
|
||||
*walk = scm_mcache_compute_cmethod (SCM_GENERIC_METHOD_CACHE (x), args);
|
||||
goto vm_goto_args;
|
||||
}
|
||||
|
||||
/*
|
||||
* Other interpreted or compiled call
|
||||
|
@ -952,17 +930,6 @@ VM_DEFINE_INSTRUCTION (57, mv_call, "mv-call", 4, -1, 1)
|
|||
sp[-nargs] = SCM_STRUCT_PROCEDURE (x);
|
||||
goto vm_mv_call;
|
||||
}
|
||||
if (SCM_STRUCTP (x) && SCM_OBJ_CLASS_FLAGS (x) & SCM_CLASSF_PURE_GENERIC)
|
||||
{
|
||||
SCM args = SCM_EOL;
|
||||
int n = nargs;
|
||||
SCM* walk = sp;
|
||||
SYNC_REGISTER ();
|
||||
while (n--)
|
||||
args = scm_cons (*walk--, args);
|
||||
*walk = scm_mcache_compute_cmethod (SCM_GENERIC_METHOD_CACHE (x), args);
|
||||
goto vm_mv_call;
|
||||
}
|
||||
/*
|
||||
* Other interpreted or compiled call
|
||||
*/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue