Merge zizzer.eecs.umich.edu:/bk/newmem/
[gem5.git] / src / cpu / ozone / simple_params.hh
1 /*
2 * Copyright (c) 2006 The Regents of The University of Michigan
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;
9 * redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the
11 * documentation and/or other materials provided with the distribution;
12 * neither the name of the copyright holders nor the names of its
13 * contributors may be used to endorse or promote products derived from
14 * this software without specific prior written permission.
15 *
16 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
17 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
18 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
19 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
20 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
21 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
22 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
26 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 *
28 * Authors: Kevin Lim
29 */
30
31 #ifndef __CPU_OZONE_SIMPLE_PARAMS_HH__
32 #define __CPU_OZONE_SIMPLE_PARAMS_HH__
33
34 #include "cpu/ozone/cpu.hh"
35
36 //Forward declarations
37 namespace TheISA
38 {
39 class DTB;
40 class ITB;
41 }
42 class FUPool;
43 class MemObject;
44 class PageTable;
45 class Process;
46 class System;
47
48 /**
49 * This file defines the parameters that will be used for the OzoneCPU.
50 * This must be defined externally so that the Impl can have a params class
51 * defined that it can pass to all of the individual stages.
52 */
53
54 class SimpleParams : public BaseCPU::Params
55 {
56 public:
57
58 #if FULL_SYSTEM
59 TheISA::ITB *itb; TheISA::DTB *dtb;
60 #else
61 std::vector<Process *> workload;
62 #endif // FULL_SYSTEM
63
64 //Page Table
65 PageTable *pTable;
66
67 //
68 // Caches
69 //
70 // MemInterface *icacheInterface;
71 // MemInterface *dcacheInterface;
72
73 unsigned cachePorts;
74 unsigned width;
75 unsigned frontEndLatency;
76 unsigned frontEndWidth;
77 unsigned backEndLatency;
78 unsigned backEndWidth;
79 unsigned backEndSquashLatency;
80 unsigned maxInstBufferSize;
81 unsigned numPhysicalRegs;
82 unsigned maxOutstandingMemOps;
83 //
84 // Fetch
85 //
86 unsigned decodeToFetchDelay;
87 unsigned renameToFetchDelay;
88 unsigned iewToFetchDelay;
89 unsigned commitToFetchDelay;
90 unsigned fetchWidth;
91
92 //
93 // Decode
94 //
95 unsigned renameToDecodeDelay;
96 unsigned iewToDecodeDelay;
97 unsigned commitToDecodeDelay;
98 unsigned fetchToDecodeDelay;
99 unsigned decodeWidth;
100
101 //
102 // Rename
103 //
104 unsigned iewToRenameDelay;
105 unsigned commitToRenameDelay;
106 unsigned decodeToRenameDelay;
107 unsigned renameWidth;
108
109 //
110 // IEW
111 //
112 unsigned commitToIEWDelay;
113 unsigned renameToIEWDelay;
114 unsigned issueToExecuteDelay;
115 unsigned issueWidth;
116 unsigned executeWidth;
117 unsigned executeIntWidth;
118 unsigned executeFloatWidth;
119 unsigned executeBranchWidth;
120 unsigned executeMemoryWidth;
121 FUPool *fuPool;
122
123 //
124 // Commit
125 //
126 unsigned iewToCommitDelay;
127 unsigned renameToROBDelay;
128 unsigned commitWidth;
129 unsigned squashWidth;
130
131 //
132 // Branch predictor (BP & BTB)
133 //
134 std::string predType;
135 unsigned localPredictorSize;
136 unsigned localCtrBits;
137 unsigned localHistoryTableSize;
138 unsigned localHistoryBits;
139 unsigned globalPredictorSize;
140 unsigned globalCtrBits;
141 unsigned globalHistoryBits;
142 unsigned choicePredictorSize;
143 unsigned choiceCtrBits;
144
145 unsigned BTBEntries;
146 unsigned BTBTagSize;
147
148 unsigned RASSize;
149
150 //
151 // Load store queue
152 //
153 unsigned LQEntries;
154 unsigned SQEntries;
155 bool lsqLimits;
156
157 //
158 // Memory dependence
159 //
160 unsigned SSITSize;
161 unsigned LFSTSize;
162
163 //
164 // Miscellaneous
165 //
166 unsigned numPhysIntRegs;
167 unsigned numPhysFloatRegs;
168 unsigned numIQEntries;
169 unsigned numROBEntries;
170
171 bool decoupledFrontEnd;
172 int dispatchWidth;
173 int wbWidth;
174
175 //SMT Parameters
176 unsigned smtNumFetchingThreads;
177
178 std::string smtFetchPolicy;
179
180 std::string smtIQPolicy;
181 unsigned smtIQThreshold;
182
183 std::string smtLSQPolicy;
184 unsigned smtLSQThreshold;
185
186 std::string smtCommitPolicy;
187
188 std::string smtROBPolicy;
189 unsigned smtROBThreshold;
190
191 // Probably can get this from somewhere.
192 unsigned instShiftAmt;
193 };
194
195 #endif // __CPU_OZONE_SIMPLE_PARAMS_HH__