You are not logged in.

#26 2021-11-02 18:38:56

0BADC0DE
Member
From: Regnum Utriusque Siciliae
Registered: 2018-02-21
Posts: 267

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

Setup
Compositor: Enabled
Scale method: Smooth (vs Accurate)
Rendering backend: OpenGL 3.1 (vs 2.0)
Latency: Balance (vs force lowest, prefer lower, prefer smoother, force smoothest)
Tearing prevention ("vsync"): automatic
Keep window thumbnails: never (vs always, only shown)
Allow applications to block compositing: true

Results
Browsers seem to run smooth (not tested with MS Teams)
Browsers show artifacts during updates, menu drop down
Browsers show artifacts during video playback (even with just builtin monitor)
Video playback (youtube, vlc) has artifacts and frame drops.
Konsole shows good responsiveness w/ artifacts to display fonts (ls -l /etc)

Xorg.log
Here

glxinfo -B
Here

qdbus org.kde.KWin /KWin org.kde.KWin.supportInformation
Here

Last edited by 0BADC0DE (2021-11-02 18:40:19)


Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.

Offline

#27 2021-11-03 03:31:34

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,424

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

That shows that your GL is broken now, it's very possible that GPU never got support for i965 and absolutely depends on iris, in which case you probably want to remove the MESA_LOADER_DRIVER_OVERRIDE=i965 again.

If it isn't better with OpenGL 3.1 in the compositor settings with that removed (... and glxinfo -B showing the real intel opengl again) another suggestion I'd have is to either downgrade mesa to 21.1.6 or actually trying mesa-git or so

Online

#28 2021-11-03 07:58:57

0BADC0DE
Member
From: Regnum Utriusque Siciliae
Registered: 2018-02-21
Posts: 267

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

I disabled KDE compositor altogether because I need my PC to be usable.
I also disabled MESA_LOADER_DRIVER_OVERRIDE.

Xorg.log
glxinfo -B
qdbus org.kde.KWin /KWin org.kde.KWin.supportInformation

Xorg fails to find and load intel module and I think this is OK as I removed the xf86-video-intel package: the wiki clearly says that  xf86-video-intel is unreliable.
glxinfo seems to be OK (but I am not sure).
Compositor is off.

System is barely usable: browsers lag with user interaction. Youtube (as an example) plays just fine.

Last edited by 0BADC0DE (2021-11-03 08:03:56)


Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.

Offline

#29 2021-11-03 10:17:06

0BADC0DE
Member
From: Regnum Utriusque Siciliae
Registered: 2018-02-21
Posts: 267

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

Just installed mesa-git (it took quite looong time!) and activated again the compositor.
And rebooted the PC, just in case.
Nothing changed: graphics is lagging (not the mouse pointer), video (youtube and VLC), any windows opens with a delay.
Lagging is bout 1sec.
Audio is OK, network is OK, terminal console is OK (non-gfx activities are OK then).

I really need to restore decent performances: any hint?

Xorg.log
glxinfo -B
qdbus org.kde.KWin /KWin org.kde.KWin.supportInformation


Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.

Offline

#30 2021-11-03 10:22:24

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,424

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

Something I just noticed, you are still using the Aurorae engine. As far as In know this does have some known perf issues. Try switch to the default breeze window decoration.

See e.g. https://bugs.kde.org/show_bug.cgi?id=431643 and https://bugs.kde.org/show_bug.cgi?id=429336

Last edited by V1del (2021-11-03 10:27:55)

Online

#31 2021-11-03 10:30:16

seth
Member
Registered: 2012-09-03
Posts: 49,975

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

Offline

#32 2021-11-03 11:12:55

0BADC0DE
Member
From: Regnum Utriusque Siciliae
Registered: 2018-02-21
Posts: 267

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

V1del wrote:

Something I just noticed, you are still using the Aurorae engine. As far as In know this does have some known perf issues. Try switch to the default breeze window decoration.

See e.g. https://bugs.kde.org/show_bug.cgi?id=431643 and https://bugs.kde.org/show_bug.cgi?id=429336

Moving away from Plastik decorations to Breeze was devoid of any change in the behaviour. I tested both OpenGL 3.0 and 2.1.
Disabling the compositor altogether gave me a responsive desktop back.


Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.

Offline

#33 2021-11-03 11:21:52

0BADC0DE
Member
From: Regnum Utriusque Siciliae
Registered: 2018-02-21
Posts: 267

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

seth wrote:

On top of that, disable vsync in the kwin setting and also see
https://wiki.archlinux.org/title/Intel_ … on_(VSYNC)

No change.

I disabled xf86-video-intel as per wiki.
Of course I can re-enable it and configure it for DRI2...


Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.

Offline

#34 2021-11-03 11:24:29

seth
Member
Registered: 2012-09-03
Posts: 49,975

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

There's a paragraph on how to disable DRI3 for the modesetting driver.
Did you disable vsync both in the dri config as well as in the kwin settings?

Offline

#35 2021-11-03 11:37:58

0BADC0DE
Member
From: Regnum Utriusque Siciliae
Registered: 2018-02-21
Posts: 267

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

seth wrote:

There's a paragraph on how to disable DRI3 for the modesetting driver.

Done.

seth wrote:

Did you disable vsync both in the dri config as well as in the kwin settings?

Kwin doesn't allow me to disable vsync. I can set it up to "automatic".
Other options are:
  "Only when cheap" (Warning: only prevents tearing for full screen changes like a video)
  "Full screen repaints" (Warning: can cause performance problems)
  "Re-use screen content" (Warning: causes severe performance problems on MESA drivers)

They all sound scary, don't they?


Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.

Offline

#36 2021-11-03 12:03:15

seth
Member
Registered: 2012-09-03
Posts: 49,975

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

"Only when cheap" along "KWIN_USE_BUFFER_AGE=0" should™ prevent vertical sync under most circumstances.
Do not use the last option, reading the frontbuffer is very slow w/ mesa.

Offline

#37 2021-11-03 12:38:11

0BADC0DE
Member
From: Regnum Utriusque Siciliae
Registered: 2018-02-21
Posts: 267

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

Current setup:
/var/log/Xorg.0.log
glxinfo -B
org.kde.KWin.supportInformation
/etc/X11/xorg.conf.d/20-intel.conf
~/.drirc

xf86-video-intel: installed
mesa-git: installed
KWIN_USE_BUFFER_AGE=0

KWin Compositor:
1. enabled
2. Scale method: smooth
3. Backend: OpenGL 3.1
4. Latency: balanced
5. Tearing prevention: Only when cheap
6. Windows thumbnails: never (???)
7. Allow applications to block compositing: enabled

Behavior
Everything seems ok now. No lagging nor frame drops.
Responsiveness seems back to normal.
I had to remove some Vivaldi (my main browser) GPU-related settings to make it working again.
This is current vivaldi://gpu page:

Graphics Feature Status
Canvas: Hardware accelerated
Compositing: Hardware accelerated
Multiple Raster Threads: Enabled
Out-of-process Rasterization: Disabled
OpenGL: Enabled
Rasterization: Software only. Hardware acceleration disabled
Skia Renderer: Enabled
Video Decode: Software only. Hardware acceleration disabled
Vulkan: Disabled
WebGL: Hardware accelerated
WebGL2: Hardware accelerated

I am not sure whether I can get any better than this. For sure, when I run MS Teams on the browser I experience the original slowness.
But this could be due to the (intended) client behavior with that web app (I cannot avoid).

Is there anything else I should check out?
I am not sure whether vulkan-intel can be useful and whether I can switch back to mesa from mesa-git that takes ages to recompile once a day.

Last edited by 0BADC0DE (2021-11-03 12:50:55)


Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.

Offline

#38 2021-11-03 13:07:29

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,424

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

vulkan intel is irrelevant here, and you can definitely test whether rolling back to mesa works out. FWIW I can't reproduce any of this on my "older" 6700HQ Skylake laptop so some weirdness might still be around

Online

#39 2021-11-03 13:23:40

0BADC0DE
Member
From: Regnum Utriusque Siciliae
Registered: 2018-02-21
Posts: 267

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

I rolled back to "extra/mesa" (currently v21.2.4-1) and put back "AccelMethod" to "sna" and "DRI" to "3" in /etc/X11/xorg.conf.d/20-intel.conf.
Everything still works.
Yes, now I know Vulkan is not relevant here.
I enabled hardware-accelerated rasterization on vivaldi://flags: just searched for GPU!
Hardware acceleration for  video decode seems to be still out of my reach. :-/

That would maybe offload the CPU and maybe same some battery in my PC.
I tried several approaches with libva and vdpau but nothing changes, while vainfo badly fails:

libva error: /usr/lib/dri/i965_drv_video.so init failed
vaInitialize failed with error code -1 (unknown libva error),exit

Any hint?

Good results so far, though!
Thanks a whole lot @seth and @V1del!

But we're not there yet! Read next message.

U P D A T E
DRI needs to stay at "2". I get random errors with 3, at least with Vivaldi!

U P D A T E   N. 2
Start your chromium-based browser with "--enable-features=VaapiVideoDecoder" and you will also get "Video Decode: Hardware accelerated".
Of course, you need to install a bunch of packages (I am not sure you really need all of them, though!):
community/libvdpau-va-gl
extra/libva
extra/libva-intel-driver
extra/libva-mesa-driver
extra/libva-vdpau-driver
extra/mesa-vdpau

U P D A T E   N. 3
During MS Teams and Google Meet video calls, all graphics gets a little bit stuttering with all 8 cores in use at about 50% with a loadavg between 4 and 5.
Even moving around a static window (konsole) is slow and a little bit unresponsive.
I can imagine that the CPU load has something to do with WebRTC and that X is not coping nicely with those video streams despite hardware acceleration is now enabled in the browsers.

U P D A T E   N. 4
You need to install also this: community/libvdpau-va-gl . Read below.

Last edited by 0BADC0DE (2021-11-04 10:13:07)


Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.

Offline

#40 2021-11-04 10:05:40

0BADC0DE
Member
From: Regnum Utriusque Siciliae
Registered: 2018-02-21
Posts: 267

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

Unluckily it doesn't work yet.
I went to vivaldi://media-internals (or chrome://media-internals/ if you use chrome) while playing a video on youtube.
I selected the "blob:https;//www.youtube.com/..." and this is what I have got:

render_id: 8
player_id: 40
origin_url: https://www.youtube.com/
kFrameUrl: https://www.youtube.com/watch?v=aV6tuwm4Srw
kFrameTitle: 3 Storm Large 7 Deadly sins with Detroit symphony Orchestra - YouTube
url: blob:https://www.youtube.com/73fcb5ea-15d3-4c6c-b21c-93ee0b9a5705
kTextTracks: 
info: Selected video track: []
kRendererName: RendererImpl
pipeline_state: kPlaying
kVideoTracks: [object Object]
kAudioTracks: [object Object]
event: kPlay
kIsAudioDecryptingDemuxerStream: false
kAudioDecoderName: FFmpegAudioDecoder
kIsPlatformAudioDecoder: false
kIsVideoDecryptingDemuxerStream: false
kVideoDecoderName: Dav1dVideoDecoder  <<<< LOOK HERE!!!
kIsPlatformVideoDecoder: false
dimensions: 848x480
kResolution: 848x480
duration: 579.241
pipeline_buffering_state: [object Object]

You can see this "kVideoDecoderName: Dav1dVideoDecoder" .
The browser isn't using the GPU decoder, but a software one! :-|
As I reported earlier, vainfo tool fails to initialize while vdpauinfo required an extra package to be installed (community/libvdpau-va-gl).
Output is here: no decoder capability is supported! :-(

So, despite it should work(tm), it actually DOESN'T.
Not yet.

Any hint is very appreciated.

U P D A T E   N. 1
I tried mesa-git and libva-utils-git but nothing changed: vainfo keeps failing at initialization.


U P D A T E   N. 2
vainfo requires two extra packages in order to work:
intel-gmmlib (21.3.1-1)
intel-media-driver (21.3.5-1)

So, this is vainfo output and this is vdpauinfo's.
vdpauingo now SIGABRTs with a double free error message and reports to me some supported stuff:
H264_BASELINE
H264_MAIN
H264_HIGH
H264_CONSTRAINED_BASELINE

Last edited by 0BADC0DE (2021-11-12 08:02:52)


Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.

Offline

#41 2021-11-04 10:51:33

0BADC0DE
Member
From: Regnum Utriusque Siciliae
Registered: 2018-02-21
Posts: 267

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

-

Last edited by 0BADC0DE (2021-11-04 12:24:56)


Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.

Offline

#42 2021-12-02 14:52:35

0BADC0DE
Member
From: Regnum Utriusque Siciliae
Registered: 2018-02-21
Posts: 267

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

00:00:00.117    info    "Failed to initialize DecryptingVideoDecoder"
00:00:00.117    info    "Failed to initialize VDAVideoDecoder"

This is what Chromium/Vivald/Chrome reports.
Honestly I really have no clue.


Maybe Computers Will Never Become As Intelligent
As Humans. Surely They Won't Ever Become So Stupid.

Offline

#43 2021-12-02 16:13:13

seth
Member
Registered: 2012-09-03
Posts: 49,975

Re: [not really SOLVED] Slow X when using Chrome/Chromium/Vivaldi

Browsers not using hw video decoding is snafu, https://bbs.archlinux.org/viewtopic.php?id=244031&p=25

Offline

Board footer

Powered by FluxBB