-C cascading errors; risk crash from accumulation of error recoveries
-D input is HLSL
-D<macro=def>
-D<macro>
define a pre-processor macro
-E print pre-processed GLSL; cannot be used with -l; errors will appear on stderr.
-G[ver]
create SPIR-V binary, under OpenGL semantics; turns on -l; default file name is <stage>.spv (-o
overrides this) 'ver', when present, is the version of the input semantics, which will appear in
#define GL_SPIRV ver. --clientopengl100 is the same as -G100 and --target-env for OpenGL will
also imply -G-H print human readable form of SPIR-V; turns on -V-I<dir>
add dir to the include search path; includer's directory is searched first, followed by
left-to-right order of -I-Od disables optimization. May cause illegal SPIR-V for HLSL.
-Os optimizes SPIR-V to minimize size.
-S <stage>
uses specified stage rather than parsing the file extension choices for <stage> are vert, tesc,
tese, geom, frag, or comp
-U<macro>
undefine a pre-processor macro
-V[ver]
create SPIR-V binary, under Vulkan semantics; turns on -l; default file name is <stage>.spv (-o
overrides this) 'ver', when present, is the version of the input semantics, which will appear in
#define VULKAN ver. --clientvulkan100 is the same as -V100 and --target-env for Vulkan will also
imply -V-c configuration dump; creates the default configuration file (redirect to a .conf file)
-d default to desktop (#version 110) when there is no shader #version (default is ES version 100)
-e <name>
specify <name> as the entry-point name
-g generate debug information
-h print this usage message
-i intermediate tree (glslang AST) is printed out
-l link all input files together to form a single module
-m memory leak mode
-o <file>
save binary to <file>, requires a binary option (e.g., -V)
-q dump reflection query database
-r synonym for --relaxed-errors-s silence syntax and semantic error reporting
-t multi-threaded mode
-v print version strings
-w synonym for --suppress-warnings-x save binary output as text-based 32-bit hexadecimal numbers
--auto-map-bindings
automatically bind uniform variables without explicit bindings.
--amb synonym for --auto-map-bindings--auto-map-locations
automatically locate input/output lacking 'location' (fragile, not cross stage)
--aml synonym for --auto-map-locations--client {vulkan<ver>|opengl<ver>}
see -V and -G--flatten-uniform-arrays
flatten uniform texture/sampler arrays to scalars
--fua synonym for --flatten-uniform-arrays--hlsl-offsets
Allow block offsets to follow HLSL rules. Works independently of source language
--hlsl-iomap
Perform IO mapping in HLSL register space
--keep-uncalled
don't eliminate uncalled functions
--ku synonym for --keep-uncalled--no-storage-format
use Unknown image format
--nsf synonym for --no-storage-format--relaxed-errors
relaxed GLSL semantic error-checking mode
--resource-set-binding [stage] name set binding
Set descriptor set and binding for individual resources
--resource-set-binding [stage] set
Set descriptor set for all resources
--rsb [stage] type set binding
synonym for --resource-set-binding--shift-image-binding [stage] num
base binding number for images (uav)
--shift-image-binding [stage] [num set]... per-descriptor-set shift values
--sib [stage] num
synonym for --shift-image-binding--shift-sampler-binding [stage] num
base binding number for samplers
--shift-sampler-binding [stage] [num set]... per-descriptor-set shift values
--ssb [stage] num
synonym for --shift-sampler-binding--shift-ssbo-binding [stage] num
base binding number for SSBOs
--shift-ssbo-binding [stage] [num set]... per-descriptor-set shift values
--sbb [stage] num
synonym for --shift-ssbo-binding--shift-texture-binding [stage] num
base binding number for textures
--shift-texture-binding [stage] [num set]... per-descriptor-set shift values
--stb [stage] num
synonym for --shift-texture-binding--shift-uav-binding [stage] num
base binding number for UAVs
--shift-uav-binding [stage] [num set]... per-descriptor-set shift values
--suavb [stage] num
synonym for --shift-uav-binding--shift-UBO-binding [stage] num
base binding number for UBOs
--shift-UBO-binding [stage] [num set]... per-descriptor-set shift values
--shift-cbuffer-binding [stage] num
synonym for --shift-UBO-binding--shift-cbuffer-binding [stage] [num set]... per-descriptor-set shift values
--sub [stage] num
synonym for --shift-UBO-binding--source-entrypoint <name>
the given shader source function is renamed to be the <name> given in -e--sep synonym for --source-entrypoint--stdin
Read from stdin instead of from a file. You'll have to provide the shader stageusing -S.
--suppress-warnings
suppress GLSL warnings (except as required by #extension : warn)
--target-env {vulkan1.0|opengl}
set the execution environment code will execute in (as opposed to language semantics selected by
--client) defaults: 'vulkan1.0' under --clientvulkan<ver> 'opengl' under --clientopengl<ver>--variable-name <name>
Creates a C header file that contains a uint32_t array named <name> initialized with the shader
binary code.
--vn <name>
synonym for --variable-name <name>