diff options
author | thegeorg <thegeorg@yandex-team.com> | 2024-08-06 11:28:07 +0300 |
---|---|---|
committer | thegeorg <thegeorg@yandex-team.com> | 2024-08-06 12:50:21 +0300 |
commit | de4d7efd8871b850e3ea79164d7661e2299836b7 (patch) | |
tree | 47d8cf597b3789a807a4b1cec0a9fd66788767c2 /contrib/restricted/abseil-cpp-tstring/y_absl/numeric/internal | |
parent | e003b4c129e1381591dcb75a96bf9a970b2b47fb (diff) | |
download | ydb-de4d7efd8871b850e3ea79164d7661e2299836b7.tar.gz |
Update contrib/restricted/abseil-cpp-tstring to 20240722.0
83a5727000e16bc5a94523a0cf1cce75fa86a191
Diffstat (limited to 'contrib/restricted/abseil-cpp-tstring/y_absl/numeric/internal')
-rw-r--r-- | contrib/restricted/abseil-cpp-tstring/y_absl/numeric/internal/bits.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/contrib/restricted/abseil-cpp-tstring/y_absl/numeric/internal/bits.h b/contrib/restricted/abseil-cpp-tstring/y_absl/numeric/internal/bits.h index a19e3c6bbc..152b5005a3 100644 --- a/contrib/restricted/abseil-cpp-tstring/y_absl/numeric/internal/bits.h +++ b/contrib/restricted/abseil-cpp-tstring/y_absl/numeric/internal/bits.h @@ -167,7 +167,9 @@ CountLeadingZeroes32(uint32_t x) { Y_ABSL_ATTRIBUTE_ALWAYS_INLINE Y_ABSL_INTERNAL_CONSTEXPR_CLZ inline int CountLeadingZeroes16(uint16_t x) { -#if Y_ABSL_HAVE_BUILTIN(__builtin_clzs) +#if Y_ABSL_HAVE_BUILTIN(__builtin_clzg) + return x == 0 ? 16 : __builtin_clzg(x); +#elif Y_ABSL_HAVE_BUILTIN(__builtin_clzs) static_assert(sizeof(unsigned short) == sizeof(x), // NOLINT(runtime/int) "__builtin_clzs does not take 16-bit arg"); return x == 0 ? 16 : __builtin_clzs(x); @@ -303,7 +305,9 @@ CountTrailingZeroesNonzero64(uint64_t x) { Y_ABSL_ATTRIBUTE_ALWAYS_INLINE Y_ABSL_INTERNAL_CONSTEXPR_CTZ inline int CountTrailingZeroesNonzero16(uint16_t x) { -#if Y_ABSL_HAVE_BUILTIN(__builtin_ctzs) +#if Y_ABSL_HAVE_BUILTIN(__builtin_ctzg) + return __builtin_ctzg(x); +#elif Y_ABSL_HAVE_BUILTIN(__builtin_ctzs) static_assert(sizeof(unsigned short) == sizeof(x), // NOLINT(runtime/int) "__builtin_ctzs does not take 16-bit arg"); return __builtin_ctzs(x); |