Commit Graph

864 Commits

Author SHA1 Message Date
John Kessenich
2211835b4d SPV: Implement composite comparisons (reductions across hierchical compare). 2015-12-21 20:54:09 -07:00
John Kessenich
59420fd356 SPV: Move to deterministic results for OpEntryPoint, for test stability across platforms. 2015-12-21 11:45:34 -07:00
John Kessenich
7ba6341a05 SPV: Make OpEntryPoint I/O list include all static uses.
Before, it was only including explicit interface, sufficient for IO-Block-declared
oriented interface, but not sufficient for all modes GLSL might be used with
SPIR-V.

Two things are accomplished now:
1) each id will appear exactly once
2) the OpEntryPoint list will union static use with declarations
2015-12-20 17:37:07 -07:00
John Kessenich
3ac051e41d SPV: recursively propagate row/col majorness through nested structures.
This includes doing structure uniqueness modulo majorness, for shared nested structures.
2015-12-20 12:25:21 -07:00
John Kessenich
f85e806e44 SPV: Nested layouts: Recursively send around the top-level std140 or std430 packing.
This also distinguishes between the same struct included in multiple parent packings.
2015-12-19 15:21:38 -07:00
John Kessenich
b62e693f74 Merge pull request #118 from amdrexu/bugfix
SPV: Fix an issue related with imageStore() for 2DMS.
2015-12-19 11:20:25 -07:00
John Kessenich
a3211bfe72 Merge pull request #120 from amdrexu/bugfix2
Parser: Correct the storage qualifier of gl_HelperInvocation.
2015-12-19 11:14:32 -07:00
John Kessenich
aa1dd61257 Merge branch 'master' of github.com:KhronosGroup/glslang 2015-12-19 11:10:56 -07:00
John Kessenich
b6d7fa91a1 Merge pull request #117 from amdrexu/feature
SPV: Implement GLSL built-in bitcast functions.
2015-12-19 11:08:02 -07:00
John Kessenich
297bb3f2d0 Tests for PR: Fix results for 4f68b83ea1. 2015-12-19 11:05:44 -07:00
John Kessenich
4f68b83ea1 Merge pull request #119 from thothonegan/master
Display the filename if we have output, even if validating  a single file
2015-12-19 11:00:49 -07:00
John Kessenich
61c47a951b Constant folding: Correct result type of non-square matrix folding.
This also made the function easier to read by identifying
left and right operands more clearly.
2015-12-16 15:50:25 -07:00
Rex Xu
1934506555 Parser: Correct the storage qualifier of gl_HelperInvocation. 2015-12-16 14:41:39 +08:00
Kenneth Perry
b07e6beb8a Display the filename if we have output, even if validating a single file. 2015-12-15 10:52:34 -06:00
Rex Xu
7beb44190f SPV: Fix an issue related with imageStore() for 2DMS. 2015-12-15 17:52:45 +08:00
Rex Xu
cbc426ee62 SPV: Implement GLSL built-in bitcast functions. 2015-12-15 16:03:10 +08:00
John Kessenich
ea0cb2eb11 Merge pull request #116 from mgadams/scan_compile_fix
Fix compile warning/error due to assignment in while() loop
2015-12-14 17:47:51 -07:00
Mark Adams
22badee09a Fix compile warning/error due to assignment in while() loop
This causes build failures with -Werror=parentheses
2015-12-14 10:48:04 -05:00
John Kessenich
e7c83cfb8c SPV GLSL.std.450: Add needed smear operations for min, max, clamp, mix, step, and smoothstep. 2015-12-13 13:34:37 -07:00
John Kessenich
6feb4989fe SPV texturing: Use comp. 2 as the 3rd comp. for Dref in ImageSampleProjDrefImplicitLod. 2015-12-13 12:23:33 -07:00
John Kessenich
f5ce646546 Fix crash: when no #version for compute shader in es mode.
An extra line of error recovery code set a non-sense combination of
es version and core profile.
2015-12-13 11:20:12 -07:00
John Kessenich
61d9fb9048 Semantics: 'invocations' defaults to 1, not 0.
'invocations' was using 0 as the "shader never set" flag and as the
default. Formalize this and explicit set to 1 and link time.
2015-12-13 10:59:17 -07:00
John Kessenich
04bb8a01d6 SPV: Implement all matrix operators {+,-,*,/} for {matrix,scalar,vector}. 2015-12-12 12:28:14 -07:00
John Kessenich
494a02a2b0 Semantics: Geometry stage can support max_vertices = 0.
To do this, more generally use a named -1 as a not set value.
2015-12-11 17:54:35 -07:00
John Kessenich
3c24a06c8c SPV tests: Turn on some more tests related to currently pending issues. 2015-12-11 15:08:26 -07:00
John Kessenich
cc16fa0720 Tests: Move to just linefeed to simply cross-platform test changes. 2015-12-10 18:01:54 -07:00
John Kessenich
562394d112 Linux: Fix case of test file. 2015-12-10 12:01:41 -07:00
John Kessenich
76f7139789 SPV: Modify last merge: Have promoteScalar() generate the correct vectorType. 2015-12-09 19:08:42 -07:00
John Kessenich
c51710e0a9 Merge pull request #115 from amdrexu/bugfix
SPV: Smear should use type of the scalar to make the expected vector type when the provided vector type is incompatible with the scalar.
2015-12-09 18:47:48 -07:00
John Kessenich
534610d815 Merge pull request #114 from amdrexu/bugfix2
Parser: Extension requirement of gl_PrimitiveID and gl_Layer should be checked only for ESSL instead of GLSL.
2015-12-09 18:26:38 -07:00
Rex Xu
e723b45bca SPV: Scalar smear operation should use type of the scalar to make the
expected vector type when the provided vector type is incompatible with
the scalar.
2015-12-09 16:05:06 +08:00
Rex Xu
e553ace049 Parser: Extension requirement of gl_PrimitiveID and gl_Layer should be checked only for ESSL instead of GLSL. 2015-12-09 15:03:41 +08:00
John Kessenich
e00e72ded1 SPV: Protect getStorageClass() with a test that the thing is pointer. 2015-12-08 20:48:49 -07:00
John Kessenich
33661450c7 SPV: Implement OpImage functionality (emit before query). 2015-12-08 19:32:47 -07:00
John Kessenich
45457bcddb Merge pull request #113 from amdrexu/feature
SPV: Implement GLSL interpolation built-in functions.
2015-12-08 14:45:01 -07:00
John Kessenich
5d60ca5744 Platforms: Remove support for Windows XP executables.
Dealing with the 110 toolset seems not worth it.
2015-12-08 14:26:26 -07:00
Rex Xu
7a26c176ce SPV: Implement GLSL interpolation built-in functions. 2015-12-08 17:40:11 +08:00
John Kessenich
c92e370e87 Merge pull request #111 from dneto0/issue-110-frexp-fix
Avoid read past end of operands vector for EOpFrexp
2015-12-07 15:03:16 -07:00
David Neto
8d63a3d35a Avoid read past end of operands vector for EOpFrexp
When emitting SPIR-V code for frexp, avoid access
beyond the end of the operands vector.  When constructing
the OpExtInst, construct a new arguments vector instead of
modifying the existing operands vector.  In the case of OpFrexp,
well need that last operand later on to generate the store.

Fixes https://github.com/KhronosGroup/glslang/issues/110

Change-Id: Ibc380fadf5e600ac491932e9ecef7afe2d72fd7f
2015-12-07 16:24:31 -05:00
John Kessenich
8c1c2ca0d7 Built-ins: fix mapping of packDouble2x32 and unpackDouble2x32. 2015-12-06 19:33:07 -07:00
John Kessenich
2359bd0a1d SPV: Fix extra operands when using the "struct" form of a built-in taking an 'out' param. 2015-12-06 19:29:11 -07:00
John Kessenich
e721f49dbd SPV: Distinguish between std140 and std430 layouts, and correctly use alignments as the base for strides. 2015-12-06 19:17:49 -07:00
John Kessenich
dd6ca17845 Semantics: Correct that std430 is universally disallowed with 'uniform'. 2015-12-06 18:10:27 -07:00
John Kessenich
71e04d62a4 Merge pull request #100 from mawww/scanner-optim
Scanner optimisations
2015-12-06 17:12:53 -07:00
John Kessenich
2765749856 Merge pull request #109 from xorgy/add-unary-math-check-for-null-before-dereferencing
In addUnaryMath, check for 'child' being null before dereferencing it.
2015-12-06 10:29:06 -07:00
Aaron Hamilton
af5a123652 In addUnaryMath, check for 'child' being null before dereferencing it. 2015-12-06 01:10:54 +00:00
John Kessenich
8481679f4d Merge pull request #107 from xorgy/fail-init-process-on-init-thread-fail
Fail InitProcess() when InitThread() fails.
2015-12-03 17:57:35 -07:00
John Kessenich
c9d6477ee2 Merge pull request #108 from mgadams/extensions_compile_fix
Fix ordered pointer comparison build warning/error
2015-12-03 17:56:53 -07:00
John Kessenich
bd0726be34 Build: Fix CMake files to find osinclude.h 2015-12-03 17:46:03 -07:00
John Kessenich
e54dd2330a Merge pull request #105 from phaulos/generic-osinclude
Use generic osinclude.h.
2015-12-03 17:20:24 -07:00