<?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>58098</bug_id>
          
          <creation_ts>2011-04-07 16:52:28 -0700</creation_ts>
          <short_desc>Optimize filling rounded rects that are actually ellipses</short_desc>
          <delta_ts>2011-06-01 14:49:16 -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>WebCore Misc.</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>Mac (Intel)</rep_platform>
          <op_sys>OS X 10.6</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</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>
          
          
          <everconfirmed>0</everconfirmed>
          <reporter name="Ian Henderson">ian</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>commit-queue</cc>
    
    <cc>eric</cc>
    
    <cc>simon.fraser</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>381849</commentid>
    <comment_count>0</comment_count>
    <who name="Ian Henderson">ian</who>
    <bug_when>2011-04-07 16:52:28 -0700</bug_when>
    <thetext>In CG, drawing an ellipse directly is faster than constructing and filling a rounded rect path.  We should optimize fillRoundedRect in the case that it&apos;s just drawing an ellipse.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>381850</commentid>
    <comment_count>1</comment_count>
      <attachid>88734</attachid>
    <who name="Ian Henderson">ian</who>
    <bug_when>2011-04-07 16:53:57 -0700</bug_when>
    <thetext>Created attachment 88734
proposed patch</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>382005</commentid>
    <comment_count>2</comment_count>
    <who name="WebKit Commit Bot">commit-queue</who>
    <bug_when>2011-04-07 22:37:32 -0700</bug_when>
    <thetext>The commit-queue encountered the following flaky tests while processing attachment 88734:

http/tests/inspector/console-websocket-error.html bug 57392 (authors: pfeldman@chromium.org and yutak@chromium.org)
The commit-queue is continuing to process your patch.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>382006</commentid>
    <comment_count>3</comment_count>
      <attachid>88734</attachid>
    <who name="WebKit Commit Bot">commit-queue</who>
    <bug_when>2011-04-07 22:39:10 -0700</bug_when>
    <thetext>Comment on attachment 88734
proposed patch

Clearing flags on attachment: 88734

Committed r83253: &lt;http://trac.webkit.org/changeset/83253&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>382007</commentid>
    <comment_count>4</comment_count>
    <who name="WebKit Commit Bot">commit-queue</who>
    <bug_when>2011-04-07 22:39:16 -0700</bug_when>
    <thetext>All reviewed patches have been landed.  Closing bug.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>382013</commentid>
    <comment_count>5</comment_count>
    <who name="WebKit Commit Bot">commit-queue</who>
    <bug_when>2011-04-07 22:59:18 -0700</bug_when>
    <thetext>The commit-queue encountered the following flaky tests while processing attachment 88734:

animations/suspend-resume-animation.html bug 48161 (author: cmarrin@apple.com)
The commit-queue is continuing to process your patch.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>413613</commentid>
    <comment_count>6</comment_count>
    <who name="Simon Fraser (smfr)">simon.fraser</who>
    <bug_when>2011-06-01 13:20:59 -0700</bug_when>
    <thetext>I think this change broke filling circles in canvas when there is a gradient pattern, since the code no longer goes through the fillPath() logic</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>413623</commentid>
    <comment_count>7</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2011-06-01 13:36:14 -0700</bug_when>
    <thetext>Why is fillRoundedRect ever drawing an ellipse?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>413663</commentid>
    <comment_count>8</comment_count>
    <who name="Simon Fraser (smfr)">simon.fraser</who>
    <bug_when>2011-06-01 14:20:52 -0700</bug_when>
    <thetext>border-radius: 50%</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>413673</commentid>
    <comment_count>9</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2011-06-01 14:31:04 -0700</bug_when>
    <thetext>(In reply to comment #8)
&gt; border-radius: 50%

Is that really the case we&apos;re optimizing for?  I can see how it would be *much* faster to let CG do the elipse, but seems like an odd motivation for this change.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>413679</commentid>
    <comment_count>10</comment_count>
    <who name="Simon Fraser (smfr)">simon.fraser</who>
    <bug_when>2011-06-01 14:42:38 -0700</bug_when>
    <thetext>Drawing circles with css border-radius is fairly common, and some benchmarks to it. I think it&apos;s worth the optimization.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>413684</commentid>
    <comment_count>11</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2011-06-01 14:49:16 -0700</bug_when>
    <thetext>OK.  I&apos;ll have to trust you on this one. :)  Does seem like an easy way to draw a circle in CSS.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>88734</attachid>
            <date>2011-04-07 16:53:57 -0700</date>
            <delta_ts>2011-04-07 22:39:10 -0700</delta_ts>
            <desc>proposed patch</desc>
            <filename>58098-1.patch</filename>
            <type>text/plain</type>
            <size>2499</size>
            <attacher name="Ian Henderson">ian</attacher>
            
              <data encoding="base64">SW5kZXg6IFNvdXJjZS9XZWJDb3JlL0NoYW5nZUxvZwo9PT09PT09PT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ci0tLSBTb3VyY2UvV2Vi
Q29yZS9DaGFuZ2VMb2cJKHJldmlzaW9uI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