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

Remove AliasAnalysis metadata from LocalScope #10833

Closed
2 of 3 tasks
Akirathan opened this issue Aug 16, 2024 · 2 comments
Closed
2 of 3 tasks

Remove AliasAnalysis metadata from LocalScope #10833

Akirathan opened this issue Aug 16, 2024 · 2 comments

Comments

@Akirathan
Copy link
Member

Akirathan commented Aug 16, 2024

LocalScope is used in many places. It is referenced by some runtime objects, like MethodRootNode. The problem is that LocalScope contains references to AliasAnalysis metadata (e.g., AliasGraph in https://github.com/enso-org/enso/blob/develop/engine/runtime-compiler/src/main/scala/org/enso/compiler/context/LocalScope.scala#L34).

Loading AliasAnalysis metadata in IrToTruffle is potentially very slow, as the size of the metadata is enormous. Therefore, we should avoid using AliasAnalysis metadata in IrToTruffle altogether. This first PR (#10729) removed some usages and introduced new, lightweight, FramePointer metadata. In this task, let's remove the references to AliasAnalysis metadata from LocalScope altogether.

Tasks

Preview Give feedback

Follow-up of #10129

@JaroslavTulach
Copy link
Member

JaroslavTulach commented Aug 17, 2024

A step towards 10% speedup seems possible, but:

... still see more than 500 of AliasAnalysis metadata being read ... coming from EnsoRootNode.buildFrameDescriptor() - we need to find a build to build the descriptor ... without needing AliasAnalysis.

mergify bot pushed a commit that referenced this issue Aug 19, 2024
Continuation of #10729 and a step towards #10833 to actually speed things up by 10% by delaying loading of `AliasAnalysis` data.
@JaroslavTulach
Copy link
Member

Since #10837 the LocalScope can be constructed without loading AliasAnalysis data - if needed the data can be loaded later. Since #10906 we can build FrameDescriptor without loading these AliasAnalysis data at all. With #10996 we fix the caches to be able to load Hello_World.enso without needing any AliasAnalysis. To track use:

./enso --log-level trace --run xyz.enso | grep "] Scope"

I believe we are done.

@github-project-automation github-project-automation bot moved this from 📤 Backlog to 🟢 Accepted in Issues Board Sep 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

No branches or pull requests

2 participants