gem5 v24.0.0.0
|
A class to skip udelay() and related calls in the kernel. More...
#include <events.hh>
Public Member Functions | |
SkipUDelay (PCEventScope *s, const std::string &desc, Addr addr, uint64_t mult, uint64_t div) | |
void | process (ThreadContext *tc) override |
Private Attributes | |
uint64_t | argDivToNs |
value to divide arg by to create ns. | |
uint64_t | argMultToNs |
value to multiple arg by to create ns. | |
A class to skip udelay() and related calls in the kernel.
This class has two additional parameters that take the argument to udelay and manipulated it to come up with ns and eventually ticks to quiesce for. See descriptions of argDivToNs and argMultToNs below.
|
inline |
|
inlineoverride |
Definition at line 75 of file events.hh.
References gem5::free_bsd::SkipUDelay< ABI, Base >::argDivToNs, gem5::free_bsd::SkipUDelay< ABI, Base >::argMultToNs, gem5::invokeSimcall(), and gem5::free_bsd::onUDelay().
|
private |
value to divide arg by to create ns.
This is present beacues the linux kernel code sometime precomputes the first multiply that is done in udelay() if the parameter is a constant. We need to undo it so here is how.
Definition at line 61 of file events.hh.
Referenced by gem5::free_bsd::SkipUDelay< ABI, Base >::process().
|
private |
value to multiple arg by to create ns.
Nominally, this is 1000 to convert us to ns, but since linux can do some preprocessing of constant values something else might be required.
Definition at line 66 of file events.hh.
Referenced by gem5::free_bsd::SkipUDelay< ABI, Base >::process().