aboutsummaryrefslogtreecommitdiffstats
path: root/src/mutils.ads
blob: 1a3afd4f116090926bb19830922316df0e132aba (plain)
1
2
3
4
5
6
7
8
9
10
with Types; use Types;

package Mutils is
   --  Return the ceiling log2 of V.
   --  Returns 0 for 0.
   function Clog2 (V : Uns64) return Integer;

   --  Return True IFF V is 0 or a power of 2.
   function Is_Power2 (V : Uns64) return Boolean;
end Mutils;