[Toybox] [PATCH] ping: print ttl

Rob Landley rob at landley.net
Tue Mar 3 09:50:07 PST 2020


On 3/2/20 7:00 PM, enh wrote:
>> LP64 is a standard introduced during the 32->64 bit transition somewhere around
>> Y2 that says sizeof(char) = 1, sizeof(short) = 2, sizeof(int) = 3, and
> 
> or sometimes 4. usually 4. actually, always 4. :-)

Actual, literal typo.

>> sizeof(long) == sizeof(pointer), and sizeof(long long) is "at least" 64 bits (in
>> practice always exactly 8 bytes, but they should _specify_).
>>
>> Linux, BSD, MacOSX, iOS, and Android all adhere to this standard. Windows does
>> _not_ (they went with LLP64 instead) for insane legacy reasons described... darn
>> it, the downside of discussing 20 year old things is all the pointers moved. I
>> should update the links on the design.html page, but here's Microsoft's insane
>> legacy reasons for going with LLP64 for the Win64 API:
>>
>>   https://devblogs.microsoft.com/oldnewthing/20050131-00/?p=36563
> 
> huh. i see what he's saying, but i wouldn't have made that decision
> myself. still, that's better than my previously-assumed reason of
> "just to be different".

See our earlier conversation on "this is why people give the exact same talk to
10 different audiences" (ala https://landley.net/notes-2017.html#20-12-2017). I
did fairly extensive research when deciding to rely upon LP64 way back when,
wrote documentation with links to primary sources, and assumed everybody else
then knew everything I did and that if I _repeat_ it I'm being annoying.

But no...

The context within which Microsoft made its API compatibility decisions is
actually fascinating and there's an excellent writeup of the behind-the-scenes
politics from somebody who used to _work_ at Microsoft here:

  https://www.joelonsoftware.com/2004/06/13/how-microsoft-lost-the-api-war/

And the context I read _that_ article in was after reading:


https://web.archive.org/web/19991013145536/http://pbs.org/cringely/pulpit/pulpit19990826.html

Which explained a lot to me at the time. I'm pretty sure I did a Motley Fool
article mentioning it. (I had a habit of linking to him, ala
https://www.fool.com/archive/portfolios/rulemaker/2000/10/05/intel-spreads-out.aspx
because his work is what got me interested in computer history in the first
place, I even had triumph of the nerds ala
https://www.youtube.com/watch?v=cpcFfNyoUwA on VHS.)

Rob

P.S. By "annoying", I mean turning into
https://web.archive.org/web/20080306202828/http://www.homeonthestrange.com/view.php?ID=28
at the drop of a hat...



More information about the Toybox mailing list