3 ms·
I've been in this game for a long time. BCD was a scheme to avoid the cost of binary-to-decimal conversion at display time, when processing was much more expens
by lutusp 12y ago
I've been in this game for a long time. BCD was a scheme to avoid the cost of binary-to-decimal conversion at display time, when processing was much more expensive than it is now. Obviously using binary storage of integers, you now can get the same display of integer values that you could then, but you have to convert from binary to decimal on the fly. The change is that the conversion is much easier and faster than it was then.
That means the storage differential of 100/256, i.e. the loss of bit real estate, is the reason BCD isn't used any more.
- dllthomas 12y ago"That means the storage differential of 100/256" In terms of "number of representable values", it's 100/256 to the power of the number of bytes in packed BCD rather than binary. Alternatively, with BCD you're only using about 80% of your bits. (Clarifying, more than disagreeing - up-voted).