Bug 252045 - Default Sheet Parsing can add delays before requesting main resource
Summary: Default Sheet Parsing can add delays before requesting main resource
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Page Loading (show other bugs)
Version: Safari Technology Preview
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2023-02-10 04:10 PST by Ahmad Saleem
Modified: 2023-02-17 04:11 PST (History)
8 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ahmad Saleem 2023-02-10 04:10:38 PST
Hi Team,

It is just another potential optimisation done in Chrome which I came across and wanted to get input whether similar can be done in WebKit or not:

Blink Commit - https://chromium.googlesource.com/chromium/blink/+/c0aa7538cb054f429822a3f3cc66efe826122b80

WebKit Source - https://searchfox.org/wubkat/source/Source/WebCore/dom/Document.cpp#6387

___

In local testing, it compiles but had to use 'committedFirstRealDocumentLoad', which in case of Blink also got changed later in another commit (can't find it).

I haven't had any metrics to back up whether it works or not but again it is just for discussion on whether something can be done to get faster page loading or it is just placebo using this idea.

Keep making WebKit better.

Thanks!
Comment 1 Antti Koivisto 2023-02-15 04:27:38 PST
Process prewarming initializes the UA stylesheet among other things, see ProcessWarming::prewarmGlobally()
Comment 2 Ben Nham 2023-02-15 22:52:07 PST
I don't think this is a priority since we generally load pages into either a prewarmed WebProcess or an existing WebProcess, both of which will have their default stylesheet already parsed at the point of page load.
Comment 3 Radar WebKit Bug Importer 2023-02-17 04:11:16 PST
<rdar://problem/105592243>