diff options
Diffstat (limited to 'apps/codecs/libffmpegFLAC/golomb.h')
-rw-r--r-- | apps/codecs/libffmpegFLAC/golomb.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/apps/codecs/libffmpegFLAC/golomb.h b/apps/codecs/libffmpegFLAC/golomb.h index 659ecc1579..11753fc4bb 100644 --- a/apps/codecs/libffmpegFLAC/golomb.h +++ b/apps/codecs/libffmpegFLAC/golomb.h @@ -21,6 +21,13 @@ #include <limits.h> +#if (defined(CPU_ARM) && (ARM_ARCH > 4)) +static inline int av_log2(uint32_t v) +{ + return 31 - __builtin_clz(v); +} +#else + /* From libavutil/common.h */ extern const uint8_t ff_log2_tab[256]; @@ -41,6 +48,7 @@ static inline int av_log2(unsigned int v) return n; } +#endif /** * @file golomb.h |