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

Optimise Non-Capturing Lambdas #582

Closed
iamrecursion opened this issue Jul 15, 2019 · 1 comment
Closed

Optimise Non-Capturing Lambdas #582

iamrecursion opened this issue Jul 15, 2019 · 1 comment
Labels
p-medium Should be completed in the next few sprints

Comments

@iamrecursion
Copy link
Contributor

Summary

In the current Enso interpreter all lambdas will capture their outer scope, materialising the parent stack frame even if they don't need to. We can optimise this by not materialising the frame unless specifically required to by the variables captured in the lambda.

Specification

  • Rework the implementation of lambdas such that they do not materialise their parent frame unless necessary.

Acceptance Criteria & Test Cases

  • The above optimisation has been made.
  • It results in performance improvements.
@kustosz
Copy link
Contributor

kustosz commented Aug 9, 2019

I cannot satisfy the second acceptance criterion – I cannot find a single benchmark that has room for improvement. I've tried refactoring the current benchmarks to take lambdas instead of just performing operations like addition. They have exactly the same scores. So I'm not implementing this – there's no point maintaining additional code when we don't have a tangible reason to. Moving this task to the icebox – maybe it will prove useful at a later stage.

@iamrecursion iamrecursion transferred this issue from another repository Jun 23, 2020
@joenash joenash added Category: Interpreter p-medium Should be completed in the next few sprints labels Jun 23, 2020
@wdanilo wdanilo closed this as completed Apr 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p-medium Should be completed in the next few sprints
Projects
None yet
Development

No branches or pull requests

4 participants