From 3892763e4e7ed99c53560e004a624e53d3226bb7 Mon Sep 17 00:00:00 2001 From: Jan Wassenberg Date: Thu, 2 Apr 2026 04:19:16 -0700 Subject: [PATCH] Use HWY_MEMBER_VAR_MAYBE_UNUSED for members PiperOrigin-RevId: 893428331 --- ops/matmul.h | 2 +- util/basics.h | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/ops/matmul.h b/ops/matmul.h index 85deb624..0f3d2866 100644 --- a/ops/matmul.h +++ b/ops/matmul.h @@ -663,7 +663,7 @@ struct MatMulEnv { MMKeys keys; std::vector per_key; // Prevents false sharing. - HWY_MAYBE_UNUSED uint8_t + HWY_MEMBER_VAR_MAYBE_UNUSED uint8_t padding[HWY_ALIGNMENT - sizeof(MMKeys) - sizeof(per_key)]; }; std::vector per_cluster; diff --git a/util/basics.h b/util/basics.h index f4423a1b..bfab3f89 100644 --- a/util/basics.h +++ b/util/basics.h @@ -198,7 +198,8 @@ class RngStream { uint64_t stream_ = 0; // immutable after ctor uint64_t counter_ = 0; // Prevent false sharing if used by multiple threads. - HWY_MAYBE_UNUSED uint8_t padding_[HWY_ALIGNMENT - 16 - sizeof(engine_)]; + HWY_MEMBER_VAR_MAYBE_UNUSED uint8_t + padding_[HWY_ALIGNMENT - 16 - sizeof(engine_)]; }; } // namespace gcpp