-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
audit: JavaScript boot-up time is high ⏱ #3105
Comments
I have a few questions about this one before I can start. What do we want to show here? What do we consider boot-up time? Including this data inside the report might be a bit tricky as it's hard to display this kind of data For an overall view per script a pie chart might be useful but you probably lose the raw numbers of the measurements. Perhaps start with a table showing time per category for each script |
Showing overall parse and compile is important for showing the difference in a CPU limited device vs one that isn't, so if we could have 'overall timings' as well as 'per script', that'd be best. I'd say the 'boot up time' is all the scripting involved until TTI. |
At the last team sync, we discussed coming up with a group of "how to serve JS better" audits that could show for each script:
@paulirish Was there anything else we wanted to include in there? |
@brendankenny @patrickhulce I had some time to kill during BlinkOn so threw together a mock for JS opportunities we could bikeshed on. Colors:
I tried to integrate a similar breakdown to the page execution PR in #1695 if you want to understand boot-up time in more depth. These aren't shown by default but are visible as an expandable. |
probably lots of iterating that can be done, but I really like this. Would have loved exactly this doing a perf audit today |
I really like the mockup. Perhaps just go with this to start with? We could improve later on? |
👍 Looking great! We could probably roll up the bootup time into a small split bar graph in order to remove the need for a @addyosmani Nit: Here, it's listed as "bootup time", but elsewhere you've referred to it as "startup". Are you leaning towards one or the other? Could we call it Parse & Compile? or Script time? I feel like we're losing something in "boot up time". |
I like it :) I'm similarly a little confused by what exactly "boot up time" represents. One thing that might be lost by breaking everything down by file is total time spent, but we might be able to break from our traditional table-only details and get creative about surfacing that too. |
In Calibre, I'd probably have an overall timing (on the pulse page), then show the break down on a per script level a bit deeper into the report. Perhaps an overall summary would be useful too? |
This may be a nomenclature issue. Does "start-up" time make more sense? My mock originally had "Parse/Compile/Execution Time" but that felt like a pretty large label to try squeezing in. "Script time" or "Time in JavaScript" could also work.
Perhaps something like this, @benschwarz? @wardpeet Per the last team sync, it sounds like we're okay with focusing on the JS breakdown audits here for the short-term as both #931 and #3106 will require more complex critical-path analysis in order for us to move forward with them. Does that sound good to you? |
Thanks for putting together this mock Addy! Some quick feedback (from a lens of someone slightly more new to performance):
|
I think this is a solid idea. I'll check if we have a good existing article we can point to, otherwise we might need to put together a page in the Lighthouse doc that points to a few different resources.
Yeah. I think we'll need to iterate and agree on the best label to use there. I wouldn't be surprised if folks were confused with "boot-up" or "start-up" time but opting for a clear label sounds reasonable.
Good question. I don't believe the current Lighthouse report uses a color legend for the other colors there (e.g we assume folks know red = bad). Perhaps to stay consistent we should either highlight rows as red or introduce a color legend as you suggested.
"Reduce JavaScript fetch & evaluation time" Sure there are some other variants we can brainstorm too. |
Thanks for the quick feedback! Re: 4, I really like "Reduce time spent fetching & processing JavaScript" OR "Reduce time processing JavaScript." Open to hearing what others think though! :) For next steps, perhaps we can wait for folks to chime in by Friday, and put together a new version of the mock then? Addy- lmk if you need help (not sure if you're using Sketch to put this together) and I'll be happy to help you make changes as well. |
I really like the information this is surfacing here. One quick note based on our goals for what counts as an "Opportunity." What do you guys think about having this per-script breakdown and summary as mocked in "Diagnostics" and surfacing the minification separately as an additional opportunity (since code coverage as an opportunity is already done)? |
We see there are two separate components here. Both are inevitably diagnostics to the user:
Let's do them separately. Let's start with the global execution breakdown. patrick, brendankenny, and me agree on all this ^. @wardpeet sg? |
Addy- do we have any updates on the UX? Want to make sure the UX is ready for Ward so he's not blocked on this :) |
I think all ideas are already in this thread :) We're probably going to have go with a bare-bones first implementation (hidden from the report if it's too rough at first :) For
we could probably just start with a table in Diagnostics. |
Initially focusing on the global execution breakdowns sgtm. Are we aiming to follow this up with the per-script bootup costs shortly after? Keen for us to give developers an answer to the (more actionable) "which scripts should I be looking at reducing time spent in?", but knowing you're spending too long in JS is still p valuable.
Surfacing minification as a separate opportunity sg. I do think (at some point) it might be worth exploring how we can better group categories of JS optimization opportunities better but that can be an exercise for the future :) |
Can we combine these 2 in one audit or wouldn't that be possible due the limitations of the report? I'll start on 1 |
Do we want to only include script related categories in the timing here
(compile, eval, GC etc but not image decodes, parsing styles, html)?
Original intent was raising awareness of the time spent in JS.
Would understand if we wanted this to be slightly broader.
…On Oct 6, 2017 2:23 PM, "Ward Peeters" ***@***.***> wrote:
[image: image]
<https://user-images.githubusercontent.com/1120926/31299119-4b992cf4-aaed-11e7-8578-42b941243724.png>
should I move to lines like perf-metric? Description isn't correct with
global execution either.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#3105 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAGxaQ9_XMtSVhZqzRmonzYObGrZuZJjks5sppppgaJpZM4PAqWJ>
.
|
@wardpeet looks good.
I'd prefer to make sure this includes everything. But in order to help clarify script costs.. I see two solutions here:
Obviously a more involved visualization would help make this data explorable, but this can wait. In this table format I'm also thinking it might be useful to add another column indicating whats typical or flagging particular outliers. ("This is 500% more than the average pageload!") Do we have this data? no. :) But is it an interesting idea @addyosmani ? |
I like the idea of the Task Category column and see that Ward has started implementing it over in #3520. Looking sharp. I do think that we could use some color in there to visually differentiate the different categories but agree that can be done in a follow-up PR.
How important is it that we have this data for each of the categories? With HTTP Archive we do have median and 99th percentile information available on parse/eval times. I think we could extract this for some of the other categories too but we'd have to check. cc @rviscomi as an fyi that this came up. On is this useful/an interesting idea: I think there's value in gut-checking where you're at relative to the industry for some of these timings. I do think we might need to noodle on the design for it. If you think about parse times, the global median for any given page could be 4s. If our table highlighted that you had 5 x scripts, each of which were spending 3s in parse, we'd technically be telling you you're doing fine vs. looking at this in the aggregate (15s). Maybe highlighting this for the entire table would be useful? |
In https://www.fileour.com/ site will be a problem. But it's only like the mobile version. |
Description: JavaScript boot-up time is high (> 4s)
Failure text: JavaScript boot-up time was 12s. This is too high.
Help text: Consider reducing the time spent parsing, compiling and executing JS. You may find delivering smaller JS payloads helps with this.
Overall: Highlight issues with parse/compile/execution time and point to the Performance panel for digging into this deeper.
Related issues: #2535
Could be a proper version of/redux of: #1695
The text was updated successfully, but these errors were encountered: