SPIRV-Cross/reference/shaders-msl/comp
Chip Davis 9d9415754b MSL: Add support for subgroup operations.
Some support for subgroups is present starting in Metal 2.0 on both iOS
and macOS. macOS gains more complete support in 10.14 (Metal 2.1).

Some restrictions are present. On iOS and on macOS 10.13, the
implementation of `OpGroupNonUniformElect` is incorrect: if thread 0 has
already terminated or is not executing a conditional branch, the first
thread that *is* will falsely believe itself not to be. Unfortunately,
this operation is part of the "basic" feature set; without it, subgroups
cannot be supported at all.

The `SubgroupSize` and `SubgroupLocalInvocationId` builtins are only
available in compute shaders (and, by extension, tessellation control
shaders), despite SPIR-V making them available in all stages. This
limits the usefulness of some of the subgroup operations in fragment
shaders.

Although Metal on macOS supports some clustered, inclusive, and
exclusive operations, it does not support them all. In particular,
inclusive and exclusive min, max, and, or, and xor; as well as cluster
sizes other than 4 are not supported. If this becomes a problem, they
could be emulated, but at a significant performance cost due to the need
for non-uniform operations.
2019-05-15 17:40:04 -05:00
..
access-private-workgroup-in-function.comp Deal with scoping for Private variables. 2018-05-16 10:49:30 +02:00
argument-buffers-discrete.msl2.argument.discrete.comp Rename "push descriptor set" to "discrete descriptor set". 2019-03-15 21:53:21 +01:00
argument-buffers-image-load-store.msl2.argument.comp MSL: Implement Metal 2.0 indirect argument buffers. 2019-03-15 11:01:27 +01:00
atomic.comp MSL: Fix infinite CAS loop on atomic_compare_exchange_weak_explicit(). 2019-04-05 21:28:57 -04:00
barriers.comp MSL: Add support for subgroup operations. 2019-05-15 17:40:04 -05:00
basic.comp Declare read-only SSBOs as const device in MSL. 2018-05-25 10:14:05 +02:00
bitcast-16bit-1.invalid.comp Always value-cast FP16 constants instead of using literals. 2019-02-20 12:30:01 +01:00
bitcast-16bit-2.invalid.comp Support bitcasts of 16-bit types. 2018-11-05 14:56:36 -06:00
builtins.comp MSL: Declare gl_WorkGroupSize constant with [[maybe_unused]]. 2019-03-28 10:54:18 +01:00
cfg-preserve-parameter.comp Enhancements to MSL compute and entry point naming. 2017-11-05 21:34:42 -05:00
coherent-block.comp Use declared binding in SPIR-V as a fallback for explicit MSL binds. 2018-04-04 12:25:11 +02:00
coherent-image.comp Use declared binding in SPIR-V as a fallback for explicit MSL binds. 2018-04-04 12:25:11 +02:00
composite-array-initialization.comp MSL: Declare gl_WorkGroupSize constant with [[maybe_unused]]. 2019-03-28 10:54:18 +01:00
composite-construct.comp MSL: Support copying array of arrays. 2018-09-12 09:54:55 +02:00
copy-array-of-arrays.comp MSL: Support array-of-arrays composite construction. 2018-09-12 10:25:51 +02:00
culling.comp MSL: Declare gl_WorkGroupSize constant with [[maybe_unused]]. 2019-03-28 10:54:18 +01:00
defer-parens.comp Enhance MSL testing and add numerous MSL test cases. 2017-01-30 22:55:21 -05:00
dowhile.comp Declare read-only SSBOs as const device in MSL. 2018-05-25 10:14:05 +02:00
force-recompile-hooks.swizzle.comp Take the vertex count from any indirect parameters passed. 2019-02-06 15:17:14 -06:00
functions.comp Fix passing arrays of arrays to functions in MSL. 2018-01-29 10:57:52 +01:00
global-invocation-id-writable-ssbo-in-function.comp CompilerMSL map many GLSL functions to MSL functions. 2017-05-19 18:14:08 -04:00
global-invocation-id.comp CompilerMSL map many GLSL functions to MSL functions. 2017-05-19 18:14:08 -04:00
image-cube-array-load-store.comp Fix image load/store on cube arrays in MSL. 2018-05-25 12:43:25 +02:00
image.comp Update test files 2018-01-29 06:40:45 -08:00
insert.comp Enhancements to MSL compute and entry point naming. 2017-11-05 21:34:42 -05:00
inverse.comp Declare read-only SSBOs as const device in MSL. 2018-05-25 10:14:05 +02:00
local-invocation-id.comp CompilerMSL map many GLSL functions to MSL functions. 2017-05-19 18:14:08 -04:00
local-invocation-index.comp CompilerMSL map many GLSL functions to MSL functions. 2017-05-19 18:14:08 -04:00
mat3.comp Use declared binding in SPIR-V as a fallback for explicit MSL binds. 2018-04-04 12:25:11 +02:00
mod.comp Declare read-only SSBOs as const device in MSL. 2018-05-25 10:14:05 +02:00
modf.comp Declare read-only SSBOs as const device in MSL. 2018-05-25 10:14:05 +02:00
packing-test-1.comp MSL: Declare gl_WorkGroupSize constant with [[maybe_unused]]. 2019-03-28 10:54:18 +01:00
packing-test-2.comp MSL: Declare gl_WorkGroupSize constant with [[maybe_unused]]. 2019-03-28 10:54:18 +01:00
read-write-only.comp Declare read-only SSBOs as const device in MSL. 2018-05-25 10:14:05 +02:00
rmw-matrix.comp Do not use RMW rewrite for matrices. 2018-05-04 10:35:56 +02:00
rmw-opt.comp Enhancements to MSL compute and entry point naming. 2017-11-05 21:34:42 -05:00
shared-array-of-arrays.comp MSL: Declare gl_WorkGroupSize constant with [[maybe_unused]]. 2019-03-28 10:54:18 +01:00
shared.comp MSL: Declare gl_WorkGroupSize constant with [[maybe_unused]]. 2019-03-28 10:54:18 +01:00
spec-constant-op-member-array.comp Update to latest glslang/SPIRV-Tools. 2019-01-30 13:41:57 +01:00
spec-constant-work-group-size.comp MSL: Declare gl_WorkGroupSize constant with [[maybe_unused]]. 2019-03-28 10:54:18 +01:00
storage-buffer-std140-vector-array.comp Add basic test for std140 small vector arrays. 2019-01-17 11:29:09 +01:00
struct-layout.comp Declare read-only SSBOs as const device in MSL. 2018-05-25 10:14:05 +02:00
struct-nested.comp Rewrite how IDs are iterated over. 2019-01-10 12:52:56 +01:00
struct-packing.comp MSL: Use correct size for structs. 2019-01-28 15:20:30 +01:00
torture-loop.comp Declare read-only SSBOs as const device in MSL. 2018-05-25 10:14:05 +02:00
type-alias.comp Rewrite how IDs are iterated over. 2019-01-10 12:52:56 +01:00
udiv.comp Use declared binding in SPIR-V as a fallback for explicit MSL binds. 2018-04-04 12:25:11 +02:00
writable-ssbo.comp CompilerMSL map many GLSL functions to MSL functions. 2017-05-19 18:14:08 -04:00