You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+63-12
Original file line number
Diff line number
Diff line change
@@ -9,24 +9,58 @@
9
9
`.__.-.__.'
10
10
11
11
```
12
-
13
12
----
14
13
15
-
DLX ISA, RISC microprocessor, VHDL implementation
14
+
### Author Note
15
+
> I don't like this folder structure but it was imposed on us to keep the project "tidier" and simpler to recognize the hierarchy from. To be honest the constraint is understandable but it's still awful to look at and use.
As can be seen in the block schema of the processor, data and instruction memories are placed outside the CPU.
20
+
21
+
## Data-path
22
+
The data-path is represented in black, the control unit and its signals are blue and the hazard unit is purple.
23
+

24
+
25
+
## ALU
26
+
The ALU features a Pentium 4 adder unit, a UltraSPARC T2 Shifter and Logic units and a behavioural comparator unit.
27
+

28
+
29
+
### T2 Shifter
30
+
The shifter unit is based on the SUN UltraSPARC T2 design, with a three-stage
31
+
shifter implemented using masks shifted by varying amounts and combined to obtain
32
+
the required operation. The implemented unit is able to perform left and right
33
+
logical shifts and right arithmetical shifts.
34
+

35
+
#### Mask Generator
36
+
The mask generator generates four masks, that contain the
37
+
input A signal shifted by 8, 16, 24 and 32 bits respectively. The shift direction is
38
+
dictated by the op signal (`00` for logical left shift, `01` for logical right shifts and
39
+
`10` for arithmetical right shifts). An additional signal, msb, generates a fifth mask
40
+
that is used for AMOUNT values greater than 31. The value of msb is `0` when a
41
+
logical shift is being performed and is equals to the most-significant bit of A when
42
+
an arithmetic shift is selected.
43
+
#### Coarse Shift
44
+
The coarse shift stage selects the coarse mask by considering the 30
45
+
most-significant bits of the AMOUNT signal. If AMOUNT is bigger than 31, the
46
+
coarse shift will select the msb mask.
47
+
#### Fine Shift
48
+
The fine shift will shift the selected coarse mask by the three least-
49
+
significant digits of AMOUNT , completing the shift operation
50
+
51
+
### T2 Logic Unit
52
+
The T2 logic unit is able to perform five logical operations with just five NAND gates.
53
+

20
54
21
55
## Dependencies
22
56
- Questa Sim-64 10.7c
23
57
- design compiler F-2011.09-SP3
24
58
- Bash
25
-
-Pearl
59
+
-Perl
26
60
27
61
## How To Run An Assembly Program
28
62
1) Write an Assembly program using the DLX isa found [here](./doc/isa.md)
29
-
1) The size of your program (lines of code), must be so that it culd be saved in the instruction memory. If your program exceeds this size the design will not compile, in such case change the value `C_IMEM_ADDR_W` in file `./src/000-common.core/000-DLX_PKG.vhd` accordingly.
63
+
1) The size of your program (lines of code), must be so that it could be saved in the instruction memory. If your program exceeds this size the design will not compile, in such case change the value `C_IMEM_ADDR_W` in file `./src/000-common.core/000-DLX_PKG.vhd` accordingly.
30
64
2) If you need to address more then the default data-memory space change the variable
31
65
`C_DMEM_ADDR_W` in file `./src/000-common.core/000-DLX_PKG.vhd` accordingly. The compiler can't catch this error, the design will simulate your design but will truncate the data-memory-addresses to comply with its internal address space.
32
66
@@ -51,7 +85,7 @@ DLX ISA, RISC microprocessor, VHDL implementation
51
85
```
52
86
To change the simulation time modify the line `run 212us`in`./sim/sim.do`
53
87
54
-
5) The simulation will output the file `./sim/rf_dmemd.dump`. This file contains the content of the Register file (in order 0 to 31) and data memroy (in reverse order DATA_MEM_SIZE-1 downto 0). Check this file to see if your program is compliant with your behaviour (you obviously need to save the program state either in data memory of in the register file)
88
+
5) The simulation will output the file `./sim/rf_dmemd.dump`. This file contains the content of the Register file (in order 0 to 31) and data memory (in reverse order `DATA_MEM_SIZE-1 downto 0`). Check this file to see if your program is compliant with your behaviour (you obviously need to save the program state either in data memory of in the register file)
55
89
56
90
## How To Syntesize The Design
57
91
The design synthesized is only MELA without memories.
@@ -76,11 +110,11 @@ Select the configuration and the desired clock-period in nanoseconds (can be a f
76
110
Synthesis outputs will be in the `./syn` folder, respectively:
77
111
- `./syn/reports` will contain timing, area and power reports
78
112
- `./syn/netlists` will contain the synthesized netlist
79
-
- `./syn/design_compiler_sdc` will contain the `sdc` file generated by design compiler for this syntesis run
113
+
- `./syn/design_compiler_sdc` will contain the `sdc` file generated by design compiler for this synthesis run
80
114
81
115
## Place And Route
82
-
Here some nice pictures. No description for this process because we didn't know what we where doing, just followin a recepy, but nice pics.
83
-
### Asic View
116
+
Here some nice pictures. No description for this process because we didn't know what we where doing, just following a recipe, but nice pics.
@@ -93,7 +127,24 @@ Here some nice pictures. No description for this process because we didn't know
93
127

94
128
95
129
## Notes
96
-
I don't like this folder strcuture but it was imposed on us to keep the project "tidier" and simpler to recognize the hierarchy from.
97
-
To be honest the constraint is understandable but it's still aweful to look at and use.
130
+
I don't like this folder structure but it was imposed on us to keep the project "tidier" and simpler to recognize the hierarchy from.
131
+
To be honest the constraint is understandable but it's still awful to look at and use.
132
+
133
+
## ALU
134
+
MELA's ALU features a Pentium 4 adder unit, UltraSPARC T2 Shifter and Logic units, and a behavioural comparator. The ALU can be configured to have behavioural implementations of the aforementioned units.
135
+
136
+
137
+
For more info about MELA's architecture, check out the [report](doc/report.pdf)
138
+
139
+
## Nerd corner
140
+
### Vim bindings
141
+
Make sure the vim `PWD` is the root of the project
0 commit comments