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

Unify perform{Sync,Concurrent}WorkOnRoot implementation #31029

Merged
merged 2 commits into from
Sep 25, 2024

Conversation

acdlite
Copy link
Collaborator

@acdlite acdlite commented Sep 23, 2024

Over time the behavior of these two paths has converged to be essentially the same. So this merges them back into one function. This should save some code size and also make it harder for the behavior to accidentally diverge. (For the same reason, rolling out this change might expose some areas where we had already accidentally diverged.)

Copy link

vercel bot commented Sep 23, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
react-compiler-playground ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 23, 2024 9:04pm

@react-sizebot
Copy link

react-sizebot commented Sep 23, 2024

Comparing: 5b19dc0...cb792b3

Critical size changes

Includes critical production bundles, as well as any change greater than 2%:

Name +/- Base Current +/- gzip Base gzip Current gzip
oss-stable/react-dom/cjs/react-dom.production.js = 6.68 kB 6.68 kB +0.05% 1.82 kB 1.82 kB
oss-stable/react-dom/cjs/react-dom-client.production.js = 509.10 kB 508.43 kB = 91.06 kB 90.91 kB
oss-experimental/react-dom/cjs/react-dom.production.js = 6.69 kB 6.69 kB +0.05% 1.83 kB 1.83 kB
oss-experimental/react-dom/cjs/react-dom-client.production.js = 514.04 kB 513.37 kB = 91.78 kB 91.63 kB
facebook-www/ReactDOM-prod.classic.js = 603.53 kB 602.96 kB = 106.78 kB 106.63 kB
facebook-www/ReactDOM-prod.modern.js = 579.76 kB 579.15 kB = 102.88 kB 102.71 kB

Significant size changes

Includes any change greater than 0.2%:

Expand to show
Name +/- Base Current +/- gzip Base gzip Current gzip
react-native/implementations/ReactNativeRenderer-dev.js = 642.39 kB 641.08 kB = 105.39 kB 105.25 kB
facebook-www/ReactART-dev.modern.js = 632.79 kB 631.45 kB = 101.19 kB 101.03 kB
facebook-react-native/react-test-renderer/cjs/ReactTestRenderer-dev.js = 580.26 kB 578.95 kB = 94.53 kB 94.39 kB
facebook-www/ReactTestRenderer-dev.classic.js = 574.48 kB 573.17 kB = 93.92 kB 93.79 kB
facebook-www/ReactTestRenderer-dev.modern.js = 574.48 kB 573.16 kB = 93.92 kB 93.79 kB
oss-stable/react-art/cjs/react-art.development.js = 554.30 kB 552.99 kB = 89.70 kB 89.56 kB
oss-stable-rc/react-art/cjs/react-art.development.js = 554.24 kB 552.93 kB = 89.68 kB 89.54 kB
oss-stable-semver/react-art/cjs/react-art.development.js = 554.24 kB 552.93 kB = 89.68 kB 89.54 kB
oss-experimental/react-test-renderer/cjs/react-test-renderer.development.js = 549.72 kB 548.41 kB = 89.81 kB 89.66 kB
oss-stable/react-test-renderer/cjs/react-test-renderer.development.js = 547.16 kB 545.84 kB = 89.41 kB 89.26 kB
oss-stable-rc/react-test-renderer/cjs/react-test-renderer.development.js = 547.10 kB 545.78 kB = 89.39 kB 89.24 kB
oss-stable-semver/react-test-renderer/cjs/react-test-renderer.development.js = 547.10 kB 545.78 kB = 89.39 kB 89.24 kB
react-native/implementations/ReactNativeRenderer-profiling.fb.js = 411.40 kB 410.08 kB = 71.33 kB 71.08 kB
react-native/implementations/ReactFabric-profiling.fb.js = 405.77 kB 404.45 kB = 70.20 kB 69.96 kB
react-native/implementations/ReactNativeRenderer-profiling.js = 386.33 kB 385.02 kB = 67.02 kB 66.73 kB
react-native/implementations/ReactNativeRenderer-prod.fb.js = 385.84 kB 384.53 kB = 67.54 kB 67.29 kB
facebook-www/ReactART-prod.classic.js = 370.65 kB 369.38 kB = 62.73 kB 62.51 kB
react-native/implementations/ReactFabric-prod.fb.js = 380.18 kB 378.86 kB = 66.33 kB 66.10 kB
react-native/implementations/ReactFabric-profiling.js = 376.67 kB 375.36 kB = 65.21 kB 64.96 kB
react-native/implementations/ReactNativeRenderer-prod.js = 361.08 kB 359.77 kB = 63.20 kB 62.96 kB
facebook-www/ReactART-prod.modern.js = 353.61 kB 352.30 kB = 59.98 kB 59.77 kB
react-native/implementations/ReactFabric-prod.js = 351.42 kB 350.11 kB = 61.53 kB 61.31 kB
facebook-react-native/react-test-renderer/cjs/ReactTestRenderer-profiling.js = 346.11 kB 344.80 kB = 60.20 kB 59.89 kB
facebook-react-native/react-test-renderer/cjs/ReactTestRenderer-prod.js = 324.25 kB 322.94 kB = 57.12 kB 56.86 kB
oss-experimental/react-test-renderer/cjs/react-test-renderer.production.js = 309.29 kB 307.92 kB = 54.72 kB 54.44 kB
oss-stable/react-test-renderer/cjs/react-test-renderer.production.js = 306.88 kB 305.51 kB = 54.26 kB 53.98 kB
oss-stable-rc/react-test-renderer/cjs/react-test-renderer.production.js = 306.82 kB 305.44 kB = 54.24 kB 53.96 kB
oss-stable-semver/react-test-renderer/cjs/react-test-renderer.production.js = 306.82 kB 305.44 kB = 54.24 kB 53.96 kB
oss-experimental/react-art/cjs/react-art.production.js = 304.21 kB 302.84 kB = 52.28 kB 52.01 kB
oss-stable/react-art/cjs/react-art.production.js = 299.69 kB 298.33 kB = 51.52 kB 51.26 kB
oss-stable-rc/react-art/cjs/react-art.production.js = 299.63 kB 298.26 kB = 51.50 kB 51.24 kB
oss-stable-semver/react-art/cjs/react-art.production.js = 299.63 kB 298.26 kB = 51.50 kB 51.24 kB

Generated by 🚫 dangerJS against 5833022

Over time the behavior of these two paths has converged to be
essentially the same. So this merges them back into one function. This
should save some code size and also make it harder for the behavior to
accidentally diverge. (For the same reason, rolling out this change
might expose some areas where we had already accidentally diverged.)

let renderEndTime = 0;
if (enableProfilerTimer && enableComponentPerformanceTrack) {
renderEndTime = now();
Copy link
Collaborator

Choose a reason for hiding this comment

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

I was originally confused by the diffing but this seems like it's now covered by performWorkOnRoot.

@acdlite acdlite merged commit 3c7667a into facebook:main Sep 25, 2024
184 checks passed
github-actions bot pushed a commit that referenced this pull request Sep 25, 2024
Over time the behavior of these two paths has converged to be
essentially the same. So this merges them back into one function. This
should save some code size and also make it harder for the behavior to
accidentally diverge. (For the same reason, rolling out this change
might expose some areas where we had already accidentally diverged.)

DiffTrain build for [3c7667a](3c7667a)
github-actions bot pushed a commit that referenced this pull request Sep 25, 2024
Over time the behavior of these two paths has converged to be
essentially the same. So this merges them back into one function. This
should save some code size and also make it harder for the behavior to
accidentally diverge. (For the same reason, rolling out this change
might expose some areas where we had already accidentally diverged.)

DiffTrain build for commit 3c7667a.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed React Core Team Opened by a member of the React Core Team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants