You are not logged in.

#1 2022-10-26 06:53:31

varolbora5
Member
Registered: 2022-07-17
Posts: 76

Arch lags on dedicated GPU

I have an ASUS Zenbook with dualboot arch/win11. It has Ryzen Integrated Graphics and a Nvidia 3050 Ti. I got the optimus manager to switch between them easily. On hybrid it seems fine but when I open a game (minecraft) it lags a bit, but if I turn it to just the nvidia it lags the whole computer and I get like a frame every 5 seconds.

lspci output

00:00.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne Root Complex
00:00.2 IOMMU: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne IOMMU
00:01.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe Dummy Host Bridge
00:01.1 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe GPP Bridge
00:01.3 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne PCIe GPP Bridge
00:02.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe Dummy Host Bridge
00:02.2 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne PCIe GPP Bridge
00:02.4 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne PCIe GPP Bridge
00:08.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Renoir PCIe Dummy Host Bridge
00:08.1 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir Internal PCIe GPP Bridge to Bus
00:08.2 PCI bridge: Advanced Micro Devices, Inc. [AMD] Renoir Internal PCIe GPP Bridge to Bus
00:14.0 SMBus: Advanced Micro Devices, Inc. [AMD] FCH SMBus Controller (rev 51)
00:14.3 ISA bridge: Advanced Micro Devices, Inc. [AMD] FCH LPC Bridge (rev 51)
00:18.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Cezanne Data Fabric; Function 0
00:18.1 Host bridge: Advanced Micro Devices, Inc. [AMD] Cezanne Data Fabric; Function 1
00:18.2 Host bridge: Advanced Micro Devices, Inc. [AMD] Cezanne Data Fabric; Function 2
00:18.3 Host bridge: Advanced Micro Devices, Inc. [AMD] Cezanne Data Fabric; Function 3
00:18.4 Host bridge: Advanced Micro Devices, Inc. [AMD] Cezanne Data Fabric; Function 4
00:18.5 Host bridge: Advanced Micro Devices, Inc. [AMD] Cezanne Data Fabric; Function 5
00:18.6 Host bridge: Advanced Micro Devices, Inc. [AMD] Cezanne Data Fabric; Function 6
00:18.7 Host bridge: Advanced Micro Devices, Inc. [AMD] Cezanne Data Fabric; Function 7
01:00.0 3D controller: NVIDIA Corporation GA107M [GeForce RTX 3050 Ti Mobile] (rev a1)
02:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTS522A PCI Express Card Reader (rev 01)
03:00.0 Network controller: Intel Corporation Wireless-AC 9260 (rev 29)
04:00.0 Non-Volatile memory controller: SK hynix PC711 NVMe Solid State Drive
05:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Cezanne (rev c5)
05:00.1 Audio device: Advanced Micro Devices, Inc. [AMD/ATI] Renoir Radeon High Definition Audio Controller
05:00.2 Encryption controller: Advanced Micro Devices, Inc. [AMD] Family 17h (Models 10h-1fh) Platform Security Processor
05:00.3 USB controller: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne USB 3.1
05:00.4 USB controller: Advanced Micro Devices, Inc. [AMD] Renoir/Cezanne USB 3.1
05:00.6 Audio device: Advanced Micro Devices, Inc. [AMD] Family 17h/19h HD Audio Controller
06:00.0 SATA controller: Advanced Micro Devices, Inc. [AMD] FCH SATA Controller [AHCI mode] (rev 81)
06:00.1 SATA controller: Advanced Micro Devices, Inc. [AMD] FCH SATA Controller [AHCI mode] (rev 81)

nvidia-smi output:

Wed Oct 26 08:52:34 2022       
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 520.56.06    Driver Version: 520.56.06    CUDA Version: 11.8     |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|                               |                      |               MIG M. |
|===============================+======================+======================|
|   0  NVIDIA GeForce ...  Off  | 00000000:01:00.0 Off |                  N/A |
| N/A   31C    P3    N/A /  N/A |      4MiB /  4096MiB |      0%      Default |
|                               |                      |                  N/A |
+-------------------------------+----------------------+----------------------+
                                                                               
+-----------------------------------------------------------------------------+
| Processes:                                                                  |
|  GPU   GI   CI        PID   Type   Process name                  GPU Memory |
|        ID   ID                                                   Usage      |
|=============================================================================|
|    0   N/A  N/A       638      G   /usr/lib/Xorg                       4MiB |
+-----------------------------------------------------------------------------+

Offline

#2 2022-10-26 07:52:32

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,206

Re: Arch lags on dedicated GPU

Don't use optimus-manager, use PRIME offloading: https://wiki.archlinux.org/title/PRIME# … er_offload

If that doesn't fix it, which AMD xorg ddx are you using? modesetting or xf86-video-amdgpu? Does switching between the two change things?

Last edited by V1del (2022-10-26 07:53:31)

Offline

#3 2022-10-26 09:50:37

varolbora5
Member
Registered: 2022-07-17
Posts: 76

Re: Arch lags on dedicated GPU

I have xf86-video-amdgpu, but while I was trying to switch to prime offloading I broke something and now xrandr won't recognize my ded. gpu

xrandr --listproviders
Providers: number : 1
Provider 0: id: 0x55 cap: 0xf, Source Output, Sink Output, Source Offload, Sink Offload crtcs: 4 outputs: 3 associated providers: 0 name:Unknown AMD Radeon GPU @ pci:0000:05:00.0

I can use prime-run and it shows up as 3D controller in lspci

Last edited by varolbora5 (2022-10-26 09:52:40)

Offline

#4 2022-10-26 13:15:40

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 75,790

Re: Arch lags on dedicated GPU

Because it's a 3D controller, not a VGA device.
It has no crtcs, you cannot attach outputs there so there's also no output redirection.

I can use prime-run

would mean that things are fine and work as expected?

Offline

#5 2022-10-26 19:17:53

varolbora5
Member
Registered: 2022-07-17
Posts: 76

Re: Arch lags on dedicated GPU

Before trying to switch to using PRIME I could see the card on xrandr.

would mean that things are fine and work as expected?

I am not sure because for some instances it is worse with prime-run, like minecraft gets major screen tearing with it,
but factorio performs better with it, and glxgears does like 30 times better with it too.

Last edited by varolbora5 (2022-10-26 19:18:11)

Offline

#6 2022-10-26 20:03:52

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 75,790

Re: Arch lags on dedicated GPU

https://wiki.archlinux.org/title/PRIME# … ronization
nb. the prerequisites, no xf86-video-amdgpu and enable nvidia-drm.modeset=1

Offline

#7 2022-10-27 08:01:32

varolbora5
Member
Registered: 2022-07-17
Posts: 76

Re: Arch lags on dedicated GPU

I already have nvidia-drm.modeset enabled, should I delete the xf86-video-amdgpu?

Offline

#8 2022-10-27 08:06:04

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 75,790

Re: Arch lags on dedicated GPU

Yes. Also make sure there're not let-over configs referencing it afterwards

grep -ri amdgpu /{etc,usr/share}/X11/xorg.conf*

Offline

#9 2022-10-27 17:59:39

varolbora5
Member
Registered: 2022-07-17
Posts: 76

Re: Arch lags on dedicated GPU

I did,
what should happen now?

Offline

#10 2022-10-27 19:10:29

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,206

Re: Arch lags on dedicated GPU

If you reboot/restart xorg, is the behaviour different now?

Offline

Board footer

Powered by FluxBB