Skip to content
Permalink
Browse files
Merge pull request #9868 from leoetlino/constexpr-intlog2
MathUtil: Mark IntLog2 as constexpr
  • Loading branch information
JosJuice committed Jul 6, 2021
2 parents 21d7509 + b82b068 commit 02309bd
Showing 1 changed file with 1 addition and 1 deletion.
@@ -191,7 +191,7 @@ class RunningVariance
float MathFloatVectorSum(const std::vector<float>&);

// Rounds down. 0 -> undefined
inline int IntLog2(u64 val)
constexpr int IntLog2(u64 val)
{
return 63 - Common::CountLeadingZeros(val);
}

0 comments on commit 02309bd

Please sign in to comment.