[webkit-changes] [WebKit/WebKit] aea4f3: Shrink StyleRule by reducing padding and moving CS...

Cameron McCormack noreply at github.com
Sun Feb 5 17:45:38 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: aea4f3f29a7c8f7dbf76e52647c30b6cfc4cc464
      https://github.com/WebKit/WebKit/commit/aea4f3f29a7c8f7dbf76e52647c30b6cfc4cc464
  Author: Cameron McCormack <heycam at apple.com>
  Date:   2023-02-05 (Sun, 05 Feb 2023)

  Changed paths:
    M Source/WebCore/css/StyleRule.cpp
    M Source/WebCore/css/StyleRule.h

  Log Message:
  -----------
  Shrink StyleRule by reducing padding and moving CSS Nesting fields to a rare data object
https://bugs.webkit.org/show_bug.cgi?id=251744
rdar://105046580

Reviewed by Simon Fraser.

This reduces StyleRule from 64 to 40 bytes.

* Source/WebCore/css/StyleRule.cpp:
(WebCore::StyleRuleRareData::createIfNeeded):
(WebCore::StyleRule::StyleRule):
(WebCore::StyleRule::rareData const):
(WebCore::StyleRule::setNestedRules):
(WebCore::StyleRule::setResolvedSelectorList const):
(WebCore::emptyRuleVector):
(WebCore::StyleRule::nestedRules const):
* Source/WebCore/css/StyleRule.h:
(WebCore::StyleRuleRareData::createIfNeeded):

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




More information about the webkit-changes mailing list