X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=src%2Fbase%2Fpollevent.hh;h=67dca68a2bc1218a4ae568a211bff7fd16996d2d;hb=ebd62eff3c98564b175e7acc69bbdc7e823da059;hp=ecaeb94ce9b2db4bfded43e14dcc461f5d4c6c0e;hpb=ea7bdf9f60c404761dfc568d5291c75747a2dd88;p=gem5.git diff --git a/src/base/pollevent.hh b/src/base/pollevent.hh index ecaeb94ce..67dca68a2 100644 --- a/src/base/pollevent.hh +++ b/src/base/pollevent.hh @@ -24,21 +24,21 @@ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * Authors: Nathan Binkert */ #ifndef __POLLEVENT_H__ #define __POLLEVENT_H__ -#include #include + +#include + #include "sim/core.hh" class Checkpoint; class PollQueue; -class PollEvent +class PollEvent : public Serializable { private: friend class PollQueue; @@ -58,8 +58,8 @@ class PollEvent bool queued() { return queue != 0; } - virtual void serialize(std::ostream &os); - virtual void unserialize(Checkpoint *cp, const std::string §ion); + void serialize(CheckpointOut &cp) const override; + void unserialize(CheckpointIn &cp) override; }; class PollQueue @@ -81,17 +81,8 @@ class PollQueue void schedule(PollEvent *event); void service(); - protected: - static bool handler; - static struct sigaction oldio; - static struct sigaction oldalrm; - public: static void setupAsyncIO(int fd, bool set); - static void handleIO(int); - static void handleALRM(int); - static void removeHandler(); - static void setupHandler(); }; extern PollQueue pollQueue;