------------------------------------------------------------------------------ ------------------------------------------------------------------------------ -- Cheddar is a GNU GPL real time scheduling analysis tool. -- This program provides services to automatically check performances -- of real time architectures. -- -- Copyright (C) 2002-2010, by Frank Singhoff, Alain Plantec, Jerome Legrand -- -- The Cheddar project was started in 2002 by -- the LISyC Team, University of Western Britanny. -- -- Since 2008, Ellidiss technologies also contributes to the development of -- Cheddar and provides industrial support. -- -- This program is free software; you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation; either version 2 of the License, or -- (at your option) any later version. -- -- This program is distributed in the hope that it will be useful, -- but WITHOUT ANY WARRANTY; without even the implied warranty of -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- GNU General Public License for more details. -- -- You should have received a copy of the GNU General Public License -- along with this program; if not, write to the Free Software -- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA -- -- -- Contact : cheddar@listes.univ-brest.fr -- ----------------------------------------------------------------------------- -- Last update : -- $Rev: 523 $ -- $Date: 2012-09-26 15:09:39 +0200 (Wed, 26 Sep 2012) $ -- $Author: fotsing $ ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ with Xml_Tag; use Xml_Tag; with Scheduling_Analysis.extended; use Scheduling_Analysis.extended; with Scheduler.Fixed_Priority; use Scheduler.Fixed_Priority; with Scheduler.Fixed_Priority.Dm; use Scheduler.Fixed_Priority.Dm; with Scheduler.Fixed_Priority.Rm; use Scheduler.Fixed_Priority.Rm; with double_util; use double_util; with Translate; use Translate; with Tasks; use Tasks; with Event_Analyzers; use Event_Analyzers; with Event_Analyzer_Set; use Event_Analyzer_Set; use Event_Analyzer_Set.Generic_Event_Analyzer_Set; with Ada.Numerics.Aux; use Ada.Numerics.Aux; with unbounded_strings; use unbounded_strings; with Scheduling_Analysis; use Scheduling_Analysis; with GNAT.Current_Exception; use GNAT.Current_Exception; with Expressions; use Expressions; with Framework_Config; use Framework_Config; with Time_Unit_Events; use Time_Unit_Events; with Multiprocessor_Services; use Multiprocessor_Services; with partitioning_Services; use partitioning_Services; with Debug; use Debug; with Processors.extended; use Processors.extended; with framework; use framework; with feasibility_test.processor_utilization; use feasibility_test.processor_utilization; with feasibility_test.feasibility_interval; use feasibility_test.feasibility_interval; package body Call_Scheduling_Framework is procedure Compute_Simulation_Time_Line (Sys : in out System; Result : in out Unbounded_String; Period : in Natural; Schedule_With_Offsets : in Boolean; Schedule_With_Precedencies : in Boolean; Schedule_With_Resources : in Boolean; With_Task_Specific_Seed : in Boolean := True; Global_Seed_Value : in Integer := 0; Predictable_Global_Seed : in Boolean := True; Event_To_Generate : in Time_Unit_Event_Type_Boolean_Table; Output : in Output_Format := String_Output) is begin Put_Debug ("Call Compute_Simulation_Time_Line"); sort (Sys.Tasks, Increasing_Name'Access); Scheduling_Base_Period := Period; initialize (Sched.all); Build_Multiprocessor_Scheduling (Sys, Sched, Event_To_Generate, Period, Schedule_With_Offsets, Schedule_With_Precedencies, Schedule_With_Resources, With_Task_Specific_Seed, Global_Seed_Value, Predictable_Global_Seed); exception when Exit_Statement_Exception => Result := Result & Lb_Minus & Lb_Simulation_warning (Current_Language) & Exception_Message & unbounded_lf; when Parametric_File_Error => Result := Result & Lb_Minus & Lb_Simulation_Error (Current_Language) & Lb_Parametric_File_Error (Current_Language) & Lb_Comma & Exception_Message & unbounded_lf; when Type_Error => Result := Result & Lb_Minus & Lb_Simulation_Error (Current_Language) & Lb_Type_Error (Current_Language) & Lb_Comma & Exception_Message & unbounded_lf; when Statement_Error => Result := Result & Lb_Minus & Lb_Simulation_Error (Current_Language) & Lb_Statement_Error (Current_Language) & Lb_Comma & Exception_Message & unbounded_lf; when Variable_Error => Result := Result & Lb_Minus & Lb_Simulation_Error (Current_Language) & Lb_Variable_Error (Current_Language) & Lb_Comma & Exception_Message & unbounded_lf; when Syntax_Error => Result := Result & Lb_Minus & Lb_Simulation_Error (Current_Language) & Lb_Syntax_Error (Current_Language) & Lb_Comma & Exception_Message & unbounded_lf; when Time_Unit_Package.indexed_table_full => Result := Result & Lb_Compute_Scheduling_Error_22 (Current_Language) & unbounded_lf; initialize (Sched.all); end Compute_Simulation_Time_Line; procedure Compute_Simulation_Basics (Sys : in System; Result : in out Unbounded_String; A_Processor : in Generic_Processor_Ptr; Output : in Output_Format := String_Output) is Check : Unbounded_String; begin Put_Debug ("Call Compute_Simulation_Basics"); Check := empty_string; Compute_Simulation_Number_Of_Context_Switch (Sys, Check, A_Processor, Output); Result := Result & Check; Check := empty_string; Compute_Simulation_Number_Of_Preemption (Sys, Check, A_Processor, Output); Result := Result & Check; Check := empty_string; Compute_Simulation_Response_Time (Sys, Check, A_Processor, True, False, False, Output); Result := Result & unbounded_lf & Check & unbounded_lf; end Compute_Simulation_Basics; procedure Compute_Simulation_Number_Of_Context_Switch (Sys : in System; Result : in out Unbounded_String; A_Processor : in Generic_Processor_Ptr; Output : in Output_Format := String_Output) is Nb : Natural := 0; begin Put_Debug ("Call Compute_Simulation_Number_Of_Context_Switch"); if Output = Xml_Output then Set_Tag; else Set_Empty; end if; for J in 0 .. Sched.nb_entries - 1 loop if Sched.entries (J).item.name = A_Processor.name then if Sched.entries (J).data.error_msg /= empty_string then Result := Result & Sched.entries (J).data.error_msg & unbounded_lf; else Nb := Number_Of_Switch_Context_From_Simulation (Sched.entries (J).data.result); Result := Result & Start_Line & Lb_Minus & Lb_Number_Of_Context_Switch (Current_Language) & Lb_Colon & Start_Num_Of_Context_Switch & Nb'Img & End_Num_Of_Context_Switch & End_Line & unbounded_lf; end if; end if; end loop; end Compute_Simulation_Number_Of_Context_Switch; procedure Compute_Simulation_Number_Of_Preemption (Sys : in System; Result : in out Unbounded_String; A_Processor : in Generic_Processor_Ptr; Output : in Output_Format := String_Output) is Nb : Natural := 0; begin Put_Debug ("Call Compute_Simulation_Number_Of_Preemption"); if Output = Xml_Output then Set_Tag; else Set_Empty; end if; for J in 0 .. Sched.nb_entries - 1 loop if Sched.entries (J).item.name = A_Processor.name then if Sched.entries (J).data.error_msg /= empty_string then Result := Result & Sched.entries (J).data.error_msg & unbounded_lf; else Nb := Number_Of_Preemption_From_Simulation (Sched.entries (J).data.result, Sys.Tasks); Result := Result & Sched.entries (J).data.scheduling_msg; Result := Result & Start_Line & Lb_Minus & Lb_Number_Of_Preemption (Current_Language) & Lb_Colon & Start_Num_Of_Preemp & Nb'Img & End_Num_Of_Preemp & End_Line & unbounded_lf; end if; end if; end loop; end Compute_Simulation_Number_Of_Preemption; procedure Compute_Simulation_Response_Time (Sys : in System; Result : in out Unbounded_String; A_Processor : in Generic_Processor_Ptr; Worst_Case : Boolean; Best_Case : Boolean; Average_Case : Boolean; Output : in Output_Format := String_Output) is Check : Unbounded_String := empty_string; A_Task : Generic_Task_Ptr; My_Iterator : Tasks_Iterator; Min : Natural := 0; Max : Natural := 0; Average : Double := 0.0; Missed : Boolean := False; begin Put_Debug ("Call Compute_Simulation_Response_Time"); for J in 0 .. Sched.nb_entries - 1 loop if Sched.entries (J).item.name = A_Processor.name then if Get_Number_Of_Task_From_Processor (Sys.Tasks, A_Processor.name) > 0 then Result := Lb_Minus & Lb_Task_Response_Time_From_Simulation ( Current_Language) & Lb_Colon & unbounded_lf; reset_iterator (Sys.Tasks, My_Iterator); loop current_element (Sys.Tasks, A_Task, My_Iterator); Check := empty_string; if (A_Processor.name = A_Task.cpu_name) then Response_Time_By_Simulation (A_Task, Sched.entries (J).data.result, Check, Max, Min, Average); Result := Result & Start_Task & To_Unbounded_String (" ") & A_Task.name & To_Unbounded_String (" =>"); if Worst_Case then Result := Result & Max'Img & To_Unbounded_String ("/worst "); end if; if Best_Case then Result := Result & Min'Img & To_Unbounded_String ("/best "); end if; if Average_Case then Result := Result & format (Average) & To_Unbounded_String ("/average "); end if; if (Worst_Case) and (Max = 0) then Result := Result & Lb_Comma & lb_task_is_not_over_response_time_is_not_computed (Current_Language); end if; Result := Result & Check & unbounded_lf; if Check /= empty_string then Missed := True; end if; end if; exit when is_last_element (Sys.Tasks, My_Iterator); next_element (Sys.Tasks, My_Iterator); end loop; end if; end if; end loop; if Missed = False then Result := Result & Lb_No_Deadline_Missed_In_The_Computed_Scheduling ( Current_Language) & unbounded_lf; else Result := Result & Lb_Deadline_Will_Be_Missed_Task_Are_Not_Schedulable ( Current_Language) & unbounded_lf; end if; end Compute_Simulation_Response_Time; procedure Compute_Feasibility_Period (Sys : in System; Result : in out Unbounded_String; A_Processor : in Generic_Processor_Ptr; Output : in Output_Format := String_Output) is Period_String : Unbounded_String; Free_Ut_String : Unbounded_String; Period : Double := 0.0; Util : Double := 0.0; Free_Ut : Double := 0.0; begin Put_Debug ("Call Compute_Feasibility_Period"); if Output = Xml_Output then Set_Tag; else Set_Empty; end if; begin Period := Scheduling_Period (Sys.Tasks, A_Processor.name); exception -- A large task set with many different period values can lead to -- a CONSTRAINT_ERROR exception due to type overflow -- This "Scheduling Period" is computed with the help of a "big -- number" package. If you want to increase the accurrancy of this -- computation, increase Max_Big_Number_Size in config/config.ads -- when others => null; end; if Period > Double (Natural'Last) then Period_String := To_Unbounded_String (Double'Image (Period)); else Period_String := To_Unbounded_String (Natural'Image (Natural (Period))); end if; Result := Result & Start_Line & Lb_Scheduling_Period (Current_Language) & Start_Bas_Per & Period_String & End_Bas_Per & Start_Ref & To_Unbounded_String (" (") & Lb_See (Current_Language) & To_Unbounded_String ("[18], page 5). ") & End_Ref & End_Line & unbounded_lf; Util := Processor_Utilization_Over_Period (Sys.Tasks, A_Processor.name); Free_Ut := Period * (1.0 - Util); Free_Ut := Double'Max (0.0, Free_Ut); if Free_Ut > Double (Natural'Last) then Free_Ut_String := To_Unbounded_String (Double'Image (Free_Ut)); else Free_Ut_String := To_Unbounded_String (Natural'Image (Natural (Free_Ut))); end if; Result := Result & Start_Line & To_Unbounded_String ("-") & Start_Unit & Free_Ut_String & End_Unit & Lb_Free_Unit_Time (Current_Language) & End_Line & unbounded_lf; exception when Task_Set.Task_Must_Be_Periodic => Result := Result & Lb_Compute_Scheduling_Error_2 (Current_Language) & unbounded_lf; when Task_Set.Task_Model_Error => Result := Result & Lb_Compute_Scheduling_Error_3 (Current_Language) & unbounded_lf; end Compute_Feasibility_Period; procedure Compute_Feasibility_Processor_Utilization_Factor (Sys : in System; Result : in out Unbounded_String; A_Processor : in Generic_Processor_Ptr; Output : in Output_Format := String_Output) is Util : Double; Utildi : Double; begin Put_Debug ("Call Compute_Feasibility_Processor_Utilization_Factor"); if Output = Xml_Output then Set_Tag; else Set_Empty; end if; Result := Result & Lb_Feasibility_Number1 (Current_Language) & unbounded_lf & unbounded_lf; Compute_Feasibility_Period (Sys, Result, A_Processor, Output); begin Utildi := Processor_Utilization_Over_Deadline (Sys.Tasks, A_Processor.name); Result := Result & Start_Line & Lb_Utilization_With_Deadline (Current_Language) & Start_Deadl_Fact & format (Utildi) & End_Deadl_Fact & Start_Ref & To_Unbounded_String (" (") & Lb_See (Current_Language) & To_Unbounded_String ("[1], page 6). ") & End_Ref & End_Line & unbounded_lf; exception when Task_Set.Task_Must_Be_Periodic => Result := Result & Lb_Compute_Scheduling_Error_9 (Current_Language) & unbounded_lf; when Task_Set.Task_Model_Error => Result := Result & Lb_Compute_Scheduling_Error_10 (Current_Language) & unbounded_lf; when Deadline_Error => Result := Result & Lb_Compute_Scheduling_Error_21 (Current_Language) & unbounded_lf; end; begin Util := Processor_Utilization_Over_Period (Sys.Tasks, A_Processor.name); Result := Result & Start_Line & Lb_Utilization_With_Period (Current_Language) & Start_Per_Fact & format (Util) & End_Per_Fact & Start_Ref & To_Unbounded_String (" (") & Lb_See (Current_Language) & To_Unbounded_String ("[1], page 6). ") & End_Ref & unbounded_lf; exception when Task_Set.Task_Must_Be_Periodic => Result := Result & Lb_Compute_Scheduling_Error_9 (Current_Language) & unbounded_lf; when Task_Set.Task_Model_Error => Result := Result & Lb_Compute_Scheduling_Error_10 (Current_Language) & unbounded_lf; end; begin Result := Result & Start_Line; Utilization_Factor_Feasibility_Test ( extended_Core_Unit_Ptr (get_a_core(A_Processor)). scheduler.all, Sys.Tasks, A_Processor.name, Result); exception when Task_Set.Task_Must_Be_Periodic => Result := Result & Lb_Compute_Scheduling_Error_9 (Current_Language) & unbounded_lf; when Task_Set.Task_Model_Error => Result := Result & Lb_Compute_Scheduling_Error_10 (Current_Language) & unbounded_lf; when Deadline_Error => Result := Result & Lb_Compute_Scheduling_Error_21 (Current_Language) & unbounded_lf; when Task_Set.Start_Time_Error => Result := Result & Lb_Compute_Scheduling_Error_23 (Current_Language) & unbounded_lf; when Task_Set.Offset_Error => Result := Result & Lb_Compute_Scheduling_Error_24 (Current_Language) & unbounded_lf; end; end Compute_Feasibility_Processor_Utilization_Factor; procedure Compute_feasibility_test_by_name (Sys : in System; Result : in out Unbounded_String; A_Processor : in Generic_Processor_Ptr; test_name : unbounded_string; Output : in Output_Format := String_Output) is begin Put_Debug ("Call Compute_Feasibility_Test_By_Name"); if Output = Xml_Output then Set_Tag; else Set_Empty; end if; Result := Result & unbounded_lf ; end Compute_feasibility_test_by_name; procedure Compute_Feasibility_Response_Time (Sys : in out System; Result : in out Unbounded_String; A_Processor : in Generic_Processor_Ptr; Output : in Output_Format := String_Output) is Rt : Response_Time_Table; Msg : Unbounded_String := empty_string; Missed : Boolean := False; begin Put_Debug ("Call Compute_Feasibility_Response_Time"); if Output = Xml_Output then Set_Tag; else Set_Empty; end if; Result := Result & unbounded_lf & Lb_Feasibility_Number2 (Current_Language) & unbounded_lf & unbounded_lf; Compute_Response_Time ( extended_Core_Unit_Ptr (get_a_core(A_Processor)). scheduler.all, Sys.Tasks, A_Processor.name, Msg, Rt); Result := Result & Start_Line & Lb_Minus & Lb_Bound_On_Task_Response_Time (Current_Language) & Lb_Colon & Start_Ref & Msg & End_Ref & unbounded_lf; for I in 0 .. Response_Time_Range (Get_Number_Of_Task_From_Processor (Sys.Tasks, A_Processor.name) - 1) loop if (Rt.entries (I).item /= null) then Result := Result & Start_Task & To_Unbounded_String (" ") & Rt.entries (I).item.name & To_Unbounded_String (" =>") & Integer'Image (Integer (Rt.entries (I).data)) & End_Task; if (Natural (Rt.entries (I).data) > Rt.entries (I).item.deadline) then Result := Result & Lb_Comma & Lb_Check_Deadline (Current_Language) & Rt.entries (I).item.deadline'Img & To_Unbounded_String (")"); Missed := True; end if; Result := Result & unbounded_lf; end if; end loop; if Missed = False then Result := Result & Lb_No_Deadline_Will_Be_Missed_Task_Are_Schedulable ( Current_Language); else Result := Result & Lb_Deadline_Will_Be_Missed_Task_Are_Not_Schedulable ( Current_Language); end if; Result := Result & End_Line & unbounded_lf & End_Sched_Feas & unbounded_lf; exception when Task_Set.Task_Must_Have_Period_Equal_To_Deadline => Result := Result & Lb_Compute_Scheduling_Error_4 (Current_Language) & unbounded_lf; when Task_Set.Task_Must_Be_Periodic => Result := Result & Lb_Compute_Scheduling_Error_5 (Current_Language) & unbounded_lf; when Task_Set.Task_Model_Error => Result := Result & Lb_Compute_Scheduling_Error_6 (Current_Language) & unbounded_lf; when Scheduler.Processor_Utilization_Exceeded => Result := Result & Lb_Compute_Scheduling_Error_7 (Current_Language) & unbounded_lf; when Task_Set.Start_Time_Error => Result := Result & Lb_Compute_Scheduling_Error_12 (Current_Language) & unbounded_lf; when Task_Set.Offset_Error => Result := Result & Lb_Compute_Scheduling_Error_13 (Current_Language) & unbounded_lf; when Invalid_Scheduler => Result := Result & Lb_Compute_Scheduling_Error_18 (Current_Language) & unbounded_lf; end Compute_Feasibility_Response_Time; procedure Set_Priorities (Sys : in out System; Result : in out Unbounded_String; A_Processor : in Generic_Processor_Ptr; A_Scheduler : in Schedulers_Type; Output : in Output_Format := String_Output) is A_Rm_Scheduler : Rm_Scheduler; A_Dm_Scheduler : Dm_Scheduler; Ok : Boolean := True; error_msg : unbounded_string; A_Task : Generic_Task_Ptr; My_Task_Iterator : Tasks_Iterator; begin Put_Debug ("Call Set_Priorities"); if Output = Xml_Output then Set_Tag; else Set_Empty; end if; begin if (A_Scheduler = Rate_Monotonic_Protocol) then Set_Priority_According_To_Rm (A_Rm_Scheduler, Sys.Tasks, A_Processor.name); else Set_Priority_According_To_Dm (A_Dm_Scheduler, Sys.Tasks, A_Processor.name); end if; exception when Task_Set.Task_Must_Be_Periodic => Ok := False; error_msg:=Lb_priorities_error1(current_language); when Generic_Task_Set.empty_set => Ok := False; error_msg:=Lb_priorities_error2(current_language); end; if Ok then if (A_Scheduler = Rate_Monotonic_Protocol) then Result := Result & Start_Line & Lb_Set_Priorities_Rm (Current_Language) & End_Line; else Result := Result & Start_Line & Lb_Set_Priorities_Dm (Current_Language) & End_Line; end if; Result := Result & unbounded_lf & Start_Line & Lb_Priorities (Current_Language); reset_iterator (Sys.Tasks, My_Task_Iterator); loop current_element (Sys.Tasks, A_Task, My_Task_Iterator); if (A_Task.cpu_name = A_Processor.name) then Result := Result & unbounded_lf & Start_Task & To_Unbounded_String (" ") & A_Task.name & To_Unbounded_String (" =>") & To_Unbounded_String (A_Task.priority'Img) & End_Task; end if; exit when is_last_element (Sys.Tasks, My_Task_Iterator); next_element (Sys.Tasks, My_Task_Iterator); end loop; Result := Result & unbounded_lf & End_Line & unbounded_lf & End_Set_Prio; else Result := Result & error_msg; end if; end Set_Priorities; procedure Run_User_Defined_Event_Handlers (Sys : in System; Result : in out Unbounded_String; Output : in Output_Format := String_Output) is Msg : Unbounded_String; My_Iterator : Event_Analyzers_Iterator; An_Event_Analyzer : Event_Analyzer_Ptr; begin Put_Debug ("Call Run_User_Defined_Event_Handlers"); if Output = Xml_Output then Set_Tag; else Set_Empty; end if; if (get_number_of_elements (Sys.Event_Analyzers) > 0) then reset_iterator (Sys.Event_Analyzers, My_Iterator); loop current_element (Sys.Event_Analyzers, An_Event_Analyzer, My_Iterator); -- Run an event analyzer --- begin Msg := empty_string; Result := Result & unbounded_lf & unbounded_lf; Result := Result & Lb_Minus & Lb_Event_Analyzer_Name (Current_Language) & Lb_Colon & An_Event_Analyzer.event_analyzer_source_file_name & unbounded_lf & unbounded_lf; Run_An_Event_Analyzer (Sys, Sched, An_Event_Analyzer, Msg); Result := Result & Msg; Result := Result & unbounded_lf & unbounded_lf; exception when Parametric_File_Error => Result := Result & Lb_Minus & Lb_Simulation_Error (Current_Language) & Lb_Parametric_File_Error (Current_Language) & Lb_Comma & Exception_Message & unbounded_lf; when Type_Error => Result := Result & Lb_Minus & Lb_Simulation_Error (Current_Language) & Lb_Type_Error (Current_Language) & Lb_Comma & Exception_Message & unbounded_lf; when Statement_Error => Result := Result & Lb_Minus & Lb_Simulation_Error (Current_Language) & Lb_Statement_Error (Current_Language) & Lb_Comma & Exception_Message & unbounded_lf; when Variable_Error => Result := Result & Lb_Minus & Lb_Simulation_Error (Current_Language) & Lb_Variable_Error (Current_Language) & Lb_Comma & Exception_Message & unbounded_lf; when Syntax_Error => Result := Result & Lb_Minus & Lb_Simulation_Error (Current_Language) & Lb_Syntax_Error (Current_Language) & Lb_Comma & Exception_Message & unbounded_lf; end; exit when is_last_element (Sys.Event_Analyzers, My_Iterator); next_element (Sys.Event_Analyzers, My_Iterator); end loop; end if; end Run_User_Defined_Event_Handlers; procedure Partionning_Tasks (Sys : in out System; Result : in out Unbounded_String; A_Parition_Rule : in Partioning_Type; Output : in Output_Format := String_Output) is Partitionned_Task_Set : Tasks_Set; A_Task : Generic_Task_Ptr; My_Task_Iterator : Tasks_Iterator; Msg : Unbounded_String := empty_string; begin Put_Debug ("Call Partionning_Tasks"); if Output = Xml_Output then Set_Tag; else Set_Empty; end if; case A_Parition_Rule is when General_Task => Partition_General_Task (Sys.Processors, Sys.Tasks, Msg, Partitionned_Task_Set); when Best_Fit => Partition_Best_Fit (Sys.Processors, Sys.Tasks, Msg, Partitionned_Task_Set); when Next_Fit => Partition_Next_Fit (Sys.Processors, Sys.Tasks, Msg, Partitionned_Task_Set); when First_Fit => Partition_First_Fit (Sys.Processors, Sys.Tasks, Msg, Partitionned_Task_Set); when Small_Task => Partition_Small_Task (Sys.Processors, Sys.Tasks, Msg, Partitionned_Task_Set); end case; Result := Result & Start_Line & Lb_Minus & Lb_Partitioning_Result (Current_Language) & Start_Ref & Msg & End_Ref & Lb_Colon & unbounded_lf; Sys.Tasks := Partitionned_Task_Set; reset_iterator (Sys.Tasks, My_Task_Iterator); loop current_element (Sys.Tasks, A_Task, My_Task_Iterator); Result := Result & unbounded_lf & To_Unbounded_String (" ") & A_Task.name & To_Unbounded_String (" =>") & A_Task.cpu_name; exit when is_last_element (Sys.Tasks, My_Task_Iterator); next_element (Sys.Tasks, My_Task_Iterator); end loop; Result := Result & unbounded_lf & unbounded_lf; exception when Processors_Should_Have_The_Same_Scheduler => Result := Result & Lb_Partition_Error1 (Current_Language); when No_Such_Processors => Result := Result & Lb_Partition_Error2 (Current_Language); when Invalid_Scheduler_Multiprocessors => Result := Result & Lb_Partition_Error3 (Current_Language); when Task_Set.Task_Must_Be_Periodic => Result := Result & Lb_Partition_Error4 (Current_Language); end Partionning_Tasks; procedure Compute_Feasibility_Basics (Sys : in out System; Result : in out Unbounded_String; A_Processor : in Generic_Processor_Ptr; Output : in Output_Format := String_Output) is begin Put_Debug ("Call Compute_Feasibility_Basics"); Compute_Feasibility_Processor_Utilization_Factor (Sys, Result, A_Processor, Output); Compute_Feasibility_Response_Time (Sys, Result, A_Processor, Output); end Compute_Feasibility_Basics; end Call_Scheduling_Framework;