memory: Use non-bitops ctzl

A memory size of zero is invalid, and so that edge condition
does not occur.

Signed-off-by: Richard Henderson <rth@twiddle.net>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
