fix: const not constexpr for SCALE

This commit is contained in:
2026-05-30 09:04:45 +00:00
parent 3da31de4c0
commit d424ccbcc1

View File

@@ -53,7 +53,7 @@ void reference_attention(
int main() {
constexpr int HD = 64;
constexpr int SK = 256; // 2 KV tiles
constexpr float SCALE = 1.0f / sqrtf((float)HD);
const float SCALE = 1.0f / sqrtf((float)HD);
// Allocate host data
bf16_t h_q[HD], h_k[SK * HD], h_v[HD * SK];