How to Benchmark your GPU on Linux

Linux is not famous for its gaming abilities and possibilities, and it is only natural that there aren't many GPU benchmarking tools available with which users can test their graphics hardware. There are however some benchmarking suites that can help you determine the various aspects of your GPU performance with precision. These are very important for the drawing of solid conclusions, technical and numerical comparison, or for the satisfaction of a plain interest on how (well) things work. Technically speaking, all of the available GPU benchmarking tools in Linux only test under the OpenGL renderer of course. While your GPU may be compatible with some versions of Direct3D, it is not possible to test this renderer under Linux.

GLX-Gears

GLX gears is a popular OpenGL test that is part of the “mesa-utils” package. Install the package on Ubuntu with this command:

sudo apt install mesa-utils

You can invoke it by typing “glxgears” on a terminal.

glxgears

This will open up a window with an OpenGL rendering of a simple arrangement of three rotating gears. The frame rate is measured and printed out on the terminal every five seconds. This tool is very old, very basic and only tests a small portion of today's OpenGL capabilities. Back in the old days, it was used to determine if the proprietary driver was installed and running properly as open-source drivers were performing awfully enough to be perfectly noticeable during this test. Nowadays, you won't notice any difference between the two (in glxgears).

GLX Gears Benchmark

GL Mark 2

GL mark is a much richer benchmarking tool developed by the kind people behind the Linaro distribution. Contrary to glxgears, glmark offers a rich set of tests that concern different aspects of your graphics unit performance (buffering, building, lighting, texturing etc), allowing for a much more comprehensive and meaningful test. Each test is conducted for 10 seconds and the frame rate is counted individually. In the end, users get a performance score based on all previous tests. I like this tool for its simplicity and flawless operation. You can find it as a pre-built package in most distributions under the name “glmark2”. Install it with:

sudo apt-get install glmark2

on Ubuntu.

After installing it, you may run it by typing “glmark2” on a terminal.

glmark2

GL Mark 2

OpenGL Benchmark

Unigine Benchmark Products

Finally, for users that seek something more advanced than the previous two tools, there are four benchmark tools that use the Unigine 3D engine. These are the Valley, Heaven, Tropics, and Sanctuary which offer free versions that can be downloaded from the Unigine website. These benchmarking tools boast real-time ambient occlusion, interplaying lights from different sources, HDR renderings, realistic water, and a dynamic sky with atmospheric light scattering. Users may also set the anti-aliasing levels, texture quality and filtering, anisotropy, and shader quality. Besides hitting that “benchmark” button that will test your hardware in 10 steps, you may also wander around freely, change the time of day (which changes the lighting of the world) and accurately determine the conditions that “bend” your hardware the most.

Unigine GPU Benchmark

Linux GPU Benchmark running

Share this page:

Suggested articles

18 Comment(s)

Add comment

Comments

By: zergel at: 2016-07-12 06:57:20

Thanks this is very helpful! :D

By: behzad at: 2016-08-16 18:02:41

Finally, I can compare my graphic cards on linux. Thank you.

By: pg1 at: 2016-10-11 21:20:36

Thanks! It helps me benchmark my old and new video card in Linux Mint.

By: ummer Muqthiar A at: 2017-02-06 11:05:19

Thank U :)

By: federico kiczka at: 2017-06-02 00:38:17

thank you for this benchmark LINUX is the gretest O.S.

By: search_engine_user_1096832495 at: 2017-11-03 16:47:54

Very detailed and excellent tutorial. I used this on Ubuntu 17.10 to test out the difference between nvidia and nouveu drivers.

By: Ryan at: 2018-01-13 02:42:57

I get a seg fault when I do try to run the jellyfish (im new to linux, im on ubuntu)

I typed commands same as u said for jellyfish, have nvida card (onyx pro laptop from system 76)

By: tony at: 2018-12-16 05:00:52

helpfull. i was able to test some stuff out on my mint macbook install. =)

By: Catalufots at: 2018-12-26 15:33:38

ok wow for free I find that is much better than 3DMark. Good job mate!

By: Nishandh mayiladan at: 2019-02-07 19:23:21

Appreciate this effort very much, Bill Toulas !I was trying to install PhoronixTS in two systems and was taking forever to get similar installation in both systems. Got tp know th performance differences fast and easy this way !

By: Sudo Sue at: 2019-03-11 19:19:05

Blender exists, as well! It is a 3D program that you can download test renders for, and use the time of rendering single frames as a scale reference.

By: Merc at: 2019-06-19 06:17:49

Thanks, worked like a charm on Ubutu

By: Mr.Rdr at: 2020-04-20 16:15:56

Thanks for the article.

Just a suggestion, and that is not particular to this article, I think it would be relevant an useful for most "how to's" to include when it was written, and when possible also what "system" that it was "tested/used on". Best regards

By: Nikolay at: 2020-04-21 21:17:16

I'm just running this on my PC but I need some help in diagnosing my video card. I'm suffering from at random (mostly when youtbe playing but it happen also while playing withcer) time fedora freeze and some time I'm losing display signal again randomly and realy rare .

glmark2

=======================================================

    glmark2 2017.07

=======================================================

    OpenGL Information

    GL_VENDOR:     X.Org

    GL_RENDERER:   Radeon RX 560 Series (POLARIS11, DRM 3.36.0, 5.5.16-200.fc31.x86_64, LLVM 9.0.0)

    GL_VERSION:    4.5 (Compatibility Profile) Mesa 19.2.8

=======================================================

[build] use-vbo=false: FPS: 2131 FrameTime: 0.469 ms

[build] use-vbo=true: FPS: 5841 FrameTime: 0.171 ms

[texture] texture-filter=nearest: FPS: 4901 FrameTime: 0.204 ms

[texture] texture-filter=linear: FPS: 4388 FrameTime: 0.228 ms

[texture] texture-filter=mipmap: FPS: 3496 FrameTime: 0.286 ms

[shading] shading=gouraud: FPS: 2745 FrameTime: 0.364 ms

[shading] shading=blinn-phong-inf: FPS: 2610 FrameTime: 0.383 ms

[shading] shading=phong: FPS: 2295 FrameTime: 0.436 ms

[shading] shading=cel: FPS: 2111 FrameTime: 0.474 ms

[bump] bump-render=high-poly: FPS: 1475 FrameTime: 0.678 ms

[bump] bump-render=normals: FPS: 2235 FrameTime: 0.447 ms

[bump] bump-render=height: FPS: 2098 FrameTime: 0.477 ms

[effect2d] kernel=0,1,0;1,-4,1;0,1,0;: FPS: 1881 FrameTime: 0.532 ms

[effect2d] kernel=1,1,1,1,1;1,1,1,1,1;1,1,1,1,1;: FPS: 1180 FrameTime: 0.847 ms

[pulsar] light=false:quads=5:texture=false: FPS: 1831 FrameTime: 0.546 ms

[desktop] blur-radius=5:effect=blur:passes=1:separable=true:windows=4: FPS: 861 FrameTime: 1.161 ms

[desktop] effect=shadow:windows=4: FPS: 1377 FrameTime: 0.726 ms

[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 650 FrameTime: 1.538 ms

[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=subdata: FPS: 713 FrameTime: 1.403 ms

[buffer] columns=200:interleave=true:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 748 FrameTime: 1.337 ms

[ideas] speed=duration: FPS: 1600 FrameTime: 0.625 ms

[jellyfish] <default>: FPS: 1477 FrameTime: 0.677 ms

[terrain] <default>: FPS: 204 FrameTime: 4.902 ms

[shadow] <default>: FPS: 1486 FrameTime: 0.673 ms

[refract] <default>: FPS: 443 FrameTime: 2.257 ms

[conditionals] fragment-steps=0:vertex-steps=0: FPS: 1909 FrameTime: 0.524 ms

[conditionals] fragment-steps=5:vertex-steps=0: FPS: 1905 FrameTime: 0.525 ms

[conditionals] fragment-steps=0:vertex-steps=5: FPS: 1893 FrameTime: 0.528 ms

[function] fragment-complexity=low:fragment-steps=5: FPS: 1909 FrameTime: 0.524 ms

[function] fragment-complexity=medium:fragment-steps=5: FPS: 1907 FrameTime: 0.524 ms

[loop] fragment-loop=false:fragment-steps=5:vertex-steps=5: FPS: 1899 FrameTime: 0.527 ms

[loop] fragment-steps=5:fragment-uniform=false:vertex-steps=5: FPS: 1910 FrameTime: 0.524 ms

[loop] fragment-steps=5:fragment-uniform=true:vertex-steps=5: FPS: 1905 FrameTime: 0.525 ms

=======================================================

                                  glmark2 Score: 2000 

 

=======================================================

 

By: Alexai at: 2020-07-02 04:37:47

Thanks, now I can test and know my laptop GPU performance.I am using Ryzen 5 2500u

By: islamux at: 2021-03-13 20:02:11

Thanks 

By: Joseph Donahue at: 2021-07-18 15:41:01

I really appreciate this post. I¡¦ve been looking all over for this! Thank goodness I found it on Bing. You have made my day! Thank you again.

By: waheed at: 2021-09-19 14:18:37

=======================================================    glmark2 2021.02 =======================================================    OpenGL Information    GL_VENDOR:     AMD    GL_RENDERER:   AMD Radeon HD 7800 Series (specficially 7850 a bit tuned) (PITCAIRN, DRM 3.42.0, 5.15.0-rc1bargos+, LLVM 12.0.0)    GL_VERSION:    4.6 (Compatibility Profile) Mesa 21.2.1 ======================================================= [build] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:interleave=false:model=horse:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:use-vbo=false:vertex-precision=default,default,default,default: FPS: 2354 FrameTime: 0.425 ms [build] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:interleave=false:model=horse:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:use-vbo=true:vertex-precision=default,default,default,default: FPS: 2855 FrameTime: 0.350 ms [texture] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:model=cube:nframes=:show-fps=false:texgen=false:texture=crate-base:texture-filter=nearest:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 2784 FrameTime: 0.359 ms [texture] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:model=cube:nframes=:show-fps=false:texgen=false:texture=crate-base:texture-filter=linear:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 2786 FrameTime: 0.359 ms [texture] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:model=cube:nframes=:show-fps=false:texgen=false:texture=crate-base:texture-filter=mipmap:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 2789 FrameTime: 0.359 ms [shading] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:model=cat:nframes=:num-lights=1:shading=gouraud:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 2687 FrameTime: 0.372 ms [shading] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:model=cat:nframes=:num-lights=1:shading=blinn-phong-inf:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 2687 FrameTime: 0.372 ms [shading] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:model=cat:nframes=:num-lights=1:shading=phong:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 2628 FrameTime: 0.381 ms [shading] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:model=cat:nframes=:num-lights=1:shading=cel:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 2585 FrameTime: 0.387 ms [bump] bump-render=high-poly:duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 2490 FrameTime: 0.402 ms [bump] bump-render=normals:duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 2820 FrameTime: 0.355 ms [bump] bump-render=height:duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 2780 FrameTime: 0.360 ms [effect2d] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:kernel=0,1,0;1,-4,1;0,1,0;:nframes=:normalize=true:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 1956 FrameTime: 0.511 ms [effect2d] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:kernel=1,1,1,1,1;1,1,1,1,1;1,1,1,1,1;:nframes=:normalize=true:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 938 FrameTime: 1.066 ms [pulsar] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:light=false:nframes=:quads=5:random=false:show-fps=false:texture=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 2493 FrameTime: 0.401 ms [desktop] blur-radius=5:duration=10.0:effect=blur:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:nframes=:passes=1:separable=true:shadow-size=20:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default:window-size=0.35:windows=4: FPS: 970 FrameTime: 1.031 ms [desktop] blur-radius=5:duration=10.0:effect=shadow:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:nframes=:passes=1:separable=true:shadow-size=20:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default:window-size=0.35:windows=4: FPS: 1497 FrameTime: 0.668 ms [buffer] buffer-usage=static:columns=200:duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:interleave=false:nframes=:rows=20:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:update-dispersion=0.9:update-fraction=0.5:update-method=map:vertex-precision=default,default,default,default: FPS: 1593 FrameTime: 0.628 ms [buffer] buffer-usage=static:columns=200:duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:interleave=false:nframes=:rows=20:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:update-dispersion=0.9:update-fraction=0.5:update-method=subdata:vertex-precision=default,default,default,default: FPS: 1814 FrameTime: 0.551 ms [buffer] buffer-usage=static:columns=200:duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:interleave=true:nframes=:rows=20:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:update-dispersion=0.9:update-fraction=0.5:update-method=map:vertex-precision=default,default,default,default: FPS: 1914 FrameTime: 0.522 ms [ideas] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:nframes=:show-fps=false:speed=duration:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 2565 FrameTime: 0.390 ms [jellyfish] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 1964 FrameTime: 0.509 ms [terrain] bloom=true:duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:nframes=:repeat-overlay=6.0:show-fps=false:tilt-shift=true:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-precision=default,default,default,default: FPS: 274 FrameTime: 3.650 ms [shadow] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:interleave=false:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:use-vbo=true:vertex-precision=default,default,default,default: FPS: 1083 FrameTime: 0.923 ms [refract] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-precision=default,default,default,default:index=1.2:interleave=false:model=bunny:nframes=:show-fps=false:texture=nasa1:title=:title-pos=-0.7,-1.0:title-size=0.03:use-vbo=true:vertex-precision=default,default,default,default: FPS: 394 FrameTime: 2.538 ms [conditionals] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-conditionals=true:fragment-precision=default,default,default,default:fragment-steps=0:grid-length=5.0:grid-size=32:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-conditionals=true:vertex-precision=default,default,default,default:vertex-steps=0: FPS: 2828 FrameTime: 0.354 ms [conditionals] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-conditionals=true:fragment-precision=default,default,default,default:fragment-steps=5:grid-length=5.0:grid-size=32:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-conditionals=true:vertex-precision=default,default,default,default:vertex-steps=0: FPS: 2822 FrameTime: 0.354 ms [conditionals] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-conditionals=true:fragment-precision=default,default,default,default:fragment-steps=0:grid-length=5.0:grid-size=32:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-conditionals=true:vertex-precision=default,default,default,default:vertex-steps=5: FPS: 2822 FrameTime: 0.354 ms [function] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-complexity=low:fragment-function=true:fragment-precision=default,default,default,default:fragment-steps=5:grid-length=5.0:grid-size=32:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-complexity=low:vertex-function=true:vertex-precision=default,default,default,default:vertex-steps=1: FPS: 2819 FrameTime: 0.355 ms [function] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-complexity=medium:fragment-function=true:fragment-precision=default,default,default,default:fragment-steps=5:grid-length=5.0:grid-size=32:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-complexity=low:vertex-function=true:vertex-precision=default,default,default,default:vertex-steps=1: FPS: 2776 FrameTime: 0.360 ms [loop] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-loop=false:fragment-precision=default,default,default,default:fragment-steps=5:fragment-uniform=true:grid-length=5.0:grid-size=32:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-loop=true:vertex-precision=default,default,default,default:vertex-steps=5:vertex-uniform=true: FPS: 2815 FrameTime: 0.355 ms [loop] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-loop=true:fragment-precision=default,default,default,default:fragment-steps=5:fragment-uniform=false:grid-length=5.0:grid-size=32:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-loop=true:vertex-precision=default,default,default,default:vertex-steps=5:vertex-uniform=true: FPS: 2817 FrameTime: 0.355 ms [loop] duration=10.0:fps-pos=-1.0,-1.0:fps-size=0.03:fragment-loop=true:fragment-precision=default,default,default,default:fragment-steps=5:fragment-uniform=true:grid-length=5.0:grid-size=32:nframes=:show-fps=false:title=:title-pos=-0.7,-1.0:title-size=0.03:vertex-loop=true:vertex-precision=default,default,default,default:vertex-steps=5:vertex-uniform=true: FPS: 2815 FrameTime: 0.355 ms =======================================================                                  glmark2 Score: 2248  ======================================================= [email protected]:/home/bargo# cat gl_mark