Skip to content

Commit 6505fc2

Browse files
committed
Hip: Supress transformation warning in softmax.cu, loops with bounds not known at compiletime indeed can not be unrolled.
1 parent cae9fb4 commit 6505fc2

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

ggml/src/ggml-cuda/softmax.cu

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ __device__ float __forceinline__ t2f32<half>(half val) {
1313
return __half2float(val);
1414
}
1515

16+
#pragma clang diagnostic push
17+
#pragma clang diagnostic ignored "-Wpass-failed"
1618
template <bool use_shared, int ncols_template, int block_size_template, typename T>
1719
static __global__ void soft_max_f32(
1820
const float * x, const T * mask, float * dst, const int ncols_par, const int nrows_y,
@@ -118,6 +120,7 @@ static __global__ void soft_max_f32(
118120
dst[col] = vals[col] * inv_sum;
119121
}
120122
}
123+
#pragma clang diagnostic pop
121124

122125
static __global__ void soft_max_back_f32(
123126
const float * grad, const float * dstf, float * dst, const int ncols, const float scale) {

0 commit comments

Comments
 (0)