#include <metal_stdlib>

using namespace metal;
float subgroupExclusiveAdd_967e38() {
  float arg_0 = 1.0f;
  float res = simd_prefix_exclusive_sum(arg_0);
  return res;
}

fragment void fragment_main(device float* tint_symbol [[buffer(0)]]) {
  *(tint_symbol) = subgroupExclusiveAdd_967e38();
  return;
}

kernel void compute_main(device float* tint_symbol_1 [[buffer(0)]]) {
  *(tint_symbol_1) = subgroupExclusiveAdd_967e38();
  return;
}

