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

DYN-777 : performance improvements demo #12055

Draft
wants to merge 1 commit into
base: RC2.12.0_master
Choose a base branch
from

Conversation

BogdanZavu
Copy link
Contributor

We don't always need to execute UI-related code and render UI components.
So we are going to load UI elements for nodes ( main content plus ports ) on demand when the user sets focus on a specific control.
If we are doing this Dynamo is ~= 50% faster when we are opening a graph and consumes ~= 50% less memory.
UI-less performance should be improved as well but probably not that much.
Note that even if full UI components are not loaded and a node looks empty graph execution works as expected.
Another nice aspect of this is that this work can be done incrementally one control after another.

@BogdanZavu BogdanZavu added the DNM Do not merge. For PRs. label Sep 23, 2021

private void ViewNode_MouseEnter(object sender, System.Windows.Input.MouseEventArgs e)
{
ConstructView();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so this is a little worrying - I think we'd want to add this to some base class to help authors not need to do this themselves, and we'll call ConstructView or whatever for them?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

something like that yes, we'll need a better mechanism to handle this different than mouse enter event


private void NodeView_MouseEnter(object sender, MouseEventArgs e)
{
PrepareInOutPortsControls();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what about destroying the ports control as well after zoom out or something to free up memory?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that too yes

@mjkkirschner
Copy link
Member

mjkkirschner commented Oct 4, 2021

@BogdanZavu I'm going to mark this draft, it seems to be making the tests run for a long time, if you plan to continue it then mark it ready.

@mjkkirschner mjkkirschner marked this pull request as draft October 4, 2021 21:23
@BogdanZavu
Copy link
Contributor Author

@mjkkirschner I don't plan on continuing with this, for now. Sorry, I just have made it a draft in the first place.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DNM Do not merge. For PRs.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants