https://bugs.freedesktop.org/show_bug.cgi?id=106736

            Bug ID: 106736
           Summary: Xwayland halves *visible* screen update rate
           Product: Wayland
           Version: unspecified
          Hardware: Other
                OS: All
            Status: NEW
          Severity: normal
          Priority: medium
         Component: XWayland
          Assignee: wayland-bugs@lists.freedesktop.org
          Reporter: eero.t.tammi...@intel.com
        QA Contact: xorg-t...@lists.x.org

Setup:
- Intel Skylake or BXT HW
- Git versions of:
  - kernel (supports atomic modesetting)
  - X server / Xwayland
  - Mesa
  - Weston
  (latest releases may be enough, but hasn't been tested)
- New enough dependencies for above, so that modifiers are supported
- X Benchmarks running with Vsync turned off, e.g. GpuTest v0.7

Test-case:
- Start Weston with --xwayland
- Start windowed Benchmark that runs on given HW at approximately 1.5x speed
compared to monitor refresh rate (e.g. ~90FPS benchmark on 60Hz monitor) [1]
- Monitor at which frequency Weston composites the application frames [2]
- Do similar test also on X, e.g. under Ubuntu Unity

Expected outcome:
- Both X and Weston compositors update application frames to screen at monitor
frequency (60Hz)

Actual outcome:
- Benchmark itself runs at about same speed under both windowing systems
- X compositor does app frame updates at expected rate (60)
- Xwayland causes Weston to do updates at half the rate (30)

Notes:
- Benchmark itself can even run a bit faster on Weston than on X, e.g. because
compositor memory bandwidth overhead is smaller when it does less updates. 
It's just that users sees only every 3rd frame of them...
- Xwayland should forward the frames immediately, but it's almost like frames
were Vsynched to display refresh *twice* (with some extra delay added
in-between to guarantee that FPS drops from expected 60 to 30 FPS)
- I've seen similar issue with benchmarks running at 5-120FPS, 90 FPS is just
where it's easiest to see. After benchmark goes >120 FPS, both X and Weston do
compositor updates at 60 FPS.
- The same issue could be there also when application is Vsynched, I haven't
investigated that (Vsync makes it harder to notice / investigate)

Most of the games (e.g. in Steam) don't support Wayland natively, so they get
run through Xwayland.  Games are often run with Vsync disabled, for higher FPS.
 This bug really ruins their performance, which hinders Wayland adoption.


[1] First select GpuTest benchmark that is close enough, and then change window
size to fine-tune the perf to your HW
[2] I'm monitoring whole system updates by tracing user-space kprobes set to
buffer swap functions in all 3D libraries.  Simpler method could be starting
Weston with Mesa LIBGL_SHOW_FPS=true option and redirecting its output to a
file  monitored with "tail -f".

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
wayland-bugs mailing list
wayland-bugs@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/wayland-bugs

Reply via email to