[webkit-changes] [WebKit/WebKit] 20f1c3: Don't try to deduplicate SVG presentation attribut...

Antti Koivisto noreply at github.com
Thu Feb 15 04:28:20 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 20f1c3fa6bbff1049237054dba3666ea8680d138
      https://github.com/WebKit/WebKit/commit/20f1c3fa6bbff1049237054dba3666ea8680d138
  Author: Antti Koivisto <antti at apple.com>
  Date:   2024-02-15 (Thu, 15 Feb 2024)

  Changed paths:
    M Source/JavaScriptCore/runtime/JSGlobalObject.cpp
    M Source/WebCore/css/MutableStyleProperties.cpp
    M Source/WebCore/css/MutableStyleProperties.h
    M Source/WebCore/css/StyleProperties.cpp
    M Source/WebCore/dom/StyledElement.cpp
    M Source/WebCore/style/ElementRuleCollector.cpp

  Log Message:
  -----------
  Don't try to deduplicate SVG presentation attribute style that is likely unique
https://bugs.webkit.org/show_bug.cgi?id=269439
<rdar://problem/122994878>

Reviewed by Ryosuke Niwa.

* Source/WebCore/css/MutableStyleProperties.cpp:
(WebCore::MutableStyleProperties::immutableCopy const):
(WebCore::MutableStyleProperties::immutableDeduplicatedCopy const):
* Source/WebCore/css/MutableStyleProperties.h:
* Source/WebCore/css/StyleProperties.cpp:
(WebCore::StyleProperties::immutableCopyIfNeeded const):
* Source/WebCore/dom/StyledElement.cpp:
(WebCore::StyledElement::rebuildPresentationalHintStyle):

SVG x/y attributes rarely repeat so avoid deduplication work if they are present.

* Source/WebCore/style/ElementRuleCollector.cpp:
(WebCore::Style::ElementRuleCollector::matchAllRules):

Mark SVG properties that are shared much between elements uncacheable to avoid cache bloat.

Canonical link: https://commits.webkit.org/274715@main




More information about the webkit-changes mailing list