Chromium Code Reviews
DescriptionAvoid initializing a SecurityOrigin from a KURL for isSecure() check.
Initializing a SecurityOrigin is not cheap. We should avoid it where possible.
Initialization causes
- Looking up the origin in a map (blobs)
- FastMalloc the origin
- Many calls to StringImpl::lower() which causes allocation
- HashMap lookups for e.g. shouldTreatURLSchemeAsLocal
This saves ~1% overhead off of resource requesting.
BUG=348655
Committed: https://crrev.com/616c7df79bbc2d892ecee0305dff57a0faaf80a2
Cr-Commit-Position: refs/heads/master@{#425946}
Patch Set 1 #
Messages
Total messages: 14 (7 generated)
|
|||||||||||||||||||||||||||||||||||||