Instructions
Memory Cells |
---|
Program Counter | Time |
---|---|
0 | 0 |
LW Computer Simulator
Quiz (1 point)
Given that:
instruction #7 is
addi dst=4 src=4 imm=1
the PC at time 13 = 7
value of cell 4 at time 13 = 1
Prove that:
value of cell 4 at time 14 = 2
The following properties may be helpful:
- 13 + 1 = 14
- 1 + 1 = 2
if the following are true:
- instruction #i is
addi dst=dst src=src imm=imm
- the PC at time t = i
then value of cell dst at time (t + 1) = (value of cell src at time t) + imm
- instruction #i is
if 13 + 1 = 14, then value of cell 4 at time (13 + 1) = value of cell 4 at time 14
if the following are true:
- a = b
- a = c
then b = c
if the following are true:
- a = b + c
- b = d
then a = d + c
if the following are true:
- a = b
- b = c
then a = c
Please write your proof in the table below. Each row should contain one claim. The last claim is the statement that you are trying to prove.