From 4d757068c4784a18026089fd812949703bd9470a Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Tue, 6 Dec 2022 01:48:58 -0800 Subject: Avoid using a macro to wrap standard attributes --- common/alnumeric.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'common/alnumeric.h') diff --git a/common/alnumeric.h b/common/alnumeric.h index b617b363..13e61645 100644 --- a/common/alnumeric.h +++ b/common/alnumeric.h @@ -161,11 +161,11 @@ inline int float2int(float f) noexcept shift = ((conv.i>>23)&0xff) - (127+23); /* Over/underflow */ - if(shift >= 31 || shift < -23) [[alunlikely]] + if(shift >= 31 || shift < -23) [[unlikely]] return 0; mant = (conv.i&0x7fffff) | 0x800000; - if(shift < 0) [[allikely]] + if(shift < 0) [[likely]] return (mant >> -shift) * sign; return (mant << shift) * sign; @@ -198,11 +198,11 @@ inline int double2int(double d) noexcept shift = ((conv.i64 >> 52) & 0x7ff) - (1023 + 52); /* Over/underflow */ - if(shift >= 63 || shift < -52) [[alunlikely]] + if(shift >= 63 || shift < -52) [[unlikely]] return 0; mant = (conv.i64 & 0xfffffffffffff_i64) | 0x10000000000000_i64; - if(shift < 0) [[allikely]] + if(shift < 0) [[likely]] return (int)(mant >> -shift) * sign; return (int)(mant << shift) * sign; @@ -251,7 +251,7 @@ inline float fast_roundf(float f) noexcept sign = (conv.i>>31)&0x01; expo = (conv.i>>23)&0xff; - if(expo >= 150/*+23*/) [[alunlikely]] + if(expo >= 150/*+23*/) [[unlikely]] { /* An exponent (base-2) of 23 or higher is incapable of sub-integral * precision, so it's already an integral value. We don't need to worry -- cgit v1.2.3