Re: implementation note for scapegoat tree
- From: Hallvard B Furuseth <h.b.furuseth@xxxxxxxxxxx>
- Date: Thu, 29 Mar 2007 20:47:55 +0200
Ben Pfaff writes:
floor_log2 (size_t x)
{
return sizeof (size_t) * CHAR_BIT - 1 - count_leading_zeros (x);
}
Wrong if size_t has padding bits.
--
Regards,
Hallvard
.
- Follow-Ups:
- Re: implementation note for scapegoat tree
- From: Ben Pfaff
- Re: implementation note for scapegoat tree
- References:
- implementation note for scapegoat tree
- From: Ben Pfaff
- implementation note for scapegoat tree
- Prev by Date: computing the moment of inertia
- Next by Date: Re: computing the moment of inertia
- Previous by thread: Re: implementation note for scapegoat tree
- Next by thread: Re: implementation note for scapegoat tree
- Index(es):