Skip to content

Commit

Permalink
sycl : fix powf call in device code (#8368)
Browse files Browse the repository at this point in the history
  • Loading branch information
Alcpz authored Jul 8, 2024
1 parent 3f2d538 commit 2ec846d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ggml/src/ggml-sycl/rope.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ static void rope_norm(
const int i = row*ne0 + i0;
const int i2 = row/p_delta_rows;

const float theta_base = pos[i2]*powf(theta_scale, i0/2.0f);
const float theta_base = pos[i2] * sycl::pow(theta_scale, i0 / 2.0f);

const float freq_factor = has_ff ? freq_factors[i0/2] : 1.0f;

Expand Down Expand Up @@ -98,7 +98,7 @@ static void rope_neox(
const int i = row*ne0 + i0/2;
const int i2 = row/p_delta_rows;

const float theta_base = pos[i2]*powf(theta_scale, i0/2.0f);
const float theta_base = pos[i2] * sycl::pow(theta_scale, i0 / 2.0f);

const float freq_factor = has_ff ? freq_factors[i0/2] : 1.0f;

Expand Down

0 comments on commit 2ec846d

Please sign in to comment.