Bug 95219 - Cache and share parsed imported stylesheets
Summary: Cache and share parsed imported stylesheets
Status: REOPENED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks: 77745
  Show dependency treegraph
 
Reported: 2012-08-28 11:07 PDT by Antti Koivisto
Modified: 2012-09-14 12:06 PDT (History)
6 users (show)

See Also:


Attachments
patch (7.16 KB, patch)
2012-08-28 11:18 PDT, Antti Koivisto
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Antti Koivisto 2012-08-28 11:07:01 PDT
We currently cache and share parsed data structures of stylesheets loaded with <link>. We should do the same with stylesheets loaded using @import rules as they are also fairly common.
Comment 1 Antti Koivisto 2012-08-28 11:18:19 PDT
Created attachment 161018 [details]
patch

Mutation-of-shared-import case could probably use a test case. Not sure if that is covered.
Comment 2 Andreas Kling 2012-08-28 11:22:07 PDT
Comment on attachment 161018 [details]
patch

View in context: https://bugs.webkit.org/attachment.cgi?id=161018&action=review

Awesome. r=me

> Source/WebCore/css/StyleRuleImport.cpp:62
> -void StyleRuleImport::setCSSStyleSheet(const String& url, const KURL& baseURL, const String& charset, const CachedCSSStyleSheet*)
> +void StyleRuleImport::setCSSStyleSheet(const String& url, const KURL& baseURL, const String& charset, const CachedCSSStyleSheet* )

ORLY?
Comment 3 Antti Koivisto 2012-08-30 04:07:36 PDT
http://trac.webkit.org/changeset/127123

Turned out we have test coverage for import mutations too.
Comment 4 Alexey Proskuryakov 2012-09-14 12:06:12 PDT
Rolled out in <http://trac.webkit.org/changeset/128637>, because this depended on an earlier patch that had to be rolled out.