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

refactor: use map for user timing API for better performance (fixes #45122) #45206

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

robik
Copy link
Contributor

@robik robik commented Jun 27, 2024

Summary:

Fix #45122.

performance.mark is currently O(1) but performance.clearMark is O(n) (being n the number of entries in the buffer), which makes this operation very slow.

Changelog:

[GENERAL] [CHANGED] - Improved performance of performance.clearMarks and performance.clearMeasures

Test Plan:

n/a

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Jun 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve performance of performance.clearMarks
2 participants