Hello! l...@gnu.org (Ludovic Courtès) writes:
> The attached patch creates a new type tag, `scm_tc7_gsubr', whereby the > 24 MSBs are used to store gsubr arity information as returned by > `SCM_GSUBR_MAKTYPE ()'. This makes cclos useless, which simplifies the > code and reduces the overhead when creating and invoking such > procedures. I committed it: http://git.savannah.gnu.org/gitweb/?p=guile.git;a=commitdiff;h=e20d7001c3f7150400169fecb0bf0eefdf122fe2 http://git.savannah.gnu.org/gitweb/?p=guile.git;a=commitdiff;h=54d14084e229f90b75475a866e3f458be30fa233 I also committed a simple benchmark for subr invocation [0]. The result is as follows (truncated for clarity): - before patch ("subr.bm: subr invocation: simple subr" 700000 total 0.99) ("subr.bm: subr invocation: generic subr" 700000 total 1.77) ("subr.bm: subr application: simple subr" 700000 total 1.75) ("subr.bm: subr application: generic subr" 700000 total 2.31) - after patch ("subr.bm: subr invocation: simple subr" 700000 total 0.98) ("subr.bm: subr invocation: generic subr" 700000 total 1.38) ("subr.bm: subr application: simple subr" 700000 total 1.76) ("subr.bm: subr application: generic subr" 700000 total 2.16) That is, roughly a 20% improvement on gsubr invocation. Thanks, Ludo'. [0] http://git.savannah.gnu.org/gitweb/?p=guile.git;a=commitdiff;h=b786a5bbf825f61e04ccd9a54f93cb1e40ac67d9