platform/upstream/glslang.git
10 years agoTrack expected test results and add more README information.
John Kessenich [Mon, 5 Aug 2013 15:52:03 +0000 (15:52 +0000)]
Track expected test results and add more README information.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22602 e7fa87d3-cd2b-0410-9028-fcbf551c1848

10 years agoAllow unsigned int in the "location = " grammar, and generally improve recognition...
John Kessenich [Sun, 4 Aug 2013 23:51:37 +0000 (23:51 +0000)]
Allow unsigned int in the "location = " grammar, and generally improve recognition of numeric literals to be up to spec.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22597 e7fa87d3-cd2b-0410-9028-fcbf551c1848

10 years agoAdd windows executable.
John Kessenich [Sat, 3 Aug 2013 00:27:08 +0000 (00:27 +0000)]
Add windows executable.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22595 e7fa87d3-cd2b-0410-9028-fcbf551c1848

10 years agoAdd Linux executables
John Kessenich [Sat, 3 Aug 2013 00:16:49 +0000 (00:16 +0000)]
Add Linux executables

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22594 e7fa87d3-cd2b-0410-9028-fcbf551c1848

10 years agoSet up infrastructure for installing an executable. Changes the standalone name to...
John Kessenich [Sat, 3 Aug 2013 00:04:10 +0000 (00:04 +0000)]
Set up infrastructure for installing an executable. Changes the standalone name to glslangValidator.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22593 e7fa87d3-cd2b-0410-9028-fcbf551c1848

10 years agoFix bison file naming issues from upgrading to version 2.7 of bison.
John Kessenich [Thu, 1 Aug 2013 18:04:50 +0000 (18:04 +0000)]
Fix bison file naming issues from upgrading to version 2.7 of bison.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22578 e7fa87d3-cd2b-0410-9028-fcbf551c1848

10 years agoMake previous check in compile correctly on linux.
John Kessenich [Wed, 31 Jul 2013 23:19:17 +0000 (23:19 +0000)]
Make previous check in compile correctly on linux.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22568 e7fa87d3-cd2b-0410-9028-fcbf551c1848

10 years agoImprove multi-threading and move Standalone to a multi-threading model (currently...
John Kessenich [Wed, 31 Jul 2013 18:44:13 +0000 (18:44 +0000)]
Improve multi-threading and move Standalone to a multi-threading model (currently off though).

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22565 e7fa87d3-cd2b-0410-9028-fcbf551c1848

10 years agoUpdate index.
John Kessenich [Mon, 22 Jul 2013 22:31:08 +0000 (22:31 +0000)]
Update index.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22513 e7fa87d3-cd2b-0410-9028-fcbf551c1848

10 years agoPush index page now that SVN access is setup.
John Kessenich [Mon, 22 Jul 2013 22:29:42 +0000 (22:29 +0000)]
Push index page now that SVN access is setup.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22512 e7fa87d3-cd2b-0410-9028-fcbf551c1848

10 years agoPut on hold pending configuring glslang for public access.
John Kessenich [Mon, 22 Jul 2013 07:53:37 +0000 (07:53 +0000)]
Put on hold pending configuring glslang for public access.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22491 e7fa87d3-cd2b-0410-9028-fcbf551c1848

10 years agoLink glslang project into site nav.
John Kessenich [Mon, 22 Jul 2013 07:40:27 +0000 (07:40 +0000)]
Link glslang project into site nav.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22487 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoFix warning in release build. Update to-do list.
John Kessenich [Tue, 9 Jul 2013 23:57:13 +0000 (23:57 +0000)]
Fix warning in release build.  Update to-do list.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22315 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoTie missing default-precision error checks to EShMsgRelaxedErrors.
John Kessenich [Tue, 9 Jul 2013 17:23:39 +0000 (17:23 +0000)]
Tie missing default-precision error checks to EShMsgRelaxedErrors.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22304 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoFinal linux tweak.
John Kessenich [Mon, 8 Jul 2013 21:50:31 +0000 (21:50 +0000)]
Final linux tweak.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22294 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoA few linux improvements/fixes for the previous check in.
John Kessenich [Mon, 8 Jul 2013 20:51:29 +0000 (20:51 +0000)]
A few linux improvements/fixes for the previous check in.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22292 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoReframe the preprocessor as a C++ class, with instances, removing all C code, removin...
John Kessenich [Mon, 8 Jul 2013 19:39:16 +0000 (19:39 +0000)]
Reframe the preprocessor as a C++ class, with instances, removing all C code, removing all global variables.  Upgrade bison version to pass a parse context on through to the preprocessor.  All the basic things to make something thread safe.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22291 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoEliminate flex as the GLSL lexical analyzer, going from two nested lexical analyzers...
John Kessenich [Sat, 6 Jul 2013 19:54:21 +0000 (19:54 +0000)]
Eliminate flex as the GLSL lexical analyzer, going from two nested lexical analyzers down to one, leaving just the preprocessor's lexical analysis.  A new layer replaces it, to translate from the preprocessor's view of tokenization to glslang's view of tokenization.

Also:
 - change source locations from an int to TSourceLoc (shader number, line number) throughout
 - various improvements to the preprocessor

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22277 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoRationalize naming/access to current thread-local-storage scheme. However, the prepr...
John Kessenich [Tue, 2 Jul 2013 20:18:59 +0000 (20:18 +0000)]
Rationalize naming/access to current thread-local-storage scheme.  However, the preprocessor tokenizer is not thread-safe, so this may all change.

Also adding missing test.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22249 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years ago1) Don't propagate precision of built-in function arguments to return type when retur...
John Kessenich [Mon, 1 Jul 2013 17:56:24 +0000 (17:56 +0000)]
1) Don't propagate precision of built-in function arguments to return type when return type is bool (e.g., isnan).
2) Check an additional path for missing default precision qualification, except allow built-in declarations to pass the check.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22241 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoFix bug dropping some qualifiers when merging with block member default qualification.
John Kessenich [Mon, 1 Jul 2013 04:54:28 +0000 (04:54 +0000)]
Fix bug dropping some qualifiers when merging with block member default qualification.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22240 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoUse the default of "smooth" for interpolation qualification for vertex outs and fragm...
John Kessenich [Fri, 28 Jun 2013 05:32:15 +0000 (05:32 +0000)]
Use the default of "smooth" for interpolation qualification for vertex outs and fragment ins (rather than all fragment IO).

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22222 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoFix preprocessor memory leak.
John Kessenich [Wed, 26 Jun 2013 23:41:30 +0000 (23:41 +0000)]
Fix preprocessor memory leak.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22195 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoHandle bad input file.
John Kessenich [Wed, 26 Jun 2013 22:42:55 +0000 (22:42 +0000)]
Handle bad input file.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22194 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoSemantic checks for .length(), switch/case/default, and multidimensional arrays.
John Kessenich [Wed, 26 Jun 2013 05:54:40 +0000 (05:54 +0000)]
Semantic checks for .length(), switch/case/default, and multidimensional arrays.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22175 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd semantic check for precision qualifier on wrong kind of type. Added a few more...
John Kessenich [Tue, 25 Jun 2013 21:53:59 +0000 (21:53 +0000)]
Add semantic check for precision qualifier on wrong kind of type.  Added a few more tests.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22170 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoSupport line-continuation (backslash before newline) for tokens and one-line comments...
John Kessenich [Tue, 25 Jun 2013 21:09:47 +0000 (21:09 +0000)]
Support line-continuation (backslash before newline) for tokens and one-line comments in the preprocessor.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22168 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoRemove the -a option, it doesn't belong here.
John Kessenich [Tue, 25 Jun 2013 18:31:47 +0000 (18:31 +0000)]
Remove the -a option, it doesn't belong here.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22166 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd scanner that can find '#version' across an array of non-null terminated, length...
John Kessenich [Tue, 25 Jun 2013 18:10:05 +0000 (18:10 +0000)]
Add scanner that can find '#version' across an array of non-null terminated, length-based, strings.  Handle the ES error where #version is not the first thing found, while still supporting desktop behavior, and more generally support length-based multiple strings for a single shader.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22165 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd the 6 hyperbolic trig functions.
John Kessenich [Mon, 24 Jun 2013 22:40:19 +0000 (22:40 +0000)]
Add the 6 hyperbolic trig functions.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22149 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoDisallow variable indexing into sampler array for ES and desktop before version 400.
John Kessenich [Mon, 24 Jun 2013 21:52:41 +0000 (21:52 +0000)]
Disallow variable indexing into sampler array for ES and desktop before version 400.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22148 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd semantic checks for order of qualification and repetition within a class of quali...
John Kessenich [Mon, 24 Jun 2013 21:22:03 +0000 (21:22 +0000)]
Add semantic checks for order of qualification and repetition within a class of qualifiers.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22145 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAddress a g++ complaint.
John Kessenich [Mon, 24 Jun 2013 18:24:23 +0000 (18:24 +0000)]
Address a g++ complaint.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22143 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoCreate linkage symbol nodes in the AST so a linker has access to all global objects...
John Kessenich [Mon, 24 Jun 2013 17:26:56 +0000 (17:26 +0000)]
Create linkage symbol nodes in the AST so a linker has access to all global objects that were declared, for error checking, etc.  Use it now for all ins/outs/uniforms as well as gl_VertexID and gl_InstanceID.

Also fixed a confusing name and added more 'const'.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22142 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoFix bug of accidentally overriding initial layout location with 0, which does not...
John Kessenich [Fri, 21 Jun 2013 19:43:44 +0000 (19:43 +0000)]
Fix bug of accidentally overriding initial layout location with 0, which does not mean no location.  Added in/out structure tests.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22120 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd grammar productions for the syntax "layout(...) uniform;" for setting global...
John Kessenich [Thu, 20 Jun 2013 22:54:40 +0000 (22:54 +0000)]
Add grammar productions for the syntax "layout(...) uniform;" for setting global defaults.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22112 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd grammar productions for adding 'invariant' to already declared variables.
John Kessenich [Wed, 19 Jun 2013 20:44:17 +0000 (20:44 +0000)]
Add grammar productions for adding 'invariant' to already declared variables.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22083 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoTrack separate precision defaults for each kind of sampler, give initial defaults...
John Kessenich [Wed, 19 Jun 2013 05:41:25 +0000 (05:41 +0000)]
Track separate precision defaults for each kind of sampler, give initial defaults as per spec. Also make fragment floats have no default.  Modify/add tests to adapt to these changes.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22066 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoEncapsulate warnings like errors. Add warning for missing #version.
John Kessenich [Mon, 17 Jun 2013 21:47:23 +0000 (21:47 +0000)]
Encapsulate warnings like errors.  Add warning for missing #version.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22041 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoFix linux build problem.
John Kessenich [Fri, 14 Jun 2013 17:32:46 +0000 (17:32 +0000)]
Fix linux build problem.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22002 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoImplement __VERSION__ macro, make ftransform() non-ES only, add more tests.
John Kessenich [Thu, 13 Jun 2013 23:56:04 +0000 (23:56 +0000)]
Implement __VERSION__ macro, make ftransform() non-ES only, add more tests.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@22000 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoSemantic checks: ES doesn't have unsized arrays or noise*().
John Kessenich [Thu, 13 Jun 2013 20:16:43 +0000 (20:16 +0000)]
Semantic checks: ES doesn't have unsized arrays or noise*().

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21998 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd semantic checks for nested blocks/structures.
John Kessenich [Thu, 13 Jun 2013 00:13:36 +0000 (00:13 +0000)]
Add semantic checks for nested blocks/structures.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21960 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoSimply compile-time error handling: mostly removed the need to test an error occurred...
John Kessenich [Wed, 12 Jun 2013 22:41:21 +0000 (22:41 +0000)]
Simply compile-time error handling: mostly removed the need to test an error occurred and the need to call recover().

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21959 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoGet all the scoping rules right for ES and non ES, name hiding, built-in overriding...
John Kessenich [Wed, 12 Jun 2013 06:13:17 +0000 (06:13 +0000)]
Get all the scoping rules right for ES and non ES, name hiding, built-in overriding, etc.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21948 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoFix a linux build issue.
John Kessenich [Tue, 11 Jun 2013 18:30:26 +0000 (18:30 +0000)]
Fix a linux build issue.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21945 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd constant folding for the exp*(), log*(), *sqrt(), round*(), floor(), fract()...
John Kessenich [Tue, 11 Jun 2013 00:09:48 +0000 (00:09 +0000)]
Add constant folding for the exp*(), log*(), *sqrt(), round*(), floor(), fract(), ceil(), abs(), and sign() built in functions.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21927 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoUnify constant floats and constant doubles; they can all be constant doubles.
John Kessenich [Mon, 10 Jun 2013 21:56:23 +0000 (21:56 +0000)]
Unify constant floats and constant doubles; they can all be constant doubles.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21921 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd constant folding for length(), normalize(), fwidth(), dFdx(), and dFdy().
John Kessenich [Mon, 10 Jun 2013 07:37:49 +0000 (07:37 +0000)]
Add constant folding for length(), normalize(), fwidth(), dFdx(), and dFdy().

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21918 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoA round of increasing robustness against buffer overruns.
John Kessenich [Mon, 10 Jun 2013 07:36:26 +0000 (07:36 +0000)]
A round of increasing robustness against buffer overruns.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21917 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd semantic check for ES variably indexing a uniform block.
John Kessenich [Fri, 7 Jun 2013 19:07:39 +0000 (19:07 +0000)]
Add semantic check for ES variably indexing a uniform block.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21894 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd more tests for built-in variables.
John Kessenich [Fri, 7 Jun 2013 18:54:19 +0000 (18:54 +0000)]
Add more tests for built-in variables.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21893 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoBlock/structure fixes: Merge qualifiers with multiple declarators, handle arrays...
John Kessenich [Thu, 6 Jun 2013 18:31:21 +0000 (18:31 +0000)]
Block/structure fixes: Merge qualifiers with multiple declarators, handle arrays of blocks, more semantic checks for what's allowed.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21883 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoFix another problem with undefined macros needing to evaluate to 0 within a preproces...
John Kessenich [Mon, 3 Jun 2013 04:15:57 +0000 (04:15 +0000)]
Fix another problem with undefined macros needing to evaluate to 0 within a preprocessor expression, but not outside a preprocessor expression.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21815 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoThe new test that was to have been added with the previous check in.
John Kessenich [Sun, 2 Jun 2013 22:57:37 +0000 (22:57 +0000)]
The new test that was to have been added with the previous check in.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21814 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd test for operation semantics, fix one bug it found.
John Kessenich [Thu, 30 May 2013 23:31:38 +0000 (23:31 +0000)]
Add test for operation semantics, fix one bug it found.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21798 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoA bunch of semantic checks were missing for binary arithmetic operations. Refactor...
John Kessenich [Thu, 30 May 2013 19:15:35 +0000 (19:15 +0000)]
A bunch of semantic checks were missing for binary arithmetic operations. Refactor the "promote" logic to fix these.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21784 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoChange warning to error for use of double underscore.
John Kessenich [Wed, 29 May 2013 22:40:31 +0000 (22:40 +0000)]
Change warning to error for use of double underscore.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21765 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd missing type check for operands having the same type (after conversion) around...
John Kessenich [Tue, 28 May 2013 07:29:58 +0000 (07:29 +0000)]
Add missing type check for operands having the same type (after conversion) around the ":" in a "?:" operation.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21721 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd precision qualifier propagation for swizzling, texture lookups, built-in funtions...
John Kessenich [Fri, 17 May 2013 02:51:45 +0000 (02:51 +0000)]
Add precision qualifier propagation for swizzling, texture lookups, built-in funtions mapped to operators, comma op, and more robustly propagate for all binary/unary ops.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21622 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoRemove too aggressive and redundant lexical keyword check: attribute and varying...
John Kessenich [Tue, 7 May 2013 23:48:06 +0000 (23:48 +0000)]
Remove too aggressive and redundant lexical keyword check: attribute and varying can always be error checked in the grammar.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21443 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoMake the PP report an error on undefined macro in "#if ..." for ES profiles, unless...
John Kessenich [Sun, 5 May 2013 23:46:22 +0000 (23:46 +0000)]
Make the PP report an error on undefined macro in "#if ..." for ES profiles, unless relaxed error checking is requested.  Still works as normal CPP on non-ES.

Also, improved error reporting in general for the PP.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21417 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd 3 missing reserved keywords.
John Kessenich [Fri, 26 Apr 2013 09:36:42 +0000 (09:36 +0000)]
Add 3 missing reserved keywords.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21296 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoFor all keywords already present, get correct when they could be identifiers, are...
John Kessenich [Thu, 25 Apr 2013 16:44:03 +0000 (16:44 +0000)]
For all keywords already present, get correct when they could be identifiers, are reserved words, or are keywords, for all versions of ESSL and GLSL.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21282 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoPut memory counter stuff in #ifdef _WIN32.
John Kessenich [Wed, 17 Apr 2013 19:34:23 +0000 (19:34 +0000)]
Put memory counter stuff in #ifdef _WIN32.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21181 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd some more qualifier helper functions.
John Kessenich [Wed, 17 Apr 2013 05:02:12 +0000 (05:02 +0000)]
Add some more qualifier helper functions.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21173 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoFix dependency misspelling that caused unnecessary grammar rebuilds.
John Kessenich [Mon, 15 Apr 2013 00:14:34 +0000 (00:14 +0000)]
Fix dependency misspelling that caused unnecessary grammar rebuilds.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21142 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoRationalize command-line options: controlling memory leak testing, AST output, and...
John Kessenich [Sun, 14 Apr 2013 19:23:50 +0000 (19:23 +0000)]
Rationalize command-line options: controlling memory leak testing, AST output, and info log output.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21141 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoForce "smooth" interpolation qualification when in a fragment shader.
John Kessenich [Sat, 13 Apr 2013 06:05:31 +0000 (06:05 +0000)]
Force "smooth" interpolation qualification when in a fragment shader.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21140 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoSmall tweak to switch statements: use a smaller base class.
John Kessenich [Fri, 12 Apr 2013 22:57:28 +0000 (22:57 +0000)]
Small tweak to switch statements: use a smaller base class.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21138 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoUpdate all "TODO", add some comments.
John Kessenich [Fri, 12 Apr 2013 17:17:07 +0000 (17:17 +0000)]
Update all "TODO", add some comments.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21137 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoMinor changes: remove use of 'auto', plug obscure memory leak, update copyright.
John Kessenich [Fri, 12 Apr 2013 16:50:28 +0000 (16:50 +0000)]
Minor changes: remove use of 'auto', plug obscure memory leak, update copyright.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21136 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd switch/case/default statements, using a switch node that contains a sequence...
John Kessenich [Fri, 12 Apr 2013 03:57:02 +0000 (03:57 +0000)]
Add switch/case/default statements, using a switch node that contains a sequence of case/default nodes and top-level nodes of the code chunks in between them.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21131 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years ago- Temp fix for the GLSL yacc file (linux builds failing).
John Kessenich [Thu, 11 Apr 2013 22:38:16 +0000 (22:38 +0000)]
- Temp fix for the GLSL yacc file (linux builds failing).

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21130 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd the GL_ES macro for ES personalities, along with a general mechanism for adding...
John Kessenich [Thu, 11 Apr 2013 16:31:09 +0000 (16:31 +0000)]
Add the GL_ES macro for ES personalities, along with a general mechanism for adding preambles in front of shaders without effecting line numbers, etc.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21122 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdditional layout-related error checking.
John Kessenich [Wed, 10 Apr 2013 23:30:05 +0000 (23:30 +0000)]
Additional layout-related error checking.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21108 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoImplement default layout qualifiers at global and block levels with proper inheritanc...
John Kessenich [Wed, 10 Apr 2013 22:26:56 +0000 (22:26 +0000)]
Implement default layout qualifiers at global and block levels with proper inheritance.  Also add more error checking of qualifiers.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21107 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd anonymous members as a new symbol table type, so the infrastructure can handle...
John Kessenich [Wed, 10 Apr 2013 20:15:16 +0000 (20:15 +0000)]
Add anonymous members as a new symbol table type, so the infrastructure can handle blocks with no names.

Also, add more safety to the types involved regarding copy constructors, operator=, etc.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21106 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoChange TType member from "type" to "basicType". It was very confusing.
John Kessenich [Wed, 10 Apr 2013 02:28:55 +0000 (02:28 +0000)]
Change TType member from "type" to "basicType". It was very confusing.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21094 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd interface blocks as a basic type and handle uniform blocks that have an instance...
John Kessenich [Wed, 10 Apr 2013 02:06:46 +0000 (02:06 +0000)]
Add interface blocks as a basic type and handle uniform blocks that have an instance name.  Includes handling qualifiers on structure members.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21093 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoInitial implementation of layout qualifiers. More to come after uniform blocks are...
John Kessenich [Tue, 9 Apr 2013 01:20:01 +0000 (01:20 +0000)]
Initial implementation of layout qualifiers.  More to come after uniform blocks are in place.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21078 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoPut in correct rules for multiple versions of qualification and typing of inputs...
John Kessenich [Sun, 7 Apr 2013 22:43:16 +0000 (22:43 +0000)]
Put in correct rules for multiple versions of qualification and typing of inputs and outputs.  Also, removed EvqAttribute, merging it with EvqVaryingIn.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21064 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd ES 300 built-ins trunc, round, roundEven, modf, isnan, isinf, floatBitsToInt...
John Kessenich [Sun, 7 Apr 2013 20:04:12 +0000 (20:04 +0000)]
Add ES 300 built-ins trunc, round, roundEven, modf, isnan, isinf, floatBitsToInt, floatBitsToUint, intBitsToFloat, uintBitsToFloat, packSnorm2x16, unpackSnorm2x16, packUnorm2x16, unpackUnorm2x16, packHalf2x16, and unpackHalf2x16, and new form of min, max, clamp, and mix.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21063 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoSplit out the unary-argument built-in function path from the addUnaryMath() path...
John Kessenich [Sun, 7 Apr 2013 02:10:55 +0000 (02:10 +0000)]
Split out the unary-argument built-in function path from the addUnaryMath() path, allowing the return types to be treated correctly without any special casing.  Also, implement the correct precision qualifier propagation rules for built-in functions mapped to operators.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21062 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd uint type (big change). For both int/uint, add the operators >>, <<, &, |, and...
John Kessenich [Fri, 5 Apr 2013 04:05:39 +0000 (04:05 +0000)]
Add uint type (big change).  For both int/uint, add the operators >>, <<, &, |, and ^.  Also added unsigned literals and uint precision support.  Also fixed how int/uint literal underflow/overflow is handled.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21054 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoCPP: Handle the "u" and "U" suffixes for uint literals, and correctly handle underfl...
John Kessenich [Wed, 3 Apr 2013 18:42:43 +0000 (18:42 +0000)]
CPP:  Handle the "u" and "U" suffixes for uint literals, and correctly handle underflow/overflow of integer literals.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@21033 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd a forward reference function call test.
John Kessenich [Thu, 21 Mar 2013 17:33:38 +0000 (17:33 +0000)]
Add a forward reference function call test.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20945 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoFix release build, it was missing the custom build steps.
John Kessenich [Wed, 13 Mar 2013 01:58:33 +0000 (01:58 +0000)]
Fix release build, it was missing the custom build steps.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20845 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd and use ability to tell the backend compiler what version/profile the source...
John Kessenich [Tue, 12 Mar 2013 17:53:55 +0000 (17:53 +0000)]
Add and use ability to tell the backend compiler what version/profile the source shader was.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20840 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoA few trivial things, including removing '/' as a command line option indicator so...
John Kessenich [Tue, 12 Mar 2013 17:52:59 +0000 (17:52 +0000)]
A few trivial things, including removing '/' as a command line option indicator so absolute paths work naturally.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20839 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoGet a clean g++/gcc build. Runs and gets correct results on linux.
John Kessenich [Sat, 9 Mar 2013 19:50:19 +0000 (19:50 +0000)]
Get a clean g++/gcc build.  Runs and gets correct results on linux.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20820 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAnother round of gcc/g++ fixes.
John Kessenich [Fri, 8 Mar 2013 23:14:42 +0000 (23:14 +0000)]
Another round of gcc/g++ fixes.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20819 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd warning-suppression flag. Combined with relaxed errors, so an enum can be used...
John Kessenich [Fri, 8 Mar 2013 19:26:11 +0000 (19:26 +0000)]
Add warning-suppression flag.  Combined with relaxed errors, so an enum can be used instead of many bools.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20818 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd compilation mode flags for forward-compatible contexts and relaxed error checking...
John Kessenich [Fri, 8 Mar 2013 18:49:22 +0000 (18:49 +0000)]
Add compilation mode flags for forward-compatible contexts and relaxed error checking.  These initiate as arguments to ShCompile() and both default to being off.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20817 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoUpgrade to MSVC 11. Fix pool_allocator a bit.
John Kessenich [Fri, 8 Mar 2013 06:51:50 +0000 (06:51 +0000)]
Upgrade to MSVC 11.  Fix pool_allocator a bit.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20811 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoChange infrastructure to support constant folding across built-in functions, as requi...
John Kessenich [Thu, 7 Mar 2013 19:22:07 +0000 (19:22 +0000)]
Change infrastructure to support constant folding across built-in functions, as required by 1.2 semantics.  Partially fleshed out with min/max and some trig functions.  Still have to complete all operations.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20806 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd unsigned ints to constUnions. (Unsigned int support is still partial throughout.)
John Kessenich [Thu, 7 Mar 2013 01:02:02 +0000 (01:02 +0000)]
Add unsigned ints to constUnions.  (Unsigned int support is still partial throughout.)

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20790 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoMinor updates to tests.
John Kessenich [Mon, 4 Mar 2013 23:50:08 +0000 (23:50 +0000)]
Minor updates to tests.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20758 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoAdd productions/data for about 14 qualifiers (versions 1.2 through 4.3). Fixed some...
John Kessenich [Fri, 1 Mar 2013 21:53:13 +0000 (21:53 +0000)]
Add productions/data for about 14 qualifiers (versions 1.2 through 4.3). Fixed some case issues for rect/array keywords.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20742 e7fa87d3-cd2b-0410-9028-fcbf551c1848

11 years agoImplement operator-based implicit type conversions.
John Kessenich [Thu, 28 Feb 2013 20:49:41 +0000 (20:49 +0000)]
Implement operator-based implicit type conversions.

git-svn-id: https://cvs.khronos.org/svn/repos/ogl/trunk/ecosystem/public/sdk/tools/glslang@20724 e7fa87d3-cd2b-0410-9028-fcbf551c1848