The instruction set also includes these bit manipulation instructions:
Instruction | Explanation | |
|---|---|---|
Opcode | Operand | |
|
| BitwiseAND operation of the contents ofACC with the operand |
|
| Bitwise AND operation of the contents of ACC with the contents of <address> |
|
| Bitwise XOR operation of the contents ofACC with the operand |
|
| Bitwise XOR operation of the contents of ACC with the contents of <address> |
|
| Bitwise OR operation of the contents ofACC with the operand |
|
| Bitwise OR operation of the contents of ACC with the contents of <address> |
|
| Bits in ACC are shifted logically n places to the left. Zeros are introduced on the right-hand end |
|
| Bits in ACC are shifted logically n places to the right. Zeros are introduced on the left-hand end |
<address> can be an absolute or a symbolic address | ||
The current content of the ACC is shown:
ACC | 1 | 0 | 0 | 1 | 1 | 0 | 1 | 0 |
|---|
The table has three sets of instructions. The binary number 10011010 is reloaded into the ACC before each set of instructions is run.
Complete the table by writing the content of the ACC after each set of instructions has run.
Instructions | ACC content | |
|---|---|---|
1 |
| |
2 |
| |
3 |
|
(3)
(ii) Explain how bit manipulation can be used to test whether the binary number stored in the ACC represents an odd denary number.
Write the bit manipulation instruction that will be used.
(3)
Did this page help you?