[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kwin
Subject:    Re: Review Request: Finally really fix the XSYNC implementation
From:       Martin_Gräßlin <kde () martin-graesslin ! com>
Date:       2011-08-12 7:52:37
Message-ID: 20110812075237.19869.48096 () vidsolbach ! de
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/102311/#review5656
-----------------------------------------------------------


omg - I will have a look at it and test it, when I am back from Berlin tomorrow. And \
I agree that one should go into master pretty soon. Let's see maybe it will even be \
something for 4.7.3?

- Martin


On Aug. 12, 2011, 12:50 a.m., Thomas Lübking wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/102311/
> -----------------------------------------------------------
> 
> (Updated Aug. 12, 2011, 12:50 a.m.)
> 
> 
> Review request for kwin and Martin Gräßlin.
> 
> 
> Summary
> -------
> 
> <assume some very angry rant about the "protocol", it's authors and the author of \
> the original patch here> 
> I finally got along, looking depper into this.
> So far, the kwin implementation did hardly more than wasting resources.
> 
> => changes:
> a) ensure to NEVER send a second sync request while one's still pending (leading to \
> the issues back then) b) trigger a resize of the targetted geometry before \
> requesting the sync (so the client actually syncs to the proper size and is there \
> when we release the mutex) c) skip all moveResizeHandle calls while there's a \
> pending sync (the client's not done anyway and we cannot send a sync request) d) \
> move the *request* from "performMoveResize" into handleMoveResize, replace \
> "syncTimeout" (great name) with "performMoveResize" and have it do exactly that. e) \
> don't new QTimer; delete QTimer with every size change - it's on the heap.... f) \
> reduce the timeout to 250ms. waiting 500ms for the client is _completely_ \
> inacceptable. if it cannot keep pace: bad luck. but having the user to wait half a \
> second makes him feel "oh, blast. crashed." g) fix tileset #ifdef (the geometry \
> _has_ to be set esp. if there's no tiling at all) 
> ==> todo:
> - I thought about using the compositor to perform a texture scale while we're \
> waiting for the client (but the client/effectwindow would have to keep \
>                 "realGeometry" vs. "visualGeometry" for this
> - look around whether XSYNC preproc checks are sufficient
> - attempt to drop the second XMoveResize call for the window() WId (since it \
>                 happened with the sync request)
> - add a checkbox: "don't use xsync protocol" - frankly, this thing is so much wonky \
> by design that i'd nearly say to remove support completely. 
> For the records (maybe i should add a comment in the code?)
> - two sync requests on the stack will break it. no way to re-sync.
> - one should aparently trigger the client resize before starting the sync request. \
>                 otherwise the entire thing is pointless.
> - sending the configure notifications is important. don't ask me why, but w/o the \
> client will stop sending sync events just like in the above case 
> 
> Diffs
> -----
> 
> kwin/client.h 93510ec 
> kwin/client.cpp 46c8eff 
> kwin/events.cpp f523bf7 
> kwin/geometry.cpp 51ed034 
> 
> Diff: http://git.reviewboard.kde.org/r/102311/diff
> 
> 
> Testing
> -------
> 
> yes.
> no more white edges in konsole (but for timeouts).
> no issues with clemens qclock testcase (which blocks painting for some hundred ms) \
> - scaling is smooth, blocks (as expected) and smoothly continues afterwards. 
> nevertheless, i'd like to have this in master as soon as possible (also before \
> "playing around" for performance locally) and hopefully a lot of testing... 
> 
> Thanks,
> 
> Thomas
> 
> 


[Attachment #5 (text/html)]

<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 \
solid;">  <tr>
     <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="http://git.reviewboard.kde.org/r/102311/">http://git.reviewboard.kde.org/r/102311/</a>
  </td>
    </tr>
   </table>
   <br />





 <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">omg - I will have a look \
at it and test it, when I am back from Berlin tomorrow. And I agree that one should \
go into master pretty soon. Let&#39;s see maybe it will even be something for \
4.7.3?</pre>  <br />







<p>- Martin</p>


<br />
<p>On August 12th, 2011, 12:50 a.m., Thomas Lübking wrote:</p>






<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" \
style="background-image: \
url('http://git.reviewboard.kde.org/media/rb/images/review_request_box_top_bg.png'); \
background-position: left top; background-repeat: repeat-x; border: 1px black \
solid;">  <tr>
  <td>

<div>Review request for kwin and Martin Gräßlin.</div>
<div>By Thomas Lübking.</div>


<p style="color: grey;"><i>Updated Aug. 12, 2011, 12:50 a.m.</i></p>




<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: \
1px solid #b8b5a0">  <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">&lt;assume some very angry rant about the &quot;protocol&quot;, it&#39;s \
authors and the author of the original patch here&gt;

I finally got along, looking depper into this.
So far, the kwin implementation did hardly more than wasting resources.

=&gt; changes:
a) ensure to NEVER send a second sync request while one&#39;s still pending (leading \
to the issues back then) b) trigger a resize of the targetted geometry before \
requesting the sync (so the client actually syncs to the proper size and is there \
when we release the mutex) c) skip all moveResizeHandle calls while there&#39;s a \
pending sync (the client&#39;s not done anyway and we cannot send a sync request) d) \
move the *request* from &quot;performMoveResize&quot; into handleMoveResize, replace \
&quot;syncTimeout&quot; (great name) with &quot;performMoveResize&quot; and have it \
do exactly that. e) don&#39;t new QTimer; delete QTimer with every size change - \
it&#39;s on the heap.... f) reduce the timeout to 250ms. waiting 500ms for the client \
is _completely_ inacceptable. if it cannot keep pace: bad luck. but having the user \
to wait half a second makes him feel &quot;oh, blast. crashed.&quot; g) fix tileset \
#ifdef (the geometry _has_ to be set esp. if there&#39;s no tiling at all)

==&gt; todo:
- I thought about using the compositor to perform a texture scale while we&#39;re \
waiting for the client (but the client/effectwindow would have to keep \
                &quot;realGeometry&quot; vs. &quot;visualGeometry&quot; for this
- look around whether XSYNC preproc checks are sufficient
- attempt to drop the second XMoveResize call for the window() WId (since it happened \
                with the sync request)
- add a checkbox: &quot;don&#39;t use xsync protocol&quot; - frankly, this thing is \
so much wonky by design that i&#39;d nearly say to remove support completely.

For the records (maybe i should add a comment in the code?)
- two sync requests on the stack will break it. no way to re-sync.
- one should aparently trigger the client resize before starting the sync request. \
                otherwise the entire thing is pointless.
- sending the configure notifications is important. don&#39;t ask me why, but w/o the \
client will stop sending sync events just like in the above case</pre>  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: \
1px solid #b8b5a0">  <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">yes. no more white edges in konsole (but for timeouts).
no issues with clemens qclock testcase (which blocks painting for some hundred ms) - \
scaling is smooth, blocks (as expected) and smoothly continues afterwards.

nevertheless, i&#39;d like to have this in master as soon as possible (also before \
&quot;playing around&quot; for performance locally) and hopefully a lot of \
testing...</pre>  </td>
 </tr>
</table>




<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>kwin/client.h <span style="color: grey">(93510ec)</span></li>

 <li>kwin/client.cpp <span style="color: grey">(46c8eff)</span></li>

 <li>kwin/events.cpp <span style="color: grey">(f523bf7)</span></li>

 <li>kwin/geometry.cpp <span style="color: grey">(51ed034)</span></li>

</ul>

<p><a href="http://git.reviewboard.kde.org/r/102311/diff/" style="margin-left: \
3em;">View Diff</a></p>




  </td>
 </tr>
</table>








  </div>
 </body>
</html>



_______________________________________________
kwin mailing list
kwin@kde.org
https://mail.kde.org/mailman/listinfo/kwin


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic