Using PRIME offload with driver 435.21 on Ubuntu 19.10, glxinfo fails

Hardware: Quadro M1200 (notebook).

  1. Made sure all software is up to date.
  2. Installed driver from Ubuntu “restricted” official repository.
  3. Enabled GPU screen by adding config file with “ServerLayout” Option “AllowNVIDIAGPUScreens”.
  4. xrandr --listproviders shows “Provider 1: id: 0x1f8 cap: 0x0 crtcs: 0 outputs: 0 associated providers: 0 name:NVIDIA-G0”

Running glxinfo using offload environment variable crashes:

name of display: :0
X connection to :0 broken (explicit kill or server shutdown).
X connection to :0 broken (explicit kill or server shutdown).

Please advise.
nvidia-bug-report.log.gz (467 KB)

Please remove
and use a proper /etc/X11/xorg.conf like

Section "ServerLayout"
  Identifier "layout"
  Screen 0 "iGPU"
  Option "AllowNVIDIAGPUScreens"

Section "Device"
  Identifier "iGPU"
  Driver "modesetting"
  BusID "PCI:0:2:0"

Section "Screen"
  Identifier "iGPU"
  Device "iGPU"

Section "Device"
  Identifier "nvidia"
  Driver "nvidia"
  BusID "PCI:1:0:0"

After updating the driver to the 440 series and setting the xorg.conf as suggested by generix, I can enable “Nvidia On-Demand” from nvidia-settings and xrandr shows two providers.

Launching application using the environment variables or using mate-optimus-indicator’s offload glx, shows the application detecting the Nvidia GPU - but the performance is basically identical to not using the offloading - I checked various benchmarks and the results are very similar across the board.

For example glmark2 shows ~300 FPS in all tests regardless of whether offloading is used. If there’s any difference between GPUs I would have to say that Intel edges about 10 FPS more than Nvidia!

What am I missing?

What benchmarks have you tested? There is slightly higher overhead in getting pixels to the screen in offload mode since it has to go across the PCIe bus and get read by the iGPU, so benchmarks that run at very high framerates are expected to see a drop when running in offload mode. Please try a benchmark that the iGPU struggles with, such as Unigine.

Got your point. Running Portal 2, offload boosts frame rate from ~20 fps on the iGPU to ~70 fps.