Mir

NBS causes sudden loss of performance after un-fullscreening a swap interval zero client

Bug #1557442 reported by Daniel van Vugt
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mir
Fix Released
Medium
Kevin DuBois
mir (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

NBS causes loss of frame dropping after un-fullscreening a window. When this occurs, the client only ever sees 2 buffers instead of 3, and so starts getting incorrectly sync'd to the screen:

[2016-03-15 18:29:08.885810] perf: mir_demo_client_camera.bin: 186.81 FPS, render time 5.16ms, buffer lag 9.79ms (3 buffers)
[2016-03-15 18:29:09.889336] perf: mir_demo_client_camera.bin: 187.43 FPS, render time 5.21ms, buffer lag 10.06ms (3 buffers)
[2016-03-15 18:29:10.892904] perf: mir_demo_client_camera.bin: 187.43 FPS, render time 5.13ms, buffer lag 9.99ms (3 buffers)
[2016-03-15 18:29:11.896299] perf: mir_demo_client_camera.bin: 187.43 FPS, render time 5.22ms, buffer lag 9.91ms (3 buffers)
[2016-03-15 18:29:12.906866] perf: mir_demo_client_camera.bin: 170.29 FPS, render time 4.80ms, buffer lag 11.10ms (15 buffers)
[2016-03-15 18:29:13.907306] perf: mir_demo_client_camera.bin: 60.00 FPS, render time 0.16ms, buffer lag 33.12ms (20 buffers)
[2016-03-15 18:29:14.908295] perf: mir_demo_client_camera.bin: 60.00 FPS, render time 0.12ms, buffer lag 33.23ms (4 buffers)
[2016-03-15 18:29:15.908972] perf: mir_demo_client_camera.bin: 60.00 FPS, render time 0.12ms, buffer lag 33.23ms (2 buffers)
[2016-03-15 18:29:16.909945] perf: mir_demo_client_camera.bin: 60.00 FPS, render time 0.12ms, buffer lag 33.24ms (2 buffers)
[2016-03-15 18:29:17.910827] perf: mir_demo_client_camera.bin: 60.00 FPS, render time 0.13ms, buffer lag 33.23ms (2 buffers)
[2016-03-15 18:29:18.911693] perf: mir_demo_client_camera.bin: 60.00 FPS, render time 0.13ms, buffer lag 33.22ms (2 buffers)
[2016-03-15 18:29:19.912521] perf: mir_demo_client_camera.bin: 60.00 FPS, render time 0.13ms, buffer lag 33.22ms (2 buffers)
[2016-03-15 18:29:20.913369] perf: mir_demo_client_camera.bin: 60.00 FPS, render time 0.13ms, buffer lag 33.22ms (2 buffers)

Related branches

Revision history for this message
Daniel van Vugt (vanvugt) wrote : Re: NBS causes loss of frame dropping (loss of frame rate) after resizing the window

The curious part if NBS only offers the client 2 buffers after it's been resized. So that's why the client can't perform framedropping any more.

description: updated
summary: - NBS causes loss of frame dropping after resizing the window
+ NBS causes loss of frame dropping (loss of frame rate) after resizing
+ the window
description: updated
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Another test case that's a bit easier:

$ sudo env MIR_CLIENT_PERF_REPORT=log glmark2-mir --fullscreen -b texture
=======================================================
    glmark2 2014.03+git20150611.fa71af2d
=======================================================
    OpenGL Information
    GL_VENDOR: Intel Open Source Technology Center
    GL_RENDERER: Mesa DRI Intel(R) Haswell Desktop
    GL_VERSION: 3.0 Mesa 11.1.2
=======================================================
[texture] <default>:[2016-03-16 16:43:31.520145] perf: : 1230.00 FPS, render time 0.52ms, buffer lag 1.89ms (3 buffers)
[2016-03-16 16:43:32.520374] perf: : 1259.00 FPS, render time 0.44ms, buffer lag 1.93ms (3 buffers)
[2016-03-16 16:43:33.520666] perf: : 1273.00 FPS, render time 0.44ms, buffer lag 1.91ms (3 buffers)
[2016-03-16 16:43:34.520962] perf: : 1276.00 FPS, render time 0.45ms, buffer lag 1.90ms (3 buffers)
[2016-03-16 16:43:35.532160] perf: : 446.09 FPS, render time 0.46ms, buffer lag 4.68ms (34 buffers)
*** Move/resize the window ***
[2016-03-16 16:43:36.533017] perf: : 60.00 FPS, render time 0.15ms, buffer lag 33.20ms (2 buffers)
[2016-03-16 16:43:37.533866] perf: : 60.00 FPS, render time 0.19ms, buffer lag 33.17ms (2 buffers)
[2016-03-16 16:43:38.534718] perf: : 60.00 FPS, render time 0.14ms, buffer lag 33.21ms (2 buffers)
[2016-03-16 16:43:39.535568] perf: : 60.00 FPS, render time 0.14ms, buffer lag 33.21ms (2 buffers)
^C FPS: 623 FrameTime: 1.605 ms
=======================================================
                                  glmark2 Score: 623
=======================================================

description: updated
summary: - NBS causes loss of frame dropping (loss of frame rate) after resizing
- the window
+ NBS causes loss of performance after un-fullscreening
Revision history for this message
Daniel van Vugt (vanvugt) wrote : Re: NBS causes loss of performance after un-fullscreening

Looks related to bug 1557962. In both cases, an insufficient number of buffers are being given to the client.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

The sweet spot for reproducing this bug seems to be clients that do < ~1500 FPS. If a client performs higher than that then it apparently won't hit this bug.

summary: - NBS causes loss of performance after un-fullscreening
+ NBS causes sudden loss of performance after un-fullscreening a swap
+ interval zero client
Revision history for this message
Kevin DuBois (kdub) wrote :

seems reasonable that this is a dup of 1557962

Changed in mir:
assignee: nobody → Kevin DuBois (kdub)
importance: Undecided → Medium
status: New → Fix Committed
milestone: none → 0.22.0
Changed in mir:
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package mir - 0.22.1+16.04.20160516.2-0ubuntu2

---------------
mir (0.22.1+16.04.20160516.2-0ubuntu2) yakkety; urgency=medium

  [ Dimitri John Ledkov ]
  * Fix FTBFS error: call of overloaded ‘abs(float)’ is ambiguous, by
    including cmath c++ header.

 -- Łukasz 'sil2100' Zemczak <email address hidden> Thu, 19 May 2016 21:58:43 +0200

Changed in mir (Ubuntu):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.