Computer Languages
|
The SHIFT instruction provides a logical shift of one or more places to the right, or to the left, of a string of binary digits. |
![]() | |||
In the SHR instruction the least significant bit (the furthest to the right) is moved into a separate place as a carry bit. The empty space on the extreme left is filled by a 0. The syntax differs
depending on the particular micro-processor the program is going
to run under.
In the example code above, the result
would be that AX would store the binary value 01011011. |