If I start with integer 1 and repeatedly
LSL In the value register, overflow integer once, what is the desired behavior?
On the next LSL, the program should:
- Crash
- Set R0 back 1
- Something else ? V6-M reference book section A2.2.1,
"integer arithmetic", Subsection "to rotate the shift and operation":
(B), each bit of bitsing is omitted by a specific number of bits. The zero is transferred to the right end of the bitstring. The bits transferred from the left side of bitsings are discarded, except that the last bit can be prepared as a carry output.
So it becomes 0 and the carry flag is set.
No comments:
Post a Comment