Skip to content

Conversation

@sebmarkbage
Copy link
Collaborator

Rename "Suspended" commit to "Suspended on CSS" since that's the only reason for this particular branch. This will not hold true because with suspended images and with view transitions those can also be the reason. So in the future we need to add those.

Only log "Blocked" in the components track if we yield for 3ms or longer. It's common to have like 1-2ms yield times for various reasons going on which is not worth the noise to consider "blocking".

Rename "Blocked" to "Update" in the Blocking/Transition tracks. This is when a setState happens and with stack traces it's where you should look for the stack trace of the setState. So we want to indicate that this is the "Update".

I only added the "Blocked" part if we're blocked for more than 5ms before we can start rendering - indicating that some other track was working at the same time and preventing us from rendering.

… reason

This will not hold true because with suspended images and with view transitions those can also be the reason.
So in the future we need to add those.
It's common to have like 1-2ms yield times for various reasons going on
which is not worth the noise to consider "blocking".
This is when a setState happens and with stack traces it's where you should
look for the stack trace of the setState.

I only added the "Blocked" part if we're blocked for more than 5ms indicating
that some other track was working at the same time and preventing us from
rendering.
@sebmarkbage sebmarkbage changed the title Perftweaks Minor Tweak to Performance Track Apr 2, 2025
@github-actions github-actions bot added the React Core Team Opened by a member of the React Core Team label Apr 2, 2025
@react-sizebot
Copy link

Comparing: 040f828...3e15165

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.83 kB 1.83 kB
oss-stable/react-dom/cjs/react-dom-client.production.js = 515.56 kB 515.56 kB = 91.84 kB 91.84 kB
oss-experimental/react-dom/cjs/react-dom.production.js = 6.69 kB 6.69 kB = 1.83 kB 1.83 kB
oss-experimental/react-dom/cjs/react-dom-client.production.js = 616.30 kB 616.30 kB = 109.03 kB 109.03 kB
facebook-www/ReactDOM-prod.classic.js = 650.16 kB 650.16 kB = 114.89 kB 114.89 kB
facebook-www/ReactDOM-prod.modern.js = 640.44 kB 640.44 kB = 113.33 kB 113.33 kB

Significant size changes

Includes any change greater than 0.2%:

(No significant changes)

Generated by 🚫 dangerJS against 3e15165

? 'Cascading Update'
: renderStartTime - updateTime > 5
? 'Update Blocked'
: 'Update',
Copy link
Member

Choose a reason for hiding this comment

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

I was thinking "Scheduled" which also makes sense since it's the Scheduler track

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It's tricky because the time span really mean that but it actually doubles as a "mark" too in the beginning which is the update. It's just that marks are kind of useless in this UI since they 1) stack on top of the span 2) are impossible to click. Where as the span is easier to see and click. Even if it's very small.

@sebmarkbage sebmarkbage merged commit b2f6365 into facebook:main Apr 2, 2025
243 checks passed
github-actions bot pushed a commit that referenced this pull request Apr 2, 2025
Rename "Suspended" commit to "Suspended on CSS" since that's the only
reason for this particular branch. This will not hold true because with
suspended images and with view transitions those can also be the reason.
So in the future we need to add those.

Only log "Blocked" in the components track if we yield for 3ms or
longer. It's common to have like 1-2ms yield times for various reasons
going on which is not worth the noise to consider "blocking".

Rename "Blocked" to "Update" in the Blocking/Transition tracks. This is
when a setState happens and with stack traces it's where you should look
for the stack trace of the setState. So we want to indicate that this is
the "Update".

I only added the "Blocked" part if we're blocked for more than 5ms
before we can start rendering - indicating that some other track was
working at the same time and preventing us from rendering.

DiffTrain build for [b2f6365](b2f6365)
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