gem5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Private Attributes | List of all members
EventQueue::ScopedMigration Class Reference

Temporarily migrate execution to a different event queue. More...

#include <eventq.hh>

Public Member Functions

 ScopedMigration (EventQueue *_new_eq)
 
 ~ScopedMigration ()
 

Private Attributes

EventQueuenew_eq
 
EventQueueold_eq
 

Detailed Description

Temporarily migrate execution to a different event queue.

An instance of this class temporarily migrates execution to a different event queue by releasing the current queue, locking the new queue, and updating curEventQueue(). This can, for example, be useful when performing IO across thread event queues when timing is not crucial (e.g., during fast forwarding).

Definition at line 546 of file eventq.hh.

Constructor & Destructor Documentation

EventQueue::ScopedMigration::ScopedMigration ( EventQueue _new_eq)
inline

Definition at line 549 of file eventq.hh.

References curEventQueue(), EventQueue::lock(), new_eq, old_eq, and EventQueue::unlock().

EventQueue::ScopedMigration::~ScopedMigration ( )
inline

Definition at line 557 of file eventq.hh.

References curEventQueue(), EventQueue::lock(), new_eq, old_eq, and EventQueue::unlock().

Member Data Documentation

EventQueue& EventQueue::ScopedMigration::new_eq
private

Definition at line 565 of file eventq.hh.

Referenced by ScopedMigration(), and ~ScopedMigration().

EventQueue& EventQueue::ScopedMigration::old_eq
private

Definition at line 566 of file eventq.hh.

Referenced by ScopedMigration(), and ~ScopedMigration().


The documentation for this class was generated from the following file:

Generated on Fri Jun 9 2017 13:04:10 for gem5 by doxygen 1.8.6