summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs/orbsvcs/Sched
diff options
context:
space:
mode:
authorjtc <jtc@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2005-01-28 15:56:34 +0000
committerjtc <jtc@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2005-01-28 15:56:34 +0000
commit2ce338847db2d4fb2a398ab1aca6dfc56fdd3e97 (patch)
treeea3bf16505af6f1653b00cd354fcc1910e6db6df /TAO/orbsvcs/orbsvcs/Sched
parent905e4b711051a3f0003cd024d65af2f13d2d2c75 (diff)
downloadATCD-2ce338847db2d4fb2a398ab1aca6dfc56fdd3e97.tar.gz
ChangeLogTag: Fri Jan 28 07:53:34 2005 J.T. Conklin <jtc@acorntoolworks.com>
Diffstat (limited to 'TAO/orbsvcs/orbsvcs/Sched')
-rw-r--r--TAO/orbsvcs/orbsvcs/Sched/Config_Scheduler.cpp2
-rw-r--r--TAO/orbsvcs/orbsvcs/Sched/DynSched.cpp11
-rw-r--r--TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils.cpp48
-rw-r--r--TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils_T.cpp6
-rw-r--r--TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.cpp5
-rw-r--r--TAO/orbsvcs/orbsvcs/Sched/SchedEntry.i3
6 files changed, 26 insertions, 49 deletions
diff --git a/TAO/orbsvcs/orbsvcs/Sched/Config_Scheduler.cpp b/TAO/orbsvcs/orbsvcs/Sched/Config_Scheduler.cpp
index cc623085ad8..6eb207fbc6d 100644
--- a/TAO/orbsvcs/orbsvcs/Sched/Config_Scheduler.cpp
+++ b/TAO/orbsvcs/orbsvcs/Sched/Config_Scheduler.cpp
@@ -392,7 +392,7 @@ void ACE_Config_Scheduler::compute_scheduling (CORBA::Long minimum_priority,
{
case BaseSchedImplType::SUCCEEDED:
// We know that handles start at 1.
- infos[ACE_static_cast (CORBA::ULong, handle - 1)] = *rt_info;
+ infos[static_cast<CORBA::ULong> (handle - 1)] = *rt_info;
break;
case BaseSchedImplType::FAILED:
case BaseSchedImplType::ST_UNKNOWN_TASK:
diff --git a/TAO/orbsvcs/orbsvcs/Sched/DynSched.cpp b/TAO/orbsvcs/orbsvcs/Sched/DynSched.cpp
index e4d23988e30..b4bea6cb946 100644
--- a/TAO/orbsvcs/orbsvcs/Sched/DynSched.cpp
+++ b/TAO/orbsvcs/orbsvcs/Sched/DynSched.cpp
@@ -50,9 +50,9 @@ extern "C" int compare_entry_finish_times (const void *first, const void *second
}
const Task_Entry *first_entry =
- * ACE_static_cast (const Task_Entry *const *, first);
+ * static_cast<const Task_Entry *const *> (first);
const Task_Entry *second_entry =
- * ACE_static_cast (const Task_Entry *const *, second);
+ * static_cast<const Task_Entry *const *> (second);
// sort blank entries to the end
if (! first_entry)
@@ -1276,8 +1276,7 @@ ACE_DynScheduler::calculate_utilization_params (void)
(ordered_dispatch_entries_ [i]->task_entry ().effective_period () > 0))
{
utilization_ +=
- ACE_static_cast (double,
- ACE_UINT64_DBLCAST_ADAPTER (ordered_dispatch_entries_ [i]->
+ static_cast<double> (ACE_UINT64_DBLCAST_ADAPTER (ordered_dispatch_entries_ [i]->
task_entry ().rt_info ()->worst_case_execution_time)) /
static_cast<double> (ordered_dispatch_entries_ [i]->
task_entry ().effective_period ());
@@ -1380,9 +1379,7 @@ ACE_DynScheduler::setup_task_entries (void)
// stored magic cookie are the same (see the definition of
// ptrdiff_t in ACE to grok how this works portably).
task_entries_ [i].rt_info ()->volatile_token =
- ACE_static_cast (CORBA::ULongLong,
- ACE_reinterpret_cast (ptrdiff_t,
- &(task_entries_ [i])));
+ static_cast<CORBA::ULongLong> (reinterpret_cast<ptrdiff_t> (&(task_entries_ [i])));
// tie ordered task entry pointer to corresponding task entry
ordered_task_entries_ [i] = &(task_entries_ [i]);
diff --git a/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils.cpp b/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils.cpp
index 11449d2027e..3cbcdce2248 100644
--- a/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils.cpp
+++ b/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils.cpp
@@ -954,16 +954,14 @@ TAO_Reconfig_Sched_Strategy_Base::comp_tuple_finish_times (const void *first, co
// Convert the passed pointers: the double cast is needed to
// make Sun C++ 4.2 happy.
TAO_RT_Info_Tuple **first_tuple =
- ACE_reinterpret_cast (TAO_RT_Info_Tuple **,
- const_cast<void *> (first));
+ reinterpret_cast<TAO_RT_Info_Tuple **> (const_cast<void *> (first));
//volatile_token is a TAO_Reconfig_Scheduler_Entry*, but we need to treat it as a void*
void * first_entry = ACE_LONGLONG_TO_PTR (void *,
(*first_tuple)->volatile_token);
TAO_RT_Info_Tuple **second_tuple =
- ACE_reinterpret_cast (TAO_RT_Info_Tuple **,
- const_cast<void *> (second));
+ reinterpret_cast<TAO_RT_Info_Tuple **> (const_cast<void *> (second));
//volatile_token is a TAO_Reconfig_Scheduler_Entry*, but we need to treat it as a void*
void * second_entry = ACE_LONGLONG_TO_PTR (TAO_Reconfig_Scheduler_Entry *,
@@ -979,12 +977,10 @@ int
TAO_Reconfig_Sched_Strategy_Base::comp_entry_finish_times (const void *first, const void *second)
{
const TAO_Reconfig_Scheduler_Entry *first_entry =
- * ACE_reinterpret_cast (const TAO_Reconfig_Scheduler_Entry *const *,
- first);
+ * reinterpret_cast<const TAO_Reconfig_Scheduler_Entry *const *> (first);
const TAO_Reconfig_Scheduler_Entry *second_entry =
- * ACE_reinterpret_cast (const TAO_Reconfig_Scheduler_Entry *const *,
- second);
+ * reinterpret_cast<const TAO_Reconfig_Scheduler_Entry *const *> (second);
// sort blank entries to the end
if (! first_entry)
@@ -1108,11 +1104,9 @@ TAO_MUF_FAIR_Reconfig_Sched_Strategy::total_priority_comp (const void *s, const
// Convert the passed pointers: the double cast is needed to
// make Sun C++ 4.2 happy.
TAO_Reconfig_Scheduler_Entry **first =
- ACE_reinterpret_cast (TAO_Reconfig_Scheduler_Entry **,
- const_cast<void *> (s));
+ reinterpret_cast<TAO_Reconfig_Scheduler_Entry **> (const_cast<void *> (s));
TAO_Reconfig_Scheduler_Entry **second =
- ACE_reinterpret_cast (TAO_Reconfig_Scheduler_Entry **,
- const_cast<void *> (t));
+ reinterpret_cast<TAO_Reconfig_Scheduler_Entry **> (const_cast<void *> (t));
// Check the converted pointers.
if (first == 0 || *first == 0)
@@ -1163,16 +1157,14 @@ TAO_MUF_FAIR_Reconfig_Sched_Strategy::total_admission_comp (const void *s,
// Convert the passed pointers: the double cast is needed to
// make Sun C++ 4.2 happy.
TAO_RT_Info_Tuple **first =
- ACE_reinterpret_cast (TAO_RT_Info_Tuple **,
- const_cast<void *> (s));
+ reinterpret_cast<TAO_RT_Info_Tuple **> (const_cast<void *> (s));
TAO_Reconfig_Scheduler_Entry * first_entry =
ACE_LONGLONG_TO_PTR (TAO_Reconfig_Scheduler_Entry *,
(*first)->volatile_token);
TAO_RT_Info_Tuple **second =
- ACE_reinterpret_cast (TAO_RT_Info_Tuple **,
- const_cast<void *> (t));
+ reinterpret_cast<TAO_RT_Info_Tuple **> (const_cast<void *> (t));
TAO_Reconfig_Scheduler_Entry * second_entry =
ACE_LONGLONG_TO_PTR (TAO_Reconfig_Scheduler_Entry *,
@@ -1312,11 +1304,9 @@ TAO_RMS_FAIR_Reconfig_Sched_Strategy::total_priority_comp (const void *s, const
// Convert the passed pointers: the double cast is needed to
// make Sun C++ 4.2 happy.
TAO_Reconfig_Scheduler_Entry **first =
- ACE_reinterpret_cast (TAO_Reconfig_Scheduler_Entry **,
- const_cast<void *> (s));
+ reinterpret_cast<TAO_Reconfig_Scheduler_Entry **> (const_cast<void *> (s));
TAO_Reconfig_Scheduler_Entry **second =
- ACE_reinterpret_cast (TAO_Reconfig_Scheduler_Entry **,
- const_cast<void *> (t));
+ reinterpret_cast<TAO_Reconfig_Scheduler_Entry **> (const_cast<void *> (t));
// Check the converted pointers.
if (first == 0 || *first == 0)
@@ -1370,16 +1360,14 @@ TAO_RMS_FAIR_Reconfig_Sched_Strategy::total_admission_comp (const void *s,
// Convert the passed pointers: the double cast is needed to
// make Sun C++ 4.2 happy.
TAO_RT_Info_Tuple **first =
- ACE_reinterpret_cast (TAO_RT_Info_Tuple **,
- const_cast<void *> (s));
+ reinterpret_cast<TAO_RT_Info_Tuple **> (const_cast<void *> (s));
TAO_Reconfig_Scheduler_Entry * first_entry =
ACE_LONGLONG_TO_PTR (TAO_Reconfig_Scheduler_Entry *,
(*first)->volatile_token);
TAO_RT_Info_Tuple **second =
- ACE_reinterpret_cast (TAO_RT_Info_Tuple **,
- const_cast<void *> (t));
+ reinterpret_cast<TAO_RT_Info_Tuple **> (const_cast<void *> (t));
TAO_Reconfig_Scheduler_Entry * second_entry =
ACE_LONGLONG_TO_PTR (TAO_Reconfig_Scheduler_Entry *,
@@ -1542,11 +1530,9 @@ TAO_RMS_MLF_Reconfig_Sched_Strategy::total_priority_comp (const void *s, const v
// Convert the passed pointers: the double cast is needed to
// make Sun C++ 4.2 happy.
TAO_Reconfig_Scheduler_Entry **first =
- ACE_reinterpret_cast (TAO_Reconfig_Scheduler_Entry **,
- const_cast<void *> (s));
+ reinterpret_cast<TAO_Reconfig_Scheduler_Entry **> (const_cast<void *> (s));
TAO_Reconfig_Scheduler_Entry **second =
- ACE_reinterpret_cast (TAO_Reconfig_Scheduler_Entry **,
- const_cast<void *> (t));
+ reinterpret_cast<TAO_Reconfig_Scheduler_Entry **> (const_cast<void *> (t));
// Check the converted pointers.
if (first == 0 || *first == 0)
@@ -1600,16 +1586,14 @@ TAO_RMS_MLF_Reconfig_Sched_Strategy::total_admission_comp (const void *s,
// Convert the passed pointers: the double cast is needed to
// make Sun C++ 4.2 happy.
TAO_RT_Info_Tuple **first =
- ACE_reinterpret_cast (TAO_RT_Info_Tuple **,
- const_cast<void *> (s));
+ reinterpret_cast<TAO_RT_Info_Tuple **> (const_cast<void *> (s));
TAO_Reconfig_Scheduler_Entry * first_entry =
ACE_LONGLONG_TO_PTR (TAO_Reconfig_Scheduler_Entry *,
(*first)->volatile_token);
TAO_RT_Info_Tuple **second =
- ACE_reinterpret_cast (TAO_RT_Info_Tuple **,
- const_cast<void *> (t));
+ reinterpret_cast<TAO_RT_Info_Tuple **> (const_cast<void *> (t));
TAO_Reconfig_Scheduler_Entry * second_entry =
ACE_LONGLONG_TO_PTR (TAO_Reconfig_Scheduler_Entry *,
diff --git a/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils_T.cpp b/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils_T.cpp
index a13c79c53d8..d6c0fc79eee 100644
--- a/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils_T.cpp
+++ b/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils_T.cpp
@@ -947,8 +947,7 @@ TAO_Tuple_Admission_Visitor<RECONFIG_SCHED_STRATEGY>::visit (TAO_RT_Info_Tuple &
// Compute the current tuple's utilization.
CORBA::Double delta_utilization =
(static_cast<CORBA::Double> (t.threads)
- * ACE_static_cast (CORBA::Double,
- ACE_UINT64_DBLCAST_ADAPTER (entry->
+ * static_cast<CORBA::Double> (ACE_UINT64_DBLCAST_ADAPTER (entry->
aggregate_exec_time ())))
/ static_cast<CORBA::Double> (t.period);
@@ -957,8 +956,7 @@ TAO_Tuple_Admission_Visitor<RECONFIG_SCHED_STRATEGY>::visit (TAO_RT_Info_Tuple &
{
delta_utilization -=
(static_cast<CORBA::Double> (entry->current_admitted_tuple ()->threads)
- * ACE_static_cast (CORBA::Double,
- ACE_UINT64_DBLCAST_ADAPTER (entry->
+ * static_cast<CORBA::Double> (ACE_UINT64_DBLCAST_ADAPTER (entry->
aggregate_exec_time ())))
/ static_cast<CORBA::Double> (entry->current_admitted_tuple ()->period);
}
diff --git a/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.cpp b/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.cpp
index cb2144fbd02..5dc08986705 100644
--- a/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.cpp
+++ b/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.cpp
@@ -1490,7 +1490,7 @@ get_rt_info_set (RtecScheduler::RT_Info_Set_out infos
{
// TODO - rethink this: is it more useful to only return the *enabled* RT_Infos?
rt_info = (*info_iter).int_id_;
- infos[ACE_static_cast (CORBA::ULong, rt_info->handle - 1)] = *rt_info;
+ infos[static_cast<CORBA::ULong> (rt_info->handle - 1)] = *rt_info;
}
return;
@@ -1813,8 +1813,7 @@ create_i (const char *entry_point,
// Connect the entry to the RT_Info.
new_rt_info->volatile_token =
- ACE_static_cast (CORBA::ULongLong,
- reinterpret_cast<ptrdiff_t> (new_sched_entry));
+ static_cast<CORBA::ULongLong> (reinterpret_cast<ptrdiff_t> (new_sched_entry));
// With everything safely registered in the map and tree, just
// update the next handle and info counter and return the new info.
diff --git a/TAO/orbsvcs/orbsvcs/Sched/SchedEntry.i b/TAO/orbsvcs/orbsvcs/Sched/SchedEntry.i
index f3640e8a829..f133d00e95f 100644
--- a/TAO/orbsvcs/orbsvcs/Sched/SchedEntry.i
+++ b/TAO/orbsvcs/orbsvcs/Sched/SchedEntry.i
@@ -177,8 +177,7 @@ Task_Entry::effective_execution_time () const
return ((rt_info_->info_type == RtecScheduler::OPERATION) ||
(rt_info_->info_type == RtecScheduler::REMOTE_DEPENDANT))
- ? ACE_static_cast (u_long,
- worst_case_execution_time * dispatches_.size ())
+ ? static_cast<u_long> (worst_case_execution_time * dispatches_.size ())
: 0;
}