I know this is a complicated topic but I would like to put my computer working with the ability to change between GPUs. It's a Toshiba satellite with an (originally) Optimus system. It has an Intel core i7 CPU and a NVIDIA GT 740M GPU. My steps according to some tutorials I found was:

  1. Going to Additional drivers and checking if I was using NVIDIA proprietary drivers. I was. Version 375.39.
  2. After that I installed nvidia-prime and nvidia-375 drivers with:

    sudo apt-get install nvidia-375 nvidia-prime

  3. Rebooting
  4. Choosing NVIDIA in the Prime Profiles in the NVIDIA X SERVER SETTINGS.
  5. Loging out and in.

All worked like a charm. No error messages or anything strange. After that I went to watch a movie and noticed some flickering. So I ran

lspci -vnnn | perl -lne 'print if /^\d+\:.+(\[\S+\:\S+\])/' | grep VGA

to show me which GPU i was using which showed me:

00:02.0 VGA compatible controller [0300]: Intel Corporation 4th Gen Core Processor Integrated Graphics Controller [8086:0416] (rev 06) (prog-if 00 [VGA controller])

I don't understand as in NVIDIA X SERVER SETTINGS all seems right telling me I'm using my NVIDIA GPU. But I definitely am not as the screen is flickering with a movie which isn't HD. Can anyone help?

Notes: I tried it with a second monitor and without one. All gave the same results. The nvidia app doesn't seem to recognize the second monitor instead preferring to tell me it's using a single monitor with the sum of the resolutions. Don't know if it's relevant.

  • grep VGA does not show the Nvidia GPU. Use lspci -k | grep -EA2 'VGA|3D' to see it. All looks OK. – Pilot6 May 8 '17 at 8:35

I have two ThinkPads with Optimus. In both cases, they have a BIOS setting disabling Optimus and only revealing to the computer the Nvidia card: in this scenario, the Intel video disappears. However, this is the only way you remove the Intel video from the picture, so to speak, and this is not Optimus mode. In Optimus mode, or Hybrid mode, the laptop's display panel is run by the Intel hardware, and the HDMI or Display Port devices are run by Nvidia. If you choose Intel profile, the nvidia card turns off, but you lose external screens. When Nvidia profile is on, the Nvidia card does all rendering, but it sends the rendered frame to the intel video, and it is the Intel hardware which shows it on the laptop's panel. I read that some laptops do not have a way of enabling "discrete" video; it adds to the expense of the laptop.

Until X version 1.19, there was simply no way for the Nvidia driver to time these transfers to Intel to avoid tearing (the flickering you see). This is fixed now, but you need Ubuntu 17.04 or something else quite new to take advantage. It was a problem with the xserver software, and Nvidia's patches have finally been accepted.

So in Optimus mode Nvidia profile, both cards are used. It sounds a bit odd, but this is the only way the laptop can dynamically switch workload between the two cards. In Windows this makes sense because the Nvidia driver sends rendering to the Intel card when it is good enough. The Bumblebee software in linux does this, but Prime doesn't. Under Prime, Nvidia is always on, in Nvidia profile, and does all the work. The Intel driver is relegated to simply dumbly rebroadcasting to the laptop's panel. It doesn't save power. The only win is switching to intel profile is slightly more convenient than accessing BIOS settings, because you can switch by rebooting without entering BIOS.

To be honest, if I am using external monitors, I usually use the BIOS settings to choose discrete video (100% Nvidia), since there is no tearing (I am using xubuntu 16.04.2 and the nvidia/intel Optimus tearing fix won't hit until July's 16.04.3). To get tearfree in Nvidia, I enable the Nvidia driver option Force Composition Pipeline, but this may not be necessary for you.

  • Will check for that option in my BIOS menu although I have never seen it. Thanks such explicative answer! – Joaquim Ferrer May 8 '17 at 11:13
  • If you can't disable Optimus, shame on Toshiba, but then you should use a linux distribution based on ubuntu 17.04 or some other recent distribution, you need xserver v19.x and the very latest nvidia drivers (May 2017). Nvidia calls the nvidia->intel way of working "prime sync". this thread explains what it is, and how to get it working without tearing (see most recents posts for that). devtalk.nvidia.com/default/topic/957814/… – Tim Richardson May 8 '17 at 23:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.