-
Notifications
You must be signed in to change notification settings - Fork 0
/
testingStoreLoad.mif
34 lines (31 loc) · 1.27 KB
/
testingStoreLoad.mif
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
WIDTH=24;
DEPTH=32;
ADDRESS_RADIX=HEX;
DATA_RADIX=BIN;
--this file does:
-- 00 nop | 00000 | 0000 | 0 | 0000 | 0000 | 00000 | 0 |
-- 01 add r2 #5 | 00011 | 0000 | 0 | 0010 | 0000 | 00101 | 1 |
-- 02 add r3 #25 | 00011 | 0000 | 0 | 0011 | 0000 | 11001 | 1 |
-- 03 st r2 0(r3) | 00111 | 0000 | 0 | 0010 | 0011 | 00000 | 0 |
-- 04 ld r4 0(r3) | 00110 | 0000 | 0 | 0100 | 0011 | 00000 | 0 |
-- 05 j.l #5 | 10001 | 0000 | 0 | 0000 | 0000 | 00010 | 1 | expected pc: 10
-- 06 add r2 r4 | 00011 | 0000 | 0 | 0010 | 0100 | 00000 | 0 |
-- 07 nop | 00000 | 0000 | 0 | 0000 | 0000 | 00000 | 0 |
-- 08 nop | 00000 | 0000 | 0 | 0000 | 0000 | 00000 | 0 |
-- 09 nop | 00000 | 0000 | 0 | 0000 | 0000 | 00000 | 0 |
-- 0A nop | 00000 | 0000 | 0 | 0000 | 0000 | 00000 | 0 |
-- 0B jr r15 | 01010 | 0000 | 0 | 1111 | 0000 | 00000 | 0 | expected pc: 5 then increments @ next cycle
CONTENT BEGIN
00 : 000000000000000000000000;
01 : 000110000000100000001011;
02 : 000110000000110000110011;
03 : 001110000000100011000000;
04 : 001100000001000011000000;
05 : 100010000000000000000101;
06 : 000110000000100100000000;
07 : 000000000000000000000000;
08 : 000000000000000000000000;
09 : 000000000000000000000000;
0A : 000000000000000000000000;
0B : 010100000011110000000000;
END;