John Kessenich
4f4683d251
Merge pull request #1050 from amdrexu/feature
...
Implement the extension GL_AMD_shader_fragment_mask
2017-09-12 09:09:37 -06:00
John Kessenich
ea1ea974eb
Address #1052 : Have language-level exits of case statements.
2017-09-11 19:25:17 -06:00
amhagan
05506bb874
Implement the extension GL_AMD_shader_fragment_mask
2017-09-09 22:05:24 +08:00
LoopDawg
76117921b9
Fix lvalue check in SPIR-V generation
...
There were several locations in TGlslangToSpvTraverser::handleUserFunctionCall testing for
whether a fn argument should be in the lvalue or rvalue array. They must get the same
result for indexing sanity, but had slightly different logic.
They're now forced into the same test.
2017-09-06 15:04:52 -06:00
LoopDawg
2baa774259
Linux build warning fix
...
* Remove complaint about unused function parameter in resolveUniformLocation()
* Remove complaint about defined but not used variable in spvIR.h
2017-08-31 18:09:58 -06:00
John Kessenich
8268a35504
Build: Attempt better support for VS 2012.
...
Fix #1020 . Fix #1021 . Fix #1022 .
2017-08-25 21:35:37 -06:00
John Kessenich
74c5f711b4
Merge pull request #1014 from KhronosGroup/SPV_EXT_shader_viewport_index_layer
...
SPV: 1st pass implementation of SPV_EXT_shader_viewport_index_layer.
2017-08-25 13:33:16 -06:00
John Kessenich
35343cb84d
Merge pull request #1034 from KhronosGroup/module-processes
...
SPV reflection: Add OpModuleProcessed for compile options.
2017-08-25 13:05:54 -06:00
John Kessenich
b41bff69d2
SPV: 1st pass implementation of SPV_EXT_shader_viewport_index_layer.
2017-08-25 13:04:39 -06:00
John Kessenich
2a27116cae
SPV reflection: Add OpModuleProcessed for compile options.
2017-08-25 11:48:02 -06:00
John Kessenich
fc3436941e
Merge pull request #1029 from amdrexu/feature2
...
Implement extension GL_AMD_shader_image_load_store_lod
2017-08-23 23:13:19 -06:00
Rex Xu
129799a709
Implement extension GL_AMD_shader_image_load_store_lod
2017-08-24 06:56:39 +08:00
Rex Xu
e8fdd79f2e
SPV: Implement extension SPV_EXT_shader_stencil_export
2017-08-24 06:26:15 +08:00
John Kessenich
786e8795ee
Build: Fix build when NV_EXTENSIONS is not enabled.
2017-08-19 15:54:49 -06:00
John Kessenich
d6be6da031
SPV: Fix #1016 : Don't allow non-GLSL-extension protected Layer and ViewportIndex members.
2017-08-17 23:49:39 -06:00
John Kessenich
260f50616a
SPV: Correct selection of storage-image capabilities. Fixes #986 .
...
Code was reflecting an old historical use of sampled as a SPIR-V
2-valued operand, instead of its current 3 values.
2017-08-14 22:10:00 -06:00
John Kessenich
0d0c6d38f0
GLSL 4.6: Implement atomic counter ops and SPV_KHR_shader_atomic_counter_ops.
2017-07-31 03:00:04 -06:00
Rex Xu
286ca432cf
SPV: Memory qualifiers should decorate top-level block members
2017-07-27 14:33:16 +08:00
John Kessenich
d2d3a14237
SPV: Update to latest 1.0 headers, removing redundancies in GLSL.ext.AMD.h.
2017-07-25 21:03:29 -06:00
LoopDawg
ef94b1a5ca
Fix dref explicit LOD form of sample with cube texture arrays
...
The dref parameter was being used as the LOD. Now it it's properly the dref.
2017-07-24 18:45:37 -06:00
John Kessenich
961cd35b73
SPV: Fix #995 : Include memory decorations on parameters.
2017-07-18 03:07:43 -06:00
John Kessenich
fad6297206
SPV: Non-functional: support lists of decorations per parameter.
2017-07-18 02:46:59 -06:00
John Kessenich
735d7e56a6
Address part A of #982 : $Global will use std140 instead of HLSL offsets.
...
From comment about this:
Adjust alignment for HLSL rules
TODO: make this consistent in early phases of code: adjusting this late means inconsistencies with earlier code, which for reflection is an issue.
Until reflection is brought in sync with these adjustments, don't apply to $Global,
which is the most likely to rely on reflection, and least likely to rely
implicit layouts.
2017-07-13 11:39:16 -06:00
Rex Xu
57e65929e4
HLSL: Translate directive [flatten] and [branch] to SPV control mask.
2017-07-06 11:31:33 +08:00
John Kessenich
9645f78293
Merge pull request #965 from chaoc/spv-khr-post-depth-coverage
...
Implement SPV_KHR_post_depth_coverage
2017-07-05 14:48:19 -06:00
chaoc
c120452754
Implement SPV_KHR_post_depth_coverage
...
Added support for both extension GL_ARB_post_depth_coverage and GL_EXT_post_depth_coverage.
2017-07-05 12:27:15 -07:00
John Kessenich
17b5f9175d
Merge pull request #969 from d3x0r/patch-1
...
Add option to skip installation
2017-07-04 11:00:42 -06:00
Rohith Chandran
6206091e63
Fix CMake scripts: The set_property script can be used to set only a single property, so now setting the POSITION_INDEPENDENT_CODE property correctly.
2017-07-04 10:53:45 -04:00
d3x0r
4e53d9052d
Update CMakeLists.txt
2017-07-04 06:00:35 -07:00
Rex Xu
37cdceed41
Implement extension GL_ARB_shader_stencil_export
2017-06-29 17:50:46 +08:00
John Kessenich
e2ff404f6b
Merge pull request #917 from KhronosGroup/remove-redundant-locations
...
Replace #422 : Remove the redundant location setting in AST->SPIR-V.
2017-06-15 12:11:37 -06:00
Rex Xu
301a2bc8a7
SPV: Fix an typo of SPV_AMD_texture_gather_bias_lod
2017-06-14 23:09:39 +08:00
Rex Xu
cabbb788b4
Implement extension GL_AMD_gpu_shader_int16
...
- Add int16 types (int16_t, uint16_t, i16vec, u16vec).
- Add int16 support to GLSL operators.
- Add int16 type conversions (to int16, from int16).
- Add int16 built-in functions.
2017-06-09 17:11:23 +08:00
Rex Xu
225e0fcadd
Implement the extension GL_AMD_texture_gather_bias_lod
2017-06-05 16:41:06 +08:00
John Kessenich
7cdf3fc3c6
Replace #422 : Remove the redundant location setting in AST->SPIR-V.
...
This was redundant in two ways:
1) it replicated algorithms owned in the front end, and
2) it sometimes left location information on both a block and its members.
2017-06-04 13:22:39 -06:00
John Kessenich
e485c7af58
SPV: Debug output: Include OpLine information for execution path.
...
Note that declaratives are not handled, only procedurals.
2017-05-31 18:50:53 -06:00
John Kessenich
121853f4df
SPV: Add OpSource shader source code and file name.
2017-05-31 17:14:15 -06:00
John Kessenich
d6af18f621
Merge pull request #901 from LoopDawg/imat-construct
...
HLSL: Add imat, umat, and bmat constructors
2017-05-24 23:12:58 -06:00
John Kessenich
84cc15f0d0
HLSL: Fix #903 : Don't short-circuit && or ||.
2017-05-24 16:47:32 -06:00
LoopDawg
174ccb8f1d
HLSL: Add imat, umat, and bmat constructors
...
Fixes #894
2017-05-20 21:54:16 -06:00
John Kessenich
7b8c386c5d
More non-determinism fixed.
2017-05-19 23:44:51 -06:00
John Kessenich
b6cabc4f24
Fix C++ portability, non-deterministic order of argument evaluation.
2017-05-19 23:29:50 -06:00
John Kessenich
80f92a190a
Fix #857 : Convert uniform int to local bool for struct alias assignment.
...
This was done for one direction, but not both directions, so this commit
picks up the other direction.
2017-05-19 23:00:13 -06:00
John Kessenich
0d2b4713c5
HLSL: Don't do logical short-circuits when the operands are bool-vectors.
...
This seems a bit ill-defined, and was generating code that made OpPhi of two
operands that were Boolean vectors result in a scalar bool.
2017-05-19 20:19:00 -06:00
LoopDawg
65c2eed65d
Remapper: handle embedded opcode in OpSpecConstantOp
...
OpSpecConstantOp contains an embedded opcode which is given as a literal
argument to the OpSpecConstantOp. The subsequent arguments are as the
embedded op would expect, which may be a mixture of IDs and literals. This
adds support for that to the remapper binary parser. Upon seeing such an
embedded op, the parser flips over to parsing the argument list as
appropriate for that opcode.
Fixes #882 .
2017-05-18 16:13:04 -06:00
Lei Zhang
2840f63fbc
Use unordered_set in ReadableOrderTraverser.
...
Previously we are using unordered_map to map to bool, which can
be simplified with unordered_set.
2017-05-11 20:48:34 -04:00
Aras Pranckevicius
23d3c712bc
[lumped builds] Add include guards (#pragma once) to header files that did not have any.
...
The codebase seems to use both “#pragma once“ approach, and “#ifndef / #define” approach,
so I picked pragma once as that one is less typing & less brittle.
When glslang is built with some other build system and lumped/unity builds are used,
without the include guards some headers would get included multiple times, leading to duplicate
declaration errors.
2017-05-10 16:58:38 +03:00
John Kessenich
a5c5fb6118
SPV: Emit extension for using StorageClassStorageBuffer.
2017-05-05 05:09:58 -06:00
steve-lunarg
f1709e7146
HLSL: implement [unroll] and [loop] attributes
...
This adds infrastructure suitable for any front end to create SPIR-V loop
control flags. The only current front end doing so is HLSL.
[unroll] turns into spv::LoopControlUnrollMask
[loop] turns into spv::LoopControlDontUnrollMask
no specification means spv::LoopControlMaskNone
2017-05-03 13:44:40 -06:00
David Seifert
22afc38b55
Modernise CMake #2
...
This reverts commit cfc69d95afed34e1ba1371df0ddb56f2f491a5cb.
* Change CMAKE_INSTALL_PREFIX default on Windows in order
to prevent permission denied errors when trying to install
to "Program Files".
2017-04-29 11:23:15 +02:00