shader-slang / slang

Making it easier to work with shaders
MIT License
1.78k stars 159 forks source link

Metal: Investigate why `slang-test` fails with valid shaders targeting Metal backend #4500

Open ArielG-NV opened 4 days ago

ArielG-NV commented 4 days ago

Shaders are failing with our Metal backend despite these being valid shaders (that compile successfully). Errors are likely the Metal GFX backend failing with slang-test input, actual reasons for failure are unknown:

  1. tests/language-feature/types/opaque/inout-param-opaque-type-in-struct.slang.1 (mtl)
  2. tests/language-feature/types/opaque/out-param-opaque-type-in-struct.slang.1 (mtl)
  3. tests/language-feature/types/opaque/return-opaque-type-in-struct.slang.1 (mtl) This is not an exhaustive list, there may be more shaders added later.

I think the problem has todo with the test syntax //TEST_INPUT:set C = new { {1, ubuffer(data=[2 3 4 5], stride=4)}, {6, ubuffer(data=[7 8 9 10], stride=4)} }

bmillsNV commented 4 days ago

@westlicht possible for you to take a look at these?

skallweitNV commented 4 days ago

The problem is that these shaders use parameter blocks which aren't yet supported on the gfx metal backend.