4 ms·
> Unfortunately this is less suitable for integers larger than 64 bits, because then you run out of bits in the first byte. Just spitballing here but is it nec
by klabb3 2y ago
> Unfortunately this is less suitable for integers larger than 64 bits, because then you run out of bits in the first byte.
Just spitballing here but is it necessary to support every increment of octets? Do we really need a 7 octet/56bit width for instance? Instead couldn’t we just allow widths of log2(n_octets)? An int64 would need 2 bits of length info (8, 16, 32, 64). Or maybe I’m thinking wrong cause not all bits are can be used.
> its efficiency really depends on the expected input distribution
Right. But everything else in computers is rounded to the nearest power of 2, so maybe it works here too haha.
- lifthrasiir 2y ago> Just spitballing here but is it necessary to support every increment of octets? Indeed CBOR does this, and that's another reason you should put continuation bits to the first byte: it allows for much greater control.