diff options
author | Ali Saidi <Ali.Saidi@ARM.com> | 2013-01-07 13:05:33 -0500 |
---|---|---|
committer | Ali Saidi <Ali.Saidi@ARM.com> | 2013-01-07 13:05:33 -0500 |
commit | 5146a69835bc9ba37fba7d3b0ff72ecaf9b98b74 (patch) | |
tree | 694786d4ffd6384a3736d48e1fd20e29408bf56d /src/cpu/ozone/inorder_back_end_impl.hh | |
parent | 90bd20aae2bc940397628a4598b5b25f2c8549b5 (diff) | |
download | gem5-5146a69835bc9ba37fba7d3b0ff72ecaf9b98b74.tar.xz |
cpu: rename the misleading inSyscall to noSquashFromTC
isSyscall was originally created because during handling of a syscall in SE
mode the threadcontext had to be updated. However, in many places this is used
in FS mode (e.g. fault handlers) and the name doesn't make much sense. The
boolean actually stops gem5 from squashing speculative and non-committed state
when a write to a threadcontext happens, so re-name the variable to something
more appropriate
Diffstat (limited to 'src/cpu/ozone/inorder_back_end_impl.hh')
-rw-r--r-- | src/cpu/ozone/inorder_back_end_impl.hh | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/src/cpu/ozone/inorder_back_end_impl.hh b/src/cpu/ozone/inorder_back_end_impl.hh index 59d1dab0d..7bb876e4a 100644 --- a/src/cpu/ozone/inorder_back_end_impl.hh +++ b/src/cpu/ozone/inorder_back_end_impl.hh @@ -117,7 +117,7 @@ InorderBackEnd<Impl>::checkInterrupts() } if (ipl && ipl > thread->readMiscRegNoEffect(IPR_IPLR)) { - thread->inSyscall = true; + thread->noSquashFromTC = true; thread->setMiscRegNoEffect(IPR_ISR, summary); thread->setMiscRegNoEffect(IPR_INTID, ipl); @@ -128,7 +128,7 @@ InorderBackEnd<Impl>::checkInterrupts() // May need to go 1 inst prior squashPending = true; - thread->inSyscall = false; + thread->noSquashFromTC = false; setSquashInfoFromXC(); } @@ -206,7 +206,7 @@ InorderBackEnd<Impl>::executeInsts() Addr oldpc; do { if (count == 0) - assert(!thread->inSyscall && !thread->trapPending); + assert(!thread->noSquashFromTC && !thread->trapPending); oldpc = thread->readPC(); cpu->system->pcEventQueue.service( thread->getXCProxy()); @@ -291,16 +291,16 @@ InorderBackEnd<Impl>::executeInsts() DPRINTF(IBE, "Inst [sn:%lli] PC %#x has a fault\n", inst->seqNum, inst->readPC()); - assert(!thread->inSyscall); + assert(!thread->noSquashFromTC); - thread->inSyscall = true; + thread->noSquashFromTC = true; // Consider holding onto the trap and waiting until the trap event // happens for this to be executed. inst_fault->invoke(xc); // Exit state update mode to avoid accidental updating. - thread->inSyscall = false; + thread->noSquashFromTC = false; squashPending = true; @@ -365,16 +365,16 @@ InorderBackEnd<Impl>::handleFault() { DPRINTF(Commit, "Handling fault from fetch\n"); - assert(!thread->inSyscall); + assert(!thread->noSquashFromTC); - thread->inSyscall = true; + thread->noSquashFromTC = true; // Consider holding onto the trap and waiting until the trap event // happens for this to be executed. faultFromFetch->invoke(xc); // Exit state update mode to avoid accidental updating. - thread->inSyscall = false; + thread->noSquashFromTC = false; squashPending = true; @@ -415,8 +415,8 @@ InorderBackEnd<Impl>::squash(const InstSeqNum &squash_num, const Addr &next_PC) squashPending = false; // Probably want to make sure that this squash is the one that set the - // thread into inSyscall mode. - thread->inSyscall = false; + // thread into noSquashFromTC mode. + thread->noSquashFromTC = false; // Tell front end to squash, reset PC to new one. frontEnd->squash(squash_num, next_PC); @@ -431,7 +431,7 @@ InorderBackEnd<Impl>::squashFromXC() // Record that I need to squash squashPending = true; - thread->inSyscall = true; + thread->noSquashFromTC = true; } template <class Impl> |