diff options
author | Abdullah Sowayan <sowayan@users.noreply.github.com> | 2007-08-18 01:19:30 +0000 |
---|---|---|
committer | Abdullah Sowayan <sowayan@users.noreply.github.com> | 2007-08-18 01:19:30 +0000 |
commit | aae108a0b97de02e1df38689af7d146dcf3a5314 (patch) | |
tree | 037e96b823e73caa0eb8c176d3c79e895b347736 /ACE/Kokyu | |
parent | b7e2938bc019c04689e44cd48fbdbcc276a017b4 (diff) | |
download | ATCD-aae108a0b97de02e1df38689af7d146dcf3a5314.tar.gz |
Sat Aug 18 01:16:11 UTC 2007 Abdullah Sowayan <abdullah.sowayan@lmco.com>
Diffstat (limited to 'ACE/Kokyu')
-rw-r--r-- | ACE/Kokyu/DSRT_Direct_Dispatcher_Impl_T.cpp | 2 | ||||
-rw-r--r-- | ACE/Kokyu/Dispatch_Deferrer.cpp | 18 | ||||
-rw-r--r-- | ACE/Kokyu/Dispatch_Deferrer.h | 20 | ||||
-rw-r--r-- | ACE/Kokyu/Kokyu_dsrt.h | 6 |
4 files changed, 23 insertions, 23 deletions
diff --git a/ACE/Kokyu/DSRT_Direct_Dispatcher_Impl_T.cpp b/ACE/Kokyu/DSRT_Direct_Dispatcher_Impl_T.cpp index 74eefa681dc..ebbea987c50 100644 --- a/ACE/Kokyu/DSRT_Direct_Dispatcher_Impl_T.cpp +++ b/ACE/Kokyu/DSRT_Direct_Dispatcher_Impl_T.cpp @@ -181,7 +181,7 @@ DSRT_Direct_Dispatcher_Impl<DSRT_Scheduler_Traits>::svc (void) this->curr_scheduled_thr_handle_ = most_eligible_thr_handle; this->curr_scheduled_guid_ = item_var->guid (); } - /*change all threads in blocked_prio_ to inactive_prio_*/ + /*change all threads in blocked_prio_ to inactive_prio_*/ this->ready_queue_.change_prio(this->blocked_prio_, this->inactive_prio_,this->sched_policy_); } diff --git a/ACE/Kokyu/Dispatch_Deferrer.cpp b/ACE/Kokyu/Dispatch_Deferrer.cpp index 0d62bb28c58..6db734c8205 100644 --- a/ACE/Kokyu/Dispatch_Deferrer.cpp +++ b/ACE/Kokyu/Dispatch_Deferrer.cpp @@ -40,14 +40,14 @@ Dispatch_Deferrer::dispatch (Dispatch_Queue_Item *qitem) ACE_Time_Value tv; tv = ACE_OS::gettimeofday() + qitem->qos_info().deadline_; long timer_id = this->react_.schedule_timer(this, - 0, //NULL arg - tv); + 0, //NULL arg + tv); if (timer_id < 0) { ACE_ERROR_RETURN ((LM_ERROR, - ACE_TEXT ("EC (%P|%t) cannot schedule Release Guard timer.") - ACE_TEXT ("ACE_Reactor.schedule_timer() returned -1\n")), - -1); + ACE_TEXT ("EC (%P|%t) cannot schedule Release Guard timer.") + ACE_TEXT ("ACE_Reactor.schedule_timer() returned -1\n")), + -1); } //else valid timer_id this->timers_.bind(qitem,timer_id); @@ -68,8 +68,8 @@ Dispatch_Deferrer::handle_timeout (const ACE_Time_Value &, //get all expired Dispatch_Queue_Items ACE_Message_Block *begin,*end; this->rgq_.remove_messages(begin,end, - (u_int) (ACE_Dynamic_Message_Strategy::LATE - | ACE_Dynamic_Message_Strategy::BEYOND_LATE)); + (u_int) (ACE_Dynamic_Message_Strategy::LATE | + ACE_Dynamic_Message_Strategy::BEYOND_LATE)); //dispatch them back to Dispatcher_Impl while (begin <= end) @@ -87,12 +87,12 @@ Dispatch_Deferrer::handle_timeout (const ACE_Time_Value &, //remove timer for each enqueued qitem from reactor long timer_id; if (this->timers_.find(qitem,timer_id) < 0) - { + { ACE_ERROR_RETURN ((LM_ERROR, ACE_TEXT ("Could not cancel Release Guard timer.") ACE_TEXT ("Unknown timer ID\n")), -1); - } + } //else got timer_id this->react_.cancel_timer(timer_id); diff --git a/ACE/Kokyu/Dispatch_Deferrer.h b/ACE/Kokyu/Dispatch_Deferrer.h index 6fb1a7322e0..6375ed1b865 100644 --- a/ACE/Kokyu/Dispatch_Deferrer.h +++ b/ACE/Kokyu/Dispatch_Deferrer.h @@ -47,21 +47,21 @@ class Dispatch_Deferrer : public ACE_Event_Handler public: Dispatch_Deferrer(); //Default constructor - + ~Dispatch_Deferrer(); //Destructor - + int init(const Dispatch_Deferrer_Attributes& attr); - + int dispatch (Dispatch_Queue_Item *qitem); - + virtual int handle_timeout (const ACE_Time_Value ¤t_time, - const void *act = 0); + const void *act = 0); //TODO: what if need higher resolution timers? - + private: ACE_Deadline_Message_Strategy msg_strat_; - + ///Stores the Dispatch_Commands in earliest-release-time order, ///until they are dispatched. I decided to use an ///ACE_Dynamic_Message_Queue because it supports deadline @@ -70,7 +70,7 @@ class Dispatch_Deferrer : public ACE_Event_Handler ///Default_Dispatcher_Impl rather than allocate some structure to ///hold the Dispatch_Command and QoSDescriptor. ACE_Dynamic_Message_Queue<ACE_SYNCH> rgq_; - + //Stores timer_ids from the Reactor (longs) using the //Dispatch_Queue_Item the timer is for as the key. Used to //cancel timers if they expire and are enqueued before the @@ -78,10 +78,10 @@ class Dispatch_Deferrer : public ACE_Event_Handler typedef ACE_Map_Manager<Dispatch_Queue_Item*,long,ACE_Thread_Mutex> Timer_Map; Timer_Map timers_; - + ///Manages timers for the Dispatch_Commands ACE_Reactor react_; - + Dispatcher_Task* task_; }; diff --git a/ACE/Kokyu/Kokyu_dsrt.h b/ACE/Kokyu/Kokyu_dsrt.h index 3ec48deaf86..c10d429e062 100644 --- a/ACE/Kokyu/Kokyu_dsrt.h +++ b/ACE/Kokyu/Kokyu_dsrt.h @@ -120,7 +120,7 @@ namespace Kokyu typedef typename QoSDesc::Importance_t Importance_t; int operator ()(const QoSDesc& qos1, - const QoSDesc& qos2); + const QoSDesc& qos2); }; /** @@ -137,7 +137,7 @@ namespace Kokyu typedef typename QoSDesc::Priority_t Priority_t; int operator ()(const QoSDesc& qos1, - const QoSDesc& qos2); + const QoSDesc& qos2); }; /** @@ -155,7 +155,7 @@ namespace Kokyu typedef typename QoSDesc::Time_t Time_t; int operator ()(const QoSDesc& qos1, - const QoSDesc& qos2); + const QoSDesc& qos2); }; |