1. 08 Dec, 2020 1 commit
  2. 03 Dec, 2020 1 commit
  3. 30 Nov, 2020 1 commit
    • update spirv-headers and fix handling of gl_HitTEXT (#2471) · e11a2c8b
      Daniel Koch authored
      * update spirv-headers and fix handling of gl_HitTEXT
      
      Update spirv-headers known_good to f027d53ded7e230e008d37c8b47ede7cd308e19d
      and update SPIRV/spirv.hpp to copy from that version as well.
      
      In GLSL gl_HitTNV/gl_HitTEXT is defined as an alias of gl_RayTmaxNV/gl_RayTmaxEXT
      SPV_NV_ray_tracing has a dedicated HitTNV which gl_HitTNV maps to.
      For SPV_KHR_ray_tracing, gl_HitTEXT gets mapped to a RayTmaxKHR decoraged variable
      to simplify the SPIRV consumer.
      This change fixes the mapping for the GL_EXT_ray_tracing extension, and updates
      the test results to match.
      
      * update MissNV shader test to not use ObjectRay builtins
      
      They shouldn't existing in the miss stage because there is no object intersected
  4. 25 Nov, 2020 1 commit
  5. 23 Nov, 2020 1 commit
    • Updates for final Vulkan ray tracing extensions (#2466) · ffccefdd
      Daniel Koch authored
      * Fix traceRay/executeCallable to have id instead of constant.
      
      Update to final (non-provisional) SPIR-V capabilities
      (includes review feedback)
      - Change visibilty of findLinkerObjects.
      
      See merge request GLSL/glslang!78
      
      * Add support for OpConvertUToAccelerationStructureKHR.
      
      GLSL : https://gitlab.khronos.org/GLSL/GLSL/-/merge_requests/60
      
      SPV : https://gitlab.khronos.org/spirv/spirv-extensions/-/merge_requests/182
      
      See merge request GLSL/glslang!77
      
      * Add volatile qualifier to certain builtins for ray tracing.
      
      See merge request GLSL/glslang!81
      
      * make gl_RayTmaxEXT volatile in intersection shader
      
      Vulkan Issue #2268
      
      * Add testing for layouts on SBT
      
      vulkan/vulkan#2230
      
      - no layout specified should be same as std430
      - explicitly test std140, std430, scalar layouts
      
      See merge request GLSL/glslang!86
      
      * Support for new opcodes OpIgnoreIntersectionKHR and OpTerminateRayKHR
      
      vulkan/vulkan#2374
      
      Add support for ignoreIntersectionEXT and terminateRayEXT as block
      terminator statements.
      
      See merge request GLSL/glslang!87
      
      * Fix code-generation issues with global ray query variables
      
      See merge request GLSL/glslang!88
      
      * update dependencies for spirv-headers and tools
      
      And update mesh shader results
      
      * Fix indeterminate argument ordering
      Authored-by: 's avatarDavid Neto <dneto@google.com>
      Co-authored-by: 's avatarAshwin Lele (NVIDIA Corporation) <alele@nvidia.com>
      Co-authored-by: 's avatarNeslisah <Neslisah.Torosdagli@amd.com>
  6. 16 Nov, 2020 1 commit
  7. 12 Nov, 2020 3 commits
    • tweak local_size comparison a bit (#2456) · beec2e4a
      Malcolm Bechard authored
      no longer causes an incorrect error if the current unit has local_size
      set, but the incoming unit does not
    • Avoid spuriously adding Geometry capability for vert, tesc, tese (#2462) · fb53f835
      David Neto authored
      Use of gl_Layer and gl_ViewportIndex in tessellation and vertex
      shaders should not trigger the addition of the Geometry capability.
      
      Fixes #2461
      
      Added tests for use of gl_Layer and gl_ViewportIndex in a tessellation
      evaluation shader.
      
      Several tests for NVIDIA features for tessellation, vertex, or mesh
      shaders now lose the Geometry or MultiViewport capabilities.
      This is ok because the functionality is already covered by
      the ShaderViewportIndexLayerNV capability.
      
      The spv.meshShaderPerViewBuiltins.mesh test now fails validation
      because the validator does not know that PrimitiveId (and possibly
      other) builtins are enabled by the MeshShadingNV capability.
      I filed https://github.com/KhronosGroup/SPIRV-Headers/issues/179 to
      fix the grammar upstream.
    • New nonuniform analysis (#2457) · 639f5461
      greg-lunarg authored
      This implements a new nonunifom analysis suggested by @jbolz. This change
      generates nonUniform decorations that were previously missing and avoids
      generation of incorrect decorations. Most notably, it now generates
      decorations for nonuniform functions and out params. It avoids generating
      decorations for lvalues which themselves are not nonuniform.
  8. 09 Nov, 2020 1 commit
  9. 06 Nov, 2020 1 commit
  10. 05 Nov, 2020 1 commit
  11. 04 Nov, 2020 1 commit
  12. 03 Nov, 2020 2 commits
    • 8. io mapping refine & qualifier member check & resolver expand (#2396) · 478b2329
      Chow authored
      * Code refine and adding missing features
      
      1. Add new level for built in symbols.
      2. Fix issues for structure members' qualifiers.
      3. Global qualifier fix.
      4. IO Mapper refine. Add support for checking with mangle names.
      
      * Additional missing features
      
      * Invariant member. (Only check non-interface).
      
      * Split block nesting level and struct nesting level. To fix issues of checking 'invariant' qualifier.
      
      Current grammar would check block/struct member without its parent class's information.
      So we split nesting level, and 'invariant' would only be checked within a struct.
      
      * Format anonymous block names. Refine codes for symbols from all kinds of resouces.
      
      * Fix writeonly check.
      
      * Use LValueBase to find operator.
      
      * Fix random null ptr issue.
      
      * invariant check, stage in io mapping, reference parameter should be used and remove wrong codes introduced with ordering vector.
      
      * Remained: to be fixed with double check link.vk.multiblocksValid
      
      * Fix version error.
      
      invariant
      
      * Revert loc modification.
    • Fix build error with Chromium & ANGLE (#2446) · d550bebe
      Courtney Goeltzenleuchter authored
      Getting error about undefined symbol (include_dir) at line 320.
      Was trying to append to a non-existant variable.
      
      Bug #2445
  13. 02 Nov, 2020 3 commits
    • Add new SpirvToolsDisassemble API interface + Improve Doc on existing API interface (#2442) · c897c3bc
      pheonix authored
      * Add new SpirvToolsDisassemble API interface + Improve Doc on existing API interface (#2408)
      
      * Add more flexible SpirvToolsDisassemble interface to allow specifying spv_target_env for disassembly output.
      Improve documentation on existing SpirvToolsDisassemble interface.
      
      * Update pre-processor check - following existing ENABLE_OPT checks.
      
      * Fix not-found header paths for glslangValidator and glslangtests.
      
      * Add spirv_tools/include path where there is an ENABLE_OPT=1 in the BUILD.gn configuration.
    • Support for CapabilityShaderViewportIndex and CapabilityShaderLayer (#2432) · 56350cad
      Sidney Just authored
      * When targeting SPIR-V 1.5, using gl_ViewportIndex will emit OpCapability ShaderViewportIndex and using gl_Layer will emit OpCapability CapabilityShaderLayer. OpCapability ShaderViewportIndexLayerEXT will only get emitted if the target < SPIR-V 1.5
      
      * When using one of the viewport/layer arrays extensions, fallback to OpCapability ShaderViewportIndexLayerEXT, even when targeting SPIR-V 1.5
      
      * Revert "When using one of the viewport/layer arrays extensions, fallback to OpCapability ShaderViewportIndexLayerEXT, even when targeting SPIR-V 1.5"
      
      This reverts commit dccca82f4076ea6e2bc01dd6d1e5d290c59fab20.
      
      * Using gl_Layer and gl_ViewportIndex outside of the geometry shader stage still requires one of the viewport extensions even when targeting SPIR-V 1.5
      (Fixes a problem introduced by 670536b663f396815645b2f907f0ee92117b44f0)
    • Do not use PropagateLineInfoPass and RedundantLineInfoElimPass (#2440) · ed8bd045
      Jaebaek Seo authored
      * Do not use PropagateLineInfoPass and RedundantLineInfoElimPass
      
      Since spirv-opt will remove PropagateLineInfoPass and
      RedundantLineInfoElimPass, glslang should not use it. spirv-opt will
      propagate the line instructions and eliminate the redundant lines by
      default in IR loading/emission.
      
      * Update known_good.json for spirv-tool
  14. 30 Oct, 2020 1 commit
  15. 26 Oct, 2020 1 commit
  16. 24 Oct, 2020 1 commit
    • HLSL: Add support for printf(). · f6e0fe86
      Rex Xu authored
      Translate printf() to what GL_EXT_debug_printf has done. HLSL could
      define non-constant string variable and we don't have such features
      in SPIR-V, so just support constant string variable.
  17. 22 Oct, 2020 1 commit
  18. 21 Oct, 2020 1 commit
    • Fix GN build and presubmits · 0f52e7ef
      Ben Clayton authored
      Add missing `.cfg` files for GN presubmit.
      Add missing `recursedeps` in the `DEPS` file.
      Call `./update_glslang_sources.py` before attempting to build.
      Add more GN spew to the `.gitignore` file.
  19. 20 Oct, 2020 5 commits
  20. 19 Oct, 2020 2 commits
    • Merge pull request #2422 from ben-clayton/gn · 3ead0119
      John Kessenich authored
      Add basic GN configurations
    • Fix uninitialized use of TIntermediate::resource (#2424) · 5b99b448
      Ben Clayton authored
      TIntermediate was constructed without initializing any of the `resources` fields,
      and `TProgram::linkStage()` was not calling `TIntermediate::setLimits()`
      after constructing new `TIntermediate`s for non-first stages.
      
      Fields of `resources` were then read in `TIntermediate::finalCheck()`
      triggering undefined behavior.
      
      This CL makes three changes:
      (1) `TIntermediate::setLimits()` is now called for non-first stages by
          copying the `firstIntermediate`'s limits. This ensures that the
          `resources` fields is initialized, fixing the bug.
      (2) `TIntermediate::resources` is now wrapped in a `MustBeAssigned<>`
          helper struct, asserting in non-release builds that this field is
          always initialized before reading.
      (3) `TIntermediate::resources` is now zero-initialized, so that if
          the `TIntermediate::resources` field is not set in a release build
          (and so the `assert()` will be disabled) behavior is still
          deterministic.
      
      Fixes #2423
  21. 16 Oct, 2020 2 commits
  22. 12 Oct, 2020 2 commits
  23. 07 Oct, 2020 2 commits
  24. 05 Oct, 2020 2 commits
  25. 28 Sep, 2020 1 commit
  26. 27 Sep, 2020 1 commit
    • Add more flexible SpirvToolsDisassemble interface to allow specifying… · 2eed8236
      pheonix authored
      Add more flexible SpirvToolsDisassemble interface to allow specifying spv_target_env for disassembly output. (#2406)
      
      Improve documentation on existing SpirvToolsDisassemble interface.
      Fix cmake build scripts to account for `spirv-tools` external when -DENABLE_OPT=ON