Chris0, thanks so much for chiming in.
This part I don't get. My reasoning is that it shouldn't matter how big a processor/data bus/whatever is- the information for True/False can be easily held in single bit, so we all really need is one byte (as I understand that any data type has to have some prefix to identify that it is a so and so data type, but since we have 7 bits, we can use that to prefix this as a boolean).
This is quite interesting, but I'm afraid I still don't understand two things:
1) How is N bit significant in dictating whether a value is False or True? if I read you right, Z bit is what determines falsehood?
2) I'm not sure exactly where Z bit is, but assuming on a 32-bit x86 (Little endian), it would be on the 2nd bit next to the negative bit:
But I can set the value 1, represented as:
which would evaluate to 1, and True. But value 2, which still evaluates to True, doesn't toggle neither Z bit nor N bit at all?
Or am I not understanding something here?
BTW, I do agree with the logic of making True simply NOT False, rather fixing it to a constant, which would cause problem with portability.
As an aside, if Boolean storage capacity changes in the future it’s not likely to get smaller, rather, it may shift to 32 or 64 bits.
Both truth and falsehood are based on the in register result of the last machine operation as expressed in the Zero bit (not the N bit) of the condition codes.
This part I don't get. My reasoning is that it shouldn't matter how big a processor/data bus/whatever is- the information for True/False can be easily held in single bit, so we all really need is one byte (as I understand that any data type has to have some prefix to identify that it is a so and so data type, but since we have 7 bits, we can use that to prefix this as a boolean).
There is a fundamental difference between that which is not Zero and that which is Negative.
...
This equation of the Z bit to false enforces the logic of both false and true across programming platforms.
The Z bit is equal to false and the logical NOT of false is true.
This is quite interesting, but I'm afraid I still don't understand two things:
1) How is N bit significant in dictating whether a value is False or True? if I read you right, Z bit is what determines falsehood?
2) I'm not sure exactly where Z bit is, but assuming on a 32-bit x86 (Little endian), it would be on the 2nd bit next to the negative bit:
Code:
0[color=red]0[/color]000000 00000000 00000000 00000000
But I can set the value 1, represented as:
Code:
01000000 00000000 00000000 00000000
Code:
00100000 00000000 00000000 00000000
Or am I not understanding something here?
BTW, I do agree with the logic of making True simply NOT False, rather fixing it to a constant, which would cause problem with portability.
Last edited: