<?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>99592</bug_id>
          
          <creation_ts>2012-10-17 06:42:15 -0700</creation_ts>
          <short_desc>Add WebGraphicsContext3D::WebGraphicsUpdateVSyncTimeCallbackCHROMIUM</short_desc>
          <delta_ts>2012-10-24 09:05:06 -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>New Bugs</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>WONTFIX</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="Ali Juma">ajuma</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>backer</cc>
    
    <cc>nduca</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>744209</commentid>
    <comment_count>0</comment_count>
      <attachid>169172</attachid>
    <who name="Ali Juma">ajuma</who>
    <bug_when>2012-10-17 06:42:15 -0700</bug_when>
    <thetext>Created attachment 169172
Patch

This is needed for Chromium issue 143466 (http://crbug.com/143466).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>744432</commentid>
    <comment_count>1</comment_count>
      <attachid>169172</attachid>
    <who name="Brian Anderson">brianderson</who>
    <bug_when>2012-10-17 11:14:57 -0700</bug_when>
    <thetext>Comment on attachment 169172
Patch

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

&gt; Source/Platform/chromium/public/WebGraphicsContext3D.h:147
&gt; +        virtual void onUpdateVSyncTime(int64_t) = 0;

Can you use a more descriptive variable name so we know what the units are?
Do you need two arguments (one for phase and one for frequency)?

Also, other parts of the code have started moving towards base::TimeTicks and base::TimeDeltas.  I&apos;m not sure those are allowed in WebGraphicsContext3D.h though.  If they are, we should use those instead.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>744435</commentid>
    <comment_count>2</comment_count>
      <attachid>169172</attachid>
    <who name="Nat Duca">nduca</who>
    <bug_when>2012-10-17 11:17:24 -0700</bug_when>
    <thetext>Comment on attachment 169172
Patch

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

&gt; Source/Platform/chromium/public/WebGraphicsContext3D.h:145
&gt; +    class WebGraphicsUpdateVSyncTimeCallbackCHROMIUM {

why do you need this? Can&apos;t you use the output surface system?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>744605</commentid>
    <comment_count>3</comment_count>
    <who name="Ali Juma">ajuma</who>
    <bug_when>2012-10-17 14:14:39 -0700</bug_when>
    <thetext>(In reply to comment #2)
&gt; (From update of attachment 169172 [details])
&gt; View in context: https://bugs.webkit.org/attachment.cgi?id=169172&amp;action=review
&gt; 
&gt; &gt; Source/Platform/chromium/public/WebGraphicsContext3D.h:145
&gt; &gt; +    class WebGraphicsUpdateVSyncTimeCallbackCHROMIUM {
&gt; 
&gt; why do you need this? Can&apos;t you use the output surface system?

One big advantage of the new approach is that it works without modification for sending vsync updates to renderers on desktop Linux (whenever OML_GLX_sync_control is available). The downside of adapting this approach to go through the existing path is that the result will be Aura-specific.

To avoid having two different paths for updating vsync state, we could move the existing code to the new path. This would mean that the GPU process would always be responsible for pushing out vsync updates to all compositors; in situations (as we currently have) where the browser process is the original source of this information, the browser would send the information to the GPU process and the GPU process would pass it on to renderers. Thoughts on this?


(In reply to comment #1)
&gt; (From update of attachment 169172 [details])
&gt; View in context: https://bugs.webkit.org/attachment.cgi?id=169172&amp;action=review
&gt; 
&gt; &gt; Source/Platform/chromium/public/WebGraphicsContext3D.h:147
&gt; &gt; +        virtual void onUpdateVSyncTime(int64_t) = 0;
&gt; 
&gt; Do you need two arguments (one for phase and one for frequency)?

Yes, there should also be an argument for frequency (but note that OML_GLX_sync_control is currently not providing frequency information on Chrome OS devices).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>744607</commentid>
    <comment_count>4</comment_count>
    <who name="Nat Duca">nduca</who>
    <bug_when>2012-10-17 14:17:35 -0700</bug_when>
    <thetext>Linux platforms are the only platforms where vsync originates in the gpu process. Everywhere else, its available in the browser process. So, I see the linuxes plumbing as a special case.

We dont have a wgc3d in software mode, but we do have vsync. So, the use of outputsurface has to stay.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>744609</commentid>
    <comment_count>5</comment_count>
    <who name="Nat Duca">nduca</who>
    <bug_when>2012-10-17 14:18:46 -0700</bug_when>
    <thetext>Also, the gpu process pushing vsync to compositors adds additional hops in the propagation of the signal on platforms where the signal is directly available. These hops have queuing delays, which while short in the minimum case, are very noisy and can often have 5ms bursts in them. No good.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>749723</commentid>
    <comment_count>6</comment_count>
    <who name="Ali Juma">ajuma</who>
    <bug_when>2012-10-24 09:05:06 -0700</bug_when>
    <thetext>This is no longer needed for Chromium issue 143466 since we&apos;re going to use the existing output surface system instead.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>169172</attachid>
            <date>2012-10-17 06:42:15 -0700</date>
            <delta_ts>2012-10-17 11:17:24 -0700</delta_ts>
            <desc>Patch</desc>
            <filename>WebKitPatchForIssue143466</filename>
            <type>text/plain</type>
            <size>1483</size>
            <attacher name="Ali Juma">ajuma</attacher>
            
              <data encoding="base64">ZGlmZiAtLWdpdCBhL1NvdXJjZS9QbGF0Zm9ybS9jaHJvbWl1bS9wdWJsaWMvV2ViR3J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