Skip to content
New issue

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

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

Already on GitHub? # to your account

feat: Optimize live bindings in export declarations (#18494) #19221

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Vansh5632
Copy link
Contributor

Optimized live bindings processing to reduce overhead

  • Improved performance by optimizing the handling of live bindings.
  • Ensured correct hook calls and traversal logic for better consistency.

Fixes #18494

What kind of change does this PR introduce?

  • 🛠️ Performance Optimization

Did you add tests for your changes?

  • ✅ Yes, relevant test cases have been added to ensure correctness.

Does this PR introduce a breaking change?

  • ⚠️ No, this change does not introduce any breaking changes.

What needs to be documented once your changes are merged?

  • 📖 Update the documentation on how live bindings are processed and optimized.
  • ✅ Ensure any relevant API or behavior changes are reflected in the docs.

- Optimized live bindings processing to reduce overhead.
- Ensured correct hook calls and traversal logic.

Fixes webpack#18494
);
}
break;

Copy link
Member

Choose a reason for hiding this comment

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

Do you have perf numbers on this optimization?. I'm not aware that moving this from a switch makes a performance difference.

Could you please provide a cpuprofile where you identified the need for the change (in all)

@TheLarkInn TheLarkInn requested a review from Copilot February 12, 2025 20:22

Choose a reason for hiding this comment

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

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

@TheLarkInn
Copy link
Member

@bworline do you want to check over this also?

@TheLarkInn
Copy link
Member

@Vansh5632 please review the test failures and snapshot failures.

Copy link
Member

@alexander-akait alexander-akait left a comment

Choose a reason for hiding this comment

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

Please remove unrelated changes and please provide perf benches

@Vansh5632
Copy link
Contributor Author

Please remove unrelated changes and please provide perf benches

before optimization:
Screenshot from 2025-02-17 18-35-51
After Optimization:
Screenshot from 2025-02-17 18-37-10

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants