Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

reduce code size in initialization functions (letrec_main) #12

Open
gerdstolpmann opened this issue May 31, 2021 · 0 comments
Open

reduce code size in initialization functions (letrec_main) #12

gerdstolpmann opened this issue May 31, 2021 · 0 comments

Comments

@gerdstolpmann
Copy link
Collaborator

We already prevent local variables from being allocated and write all values to the stack. More is possible:

  • Shorter allocation snippets: instead of alloc_fast/alloc_slow just use caml_alloc_small
  • Shorter initialization of blocks: e.g. blockinit3(value, offset, p1, p2, p3) to write three values at value[offset], value[offset+1] and value[offset+2] (will need such functions for e.g. n=1 to n=5, and also shr versions that base on caml_initialize)
  • Shorter function calls
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant