So, I found this very interesting to read. I created an empty file, a la the original true, named truth and placed it at the beginning of my $PATH. $ time truth real 0m0.002s user 0m0.000s sys 0m0.003s I then realized that since true is a builtin, I'd need to call the true binary with its full path. I'd hate to give one an unfair advantage by having to search the path vs being called by name. So.... $ time /usr/bin/t…
I just repeated your test, but got opposite results: $ time /usr/bin/true real 0m0.003s user 0m0.001s sys 0m0.002s $ time /usr/bin/truth real 0m0.001s user 0m0.000s sys 0m0.001s I can't imagine for the life of me how an empty file could perform worse than an actual binary, but there's gotta be a reason.
Code Inflation [pdf]
21–30 of 30 posts
Re: Code Inflation [pdf]
#22Re: Code Inflation [pdf]
#23Here's a link to the coreutils source for true if anyone's interested: http://git.savannah.gnu.org/cgit/coreutils.git/tree/src/true... I think the argument can be made that command lines tools shouldn't provide versioning and help text at all - leave it up to the manual pages.
Re: Code Inflation [pdf]
#24Not really a meaningful explanation. Nor is the example.
Re: Code Inflation [pdf]
#25Re: Code Inflation [pdf]
#26Those who don't see anything unusual or wasteful about an 8KB+ executable whose only action is to exit and return a value are recommended to watch this demo generated in realtime by a 4KB executable: http://www.youtube.com/watch?v=jB0vBmiTr6o There's more here: http://www.pouet.net/prodlist.php?type[]=4k The demoscene is basically the exact opposite of mainstream software culture, and although it's focused on multime…
Re: Code Inflation [pdf]
#27 "Software tends to grow over time, whether or not there’s a need for it"
that it highlights, until it contained an introduction, a First Law, a table of data abou the Unix "true" command, the same data as a figure, a logarithmic chart of bash, and a foray into "dark code" (which can be present at any size.)Re: Code Inflation [pdf]
#28So, I found this very interesting to read. I created an empty file, a la the original true, named truth and placed it at the beginning of my $PATH. $ time truth real 0m0.002s user 0m0.000s sys 0m0.003s I then realized that since true is a builtin, I'd need to call the true binary with its full path. I'd hate to give one an unfair advantage by having to search the path vs being called by name. So.... $ time /usr/bin/t…
I just repeated your test, but got opposite results: $ time /usr/bin/true real 0m0.003s user 0m0.001s sys 0m0.002s $ time /usr/bin/truth real 0m0.001s user 0m0.000s sys 0m0.001s I can't imagine for the life of me how an empty file could perform worse than an actual binary, but there's gotta be a reason.
https://www.sciencebasedmedicine.org/psychology-journal-bans...
The default p is p = 0.5, so I have no trouble accepting both your conclusion and your parent's :)
seriously though, this is why we use significance testing in real fields, like computer science...
Re: Code Inflation [pdf]
#29Earlier quoted context omitted.
I just repeated your test, but got opposite results: $ time /usr/bin/true real 0m0.003s user 0m0.001s sys 0m0.002s $ time /usr/bin/truth real 0m0.001s user 0m0.000s sys 0m0.001s I can't imagine for the life of me how an empty file could perform worse than an actual binary, but there's gotta be a reason.
If you're relying on an empty binary, or exit 0; instead of an actual binary you have to execute a shell process to evaluate it. The binary doesn't need to load a shell, it can just do a bit of setup, then make a single exit 0 system call.
Re: Code Inflation [pdf]
#30Earlier quoted context omitted.
I just repeated your test, but got opposite results: $ time /usr/bin/true real 0m0.003s user 0m0.001s sys 0m0.002s $ time /usr/bin/truth real 0m0.001s user 0m0.000s sys 0m0.001s I can't imagine for the life of me how an empty file could perform worse than an actual binary, but there's gotta be a reason.
this is what happens when we aren't allowed to use p values anymore :) https://www.sciencebasedmedicine.org/psychology-journal-bans... The default p is p = 0.5, so I have no trouble accepting both your conclusion and your parent's :) seriously though, this is why we use significance testing in real fields, like computer science...