Skip to content

Instantly share code, notes, and snippets.



Created Jul 8, 2019
What would you like to do?
__global__ void maxKernel(
const int n,
const float eps,
const float* x,
float* y)
for (int i = blockIdx.x * blockDim.x + threadIdx.x;
i < n; i += gridDim.x * blockDim.x)
y[i] = fmaxf(x[i], eps);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.