Talk:Bit numbering

The least significant bit and the most significant bit
The LSb and MSb pages shoud not be merged to "bit numbering", because these are obviously deeper terms. The bit numbering is defined through MSb and LSb, You cannot do it without these basic notions. Bit numbering is a convention, while LSb and MSb are mathematical reality. The LSb is the bit in the "machine word", that has the least weight, so this is the bit with weight 1 or 20. The MSb is the bit in that has the biggest weight, so in case of a 32bit word, this is the bit with the weight of 231 in case of unsigned numbers, or -(231) in case of signed numbers.

Why do You make such a terrible mess??? Wiki shoud make terms clear!!!

--Pteryx (talk) 10:23, 24 October 2023 (UTC)

Include some math
The article says "This bit numbering method has the advantage that for any unsigned integral data type the value of the number can be calculated by using exponentiation with the bit number and a base of 2." For easier reading, I propose to add a formula here: $$ \sum_{i=0}^{w-1} bit(i) \cdot 2^i $$  where $$bit(i)$$ denotes the value of the bit with number $$i$$ and $$w$$ denotes the number of bits in total.


 * I see you already added it, which should be fine. Maybe there is some standard notation? Perhaps I might copy the notation used in Two's complement and other articles: N for the number of bits, and ai for each bit (also seen in Positional notation). Vadmium (talk, contribs) 09:51, 4 December 2012 (UTC).

conflict with another article
The article about least significant bit says: "Although a few CPU manufacturers assign bit numbers the opposite way (which is not the same as different endianness)..." while in this article, Bit numbering is compared with endianness in the first sentence: "In computing, bit numbering (or sometimes bit endianness)...". maybe someone could review it? — Preceding unsigned comment added by 84.24.135.51 (talk) 15:52, 13 August 2015 (UTC)


 * I agree that MSB0 bit numbering is consistent with big-endian, and LSB0 with little endian. As most machines don't have bit addressable hardware, some people don't seem to like the big/little endian terms, but they seem right to me. Gah4 (talk) 08:20, 12 November 2015 (UTC)


 * This article mentions the RFC convention for numbering bits, which seems to be more about numbering bits for serial network transmission than about identifying the bits within the word(s) of specific computing datatypes. — Loadmaster (talk) 22:20, 13 November 2015 (UTC)

Should there be MOS:BITNUM ?
Is there, or should there be, an MOS for bit numbering? I changed the PDP-10 page to use MSB0 numbering, as DEC used in its PDP-10 documentation. Someone changed it back, with a note that DEC used a different convention. It seems to me that using the appropriate convention as the OEM uses would be appropriate, and encyclopedic, but is there a MOS on this? Gah4 (talk) 08:25, 12 November 2015 (UTC)


 * Personally I think we should follow the respective manufacturers' and models' documentation. Everything on WP should be traceable to good references, and what the maker of a thing calls something is a "horse's mouth" reference, overriding what other manufacturers call similar things. Since there will be inconsistencies (even within mfrs, e.g. PDP-10 vs. PDP-11, VAX, and Alpha, which all used LSB0) all bit-layout diagrams should include not only bit numbers but also "LSB" and/or "MSB" designations. Jeh (talk) 00:05, 14 November 2015 (UTC)


 * Is there a process for getting an actual MOS on something? It is nice to have something to point to. Gah4 (talk) 00:36, 14 November 2015 (UTC)


 * For now we do have WP:V and WP:RS. afaik you just open a discussion on a MOS talk page. I'm not sure where in MOS this would go. Maybe near WP:COMPUNITS? Jeh (talk) 00:51, 14 November 2015 (UTC)


 * Seems to also be in Talk:PDP-11 architecture, but I think WP:V is important, too. thanks. Gah4 (talk) 01:08, 14 November 2015 (UTC)

External links modified
Hello fellow Wikipedians,

I have just modified 1 one external link on Bit numbering. Please take a moment to review my edit. If you have any questions, or need the bot to ignore the links, or the page altogether, please visit this simple FaQ for additional information. I made the following changes:
 * Added archive https://web.archive.org/web/20041029235810/http://developer.apple.com:80/documentation/mac/OSUtilities/OSUtilities-39.html to http://developer.apple.com/documentation/Mac/OSUtilities/OSUtilities-39.html

When you have finished reviewing my changes, please set the checked parameter below to true or failed to let others know (documentation at ).

Cheers.— InternetArchiveBot  (Report bug) 09:01, 3 November 2016 (UTC)

Regarding the note: The article is full of inaccuracies and mixes endianness with bit numbering. The article also implies that bit numbering is a property of the CPU
There is a note, recently added, saying: ''The article is full of inaccuracies and mixes endianness with bit numbering. The article also implies that bit numbering is a property of the CPU''. Manufacturer documentation most often uses a specific bit numbering. You will get people very confused if you use a different bit numbering. Yes it is inconvenient, but just as much as byte endianness. MSB 0 bit numbering is consistent with big-endian byte numbering, though most processors don't have bit addressing. I believe IBM uses MSB 0 for S/360 and successors specifically because it is consistent with big-endian addressing. This gets more interesting with 64 bit Z/Architecture, where 32 bit registers are the low half of 64 bit registers, with bit numbering 32 (MSB) to 63 (LSB). Gah4 (talk) 17:06, 15 May 2019 (UTC)

CPU bit numbering
I believe you are talking about bit numbering conventions in CPU documentation. This is not a property of the CPU. Some specs use MSB 0 and others LSB 0 when you are implementing the spec you may need to worry about endianness, but there is no CPU bit numbering that you need to worry about. This is not the same as endianness. That is a property of the CPU and when serializing structures endianness is usually part of the spec. You do need to worry about endianness when using a CPU. Bcr33d (talk) 21:14, 28 May 2019 (UTC)


 * It depends on what the meaning of use is. First, some CPUs have bit manipulation instructions which have a bit number argument.  If by use, you mean software, then as you say usually not. Though if you are told, or you software comment says set bit 3, then you better set the right bit. On the other hand, at the hardware level bit numbering is significant. If you interface to a microprocessor bus, you better do it using the documented bit numbering. I once knew someone to build an 8251 (USART) board for an Apple II. When he tried it out, it didn't work, and finally the problem came from the fact that one numbered the bits one way, and the other one, the other way.  (I don't remember now which one was which.)   In most cases, a CPU is not separate from its documentation. But yes, for processor independent software, in high-level languages, you normally don't need to know about bit numbering.  For assembly programming, or using processor-specific features, (often enough done in C), you do. Gah4 (talk) 02:19, 29 May 2019 (UTC)

This is Bit numbering? So what is the first bit?
This page is missing the main information regarding its name Bit numbering, because there is no information about about first bit, second bit, etc. It would be nice to know the consensus on the matter (with citations).
 * In the case of a parallel bus, there is no first bit. For serial data, there is a first and last bit. Bits are normally numbered starting with 0, such that bit 0 might be the first or last bit. Gah4 (talk) 22:21, 27 September 2021 (UTC)
 * In the case of a parallel bus, there is no first bit. For serial data, there is a first and last bit. Bits are normally numbered starting with 0, such that bit 0 might be the first or last bit. Gah4 (talk) 22:21, 27 September 2021 (UTC)