#include <metal_stdlib>

using namespace metal;
int tint_extract_bits(int v, uint offset, uint count) {
  uint const s = min(offset, 32u);
  uint const e = min(32u, (s + count));
  return extract_bits(v, s, (e - s));
}

void f_1() {
  int v = 0;
  uint offset_1 = 0u;
  uint count = 0u;
  int const x_14 = tint_extract_bits(v, offset_1, count);
  return;
}

kernel void f() {
  f_1();
  return;
}

