[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#17505: Interface inconsistency, use of intelligent defaults.
From: |
Ruediger Meier |
Subject: |
bug#17505: Interface inconsistency, use of intelligent defaults. |
Date: |
Fri, 16 May 2014 11:15:06 +0200 |
User-agent: |
KMail/1.9.10 |
On Friday 16 May 2014, Linda Walsh wrote:
> On programs that allow input and output by specifying computer-base2
> powers of K/M/G OR decimal based powers of 10,
>
> If the input units are specified in in powers of 2 then the output
> should be given in the same units.
>
> Example:
>
> dd if=/dev/zero of=/dev/null bs=256M count=2
> ... So 512MB, total -... but what do I see:
> 536870912 bytes (537 MB) copied, 0.225718 s, 2.4 GB/s
>
> Clearly 256*2 != 537.
>
> At the very least this violates the design principle of 'least
> surprise' and/or 'least astonishment'.
Yes, I also had to think again and again about this. Often being unsure
whether it did what I want. Actually I would like to have a global
switch or env to turn off all powers of 10 based output and input.
Power of 10 is IMO only useful for the human reader to quickly
understand the magnitude of byte count.
For example these both lines are equally easy to read
536870912 bytes (537 MB):
536,870,912 bytes
But power of 10 is annoying as well as thousands separators. The most
useful and least confusing would be this one:
536870912 bytes (256 M)
For the last line it's easy mental arithmetic to "calculate" that this
is 537 MB. But I doubt that anybody wants to know this at all.
cu,
Rudi