1. 24 May, 2012 4 commits
    • antirez's avatar
      bitop.c renamed bitops.c · 80f8028e
      antirez authored
      bitop.c contains the "Bit related string operations" so it seems more
      logical to call it bitops instead of bitop.
      This also makes it matching the name of the test (unit/bitops.tcl).
      80f8028e
    • antirez's avatar
      popcount() optimization for speed. · 343d3bd2
      antirez authored
      We run the array by 32 bit words instead of processing it byte per byte.
      If the code is compiled using GCC __builtin_popcount() builtin function
      is used instead.
      343d3bd2
    • antirez's avatar
      BITCOUNT refactoring. · dbbbe49e
      antirez authored
      The low level popualtion counting function is now separated from the
      BITCOUNT command implementation, so that the low level function can be
      further optimized and eventually used in other contexts if needed.
      dbbbe49e
    • antirez's avatar
      Bit-related string operations moved to bitop.c · 760e7765
      antirez authored
      All the general string operations are implemented in t_string.c, however
      the bit operations, while targeting the string type, are better served
      in a specific file where we have the implementations of the following
      four commands and helper functions:
      
          GETBIT
          SETBIT
          BITOP
          BITCOUNT
      
      In the future this file will probably contain more code related to
      making the BITOP and BITCOUNT operations faster.
      760e7765