NonBlockingSwapTesting

CLOSED

This wiki has been left up for reference, but the modification to alter swap buffer calls to be non-blocking has landed in Mir v0.1.9, which was promoted to Utopic on May1 in Touch image #7. Thanks to all who provided feedback.

Testing Non Blocking EGLSwapBuffers and Qt exposeEvent

To solve the problem of Qt5.2 queuing events due to gui thread blocking on EGLSwapBuffers, we're working on altering Mir to not block on swapbuffers in the instance of occluded apps & screen off and relying on the shell to enforce the toolkit side channel to halt rendering.

Given that this is a significant behavioral change we're proceeding with some caution and hoping to get some additional testing. At the moment we have branches available which to deliver the desired change. We welcome anyone who would like to help out by testing.

Results so far

Nexus 4

Music App team contacted to say they found this change solves their problems, seeing no other side effects. Also, additional feedback from a handful of individuals on Mir and Unity teams indicating it seems to be working and no additional problems. Focus on launching apps, switching and screen on/off.

Nexus 10

Tested by 2 folks, no additional problems seem to be introduced. Testing focus was around sidestage elements. Power off, on, hiding sidestage, exposing etc.

Desktop

SDL2 on Mir tested, no new bugs or problems discovered. http://i.imgur.com/e2xRZ2i.png

Tested with Xmir for several hours on Intel w/ integrated graphics (mobile4 series rev7). No functional problems.

Further Background

How To Test

We're using our CI Train build silo's as a way to keep up with the latest image and iterate over the proposed branches. note: we will continue to polish & fix bugs we find on the branches, so the packages may update.

Current silo is https://launchpad.net/~ci-train-ppa-service/+archive/landing-003.

note: silo's sometimes get reallocated, so the package location may change, so double check its mir, qtubuntu, platform-api, unity-mir, unity-system-compositor in this location.

Steps to install

  1. flash your device with the latest devel-proposed image, assuming you're already setup, connect your host machine to device usb
    • host-computer$ adb reboot bootloader

      host-computer$ ubuntu-device-flash --channel=devel-proposed --bootstrap

    for more information on devices, flashing & setup see https://wiki.ubuntu.com/Touch/Install

  2. Don't forget to connect to the network & make writable

    • host-computer$ phablet-network 

      host-computer$ phablet-config writable-image 

      host-computer$ adb reboot 

  3. Add the PPA to your device
    • device-phablet$ adb shell apt-add-repository -y ppa:ci-train-ppa-service/landing-003 

      device-phablet$ adb shell apt-get update 

  4. While you may apt-get dist-upgrade to install, you will pull in other packages, i recommend installing in isolation like so
    • device-phablet$  adb shell apt-get install libmirclient7 libmirclientplatform-android libmirplatform libmirplatformgraphics-android libmirprotobuf0 libmirserver19 mir-utils libplatform-api1-hybris libplatform-hardware-api1-hybris libubuntu-application-api-mirclient1 libubuntu-application-api-mirserver1 libubuntu-application-api1 libubuntu-platform-hardware-api1 qthybris qtubuntu-android libunity-mir1 unity-system-compositor 

What to test

Just about anything. But primarily, this is a change pertaining to applications and their render loops when the screen is turned off, on, and when applications are occluded (aka "pushed back in the stack"). As such the most useful tests are around opening/using applications then either a) hitting power key to turn display off, b) allowing inactivity timer to turn screen off or c) pushing application back in the stack by launching a new application or choosing an application from the right-edge swipe spread. Then returning to the application by turning the screen on and navigating back to it (in any way: right-edge, select from application scope running app, launcher icon etc.)

We would expect all behaviors of the applications to remain the same as before introducing this change, with of course the improvements or a "fix" for the following: a) music will advance to the next song when the screen is off, b) volume keys have an effect with screen off, c) alarms set will fire and alert when screen is off, and d) the "stale" frame on lockscreen after screen-on is no longer present.

Symptoms that we don't expect but you might witness: freezing apps, applications seeming to "continue" unexpectedly with the screen off, or unexpected rendering from an application.

Logging Bugs

If you find what you think is a bug potentially due to this change, please check the known bugs for this silo first. You can check here https://bugs.launchpad.net/bugs/+bugs?field.searchtext=nonblockswap. Please use the tag "nonblockswap". Please note the applications you've launched, relative amount of times the application has been stopped through screen-off or pushed back in the stack. Also, please note the version of the packages you tested since we plan to be updating those as we fix bugs. You can do this by noting in the bug output from

  • device-phablet$  sudo apt-cache policy libmirplatform 

    device-phablet$  sudo apt-cache policy libubuntu-application-api-mirclient1 

    device-phablet$  sudo apt-cache policy qtubuntu-android 

    device-phablet$  sudo apt-cache policy libunity-mir1 

    device-phablet$  sudo apt-cache policy unity-system-compositor 

You can note the image number from

  • device-root#  sudo system-image-cli -i

Contact us

If you're not sure if somethings a bug or need help for any reason on directions. Feel free to hit any of us up on IRC freenode #ubuntu-mir at kgunn, camako, AlbertA, alf. Or feel free to email the ubuntu-phone mailing list (ubuntu-phone@lists.launchpad.net).

Mir/NonBlockingSwapTesting (last edited 2014-05-01 19:12:15 by pool-173-64-197-91)