How to disable Vsync when using prime-run?

Hi, i'm using Manjaro 20 Gnome on an Intel+Nvidia laptop with nvidia 440xx-prime drivers.

In previous versions of manjaro, I added vblank_mode=0 option to the optirun command to disable vsync and run apps on discrete graphics (nvidia).

With the new drivers (440xx-prime), manjaro comes with nvidia prime instead of the bumblebee and optirun. So now i'm running apps on discrete graphics with the prime-run command, but prime-run doesn't accept vblank_mode=0 option, and always enable the vsync, locks the frame at 60 fps (for example, in glxspheres64).
so, how can i disable the vsync when i run apps with prime-run command?

Hello and welcome to the forum :slightly_smiling_face:!
The new prime drivers use NVDIA's proprietary drivers to run apps on the discrete GPU, and disabling vblank on NVIDIA's proprietary drivers works differently. For NVIDA's proprietary drivers, the variable is called __GL_SYNC_TO_VBLANK=0. That means that running

__GL_SYNC_TO_VBLANK=0 prime-run <your app>

now does the same as previously running

vblank_mode=0 optirun <your app>

I hope this helped!
If you have any further questions, feel free to ask.

Forum kindly sponsored by