Unverified Commit d8f7fcca authored by Jerome Hugues's avatar Jerome Hugues Committed by GitHub
Browse files

Merge pull request #220 from bouazizrahma/fix_send_out_on_a_port

Fix send output on a port
For openaadl/ocarina#190
parents 576b518d 9e5e0941
...@@ -1352,6 +1352,11 @@ package body Ocarina.Backends.C_Common.BA is ...@@ -1352,6 +1352,11 @@ package body Ocarina.Backends.C_Common.BA is
& " the LOCAL_PORT macro. "); & " the LOCAL_PORT macro. ");
Append_Node_To_List (N, Statements); Append_Node_To_List (N, Statements);
-- __po_hi_gqueue_store_out
-- (self,
-- LOCAL_PORT (<<thread_name>>, <<port_name>>),
-- &__<<port_name>>_request);
Call_Parameters := New_List (CTN.K_Parameter_List); Call_Parameters := New_List (CTN.K_Parameter_List);
Set_Str_To_Name_Buffer ("self"); Set_Str_To_Name_Buffer ("self");
...@@ -1384,6 +1389,30 @@ package body Ocarina.Backends.C_Common.BA is ...@@ -1384,6 +1389,30 @@ package body Ocarina.Backends.C_Common.BA is
Call_Parameters); Call_Parameters);
Append_Node_To_List (N, Statements); Append_Node_To_List (N, Statements);
-- __po_hi_send_output
-- (self,REQUEST_PORT(<<thread_name>>, <<port_name>>));
Call_Parameters := New_List (CTN.K_Parameter_List);
Append_Node_To_List (Make_Defining_Identifier (N1), Call_Parameters);
Append_Node_To_List
(Make_Call_Profile
(RE (RE_REQUEST_PORT),
Make_List_Id
(Make_Defining_Identifier
(Map_Thread_Port_Variable_Name (S)),
Make_Defining_Identifier
(BATN.Display_Name (BATN.First_Node
(BATN.Idt (BATN.Identifier (Node))))))),
Call_Parameters);
N := Make_Call_Profile
(RE (RE_Send_Output),
Call_Parameters);
Append_Node_To_List (N, Statements);
end Make_Send_Output_Port; end Make_Send_Output_Port;
------------------------------------ ------------------------------------
......
...@@ -342,7 +342,7 @@ package Ocarina.Backends.PO_HI_C.Runtime is ...@@ -342,7 +342,7 @@ package Ocarina.Backends.PO_HI_C.Runtime is
RE_Protected_Lock => RH_PO_HI_Protected, RE_Protected_Lock => RH_PO_HI_Protected,
RE_Protected_Unlock => RH_PO_HI_Protected, RE_Protected_Unlock => RH_PO_HI_Protected,
RE_Copy_Array => RH_PO_HI_Types, RE_Copy_Array => RH_PO_HI_Types,
RE_Send_Output => RH_Activity, RE_Send_Output => RH_PO_HI_Transport, -- RH_Activity,
RE_Get_Entity_From_Global_Port => RH_PO_HI_Transport, RE_Get_Entity_From_Global_Port => RH_PO_HI_Transport,
RE_Gqueue_Store_In => RH_PO_HI_Gqueue, RE_Gqueue_Store_In => RH_PO_HI_Gqueue,
RE_Gqueue_Store_Out => RH_PO_HI_Gqueue, RE_Gqueue_Store_Out => RH_PO_HI_Gqueue,
......
Supports Markdown
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