Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 02 Apr 2023 18:50:56 +0200
From:      Jan Beich <jbeich@FreeBSD.org>
To:        Kevin Oberman <rkoberman@gmail.com>
Cc:        multimedia@freebsd.org
Subject:   Re: Poor performance with Alder Lake graphics (ThinkPad T16)
Message-ID:  <bkk6-5itr-wny@FreeBSD.org>
In-Reply-To: <CAN6yY1uvk5QdAcfnqoUVDH-sO6t9sJ4OWCBjB2pQee%2B8MqDCPQ@mail.gmail.com> (Kevin Oberman's message of "Sat, 1 Apr 2023 22:51:43 -0700")
References:  <CAN6yY1uvk5QdAcfnqoUVDH-sO6t9sJ4OWCBjB2pQee%2B8MqDCPQ@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Kevin Oberman <rkoberman@gmail.com> writes:

> Since update to drm-550-kmod I noticed n seeming improvement over scfb. I
> ran glxgears and saw agour 900 fps.

glxgears should never show more FPS than monitor refresh rate unless it
uses software rendering or VSYNC is disabled via vblank_mode=0 in
environ(7) or ~/.drirc. If you need to benchmark GPU use at least
glmark2 + vkmark.

Assuming drm-550-kmod is typo for drm-515-kmod.

> [vo/gpu] VT_GETMODE failed: Inappropriate ioctl for device
> [vo/gpu/opengl] Failed to set up VT switcher. Terminal switching will be
> unavailable.

VT_GETMODE isn't supposed to be used outside of --gpu-context=drm and
maybe --gpu-context=displayvk. Both are intended for playing videos
with the best performance directly on KMS console like /dev/ttyv0.

In short, ignore this error due to auto-detection scrambling to find any
accelerated GPU context.

> [vo/gpu/opengl] Suspected software renderer or indirect context.
[...]
> error: Kernel is too old (4.16+ required) or unusable for Iris.
> Check your dmesg logs for loading failures.
[...]
> libEGL warning: DRI2: failed to authenticate

Looks like OpenGL acceleration failed under Xorg for some reason.
Maybe caused by https://github.com/freebsd/drm-kmod/issues/175

> Am I doing something wrong or is there a lack of support for Alder Lake
> graphics? N.B. Alder Lake graphics is Iris and I think Gallium might be
> needed.

If /dev/dri exists and kmscube runs fine then your GPU is properly supported.

VA-API is separate from OpenGL. VA-API on Alder Lake needs libva-intel-media-driver
but the actual support depends on PCI ID e.g., may require newer version
than then one packaged.

>  Should I use xf86-intel-drive?

Did you miss Intel copyright in libwayland and Wayland code in Mesa?

Intel stopped contributing to modesetting years ago, sometime after
Ice Lake launch. xf86-video-intel was deprecated by Intel before that.
modesetting is still maintained by others and doesn't need GPU-specific
support but has many bugs compared to Wayland rendering e.g., atomic
mode setting is broken. This is likely a limitation of DDX layer in Xorg
compared to other X11 servers.

xf86-video-intel may work if you add Alder Lake PCI IDs similar to Tiger Lake.
However, performance on Cannon Lake and later is likely very poor due to
https://gitlab.freedesktop.org/xorg/driver/xf86-video-intel/-/commit/7181c5a41c3f



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bkk6-5itr-wny>