Skip to content

[Nvidia Optimus] Why does GPU offloading require supported drivers?

I just read about Nvidia 435 now supporting GPU offloading of OpenGL and Vulkan apps with dual intel & Nvidia gpus. I assumed so far that offloading is the Vulkan ICD loader and the LibGLVN's job, since they decide which implementation to load for an application, and thus which driver is used to render. But then I read here about a ton of Xorg configuration in order to get it working, and now I really don't think I understand how GPU offloading works

So it's more than just loading a different libgl implementation, I suppose. Does anyone have a clear understanding on how an app renders on the screen using GPU and LibGl / LibVk? Thanks!

11 points7 comments
Open on Reddit
About this post
Posted
Archived
Score
11 · 100% up
Kind
Text
ID
dwdalm

Author

59
posts
308
comments
8
media
View profile

7 comments

You can render on the Nvidia card just fine with just a Vulkan loader - the tricky part is getting the frames on screen, which is only connected to the integrated card. The trickier part is doing it quickly, i.e. without copying the rendered image through RAM. The even trickier part is making the whole thing work with color management, vsync, adaptive refresh and all the other display-related stuff.

12 points

Wait aren't both the iGPU and the Nvidia one connected to a framebuffer, which is fed to the screen?

0 points

There is no separate "framebuffer" hardware, a framebuffer is just a chunk of VRAM. Each GPU technically has a display controller, so it could drive a screen, but only one GPU can drive a specific screen at a time, and most laptops don't actually connect the external card to the screen at all. Also, what if the game is running in windowed mode?

8 points

Keyboard shortcuts

Move and act

jork
Next / previous post or comment
Enteroro
Open the post
f
Open the media viewer
s
Save
h
Hide (the toast has Undo)
Tab
Right after an action: the toast's Undo
x
Collapse the comment
v
Next layout: cards, compact, grid

Go to

/
Search
gthenh
Home
gthena
All
gthens
Subreddits
gthenl
Library
?
This list
Esc
Close a menu or this list

In the viewer

←or→
Previous / next file
↑or↓
Previous / next post
korj
Previous / next post
Space
Play / pause
m
Mute
z
Zoom
s
Save
o
Open the post (on its own page: back to it)
Esc
Close

Keys do nothing while you type in a box.