diff options
author | wm4 <wm4@nowhere> | 2019-10-31 13:16:58 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2019-10-31 13:16:58 +0100 |
commit | 7510ed6f684041db643c051cb17b13abf663b3b2 (patch) | |
tree | e99355085b8f9ccb13d883d08dc22dca1a58ff50 /player | |
parent | 6d92e5550203b04b7254eb8ffe31734e57070d79 (diff) | |
download | mpv-7510ed6f684041db643c051cb17b13abf663b3b2.tar.bz2 mpv-7510ed6f684041db643c051cb17b13abf663b3b2.tar.xz |
common: add mp_log2()
To be used in the next commit.
According to compiler explorer, __builtin_clz is very widely available,
and it barely makes sense to provide a fallback. clang also eats this
(and identifies at least as GCC 4). Actually, there's doubt that a fast
log2 implementation is needed at all (I guess UTF-8 parsing needs it,
but something UTF-8-specific would probably make it faster than using
log2). So the fallback is just something naive.
Diffstat (limited to 'player')
0 files changed, 0 insertions, 0 deletions