Commit c129694f authored by bouazizrahma's avatar bouazizrahma Committed by Jerome Hugues

extend runtime with types needed to implement many transitions in BA of threads

parent e9ed1fb4
......@@ -142,8 +142,27 @@ package body Ocarina.Backends.PO_HI_C.Runtime is
Set_Name (RED (E), Name);
end loop;
for E in RB_Id loop
Set_Str_To_Name_Buffer (RB_Id'Image (E));
Set_Str_To_Name_Buffer ("__po_hi_" & Name_Buffer (4 .. Name_Len));
Apply_Casing_Rules (Name_Buffer (1 .. Name_Len));
while Name_Buffer (Name_Len) in '0' .. '9'
or else Name_Buffer (Name_Len) = '_'
loop
Name_Len := Name_Len - 1;
end loop;
Name := Name_Find;
Name := To_Lower (Name);
RED (E) := New_Node (K_Defining_Identifier);
Set_Name (RED (E), Name);
end loop;
for E in RM_Id loop
Set_Str_To_Name_Buffer (RC_Id'Image (E));
Set_Str_To_Name_Buffer (RM_Id'Image (E));
Set_Str_To_Name_Buffer (Name_Buffer (4 .. Name_Len));
Apply_Casing_Rules (Name_Buffer (1 .. Name_Len));
......
......@@ -260,7 +260,17 @@ package Ocarina.Backends.PO_HI_C.Runtime is
RE_Local_Port, -- LOCAL_PORT
RE_PORT_VARIABLE, -- PORT_VARIABLE
RE_REQUEST_PORT -- REQUEST_PORT
RE_REQUEST_PORT, -- REQUEST_PORT
RE_Initial, -- __po_hi_initial
RE_Initial_Complete, -- __po_hi_initial_complete
RE_Initial_Complete_Final, -- __po_hi_initial_complete_final
RE_Initial_Final, -- __po_hi_initial_final
RE_Complete, -- __po_hi_complete
RE_Complete_Final, -- __po_hi_complete_final
RE_Final, -- __po_hi_final
RE_Execution, -- __po_hi_execution
RE_State_Kind_T -- __po_hi_state_kind_t
);
-- Runtime types
......@@ -270,6 +280,7 @@ package Ocarina.Backends.PO_HI_C.Runtime is
subtype RF_Id is RE_Id range RE_Null .. RE_Wait_For_Tasks;
subtype RV_Id is RE_Id range RE_Operation_Names .. RE_Port_Global_To_Local;
subtype RM_Id is RE_Id range RE_Local_Port .. RE_REQUEST_PORT;
subtype RB_Id is RE_Id range RE_Initial .. RE_State_Kind_T;
RE_Header_Table : constant array (RE_Id) of RH_Id :=
(RE_Null => RH_Null,
......@@ -479,7 +490,17 @@ package Ocarina.Backends.PO_HI_C.Runtime is
RE_Local_Port => RH_AADL,
RE_PORT_VARIABLE => RH_AADL,
RE_REQUEST_PORT => RH_AADL
RE_REQUEST_PORT => RH_AADL,
RE_Initial => RH_Null,
RE_Initial_Complete => RH_Null,
RE_Initial_Complete_Final => RH_Null,
RE_Initial_Final => RH_Null,
RE_Complete => RH_Null,
RE_Complete_Final => RH_Null,
RE_Final => RH_Null,
RE_Execution => RH_Null,
RE_State_Kind_T => RH_Null
);
procedure Initialize;
procedure Reset;
......
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