• From smallest to biggest:

    Bits (basic unit)

    Bytes (8:1 reduction)

    Words (4:1 reduction)

    KiB (32:1 reduction)

    MiB (1024:1)

    GiB (1024:1)

    TiB (1024:1)

    PiB (1024:1)

    A normal amount of porn (237:1)

    • @barsoap
      link
      14
      edit-2
      2 months ago

      All definitely not metric as metric uses steps of 1000 (and there’s also 10 and 100 and 1/10th and 1/100th but that doesn’t extend to 10000 and 1/10000th).

      The KiB, MiB, etc, the 2^10 scale is called binary prefixes (as opposed to decimal prefixes KB, MB, etc) and standardised by the IEC.

      And while the B in KiB is always going to mean eight bits it’s not a given that a byte is actually eight bits, network people still use “octet” to disambiguate because back in the days there were plenty of architectures around with other byte sizes. “byte” simply means “smallest number of bits an operation like addition will be done in” in the context of architectures. Then you have word for two bytes, d(ouble)word for four, q(uad)word for eight, o(cto)word for 16, and presumably h(ex)word for 32 it’s already hard to find owords in the wild. Yes it’s off by one of course it’s off by one what do you expect it’s about computers. There’s also nibble for half a byte.

      EDIT: Actually that’s incorrect word is also architecture-dependent, the word/dword/qword sequence applies to architectures (like x86) which went from being 16-bit machines to now being 64 bit while keeping backwards compatibility. E.g. RISC-V uses 32-bit words, 16 bits there are a half-word.

      The bit, at least, is not under contention everyone agrees what it is. Though you can occasionally see people staring in wild disbelief and confusion at statements such as “this information can be stored in ~1.58 bits”. That number is ~ log2 3, that is, the information that fits in one trit. Such as “true, false, maybe”.

      • @notfromhere@lemmy.ml
        link
        fedilink
        32 months ago

        Great write up, glad to see mention of nibble (my favorite lol)… You forgot to mention byte order (Little/Big Endian).

      • So you’re saying my proposed imperial units depend on where you are, and who is using them, for what purpose? That just sells me on them as imperial units even more. :)

        Thank you for the details.

    • @uis
      link
      02 months ago

      Words (4:1 reduction)

      Word is imperial unit. Like one british gallon is not equal to one us gallon, one x86 word is not equal one ARM word.