jubatus_core  0.1.2
Jubatus: Online machine learning framework for distributed environment
Static Public Member Functions | List of all members
jubatus::core::storage::detail::bitcount_impl< T, 2 > Struct Template Reference

#include <bit_vector.hpp>

Collaboration diagram for jubatus::core::storage::detail::bitcount_impl< T, 2 >:
Collaboration graph

Static Public Member Functions

static int call (T bits)
 

Detailed Description

template<typename T>
struct jubatus::core::storage::detail::bitcount_impl< T, 2 >

Definition at line 47 of file bit_vector.hpp.

Member Function Documentation

template<typename T >
static int jubatus::core::storage::detail::bitcount_impl< T, 2 >::call ( bits)
inlinestatic

Definition at line 48 of file bit_vector.hpp.

48  {
49  bits = (bits & 0x5555U) + (bits >> 1 & 0x5555U);
50  bits = (bits & 0x3333U) + (bits >> 2 & 0x3333U);
51  bits = (bits & 0x0f0fU) + (bits >> 4 & 0x0f0fU);
52  return (bits & 0x00ffU) + (bits >> 8 & 0x00ffU);
53  }

The documentation for this struct was generated from the following file: