Skip to content

Commit

Permalink
fix(codegen): add herf function definition
Browse files Browse the repository at this point in the history
  • Loading branch information
kongroo committed Aug 27, 2020
1 parent c958bc1 commit 505421e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/target/source/literal/cuda_half_t.h
Original file line number Diff line number Diff line change
Expand Up @@ -308,6 +308,10 @@ static inline __device__ __host__ half htanh(half x) {
float result = tanhf(tmp_x);
return __float2half(result);
}
static inline __device__ __host__ half herf(half x) {
return __float2half(erf(__half2float(x)));
}
#endif
)";

Expand Down

0 comments on commit 505421e

Please sign in to comment.