summaryrefslogtreecommitdiff
path: root/src/mem/packet.hh
diff options
context:
space:
mode:
authorRon Dreslinski <rdreslin@umich.edu>2006-06-28 17:28:33 -0400
committerRon Dreslinski <rdreslin@umich.edu>2006-06-28 17:28:33 -0400
commit0d323c753d897bec72884089bc0dc334a64e9eb3 (patch)
treeb5c69c91860b1282cf2ef8a415ce965e51d94f4f /src/mem/packet.hh
parentfc281d0b64fca8d2809ec462148acb7cf0461ea5 (diff)
downloadgem5-0d323c753d897bec72884089bc0dc334a64e9eb3.tar.xz
More Changes, working towards cache.cc compiling. Headers cleaned up.
src/mem/cache/cache_blk.hh: Remove XC --HG-- extra : convert_revision : aa2c43e4412ebb93165e12f693d5126983cfd0dc
Diffstat (limited to 'src/mem/packet.hh')
-rw-r--r--src/mem/packet.hh17
1 files changed, 16 insertions, 1 deletions
diff --git a/src/mem/packet.hh b/src/mem/packet.hh
index 176c6f793..3d3768676 100644
--- a/src/mem/packet.hh
+++ b/src/mem/packet.hh
@@ -41,10 +41,17 @@
#include "mem/request.hh"
#include "arch/isa_traits.hh"
#include "sim/root.hh"
+#include <list>
struct Packet;
typedef Packet* PacketPtr;
typedef uint8_t* PacketDataPtr;
+typedef std::list<PacketPtr> PacketList;
+
+//Coherence Flags
+#define NACKED_LINE 1 << 0
+#define SATISFIED 1 << 1
+#define SHARED_LINE 1 << 2
//For statistics we need max number of commands, hard code it at
//20 for now. @todo fix later
@@ -173,7 +180,10 @@ class Packet
SoftPFReq = IsRead | IsRequest | IsSWPrefetch | NeedsResponse,
HardPFReq = IsRead | IsRequest | IsHWPrefetch | NeedsResponse,
SoftPFResp = IsRead | IsRequest | IsSWPrefetch | IsResponse,
- HardPFResp = IsRead | IsRequest | IsHWPrefetch | IsResponse
+ HardPFResp = IsRead | IsRequest | IsHWPrefetch | IsResponse,
+ InvalidateReq = IsInvalidate | IsRequest,
+ WriteInvalidateReq = IsWrite | IsInvalidate | IsRequest,
+ UpgradeReq = IsInvalidate | NeedsResponse
};
/** Return the string name of the cmd field (for debugging and
@@ -190,9 +200,14 @@ class Packet
Command cmd;
bool isRead() { return (cmd & IsRead) != 0; }
+ bool isWrite() { return (cmd & IsWrite) != 0; }
bool isRequest() { return (cmd & IsRequest) != 0; }
bool isResponse() { return (cmd & IsResponse) != 0; }
bool needsResponse() { return (cmd & NeedsResponse) != 0; }
+ bool isInvalidate() { return (cmd * IsInvalidate) != 0; }
+
+ bool isCacheFill() { assert("Unimplemented yet\n" && 0); }
+ bool isNoAllocate() { assert("Unimplemented yet\n" && 0); }
/** Possible results of a packet's request. */
enum Result