mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-14 15:40:19 +02:00
lazily load meta info, for less consage
* module/system/vm/assemble.scm (make-meta, codegen): Hide the "meta" information -- the names of the bindings, source info, procedure properties, etc -- behind a lambda. This way, loading up a program conses less, because the metadata stays as mmap'd code until it is needed. * libguile/vm-i-loader.c (load-program): Adjust load-program to expect the metadata to be a program. * module/system/vm/program.scm (program-bindings, program-sources) (program-properties): Adjust to new meta format.
This commit is contained in:
parent
7063452276
commit
13906f976e
3 changed files with 33 additions and 14 deletions
|
@ -118,7 +118,7 @@ VM_DEFINE_LOADER (load_program, "load-program")
|
|||
POP (x);
|
||||
|
||||
/* init meta data */
|
||||
if (SCM_CONSP (x))
|
||||
if (SCM_PROGRAM_P (x))
|
||||
{
|
||||
p->meta = x;
|
||||
POP (x);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue