Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not using Acceleration? #134

Open
sshaikh opened this issue Nov 14, 2020 · 5 comments
Open

Not using Acceleration? #134

sshaikh opened this issue Nov 14, 2020 · 5 comments

Comments

@sshaikh
Copy link

sshaikh commented Nov 14, 2020

Arch Linux, hardware and driver details below.

When I tried GLMark2 back in April, I was getting a score of around 2500:

$ glmark2

=======================================================
    glmark2 2017.07
=======================================================
    OpenGL Information
    GL_VENDOR:     Intel Open Source Technology Center
    GL_RENDERER:   Mesa DRI Intel(R) HD Graphics P4600/P4700 (HSW GT2)
    GL_VERSION:    3.0 Mesa 20.0.4
=======================================================
[build] use-vbo=false: FPS: 2493 FrameTime: 0.401 ms
=======================================================
                                  glmark2 Score: 2493
=======================================================

However now I seem to be getting a fifth of that:

glmark2
=======================================================
    glmark2 2020.04
=======================================================
    OpenGL Information
    GL_VENDOR:     Intel Open Source Technology Center
    GL_RENDERER:   Mesa DRI Intel(R) HD Graphics P4600/P4700 (HSW GT2)
    GL_VERSION:    3.0 Mesa 20.2.2
=======================================================
[build] use-vbo=false: FPS: 560 FrameTime: 1.786 ms
=======================================================
                                  glmark2 Score: 560 
=======================================================

Similarly back in April GPUTest would report ~2600fps, while now I see ~400.

I've reverted to the April versions of GLMark2 and Mesa but still get around 500. The April results were also generated while passing through to a VM but I've tried GLMark on a native installation and still no luck. I am seeing similar scores when disabling the IGD and using llvmpipe (again via a VM), so it seems like HW acceleration is not being used.

I suspect I'm missing something obvious but other benchmarks like Unigine Heaven appear to be a bit more consistent, and is on par with the results I see eg via Windows, so it seems this problem is limited to GLmark2 (and GPUtest)

Is there a way to see what GLMark is actually doing past the information above?

@afrantzis
Copy link
Contributor

Hi! From the "GL_RENDERER" field value, it seems that you are in fact using the Intel hardware driver. In a different case you would see information about llvmpipe. You can force running with software rendering with the LIBGL_ALWAYS_SOFTWARE=1 Mesa environment variable, to see if this can help you make some progress investigating this.

glmark2 has the --debug command-line option, that provides some more information, but I don't know how much it can help you in this case (perhaps the two mesa versions provide different X11 visuals?).

@sshaikh
Copy link
Author

sshaikh commented Nov 16, 2020

I agree - I have managed to have the GL_RENDERER display llvmpipe and hit the same score.

I do have an update however - with intel_gpu_top I see that the GPU is in fact being used when glmark2 says it is, albeit at 50%. I'll try the SOFTWARE flag next.

It's all very puzzling! Could it be possible that glmark is being artificially limited somehow by a setting (maybe to refresh or something?)

@afrantzis
Copy link
Contributor

Are you using a different version of the VM software now? Could it be that previously the VM software was doing something different in terms of handling buffer submissions from the guest? Or perhaps there was a change in the host system drivers?

@sshaikh
Copy link
Author

sshaikh commented Nov 16, 2020

I tried it outside the VM (ie new hard disk on the host) and get a ~500 score, so whatever is limiting the glmark is not to do with virtualisation. It could be drivers?

It could be possible that an older version of QEMU/KVM caused glmark to incorrectly calculate the score by 5x, but that doesn't explain why llvmpipe also gets ~500 (as I understand it there is no "host acceleration" of VM graphics). Also other benchmarks suffer greatly so I'm pretty sure that 500 is the unaccelerated score.

@sshaikh
Copy link
Author

sshaikh commented Nov 16, 2020

Some experiments!

In a VM with GPU passed through. gpu_top shows work being done.

$ glmark2
=======================================================
    glmark2 2020.04
=======================================================
    OpenGL Information
    GL_VENDOR:     Intel Open Source Technology Center
    GL_RENDERER:   Mesa DRI Intel(R) HD Graphics P4600/P4700 (HSW GT2)
    GL_VERSION:    3.0 Mesa 20.2.2
=======================================================
[build] use-vbo=false: FPS: 418 FrameTime: 2.392 ms
=======================================================
                                  glmark2 Score: 418
=======================================================

In the same VM (forcing software). gpu_top shows some work (I suspect due to 2d acceleration) but not as much as the previous try:

$ LIBGL_ALWAYS_SOFTWARE=1 glmark2
** GLX does not support GLX_EXT_swap_control or GLX_MESA_swap_control!
** Failed to set swap interval. Results may be bounded above by refresh rate.
=======================================================
    glmark2 2020.04
=======================================================
    OpenGL Information
    GL_VENDOR:     Mesa/X.org
    GL_RENDERER:   llvmpipe (LLVM 11.0.0, 256 bits)
    GL_VERSION:    3.1 Mesa 20.2.2
=======================================================
** GLX does not support GLX_EXT_swap_control or GLX_MESA_swap_control!
** Failed to set swap interval. Results may be bounded above by refresh rate.
[build] use-vbo=false: FPS: 68 FrameTime: 14.706 ms
** GLX does not support GLX_EXT_swap_control or GLX_MESA_swap_control!
** Failed to set swap interval. Results may be bounded above by refresh rate.
[build] use-vbo=true: FPS: 77 FrameTime: 12.987 ms
=======================================================
                                  glmark2 Score: 72
=======================================================

All makes sense so far. But now let's try in a VM without a GPU:

[shak@shak-studio ~]$ glmark2
** GLX does not support GLX_EXT_swap_control or GLX_MESA_swap_control!
** Failed to set swap interval. Results may be bounded above by refresh rate.
=======================================================
    glmark2 2020.04
=======================================================
    OpenGL Information
    GL_VENDOR:     Mesa/X.org
    GL_RENDERER:   llvmpipe (LLVM 11.0.0, 256 bits)
    GL_VERSION:    3.1 Mesa 20.2.2
=======================================================
** GLX does not support GLX_EXT_swap_control or GLX_MESA_swap_control!
** Failed to set swap interval. Results may be bounded above by refresh rate.
[build] use-vbo=false: FPS: 372 FrameTime: 2.688 ms
** GLX does not support GLX_EXT_swap_control or GLX_MESA_swap_control!
** Failed to set swap interval. Results may be bounded above by refresh rate.
[build] use-vbo=true: FPS: 360 FrameTime: 2.778 ms
=======================================================
                                  glmark2 Score: 366
=======================================================

gpu_top doesn't work (as there's no GPU).

I suppose the next step is to try LIBGL_ALWAYS_SOFTWARE=1 on bare metal to see what happens, but needless to say there's a bit of a mystery going on.

Tackling this from another angle, can I find what to expect from my HW? Details are here:

https://www.techpowerup.com/gpu-specs/hd-graphics-p4600.c2369

I'm not looking to optimise my system, just trying to figure out if 500 or 2500 is the more appropriate score to get.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants