127.0 0.1 loopback6/22/2023 ![]() ![]() ![]() Imagine the networking program looks like this in pseudocode: if (value = 0) doLocal() Īlthough it depends on the chip, in those days most chips could encode these tests with 2 words, 3 words and 3 words respectively (total 8 words) and further those particular tests were all likely to execute in 1 clock cycle each. ![]() Merely loading the value 0 into a register will usually set a zero flag on the chip. Similarly, incrementing 255 will cause unsigned overflow. 127 is the highest signed 8 bit integer, so incrementing it by 1 will cause a signed overflow. The values 0, 127 and 255 are special in 8 bit assembly and machine language programming because there are "tricks" you can use to test for these values and branch to different code using smaller instructions that execute faster than for other integers. The designers of the Internet really knew how the hardware worked, and they designed with low level implementation in mind. It might have made more sense to choose 1.0.0.0 for loopback but that was already given to BBN Packet Radio Network. I know this doesn't answer the question, but this is as far back as I could dig. 0 was used for pointing to a specific host, so that left 127 for loopback. Earliest mention I can find regarding 127's assignment as loopback is November 1986 RFC 990 authored by Reynolds and Postel:Įven as early as September 1981 RFC 790, 0 and 127 were already reserved:Ġ and 127 were the only reserved Class A networks by 1981. ![]()
0 Comments
Leave a Reply. |