Git Product home page Git Product logo

Comments (5)

dneto0 avatar dneto0 commented on May 2, 2024

Acknowledged. Currently Shaderc doesn't support setting non-default resource limits. But we've known that it would eventually be needed. Thank you for raising this.

from shaderc.

dneto0 avatar dneto0 commented on May 2, 2024

My #277 will fix this issue.

For example:

$ cat x.comp
#version 450

layout(binding=0) uniform atomic_uint x;
layout(binding=1) uniform atomic_uint y;
void main() {}
$ glslc --target-env=opengl -c x.comp
x.comp:4: error: 'binding' : atomic_uint binding is too large; see gl_MaxAtomicCounterBindings
1 error generated.
$ glslc --target-env=opengl -c x.comp -flimit="MaxAtomicCounterBindings 2"
$ spirv-dis x.comp.spv --no-color
; SPIR-V
; Version: 1.0
; Generator: Khronos Glslang Reference Front End; 1
; Bound: 10
; Schema: 0
               OpCapability Shader
               OpCapability AtomicStorage
          %1 = OpExtInstImport "GLSL.std.450"
               OpMemoryModel Logical GLSL450
               OpEntryPoint GLCompute %main "main"
               OpExecutionMode %main LocalSize 1 1 1
               OpSource GLSL 450
               OpSourceExtension "GL_GOOGLE_cpp_style_line_directive"
               OpSourceExtension "GL_GOOGLE_include_directive"
               OpName %main "main"
               OpName %x "x"
               OpName %y "y"
               OpDecorate %x Offset 0
               OpDecorate %x Binding 0
               OpDecorate %y Offset 0
               OpDecorate %y Binding 1
       %void = OpTypeVoid
          %3 = OpTypeFunction %void
       %uint = OpTypeInt 32 0
%_ptr_AtomicCounter_uint = OpTypePointer AtomicCounter %uint
          %x = OpVariable %_ptr_AtomicCounter_uint AtomicCounter
          %y = OpVariable %_ptr_AtomicCounter_uint AtomicCounter
       %main = OpFunction %void None %3
          %5 = OpLabel
               OpReturn
               OpFunctionEnd

from shaderc.

dneto0 avatar dneto0 commented on May 2, 2024

Fixed by #277 and in particular 2df47b5

from shaderc.

 avatar commented on May 2, 2024

Again error with OpenGL

Compute info
------------
(0) : error C7006: no work group size specified

But It already declared

layout ( local_size_x = 256, local_size_y = 1, local_size_z = 1) in;

from shaderc.

dneto0 avatar dneto0 commented on May 2, 2024

@acterhd: That would be a different issue, unrelated to resource limits.
Please open a new issue, and provide your shader and the command line you used.
Also, without seeing a reproducible case, I'd guess that you'd get the same failure with the underlying glslangValidator compiler.

from shaderc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.