Merge zizzer:/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 class AlphaDTB;
38 class AlphaITB;
39 class FUPool;
40 class FunctionalMemory;
41 class MemInterface;
42 class PageTable;
43 class Process;
44 class System;
45
46 /**
47 * This file defines the parameters that will be used for the OzoneCPU.
48 * This must be defined externally so that the Impl can have a params class
49 * defined that it can pass to all of the individual stages.
50 */
51
52 class SimpleParams : public BaseCPU::Params
53 {
54 public:
55
56 #if FULL_SYSTEM
57 AlphaITB *itb; AlphaDTB *dtb;
58 #else
59 std::vector<Process *> workload;
60 #endif // FULL_SYSTEM
61
62 //Page Table
63 PageTable *pTable;
64
65 FunctionalMemory *mem;
66
67 //
68 // Caches
69 //
70 MemInterface *icacheInterface;
71 MemInterface *dcacheInterface;
72
73 unsigned cachePorts;
74 unsigned width;
75 unsigned frontEndWidth;
76 unsigned backEndWidth;
77 unsigned backEndSquashLatency;
78 unsigned backEndLatency;
79 unsigned maxInstBufferSize;
80 unsigned numPhysicalRegs;
81 unsigned maxOutstandingMemOps;
82 //
83 // Fetch
84 //
85 unsigned decodeToFetchDelay;
86 unsigned renameToFetchDelay;
87 unsigned iewToFetchDelay;
88 unsigned commitToFetchDelay;
89 unsigned fetchWidth;
90
91 //
92 // Decode
93 //
94 unsigned renameToDecodeDelay;
95 unsigned iewToDecodeDelay;
96 unsigned commitToDecodeDelay;
97 unsigned fetchToDecodeDelay;
98 unsigned decodeWidth;
99
100 //
101 // Rename
102 //
103 unsigned iewToRenameDelay;
104 unsigned commitToRenameDelay;
105 unsigned decodeToRenameDelay;
106 unsigned renameWidth;
107
108 //
109 // IEW
110 //
111 unsigned commitToIEWDelay;
112 unsigned renameToIEWDelay;
113 unsigned issueToExecuteDelay;
114 unsigned issueWidth;
115 unsigned executeWidth;
116 unsigned executeIntWidth;
117 unsigned executeFloatWidth;
118 unsigned executeBranchWidth;
119 unsigned executeMemoryWidth;
120 FUPool *fuPool;
121
122 //
123 // Commit
124 //
125 unsigned iewToCommitDelay;
126 unsigned renameToROBDelay;
127 unsigned commitWidth;
128 unsigned squashWidth;
129
130 //
131 // Branch predictor (BP & BTB)
132 //
133 std::string predType;
134 unsigned localPredictorSize;
135 unsigned localCtrBits;
136 unsigned localHistoryTableSize;
137 unsigned localHistoryBits;
138 unsigned globalPredictorSize;
139 unsigned globalCtrBits;
140 unsigned globalHistoryBits;
141 unsigned choicePredictorSize;
142 unsigned choiceCtrBits;
143
144 unsigned BTBEntries;
145 unsigned BTBTagSize;
146
147 unsigned RASSize;
148
149 //
150 // Load store queue
151 //
152 unsigned LQEntries;
153 unsigned SQEntries;
154
155 //
156 // Memory dependence
157 //
158 unsigned SSITSize;
159 unsigned LFSTSize;
160
161 //
162 // Miscellaneous
163 //
164 unsigned numPhysIntRegs;
165 unsigned numPhysFloatRegs;
166 unsigned numIQEntries;
167 unsigned numROBEntries;
168
169 bool decoupledFrontEnd;
170 int dispatchWidth;
171 int wbWidth;
172
173 //SMT Parameters
174 unsigned smtNumFetchingThreads;
175
176 std::string smtFetchPolicy;
177
178 std::string smtIQPolicy;
179 unsigned smtIQThreshold;
180
181 std::string smtLSQPolicy;
182 unsigned smtLSQThreshold;
183
184 std::string smtCommitPolicy;
185
186 std::string smtROBPolicy;
187 unsigned smtROBThreshold;
188
189 // Probably can get this from somewhere.
190 unsigned instShiftAmt;
191 };
192
193 #endif // __CPU_OZONE_SIMPLE_PARAMS_HH__