Commit Graph

  • 09709c1521 Don't allow invariant in a function. John Kessenich 2013-11-11 23:51:57 +00:00
  • e74fe56b02 Update Linux binaries John Kessenich 2013-11-11 23:31:44 +00:00
  • bd1a5b7727 Add GL_OES_EGL_image_external. Includes new keyword, type, name mangling, built-in function calls, etc. John Kessenich 2013-11-11 23:29:59 +00:00
  • 99296369d3 Add GL_EXT_frag_depth. John Kessenich 2013-11-11 20:51:50 +00:00
  • 06a37c3964 Add GL_OES_standard_derivatives. Also added extension infrastructure that allows built-in symbols to be tagged with extensions and automatically error checked against them. John Kessenich 2013-11-11 20:31:45 +00:00
  • 115a0adc29 Add GL_OES_texture_3D extension. Also, minor tweaks to extension adding infrastructure. John Kessenich 2013-11-11 18:50:06 +00:00
  • df81ce90c3 Update Linux binaries John Kessenich 2013-11-11 17:01:55 +00:00
  • 359326b866 Minor consistency fix: Define built-in functions to have bodies. John Kessenich 2013-11-11 04:59:32 +00:00
  • a4351c55e8 More subtle checking for redeclarations: - 300 doesn't allow built-in overload, while 100 does, while neither allows redefining - block name can't be reused for block name within the same interface (though, the spec. isn't clear about that, it's easier than verifying member matches, will file bug on it) John Kessenich 2013-11-11 04:21:31 +00:00
  • 4d6570a1b3 Fix several issues in the preprocessor: - macro expansion of hexidecimal numbers - give errors instead of warnings/silence on extra tokens after #endif, #else, etc. - give errors on reserved macro name use, reuse of argument, and redefinition with different whitespace presence - detect and give error for all cases of #elif and #else after #else John Kessenich 2013-11-10 23:07:36 +00:00
  • cfe3ba5a18 update linux binaries John Kessenich 2013-11-09 00:19:17 +00:00
  • 77d908af8a Added constant folding for relational (e.g. lessThan) built-ins, relational built-ins for uints, and bitwise ops for mixed scalars and vectors. John Kessenich 2013-11-09 00:18:22 +00:00
  • 0876a58203 Misc. constant-folding fixes: Check % for 0, mat(mat) constructor, index range checking (within constant objects). Also, rationalize addConst*() methods. John Kessenich 2013-11-08 21:47:56 +00:00
  • 6d7fe63d76 Update glslang_vs2010 project to use C7 Compatible Debug information (/C7) so that projects that link against it don't have LNK4204 warnings. Also fix errant space in "StandAlone _vs2010.sln". John Kessenich 2013-11-08 12:59:26 +00:00
  • 49d6121288 update linux binaries John Kessenich 2013-11-08 07:14:31 +00:00
  • 01c22afa37 Add some missing invariant semantic checks, replace some misplaced sampler semantic checks, add parameter and structure member checks against new qualifiers. John Kessenich 2013-11-08 07:13:18 +00:00
  • c999ba2816 Complete hook up all the compile/link errors to the command-line exit status. (Also, an updated test left from the last check-in.) John Kessenich 2013-11-07 23:33:24 +00:00
  • b0a7eb599b Stop emitting the "#version missing" warning, and hook up the existing "suppress warnings" to a command-line option (-w). John Kessenich 2013-11-07 17:44:20 +00:00
  • d627502d07 remove ^M John Kessenich 2013-11-07 01:48:13 +00:00
  • 3ac3578968 Fix some Linux issues. John Kessenich 2013-11-07 01:36:56 +00:00
  • 11f9fc7247 Add and partially implement an interface for doing uniform reflection. It includes an AST traversal to identify live accesses. John Kessenich 2013-11-07 01:06:34 +00:00
  • 8ec55cdcd2 Clean up/resolve a bunch of TODO, which included implementing pixel_center_integer and origin_upper_left and adjusting what versions see legacy texturing names. John Kessenich 2013-11-05 18:07:25 +00:00
  • c36e1d8e51 Interface and naming improvements: - the new C++ style interface now stands on its own, with the addition of glslang::InitializeProcess() and glslang::FinalizeProcess() - more "global" pool names from a decade ago are fixed to be thread names - StandAlone.cpp fully uses one of the old-style interface or new C++ style interface John Kessenich 2013-11-01 17:41:52 +00:00
  • 5b0f13acbc Include per-shader and per-program pools in the new C++ interface to glslang. (And picked up missing test result from previous check in.) John Kessenich 2013-11-01 03:08:40 +00:00
  • 83a6b1edfc Fix parameter count bug in ambiguity checking for overloaded function matching under implicit conversions. John Kessenich 2013-10-31 18:05:50 +00:00
  • 0d22e31c75 Implement 1.20 style function signature matching under implicit conversion. This was the last key unimplemented feature of versions 120 through 330. John Kessenich 2013-10-30 23:17:34 +00:00
  • 8cbd18ecaa Fix recursion detection (it was detecting cycles in the call graph that were not directed cycles). John Kessenich 2013-10-30 01:22:04 +00:00
  • d492aafad7 Add VS2010 version of solution file and projects. These differ from the VS2012 versions checked in as follows: John Kessenich 2013-10-29 16:25:15 +00:00
  • e17ef84753 Fix bug where bracket dereferences were incorrectly keeping the base's qualifier (for example constBase[i] would still be a const instead of EvqTemporary). John Kessenich 2013-10-28 19:49:16 +00:00
  • ea869fb403 Improve preprocessor by using GLSL scanner, allowing read-only strings to be compiled, unifying of line # tracking, and correct detection that ES #version appeared after a comment. John Kessenich 2013-10-28 18:12:06 +00:00
  • 9497485e14 Add geometry shader input array sizing/checking WRT declared input primitive layout. John Kessenich 2013-10-24 22:41:04 +00:00
  • ab41fe5df6 Add redeclarations of built-in blocks. John Kessenich 2013-10-24 01:25:40 +00:00
  • 94fdd1117b Add geometry-shader stream, invocations, max_vertices, lines, triangles, etc. layout qualifiers, and their default/inheritance behaviors, and some other misc. geometry shader features. (Geometry shaders are not yet done though.) John Kessenich 2013-10-23 19:34:05 +00:00
  • 284231c9c5 Add built-in constants through version 440. Some still need to be consumed when initializing the symbol table. John Kessenich 2013-10-22 01:50:39 +00:00
  • c78a126ba6 Tie "location = " to the right stages/versions/extensions. Also add "#define extension 1" extension support and instructions. John Kessenich 2013-10-22 00:21:04 +00:00
  • bf688510a8 For portability, use std::map instead of std::hash_map in recent preprocessor fix. John Kessenich 2013-10-21 19:50:14 +00:00
  • 21a8770f92 Add texture gather functions (and extension check) for GLSL 400 and GL_ARB_texture_gather. John Kessenich 2013-10-21 19:25:59 +00:00
  • a65dc63d46 Update Linux binaries John Kessenich 2013-10-21 16:13:46 +00:00
  • 028dbad0e9 Update Window's binary. John Kessenich 2013-10-21 16:12:23 +00:00
  • c973c004d4 Non-functional: Use better token names for the preprocessor. John Kessenich 2013-10-20 18:37:53 +00:00
  • 1f4104fbb1 Fix memory corruption problem in the preprocessor, removing custom hash-tables/etc. and replacing with std containers. John Kessenich 2013-10-20 18:18:36 +00:00
  • ab3080353a Add layout binding qualifier for blocks and samplers (atomics are not yet in, nor link validation). John Kessenich 2013-10-18 21:37:55 +00:00
  • 8f13e1322d Add swizzles to scalars. John Kessenich 2013-10-18 03:56:23 +00:00
  • 8d8f4cc408 Minor preprocessor fix for error message line/string numbers coming from source line, not macro line. John Kessenich 2013-10-18 03:09:37 +00:00
  • e46b087760 Add function "const", where the initializer does not have to be a compile-time constant. John Kessenich 2013-10-17 20:55:30 +00:00
  • 779e6b406a Add C-style curly-brace initializers. John Kessenich 2013-10-17 19:43:43 +00:00
  • e7c59c187c Add all built-in variables for all versions/profiles/stages of GLSL. Also, made more readable; declarations are cut and paste from the specs, with quotes around them. This does not include built-in constants yet (other than MaxClipDistances), just the non-constants. John Kessenich 2013-10-16 22:28:35 +00:00
  • 457145ded5 Have block members use EvqVaryingIn rather than EvqIn, etc., confining the EvqIn-class of qualifier just to parameters and parse time (before it's known if something is a parameter). Also, have member error messages report their actual line, rather than the block's line. John Kessenich 2013-10-16 04:08:21 +00:00
  • fb57e7cc5e Add ES 3.0 fragment output link-time test for outputs having or not having location qualifiers. John Kessenich 2013-10-15 21:46:20 +00:00
  • 27b72e42c3 Implement ES 2.0 (version 100) limitations for non-inductive loop detection and array indexes needing "constant-index-expressions" (inductive variables and constant expressions). John Kessenich 2013-10-14 22:42:16 +00:00
  • a4ea1313c3 Turn on non-uniform blocks (in/out/buffer), and prevent new stages from working with "no profile" (before 150) shaders. John Kessenich 2013-10-11 19:46:10 +00:00
  • 9d30218fb6 Generalize the symbol hierarchy to transparently handle anonymous-block members better. John Kessenich 2013-10-11 17:29:19 +00:00
  • 4c70685382 Memory management hygiene: Use compare() instead of substr(), and put a few more things intrinsically in the memory pool. John Kessenich 2013-10-11 16:28:43 +00:00
  • 3afe67dcc2 Non-functional: Remove use of the unused structure 'remapper', and other minor internal improvements. Triggered by some bigger changes in the works. Also, turned on an existing test that was not included in the test list. John Kessenich 2013-10-09 00:20:26 +00:00
  • 7ea2f9c39f Fix g++ complaint about taking address of temporary. John Kessenich 2013-10-07 22:02:36 +00:00
  • b5af825841 Update Linux binaries John Kessenich 2013-10-07 22:01:27 +00:00
  • 941d156c13 Update Windows binary. John Kessenich 2013-10-07 21:54:43 +00:00
  • 98c2ef25de Non-functional changes: Typo in error message and in comment, remove unneeded arguments, separate constructor-op mapping from handling constructors. John Kessenich 2013-10-05 19:03:50 +00:00
  • 816e9bc90b Improve robustness of extension checking, and its intersection with ES 100 features. John Kessenich 2013-10-04 21:09:36 +00:00
  • c6b7e6350b Make ES 100 gl_FragData be a mediump, and fix some warnings from g++. John Kessenich 2013-10-04 03:05:45 +00:00
  • e50441ad94 Make some portability improvements identified by Christophe: A few size_t, a couple "../Include", and a whole bunch of parenthesizing "(A && B) || (C && D)", because some compilers don't believe humans know && is higher precedence than ||. John Kessenich 2013-10-04 02:27:06 +00:00
  • 61c2d1410a Document how to add a new feature enabled by an extension in Versions.cpp. Also reorganized slightly to localize related functions. John Kessenich 2013-10-03 20:23:57 +00:00
  • a5830dfc0e Add the following ESSL 2.0 (#version 100) limitations to the configuration file, internal infrastructure, and test cases. Still need to implement the actual detection of non-inductive loops and array accesses. While and do-while loop detection is done. John Kessenich 2013-10-02 05:10:48 +00:00
  • 44e8cae80a Allow ES version 100 to redeclare built-in functions. John Kessenich 2013-10-02 01:30:14 +00:00
  • 447fc3613a Add message indicating level of completeness for not-yet-complete versions. John Kessenich 2013-10-01 23:13:50 +00:00
  • e29e4af7a7 Update Window's binary. John Kessenich 2013-10-01 22:05:18 +00:00
  • 04750f7948 Update Linux binaries John Kessenich 2013-10-01 22:04:33 +00:00
  • 2ecdd14288 Add function recursion testing to the link-time validation. John Kessenich 2013-10-01 21:58:43 +00:00
  • f2ee3dd46a Add full support for uniforms with initializers, including intra-stage link validation of aggregate constant initializers. John Kessenich 2013-09-28 04:02:08 +00:00
  • b3345c422d Fix g++ complaint with previous check in. John Kessenich 2013-09-26 00:53:10 +00:00
  • 9839e2440e Unify the 8 grammar productions for declaring variables. This greatly simplifies making changes for this set of productions. John Kessenich 2013-09-26 00:45:21 +00:00
  • 337dbc7d8c Add basic intra-stage linking validation for matching types and qualification of uniforms/ins/outs/globals, function body duplication, and mixing ES/non-ES shaders. John Kessenich 2013-09-24 21:18:46 +00:00
  • f5ebfb5f27 Test for and prevent any dead-code elimination, as all code is needed in the AST for static-use analysis. John Kessenich 2013-09-20 06:20:21 +00:00
  • c981efd84d Update Linux binaries John Kessenich 2013-09-17 22:44:35 +00:00
  • efd93d4342 Update the windows executable. John Kessenich 2013-09-17 22:42:02 +00:00
  • 05a7063007 Add optional configuration file for specifying (existing) limits. Details explained by usage statement. More limits to be added in the future. John Kessenich 2013-09-17 19:26:08 +00:00
  • b84b700d90 Basic infrastructure for redeclaring built-in variables (like gl_FragCoord) so shaders can change their type/layout. John Kessenich 2013-09-17 18:45:24 +00:00
  • 5f753e0222 Full thread safety working: - don't use [] for map lookups, it can modify the map - copy up built-in symbols out of shared symbol table levels before modifying them - enforce shallow vs. deep TType copies - combine maxArraySize with the array dimensions vector, encapsulate - remove chaining of array types John Kessenich 2013-09-08 21:04:46 +00:00
  • 38f3b890de Ensure the shared symbol table levels are read-only to make multi-threading safe. Also removed inadvertent extra copies of the symbol table shared across all stages. John Kessenich 2013-09-06 19:52:57 +00:00
  • 69f4b517c2 Add link validation infrastructure for multiple compilation units per stage. Includes a new, straightforward, C++ interface to the front end. John Kessenich 2013-09-04 21:19:27 +00:00
  • 2f1eb37d82 Some rationalization of TIntermediate (to own it's own tree root) and TParseHelper for better encapsulation. Needed by some upcoming intra-stage link validation. John Kessenich 2013-09-03 22:57:27 +00:00
  • 807b8e3b82 Remove TIntermediate's dependency on infoSink, simplify folding of constant aggregates, and infoSink use in constant folding. John Kessenich 2013-09-03 22:14:59 +00:00
  • fca7534044 Restore TDebugOptions, as code consuming this interface is still using it, even though the front-end proper no longer uses it. John Kessenich 2013-09-03 15:16:03 +00:00
  • 94a81fbd31 Option rationalization and minor clean up. John Kessenich 2013-08-31 02:41:30 +00:00
  • 8700e9e6d1 Add more constant folding cases for min, max, step, smoothstep, mix, clamp, atan, and pow. John Kessenich 2013-08-30 00:45:57 +00:00
  • b603f918a4 Put all glslang internals (but not the external interface) into the glslang namespace. John Kessenich 2013-08-29 00:39:25 +00:00
  • 23bdb29eac Move the complex pieces of C++ code from glslang.y to ParseHelper.cpp. Updated some tests. John Kessenich 2013-08-27 05:57:15 +00:00
  • d46b31fdc5 Give new scopes to non-compound (simple) if-then-else substatements, correcting scoping for declarations they contain. John Kessenich 2013-08-27 03:59:04 +00:00
  • 3af0d53dac Remove unnecessary TString constructors. John Kessenich 2013-08-27 03:43:13 +00:00
  • a5ea9c63f7 Dynamically allocate symbol table containers, so timing of clean up can be more easily controlled WRT memory pool cleanup. John Kessenich 2013-08-13 00:58:49 +00:00
  • 99a0576225 Share built-in symbols common to all stages for desktop (but still per profile per version). John Kessenich 2013-08-09 20:31:43 +00:00
  • c027579631 Put in infrastructure for tessellation, geometry, and compute stages, and partially flesh out with built-in functions. John Kessenich 2013-08-09 17:14:49 +00:00
  • 317f1af217 Update Linux binaries for name-mangling bug fix John Kessenich 2013-08-08 16:26:36 +00:00
  • 252b619066 Remove a mangled-name cache in the type that was sometimes stale. John Kessenich 2013-08-08 16:22:54 +00:00
  • 1b42f2a33d Add parse-time constant folding for isinf() and isnan(). John Kessenich 2013-08-06 20:22:51 +00:00
  • af262433ab Update Linux binaries John Kessenich 2013-08-05 17:11:37 +00:00
  • acc55c2724 Update the Windows binary. John Kessenich 2013-08-05 17:09:24 +00:00
  • 8d2fe45334 Linux abs() needs to be fabs(); a few other minor Linux tweaks. John Kessenich 2013-08-05 16:36:49 +00:00
  • 4586dbdc1b Track expected test results and add more README information. John Kessenich 2013-08-05 15:52:03 +00:00
  • 41a5918eaa Allow unsigned int in the "location = " grammar, and generally improve recognition of numeric literals to be up to spec. John Kessenich 2013-08-04 23:51:37 +00:00