#include <metal_stdlib>

using namespace metal;
void textureStore_cb3b0b(texture3d<int, access::write> tint_symbol) {
  uint3 arg_1 = uint3(1u);
  int4 arg_2 = int4(1);
  tint_symbol.write(arg_2, uint3(arg_1));
}

fragment void fragment_main(texture3d<int, access::write> tint_symbol_1 [[texture(0)]]) {
  textureStore_cb3b0b(tint_symbol_1);
  return;
}

kernel void compute_main(texture3d<int, access::write> tint_symbol_2 [[texture(0)]]) {
  textureStore_cb3b0b(tint_symbol_2);
  return;
}

