• Aux@feddit.uk
      link
      fedilink
      English
      arrow-up
      1
      ·
      8 hours ago

      Usually the most effective way is to read and write the same amount of bits as the architecture of the CPU, so for 64 bit CPUs it’s 64 bits at once.

    • excral@feddit.org
      link
      fedilink
      arrow-up
      11
      ·
      1 day ago

      In terms of memory usage it’s a waste. But in terms of performance you’re absolutely correct. It’s generally far more efficient to check is a word is 0 than to check if a single bit is zero.