mesa::DisplayBuffer::post_update is triple buffered - more laggy than it needs to be
Bug #1350725 reported by
Daniel van Vugt
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mir |
Fix Released
|
Medium
|
Daniel van Vugt | ||
mir (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Our DisplayBuffer implementation for Mesa/desktop is actually triple buffered, making it one frame more laggy than it needs to be. This was intentional because it's required to allow cloned displays to keep up (waiting for all vblanks may take an extra 16ms).
But we don't need to keep it always-on. We can revert to double buffering in the common case where cloning is not active by adding this to the bottom of mesa::DisplayBu
if (outputs.size() == 1)
Making this change results in a noticeable improvement in responsiveness when dragging windows around.
Related branches
lp://staging/~vanvugt/mir/mesa-double
- PS Jenkins bot (community): Approve (continuous-integration)
- Robert Carr (community): Approve
- Alexandros Frantzis (community): Approve
- Alan Griffiths: Approve
- Cemil Azizoglu: Pending requested
-
Diff: 126 lines (+57/-8)3 files modifiedsrc/platforms/mesa/display_buffer.cpp (+25/-0)
tests/unit-tests/graphics/mesa/test_display.cpp (+2/-1)
tests/unit-tests/graphics/mesa/test_display_buffer.cpp (+30/-7)
description: | updated |
Changed in mir: | |
milestone: | none → 0.9.0 |
status: | Triaged → In Progress |
Changed in mir: | |
milestone: | 0.9.0 → 0.10.0 |
Changed in mir: | |
milestone: | none → 0.10.0 |
status: | Triaged → In Progress |
Changed in mir: | |
milestone: | 0.10.0 → 0.11.0 |
Changed in mir: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
Just re-tested this, and while still true, discovered a problem.
My high-end quad-core i7 system can't keep up with compositing if I throw 10+ triangles at it use enable double-buffering. It requires the display buffer to remain triple buffered to keep up. Sounds like we need to work on the efficiency of our compositing before it's feasible to resolve this bug, if ever.