RESOLVED FIXED 119475
Inserting a rule into an empty style sheet shouldn't trigger style recalc unless necessary.
https://bugs.webkit.org/show_bug.cgi?id=119475
Summary Inserting a rule into an empty style sheet shouldn't trigger style recalc unl...
Andreas Kling
Reported 2013-08-04 00:28:28 PDT
Inserting a rule into an empty style sheet shouldn't trigger style recalc.
Attachments
Patch idea (4.79 KB, patch)
2013-08-04 00:31 PDT, Andreas Kling
koivisto: review+
Crazier patch idea (8.14 KB, patch)
2013-08-04 03:26 PDT, Andreas Kling
buildbot: commit-queue-
Archive of layout-test-results from webkit-ews-05 for mac-mountainlion (1.23 MB, application/zip)
2013-08-04 05:56 PDT, Build Bot
no flags
Archive of layout-test-results from webkit-ews-06 for mac-mountainlion (1.22 MB, application/zip)
2013-08-04 06:54 PDT, Build Bot
no flags
Slightly less crazy patch idea (15.05 KB, patch)
2013-08-04 07:39 PDT, Andreas Kling
no flags
Wider patch idea (15.38 KB, patch)
2013-08-04 07:43 PDT, Andreas Kling
koivisto: review+
Radar WebKit Bug Importer
Comment 1 2013-08-04 00:28:39 PDT
Andreas Kling
Comment 2 2013-08-04 00:31:37 PDT
Created attachment 208080 [details] Patch idea
Andreas Kling
Comment 3 2013-08-04 03:26:34 PDT
Created attachment 208085 [details] Crazier patch idea Another approach. This one supports multiple insertions.
Andreas Kling
Comment 4 2013-08-04 03:55:40 PDT
Comment on attachment 208085 [details] Crazier patch idea Actually, this is not quite correct. The existing invalidation analysis would not detect insertion into a non-empty active sheet, and fail to trigger recalc in that case.
Build Bot
Comment 5 2013-08-04 05:56:03 PDT
Comment on attachment 208085 [details] Crazier patch idea Attachment 208085 [details] did not pass mac-ews (mac): Output: http://webkit-queues.appspot.com/results/1342794 New failing tests: media/track/track-css-user-override.html inspector/styles/undo-add-new-rule.html http/tests/css/shared-stylesheet-mutation.html http/tests/misc/acid3.html inspector/styles/styles-add-new-rule.html css3/filters/custom/custom-filter-property-computed-style.html fast/shapes/shape-inside/shape-inside-simple-polygon-001.html fast/shapes/shape-inside/shape-inside-regular-polygon16.html fast/shapes/shape-inside/shape-inside-outside-shape.html http/tests/css/shared-stylesheet-mutation-preconstruct.html fast/shapes/shape-inside/shape-inside-simple-polygon-003.html css3/filters/filter-property-computed-style.html fast/css/pseudo-valid-dynamic.html fast/shapes/shape-inside/shape-inside-regular-polygon8.html fast/media/mq-pixel-ratio-print.html fast/shapes/shape-inside/shape-inside-simple-polygon-004.html fast/shapes/shape-inside/shape-inside-simple-polygon-002.html
Build Bot
Comment 6 2013-08-04 05:56:05 PDT
Created attachment 208089 [details] Archive of layout-test-results from webkit-ews-05 for mac-mountainlion The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: webkit-ews-05 Port: mac-mountainlion Platform: Mac OS X 10.8.4
Build Bot
Comment 7 2013-08-04 06:54:34 PDT
Comment on attachment 208085 [details] Crazier patch idea Attachment 208085 [details] did not pass mac-ews (mac): Output: http://webkit-queues.appspot.com/results/1333761 New failing tests: media/track/track-css-user-override.html inspector/styles/undo-add-new-rule.html http/tests/css/shared-stylesheet-mutation.html http/tests/misc/acid3.html inspector/styles/styles-add-new-rule.html css3/filters/custom/custom-filter-property-computed-style.html fast/shapes/shape-inside/shape-inside-simple-polygon-001.html fast/shapes/shape-inside/shape-inside-regular-polygon16.html fast/shapes/shape-inside/shape-inside-outside-shape.html http/tests/css/shared-stylesheet-mutation-preconstruct.html fast/shapes/shape-inside/shape-inside-simple-polygon-003.html css3/filters/filter-property-computed-style.html fast/css/pseudo-valid-dynamic.html fast/shapes/shape-inside/shape-inside-regular-polygon8.html fast/media/mq-pixel-ratio-print.html fast/shapes/shape-inside/shape-inside-simple-polygon-004.html fast/shapes/shape-inside/shape-inside-simple-polygon-002.html
Build Bot
Comment 8 2013-08-04 06:54:37 PDT
Created attachment 208090 [details] Archive of layout-test-results from webkit-ews-06 for mac-mountainlion The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: webkit-ews-06 Port: mac-mountainlion Platform: Mac OS X 10.8.4
Andreas Kling
Comment 9 2013-08-04 07:39:41 PDT
Created attachment 208091 [details] Slightly less crazy patch idea
Andreas Kling
Comment 10 2013-08-04 07:43:31 PDT
Created attachment 208092 [details] Wider patch idea
Antti Koivisto
Comment 11 2013-08-04 08:32:51 PDT
Comment on attachment 208092 [details] Wider patch idea Nice. r=me
Antti Koivisto
Comment 12 2013-08-04 08:41:32 PDT
Comment on attachment 208080 [details] Patch idea Might be good to land the simple version first
Andreas Kling
Comment 13 2013-08-04 08:56:19 PDT
Note You need to log in before you can comment on or make changes to this bug.