Poor gaming performance with Nvidia Prime

I was recently using pop_os and decided to switch to manjaro for a change, and also because I was tired with gnome. I’m not much of a gamer, but sometimes run emulated games on retroarch/dolphin-emu.

My laptop (Thinkpad P50) has a dual GPUs. See below:

Graphics:  Device-1: Intel HD Graphics 530 driver: i915 v: kernel
           Device-2: NVIDIA GM107GLM [Quadro M1000M] driver: nvidia v: 465.31
           Device-3: Chicony Integrated Camera type: USB driver: uvcvideo
           Display: x11 server: X.Org 1.20.11 driver: loaded: modesetting,nvidia resolution: 1: 1920x1080~60Hz
           2: 1920x1080~60Hz
           OpenGL: renderer: Mesa Intel HD Graphics 530 (SKL GT2) v: 4.6 Mesa 21.1.2

Pop_os has a GPU switch that allows the user to easily switch the gpu mode to intel only, nvidia only, or hybrid mode. I was mostly running on hybrid mode but noticed that gaming performance was worse when compared to what I was experiencing on windows. I switched to nvidia only and got comparable performance to windows.

Now that I’m using Manjaro and having installed the proprietary nvidia drivers, gaming performance is back to being poor (fps is almost halved) while I’m on hybrid mode despite launching games with prime-run dolphin-emu. I’m wondering if it’s possible:

  1. Keep using hybrid mode and improve gaming performance. I would prefer this option because KDE on nvidia-only mode is quite janky. Also, why should gpu performance take such a hit while running on hybrid mode ?

  2. If the first option is not possible, is there an easy way to select to run on nvidia only mode (disable the built-in intel gpu) ?

There is a program called optimus-manager that allow you to switch gpu,combine that with optimus-manager-qt and you will have a menu just like PopOS

That being said,I can’t tell exactly why you have performance issues,I was playing before in hybrid mode and had all my games to 60 FPS just like in Windows (1050 Ti) (Now I use the 470 drivers in the testing branch and with that I can play in Intel mode only,not need hybrid/NVIDIA mode anymore unless you want to connect to a TV).

There is one thing that i do everytime i play,I disable the compositor,the compositor can lag the game very hard (this is resolved in wayland),I don’t know if this affect in GNOME tho,in KDE the compositor can be disabled with ALT+ SHIFT + F12

I also used NVIDIA only in KDE and I don’t see any problems (at least not visible problems).

1 Like

Thanks for your reply. Let me give you an example. When I was on pop_os, super mario 64 ran at 240fps at some spot while running on nvidia only. Switching to hybrid dropped the fps to almost half at the same spot. I’m noticing the same on Manjaro. Obviously 120fps is more than enough, but this is because this game is less demanding. For instance, I notice the lower performance on games like mario kart wii and super mario galaxy, which are more demanding than games like new super mario bros.

I installed Askannz/optimus-manager and switched to Nvidia. It asked me to log out. I did, but it didn’t seem to have actually switched.

I’ve noticed something very weird. I was trying to record my gameplay (with OBS) to show how much fps I’m losing while on hybrid mode. To my surprise, the gameplay was very smooth. As soon as I closed OBS, the game started stuttering. What is going on ?

Is there any throttling going on? Might be worth installing gamemode and enabling it(you can do it in steam under launch options). See if that makes a difference, could also try launching games with lutris, that gives you lots of options to tweak things

I installed gamemode from the AUR. It helped with dolphin-emu but not with retroarch.

This is in hybrid mode with gamemoderun retroarch. The game is barely playable.

This is in hybrid-mode but with prime-run retroarch.

This is in nvidia-only mode. I’m getting 220fps.

Sounds like retroarch is running on the intergrated gpu rather than the nvidia card. I’m certainly no expert on this but I’m pretty sure you can use lutris for retroarch. Maybe try that and toggle prime render offload and gamemode in lutris and see if it makes a difference

Make sure to do the mini tutorial after the installation

Manjaro ships with a default configuration for SDDM (the default login manager for KDE) which overrides some keys needed by optimus-manager. To use optimus-manager, you need to edit the file /etc/sddm.conf and simply put a # before the line starting with DisplayCommand and the one starting with DisplayStopCommand .

Instead of running prime-run with dolphin-emu and retroarch,try selecting the GPU from the apllication itself,any application that has Vulkan support will be able to see the NVIDIA card without you to do prime-run
For example in dolphin,I don’t have any prime-run,just mangohud and gamemode,and in the graphics settings,I select Vulkan and my NVIDIA card.

Retroarch the same thing,you go to settings > video > output > video vulkan and GPU Index select your NVIDIA card.

As for Mario 64,are you sure is using the NVIDIA card in Hybrid mode? Run the command nvidia-smi,this will tell you are the process that are running the NVIDIA card (there should be a Xorg process in there in hybrid mode),