GeezerVison is showing github.com — [draft] Move resetChildLanes into complete work by bvaughn · Pull Request #19801 · react/react
Conversation
bvaughn
commented
Sep 9, 2020
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
Alternative to #19440.
I'm breaking this PR down into small chunks for my own benefit. (Obviously these commits will be squashed prior to merging.)
- Move
resetChildLanes out of work loop and into complete work (named bubbleProperties)
- Move tag-type checks in
bubbleProperties into their corresponding switch/case statements.
- Temporarily split
bubbleProperties up into separate functions for lanes, flags, and Profiler durations.
- Refactor
subtreeLanes to bubble from workInProgress to parent (rather than from children to workInProgress).
- Refactor
childLanes to bubble from workInProgress to parent (rather than from children to workInProgress). (I've committed a partial refactor for this, but it still has some failing tests.)
- Refactor Profiler durations to bubble from
workInProgress to parent (rather than from children to workInProgress).
- Merge separate bubble functions back into
bubbleProperties method.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
This enabled us to remove a few hot path tag-type checks, but did not otherwise change any functionality.
…bubble methods so I can refactor each in isolation
sizebot
commented
Sep 9, 2020
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
Details of bundled changes.
Comparing: d38ec17...7f575fa
react-dom
| File |
Filesize Diff |
Gzip Diff |
Prev Size |
Current Size |
Prev Gzip |
Current Gzip |
ENV |
| react-dom.development.js |
0.0% |
0.0% |
869.86 KB |
869.86 KB |
199.68 KB |
199.68 KB |
NODE_DEV |
| ReactDOMForked-prod.js |
🔺+0.2% |
🔺+0.1% |
387.95 KB |
388.65 KB |
71.73 KB |
71.82 KB |
FB_WWW_PROD |
| ReactDOMForked-profiling.js |
+0.2% |
0.0% |
401.44 KB |
402.13 KB |
74.21 KB |
74.22 KB |
FB_WWW_PROFILING |
| react-dom-server.browser.development.js |
0.0% |
0.0% |
143.14 KB |
143.14 KB |
36.57 KB |
36.57 KB |
UMD_DEV |
| react-dom-test-utils.production.min.js |
0.0% |
0.0% |
12.83 KB |
12.83 KB |
5.04 KB |
5.04 KB |
UMD_PROD |
| ReactDOMTesting-dev.js |
0.0% |
-0.0% |
941.49 KB |
941.49 KB |
211.57 KB |
211.57 KB |
FB_WWW_DEV |
| react-dom.development.js |
0.0% |
0.0% |
914.12 KB |
914.12 KB |
202.19 KB |
202.19 KB |
UMD_DEV |
| ReactDOMForked-dev.js |
+0.2% |
+0.3% |
985.82 KB |
988.09 KB |
219.04 KB |
219.67 KB |
FB_WWW_DEV |
| react-dom.profiling.min.js |
0.0% |
0.0% |
121.83 KB |
121.83 KB |
39.28 KB |
39.28 KB |
NODE_PROFILING |
| ReactDOM-dev.js |
0.0% |
0.0% |
985.2 KB |
985.2 KB |
219.53 KB |
219.53 KB |
FB_WWW_DEV |
| ReactDOM-prod.js |
0.0% |
0.0% |
387.45 KB |
387.45 KB |
71.46 KB |
71.47 KB |
FB_WWW_PROD |
| ReactDOM-profiling.js |
0.0% |
0.0% |
400.65 KB |
400.65 KB |
73.9 KB |
73.9 KB |
FB_WWW_PROFILING |
| react-dom-server.browser.production.min.js |
0.0% |
0.0% |
19.78 KB |
19.78 KB |
7.42 KB |
7.42 KB |
NODE_PROD |
| ReactDOMServer-prod.js |
0.0% |
0.0% |
47.3 KB |
47.3 KB |
11.03 KB |
11.04 KB |
FB_WWW_PROD |
| react-dom-test-utils.development.js |
0.0% |
-0.0% |
66.08 KB |
66.08 KB |
18.23 KB |
18.23 KB |
UMD_DEV |
ReactDOM: size: 0.0%, gzip: 0.0%
Size changes (stable)
Generated by 🚫 dangerJS against 7f575fa
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
sizebot
commented
Sep 9, 2020
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
Details of bundled changes.
Comparing: d38ec17...7f575fa
react-dom
| File |
Filesize Diff |
Gzip Diff |
Prev Size |
Current Size |
Prev Gzip |
Current Gzip |
ENV |
| react-dom.development.js |
0.0% |
0.0% |
905.31 KB |
905.31 KB |
206.17 KB |
206.17 KB |
NODE_DEV |
| ReactDOMForked-prod.js |
🔺+0.2% |
🔺+0.1% |
376.78 KB |
377.42 KB |
69.97 KB |
70.07 KB |
FB_WWW_PROD |
| ReactDOMForked-profiling.js |
+0.2% |
+0.1% |
390.22 KB |
390.85 KB |
72.45 KB |
72.5 KB |
FB_WWW_PROFILING |
| react-dom-test-utils.production.min.js |
0.0% |
0.0% |
12.84 KB |
12.84 KB |
5.04 KB |
5.05 KB |
UMD_PROD |
| ReactDOMTesting-prod.js |
0.0% |
0.0% |
375.01 KB |
375.01 KB |
70.76 KB |
70.76 KB |
FB_WWW_PROD |
| react-dom-unstable-fizz.node.development.js |
0.0% |
-0.1% |
5.52 KB |
5.52 KB |
1.84 KB |
1.84 KB |
NODE_DEV |
| react-dom-test-utils.production.min.js |
0.0% |
0.0% |
12.68 KB |
12.68 KB |
4.97 KB |
4.97 KB |
NODE_PROD |
| react-dom-unstable-fizz.browser.development.js |
0.0% |
-0.1% |
5.25 KB |
5.25 KB |
1.78 KB |
1.78 KB |
UMD_DEV |
| react-dom-unstable-fizz.browser.development.js |
0.0% |
-0.1% |
4.78 KB |
4.78 KB |
1.68 KB |
1.68 KB |
NODE_DEV |
| react-dom-unstable-fizz.browser.production.min.js |
0.0% |
🔺+0.2% |
1.01 KB |
1.01 KB |
615 B |
616 B |
NODE_PROD |
| react-dom.profiling.min.js |
0.0% |
0.0% |
127.41 KB |
127.41 KB |
41.77 KB |
41.77 KB |
UMD_PROFILING |
| ReactDOMForked-dev.js |
+0.2% |
+0.3% |
960.3 KB |
962.57 KB |
214.26 KB |
214.88 KB |
FB_WWW_DEV |
| react-dom.profiling.min.js |
0.0% |
0.0% |
127.76 KB |
127.76 KB |
41.05 KB |
41.05 KB |
NODE_PROFILING |
| react-dom-server.browser.production.min.js |
0.0% |
0.0% |
20.34 KB |
20.34 KB |
7.55 KB |
7.55 KB |
UMD_PROD |
| ReactDOM-dev.js |
0.0% |
0.0% |
959.68 KB |
959.68 KB |
214.8 KB |
214.8 KB |
FB_WWW_DEV |
| ReactDOM-prod.js |
0.0% |
0.0% |
376.28 KB |
376.28 KB |
69.76 KB |
69.76 KB |
FB_WWW_PROD |
| ReactDOM-profiling.js |
0.0% |
0.0% |
389.44 KB |
389.44 KB |
72.2 KB |
72.2 KB |
FB_WWW_PROFILING |
ReactDOM: size: 0.0%, gzip: 0.0%
Size changes (experimental)
Generated by 🚫 dangerJS against 7f575fa
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
|
This pull request is automatically built and testable in CodeSandbox.
To see build info of the built libraries, click here or the icon next to each commit SHA.
Latest deployment of this branch, based on commit 7f575fa:
| Sandbox |
Source |
| React |
Configuration |
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
(rather than from children to workInProgress). This attempt isn't quite right though. Has some test failures that requires additional investigation.
This was referenced Sep 14, 2020
|
After some thought and discussion, we've decided this effort isn't worth the time and complexity it requires right now.
Updating flags to bubble from the currently-completed node to the parent was relatively straight forward (2b767a4) but both the Profiler durations (c7c0203) and the lanes/childLanes (7f575fa) changes revealed several tricky edge cases, particularly regarding suspense and suspense list APIs.
For now, I'm going to move forward with the initial small change this branch started with (moving resetChildLanes into complete work) and we'll leave the rest for a future refactor if we decide to pick it back up.
Closing in favor of PR #19836
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Milestone
No milestone
Development
Successfully merging this pull request may close these issues.
Uh oh!
There was an error while loading. Please reload this page.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
|