<?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>111644</bug_id>
          
          <creation_ts>2013-03-06 16:40:25 -0800</creation_ts>
          <short_desc>[meta] RecalcStyle accounts for too much time on the main thread</short_desc>
          <delta_ts>2017-07-18 08:27:19 -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>NEW</bug_status>
          <resolution></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>113097</dependson>
    
    <dependson>37688</dependson>
    
    <dependson>89879</dependson>
    
    <dependson>111494</dependson>
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Eric Seidel (no email)">eric</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>eae</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>849455</commentid>
    <comment_count>0</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2013-03-06 16:40:25 -0800</bug_when>
    <thetext>[meta] RecalcStyle accounts for too much time on the main thread

In previous of Telemetry using Chromium content_shell on an Android device, we see style recalc taking up as much as 24% of total mainthread time.

https://docs.google.com/spreadsheet/ccc?key=0AlC4tS7Ao1fIdGtJTWlSaUItQ1hYaDFDcWkzeVAxOGc#gid=0
is a very run, but I will add more recent runs in further comments.

This is a meta bug to track planned work of making this take up less main-thread time.  I expect we will take several approaches, including:
- Remove unnecessary recalcs (by deferring the work as much as possible)
- Make parts of recalc faster (for example canShareStyleWith() is very very hot)
- Explore radical ideas such as making style recalc resume-able (resolve only as much of the docuement as is needed to answer a specific query) or computable by parallel threads.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>