OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [tags/] [stable_0_2_0_rc3/] [or1ksim/] [sim.cfg] - Blame information for rev 313

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 264 markom
/* sim.cfg -- Simulator configuration script file
2
   Copyright (C) 2001, Marko Mlinar, markom@opencores.org
3 312 markom
 
4
This file includes a lot of help about configurations and default one
5 264 markom
 
6
This file is part of OpenRISC 1000 Architectural Simulator.
7
 
8
This program is free software; you can redistribute it and/or modify
9
it under the terms of the GNU General Public License as published by
10
the Free Software Foundation; either version 2 of the License, or
11
(at your option) any later version.
12
 
13
This program is distributed in the hope that it will be useful,
14
but WITHOUT ANY WARRANTY; without even the implied warranty of
15
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16
GNU General Public License for more details.
17
 
18
You should have received a copy of the GNU General Public License
19
along with this program; if not, write to the Free Software
20
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
21
 
22 312 markom
 
23
/* INTRODUCTION
24
 
25
   The or1ksim have various parameters, which can be set in configuration
26
   files.  Multiple configurations may be used and switched between at
27
   or1ksim startup.
28
   By default, or1ksim loads condfiguration file from './sim.cfg' and if not
29
   found it checks '~/.or1k/sim.cfg'. If even this file is not found or
30
   all parameters are not defined, default configuration is used.
31
   Users should not rely on default configuration, but rather redefine all
32
   critical settings, since default configuration may differ in newer
33
   versions of the or1ksim.
34
   If multiple configurations are used, user can switch between them by
35
   supplying -f  option when starting simulator.
36
 
37
   This file may contain (standard C) only comments - no // support.
38
 
39
   Like normal configuration file, this file is divided in sections,
40
   where each section is described in detail also.
41
 
42
   Some section also have subsections. One example of such subsection is
43
   block:
44
 
45
   device 
46
     instance specific parameters...
47
   enddevice
48
 
49
   which creates a device instance.
50
*/
51
 
52
 
53
/* MEMORY SECTION
54
 
55
   This section specifies how is initial memory generated and which blocks
56
   it consist of.
57
 
58
   memory_table_file = ""
59
      loads memory table from filename. If filename does not exists in the
60
      current directory, it is loaded from ~/.or1k/.
61
      Memory table file structure is as follows:
62
        start_address1 length1 type1 [ce1 [delayr1 [delayw1]]]
63
        start_address2 length2 type2 [ce2 [delayr2 [delayw2]]]
64
        start_address3 length3 type3 [ce3 [delayr3 [delayw3]]]
65
 
66
      Example:
67
        00000100 00001F00 flash 3 100
68
        80000000 00010000 RAM
69
 
70
   type = random/unknown/pattern
71
      specifies the initial memory values. 'random' parameter generate
72
      random memory using seed 'random_seed' parameter. 'pattern' parameter
73
      fills memory with 'pattern' parameter and 'unknown' does not specify
74
      how memory should be generated - the fastest option.
75
 
76
   random_seed = 
77
      random seed for randomizer, used if type = random
78
 
79
   pattern = 
80
      pattern to fill memory, , used if type = pattern
81
*/
82
 
83 262 markom
section memory
84
  memory_table_file = "simmem.cfg"
85 264 markom
  /*random_seed = 12345
86
  type = random*/
87 269 markom
  pattern = 0x00
88
  type = unknown /* Fastest */
89 262 markom
end
90
 
91 312 markom
 
92
/* SIM SECTION
93
 
94
  This section specifies how should sim behave.
95
 
96
  verbose = 0/1
97
      whether to print out extra messages
98
 
99
  debug = 0/1
100
      whether to print out sim debug information
101
 
102
  profile = 0/1
103
      whether to generate profiling file 'sim.profile'
104
 
105
  prof_fn = ""
106
      filename, where to generate profiling info, used
107
      only if 'profile' is set
108
 
109
  iprompt = 0/1
110
      whether we strart in interactive prompt
111
 
112
  exe_log = 0/1
113
      whether execution log should be generated
114
 
115
  exe_log_fn = ""
116
      where to put execution log in, used only if 'exe_log'
117
      is set
118
 
119
section sim
120
  /*verbose = 1*/
121
  debug = 0
122
  profile = 0
123
  prof_fn = "sim.profile"
124
 
125
  /* iprompt = 0 */
126
  exe_log = 0
127
  exe_log_fn = "executed.log"
128
end
129
 
130
 
131
/* SECTION VAPI
132
 
133
    This section configures Verification API, used for Advanced
134
    Core Verification.
135
 
136
    enabled = 0/1
137
        whether to start VAPI server
138
 
139
    server_port = 
140
        TCP/IP port to start VAPI server on
141
*/
142
 
143
section VAPI
144
  enabled = 0
145
  server_port = 9998
146
end
147
 
148
 
149
/* CPU SECTION
150
 
151
   This section specifies various CPU parameters.
152
 
153
   ver = 
154
   rev = 
155
      specifies version and revision of the CPU used
156
 
157
   upr = 
158
      changes the upr register
159
 
160
   superscalar = 0/1
161
   hazards = 0/1
162
   history = 0/1
163
   dependstats = 0/1
164
   dependency = 0/1
165
   slp = 0/1
166
   btic = 0/1
167
   bpb = 0/1
168
      parameters for CPU analysis
169
*/
170
 
171 263 markom
section cpu
172
  ver = 0x1200
173
  rev = 0x0001
174
  /* upr = */
175
  superscalar = 0
176
  hazards = 0
177
  history = 0
178
  dependstats = 0
179
  dependency = 0
180
  slp = 0
181 304 markom
  btic = 0
182 264 markom
  bpb = 0
183 263 markom
end
184
 
185 312 markom
 
186
/* DEBUG SECTION
187
 
188
   This sections specifies how debug unit should behave.
189
 
190
   enabled = 0/1
191
      whether debug unit is enabled
192
 
193
   gdb_enabled = 0/1
194
      whether to start gdb server at 'server_port' port
195
 
196
   server_port = 
197
      TCP/IP port to start gdb server on, used only if gdb_enabled
198
      is set
199
 
200 269 markom
section debug
201 312 markom
  enabled = 0
202
  gdb_enabled = 0
203 269 markom
  server_port = 9999
204
end
205
 
206 264 markom
 
207 312 markom
/* MC SECTION
208
 
209
   This section configures the memory controller
210
 
211
   enabled = 0/1
212
      whether memory controller is enabled
213
 
214
   baseaddr = 
215
      address of first MC register
216
 
217
   POC = 
218
      Power On Configuration register
219
*/
220
 
221 243 markom
section mc
222 304 markom
  enabled = 0
223 261 markom
  baseaddr = 0xa0000000
224
  POC = 0x00000008                 /* Power on configuration register */
225 243 markom
end
226 261 markom
 
227 312 markom
 
228
/* UART SECTION
229
 
230
   This section configures UARTs
231
 
232
   enabled = 0/1
233
      whether uarts are enabled
234
 
235
   nuarts = 
236
      make specified number of instances, configure each
237
      instance within device - enddevice construct.
238
 
239
   instance specific:
240
     baseaddr = 
241
        address of first UART register for this device
242
 
243
     rx_file = ""
244
        filename, where to read data from
245
 
246
     tx_file = ""
247
        filename, where to write data to
248
 
249
     jitter = 
250
        in msecs... time to block, -1 to disable it
251 313 markom
 
252
     vapi_id = 
253
        VAPI id of this instance
254 312 markom
*/
255
 
256 261 markom
section uart
257 304 markom
  enabled = 0
258 261 markom
  nuarts = 1
259
 
260
  device 0
261
    baseaddr = 0x80000000
262
    rxfile = "/tmp/uart0.rx"
263
    txfile = "/tmp/uart0.tx"
264
    jitter = -1                     /* async behaviour */
265
  enddevice
266
end
267
 
268 312 markom
 
269
/* DMA SECTION
270
 
271
   This section configures DMAs
272
 
273
   enabled = 0/1
274
      whether DMAs are enabled
275
 
276
   ndmas = 
277
      make specified number of instances, configure each
278
      instance within device - enddevice construct.
279
 
280
   instance specific:
281
     baseaddr = 
282
        address of first DMA register for this device
283
 
284
     irq = 
285
        irq number for this device
286 313 markom
 
287
     vapi_id = 
288
        VAPI id of this instance
289 312 markom
*/
290
 
291 261 markom
section dma
292 304 markom
  enabled = 0
293 261 markom
  ndmas = 1
294
 
295
  device 0
296
    baseaddr = 0x90000000
297
    irq = 4
298
  enddevice
299
end
300 293 markom
 
301 304 markom
 
302 312 markom
/* ETHERNET SECTION
303
 
304
   This section configures ethernets
305
 
306
   enabled = 0/1
307
      whether ethernets are enabled
308
 
309
   nethernets = 
310
      make specified number of instances, configure each
311
      instance within device - enddevice construct.
312
 
313
   instance specific:
314
     baseaddr = 
315
        address of first ethernet register for this device
316
 
317
     dma = 
318
        which controller is this ethernet "connected" to
319
 
320
     rx_channel = 
321
        DMA channel used for RX
322
 
323
     tx_channel = 
324
        DMA channel used for TX
325
 
326
     rx_file = ""
327
        filename, where to read data from
328
 
329
     tx_file = ""
330
        filename, where to write data to
331 313 markom
 
332
     vapi_id = 
333
        VAPI id of this instance
334 312 markom
*/
335
 
336 304 markom
section ethernet
337
  enabled = 0
338 310 markom
  nethernets = 1
339
 
340
  device 0
341
    baseaddr = 0x88000000
342
    dma = 0
343
    tx_channel = 0
344
    rx_channel = 1
345
    rxfile = "/tmp/eth0.rx"
346
    txfile = "/tmp/eth0.tx"
347
  enddevice
348 304 markom
end

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.