2 * Copyright (c) 2004-2005 The Regents of The University of Michigan
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.
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.
29 #ifndef __CPU_BETA_CPU_COMM_HH__
30 #define __CPU_BETA_CPU_COMM_HH__
34 #include "arch/alpha/isa_traits.hh"
35 #include "cpu/inst_seq.hh"
36 #include "sim/host.hh"
38 // Find better place to put this typedef.
39 // The impl might be the best place for this.
40 typedef short int PhysRegIndex;
43 struct SimpleFetchSimpleDecode {
44 typedef typename Impl::DynInstPtr DynInstPtr;
48 DynInstPtr insts[Impl::MaxWidth];
52 struct SimpleDecodeSimpleRename {
53 typedef typename Impl::DynInstPtr DynInstPtr;
57 DynInstPtr insts[Impl::MaxWidth];
61 struct SimpleRenameSimpleIEW {
62 typedef typename Impl::DynInstPtr DynInstPtr;
66 DynInstPtr insts[Impl::MaxWidth];
70 struct SimpleIEWSimpleCommit {
71 typedef typename Impl::DynInstPtr DynInstPtr;
75 DynInstPtr insts[Impl::MaxWidth];
78 bool branchMispredict;
82 InstSeqNum squashedSeqNum;
87 typedef typename Impl::DynInstPtr DynInstPtr;
91 DynInstPtr insts[Impl::MaxWidth];
94 struct TimeBufStruct {
101 InstSeqNum doneSeqNum;
103 // Might want to package this kind of branch stuff into a single
104 // struct as it is used pretty frequently.
105 bool branchMispredict;
111 decodeComm decodeInfo;
113 // Rename can't actually tell anything to squash or send a new PC back
114 // because it doesn't do anything along those lines. But maybe leave
115 // these fields in here to keep the stages mostly orthagonal.
123 renameComm renameInfo;
128 // Also eventually include skid buffer space.
129 unsigned freeIQEntries;
137 unsigned freeROBEntries;
139 bool branchMispredict;
146 // Represents the instruction that has either been retired or
147 // squashed. Similar to having a single bus that broadcasts the
148 // retired or squashed sequence number.
149 InstSeqNum doneSeqNum;
151 // Extra bit of information so that the LDSTQ only updates when it
155 // Communication specifically to the IQ to tell the IQ that it can
156 // schedule a non-speculative instruction.
157 InstSeqNum nonSpecSeqNum;
160 commitComm commitInfo;
163 #endif //__CPU_BETA_CPU_COMM_HH__