blob: 4968408c4fe00f9d93bbfb94359f2b384c93982e [file] [log] [blame]
#include <metal_stdlib>
using namespace metal;
int tint_div(int lhs, int rhs) {
return (lhs / select(rhs, 1, bool((rhs == 0) | bool((lhs == (-2147483647 - 1)) & (rhs == -1)))));
}
kernel void f() {
int a = 1;
int b = 0;
int const r = tint_div(a, b);
return;
}