diff options
Diffstat (limited to 'src/psl/psl-nodes.ads')
-rw-r--r-- | src/psl/psl-nodes.ads | 359 |
1 files changed, 181 insertions, 178 deletions
diff --git a/src/psl/psl-nodes.ads b/src/psl/psl-nodes.ads index 241091805..b2a9a1caa 100644 --- a/src/psl/psl-nodes.ads +++ b/src/psl/psl-nodes.ads @@ -77,7 +77,7 @@ package PSL.Nodes is N_Name, N_Name_Decl, N_Number - ); + ); for Nkind'Size use 8; subtype N_Booleans is Nkind range N_Not_Bool .. N_True; @@ -109,285 +109,286 @@ package PSL.Nodes is Present_Neg ); - -- Start of nodes: + -- The next line marks the start of the node description. + -- Start of Nkind. - -- N_Error (Short) + -- N_Error (Short) - -- N_Vmode (Short) - -- N_Vunit (Short) - -- N_Vprop (Short) + -- N_Vmode (Short) + -- N_Vunit (Short) + -- N_Vprop (Short) -- - -- Get/Set_Identifier (Field1) + -- Get/Set_Identifier (Field1) -- - -- Get/Set_Chain (Field2) + -- Get/Set_Chain (Field2) -- - -- Get/Set_Instance (Field3) + -- Get/Set_Instance (Field3) -- - -- Get/Set_Item_Chain (Field4) + -- Get/Set_Item_Chain (Field4) - -- N_Hdl_Mod_Name (Short) + -- N_Hdl_Mod_Name (Short) -- - -- Get/Set_Identifier (Field1) + -- Get/Set_Identifier (Field1) -- - -- Get/Set_Prefix (Field2) + -- Get/Set_Prefix (Field2) - -- N_Assert_Directive (Short) + -- N_Assert_Directive (Short) -- - -- Get/Set_Label (Field1) + -- Get/Set_Label (Field1) -- - -- Get/Set_Chain (Field2) + -- Get/Set_Chain (Field2) -- - -- Get/Set_String (Field3) + -- Get/Set_String (Field3) -- - -- Get/Set_Property (Field4) + -- Get/Set_Property (Field4) -- - -- Get/Set_NFA (Field5) + -- Get/Set_NFA (Field5) - -- N_Property_Declaration (Short) + -- N_Property_Declaration (Short) -- - -- Get/Set_Identifier (Field1) + -- Get/Set_Identifier (Field1) -- - -- Get/Set_Chain (Field2) + -- Get/Set_Chain (Field2) -- - -- Get/Set_Global_Clock (Field3) + -- Get/Set_Global_Clock (Field3) -- - -- Get/Set_Property (Field4) + -- Get/Set_Property (Field4) -- - -- Get/Set_Parameter_List (Field5) + -- Get/Set_Parameter_List (Field5) - -- N_Sequence_Declaration (Short) - -- N_Endpoint_Declaration (Short) + -- N_Sequence_Declaration (Short) + -- N_Endpoint_Declaration (Short) -- - -- Get/Set_Identifier (Field1) + -- Get/Set_Identifier (Field1) -- - -- Get/Set_Chain (Field2) + -- Get/Set_Chain (Field2) -- - -- Get/Set_Sequence (Field3) + -- Get/Set_Sequence (Field3) -- - -- Get/Set_Parameter_List (Field5) + -- Get/Set_Parameter_List (Field5) - -- N_Const_Parameter (Short) - -- N_Boolean_Parameter (Short) - -- N_Property_Parameter (Short) - -- N_Sequence_Parameter (Short) + -- N_Const_Parameter (Short) + -- N_Boolean_Parameter (Short) + -- N_Property_Parameter (Short) + -- N_Sequence_Parameter (Short) -- - -- Get/Set_Identifier (Field1) + -- Get/Set_Identifier (Field1) -- - -- Get/Set_Chain (Field2) + -- Get/Set_Chain (Field2) -- -- -- Current actual parameter. - -- Get/Set_Actual (Field3) + -- Get/Set_Actual (Field3) - -- N_Sequence_Instance (Short) - -- N_Endpoint_Instance (Short) - -- N_Property_Instance (Short) + -- N_Sequence_Instance (Short) + -- N_Endpoint_Instance (Short) + -- N_Property_Instance (Short) -- - -- Get/Set_Declaration (Field1) [Flat] + -- Get/Set_Declaration (Field1) -- - -- Get/Set_Association_Chain (Field2) + -- Get/Set_Association_Chain (Field2) - -- N_Actual (Short) + -- N_Actual (Short) -- - -- Get/Set_Chain (Field2) + -- Get/Set_Chain (Field2) -- - -- Get/Set_Actual (Field3) + -- Get/Set_Actual (Field3) -- - -- Get/Set_Formal (Field4) + -- Get/Set_Formal (Field4) - -- N_Clock_Event (Short) + -- N_Clock_Event (Short) -- - -- Get/Set_Property (Field4) + -- Get/Set_Property (Field4) -- - -- Get/Set_Boolean (Field3) + -- Get/Set_Boolean (Field3) - -- N_Always (Short) - -- N_Never (Short) - -- N_Eventually (Short) - -- N_Strong (Short) + -- N_Always (Short) + -- N_Never (Short) + -- N_Eventually (Short) + -- N_Strong (Short) -- - -- Get/Set_Property (Field4) + -- Get/Set_Property (Field4) - -- N_Next (Short) + -- N_Next (Short) -- - -- Get/Set_Strong_Flag (Flag1) + -- Get/Set_Strong_Flag (Flag1) -- - -- Get/Set_Number (Field1) + -- Get/Set_Number (Field1) -- - -- Get/Set_Property (Field4) + -- Get/Set_Property (Field4) - -- N_Name (Short) + -- N_Name (Short) -- - -- Get/Set_Identifier (Field1) + -- Get/Set_Identifier (Field1) -- - -- Get/Set_Decl (Field2) + -- Get/Set_Decl (Field2) - -- N_Name_Decl (Short) + -- N_Name_Decl (Short) -- - -- Get/Set_Identifier (Field1) + -- Get/Set_Identifier (Field1) -- - -- Get/Set_Chain (Field2) + -- Get/Set_Chain (Field2) - -- N_Number (Short) + -- N_Number (Short) -- - -- Get/Set_Value (Field1) + -- Get/Set_Value (Field1) - -- N_Braced_SERE (Short) + -- N_Braced_SERE (Short) -- - -- Get/Set_SERE (Field1) + -- Get/Set_SERE (Field1) - -- N_Concat_SERE (Short) - -- N_Fusion_SERE (Short) - -- N_Within_SERE (Short) + -- N_Concat_SERE (Short) + -- N_Fusion_SERE (Short) + -- N_Within_SERE (Short) -- - -- Get/Set_Left (Field1) + -- Get/Set_Left (Field1) -- - -- Get/Set_Right (Field2) + -- Get/Set_Right (Field2) - -- N_Star_Repeat_Seq (Short) - -- N_Goto_Repeat_Seq (Short) - -- N_Equal_Repeat_Seq (Short) + -- N_Star_Repeat_Seq (Short) + -- N_Goto_Repeat_Seq (Short) + -- N_Equal_Repeat_Seq (Short) -- -- Note: can be null_node for star_repeat_seq. - -- Get/Set_Sequence (Field3) + -- Get/Set_Sequence (Field3) -- - -- Get/Set_Low_Bound (Field1) + -- Get/Set_Low_Bound (Field1) -- - -- Get/Set_High_Bound (Field2) + -- Get/Set_High_Bound (Field2) - -- N_Plus_Repeat_Seq (Short) + -- N_Plus_Repeat_Seq (Short) -- -- Note: can be null_node. - -- Get/Set_Sequence (Field3) + -- Get/Set_Sequence (Field3) - -- N_Match_And_Seq (Short) - -- N_And_Seq (Short) - -- N_Or_Seq (Short) + -- N_Match_And_Seq (Short) + -- N_And_Seq (Short) + -- N_Or_Seq (Short) -- - -- Get/Set_Left (Field1) + -- Get/Set_Left (Field1) -- - -- Get/Set_Right (Field2) + -- Get/Set_Right (Field2) - -- N_Imp_Seq (Short) - -- N_Overlap_Imp_Seq (Short) + -- N_Imp_Seq (Short) + -- N_Overlap_Imp_Seq (Short) -- - -- Get/Set_Sequence (Field3) + -- Get/Set_Sequence (Field3) -- - -- Get/Set_Property (Field4) + -- Get/Set_Property (Field4) - -- N_Log_Imp_Prop (Short) + -- N_Log_Imp_Prop (Short) -- - -- Get/Set_Left (Field1) + -- Get/Set_Left (Field1) -- - -- Get/Set_Right (Field2) + -- Get/Set_Right (Field2) - -- N_Next_A (Short) - -- N_Next_E (Short) + -- N_Next_A (Short) + -- N_Next_E (Short) -- - -- Get/Set_Strong_Flag (Flag1) + -- Get/Set_Strong_Flag (Flag1) -- - -- Get/Set_Low_Bound (Field1) + -- Get/Set_Low_Bound (Field1) -- - -- Get/Set_High_Bound (Field2) + -- Get/Set_High_Bound (Field2) -- - -- Get/Set_Property (Field4) + -- Get/Set_Property (Field4) - -- N_Next_Event (Short) + -- N_Next_Event (Short) -- - -- Get/Set_Strong_Flag (Flag1) + -- Get/Set_Strong_Flag (Flag1) -- - -- Get/Set_Number (Field1) + -- Get/Set_Number (Field1) -- - -- Get/Set_Property (Field4) + -- Get/Set_Property (Field4) -- - -- Get/Set_Boolean (Field3) + -- Get/Set_Boolean (Field3) - -- N_Or_Prop (Short) - -- N_And_Prop (Short) + -- N_Or_Prop (Short) + -- N_And_Prop (Short) -- - -- Get/Set_Left (Field1) + -- Get/Set_Left (Field1) -- - -- Get/Set_Right (Field2) + -- Get/Set_Right (Field2) - -- N_Until (Short) - -- N_Before (Short) + -- N_Until (Short) + -- N_Before (Short) -- - -- Get/Set_Strong_Flag (Flag1) + -- Get/Set_Strong_Flag (Flag1) -- - -- Get/Set_Inclusive_Flag (Flag2) + -- Get/Set_Inclusive_Flag (Flag2) -- - -- Get/Set_Left (Field1) + -- Get/Set_Left (Field1) -- - -- Get/Set_Right (Field2) + -- Get/Set_Right (Field2) - -- N_Next_Event_A (Short) - -- N_Next_Event_E (Short) + -- N_Next_Event_A (Short) + -- N_Next_Event_E (Short) -- - -- Get/Set_Strong_Flag (Flag1) + -- Get/Set_Strong_Flag (Flag1) -- - -- Get/Set_Low_Bound (Field1) + -- Get/Set_Low_Bound (Field1) -- - -- Get/Set_High_Bound (Field2) + -- Get/Set_High_Bound (Field2) -- - -- Get/Set_Property (Field4) + -- Get/Set_Property (Field4) -- - -- Get/Set_Boolean (Field3) + -- Get/Set_Boolean (Field3) - -- N_Abort (Short) + -- N_Abort (Short) -- - -- Get/Set_Property (Field4) + -- Get/Set_Property (Field4) -- - -- Get/Set_Boolean (Field3) + -- Get/Set_Boolean (Field3) - -- N_HDL_Expr (Short) + -- N_HDL_Expr (Short) -- - -- Get/Set_Presence (State1) + -- Get/Set_Presence (State1) -- - -- Get/Set_HDL_Node (Field1) + -- Get/Set_HDL_Node (Field1) -- - -- Get/Set_HDL_Index (Field2) + -- Get/Set_HDL_Index (Field2) -- - -- Get/Set_Hash (Field5) + -- Get/Set_Hash (Field5) -- - -- Get/Set_Hash_Link (Field6) + -- Get/Set_Hash_Link (Field6) - -- N_Not_Bool (Short) + -- N_Not_Bool (Short) -- - -- Get/Set_Presence (State1) + -- Get/Set_Presence (State1) -- - -- Get/Set_Boolean (Field3) + -- Get/Set_Boolean (Field3) -- - -- Get/Set_Hash (Field5) + -- Get/Set_Hash (Field5) -- - -- Get/Set_Hash_Link (Field6) + -- Get/Set_Hash_Link (Field6) - -- N_And_Bool (Short) - -- N_Or_Bool (Short) - -- N_Imp_Bool (Short) + -- N_And_Bool (Short) + -- N_Or_Bool (Short) + -- N_Imp_Bool (Short) -- - -- Get/Set_Presence (State1) + -- Get/Set_Presence (State1) -- - -- Get/Set_Left (Field1) + -- Get/Set_Left (Field1) -- - -- Get/Set_Right (Field2) + -- Get/Set_Right (Field2) -- - -- Get/Set_Hash (Field5) + -- Get/Set_Hash (Field5) -- - -- Get/Set_Hash_Link (Field6) + -- Get/Set_Hash_Link (Field6) - -- N_True (Short) - -- N_False (Short) + -- N_True (Short) + -- N_False (Short) - -- N_EOS (Short) + -- N_EOS (Short) -- End of simulation. -- - -- Get/Set_HDL_Index (Field2) + -- Get/Set_HDL_Index (Field2) -- - -- Get/Set_Hash (Field5) + -- Get/Set_Hash (Field5) -- - -- Get/Set_Hash_Link (Field6) + -- Get/Set_Hash_Link (Field6) - -- End of nodes. + -- End of Nkind. subtype Node is Types.PSL_Node; @@ -402,6 +403,8 @@ package PSL.Nodes is subtype HDL_Node is Types.Int32; HDL_Null : constant HDL_Node := 0; + -- General methods. + procedure Init; -- Get the number of the last node. @@ -416,7 +419,7 @@ package PSL.Nodes is -- Return the type of a node. function Get_Psl_Type (N : Node) return PSL_Types; - -- Field: Location + -- Note: use field Location function Get_Location (N : Node) return Location_Type; procedure Set_Location (N : Node; Loc : Location_Type); @@ -429,53 +432,53 @@ package PSL.Nodes is -- procedure Set_Parent (N : Node; Parent : Node); -- Disp: Special - -- Field: Field1 (conv) + -- Field: Field1 (pos) function Get_Identifier (N : Node) return Name_Id; procedure Set_Identifier (N : Node; Id : Name_Id); -- Disp: Special - -- Field: Field1 (conv) + -- Field: Field1 (pos) function Get_Label (N : Node) return Name_Id; procedure Set_Label (N : Node; Id : Name_Id); -- Disp: Chain - -- Field: Field2 (conv) + -- Field: Field2 Chain function Get_Chain (N : Node) return Node; procedure Set_Chain (N : Node; Chain : Node); - -- Field: Field3 (conv) + -- Field: Field3 function Get_Instance (N : Node) return Node; procedure Set_Instance (N : Node; Instance : Node); - -- Field: Field2 (conv) + -- Field: Field2 function Get_Prefix (N : Node) return Node; procedure Set_Prefix (N : Node; Prefix : Node); - -- Field: Field4 (conv) + -- Field: Field4 function Get_Item_Chain (N : Node) return Node; procedure Set_Item_Chain (N : Node; Item : Node); - -- Field: Field4 (conv) + -- Field: Field4 function Get_Property (N : Node) return Node; procedure Set_Property (N : Node; Property : Node); - -- Field: Field3 (conv) + -- Field: Field3 function Get_String (N : Node) return Node; procedure Set_String (N : Node; Str : Node); - -- Field: Field1 (conv) + -- Field: Field1 function Get_SERE (N : Node) return Node; procedure Set_SERE (N : Node; S : Node); - -- Field: Field1 (conv) + -- Field: Field1 function Get_Left (N : Node) return Node; procedure Set_Left (N : Node; S : Node); - -- Field: Field2 (conv) + -- Field: Field2 function Get_Right (N : Node) return Node; procedure Set_Right (N : Node; S : Node); - -- Field: Field3 (conv) + -- Field: Field3 function Get_Sequence (N : Node) return Node; procedure Set_Sequence (N : Node; S : Node); @@ -487,15 +490,15 @@ package PSL.Nodes is function Get_Inclusive_Flag (N : Node) return Boolean; procedure Set_Inclusive_Flag (N : Node; B : Boolean); - -- Field: Field1 (conv) + -- Field: Field1 function Get_Low_Bound (N : Node) return Node; procedure Set_Low_Bound (N : Node; S : Node); - -- Field: Field2 (conv) + -- Field: Field2 function Get_High_Bound (N : Node) return Node; procedure Set_High_Bound (N : Node; S : Node); - -- Field: Field1 (conv) + -- Field: Field1 function Get_Number (N : Node) return Node; procedure Set_Number (N : Node; S : Node); @@ -503,15 +506,15 @@ package PSL.Nodes is function Get_Value (N : Node) return Uns32; procedure Set_Value (N : Node; Val : Uns32); - -- Field: Field3 (conv) + -- Field: Field3 function Get_Boolean (N : Node) return Node; procedure Set_Boolean (N : Node; B : Node); - -- Field: Field2 (conv) + -- Field: Field2 function Get_Decl (N : Node) return Node; procedure Set_Decl (N : Node; D : Node); - -- Field: Field1 (conv) + -- Field: Field1 (uc) function Get_HDL_Node (N : Node) return HDL_Node; procedure Set_HDL_Node (N : Node; H : HDL_Node); @@ -520,12 +523,12 @@ package PSL.Nodes is procedure Set_Hash (N : Node; E : Uns32); pragma Inline (Get_Hash); - -- Field: Field6 (conv) + -- Field: Field6 function Get_Hash_Link (N : Node) return Node; procedure Set_Hash_Link (N : Node; E : Node); pragma Inline (Get_Hash_Link); - -- Field: Field2 + -- Field: Field2 (uc) function Get_HDL_Index (N : Node) return Int32; procedure Set_HDL_Index (N : Node; Idx : Int32); @@ -537,27 +540,27 @@ package PSL.Nodes is function Get_NFA (N : Node) return NFA; procedure Set_NFA (N : Node; P : NFA); - -- Field: Field5 (conv) + -- Field: Field5 function Get_Parameter_List (N : Node) return Node; procedure Set_Parameter_List (N : Node; E : Node); - -- Field: Field3 (conv) + -- Field: Field3 function Get_Actual (N : Node) return Node; procedure Set_Actual (N : Node; E : Node); - -- Field: Field4 (conv) + -- Field: Field4 function Get_Formal (N : Node) return Node; procedure Set_Formal (N : Node; E : Node); - -- Field: Field1 (conv) + -- Field: Field1 Ref function Get_Declaration (N : Node) return Node; procedure Set_Declaration (N : Node; Decl : Node); - -- Field: Field2 (conv) + -- Field: Field2 function Get_Association_Chain (N : Node) return Node; procedure Set_Association_Chain (N : Node; Chain : Node); - -- Field: Field3 (conv) + -- Field: Field3 function Get_Global_Clock (N : Node) return Node; procedure Set_Global_Clock (N : Node; Clock : Node); end PSL.Nodes; |