Erik Faye-Lund | 4d06683 | 2020-06-12 20:09:42 +0200 | [diff] [blame] | 1 | Environment Variables |
| 2 | ===================== |
| 3 | |
| 4 | Normally, no environment variables need to be set. Most of the |
| 5 | environment variables used by Mesa/Gallium are for debugging purposes, |
| 6 | but they can sometimes be useful for debugging end-user issues. |
| 7 | |
| 8 | LibGL environment variables |
| 9 | --------------------------- |
| 10 | |
| 11 | ``LIBGL_DEBUG`` |
| 12 | If defined debug information will be printed to stderr. If set to |
| 13 | ``verbose`` additional information will be printed. |
| 14 | ``LIBGL_DRIVERS_PATH`` |
| 15 | colon-separated list of paths to search for DRI drivers |
| 16 | ``LIBGL_ALWAYS_INDIRECT`` |
| 17 | if set to ``true``, forces an indirect rendering context/connection. |
| 18 | ``LIBGL_ALWAYS_SOFTWARE`` |
| 19 | if set to ``true``, always use software rendering |
| 20 | ``LIBGL_NO_DRAWARRAYS`` |
| 21 | if set to ``true``, do not use DrawArrays GLX protocol (for |
| 22 | debugging) |
| 23 | ``LIBGL_SHOW_FPS`` |
| 24 | print framerate to stdout based on the number of ``glXSwapBuffers`` |
| 25 | calls per second. |
| 26 | ``LIBGL_DRI3_DISABLE`` |
| 27 | disable DRI3 if set to ``true``. |
| 28 | |
| 29 | Core Mesa environment variables |
| 30 | ------------------------------- |
| 31 | |
| 32 | ``MESA_NO_ASM`` |
| 33 | if set, disables all assembly language optimizations |
| 34 | ``MESA_NO_MMX`` |
| 35 | if set, disables Intel MMX optimizations |
| 36 | ``MESA_NO_3DNOW`` |
| 37 | if set, disables AMD 3DNow! optimizations |
| 38 | ``MESA_NO_SSE`` |
| 39 | if set, disables Intel SSE optimizations |
| 40 | ``MESA_NO_ERROR`` |
| 41 | if set to 1, error checking is disabled as per ``KHR_no_error``. This |
| 42 | will result in undefined behaviour for invalid use of the api, but |
| 43 | can reduce CPU use for apps that are known to be error free. |
| 44 | ``MESA_DEBUG`` |
| 45 | if set, error messages are printed to stderr. For example, if the |
| 46 | application generates a ``GL_INVALID_ENUM`` error, a corresponding |
| 47 | error message indicating where the error occurred, and possibly why, |
| 48 | will be printed to stderr. For release builds, ``MESA_DEBUG`` |
| 49 | defaults to off (no debug output). ``MESA_DEBUG`` accepts the |
| 50 | following comma-separated list of named flags, which adds extra |
| 51 | behaviour to just set ``MESA_DEBUG=1``: |
| 52 | |
| 53 | ``silent`` |
| 54 | turn off debug messages. Only useful for debug builds. |
| 55 | ``flush`` |
| 56 | flush after each drawing command |
| 57 | ``incomplete_tex`` |
| 58 | extra debug messages when a texture is incomplete |
| 59 | ``incomplete_fbo`` |
| 60 | extra debug messages when a fbo is incomplete |
| 61 | ``context`` |
| 62 | create a debug context (see ``GLX_CONTEXT_DEBUG_BIT_ARB``) and |
| 63 | print error and performance messages to stderr (or |
| 64 | ``MESA_LOG_FILE``). |
| 65 | |
| 66 | ``MESA_LOG_FILE`` |
| 67 | specifies a file name for logging all errors, warnings, etc., rather |
| 68 | than stderr |
| 69 | ``MESA_TEX_PROG`` |
| 70 | if set, implement conventional texture env modes with fragment |
| 71 | programs (intended for developers only) |
| 72 | ``MESA_TNL_PROG`` |
| 73 | if set, implement conventional vertex transformation operations with |
| 74 | vertex programs (intended for developers only). Setting this variable |
| 75 | automatically sets the ``MESA_TEX_PROG`` variable as well. |
| 76 | ``MESA_EXTENSION_OVERRIDE`` |
| 77 | can be used to enable/disable extensions. A value such as |
| 78 | ``GL_EXT_foo -GL_EXT_bar`` will enable the ``GL_EXT_foo`` extension |
| 79 | and disable the ``GL_EXT_bar`` extension. |
| 80 | ``MESA_EXTENSION_MAX_YEAR`` |
| 81 | The ``GL_EXTENSIONS`` string returned by Mesa is sorted by extension |
| 82 | year. If this variable is set to year X, only extensions defined on |
| 83 | or before year X will be reported. This is to work-around a bug in |
| 84 | some games where the extension string is copied into a fixed-size |
| 85 | buffer without truncating. If the extension string is too long, the |
| 86 | buffer overrun can cause the game to crash. This is a work-around for |
| 87 | that. |
| 88 | ``MESA_GL_VERSION_OVERRIDE`` |
| 89 | changes the value returned by ``glGetString(GL_VERSION)`` and |
| 90 | possibly the GL API type. |
| 91 | |
| 92 | - The format should be ``MAJOR.MINOR[FC|COMPAT]`` |
| 93 | - ``FC`` is an optional suffix that indicates a forward compatible |
| 94 | context. This is only valid for versions >= 3.0. |
| 95 | - ``COMPAT`` is an optional suffix that indicates a compatibility |
| 96 | context or ``GL_ARB_compatibility`` support. This is only valid |
| 97 | for versions >= 3.1. |
| 98 | - GL versions <= 3.0 are set to a compatibility (non-Core) profile |
| 99 | - GL versions = 3.1, depending on the driver, it may or may not have |
| 100 | the ``ARB_compatibility`` extension enabled. |
| 101 | - GL versions >= 3.2 are set to a Core profile |
| 102 | - Examples: |
| 103 | |
| 104 | ``2.1`` |
| 105 | select a compatibility (non-Core) profile with GL version 2.1. |
| 106 | ``3.0`` |
| 107 | select a compatibility (non-Core) profile with GL version 3.0. |
| 108 | ``3.0FC`` |
| 109 | select a Core+Forward Compatible profile with GL version 3.0. |
| 110 | ``3.1`` |
| 111 | select GL version 3.1 with ``GL_ARB_compatibility`` enabled per |
| 112 | the driver default. |
| 113 | ``3.1FC`` |
| 114 | select GL version 3.1 with forward compatibility and |
| 115 | ``GL_ARB_compatibility`` disabled. |
| 116 | ``3.1COMPAT`` |
| 117 | select GL version 3.1 with ``GL_ARB_compatibility`` enabled. |
| 118 | ``X.Y`` |
| 119 | override GL version to X.Y without changing the profile. |
| 120 | ``X.YFC`` |
| 121 | select a Core+Forward Compatible profile with GL version X.Y. |
| 122 | ``X.YCOMPAT`` |
| 123 | select a Compatibility profile with GL version X.Y. |
| 124 | |
| 125 | - Mesa may not really implement all the features of the given |
| 126 | version. (for developers only) |
| 127 | |
| 128 | ``MESA_GLES_VERSION_OVERRIDE`` |
| 129 | changes the value returned by ``glGetString(GL_VERSION)`` for OpenGL |
| 130 | ES. |
| 131 | |
| 132 | - The format should be ``MAJOR.MINOR`` |
| 133 | - Examples: ``2.0``, ``3.0``, ``3.1`` |
| 134 | - Mesa may not really implement all the features of the given |
| 135 | version. (for developers only) |
| 136 | |
| 137 | ``MESA_GLSL_VERSION_OVERRIDE`` |
| 138 | changes the value returned by |
| 139 | ``glGetString(GL_SHADING_LANGUAGE_VERSION)``. Valid values are |
| 140 | integers, such as ``130``. Mesa will not really implement all the |
| 141 | features of the given language version if it's higher than what's |
| 142 | normally reported. (for developers only) |
| 143 | ``MESA_GLSL_CACHE_DISABLE`` |
| 144 | if set to ``true``, disables the GLSL shader cache |
| 145 | ``MESA_GLSL_CACHE_MAX_SIZE`` |
| 146 | if set, determines the maximum size of the on-disk cache of compiled |
| 147 | GLSL programs. Should be set to a number optionally followed by |
| 148 | ``K``, ``M``, or ``G`` to specify a size in kilobytes, megabytes, or |
| 149 | gigabytes. By default, gigabytes will be assumed. And if unset, a |
Erik Faye-Lund | bf3f0f7 | 2019-06-04 10:39:58 +0200 | [diff] [blame^] | 150 | maximum size of 1GB will be used. |
| 151 | |
| 152 | .. note:: |
| 153 | |
| 154 | A separate cache might be created for each architecture that Mesa is |
| 155 | installed for on your system. For example under the default settings |
| 156 | you may end up with a 1GB cache for x86_64 and another 1GB cache for |
| 157 | i386. |
| 158 | |
Erik Faye-Lund | 4d06683 | 2020-06-12 20:09:42 +0200 | [diff] [blame] | 159 | ``MESA_GLSL_CACHE_DIR`` |
| 160 | if set, determines the directory to be used for the on-disk cache of |
| 161 | compiled GLSL programs. If this variable is not set, then the cache |
| 162 | will be stored in ``$XDG_CACHE_HOME/mesa_shader_cache`` (if that |
| 163 | variable is set), or else within ``.cache/mesa_shader_cache`` within |
| 164 | the user's home directory. |
| 165 | ``MESA_GLSL`` |
| 166 | `shading language compiler options <shading.html#envvars>`__ |
| 167 | ``MESA_NO_MINMAX_CACHE`` |
| 168 | when set, the minmax index cache is globally disabled. |
| 169 | ``MESA_SHADER_CAPTURE_PATH`` |
| 170 | see `Capturing Shaders <shading.html#capture>`__ |
| 171 | ``MESA_SHADER_DUMP_PATH`` and ``MESA_SHADER_READ_PATH`` |
| 172 | see `Experimenting with Shader |
| 173 | Replacements <shading.html#replacement>`__ |
| 174 | ``MESA_VK_VERSION_OVERRIDE`` |
| 175 | changes the Vulkan physical device version as returned in |
| 176 | ``VkPhysicalDeviceProperties::apiVersion``. |
| 177 | |
| 178 | - The format should be ``MAJOR.MINOR[.PATCH]`` |
| 179 | - This will not let you force a version higher than the driver's |
| 180 | instance version as advertised by ``vkEnumerateInstanceVersion`` |
| 181 | - This can be very useful for debugging but some features may not be |
| 182 | implemented correctly. (For developers only) |
| 183 | |
| 184 | NIR passes enviroment variables |
| 185 | ------------------------------- |
| 186 | |
| 187 | The following are only applicable for drivers that uses NIR, as they |
| 188 | modify the behaviour for the common NIR_PASS and NIR_PASS_V macros, that |
| 189 | wrap calls to NIR lowering/optimizations. |
| 190 | |
| 191 | ``NIR_PRINT`` |
| 192 | If defined, the resulting NIR shader will be printed out at each |
| 193 | succesful NIR lowering/optimization call. |
| 194 | ``NIR_TEST_CLONE`` |
| 195 | If defined, cloning a NIR shader would be tested at each succesful |
| 196 | NIR lowering/optimization call. |
| 197 | ``NIR_TEST_SERIALIZE`` |
| 198 | If defined, serialize and deserialize a NIR shader would be tested at |
| 199 | each succesful NIR lowering/optimization call. |
| 200 | |
| 201 | Mesa Xlib driver environment variables |
| 202 | -------------------------------------- |
| 203 | |
| 204 | The following are only applicable to the Mesa Xlib software driver. See |
| 205 | the `Xlib software driver page <xlibdriver.html>`__ for details. |
| 206 | |
| 207 | ``MESA_RGB_VISUAL`` |
| 208 | specifies the X visual and depth for RGB mode |
| 209 | ``MESA_CI_VISUAL`` |
| 210 | specifies the X visual and depth for CI mode |
| 211 | ``MESA_BACK_BUFFER`` |
| 212 | specifies how to implement the back color buffer, either ``pixmap`` |
| 213 | or ``ximage`` |
| 214 | ``MESA_GAMMA`` |
| 215 | gamma correction coefficients for red, green, blue channels |
| 216 | ``MESA_XSYNC`` |
| 217 | enable synchronous X behavior (for debugging only) |
| 218 | ``MESA_GLX_FORCE_CI`` |
| 219 | if set, force GLX to treat 8bpp visuals as CI visuals |
| 220 | ``MESA_GLX_FORCE_ALPHA`` |
| 221 | if set, forces RGB windows to have an alpha channel. |
| 222 | ``MESA_GLX_DEPTH_BITS`` |
| 223 | specifies default number of bits for depth buffer. |
| 224 | ``MESA_GLX_ALPHA_BITS`` |
| 225 | specifies default number of bits for alpha channel. |
| 226 | |
| 227 | i945/i965 driver environment variables (non-Gallium) |
| 228 | ---------------------------------------------------- |
| 229 | |
| 230 | ``INTEL_NO_HW`` |
| 231 | if set to 1, prevents batches from being submitted to the hardware. |
| 232 | This is useful for debugging hangs, etc. |
| 233 | ``INTEL_DEBUG`` |
| 234 | a comma-separated list of named flags, which do various things: |
| 235 | |
| 236 | ``ann`` |
| 237 | annotate IR in assembly dumps |
| 238 | ``aub`` |
| 239 | dump batches into an AUB trace for use with simulation tools |
| 240 | ``bat`` |
| 241 | emit batch information |
| 242 | ``blit`` |
| 243 | emit messages about blit operations |
| 244 | ``blorp`` |
| 245 | emit messages about the blorp operations (blits & clears) |
| 246 | ``buf`` |
| 247 | emit messages about buffer objects |
| 248 | ``clip`` |
| 249 | emit messages about the clip unit (for old gens, includes the CLIP |
| 250 | program) |
| 251 | ``color`` |
| 252 | use color in output |
| 253 | ``cs`` |
| 254 | dump shader assembly for compute shaders |
| 255 | ``do32`` |
| 256 | generate compute shader SIMD32 programs even if workgroup size |
| 257 | doesn't exceed the SIMD16 limit |
| 258 | ``dri`` |
| 259 | emit messages about the DRI interface |
| 260 | ``fbo`` |
| 261 | emit messages about framebuffers |
| 262 | ``fs`` |
| 263 | dump shader assembly for fragment shaders |
| 264 | ``gs`` |
| 265 | dump shader assembly for geometry shaders |
| 266 | ``hex`` |
| 267 | print instruction hex dump with the disassembly |
| 268 | ``l3`` |
| 269 | emit messages about the new L3 state during transitions |
| 270 | ``miptree`` |
| 271 | emit messages about miptrees |
| 272 | ``no8`` |
| 273 | don't generate SIMD8 fragment shader |
| 274 | ``no16`` |
| 275 | suppress generation of 16-wide fragment shaders. useful for |
| 276 | debugging broken shaders |
| 277 | ``nocompact`` |
| 278 | disable instruction compaction |
| 279 | ``nodualobj`` |
| 280 | suppress generation of dual-object geometry shader code |
| 281 | ``nofc`` |
| 282 | disable fast clears |
| 283 | ``norbc`` |
| 284 | disable single sampled render buffer compression |
| 285 | ``optimizer`` |
| 286 | dump shader assembly to files at each optimization pass and |
| 287 | iteration that make progress |
| 288 | ``perf`` |
| 289 | emit messages about performance issues |
| 290 | ``perfmon`` |
| 291 | emit messages about ``AMD_performance_monitor`` |
| 292 | ``pix`` |
| 293 | emit messages about pixel operations |
| 294 | ``prim`` |
| 295 | emit messages about drawing primitives |
| 296 | ``reemit`` |
| 297 | mark all state dirty on each draw call |
| 298 | ``sf`` |
| 299 | emit messages about the strips & fans unit (for old gens, includes |
| 300 | the SF program) |
| 301 | ``shader_time`` |
| 302 | record how much GPU time is spent in each shader |
| 303 | ``spill_fs`` |
| 304 | force spilling of all registers in the scalar backend (useful to |
| 305 | debug spilling code) |
| 306 | ``spill_vec4`` |
| 307 | force spilling of all registers in the vec4 backend (useful to |
| 308 | debug spilling code) |
| 309 | ``state`` |
| 310 | emit messages about state flag tracking |
| 311 | ``submit`` |
| 312 | emit batchbuffer usage statistics |
| 313 | ``sync`` |
| 314 | after sending each batch, emit a message and wait for that batch |
| 315 | to finish rendering |
| 316 | ``tcs`` |
| 317 | dump shader assembly for tessellation control shaders |
| 318 | ``tes`` |
| 319 | dump shader assembly for tessellation evaluation shaders |
| 320 | ``tex`` |
| 321 | emit messages about textures. |
| 322 | ``urb`` |
| 323 | emit messages about URB setup |
| 324 | ``vert`` |
| 325 | emit messages about vertex assembly |
| 326 | ``vs`` |
| 327 | dump shader assembly for vertex shaders |
| 328 | |
| 329 | ``INTEL_SCALAR_VS`` (or ``TCS``, ``TES``, ``GS``) |
| 330 | force scalar/vec4 mode for a shader stage (Gen8-9 only) |
| 331 | ``INTEL_PRECISE_TRIG`` |
| 332 | if set to 1, true or yes, then the driver prefers accuracy over |
| 333 | performance in trig functions. |
| 334 | |
| 335 | Radeon driver environment variables (radeon, r200, and r300g) |
| 336 | ------------------------------------------------------------- |
| 337 | |
| 338 | ``RADEON_NO_TCL`` |
| 339 | if set, disable hardware-accelerated Transform/Clip/Lighting. |
| 340 | |
| 341 | EGL environment variables |
| 342 | ------------------------- |
| 343 | |
| 344 | Mesa EGL supports different sets of environment variables. See the `Mesa |
| 345 | EGL <egl.html>`__ page for the details. |
| 346 | |
| 347 | Gallium environment variables |
| 348 | ----------------------------- |
| 349 | |
| 350 | ``GALLIUM_HUD`` |
| 351 | draws various information on the screen, like framerate, cpu load, |
| 352 | driver statistics, performance counters, etc. Set |
| 353 | ``GALLIUM_HUD=help`` and run e.g. ``glxgears`` for more info. |
| 354 | ``GALLIUM_HUD_PERIOD`` |
| 355 | sets the hud update rate in seconds (float). Use zero to update every |
| 356 | frame. The default period is 1/2 second. |
| 357 | ``GALLIUM_HUD_VISIBLE`` |
| 358 | control default visibility, defaults to true. |
| 359 | ``GALLIUM_HUD_TOGGLE_SIGNAL`` |
| 360 | toggle visibility via user specified signal. Especially useful to |
| 361 | toggle hud at specific points of application and disable for |
| 362 | unencumbered viewing the rest of the time. For example, set |
| 363 | ``GALLIUM_HUD_VISIBLE`` to ``false`` and |
| 364 | ``GALLIUM_HUD_TOGGLE_SIGNAL`` to ``10`` (``SIGUSR1``). Use |
| 365 | ``kill -10 <pid>`` to toggle the hud as desired. |
| 366 | ``GALLIUM_HUD_SCALE`` |
| 367 | Scale hud by an integer factor, for high DPI displays. Default is 1. |
| 368 | ``GALLIUM_HUD_DUMP_DIR`` |
| 369 | specifies a directory for writing the displayed hud values into |
| 370 | files. |
| 371 | ``GALLIUM_DRIVER`` |
| 372 | useful in combination with ``LIBGL_ALWAYS_SOFTWARE=true`` for |
| 373 | choosing one of the software renderers ``softpipe``, ``llvmpipe`` or |
| 374 | ``swr``. |
| 375 | ``GALLIUM_LOG_FILE`` |
| 376 | specifies a file for logging all errors, warnings, etc. rather than |
| 377 | stderr. |
| 378 | ``GALLIUM_PRINT_OPTIONS`` |
| 379 | if non-zero, print all the Gallium environment variables which are |
| 380 | used, and their current values. |
| 381 | ``GALLIUM_DUMP_CPU`` |
| 382 | if non-zero, print information about the CPU on start-up |
| 383 | ``TGSI_PRINT_SANITY`` |
| 384 | if set, do extra sanity checking on TGSI shaders and print any errors |
| 385 | to stderr. |
| 386 | ``DRAW_FSE`` |
| 387 | ??? |
| 388 | ``DRAW_NO_FSE`` |
| 389 | ??? |
| 390 | ``DRAW_USE_LLVM`` |
| 391 | if set to zero, the draw module will not use LLVM to execute shaders, |
| 392 | vertex fetch, etc. |
| 393 | ``ST_DEBUG`` |
| 394 | controls debug output from the Mesa/Gallium state tracker. Setting to |
| 395 | ``tgsi``, for example, will print all the TGSI shaders. See |
| 396 | ``src/mesa/state_tracker/st_debug.c`` for other options. |
| 397 | |
| 398 | Clover environment variables |
| 399 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 400 | |
| 401 | ``CLOVER_EXTRA_BUILD_OPTIONS`` |
| 402 | allows specifying additional compiler and linker options. Specified |
| 403 | options are appended after the options set by the OpenCL program in |
| 404 | ``clBuildProgram``. |
| 405 | ``CLOVER_EXTRA_COMPILE_OPTIONS`` |
| 406 | allows specifying additional compiler options. Specified options are |
| 407 | appended after the options set by the OpenCL program in |
| 408 | ``clCompileProgram``. |
| 409 | ``CLOVER_EXTRA_LINK_OPTIONS`` |
| 410 | allows specifying additional linker options. Specified options are |
| 411 | appended after the options set by the OpenCL program in |
| 412 | ``clLinkProgram``. |
| 413 | |
| 414 | Softpipe driver environment variables |
| 415 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 416 | |
| 417 | ``SOFTPIPE_DUMP_FS`` |
| 418 | if set, the softpipe driver will print fragment shaders to stderr |
| 419 | ``SOFTPIPE_DUMP_GS`` |
| 420 | if set, the softpipe driver will print geometry shaders to stderr |
| 421 | ``SOFTPIPE_NO_RAST`` |
| 422 | if set, rasterization is no-op'd. For profiling purposes. |
| 423 | ``SOFTPIPE_USE_LLVM`` |
| 424 | if set, the softpipe driver will try to use LLVM JIT for vertex |
| 425 | shading processing. |
| 426 | |
| 427 | LLVMpipe driver environment variables |
| 428 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 429 | |
| 430 | ``LP_NO_RAST`` |
| 431 | if set LLVMpipe will no-op rasterization |
| 432 | ``LP_DEBUG`` |
| 433 | a comma-separated list of debug options is accepted. See the source |
| 434 | code for details. |
| 435 | ``LP_PERF`` |
| 436 | a comma-separated list of options to selectively no-op various parts |
| 437 | of the driver. See the source code for details. |
| 438 | ``LP_NUM_THREADS`` |
| 439 | an integer indicating how many threads to use for rendering. Zero |
| 440 | turns off threading completely. The default value is the number of |
| 441 | CPU cores present. |
| 442 | |
| 443 | VMware SVGA driver environment variables |
| 444 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 445 | |
| 446 | ``SVGA_FORCE_SWTNL`` |
| 447 | force use of software vertex transformation |
| 448 | ``SVGA_NO_SWTNL`` |
| 449 | don't allow software vertex transformation fallbacks (will often |
| 450 | result in incorrect rendering). |
| 451 | ``SVGA_DEBUG`` |
| 452 | for dumping shaders, constant buffers, etc. See the code for details. |
| 453 | ``SVGA_EXTRA_LOGGING`` |
| 454 | if set, enables extra logging to the ``vmware.log`` file, such as the |
| 455 | OpenGL program's name and command line arguments. |
| 456 | ``SVGA_NO_LOGGING`` |
| 457 | if set, disables logging to the ``vmware.log`` file. This is useful |
| 458 | when using Valgrind because it otherwise crashes when initializing |
| 459 | the host log feature. |
| 460 | |
| 461 | See the driver code for other, lesser-used variables. |
| 462 | |
| 463 | WGL environment variables |
| 464 | ~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 465 | |
| 466 | ``WGL_SWAP_INTERVAL`` |
| 467 | to set a swap interval, equivalent to calling |
| 468 | ``wglSwapIntervalEXT()`` in an application. If this environment |
| 469 | variable is set, application calls to ``wglSwapIntervalEXT()`` will |
| 470 | have no effect. |
| 471 | |
| 472 | VA-API environment variables |
| 473 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 474 | |
| 475 | ``VAAPI_MPEG4_ENABLED`` |
| 476 | enable MPEG4 for VA-API, disabled by default. |
| 477 | |
| 478 | VC4 driver environment variables |
| 479 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 480 | |
| 481 | ``VC4_DEBUG`` |
| 482 | a comma-separated list of named flags, which do various things: |
| 483 | |
| 484 | ``cl`` |
| 485 | dump command list during creation |
| 486 | ``qpu`` |
| 487 | dump generated QPU instructions |
| 488 | ``qir`` |
| 489 | dump QPU IR during program compile |
| 490 | ``nir`` |
| 491 | dump NIR during program compile |
| 492 | ``tgsi`` |
| 493 | dump TGSI during program compile |
| 494 | ``shaderdb`` |
| 495 | dump program compile information for shader-db analysis |
| 496 | ``perf`` |
| 497 | print during performance-related events |
| 498 | ``norast`` |
| 499 | skip actual hardware execution of commands |
| 500 | ``always_flush`` |
| 501 | flush after each draw call |
| 502 | ``always_sync`` |
| 503 | wait for finish after each flush |
| 504 | ``dump`` |
| 505 | write a GPU command stream trace file (VC4 simulator only) |
| 506 | |
| 507 | RADV driver environment variables |
| 508 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 509 | |
| 510 | ``RADV_DEBUG`` |
| 511 | a comma-separated list of named flags, which do various things: |
| 512 | |
| 513 | ``allbos`` |
| 514 | force all allocated buffers to be referenced in submissions |
| 515 | ``allentrypoints`` |
| 516 | enable all device/instance entrypoints |
| 517 | ``checkir`` |
| 518 | validate the LLVM IR before LLVM compiles the shader |
| 519 | ``errors`` |
| 520 | display more info about errors |
| 521 | ``info`` |
| 522 | show GPU-related information |
| 523 | ``metashaders`` |
| 524 | dump internal meta shaders |
| 525 | ``nobinning`` |
| 526 | disable primitive binning |
| 527 | ``nocache`` |
| 528 | disable shaders cache |
| 529 | ``nocompute`` |
| 530 | disable compute queue |
| 531 | ``nodcc`` |
| 532 | disable Delta Color Compression (DCC) on images |
| 533 | ``nodynamicbounds`` |
| 534 | do not check OOB access for dynamic descriptors |
| 535 | ``nofastclears`` |
| 536 | disable fast color/depthstencil clears |
| 537 | ``nohiz`` |
| 538 | disable HIZ for depthstencil images |
| 539 | ``noibs`` |
| 540 | disable directly recording command buffers in GPU-visible memory |
| 541 | ``noloadstoreopt`` |
| 542 | disable LLVM SILoadStoreOptimizer pass |
| 543 | ``nomemorycache`` |
| 544 | disable memory shaders cache |
| 545 | ``nongg`` |
| 546 | disable NGG for GFX10+ |
| 547 | ``nooutoforder`` |
| 548 | disable out-of-order rasterization |
| 549 | ``noshaderballot`` |
| 550 | disable shader ballot |
| 551 | ``nothreadllvm`` |
| 552 | disable LLVM threaded compilation |
| 553 | ``preoptir`` |
| 554 | dump LLVM IR before any optimizations |
| 555 | ``shaders`` |
| 556 | dump shaders |
| 557 | ``shaderstats`` |
| 558 | dump shader statistics |
| 559 | ``spirv`` |
| 560 | dump SPIR-V |
| 561 | ``startup`` |
| 562 | display info at startup |
| 563 | ``syncshaders`` |
| 564 | synchronize shaders after all draws/dispatches |
| 565 | ``vmfaults`` |
| 566 | check for VM memory faults via dmesg |
| 567 | ``zerovram`` |
| 568 | initialize all memory allocated in VRAM as zero |
| 569 | |
| 570 | ``RADV_FORCE_FAMILY`` |
| 571 | create a null device to compile shaders without a AMD GPU (eg. |
| 572 | gfx900) |
| 573 | ``RADV_PERFTEST`` |
| 574 | a comma-separated list of named flags, which do various things: |
| 575 | |
| 576 | ``aco`` |
| 577 | enable ACO experimental compiler |
| 578 | ``bolist`` |
| 579 | enable the global BO list |
| 580 | ``cswave32`` |
| 581 | enable wave32 for compute shaders (GFX10+) |
| 582 | ``dccmsaa`` |
| 583 | enable DCC for MSAA images |
| 584 | ``dfsm`` |
| 585 | enable dfsm |
| 586 | ``gewave32`` |
| 587 | enable wave32 for vertex/tess/geometry shaders (GFX10+) |
| 588 | ``localbos`` |
| 589 | enable local BOs |
| 590 | ``pswave32`` |
| 591 | enable wave32 for pixel shaders (GFX10+) |
| 592 | ``shader_ballot`` |
| 593 | enable shader ballot |
| 594 | ``tccompatcmask`` |
| 595 | enable TC-compat cmask for MSAA images |
| 596 | |
| 597 | ``RADV_SECURE_COMPILE_THREADS`` |
| 598 | maximum number of secure compile threads (up to 32) |
| 599 | ``RADV_TEX_ANISO`` |
| 600 | force anisotropy filter (up to 16) |
| 601 | ``RADV_TRACE_FILE`` |
| 602 | generate cmdbuffer tracefiles when a GPU hang is detected |
| 603 | ``ACO_DEBUG`` |
| 604 | a comma-separated list of named flags, which do various things: |
| 605 | |
| 606 | ``validateir`` |
| 607 | validate the ACO IR at various points of compilation (enabled by |
| 608 | default for debug/debugoptimized builds) |
| 609 | ``validatera`` |
| 610 | validate register assignment of ACO IR and catches many RA bugs |
| 611 | ``perfwarn`` |
| 612 | abort on some suboptimal code generation |
| 613 | |
| 614 | radeonsi driver environment variables |
| 615 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 616 | |
| 617 | ``AMD_DEBUG`` |
| 618 | a comma-separated list of named flags, which do various things: |
| 619 | ``nodma`` |
| 620 | Disable SDMA |
| 621 | ``nodmaclear`` |
| 622 | Disable SDMA clears |
| 623 | ``nodmacopyimage`` |
| 624 | Disable SDMA image copies |
| 625 | ``zerovram`` |
| 626 | Clear VRAM allocations. |
| 627 | ``nodcc`` |
| 628 | Disable DCC. |
| 629 | ``nodccclear`` |
| 630 | Disable DCC fast clear. |
| 631 | ``nodccfb`` |
| 632 | Disable separate DCC on the main framebuffer |
| 633 | ``nodccmsaa`` |
| 634 | Disable DCC for MSAA |
| 635 | ``nodpbb`` |
| 636 | Disable DPBB. |
| 637 | ``nodfsm`` |
| 638 | Disable DFSM. |
| 639 | ``notiling`` |
| 640 | Disable tiling |
| 641 | ``nofmask`` |
| 642 | Disable MSAA compression |
| 643 | ``nohyperz`` |
| 644 | Disable Hyper-Z |
| 645 | ``norbplus`` |
| 646 | Disable RB+. |
| 647 | ``no2d`` |
| 648 | Disable 2D tiling |
| 649 | ``info`` |
| 650 | Print driver information |
| 651 | ``tex`` |
| 652 | Print texture info |
| 653 | ``compute`` |
| 654 | Print compute info |
| 655 | ``vm`` |
| 656 | Print virtual addresses when creating resources |
| 657 | ``vs`` |
| 658 | Print vertex shaders |
| 659 | ``ps`` |
| 660 | Print pixel shaders |
| 661 | ``gs`` |
| 662 | Print geometry shaders |
| 663 | ``tcs`` |
| 664 | Print tessellation control shaders |
| 665 | ``tes`` |
| 666 | Print tessellation evaluation shaders |
| 667 | ``cs`` |
| 668 | Print compute shaders |
| 669 | ``noir`` |
| 670 | Don't print the LLVM IR |
| 671 | ``nonir`` |
| 672 | Don't print NIR when printing shaders |
| 673 | ``noasm`` |
| 674 | Don't print disassembled shaders |
| 675 | ``preoptir`` |
| 676 | Print the LLVM IR before initial optimizations |
| 677 | ``gisel`` |
| 678 | Enable LLVM global instruction selector. |
| 679 | ``w32ge`` |
| 680 | Use Wave32 for vertex, tessellation, and geometry shaders. |
| 681 | ``w32ps`` |
| 682 | Use Wave32 for pixel shaders. |
| 683 | ``w32cs`` |
| 684 | Use Wave32 for computes shaders. |
| 685 | ``w64ge`` |
| 686 | Use Wave64 for vertex, tessellation, and geometry shaders. |
| 687 | ``w64ps`` |
| 688 | Use Wave64 for pixel shaders. |
| 689 | ``w64cs`` |
| 690 | Use Wave64 for computes shaders. |
| 691 | ``checkir`` |
| 692 | Enable additional sanity checks on shader IR |
| 693 | ``mono`` |
| 694 | Use old-style monolithic shaders compiled on demand |
| 695 | ``nooptvariant`` |
| 696 | Disable compiling optimized shader variants. |
| 697 | ``forcedma`` |
| 698 | Use SDMA for all operations when possible. |
| 699 | ``nowc`` |
| 700 | Disable GTT write combining |
| 701 | ``check_vm`` |
| 702 | Check VM faults and dump debug info. |
| 703 | ``reserve_vmid`` |
| 704 | Force VMID reservation per context. |
| 705 | ``nogfx`` |
| 706 | Disable graphics. Only multimedia compute paths can be used. |
| 707 | ``nongg`` |
| 708 | Disable NGG and use the legacy pipeline. |
| 709 | ``nggc`` |
| 710 | Always use NGG culling even when it can hurt. |
| 711 | ``nonggc`` |
| 712 | Disable NGG culling. |
| 713 | ``alwayspd`` |
| 714 | Always enable the primitive discard compute shader. |
| 715 | ``pd`` |
| 716 | Enable the primitive discard compute shader for large draw calls. |
| 717 | ``nopd`` |
| 718 | Disable the primitive discard compute shader. |
| 719 | ``switch_on_eop`` |
| 720 | Program WD/IA to switch on end-of-packet. |
| 721 | ``nooutoforder`` |
| 722 | Disable out-of-order rasterization |
| 723 | ``dpbb`` |
| 724 | Enable DPBB. |
| 725 | ``dfsm`` |
| 726 | Enable DFSM. |
| 727 | |
| 728 | Other Gallium drivers have their own environment variables. These may |
| 729 | change frequently so the source code should be consulted for details. |