Is it possible to run Steam games using optirun?

30,865

In theory, primusrun is preferred over optirun for performance and stability, as recommended by the bumblebee devs. I'm unsure why you get the results you did. I know in some cases, frames are capped, but that doesn't seem to be the case for you. (In my case I get 150 fps for optirun glxspheres64 and 60 fps for primusrun glxspheres64, which I believe is due to the cap.)

In any case, I use different options for different Steam games. Mostly, performance is similar with different commands, but the main difference to me is stability. This includes stability with and without the Steam overlay enabled. The following are different settings that I've used for different games, which you can test. I generally try this first:

primusrun %command%

However, I've found this is not always optimal. Sometimes optirun is more stable.

optirun %command%

In some cases, neither of those work (e.g. in Team Fortress 2) so I use:

LD_PRELOAD="libpthread.so.0 libGL.so.1" __GL_THREADED_OPTIMIZATIONS=1 optirun %command%
Share:
30,865

Related videos on Youtube

KTW
Author by

KTW

Updated on September 18, 2022

Comments

  • KTW
    KTW almost 2 years

    I am using Bumblebee on OpenSuse 13.1 on my Intel HD4600 / Nvidia GTX 860M combo.
    Steam games seems to lag a bit, when using primusrun. (vblank_mode=0 primusrun)

    Testing both primusrun and optirun with glxspheres, indicates that optirun is the better option on my system. But my Steam games does not start with the optirun command.

    vblank_mode=0 primusrun glxspheres  
    209.926051 frames/sec - 234.277473 Mpixels/sec
    
    vblank_mode=0 optirun glxspheres  
    250.734727 frames/sec - 279.819955 Mpixels/sec
    

    Any help would be appreciated.

  • KTW
    KTW about 10 years
    That worked, thanks! Still a mystery why primusrun is slower than optirun. But the lag is gone now.
  • Steven Roose
    Steven Roose almost 9 years
    Fantastic! This solved a problem I was having with Steam for over a month now! github.com/ValveSoftware/steam-for-linux/issues/3901