Is Primus a hack?
Does it work less good and perform slower than PRIME?
Is PRIME or Primus only for X.org, or does it work on Wayland too?
Phoronix: Primus: Client-Side GPU Offloading In 500 Lines Of Code
While PRIME offloading has finally materialized and will be set when X.Org Server 1.13 is released, a new client-side GPU offloading implementation has now surfaced. Primus is a small lightweight GPU offloading implementation written in about 500 lines of code...
http://www.phoronix.com/vr.php?view=MTE3NDk
Is Primus a hack?
Does it work less good and perform slower than PRIME?
Is PRIME or Primus only for X.org, or does it work on Wayland too?
From my testing a few days ago, Primus is slower than Bumblebee and Prime even when sync-to-vblank is disabled. Very disappointing. Plus, it doesn't support Wine.
Primus Nvidia
eric@gensokyo:~/primus$ ./primusrun glxspheres
loading /usr/lib/nvidia-bumblebee/libGL.so.1: 0x7f46560c2028
loading /usr/lib/libGL.so.1: 0x7f46560c2028
Polygons in scene: 62464
Visual ID of window: 0x21
glXCreateContext: dctx = 0x1d02648, actx = 0x1d94128
glXIsDirect
Context is Direct
glXMakeCurrent
OpenGL Renderer: GeForce GT 555M/PCIe/SSE2
primus: sorry, not implemented: glXUseXFont
50.914033 frames/sec - 56.820060 Mpixels/sec
51.495871 frames/sec - 57.469392 Mpixels/sec
51.202087 frames/sec - 57.141530 Mpixels/sec
51.926189 frames/sec - 57.949627 Mpixels/sec
Prime Nouveau
eric@gensokyo:~$ DRI_PRIME=1 glxspheres
Polygons in scene: 62464
Visual ID of window: 0xf0
Context is Direct
OpenGL Renderer: Gallium 0.4 on NVC3
157.687749 frames/sec - 175.979528 Mpixels/sec
168.748184 frames/sec - 188.322973 Mpixels/sec
162.604838 frames/sec - 181.466999 Mpixels/sec
162.187192 frames/sec - 181.000906 Mpixels/sec
Bumblebee Nvidia
eric@gensokyo:~/primus$ optirun glxspheres
Polygons in scene: 62464
Visual ID of window: 0x21
Context is Direct
OpenGL Renderer: GeForce GT 555M/PCIe/SSE2
89.406007 frames/sec - 99.777104 Mpixels/sec
90.693321 frames/sec - 101.213747 Mpixels/sec
92.742092 frames/sec - 103.500175 Mpixels/sec
92.997387 frames/sec - 103.785084 Mpixels/sec
Bumblebee Nouveau
eric@gensokyo:~$ optirun glxspheres
Polygons in scene: 62464
Error: nConfigOptions (15) does not match the actual number of options in
__driConfigOptions (10).
Visual ID of window: 0x21
Context is Direct
OpenGL Renderer: Gallium 0.4 on NVC3
60.167254 frames/sec - 67.146655 Mpixels/sec
59.676654 frames/sec - 66.599146 Mpixels/sec
59.255803 frames/sec - 66.129476 Mpixels/sec
59.299268 frames/sec - 66.177983 Mpixels/sec
Last edited by LLStarks; 09-03-2012 at 11:40 AM.
Btw, this is for Xorg only and you need to have 2nd Xserver running (via Bumblebee) to even use it.
In order:
Yes, but not in a derogatory manner. It appears to be a simplified and limited solution which will give us a baseline for comparison when PRIME is ready.
It will likely be less than half the speed of Prime (probably 25% the theoretical max) and not support as many applications due to the lack of extensions. I Imagine that most simple OpenGL applications will run without issue.
Prime appears to be x11 only. You could probably do some fancy x11 over x11 over Wayland magic, but the results would not be to anyone's satisfaction. I cannot imagine a RL scenario where it would be beneficial to do this.
To summarize, the point of Primus is not to usurp PRIME, it is to demonstrate simplified implementation of GPU offloading under X11. I applaud the author for sharing it.
F
Does anyone have AMD benchmarks to share?
this is just wrong, because the primus output is vsynced.
primusrun glxspheres
loading /usr/lib64/opengl/nvidia/lib/libGL.so.1: 0x7fa3a491d000
loading /usr/lib/libGL.so.1: 0x21a0c00
Polygons in scene: 62464
Visual ID of window: 0x20
glXCreateContext
ATTENTION: default value of option vblank_mode overridden by environment.
ATTENTION: default value of option vblank_mode overridden by environment.
glXIsDirect
Context is Direct
glXMakeCurrent
OpenGL Renderer: GeForce GT 630M/PCIe/SSE2
primus: sorry, not implemented: glXUseXFont
1006.130730 frames/sec - 1122.841894 Mpixels/sec
995.853913 frames/sec - 1111.372967 Mpixels/sec
995.801018 frames/sec - 1111.313936 Mpixels/sec
1002.985652 frames/sec - 1119.331988 Mpixels/sec
990.192813 frames/sec - 1105.055179 Mpixels/sec
995.331831 frames/sec - 1110.790324 Mpixels/sec
and now, someone should say, that noveau is faster than binary driver.