From 26df6e5e7b3e6aa2448c2329e10d37edae3f8564 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Mon, 10 Sep 2018 19:12:43 -0400 Subject: [PATCH] emit_x64_vector: Correct static asserts for < 64-bit type checks in saturated accumulate fallbacks I had initially meant to use BitSize() here, not sizeof() --- src/backend/x64/emit_x64_vector.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/backend/x64/emit_x64_vector.cpp b/src/backend/x64/emit_x64_vector.cpp index 50a86519..149c4412 100644 --- a/src/backend/x64/emit_x64_vector.cpp +++ b/src/backend/x64/emit_x64_vector.cpp @@ -2815,7 +2815,7 @@ void EmitX64::EmitVectorSignedSaturatedAbs64(EmitContext& ctx, IR::Inst* inst) { template static bool EmitSignedSaturatedAccumulateUnsigned(VectorArray& result, const VectorArray& lhs, const VectorArray& rhs) { static_assert(std::is_signed_v, "T must be signed."); - static_assert(sizeof(T) < 64, "T must be less than 64 bits in size."); + static_assert(Common::BitSize() < 64, "T must be less than 64 bits in size."); bool qc_flag = false; @@ -3476,7 +3476,7 @@ void EmitX64::EmitVectorUnsignedRecipSqrtEstimate(EmitContext& ctx, IR::Inst* in template > bool EmitVectorUnsignedSaturatedAccumulateSigned(VectorArray& result, const VectorArray& lhs, const VectorArray& rhs) { static_assert(std::is_signed_v, "T must be signed."); - static_assert(sizeof(T) < 64, "T must be less than 64 bits in size."); + static_assert(Common::BitSize() < 64, "T must be less than 64 bits in size."); bool qc_flag = false;