Factorio is using llvmpipe instead of NVidia (Linux)

Anything that prevents you from playing the game properly. Do you have issues playing for the game, downloading it or successfully running it on your computer? Let us know here.
Post Reply
vzhilin
Manual Inserter
Manual Inserter
Posts: 3
Joined: Sat Nov 11, 2023 7:41 pm
Contact:

Factorio is using llvmpipe instead of NVidia (Linux)

Post by vzhilin »

Hi! I know that here is very similar topic, but I want to highlight that issue.

fps/ups is 8.1/59.5

factorio-current.log:

Code: Select all

   0.000 2023-11-11 20:44:43; Factorio 1.1.94 (build 61774, linux64, steam)
   0.000 Operating system: Linux
   0.000 Initializing Steam API.
   0.000 Program arguments: "/home/vzhilin/.var/app/com.valvesoftware.Steam/.local/share/Steam/steamapps/common/Factorio/bin/x64/factorio" "__GLX_VENDOR_LIBRARY_NAME=nvidia" 
   0.000 Config path: /home/vzhilin/.factorio/config/config.ini
   0.000 Read data path: /home/vzhilin/.var/app/com.valvesoftware.Steam/.local/share/Steam/steamapps/common/Factorio/data
   0.000 Write data path: /home/vzhilin/.factorio [27927/232069MB]
   0.000 Binaries path: /home/vzhilin/.var/app/com.valvesoftware.Steam/.local/share/Steam/steamapps/common/Factorio/bin
   0.003 System info: [CPU: AMD Ryzen 7 5800X 8-Core Processor, 16 cores, RAM: 63788 MB]
   0.003 Environment: DISPLAY=:99.0 WAYLAND_DISPLAY=<unset> DESKTOP_SESSION=gnome XDG_SESSION_DESKTOP=gnome XDG_CURRENT_DESKTOP=GNOME __GL_FSAA_MODE=<unset> __GL_LOG_MAX_ANISO=<unset> __GL_SYNC_TO_VBLANK=<unset> __GL_SORT_FBCONFIGS=<unset> __GL_YIELD=<unset>
   0.003 Display options: [FullScreen: 1] [VSync: 1] [UIScale: automatic (100.0%)] [Native DPI: 1] [Screen: 0] [Special: lmw] [Lang: en]
   0.008 Video driver: x11
   0.008 Available displays: 2
   0.008  [0]: BenQ EW3280U 32" - {[2160,1199], 3840x2160, SDL_PIXELFORMAT_RGB888, 60Hz}
   0.008  [1]: DELL U2718Q 28" - {[0,0], 2160x3840, SDL_PIXELFORMAT_RGB888, 60Hz}
   0.105 Initialised OpenGL:[0] llvmpipe (LLVM 15.0.7, 256 bits); driver: 4.5 (Core Profile) Mesa 23.1.9 (git-acb5ee278a)
   0.105   [Extensions] s3tc:yes; KHR_debug:yes; ARB_clear_texture:yes, ARB_copy_image:yes
   0.105   [Version] 4.5
   0.105 Verbose GraphicsInterfaceOpenGL.cpp:947: [Caps] Tex:16384, TexArr:2048, TexBufSz:131072kB; TexUnits:192; UboSz:64kB
   0.105 Graphics settings preset: very-high
   0.105   Dedicated video memory size 53952 MB
   0.122 Verbose PipelineStateObject.cpp:89: Time to load shaders: 0.017350 seconds.
   0.151 Warning GraphicsInterfaceOpenGL.cpp:245: SDL_GL_SetSwapInterval failed: That operation is not supported
   0.151 Graphics options: [Graphics quality: high] [Video memory usage: all] [DXT: high-quality] [Color: 32bit]
   0.151                   [Max threads (load/render): 32/8] [Max texture size: 0] [Tex.Stream.: 0] [Rotation quality: normal] [Other: STDCWT] [B:0,C:0,S:100]
   0.153 [Audio] Backend:SDL(default); Driver:pulseaudio, Device:Starship/Matisse HD Audio Controller Analog Stereo, Depth:16, Channels:2, Frequency:44100
   0.273 Warning GraphicsInterfaceOpenGL.cpp:245: SDL_GL_SetSwapInterval failed: That operation is not supported
   0.348 Loading mod core 0.0.0 (data.lua)
   0.413 Loading mod base 1.1.94 (data.lua)
   0.581 Loading mod base 1.1.94 (data-updates.lua)
   0.697 Checksum for core: 2152183905
   0.697 Checksum of base: 2056641960
   0.855 Prototype list checksum: 3034860339
   0.879 Verbose ModManager.cpp:608: Time to load mods: 0.532108
   0.902 Loading sounds...
   0.958 Info PlayerData.cpp:78: Local player-data.json unavailable
   0.958 Info PlayerData.cpp:81: Cloud player-data.json available, timestamp 1699731591
   1.139 Initial atlas bitmap size is 16384
   1.207 Created atlas bitmap 16384x16372 [none]
   1.247 Created atlas bitmap 16384x13232 [none]
   1.251 Created atlas bitmap 8192x4188 [decal]
   1.272 Created atlas bitmap 16384x5568 [low-object]
   1.280 Created atlas bitmap 8192x4432 [mipmap, linear-minification, linear-magnification, linear-mip-level]
   1.295 Created atlas bitmap 16384x6064 [terrain, mipmap, linear-minification, linear-mip-level]
   1.296 Created atlas bitmap 4096x3216 [terrain-effect-map, mipmap, linear-minification, linear-mip-level]
   1.297 Created atlas bitmap 4096x1840 [smoke, mipmap, linear-minification, linear-magnification]
   1.299 Created atlas bitmap 4096x3104 [mipmap]
   1.311 Created atlas bitmap 8192x2272 [icon, not-compressed, mipmap, linear-minification, linear-magnification, linear-mip-level]
   1.312 Created atlas bitmap 8192x1496 [alpha-mask]
   1.327 Created atlas bitmap 16384x14764 [shadow, linear-magnification, alpha-mask]
   1.329 Created atlas bitmap 8192x2352 [shadow, mipmap, linear-magnification, alpha-mask]
   1.329 Created atlas bitmap 2048x240 [icon-background, not-compressed, mipmap, linear-minification, linear-magnification, linear-mip-level, ]
   1.372 Verbose TextureProcessor.cpp:1123: GPU accelerated compression test: Time 42.871 ms; YCoCg_DXT PSNR: 35.83, BC3 PSNR: 33.82
   1.372 Texture processor created (2048). GPU accelerated compression Supported: yes, Enabled: yes/yes. Test passed. YCoCgDXT PSNR: 35.83, BC3 PSNR: 33.82
   2.034 Parallel Sprite Loader initialized (threads: 15)
   7.721 Sprites loaded
   7.857 Generated mipmaps (4) for atlas [3] of size 16384x5568   
   7.925 Generated mipmaps (3) for atlas [4] of size 8192x4432   
   8.022 Generated mipmaps (3) for atlas [5] of size 16384x6064   
   8.060 Generated mipmaps (3) for atlas [6] of size 4096x3216   
   8.098 Generated mipmaps (3) for atlas [7] of size 4096x1840   
   8.151 Generated mipmaps (3) for atlas [8] of size 4096x3104   
   8.190 Generated mipmaps (5) for atlas [9] of size 8192x2272   
   8.233 Generated mipmaps (3) for atlas [12] of size 8192x2352   
   8.235 Custom mipmaps uploaded (1942)
   8.235 Verbose AtlasSystem.cpp:964: Atlas memory size: 1231.19MB; 0.00MB (virtual)
   8.235 Verbose AtlasSystem.cpp:965: Size of sprites outside of atlas: 0.13MB
   8.235 Verbose ParallelSpriteLoader.cpp:183: Sprite loader stats> Worker loaded max size: 80.84MB, Total worker loaded max size: 1150.11MB
   8.353 Warning GraphicsInterfaceOpenGL.cpp:245: SDL_GL_SetSwapInterval failed: That operation is not supported
   8.353 Factorio initialised
   8.354 Steam Storage Quota: 23460/23841
   8.356 Verbose SteamContext.cpp:659: SteamUserStats initialized.
   8.376 Warning GraphicsInterfaceOpenGL.cpp:245: SDL_GL_SetSwapInterval failed: That operation is not supported
  13.821 Loading map /home/vzhilin/.factorio/saves/rocket.zip: 11445342 bytes.
  13.841 Loading level.dat: 30580889 bytes.
  13.845 Info Scenario.cpp:204: Map version 1.1.94-0
  14.141 Verbose Scenario.cpp:260: Loading level.dat finished: 0.296390 seconds.
  14.251 Verbose BlueprintLibrary.cpp:67: Loaded external blueprint storage: playerIndex=0, nextRecordID=1, timestamp=1698703077, records={{{index=0}{contents={id=player=0;id=0, type=2, label=, description=, icons={}, hash=19c0f0e686ba68a4b0c424ce7cc698104d374d97}}}
  14.251 Verbose Scenario.cpp:353: Entities setup finished: 0.109580 seconds.
  14.251 Loading script.dat: 1191 bytes.
  14.252 Checksum for script /home/vzhilin/.factorio/temp/currently-playing/control.lua: 3702463597
  14.258 Verbose Scenario.cpp:403: Map setup finished: 0.437021 seconds.
  93.514 Quitting: user-quit.
  93.676 Steam API shutdown.
  93.678 Goodbye
glxgears works just fine:

Code: Select all

[vzhilin@starship opengl]$ glxgears -info
Running synchronized to the vertical refresh.  The framerate should be
approximately the same as the monitor refresh rate.
GL_RENDERER   = NVIDIA GeForce RTX 3060/PCIe/SSE2
GL_VERSION    = 4.6.0 NVIDIA 535.129.03
GL_VENDOR     = NVIDIA Corporation
...omitted...
glxinfo:

Code: Select all

[vzhilin@starship opengl]$ glxinfo
name of display: :1
display: :1  screen: 0
direct rendering: Yes
server glx vendor string: NVIDIA Corporation
server glx version string: 1.4
server glx extensions:
...omitted...
xorg.conf:

Code: Select all

# nvidia-xconfig: X configuration file generated by nvidia-xconfig
# nvidia-xconfig:  version 545.23.06


Section "ServerLayout"
    Identifier     "Layout0"
    Screen      0  "Screen0" 0 0
    InputDevice    "Keyboard0" "CoreKeyboard"
    InputDevice    "Mouse0" "CorePointer"
EndSection

Section "Files"
EndSection

Section "InputDevice"

    # generated from default
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol" "auto"
    Option         "Device" "/dev/input/mice"
    Option         "Emulate3Buttons" "no"
    Option         "ZAxisMapping" "4 5"
EndSection

Section "InputDevice"

    # generated from default
    Identifier     "Keyboard0"
    Driver         "kbd"
EndSection

Section "Monitor"
    Identifier     "Monitor0"
    VendorName     "Unknown"
    ModelName      "Unknown"
    Option         "DPMS"
EndSection

Section "Device"
    Identifier     "Device0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    DefaultDepth    24
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection
Also I have coded small program in C:

Code: Select all

#include <math.h>
#include <stdio.h>
#include <GL/glew.h>
#include <GL/glut.h>

int main(int argc, char** argv)
{
  glutInit(&argc, argv);
  glutInitDisplayMode(GLUT_DOUBLE | GLUT_RGB);
  glutInitWindowSize(800, 600);
  glutCreateWindow("mini");

  glewExperimental = GL_TRUE;
  glewInit();

  printf(glGetString(GL_RENDERER));
  printf(glGetString(GL_VERSION));
  return 0;
}
And it returns:

Code: Select all

NVIDIA GeForce RTX 3060/PCIe/SSE24.6.0
NVIDIA 535.129.03
So as a programmer, Could I ask you to send me minimal piece of code that is responsible to OpenGL initialization to let me debug it and figure out what is happening here?

I have tried to install, reinstall and downgrade NVIDIA drivers. So it is kind of mysterious issue, let me help you to fix it.

Rseding91
Factorio Staff
Factorio Staff
Posts: 13219
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Factorio is using llvmpipe instead of NVidia (Linux)

Post by Rseding91 »

The error is coming from SDL2. A 3rd party library we use for window management.
If you want to get ahold of me I'm almost always on Discord.

vzhilin
Manual Inserter
Manual Inserter
Posts: 3
Joined: Sat Nov 11, 2023 7:41 pm
Contact:

Re: Factorio is using llvmpipe instead of NVidia (Linux)

Post by vzhilin »

🎉🎉🎉 I have solved that issue! 🎉🎉🎉

Steam and transitively Factorio are launched inside flatpack sandbox.

Flatpack is using it's own NVIDIA client driver packages.

flatpak list gives following output:

Code: Select all

 2.	   	org.freedesktop.Platform.GL.nvidia-515-43-04	1.4	u	flathub	< 359.7 MB
 3.	   	org.freedesktop.Platform.GL.nvidia-515-48-07	1.4	u	flathub	< 361.4 MB
 4.	   	org.freedesktop.Platform.GL.nvidia-515-65-01	1.4	u	flathub	< 365.1 MB
 5.	   	org.freedesktop.Platform.GL.nvidia-520-61-05	1.4	u	flathub	< 405.8 MB
 6.	   	org.freedesktop.Platform.GL.nvidia-525-60-13	1.4	u	flathub	< 414.3 MB
 7.	   	org.freedesktop.Platform.GL.nvidia-525-85-12	1.4	u	flathub	< 415.4 MB
 8.	   	org.freedesktop.Platform.GL.nvidia-530-30-02	1.4	u	flathub	< 345.1 MB
 9.	   	org.freedesktop.Platform.GL.nvidia-535-104-05	1.4	u	flathub	< 341.9 MB
10.	   	org.freedesktop.Platform.GL.nvidia-535-129-03	1.4	i	flathub	< 342.6 MB
11.	   	org.freedesktop.Platform.GL.nvidia-535-54-03	1.4	u	flathub	< 348.0 MB
12.	   	org.freedesktop.Platform.GL32.nvidia-515-43-04	1.4	u	flathub	< 359.6 MB
13.	   	org.freedesktop.Platform.GL32.nvidia-515-48-07	1.4	u	flathub	< 361.3 MB
14.	   	org.freedesktop.Platform.GL32.nvidia-515-65-01	1.4	u	flathub	< 365.0 MB
15.	   	org.freedesktop.Platform.GL32.nvidia-520-61-05	1.4	u	flathub	< 405.7 MB
16.	   	org.freedesktop.Platform.GL32.nvidia-525-60-13	1.4	u	flathub	< 414.2 MB
17.	   	org.freedesktop.Platform.GL32.nvidia-525-85-12	1.4	u	flathub	< 415.3 MB
18.	   	org.freedesktop.Platform.GL32.nvidia-530-30-02	1.4	u	flathub	< 345.0 MB
19.	   	org.freedesktop.Platform.GL32.nvidia-535-104-05	1.4	u	flathub	< 341.8 MB
20.	   	org.freedesktop.Platform.GL32.nvidia-535-129-03	1.4	i	flathub	< 342.5 MB
21.	   	org.freedesktop.Platform.GL32.nvidia-535-54-03	1.4	u	flathub	< 348.0 MB
So I just removed all extra packages, leaving only one that is matching my driver version. Restarted Steam and finally it works!!!

Thank you!

Post Reply

Return to “Technical Help”