43 #ifndef __ARCH_MIPS_LOCKED_MEM_HH__ 44 #define __ARCH_MIPS_LOCKED_MEM_HH__ 52 #include "arch/registers.hh" 55 #include "debug/LLSC.hh" 71 if (locked_addr == snoop_addr)
82 DPRINTF(LLSC,
"[cid:%i]: Load-Link Flag Set & Load-Link" 83 " Address set to %x.\n",
84 req->contextId(), req->getPaddr() & ~0xf);
97 if (req->isUncacheable()) {
100 req->setExtraData(2);
106 if (!lock_flag || (req->getPaddr() & ~0xf) != lock_addr) {
109 req->setExtraData(0);
116 int stCondFailures = xc->readStCondFailures();
118 xc->setStCondFailures(stCondFailures);
119 if (stCondFailures % 100000 == 0) {
120 warn(
"%i: context %d: %d consecutive " 121 "store conditional failures\n",
122 curTick(), xc->contextId(), stCondFailures);
126 DPRINTF(LLSC,
"[cid:%i]: Lock Flag Set, " 127 "Store Conditional Failed.\n",
129 }
else if ((req->getPaddr() & ~0xf) != lock_addr) {
130 DPRINTF(LLSC,
"[cid:%i]: Load-Link Address Mismatch, " 131 "Store Conditional Failed.\n",
146 xc->getCpuPtr()->wakeup(xc->threadId());
bool handleLockedWrite(XC *xc, const RequestPtr &req, Addr cacheBlockMask)
void globalClearExclusive(XC *xc)
Declaration of a request, the overall memory request consisting of the parts of the request that are ...
std::shared_ptr< Request > RequestPtr
void handleLockedSnoopHit(XC *xc)
void handleLockedSnoop(XC *xc, PacketPtr pkt, Addr cacheBlockMask)
Tick curTick()
The current simulated tick.
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
A Packet is used to encapsulate a transfer between two objects in the memory system (e...
Declaration of the Packet class.
void handleLockedRead(XC *xc, const RequestPtr &req)