Proof: Pc 12
Let's prove the following theorem:
if the following are true:
- instruction #4 is
addi dst=4 src=4 imm=1
- the PC at time 12 = 4
then the PC at time 13 = 5
Proof:
Given
1 | instruction #4 is addi dst=4 src=4 imm=1 |
---|---|
2 | the PC at time 12 = 4 |
# | Claim | Reason |
---|---|---|
1 | the PC at time (12 + 1) = 4 + 1 | if instruction #4 is addi dst=4 src=4 imm=1 and the PC at time 12 = 4, then the PC at time (12 + 1) = 4 + 1 |
2 | 12 + 1 = 13 | 12 + 1 = 13 |
3 | 4 + 1 = 5 | 4 + 1 = 5 |
4 | the PC at time (12 + 1) = the PC at time 13 | if 12 + 1 = 13, then the PC at time (12 + 1) = the PC at time 13 |
5 | the PC at time 13 = 5 | if the PC at time (12 + 1) = 4 + 1 and the PC at time (12 + 1) = the PC at time 13 and 4 + 1 = 5, then the PC at time 13 = 5 |
Comments
Please log in to add comments