SLICC: Remove the keyword wake_up_dependents
[gem5.git] / src / mem / protocol / RubySlicc_Types.sm
1
2 /*
3 * Copyright (c) 1999-2005 Mark D. Hill and David A. Wood
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions are
8 * met: redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer;
10 * redistributions in binary form must reproduce the above copyright
11 * notice, this list of conditions and the following disclaimer in the
12 * documentation and/or other materials provided with the distribution;
13 * neither the name of the copyright holders nor the names of its
14 * contributors may be used to endorse or promote products derived from
15 * this software without specific prior written permission.
16 *
17 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
18 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
19 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
20 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
21 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
22 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
23 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
24 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
25 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
27 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28 */
29
30 // External Types
31
32 //
33 // **PLEASE NOTE!** When adding objects to this file you must also add a line
34 // in the src/mem/ruby/SConscript file. Otherwise the external object's .hh
35 // file will not be copied to the protocol directory and you will encounter a
36 // undefined declaration error.
37 //
38
39 external_type(MessageBuffer, buffer="yes", inport="yes", outport="yes");
40
41 external_type(OutPort, primitive="yes");
42
43 external_type(InPort, primitive="yes") {
44 bool isReady();
45 void dequeue();
46 int dequeue_getDelayCycles();
47 void recycle();
48 bool isEmpty();
49 }
50
51 external_type(NodeID, default="0");
52 external_type(MachineID);
53
54 MessageBuffer getMandatoryQueue(int core_id);
55
56 external_type(Set, non_obj="yes") {
57 void setSize(int);
58 void add(NodeID);
59 void addSet(Set);
60 void remove(NodeID);
61 void removeSet(Set);
62 void broadcast();
63 void addRandom();
64 void clear();
65 int count();
66 bool isElement(NodeID);
67 bool isEqual(Set);
68 bool isSuperset(Set);
69 bool intersectionIsEmpty(Set);
70 NodeID smallestElement();
71 }
72
73 external_type(NetDest, non_obj="yes") {
74 void setSize(int);
75 void setSize(int, int);
76 void add(NodeID);
77 void add(MachineID);
78 void addSet(Set);
79 void addNetDest(NetDest);
80 void setNetDest(MachineType, Set);
81 void remove(NodeID);
82 void remove(MachineID);
83 void removeSet(Set);
84 void removeNetDest(NetDest);
85 void broadcast();
86 void broadcast(MachineType);
87 void addRandom();
88 void clear();
89 Set toSet();
90 int count();
91 bool isElement(NodeID);
92 bool isElement(MachineID);
93 bool isSuperset(Set);
94 bool isSuperset(NetDest);
95 bool isEmpty();
96 bool intersectionIsEmpty(Set);
97 bool intersectionIsEmpty(NetDest);
98 MachineID smallestElement(MachineType);
99 }
100
101 external_type(Sequencer) {
102 void readCallback(Address, DataBlock);
103 void readCallback(Address, GenericMachineType, DataBlock);
104 void readCallback(Address, GenericMachineType, DataBlock, Time, Time, Time);
105 void writeCallback(Address, DataBlock);
106 void writeCallback(Address, GenericMachineType, DataBlock);
107 void writeCallback(Address, GenericMachineType, DataBlock, Time, Time, Time);
108 void checkCoherence(Address);
109 void profileNack(Address, int, int, uint64);
110 }
111
112 external_type(AbstractEntry, primitive="yes");
113
114 external_type(DirectoryMemory) {
115 AbstractEntry lookup(Address);
116 bool isPresent(Address);
117 void invalidateBlock(Address);
118 }
119
120 external_type(AbstractCacheEntry, primitive="yes");
121
122 external_type(CacheMemory) {
123 bool cacheAvail(Address);
124 Address cacheProbe(Address);
125 AbstractCacheEntry allocate(Address, AbstractCacheEntry);
126 void deallocate(Address);
127 AbstractCacheEntry lookup(Address);
128 bool isTagPresent(Address);
129 void profileMiss(CacheMsg);
130
131 void profileGenericRequest(GenericRequestType,
132 AccessModeType,
133 PrefetchBit);
134
135 void setMRU(Address);
136 }
137
138 external_type(MemoryControl, inport="yes", outport="yes") {
139
140 }
141
142 external_type(DMASequencer) {
143 void ackCallback();
144 void dataCallback(DataBlock);
145 }
146
147 external_type(TimerTable, inport="yes") {
148 bool isReady();
149 Address readyAddress();
150 void set(Address, int);
151 void unset(Address);
152 bool isSet(Address);
153 }
154
155 external_type(GenericBloomFilter) {
156
157 void clear(int);
158 void increment(Address, int);
159 void decrement(Address, int);
160 void set(Address, int);
161 void unset(Address, int);
162
163 bool isSet(Address, int);
164 int getCount(Address, int);
165 }
166
167
168
169