Mir

Android overlay mode ping-pongs constantly when touchspots or software cursor is visible, causing stuttering and lag

Bug #1373696 reported by Daniel van Vugt
26
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mir
Won't Fix
High
Unassigned
mir-android-platform
New
Undecided
Unassigned
mir (Ubuntu)
Won't Fix
High
Unassigned

Bug Description

Bypass/overlay mode ping-pongs constantly during touches with touchspots enabled, or when using a mouse (software cursor on Android). This visibly means the screen is stuttering and jerky.

This is a lesser form of bug 1373689, which has a workaround about to land...

$ bin/mir_demo_server_minimal --enable-touchspots --compositor-report=log
# (and also start a fullscreen client from elsewhere)

[1411611407.207459] (II) compositor: Started
[1411611407.230898] (II) compositor: Added display 0x1123d48: 768x1280 +0+0
[1411611407.236148] (II) compositor: Display 0x1123d48 bypass OFF
[1411611410.060412] (II) compositor: Display 0x1123d48 bypass ON
[1411611410.996746] (II) compositor: Display 0x1123d48 averaged 56.652 FPS, 11.493 ms/frame, latency 0.741 ms, 57 frames over 1.006 sec, 98% bypassed
[1411611411.998852] (II) compositor: Display 0x1123d48 averaged 59.875 FPS, 10.765 ms/frame, latency 0.305 ms, 60 frames over 1.002 sec, 100% bypassed
[1411611412.584721] (II) compositor: Display 0x1123d48 bypass OFF
[1411611412.599981] (II) compositor: Display 0x1123d48 bypass ON
[1411611412.677534] (II) compositor: Display 0x1123d48 bypass OFF
[1411611412.683699] (II) compositor: Display 0x1123d48 bypass ON
[1411611412.771628] (II) compositor: Display 0x1123d48 bypass OFF
[1411611412.783500] (II) compositor: Display 0x1123d48 bypass ON
[1411611412.874756] (II) compositor: Display 0x1123d48 bypass OFF
[1411611412.883577] (II) compositor: Display 0x1123d48 bypass ON
[1411611412.972513] (II) compositor: Display 0x1123d48 bypass OFF
[1411611412.983714] (II) compositor: Display 0x1123d48 bypass ON

Workaround: Start your Mir server with --disable-overylays=1

Related branches

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

The strange thing about this bug (and why it is a bug) is that the type, number and ordering of renderables is not changing from frame to frame. Therefore whether or not any of them get overlaid should not change at all from frame to frame either.

Changed in mir:
assignee: nobody → Cemil Azizoglu (cemil-azizoglu)
assignee: Cemil Azizoglu (cemil-azizoglu) → nobody
assignee: nobody → Robert Carr (robertcarr)
Revision history for this message
Kevin DuBois (kdub) wrote :

This is probably due to: lp: #1339749, where the hwc overlay doesn't detect movement-only updates (just buffer updates) and will reject the second of two subsequent commits that it thinks are the same.

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

Removed duplicate link. I'm not arguing its that it's not essentially the same issue, just that the other bug lacks sufficient information for any casual reader (including myself) to realize that it is the same bug.

Still, one fix for both should do it...

Changed in mir:
assignee: Robert Carr (robertcarr) → Kevin DuBois (kdub)
status: Triaged → In Progress
milestone: none → 0.8.0
Revision history for this message
Kevin DuBois (kdub) wrote :

After investigating the other bug, it seems like too much of a code refactoring in the hwc code to undertake now.

Its also worth noting that this scenario only happens when the touchspot is the object that is driving the screen update. If you have other buffer-updating clients in the background, it forces a gl composition much less frequently.

Changed in mir:
status: In Progress → Confirmed
Changed in mir:
milestone: 0.8.0 → 0.9.0
Changed in mir:
milestone: 0.9.0 → 0.10.0
summary: Bypass/overlay mode ping-pongs constantly during touches with touchspots
- enabled
+ enabled, causing screen flickering and lag of touchspots
tags: added: overlays
Changed in mir:
importance: Medium → High
status: Confirmed → Triaged
assignee: Kevin DuBois (kdub) → nobody
summary: - Bypass/overlay mode ping-pongs constantly during touches with touchspots
+ Overlay mode ping-pongs constantly during touches with touchspots
enabled, causing screen flickering and lag of touchspots
Changed in mir:
milestone: 0.10.0 → 0.11.0
Revision history for this message
Kevin DuBois (kdub) wrote : Re: Overlay mode ping-pongs constantly during touches with touchspots enabled, causing screen flickering and lag of touchspots

I'm wading into code refactoring in the hwc classes for multimonitor, will keep this bug in mind.

summary: - Overlay mode ping-pongs constantly during touches with touchspots
- enabled, causing screen flickering and lag of touchspots
+ Overlay mode ping-pongs constantly with touchspots or software cursor
+ enabled, causing screen flickering and lag
Changed in mir:
milestone: 0.11.0 → 0.12.0
tags: added: performance
Kevin DuBois (kdub)
Changed in mir:
milestone: 0.12.0 → 0.13.0
Changed in mir (Ubuntu):
status: New → Triaged
importance: Undecided → High
Changed in mir:
milestone: 0.13.0 → 0.14.0
Revision history for this message
Daniel van Vugt (vanvugt) wrote : Re: Overlay mode ping-pongs constantly with touchspots or software cursor enabled, causing screen flickering and lag

Got caught by this bug again today when using a mouse plugged into an arale. Very jerky when moving the software cursor around.

And again, --disable-overylays=1 fixes it.

summary: - Overlay mode ping-pongs constantly with touchspots or software cursor
- enabled, causing screen flickering and lag
+ Android overlay mode ping-pongs constantly with touchspots or software
+ cursor enabled, causing stuttering and lag
tags: added: android
description: updated
description: updated
Changed in mir:
milestone: 0.14.0 → 0.15.0
Revision history for this message
Daniel van Vugt (vanvugt) wrote : Re: Android overlay mode ping-pongs constantly with touchspots or software cursor enabled, causing stuttering and lag

Still happening in the latest lp:mir on arale. The stuttering makes visual performance testing impossible (because I'm testing overlay-specific behaviour)...

[1435312854.762844] compositor: Display 0xae645fc0 bypass ON
[1435312854.785469] compositor: Display 0xae645fc0 bypass OFF
[1435312854.798907] compositor: Display 0xae645fc0 bypass ON
[1435312854.808670] compositor: Display 0xae645fc0 bypass OFF
[1435312854.825228] compositor: Display 0xae645fc0 bypass ON
[1435312854.831306] compositor: Display 0xae645fc0 bypass OFF
[1435312854.847606] compositor: Display 0xae645fc0 bypass ON
[1435312855.318806] compositor: Display 0xae645fc0 bypass OFF
[1435312855.339301] compositor: Display 0xae645fc0 bypass ON
[1435312855.362100] compositor: Display 0xae645fc0 bypass OFF
[1435312855.382456] compositor: Display 0xae645fc0 bypass ON
[1435312855.396474] compositor: Display 0xae645fc0 bypass OFF

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

Weirdly, the introduction of "predictive bypass" in Mir 0.15 seems to have provided a workaround. To get the bug back, just disable predictive bypass: --composite-delay=0

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

Hmm, no. The bug is still happening in proving server :P

Changed in mir:
milestone: 0.15.0 → 0.16.0
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

I'd like to see this fixed, but we have no definite plans to aim for a particular milestone.

Changed in mir:
milestone: 0.16.0 → none
description: updated
summary: - Android overlay mode ping-pongs constantly with touchspots or software
- cursor enabled, causing stuttering and lag
+ Android overlay mode ping-pongs constantly when touchspots or software
+ cursor is visible, causing stuttering and lag
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

The Android platform was deleted from lp:mir at revision 4155.

Changed in mir:
status: Triaged → Won't Fix
Changed in mir (Ubuntu):
status: Triaged → Won't Fix
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.