Skip to content

Speed up focusFunction with a typed array. #4671

Merged
mstange merged 1 commit into
firefox-devtools:mainfrom
mstange:faster-focus-function
Jun 20, 2023
Merged

Speed up focusFunction with a typed array. #4671
mstange merged 1 commit into
firefox-devtools:mainfrom
mstange:faster-focus-function

Conversation

@mstange

@mstange mstange commented Jun 16, 2023

Copy link
Copy Markdown
Contributor

This speeds up focusFunction on https://share.firefox.dev/3CvZmmy by 7x, from 643ms to 89ms.

Before: https://share.firefox.dev/3PiMYhp
After: https://share.firefox.dev/3XfPabA

@mstange mstange requested a review from canova June 16, 2023 21:17
@mstange mstange self-assigned this Jun 16, 2023
@codecov

codecov Bot commented Jun 16, 2023

Copy link
Copy Markdown

Codecov Report

Patch coverage: 94.82% and project coverage change: -0.01 ⚠️

Comparison is base (1dc10ea) 88.49% compared to head (ef309ad) 88.49%.

❗ Current head ef309ad differs from pull request most recent head 4488f89. Consider uploading reports for the commit 4488f89 to get more accurate results

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4671      +/-   ##
==========================================
- Coverage   88.49%   88.49%   -0.01%     
==========================================
  Files         296      296              
  Lines       26318    26314       -4     
  Branches     7102     7103       +1     
==========================================
- Hits        23290    23286       -4     
  Misses       2816     2816              
  Partials      212      212              
Impacted Files Coverage Δ
src/profile-logic/transforms.js 91.63% <91.89%> (-0.03%) ⬇️
src/profile-logic/profile-data.js 93.69% <100.00%> (ø)
src/utils/range-set.js 100.00% <100.00%> (ø)

... and 2 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@mstange mstange force-pushed the faster-focus-function branch from aaf28d9 to ef309ad Compare June 19, 2023 15:48

@canova canova left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Nice!

@mstange mstange force-pushed the faster-focus-function branch from ef309ad to 4488f89 Compare June 20, 2023 16:26
@mstange mstange enabled auto-merge June 20, 2023 16:26
@mstange mstange merged commit 16271e4 into firefox-devtools:main Jun 20, 2023
@canova canova mentioned this pull request Jun 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants