<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>111627</bug_id>
          
          <creation_ts>2013-03-06 14:41:21 -0800</creation_ts>
          <short_desc>recalcStyle() with a Detach styleDiff calculates style twice</short_desc>
          <delta_ts>2014-04-10 22:10:21 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Layout and Rendering</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>INVALID</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          <dependson>113123</dependson>
    
    <dependson>115042</dependson>
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Eric Seidel (no email)">eric</reporter>
          <assigned_to name="Elliott Sprehn">esprehn</assigned_to>
          <cc>allan.jensen</cc>
    
    <cc>buildbot</cc>
    
    <cc>cmarcelo</cc>
    
    <cc>darin</cc>
    
    <cc>dglazkov</cc>
    
    <cc>esprehn+autocc</cc>
    
    <cc>esprehn</cc>
    
    <cc>hyatt</cc>
    
    <cc>koivisto</cc>
    
    <cc>macpherson</cc>
    
    <cc>menard</cc>
    
    <cc>ojan.autocc</cc>
    
    <cc>rniwa</cc>
    
    <cc>simon.fraser</cc>
    
    <cc>webkit.review.bot</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>849313</commentid>
    <comment_count>0</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2013-03-06 14:41:21 -0800</bug_when>
    <thetext>recalcStyle() with a Detach styleDiff calculates style twice

As noted in:
https://bugs.webkit.org/show_bug.cgi?id=111494#c16

This is extra-bad, because I believe using lazyAttach will always go down this code path.  Fixing this could be as much as an 8% win on html5-full-render, if it cuts our style-resolves in half. :)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>849465</commentid>
    <comment_count>1</comment_count>
      <attachid>191867</attachid>
    <who name="Elliott Sprehn">esprehn</who>
    <bug_when>2013-03-06 16:51:37 -0800</bug_when>
    <thetext>Created attachment 191867
Patch</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>849467</commentid>
    <comment_count>2</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2013-03-06 16:53:52 -0800</bug_when>
    <thetext>I&apos;m not sure this is the solution we want to go with long-term. :)  But it would appear to solve the bug.

Do you have any perf data to show this is a win?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>849479</commentid>
    <comment_count>3</comment_count>
    <who name="Ryosuke Niwa">rniwa</who>
    <bug_when>2013-03-06 16:58:06 -0800</bug_when>
    <thetext>There got to be a better way of doing this?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>849487</commentid>
    <comment_count>4</comment_count>
    <who name="Elliott Sprehn">esprehn</who>
    <bug_when>2013-03-06 16:59:26 -0800</bug_when>
    <thetext>(In reply to comment #2)
&gt; I&apos;m not sure this is the solution we want to go with long-term. :)  But it would appear to solve the bug.
&gt; 
&gt; Do you have any perf data to show this is a win?

I&apos;m having issues getting the perf tests to not hang after running them, but I did a few runs and it didn&apos;t seem like it was a win at all on html5-full-render.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>849494</commentid>
    <comment_count>5</comment_count>
    <who name="Elliott Sprehn">esprehn</who>
    <bug_when>2013-03-06 17:01:38 -0800</bug_when>
    <thetext>(In reply to comment #3)
&gt; There got to be a better way of doing this?

It requires considerable amounts of plumbing since we&apos;d need to pass the style from recalcStyle =&gt; reattach =&gt; attach =&gt; createRendererIfNeeded =&gt; NodeRenderingContext::createRendererForElementIfNeeded() which finally calls styleForRenderer().

I guess we could use the same class and use the style in createRendererForElementIfNeeded instead though which means StyleResolver doesn&apos;t need this knowledge, and it would work for PseudoElements too.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>849495</commentid>
    <comment_count>6</comment_count>
      <attachid>191867</attachid>
    <who name="Antti Koivisto">koivisto</who>
    <bug_when>2013-03-06 17:02:12 -0800</bug_when>
    <thetext>Comment on attachment 191867
Patch

That&apos;s just too ugly. I have a patch somewhere that fixes this properly, by passing the style to attach().</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>849503</commentid>
    <comment_count>7</comment_count>
      <attachid>191867</attachid>
    <who name="Elliott Sprehn">esprehn</who>
    <bug_when>2013-03-06 17:10:17 -0800</bug_when>
    <thetext>Comment on attachment 191867
Patch

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

&gt; Source/WebCore/css/StyleResolver.cpp:1388
&gt; +        return style;

If we did this approach, this code should be inside NodeRenderingContext::createRendererForElementIfNeeded</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>849532</commentid>
    <comment_count>8</comment_count>
    <who name="Elliott Sprehn">esprehn</who>
    <bug_when>2013-03-06 17:36:08 -0800</bug_when>
    <thetext>Ran perf tests for html5-full-render:

With this caching:
3202.66	± 0.23%
3205.94	± 0.17%

Without this caching:
3198.89	± 0.24%
3202.49	± 0.12%

So, surprisingly, it doesn&apos;t seem to really matter. I guess there&apos;s caching stuff down inside StyleResolver already?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>849545</commentid>
    <comment_count>9</comment_count>
      <attachid>191867</attachid>
    <who name="WebKit Review Bot">webkit.review.bot</who>
    <bug_when>2013-03-06 17:49:36 -0800</bug_when>
    <thetext>Comment on attachment 191867
Patch

Attachment 191867 did not pass chromium-ews (chromium-xvfb):
Output: http://webkit-commit-queue.appspot.com/results/17062114

New failing tests:
fast/css/pseudo-empty-dynamic-empty.html
fast/events/drag-display-none-element.html
fast/selectors/empty-element-made-non-empty.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>849550</commentid>
    <comment_count>10</comment_count>
      <attachid>191867</attachid>
    <who name="Build Bot">buildbot</who>
    <bug_when>2013-03-06 17:56:05 -0800</bug_when>
    <thetext>Comment on attachment 191867
Patch

Attachment 191867 did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-commit-queue.appspot.com/results/17062117

New failing tests:
fast/css/pseudo-empty-dynamic-empty.html
http/tests/misc/acid3.html
fast/selectors/empty-element-made-non-empty.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>849994</commentid>
    <comment_count>11</comment_count>
    <who name="Allan Sandfeld Jensen">allan.jensen</who>
    <bug_when>2013-03-07 05:34:57 -0800</bug_when>
    <thetext>(In reply to comment #8)
&gt; Ran perf tests for html5-full-render:
&gt; 
&gt; With this caching:
&gt; 3202.66    ± 0.23%
&gt; 3205.94    ± 0.17%
&gt; 
&gt; Without this caching:
&gt; 3198.89    ± 0.24%
&gt; 3202.49    ± 0.12%
&gt; 
&gt; So, surprisingly, it doesn&apos;t seem to really matter. I guess there&apos;s caching stuff down inside StyleResolver already?

It only caches in the sense that it will reuse the calculated style of a sibling if the elements are similar enough. To get a performance improvement you probably need to trigger a style that is unique.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>850305</commentid>
    <comment_count>12</comment_count>
    <who name="Antti Koivisto">koivisto</who>
    <bug_when>2013-03-07 11:14:23 -0800</bug_when>
    <thetext>&gt; So, surprisingly, it doesn&apos;t seem to really matter. I guess there&apos;s caching stuff down inside StyleResolver already?

StyleResolver has multiple levels of caches. Also the case just doesn&apos;t generally get hit that much. When reattach() gets called the whole subtree under the element will get attached outside recalcStyle without hitting the double calculation case. I have yet to see a real case where this is practical problem. It would still be nice to fix it as it is silly.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>850405</commentid>
    <comment_count>13</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2013-03-07 13:01:06 -0800</bug_when>
    <thetext>(In reply to comment #12)
&gt; &gt; So, surprisingly, it doesn&apos;t seem to really matter. I guess there&apos;s caching stuff down inside StyleResolver already?
&gt; 
&gt; Also the case just doesn&apos;t generally get hit that much. When reattach() gets called the whole subtree under the element will get attached outside recalcStyle without hitting the double calculation case.

Ah!  this is the key bit I was missing.  My understanding is lazyAttach() puts us into this state all the time.  But it doesn&apos;t end up showing up because we only double-style-calc for the root most element of a subtree.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>850779</commentid>
    <comment_count>14</comment_count>
      <attachid>191867</attachid>
    <who name="Build Bot">buildbot</who>
    <bug_when>2013-03-07 19:34:00 -0800</bug_when>
    <thetext>Comment on attachment 191867
Patch

Attachment 191867 did not pass mac-ews (mac):
Output: http://webkit-commit-queue.appspot.com/results/17081252

New failing tests:
fast/css/pseudo-empty-dynamic-empty.html
fast/events/drag-display-none-element.html
http/tests/misc/acid3.html
fast/selectors/empty-element-made-non-empty.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>861148</commentid>
    <comment_count>15</comment_count>
    <who name="Elliott Sprehn">esprehn</who>
    <bug_when>2013-03-21 23:38:41 -0700</bug_when>
    <thetext>(In reply to comment #14)
&gt; (From update of attachment 191867 [details])
&gt; Attachment 191867 [details] did not pass mac-ews (mac):
&gt; Output: http://webkit-commit-queue.appspot.com/results/17081252
&gt; 
&gt; New failing tests:
&gt; fast/css/pseudo-empty-dynamic-empty.html
&gt; fast/events/drag-display-none-element.html
&gt; http/tests/misc/acid3.html
&gt; fast/selectors/empty-element-made-non-empty.html

These failures have me pretty confused. Apparently when calling styleForRenderer() inside Element::recalcStyle we get a different style than we would when later calling it inside NodeRenderingContext.

Specifically:

style1 = styleForRenderer();
detach();
style2 = styleForRenderer();

These two styles don&apos;t have the same properties which breaks the idea of passing the style down through the reattach() call.

@antti Do you know what&apos;s going on here?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>861210</commentid>
    <comment_count>16</comment_count>
    <who name="Elliott Sprehn">esprehn</who>
    <bug_when>2013-03-22 01:16:38 -0700</bug_when>
    <thetext>(In reply to comment #15)
&gt; (In reply to comment #14)
&gt;  ...
&gt; 
&gt; These failures have me pretty confused. Apparently when calling styleForRenderer() inside Element::recalcStyle we get a different style than we would when later calling it inside NodeRenderingContext.
&gt; 
&gt; Specifically:
&gt; 
&gt; style1 = styleForRenderer();
&gt; detach();
&gt; style2 = styleForRenderer();
&gt; 
&gt; These two styles don&apos;t have the same properties which breaks the idea of passing the style down through the reattach() call.
&gt; 
&gt; @antti Do you know what&apos;s going on here?

Hmm, I&apos;m wrong, there&apos;s something else weird going on here I&apos;m missing. :/</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>861730</commentid>
    <comment_count>17</comment_count>
    <who name="Elliott Sprehn">esprehn</who>
    <bug_when>2013-03-22 11:55:02 -0700</bug_when>
    <thetext>(In reply to comment #16)
&gt; ...
&gt; 
&gt; Hmm, I&apos;m wrong, there&apos;s something else weird going on here I&apos;m missing. :/

Figured this out. We used to store the affectedBy bits in the RenderStyle, but now we store them in the ElementRareData and reset them in detach() which means calling styleForRenderer in recalcStyle sets a bunch of bits, but then detach() inside reattach() clears the affectedBy bits so we get a RenderStyle but none of the correct affectedBy bits. 

So we need to tell detach() not to clear the bits so we get the right values since we&apos;re not going to call styleForRenderer() again to set them.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>861783</commentid>
    <comment_count>18</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2013-03-22 13:00:43 -0700</bug_when>
    <thetext>These are some of the side effects of style resolve which we&apos;ll need to make explicit. Dimitri and I were just musing about this yesterday.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>861978</commentid>
    <comment_count>19</comment_count>
    <who name="Elliott Sprehn">esprehn</who>
    <bug_when>2013-03-22 16:52:10 -0700</bug_when>
    <thetext>(In reply to comment #18)
&gt; These are some of the side effects of style resolve which we&apos;ll need to make explicit. Dimitri and I were just musing about this yesterday.

Yeah. So not calling resetComputedStyle() inside detach() (from reattach) fixes some of the tests, but I&apos;m still stuck for  LayoutTests/fast/events/drag-display-none-element.html

This test fails because the paragraph remains hidden. I tried not calling resetDynamicRestyleObservations but that doesn&apos;t seem to help.

I need to figure out what other shared state change happened inside style recalc.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>862042</commentid>
    <comment_count>20</comment_count>
    <who name="Elliott Sprehn">esprehn</who>
    <bug_when>2013-03-22 17:58:25 -0700</bug_when>
    <thetext>This would be resolved by passing the context in Bug 113123</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>862046</commentid>
    <comment_count>21</comment_count>
    <who name="Elliott Sprehn">esprehn</who>
    <bug_when>2013-03-22 18:01:23 -0700</bug_when>
    <thetext>(In reply to comment #19)
&gt; (In reply to comment #18)
&gt; &gt; These are some of the side effects of style resolve which we&apos;ll need to make explicit. Dimitri and I were just musing about this yesterday.
&gt; 
&gt; Yeah. So not calling resetComputedStyle() inside detach() (from reattach) fixes some of the tests, but I&apos;m still stuck for  LayoutTests/fast/events/drag-display-none-element.html
&gt; 
&gt; This test fails because the paragraph remains hidden. I tried not calling resetDynamicRestyleObservations but that doesn&apos;t seem to help.
&gt; 
&gt; I need to figure out what other shared state change happened inside style recalc.

I figured this out btw, it&apos;s because SelectorChecker looks at the renderer for isDragging to set some state which is different after detach() since we lose the renderer. We should probably break that dependency.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>879887</commentid>
    <comment_count>22</comment_count>
    <who name="Antti Koivisto">koivisto</who>
    <bug_when>2013-04-23 09:24:20 -0700</bug_when>
    <thetext>http://trac.webkit.org/changeset/148970 fixed the most common instance of this problem.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>191867</attachid>
            <date>2013-03-06 16:51:37 -0800</date>
            <delta_ts>2013-03-07 19:34:00 -0800</delta_ts>
            <desc>Patch</desc>
            <filename>bug-111627-20130306164742.patch</filename>
            <type>text/plain</type>
            <size>4516</size>
            <attacher name="Elliott Sprehn">esprehn</attacher>
            
              <data encoding="base64">U3VidmVyc2lvbiBSZXZpc2lvbjogMTQ1MDAwCmRpZmYgLS1naXQgYS9Tb3VyY2UvV2ViQ29yZS9D
aGFuZ2VMb2cgYi9Tb3VyY2UvV2ViQ29yZS9DaGFuZ2VMb2cKaW5kZXggYWY0ZDIxNGI3ZTcyNmNl
OTg2YWU2NWRkMDExYzNjNjE3OGZjN2ZjYy4uNWRiYWUyYTdkYjhmMjk1MzhmOWU1YzgxMWJjMzUy
ZjJkNGRjMmZjNCAxMDA2NDQKLS0tIGEvU291cmNlL1dlYkNvcmUvQ2hhbmdlTG9nCisrKyBiL1Nv
dXJjZS9XZWJDb3JlL0NoYW5nZUxvZwpAQCAtMSwzICsxLDI2IEBACisyMDEzLTAzLTA2ICBFbGxp
b3R0IFNwcmVobiAgPGVzcHJlaG5AY2hyb21pdW0ub3JnPgorCisgICAgICAgIHJlY2FsY1N0eWxl
KCkgd2l0aCBhIERldGFjaCBzdHlsZURpZmYgY2FsY3VsYXRlcyBzdHlsZSB0d2ljZQorICAgICAg
ICBodHRwczovL2J1Z3Mud2Via2l0Lm9yZy9zaG93X2J1Zy5jZ2k/aWQ9MTExNjI3CisKKyAgICAg
ICAgUmV2aWV3ZWQgYnkgTk9CT0RZIChPT1BTISkuCisKKyAgICAgICAgQ2FjaGUgdGhlIGNvbXB1
dGVkIHN0eWxlIGJlZm9yZSBjYWxsaW5nIHJlYXR0YWNoKCkgaW4gRWxlbWVudDo6cmVjYWxjU3R5
bGUuCisgICAgICAgIFRoaXMgbWVhbnMgd2UgZG9uJ3QgbmVlZCB0byBkbyBzdHlsZSByZXNvbHV0
aW9uIHR3aWNlIGZvciBldmVyeSBsYXp5CisgICAgICAgIGF0dGFjaGVkIGVsZW1lbnQgZHVyaW5n
IHBhZ2UgbG9hZC4KKworICAgICAgICBOb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1lbnQ6OnJlY2FsY1N0eWxlKFN0eWxlQ2hhbmdlIGNoYW5nZSkKICAgICAgICAgUmVmUHRy
PFJlbmRlclN0eWxlPiBuZXdTdHlsZSA9IHN0eWxlRm9yUmVuZGVyZXIoKTsKICAgICAgICAgU3R5
bGVDaGFuZ2UgY2ggPSBOb2RlOjpkaWZmKGN1cnJlbnRTdHlsZS5nZXQoKSwgbmV3U3R5bGUuZ2V0
KCksIGRvY3VtZW50KCkpOwogICAgICAgICBpZiAoY2ggPT0gRGV0YWNoIHx8ICFjdXJyZW50U3R5
bGUpIHsKLSAgICAgICAgICAgIC8vIEZJWE1FOiBUaGUgc3R5bGUgZ2V0cyBjb21wdXRlZCB0d2lj
ZSBieSBjYWxsaW5nIGF0dGFjaC4gV2UgY291bGQgZG8gYmV0dGVyIGlmIHdlIHBhc3NlZCB0aGUg
c3R5bGUgYWxvbmcuCisgICAgICAgICAgICAvLyBGSVhNRTogVGhpcyBkb2Vzbid0IGNhY2hlIGZv
ciBwc2V1ZG8gZWxlbWVudHMuCisgICAgICAgICAgICBDYWNoZWRTdHlsZUZvclJlYXR0YWNoIGNh
Y2hlZFN0eWxlKHRoaXMsIG5ld1N0eWxlLmdldCgpKTsKICAgICAgICAgICAgIHJlYXR0YWNoKCk7
CiAgICAgICAgICAgICAvLyBhdHRhY2ggcmVjYWxjdWxhdGVzIHRoZSBzdHlsZSBmb3IgYWxsIGNo
aWxkcmVuLiBObyBuZWVkIHRvIGRvIGl0IHR3aWNlLgogICAgICAgICAgICAgY2xlYXJOZWVkc1N0
eWxlUmVjYWxjKCk7Cg==
</data>
<flag name="commit-queue"
          id="212950"
          type_id="3"
          status="-"
          setter="webkit.review.bot"
    />
          </attachment>
      

    </bug>

</bugzilla>