kern: Stop using a pseudo instruction to quiesce the ThreadContext.
The pseudo instruction implementation is very short, and so doing the work it was doing directly doesn't really add much to the implementation of the udelay events. By not calling the pseudo instruction we also uncouple these unrelated mechanisms and don't, for instance, cause pseudo instruction debug output every time udelay executes. Change-Id: I5c9b32509562487e53b2acfa1a3f6226d33d1cfd Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/23748 Tested-by: kokoro <noreply+kokoro@google.com> Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu> Maintainer: Gabe Black <gabeblack@google.com>
This commit is contained in:
@@ -40,7 +40,6 @@
|
||||
#include "debug/DebugPrintf.hh"
|
||||
#include "kern/system_events.hh"
|
||||
#include "sim/arguments.hh"
|
||||
#include "sim/pseudo_inst.hh"
|
||||
#include "sim/system.hh"
|
||||
|
||||
namespace FreeBSD {
|
||||
@@ -69,9 +68,8 @@ UDelayEvent::process(ThreadContext *tc)
|
||||
// __delay and __loop_delay functions. One form involves setting quiesce
|
||||
// time to 0 with the assumption that quiesce will not happen. To avoid
|
||||
// the quiesce handling in this case, only execute the quiesce if time > 0.
|
||||
if (time > 0) {
|
||||
PseudoInst::quiesceNs(tc, time);
|
||||
}
|
||||
if (time > 0)
|
||||
tc->quiesceTick(curTick() + SimClock::Int::ns * time);
|
||||
}
|
||||
|
||||
} // namespace FreeBSD
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
#include "kern/linux/printk.hh"
|
||||
#include "kern/system_events.hh"
|
||||
#include "sim/arguments.hh"
|
||||
#include "sim/pseudo_inst.hh"
|
||||
#include "sim/core.hh"
|
||||
#include "sim/system.hh"
|
||||
|
||||
namespace Linux {
|
||||
@@ -90,9 +90,8 @@ UDelayEvent::process(ThreadContext *tc)
|
||||
// __delay and __loop_delay functions. One form involves setting quiesce
|
||||
// time to 0 with the assumption that quiesce will not happen. To avoid
|
||||
// the quiesce handling in this case, only execute the quiesce if time > 0.
|
||||
if (time > 0) {
|
||||
PseudoInst::quiesceNs(tc, time);
|
||||
}
|
||||
if (time > 0)
|
||||
tc->quiesceTick(curTick() + SimClock::Int::ns * time);
|
||||
}
|
||||
|
||||
void
|
||||
|
||||
Reference in New Issue
Block a user