Skip to content

Commit

Permalink
fix comment
Browse files Browse the repository at this point in the history
  • Loading branch information
zhwesky2010 committed Jun 17, 2022
1 parent 4fad3e7 commit 23504a6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions paddle/phi/kernels/sparse/gpu/softmax_kernel.cu
Expand Up @@ -56,9 +56,9 @@ __global__ void SoftmaxGpuKernel(const IntT* x_crows,
if (idx >= row_nnz) break;

auto functor = phi::funcs::CudaExpFunctor<T>();
out_values[row_first + idx] =
functor(x_values[row_first + idx] - row_max_val);
exp_sum += functor(x_values[row_first + idx] - row_max_val);
T exp = functor(x_values[row_first + idx] - row_max_val);
exp_sum += exp;
out_values[row_first + idx] = exp;
}
T row_exp_sum = phi::funcs::warpReduceSum<T>(exp_sum, 0xFFFFFFFF);

Expand Down

0 comments on commit 23504a6

Please sign in to comment.