Commit 031190df authored by jhugues's avatar jhugues

* Replace occurences of Word_Cound to Byte_Cound per latest

	AADLv2 standar property sets



git-svn-id: https://tecsw.estec.esa.int/svn/taste/trunk/ocarina@5019 129961e7-ef38-4bb5-a8f7-c9a525a55882
parent 7f41e2e0
......@@ -747,11 +747,11 @@ package body Ocarina.Backends.ARINC653_Conf.Mapping is
if Get_Bound_Memory (Process) /= No_Node then
Memory := Get_Bound_Memory (Process);
declare
Word_Count : Unsigned_Long_Long := 1;
Byte_Count : Unsigned_Long_Long := 1;
Word_Size : Unsigned_Long_Long := 1;
begin
if Get_Word_Count (Get_Bound_Memory (Process)) /= 0 then
Word_Count := Get_Word_Count (Get_Bound_Memory (Process));
if Get_Byte_Count (Get_Bound_Memory (Process)) /= 0 then
Byte_Count := Get_Byte_Count (Get_Bound_Memory (Process));
end if;
if Get_Word_Size (Get_Bound_Memory (Process)) /= Null_Size then
......@@ -763,7 +763,7 @@ package body Ocarina.Backends.ARINC653_Conf.Mapping is
Set_Str_To_Name_Buffer ("SizeBytes");
P := Make_Defining_Identifier (Name_Find);
Q := Make_Literal (XV.New_Numeric_Value
(Word_Count * Word_Size, 1, 10));
(Byte_Count * Word_Size, 1, 10));
Append_Node_To_List (Make_Assignement (P, Q), XTN.Items (M));
if Get_ARINC653_Memory_Kind (Memory) = Data then
......
......@@ -1254,18 +1254,18 @@ package body Ocarina.Backends.POK_C.Deployment is
if Bound_Memory_Component /= No_Node then
declare
Word_Count : Unsigned_Long_Long := 1;
Byte_Count : Unsigned_Long_Long := 1;
Word_Size : Unsigned_Long_Long := 1;
begin
if Get_Word_Count (Bound_Memory_Component) /= 0 then
Word_Count := Get_Word_Count (Bound_Memory_Component);
if Get_Byte_Count (Bound_Memory_Component) /= 0 then
Byte_Count := Get_Byte_Count (Bound_Memory_Component);
end if;
if Get_Word_Size (Bound_Memory_Component) /= Null_Size then
Word_Size := To_Bytes
(Get_Word_Size (Bound_Memory_Component));
end if;
Bound_Memory_Size := Word_Count * Word_Size;
Bound_Memory_Size := Byte_Count * Word_Size;
-- byte_count override other properties.
if Is_Defined_Property
......
......@@ -180,7 +180,7 @@ package body Ocarina.Backends.Properties is
-- Memory component properties --
---------------------------------
Word_Count : Name_Id;
Byte_Count : Name_Id;
Word_Size : Name_Id;
------------------------------------
......@@ -2907,19 +2907,19 @@ package body Ocarina.Backends.Properties is
end Get_Protocol;
--------------------
-- Get_Word_Count --
-- Get_Byte_Count --
--------------------
function Get_Word_Count (S : Node_Id) return Unsigned_Long_Long is
function Get_Byte_Count (S : Node_Id) return Unsigned_Long_Long is
begin
pragma Assert (Is_Memory (S));
if Is_Defined_Integer_Property (S, Word_Count) then
return Get_Integer_Property (S, Word_Count);
if Is_Defined_Integer_Property (S, Byte_Count) then
return Get_Integer_Property (S, Byte_Count);
else
return 0;
end if;
end Get_Word_Count;
end Get_Byte_Count;
-------------------
-- Get_Word_Size --
......@@ -3114,7 +3114,7 @@ package body Ocarina.Backends.Properties is
Function_Binding :=
Get_String_Name ("aram_properties::actual_function_binding");
Memory_Binding := Get_String_Name ("actual_memory_binding");
Word_Count := Get_String_Name ("word_count");
Byte_Count := Get_String_Name ("byte_count");
Word_Size := Get_String_Name ("word_size");
Process_Channel_Address := Get_String_Name
("deployment::channel_address");
......
......@@ -553,8 +553,8 @@ package Ocarina.Backends.Properties is
function Get_Channel_Address (P : Node_Id) return Value_Id;
-- Return the address of the SpaceWire channel of the process P
function Get_Word_Count (S : Node_Id) return Unsigned_Long_Long;
-- Get the Word_Count property of a memory component. Return 0
function Get_Byte_Count (S : Node_Id) return Unsigned_Long_Long;
-- Get the Byte_Count property of a memory component. Return 0
-- if the component is not set.
function Get_Word_Size (S : Node_Id) return Size_Type;
......
......@@ -743,11 +743,11 @@ package body Ocarina.Backends.Xtratum_Conf.Mapping is
if Get_Bound_Memory (Process) /= No_Node then
Memory := Get_Bound_Memory (Process);
declare
Word_Count : Unsigned_Long_Long := 1;
Byte_Count : Unsigned_Long_Long := 1;
Word_Size : Unsigned_Long_Long := 1;
begin
if Get_Word_Count (Get_Bound_Memory (Process)) /= 0 then
Word_Count := Get_Word_Count (Get_Bound_Memory (Process));
if Get_Byte_Count (Get_Bound_Memory (Process)) /= 0 then
Byte_Count := Get_Byte_Count (Get_Bound_Memory (Process));
end if;
if Get_Word_Size (Get_Bound_Memory (Process)) /= Null_Size then
......@@ -759,7 +759,7 @@ package body Ocarina.Backends.Xtratum_Conf.Mapping is
Set_Str_To_Name_Buffer ("SizeBytes");
P := Make_Defining_Identifier (Name_Find);
Q := Make_Literal (XV.New_Numeric_Value
(Word_Count * Word_Size, 1, 10));
(Byte_Count * Word_Size, 1, 10));
Append_Node_To_List (Make_Assignement (P, Q), XTN.Items (M));
if Get_ARINC653_Memory_Kind (Memory) = Data then
......
......@@ -37,9 +37,10 @@ with Ocarina.ME_AADL;
with Ocarina.ME_AADL.AADL_Tree.Nodes;
with Ocarina.ME_AADL.AADL_Tree.Nutils;
with Ocarina.Property_Sets;
with Ocarina.BE_AADL.Annexes;
with Ocarina.BE_AADL.Components;
with Ocarina.BE_AADL.Properties;
with Ocarina.BE_AADL.Identifiers;
with Ocarina.BE_AADL.Properties;
package body Ocarina.BE_AADL.Namespaces is
......@@ -48,6 +49,7 @@ package body Ocarina.BE_AADL.Namespaces is
use Ocarina.ME_AADL.AADL_Tree.Nodes;
use Ocarina.ME_AADL.AADL_Tree.Nutils;
use Ocarina.Property_Sets;
use Ocarina.BE_AADL.Annexes;
use Ocarina.BE_AADL.Components;
use Ocarina.BE_AADL.Properties;
use Ocarina.BE_AADL.Identifiers;
......@@ -281,6 +283,22 @@ package body Ocarina.BE_AADL.Namespaces is
end if;
end if;
-- Annex subclauses
if not Is_Empty (Ocarina.ME_AADL.AADL_Tree.Nodes.Annexes (Node)) then
Increment_Indentation;
List_Node := First_Node
(Ocarina.ME_AADL.AADL_Tree.Nodes.Annexes (Node));
while Present (List_Node) loop
Print_Annex_Subclause (List_Node);
List_Node := Next_Node (List_Node);
end loop;
Decrement_Indentation;
Write_Eol;
end if;
-- private part
if Has_Private then
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment