-
Notifications
You must be signed in to change notification settings - Fork 23
/
Copy pathriscv64_inorder_soc.cfg
150 lines (125 loc) · 3.26 KB
/
riscv64_inorder_soc.cfg
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
/* VM configuration file */
{
version: 1,
machine: "riscv64", /* riscv32, riscv64 */
memory_size: 2048, /* MB */
bios: "riscv64-unknown-linux-gnu/bbl64.bin",
kernel: "riscv64-unknown-linux-gnu/kernel-riscv64.bin",
cmdline: "console=hvc0 root=/dev/vda rw",
drive0: { file: "riscv64-unknown-linux-gnu/riscv64.img" },
eth0: { driver: "user" },
core: {
name: "64-bit inorder riscv CPU",
type: "incore", /* incore, oocore */
cpu_freq_mhz: 1000,
rtc_freq_mhz: 10,
incore : {
num_cpu_stages: 5, /* 5, 6 */
},
oocore: {
iq_size: 16,
iq_issue_ports: 3,
rob_size: 64,
rob_commit_ports:4,
lsq_size: 16,
},
/* Note: Latencies for functional units, caches and memory are specified in CPU cycles */
functional_units: {
num_alu_stages: 1,
alu_stage_latency: "1",
num_mul_stages: 1,
mul_stage_latency: "4",
num_div_stages: 1,
div_stage_latency: "67",
/* Note: This will create a pipelined FP-FMA unit with 4 stages with a
* latency of 1 CPU cycle(s) per stage */
num_fpu_fma_stages: 4,
fpu_fma_stage_latency: "1,1,1,1",
/* Note: FP-ALU is non-pipelined */
fpu_alu_stage_latency: {
fadd: 2,
fsub: 2,
fmul: 2,
fdiv: 8,
fsqrt: 8,
fsgnj: 2,
fmin: 4,
fmax: 4,
feq: 2,
flt: 2,
fle: 2,
cvt: 2,
fcvt: 2,
fmv: 2,
fclass: 1,
},
/* Latency for RISC-V SYSTEM opcode instructions (includes CSR and privileged instructions)*/
system_insn_latency: 3,
},
bpu: {
enable: "true", /* true, false */
flush_on_context_switch: "false", /* true, false */
btb: {
size: 32,
ways: 2,
eviction_policy: "lru", /* lru, random */
},
bpu_type: "bimodal", /* bimodal, adaptive */
bimodal: {
bht_size: 256,
},
adaptive: {
ght_size: 1,
pht_size: 1,
history_bits: 2,
aliasing_func_type: "xor", /* xor, and, none */
/* Given config for adaptive predictor will create a Gshare predictor:
* 1) global history table consisting of one entry, entry includes a 2-bit history register
* 2) pattern history table consisting of one entry, entry includes an array of 4 saturating counters
* 3) value of history register will be `xor` ed with branch PC to index into the array of saturating counters
*/
},
ras_size: 6, /* value 0 disables RAS */
},
caches: {
enable_l1_caches: "true", /* true, false */
allocate_on_write_miss: "true", /* true, false */
write_policy: "writeback", /* writeback, writethrough */
line_size: 64, /* Bytes */
icache: {
size: 32, /* KB */
ways: 4,
latency: 1,
eviction: "lru", /* lru, random */
},
dcache: {
size: 32, /* KB */
ways: 8,
latency: 1,
eviction: "lru", /* lru, random */
},
l2_shared_cache: {
enable: "true",
size: 256, /* KB */
ways: 16,
latency: 5,
eviction: "lru", /* lru, random */
},
},
},
memory: {
tlb_size: 32,
/* Memory controller burst-length in bytes */
/* Note: This is automatically set to cache line size if caches are enabled */
burst_length: 64, /* Bytes */
base_dram_model: {
mem_access_latency: 50,
},
dramsim3: {
config_file: "DRAMsim3/configs/DDR4_4Gb_x16_2400.ini",
},
ramulator: {
config_file: "ramulator/configs/DDR4-config.cfg",
},
},
}