diff options
author | Korey Sewell <ksewell@umich.edu> | 2009-07-31 09:34:29 -0400 |
---|---|---|
committer | Korey Sewell <ksewell@umich.edu> | 2009-07-31 09:34:29 -0400 |
commit | 60063cc700912666fa8b7968d692d00a1e82cb67 (patch) | |
tree | c04998dca2ebde1d95419a6e70f60ffb2809fcf6 /src/arch | |
parent | 6c463135561796a3d26709d0498f300717ceba83 (diff) | |
download | gem5-60063cc700912666fa8b7968d692d00a1e82cb67.tar.xz |
mips: fix ll/sc pairs working incorrectly because of accidental clobber of LLFLAG
Diffstat (limited to 'src/arch')
-rw-r--r-- | src/arch/mips/locked_mem.hh | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/arch/mips/locked_mem.hh b/src/arch/mips/locked_mem.hh index 2722ce8d2..8cf94df98 100644 --- a/src/arch/mips/locked_mem.hh +++ b/src/arch/mips/locked_mem.hh @@ -51,7 +51,7 @@ inline void handleLockedRead(XC *xc, Request *req) { xc->setMiscRegNoEffect(MISCREG_LLADDR, req->getPaddr() & ~0xf); - xc->setMiscRegNoEffect(MISCREG_LLADDR, true); + xc->setMiscRegNoEffect(MISCREG_LLFLAG, true); DPRINTF(LLSC, "[tid:%i]: Load-Link Flag Set & Load-Link" " Address set to %x.\n", req->threadId(), req->getPaddr() & ~0xf); @@ -83,17 +83,12 @@ handleLockedWrite(XC *xc, Request *req) int stCondFailures = xc->readStCondFailures(); stCondFailures++; xc->setStCondFailures(stCondFailures); - if (stCondFailures % 10 == 0) { + if (stCondFailures % 100000 == 0) { warn("%i: context %d: %d consecutive " "store conditional failures\n", curTick, xc->contextId(), stCondFailures); } - if (stCondFailures == 5000) { - panic("Max (5000) Store Conditional Fails Reached. " - "Check Code For Deadlock.\n"); - } - if (!lock_flag){ DPRINTF(LLSC, "[tid:%i]: Lock Flag Set, " "Store Conditional Failed.\n", |