From 91940e84b139db8d098e7182ae836595c677b115 Mon Sep 17 00:00:00 2001 From: escherstair Date: Tue, 4 Aug 2020 14:38:45 +0200 Subject: [PATCH] fallback to the naive version for CE6 --- include/rapidjson/internal/clzll.h | 23 +---------------------- 1 file changed, 1 insertion(+), 22 deletions(-) diff --git a/include/rapidjson/internal/clzll.h b/include/rapidjson/internal/clzll.h index f43e6a7..73a54f6 100644 --- a/include/rapidjson/internal/clzll.h +++ b/include/rapidjson/internal/clzll.h @@ -34,31 +34,10 @@ inline uint32_t clzll(uint64_t x) { // infinite loop in the software implementation. RAPIDJSON_ASSERT(x != 0); -#if defined(_MSC_VER) +#if defined(_MSC_VER) && !defined(UNDER_CE) unsigned long r = 0; #if defined(_WIN64) _BitScanReverse64(&r, x); -#elif defined(UNDER_CE) - // Scan the high 32 bits. - uint32_t high = static_cast(x >> 32); - if (high != 0) - { - unsigned long index = 31; - while((high & (1U<(x & 0xFFFFFFFF); - unsigned long index = 31; - while((low & (1U<(x >> 32)))