summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs
diff options
context:
space:
mode:
authorcdgill <cdgill@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1999-07-06 19:17:07 +0000
committercdgill <cdgill@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1999-07-06 19:17:07 +0000
commitdf1baf478be35bf8ef31f8163d528d967d293f0d (patch)
treefa2e2dc115c53b5b1d84805ffc7900ca2cf5ff04 /TAO/orbsvcs
parentc51bce4f1cec67443d9cc353cabfd56bda8e2097 (diff)
downloadATCD-df1baf478be35bf8ef31f8163d528d967d293f0d.tar.gz
added missing template instantiations, fixed exception specification problems reported by Sun C++, OSF1 cxx.
Diffstat (limited to 'TAO/orbsvcs')
-rw-r--r--TAO/orbsvcs/Scheduling_Service/Scheduling_Service.cpp14
-rw-r--r--TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils.h7
-rw-r--r--TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.cpp14
-rw-r--r--TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.h10
4 files changed, 34 insertions, 11 deletions
diff --git a/TAO/orbsvcs/Scheduling_Service/Scheduling_Service.cpp b/TAO/orbsvcs/Scheduling_Service/Scheduling_Service.cpp
index d1339739f95..c9388cdbaba 100644
--- a/TAO/orbsvcs/Scheduling_Service/Scheduling_Service.cpp
+++ b/TAO/orbsvcs/Scheduling_Service/Scheduling_Service.cpp
@@ -298,12 +298,19 @@ int main (int argc, char *argv[])
#if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION)
#if (! defined (__GNUC__)) || (__GNUC__ > 2) || \
(__GNUC__ == 2 && defined (__GNUC_MINOR__) && __GNUC_MINOR__ >= 8)
+template class ACE_Equal_To<int>;
template class ACE_Hash_Map_Manager_Ex<int, RtecScheduler::Config_Info *, ACE_Hash<int>, ACE_Equal_To<int>, ACE_SYNCH_MUTEX>;
template class ACE_Hash_Map_Manager_Ex<int, RtecScheduler::Dependency_Set *, ACE_Hash<int>, ACE_Equal_To<int>, ACE_SYNCH_MUTEX>;
template class ACE_Hash_Map_Manager_Ex<int, RtecScheduler::RT_Info *, ACE_Hash<int>, ACE_Equal_To<int>, ACE_SYNCH_MUTEX>;
template class ACE_Hash_Map_Iterator_Base_Ex<int, RtecScheduler::Config_Info *, ACE_Hash<int>, ACE_Equal_To<int>, ACE_SYNCH_MUTEX>;
template class ACE_Hash_Map_Iterator_Base_Ex<int, RtecScheduler::Dependency_Set *, ACE_Hash<int>, ACE_Equal_To<int>, ACE_SYNCH_MUTEX>;
template class ACE_Hash_Map_Iterator_Base_Ex<int, RtecScheduler::RT_Info *, ACE_Hash<int>, ACE_Equal_To<int>, ACE_SYNCH_MUTEX>;
+template class ACE_Hash_Map_Iterator_Ex<int,RtecScheduler::Config_Info*,ACE_Hash<int>,ACE_Equal_To<int>,ACE_Thread_Mutex>;
+template class ACE_Hash_Map_Iterator_Ex<int,RtecScheduler::Dependency_Set*,ACE_Hash<int>,ACE_Equal_To<int>,ACE_Thread_Mutex>;
+template class ACE_Hash_Map_Iterator_Ex<int,RtecScheduler::RT_Info*,ACE_Hash<int>,ACE_Equal_To<int>,ACE_Thread_Mutex>;
+template class ACE_Hash_Map_Reverse_Iterator_Ex<int,RtecScheduler::Config_Info*,ACE_Hash<int>,ACE_Equal_To<int>,ACE_Thread_Mutex>;
+template class ACE_Hash_Map_Reverse_Iterator_Ex<int,RtecScheduler::Dependency_Set*,ACE_Hash<int>,ACE_Equal_To<int>,ACE_Thread_Mutex>;
+template class ACE_Hash_Map_Reverse_Iterator_Ex<int,RtecScheduler::RT_Info*,ACE_Hash<int>,ACE_Equal_To<int>,ACE_Thread_Mutex>;
template class ACE_Hash_Map_Entry<int, RtecScheduler::Config_Info *>;
template class ACE_Hash_Map_Entry<int, RtecScheduler::Dependency_Set *>;
template class ACE_Hash_Map_Entry<int, RtecScheduler::RT_Info *>;
@@ -323,12 +330,19 @@ template class TAO_RSE_Utilization_Visitor<TAO_MUF_Reconfig_Sched_Strategy>;
#elif defined(ACE_HAS_TEMPLATE_INSTANTIATION_PRAGMA)
#if (! defined (__GNUC__)) || (__GNUC__ > 2) || \
(__GNUC__ == 2 && defined (__GNUC_MINOR__) && __GNUC_MINOR__ >= 8)
+#pragma instantiate ACE_Equal_To<int>
#pragma instantiate ACE_Hash_Map_Manager_Ex<int, RtecScheduler::Config_Info *, ACE_Hash<int>, ACE_Equal_To<int>, ACE_SYNCH_MUTEX>
#pragma instantiate ACE_Hash_Map_Manager_Ex<int, RtecScheduler::Dependency_Set *, ACE_Hash<int>, ACE_Equal_To<int>, ACE_SYNCH_MUTEX>
#pragma instantiate ACE_Hash_Map_Manager_Ex<int, RtecScheduler::RT_Info *, ACE_Hash<int>, ACE_Equal_To<int>, ACE_SYNCH_MUTEX>
#pragma instantiate ACE_Hash_Map_Iterator_Base_Ex<int, RtecScheduler::Config_Info *, ACE_Hash<int>, ACE_Equal_To<int>, ACE_SYNCH_MUTEX>
#pragma instantiate ACE_Hash_Map_Iterator_Base_Ex<int, RtecScheduler::Dependency_Set *, ACE_Hash<int>, ACE_Equal_To<int>, ACE_SYNCH_MUTEX>
#pragma instantiate ACE_Hash_Map_Iterator_Base_Ex<int, RtecScheduler::RT_Info *, ACE_Hash<int>, ACE_Equal_To<int>, ACE_SYNCH_MUTEX>
+#pragma instantiate ACE_Hash_Map_Iterator_Ex<int,RtecScheduler::Config_Info*,ACE_Hash<int>,ACE_Equal_To<int>,ACE_Thread_Mutex>
+#pragma instantiate ACE_Hash_Map_Iterator_Ex<int,RtecScheduler::Dependency_Set*,ACE_Hash<int>,ACE_Equal_To<int>,ACE_Thread_Mutex>
+#pragma instantiate ACE_Hash_Map_Iterator_Ex<int,RtecScheduler::RT_Info*,ACE_Hash<int>,ACE_Equal_To<int>,ACE_Thread_Mutex>
+#pragma instantiate ACE_Hash_Map_Reverse_Iterator_Ex<int,RtecScheduler::Config_Info*,ACE_Hash<int>,ACE_Equal_To<int>,ACE_Thread_Mutex>
+#pragma instantiate ACE_Hash_Map_Reverse_Iterator_Ex<int,RtecScheduler::Dependency_Set*,ACE_Hash<int>,ACE_Equal_To<int>,ACE_Thread_Mutex>
+#pragma instantiate ACE_Hash_Map_Reverse_Iterator_Ex<int,RtecScheduler::RT_Info*,ACE_Hash<int>,ACE_Equal_To<int>,ACE_Thread_Mutex>
#pragma instantiate ACE_Hash_Map_Entry<int, RtecScheduler::Config_Info *>
#pragma instantiate ACE_Hash_Map_Entry<int, RtecScheduler::Dependency_Set *>
#pragma instantiate ACE_Hash_Map_Entry<int, RtecScheduler::RT_Info *>
diff --git a/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils.h b/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils.h
index 5efd23b6460..de8ef81c5bb 100644
--- a/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils.h
+++ b/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Sched_Utils.h
@@ -239,9 +239,10 @@ class TAO_ORBSVCS_Export TAO_MUF_Reconfig_Sched_Strategy
public:
static int total_priority_comp (const void *, const void *);
- // Ordering function used to qsort an array of TAO_Reconfig_Scheduler_Entry
- // pointers into a total <priority, subpriority> ordering. Returns -1 if the
- // first one is higher, 0 if they're the same, and 1 if the second one is higher.
+ // Ordering function used to qsort an array of
+ // TAO_Reconfig_Scheduler_Entry pointers into a total <priority,
+ // subpriority> ordering. Returns -1 if the first one is higher, 0
+ // if they're the same, and 1 if the second one is higher.
static int compare_priority (TAO_Reconfig_Scheduler_Entry &,
TAO_Reconfig_Scheduler_Entry &);
diff --git a/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.cpp b/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.cpp
index 2b4dcf9cc03..6e4c12e8198 100644
--- a/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.cpp
+++ b/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.cpp
@@ -432,7 +432,7 @@ set (RtecScheduler::handle_t handle,
// Test the utilization difference between the old and new values.
if ((sched_entry_ptr->orig_rt_info_data ().period != rt_info_ptr->period
- && sched_entry_ptr->orig_rt_info_data ().worst_case_execution_time
+ && sched_entry_ptr->orig_rt_info_data ().worst_case_execution_time
!= rt_info_ptr->worst_case_execution_time))
{
CORBA::Double orig_time = ACE_static_cast (
@@ -451,7 +451,7 @@ set (RtecScheduler::handle_t handle,
CORBA::Double new_period = ACE_static_cast (
CORBA::Double,
ACE_UINT64_DBLCAST_ADAPTER (rt_info_ptr->period));
-
+
if ((orig_time / orig_period) - (new_time / new_period) > DBL_EPSILON
|| (orig_time / orig_period) - (new_time / new_period) < DBL_EPSILON)
{
@@ -470,7 +470,7 @@ set (RtecScheduler::handle_t handle,
// If the period changed, look up the handle in the calling
// dependency map and see if there is anything there: if so,
// the propagation is unstable.
- if (sched_entry_ptr->orig_rt_info_data ().period
+ if (sched_entry_ptr->orig_rt_info_data ().period
!= rt_info_ptr->period)
{
// Get the dependency set for the current entry.
@@ -1117,7 +1117,8 @@ dfs_traverse_i (CORBA::Environment &ACE_TRY_ENV)
// Helper function to compare the DFS finish times of
// two task entries, so qsort orders these in topological
// order, with the higher times *first*
-extern "C" int
+template <class RECONFIG_SCHED_STRATEGY, class ACE_LOCK> int
+TAO_Reconfig_Scheduler<RECONFIG_SCHED_STRATEGY, ACE_LOCK>::
comp_entry_finish_times (const void *first, const void *second)
{
const TAO_Reconfig_Scheduler_Entry *first_entry =
@@ -1169,7 +1170,8 @@ detect_cycles_i (CORBA::Environment &ACE_TRY_ENV)
::qsort (ACE_reinterpret_cast (void *, entry_ptr_array_),
next_handle_,
sizeof (TAO_Reconfig_Scheduler_Entry *),
- comp_entry_finish_times);
+ ACE_reinterpret_cast (COMP_FUNC,
+ TAO_Reconfig_Scheduler::comp_entry_finish_times));
// Traverse entries in reverse topological order,
// looking for strongly connected components (cycles).
@@ -1254,7 +1256,7 @@ assign_priorities_i (CORBA::Environment &ACE_TRY_ENV)
TAO_RSE_Priority_Visitor<RECONFIG_SCHED_STRATEGY> prio_visitor;
for (int i = 0; i < this->next_handle_; ++i)
{
- int result = prio_visitor.visit (* (entry_ptr_array_ [i]));
+ int result = prio_visitor.visit (* (entry_ptr_array_ [i]));
if (result < 0)
{
// Something bad happened with the internal data structures.
diff --git a/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.h b/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.h
index 2a00105520a..88f02fcb032 100644
--- a/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.h
+++ b/TAO/orbsvcs/orbsvcs/Sched/Reconfig_Scheduler_T.h
@@ -32,7 +32,6 @@
template <class RECONFIG_SCHED_STRATEGY, class ACE_LOCK>
class TAO_Reconfig_Scheduler :
public POA_RtecScheduler::Scheduler
-{
// = TITLE
// A servant for RtecScheduler::Scheduler that can be initialized
// and run solely with precomputed scheduling information, but is also
@@ -47,6 +46,7 @@ class TAO_Reconfig_Scheduler :
// during schedule configuration, so that it can be used during
// both schedule configuration and run-time phases of operation.
//
+{
public:
TAO_Reconfig_Scheduler ();
@@ -326,6 +326,11 @@ protected:
// Traverses dependency graph, assigning a topological ordering.
// Resets DFS map entries, do DFS traversal, constructs DFS map.
+ static int comp_entry_finish_times (const void *first, const void *second);
+ // Helper function to compare the DFS finish times of
+ // two task entries, so qsort orders these in topological
+ // order, with the higher times *first*.
+
virtual void detect_cycles_i (CORBA::Environment &_env)
ACE_THROW_SPEC ((CORBA::SystemException,
RtecScheduler::INTERNAL,
@@ -342,7 +347,8 @@ protected:
virtual void assign_priorities_i (CORBA::Environment &_env)
ACE_THROW_SPEC ((CORBA::SystemException,
- RtecScheduler::INTERNAL));
+ RtecScheduler::INTERNAL,
+ RtecScheduler::DUPLICATE_NAME));
// Sort operations by urgency (done by strategy), then
// assign priorities and subpriorities in one pass.
// Sets last scheduled priority.