John Kessenich
4e11b615db
SPV: Turn off the default validation done by the SPIRV-Tools optimizer.
...
Also use the glslang namespace qualifier consistently and validate after
legalization, not before. (But most tests don't legalize.)
2018-08-30 16:59:13 -06:00
John Kessenich
c340425bb2
SPV: Add option for controling when the SPIRV-Tools validator is used.
2018-08-23 15:29:08 -06:00
John Kessenich
717c80a9de
SPV: Isolate SPIRV-tools glue to its own file.
2018-08-23 15:17:10 -06:00
John Kessenich
cc14f2d329
SPV: Add SPIRV-Tools validator. This needs the latest SPIR-Tools.
2018-08-23 13:46:48 -06:00
John Kessenich
e7df8e0b76
Non-functional: Rationalize some existing use of SPIRV-Tools.
2018-08-22 17:12:46 -06:00
David Neto
9fd2a8cdfc
Use our own SPIRV-Tools message stringifier
...
Stop including an internal SPIRV-Tools header. It has been
deleted.
Fixes #1477
2018-08-20 10:36:27 -04:00
John Kessenich
31aa3d6019
SPV: only declare the pure 8/16-bit capabilities when needed.
...
Only when operations stray outside the 8/16-bit storage-capabilities
are the general (pure 8/16-bit) capabilities needed.
2018-08-16 15:54:21 -06:00
John Kessenich
149afc3930
SPV: More corrections of <id> versus "immediate" operands.
2018-08-14 13:31:43 -06:00
John Kessenich
228e964bcc
SPV: Correct SPIR-V operands for <id> versus immediate.
2018-08-13 21:37:59 -06:00
John Kessenich
c4510e5ebc
Merge pull request #1466 from Kangz/warning_fixes
...
Fix -Wignored-qualifier and -Wunused-variable warnings
2018-08-09 12:49:56 -07:00
Corentin Wallez
e70614223f
Fix -Wignored-qualifier and -Wunused-variable warnings
2018-08-09 14:54:33 +02:00
John Kessenich
f04c51b3bd
Non-Functional: Add postprocess as more robust way to add capabilities
...
When capabilities are needed for specific SPIR-V instructions, it is
fragile to do so based on GLSL/AST usage; it should be based on actual
instructions they got translated to.
2018-08-03 15:56:12 -06:00
John Kessenich
5a7321eb03
Merge branch 'master' of https://github.com/zeux/glslang into zeux-master
2018-07-20 17:11:44 -06:00
John Kessenich
ebd989dd58
Merge pull request #1437 from mattparks/patch-2
...
CMake options for postfix and SPVRemapper.
2018-07-18 17:15:32 -07:00
Jeff Bolz
c140b96892
Add missing OpExtension SPV_EXT_descriptor_indexing for dynamic indexing capabilities
2018-07-12 16:51:18 -05:00
Matthew Albrecht
857f25cfd2
Added the cmake option to disable building SPVRemapper.
2018-07-07 16:54:34 -05:00
Arseny Kapoulkine
112e2858cf
SPIRV: Simplify matrix->matrix constructor
...
When constructing a matrix from another matrix with smaller dimensions,
there's no need to extract the scalars out of columns and rebuild the
resulting matrix from scalars - instead, we can just construct shorter
vectors with OpShuffle and combine them to the final result.
This keeps the common casts such as mat3(mat4) in vector registers,
which may improve performance for some GPUs, and cleans up output of
translation tools like SPIRV-Cross.
Fixes #1412 .
2018-07-05 15:55:12 -07:00
Lei Zhang
a2c39a2947
Use public SPIRV-Tools header
2018-07-04 14:53:45 -04:00
John Kessenich
312dcfb070
Implement GL_EXT_shader_16bit_storage and GL_EXT_shader_8bit_storage extensions.
...
These introduce limited support for 8/16-bit types such that they can only be accessed in buffer memory and converted to/from 32-bit types.
Contributed from Khronos-internal work.
2018-07-03 13:51:31 -06:00
John Kessenich
e2156222d3
SPV: Add option to print disassembly in standard form using SPIRV-Tools.
2018-07-02 15:54:12 -06:00
GregF
c6831d1ed4
Add support for OpConstantNull and OpConstantSampler to spirv-remap
...
Fixes issue #1408
2018-06-19 13:51:28 -06:00
John Kessenich
ba018e6762
SPV: Fix #1399 emit ImageGatherExtended when using ConstOffsets operand
2018-06-05 08:53:36 -06:00
John Kessenich
ad7645f4f5
Fix #1360 : uint->int width conversions must still be typed as uint.
2018-06-04 20:09:30 -06:00
John Kessenich
14b85d3ff3
Fix #1395 : GLSL volatile maps to SPIR-V Volatile and Coherent.
...
The major version number was bumped in the previous commit to support
this.
2018-06-04 15:36:03 -06:00
John Kessenich
d6c975572e
Change the major revision number for next commit.
2018-06-04 15:33:31 -06:00
John Kessenich
32d3ec3199
Merge pull request #1394 from greg-lunarg/kg20
...
Update spirv-tools known-good.
2018-05-31 18:31:18 -06:00
GregF
b0c42b2884
Update spirv-tools known-good.
...
Includes:
Fold FMix feeding Extract, and use the simplification pass.
2018-05-31 16:17:18 -06:00
John Kessenich
b91189dbe5
Merge pull request #876 from ligfx/cmaketargetincludedirectories
...
CMake: use target_include_directories to expose includes
2018-05-27 19:29:42 -06:00
Michael Maltese
a895f378ee
CMake: use target_include_directories to expose includes
...
This makes glslang simpler to embed in larger projects.
2018-05-27 11:36:32 -07:00
Jeff Bolz
af7a94876c
Add bit width of types to disassembleInstruction
2018-05-24 21:08:20 -05:00
Rex Xu
b4a2a6cf94
Fix issue #1376 : SPV_AMD_gpu_shader_half_float is not emitted under
...
vulkan1.1
Interpolation functions, using 16-bit interpolants, should always emit
this extension string regardless of vulkan enviornment version.
2018-05-17 13:51:28 +08:00
John Kessenich
1831087e48
SPV: Fix #1374 : For an SSBO 16-bit access, only emit StorageUniformBufferBlock16 capability.
2018-05-14 22:08:53 -06:00
John Kessenich
d3ed90be3a
Fix #944 : Convert argument type to match formal parameter type.
2018-05-04 11:43:03 -06:00
Matthew Albrecht
1199cf92f7
Fixed install for SPIRV, glslang, and hlsl when building shared libs
2018-04-26 14:07:46 -05:00
Rex Xu
7c88aff1a9
Specify SPV_AMD_gpu_shader_int16 extension string when frexp() takes 16-bit
...
exp operand
2018-04-14 21:40:49 +08:00
John Kessenich
b9e9e57f12
Merge pull request #1326 from mattparks/patch1
...
Allowed for LIB_TYPE to be set to switch between static and shared libs for glslang, SPIRV, and HLSL
2018-04-11 18:14:46 -06:00
St0fF
a1184ddd48
fix further MSVC 2012 build issues
...
MSVC 2012 does not allow initializer lists - replaced with corrresponding CTor calls.
2018-04-09 21:08:14 +02:00
John Kessenich
f52b63812a
Fix #1331 : Emit SPV_GOOGLE_hlsl_functionality1 for counters.
...
It was missing when there were no semantics.
2018-04-05 19:35:38 -06:00
John Kessenich
5611c6d27b
GLSL/SPV: Implement SPV_EXT_descriptor_indexing and GL_EXT_nonuniform_qualifier
2018-04-05 11:25:02 -06:00
Matthew Albrecht
6c5f649ae8
Allowed for LIB_TYPE to be set to switch between static and shared libs for glslang, SPIRV, and HLSL
2018-03-30 09:32:03 -05:00
John Kessenich
10971553b8
Non-Functional: Remove unused parts of the disassembler.
2018-03-30 00:11:39 -06:00
Jeff Bolz
2abe9a4d34
Implement GL_NV_shader_subgroup_partitioned
2018-03-29 22:52:17 -05:00
GregF
fb03a55e0f
Only print legalization warning if optimizer disabled
2018-03-29 13:17:54 -06:00
John Kessenich
7be36647fc
Merge pull request #1319 from KhronosGroup/array-rationalization
...
Array rationalization
2018-03-28 23:26:27 -06:00
John Kessenich
ead8622484
Non-functional. Rationalizations enabling future generalizations:
...
- Use much simpler method to update implicit array sizes.
The previous overly complicated method was error prone.
- Rationalize all use of unsized arrays.
- Combine decorations when generating SPIR-V, to simplify
adding extensions.
2018-03-28 18:01:20 -06:00
GregF
4bede9eb00
Disable DCE by Remapper through glslangValidator...
...
...now that spirv-opt is capable enough.
2018-03-27 10:15:51 -06:00
John Kessenich
643e57cddf
Merge pull request #1313 from greg-lunarg/kg15
...
Update SPIRV-Tools known good.
2018-03-27 00:46:18 -06:00
greg-lunarg
0b46c1edbf
Merge branch 'master' into kg15
2018-03-26 12:20:43 -06:00
GregF
eecb874c35
Update SPIRV-Tools known good.
...
Also update spirv-opt recipes.
2018-03-26 12:11:55 -06:00
John Kessenich
859b0342b8
Types: Fix #1290 : Rationalize and correct "mixed" style array dimensioning.
...
There a couple functional problems, which when reduced down also led to
some good simplifications and rationalization. So, this commit:
- corrects "mixed" functionality: int[A] f[B] -> f[B][A]
- correct multi-identifier decls: int[A] f[B], g[C] -> f and g are independently sized.
- increases symmetry between different places in the code that do this
- makes fewer ways to do the same thing; several methods are just gone now
- makes more clear when something is copied or shared
2018-03-26 00:38:53 -06:00