dawn-cmake/test/bug/tint/926.wgsl.expected.msl

18 lines
570 B
Plaintext
Raw Normal View History

#include <metal_stdlib>
using namespace metal;
struct DrawIndirectArgs {
/* 0x0000 */ atomic_uint vertexCount;
};
void computeMain_inner(device DrawIndirectArgs& drawOut, uint3 global_id, thread uint* const tint_symbol) {
uint const firstVertex = atomic_fetch_add_explicit(&(drawOut.vertexCount), *(tint_symbol), memory_order_relaxed);
}
kernel void computeMain(uint3 global_id [[thread_position_in_grid]], device DrawIndirectArgs& drawOut [[buffer(0)]]) {
thread uint tint_symbol_1 = 0u;
computeMain_inner(drawOut, global_id, &(tint_symbol_1));
return;
}