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

PoC: Propagate arity between compilation units #1594

Draft
wants to merge 18 commits into
base: master
Choose a base branch
from
Draft

PoC: Propagate arity between compilation units #1594

wants to merge 18 commits into from

Conversation

hhugo
Copy link
Member

@hhugo hhugo commented Apr 8, 2024

PoC for #550

  • Store immutability property of blocks
  • Try to recover some immutability info from debug events. (currently assuming modules are immutable, need to check what happens with recursive modules
  • Use this info to compute an approximated shape for registered globals.
  • Use shape info to compute function arity across compilation units (this is currently only done when compiling cma files as we know the shape of previously compiled units inside the library)

TODOs/Questions:

  • check the behavior with recursive modules
  • fix with effects
  • update global_flow ?
  • better mechanism for shape propagation ?-
  • store shape in a different file ? yes
  • should the "shape" file be given jsoo on the command line or should it look for it on the file system ? both
  • update dune rules with additional deps

@hhugo hhugo requested a review from vouillon April 8, 2024 09:59
@hhugo
Copy link
Member Author

hhugo commented Apr 8, 2024

@vouillon, feel free to comment, review and even commit the branch.

compiler/lib/flow.ml Outdated Show resolved Hide resolved
compiler/lib/flow.ml Outdated Show resolved Hide resolved
compiler/lib/flow.ml Outdated Show resolved Hide resolved
compiler/lib/shape.ml Outdated Show resolved Hide resolved
@hhugo hhugo force-pushed the shapes branch 2 times, most recently from ffe3e43 to c7c009b Compare April 18, 2024 07:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants