From 8b090b01da269679e98a578f4fda17e3e4adce12 Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Sat, 8 Oct 2016 04:53:25 +0200 Subject: Add signal_attribute_declaration to hold implicit atribute signals. --- src/vhdl/canon.adb | 2 +- src/vhdl/disp_vhdl.adb | 2 +- src/vhdl/errorout.adb | 3 + src/vhdl/iirs.adb | 49 +++++ src/vhdl/iirs.ads | 39 +++- src/vhdl/nodes_meta.adb | 371 ++++++++++++++++++++++--------------- src/vhdl/nodes_meta.ads | 6 + src/vhdl/sem_decls.adb | 124 +++++++++---- src/vhdl/sem_decls.ads | 19 +- src/vhdl/translate/trans-chap4.adb | 36 +++- src/vhdl/translate/trans-rtis.adb | 49 +++-- 11 files changed, 470 insertions(+), 230 deletions(-) (limited to 'src') diff --git a/src/vhdl/canon.adb b/src/vhdl/canon.adb index cba109396..b39caab9b 100644 --- a/src/vhdl/canon.adb +++ b/src/vhdl/canon.adb @@ -2687,7 +2687,7 @@ package body Canon is when Iir_Kind_Package_Instantiation_Declaration => return Canon_Package_Instantiation_Declaration (Decl); - when Iir_Kinds_Signal_Attribute => + when Iir_Kind_Signal_Attribute_Declaration => null; when Iir_Kind_Nature_Declaration => diff --git a/src/vhdl/disp_vhdl.adb b/src/vhdl/disp_vhdl.adb index 01ad49552..b3abdcdb1 100644 --- a/src/vhdl/disp_vhdl.adb +++ b/src/vhdl/disp_vhdl.adb @@ -1738,7 +1738,7 @@ package body Disp_Vhdl is Disp_Attribute_Declaration (Decl); when Iir_Kind_Attribute_Specification => Disp_Attribute_Specification (Decl); - when Iir_Kinds_Signal_Attribute => + when Iir_Kind_Signal_Attribute_Declaration => null; when Iir_Kind_Group_Template_Declaration => Disp_Group_Template_Declaration (Decl); diff --git a/src/vhdl/errorout.adb b/src/vhdl/errorout.adb index eedece4d8..66ace9652 100644 --- a/src/vhdl/errorout.adb +++ b/src/vhdl/errorout.adb @@ -898,6 +898,9 @@ package body Errorout is return Disp_Identifier (Node, "non-object alias"); when Iir_Kind_Guard_Signal_Declaration => return "GUARD signal"; + when Iir_Kind_Signal_Attribute_Declaration => + -- Should not appear. + return "signal attribute"; when Iir_Kind_Group_Template_Declaration => return Disp_Identifier (Node, "group template"); when Iir_Kind_Group_Declaration => diff --git a/src/vhdl/iirs.adb b/src/vhdl/iirs.adb index 06ee9a305..5e940d3ac 100644 --- a/src/vhdl/iirs.adb +++ b/src/vhdl/iirs.adb @@ -338,6 +338,7 @@ package body Iirs is | Iir_Kind_Interface_Signal_Declaration | Iir_Kind_Interface_File_Declaration | Iir_Kind_Interface_Type_Declaration + | Iir_Kind_Signal_Attribute_Declaration | Iir_Kind_Identity_Operator | Iir_Kind_Negation_Operator | Iir_Kind_Absolute_Operator @@ -3937,6 +3938,22 @@ package body Iirs is Set_Field4 (Guard, Iir_List_To_Iir (List)); end Set_Guard_Sensitivity_List; + function Get_Signal_Attribute_Chain (Decl : Iir) return Iir is + begin + pragma Assert (Decl /= Null_Iir); + pragma Assert (Has_Signal_Attribute_Chain (Get_Kind (Decl)), + "no field Signal_Attribute_Chain"); + return Get_Field3 (Decl); + end Get_Signal_Attribute_Chain; + + procedure Set_Signal_Attribute_Chain (Decl : Iir; Chain : Iir) is + begin + pragma Assert (Decl /= Null_Iir); + pragma Assert (Has_Signal_Attribute_Chain (Get_Kind (Decl)), + "no field Signal_Attribute_Chain"); + Set_Field3 (Decl, Chain); + end Set_Signal_Attribute_Chain; + function Get_Block_Block_Configuration (Block : Iir) return Iir is begin pragma Assert (Block /= Null_Iir); @@ -4579,6 +4596,38 @@ package body Iirs is Set_Field4 (Target, Param); end Set_Parameter; + function Get_Attr_Chain (Attr : Iir) return Iir is + begin + pragma Assert (Attr /= Null_Iir); + pragma Assert (Has_Attr_Chain (Get_Kind (Attr)), + "no field Attr_Chain"); + return Get_Field2 (Attr); + end Get_Attr_Chain; + + procedure Set_Attr_Chain (Attr : Iir; Chain : Iir) is + begin + pragma Assert (Attr /= Null_Iir); + pragma Assert (Has_Attr_Chain (Get_Kind (Attr)), + "no field Attr_Chain"); + Set_Field2 (Attr, Chain); + end Set_Attr_Chain; + + function Get_Signal_Attribute_Declaration (Attr : Iir) return Iir is + begin + pragma Assert (Attr /= Null_Iir); + pragma Assert (Has_Signal_Attribute_Declaration (Get_Kind (Attr)), + "no field Signal_Attribute_Declaration"); + return Get_Field3 (Attr); + end Get_Signal_Attribute_Declaration; + + procedure Set_Signal_Attribute_Declaration (Attr : Iir; Decl : Iir) is + begin + pragma Assert (Attr /= Null_Iir); + pragma Assert (Has_Signal_Attribute_Declaration (Get_Kind (Attr)), + "no field Signal_Attribute_Declaration"); + Set_Field3 (Attr, Decl); + end Set_Signal_Attribute_Declaration; + function Get_Actual_Type (Target : Iir) return Iir is begin pragma Assert (Target /= Null_Iir); diff --git a/src/vhdl/iirs.ads b/src/vhdl/iirs.ads index 59d6c904f..f87159185 100644 --- a/src/vhdl/iirs.ads +++ b/src/vhdl/iirs.ads @@ -1560,6 +1560,19 @@ package Iirs is -- -- Get/Set_Name_Staticness (State2) + -- Iir_Kind_Signal_Attribute_Declaration (Short) + -- + -- Chain of implicit signals created from signal attribute. This is just + -- an helper so that translation can create these implicit signals at the + -- same time as user signal declarations. + -- + -- Get/Set_Parent (Field0) + -- + -- Get/Set_Chain (Field2) + -- + -- Chain of signals + -- Get/Set_Signal_Attribute_Chain (Field3) + -- Iir_Kind_Constant_Declaration (Medium) -- Iir_Kind_Iterator_Declaration (Medium) -- @@ -3733,12 +3746,18 @@ package Iirs is -- -- Get/Set_Prefix (Field0) -- + -- Not used by Iir_Kind_Transaction_Attribute + -- Get/Set_Parameter (Field4) + -- -- Get/Set_Type (Field1) -- - -- Get/Set_Chain (Field2) + -- Next attribute signal in the chain owned by the + -- signal_attribute_declaration. Usual Get/Set_Chain is not used here as + -- the chain is composed only of forward references. + -- Get/Set_Attr_Chain (Field2) -- - -- Not used by Iir_Kind_Transaction_Attribute - -- Get/Set_Parameter (Field4) + -- Head of the chain. Used only to ease the reconstruction of the chain. + -- Get/Set_Signal_Attribute_Declaration (Field3) -- -- Get/Set_Base_Name (Field5) -- @@ -3988,6 +4007,8 @@ package Iirs is Iir_Kind_Interface_Function_Declaration, -- interface Iir_Kind_Interface_Procedure_Declaration, -- interface + Iir_Kind_Signal_Attribute_Declaration, + -- Expressions. Iir_Kind_Identity_Operator, Iir_Kind_Negation_Operator, @@ -6585,6 +6606,10 @@ package Iirs is function Get_Guard_Sensitivity_List (Guard : Iir) return Iir_List; procedure Set_Guard_Sensitivity_List (Guard : Iir; List : Iir_List); + -- Field: Field3 Forward_Ref + function Get_Signal_Attribute_Chain (Decl : Iir) return Iir; + procedure Set_Signal_Attribute_Chain (Decl : Iir; Chain : Iir); + -- Block_Configuration that applies to this block statement. -- Field: Field6 function Get_Block_Block_Configuration (Block : Iir) return Iir; @@ -6774,6 +6799,14 @@ package Iirs is function Get_Parameter (Target : Iir) return Iir; procedure Set_Parameter (Target : Iir; Param : Iir); + -- Field: Field2 Forward_Ref + function Get_Attr_Chain (Attr : Iir) return Iir; + procedure Set_Attr_Chain (Attr : Iir; Chain : Iir); + + -- Field: Field3 Forward_Ref + function Get_Signal_Attribute_Declaration (Attr : Iir) return Iir; + procedure Set_Signal_Attribute_Declaration (Attr : Iir; Decl : Iir); + -- Type of the actual for an association by individual. -- Unless the formal is an unconstrained array type, this is the same as -- the formal type. diff --git a/src/vhdl/nodes_meta.adb b/src/vhdl/nodes_meta.adb index 21142d2d3..0efd08967 100644 --- a/src/vhdl/nodes_meta.adb +++ b/src/vhdl/nodes_meta.adb @@ -231,6 +231,7 @@ package body Nodes_Meta is Field_Guard_Expression => Type_Iir, Field_Guard_Decl => Type_Iir, Field_Guard_Sensitivity_List => Type_Iir_List, + Field_Signal_Attribute_Chain => Type_Iir, Field_Block_Block_Configuration => Type_Iir, Field_Package_Header => Type_Iir, Field_Block_Header => Type_Iir, @@ -271,6 +272,8 @@ package body Nodes_Meta is Field_Suffix => Type_Iir, Field_Index_Subtype => Type_Iir, Field_Parameter => Type_Iir, + Field_Attr_Chain => Type_Iir, + Field_Signal_Attribute_Declaration => Type_Iir, Field_Actual_Type => Type_Iir, Field_Association_Chain => Type_Iir, Field_Individual_Association_Chain => Type_Iir, @@ -769,6 +772,8 @@ package body Nodes_Meta is return "guard_decl"; when Field_Guard_Sensitivity_List => return "guard_sensitivity_list"; + when Field_Signal_Attribute_Chain => + return "signal_attribute_chain"; when Field_Block_Block_Configuration => return "block_block_configuration"; when Field_Package_Header => @@ -849,6 +854,10 @@ package body Nodes_Meta is return "index_subtype"; when Field_Parameter => return "parameter"; + when Field_Attr_Chain => + return "attr_chain"; + when Field_Signal_Attribute_Declaration => + return "signal_attribute_declaration"; when Field_Actual_Type => return "actual_type"; when Field_Association_Chain => @@ -1221,6 +1230,8 @@ package body Nodes_Meta is return "interface_function_declaration"; when Iir_Kind_Interface_Procedure_Declaration => return "interface_procedure_declaration"; + when Iir_Kind_Signal_Attribute_Declaration => + return "signal_attribute_declaration"; when Iir_Kind_Identity_Operator => return "identity_operator"; when Iir_Kind_Negation_Operator => @@ -1937,6 +1948,8 @@ package body Nodes_Meta is return Attr_None; when Field_Guard_Sensitivity_List => return Attr_None; + when Field_Signal_Attribute_Chain => + return Attr_Forward_Ref; when Field_Block_Block_Configuration => return Attr_None; when Field_Package_Header => @@ -2017,6 +2030,10 @@ package body Nodes_Meta is return Attr_Ref; when Field_Parameter => return Attr_None; + when Field_Attr_Chain => + return Attr_Forward_Ref; + when Field_Signal_Attribute_Declaration => + return Attr_Forward_Ref; when Field_Actual_Type => return Attr_None; when Field_Association_Chain => @@ -3220,6 +3237,10 @@ package body Nodes_Meta is Field_Interface_Declaration_Chain, Field_Return_Type_Mark, Field_Parent, + -- Iir_Kind_Signal_Attribute_Declaration + Field_Chain, + Field_Parent, + Field_Signal_Attribute_Chain, -- Iir_Kind_Identity_Operator Field_Expr_Staticness, Field_Operand, @@ -4067,36 +4088,40 @@ package body Nodes_Meta is Field_Expr_Staticness, Field_Name_Staticness, Field_Prefix, - Field_Chain, Field_Parameter, Field_Type, + Field_Attr_Chain, + Field_Signal_Attribute_Declaration, Field_Base_Name, -- Iir_Kind_Stable_Attribute Field_Has_Active_Flag, Field_Expr_Staticness, Field_Name_Staticness, Field_Prefix, - Field_Chain, Field_Parameter, Field_Type, + Field_Attr_Chain, + Field_Signal_Attribute_Declaration, Field_Base_Name, -- Iir_Kind_Quiet_Attribute Field_Has_Active_Flag, Field_Expr_Staticness, Field_Name_Staticness, Field_Prefix, - Field_Chain, Field_Parameter, Field_Type, + Field_Attr_Chain, + Field_Signal_Attribute_Declaration, Field_Base_Name, -- Iir_Kind_Transaction_Attribute Field_Has_Active_Flag, Field_Expr_Staticness, Field_Name_Staticness, Field_Prefix, - Field_Chain, Field_Parameter, Field_Type, + Field_Attr_Chain, + Field_Signal_Attribute_Declaration, Field_Base_Name, -- Iir_Kind_Event_Attribute Field_Expr_Staticness, @@ -4351,149 +4376,150 @@ package body Nodes_Meta is Iir_Kind_Interface_Package_Declaration => 920, Iir_Kind_Interface_Function_Declaration => 937, Iir_Kind_Interface_Procedure_Declaration => 950, - Iir_Kind_Identity_Operator => 954, - Iir_Kind_Negation_Operator => 958, - Iir_Kind_Absolute_Operator => 962, - Iir_Kind_Not_Operator => 966, - Iir_Kind_Condition_Operator => 970, - Iir_Kind_Reduction_And_Operator => 974, - Iir_Kind_Reduction_Or_Operator => 978, - Iir_Kind_Reduction_Nand_Operator => 982, - Iir_Kind_Reduction_Nor_Operator => 986, - Iir_Kind_Reduction_Xor_Operator => 990, - Iir_Kind_Reduction_Xnor_Operator => 994, - Iir_Kind_And_Operator => 999, - Iir_Kind_Or_Operator => 1004, - Iir_Kind_Nand_Operator => 1009, - Iir_Kind_Nor_Operator => 1014, - Iir_Kind_Xor_Operator => 1019, - Iir_Kind_Xnor_Operator => 1024, - Iir_Kind_Equality_Operator => 1029, - Iir_Kind_Inequality_Operator => 1034, - Iir_Kind_Less_Than_Operator => 1039, - Iir_Kind_Less_Than_Or_Equal_Operator => 1044, - Iir_Kind_Greater_Than_Operator => 1049, - Iir_Kind_Greater_Than_Or_Equal_Operator => 1054, - Iir_Kind_Match_Equality_Operator => 1059, - Iir_Kind_Match_Inequality_Operator => 1064, - Iir_Kind_Match_Less_Than_Operator => 1069, - Iir_Kind_Match_Less_Than_Or_Equal_Operator => 1074, - Iir_Kind_Match_Greater_Than_Operator => 1079, - Iir_Kind_Match_Greater_Than_Or_Equal_Operator => 1084, - Iir_Kind_Sll_Operator => 1089, - Iir_Kind_Sla_Operator => 1094, - Iir_Kind_Srl_Operator => 1099, - Iir_Kind_Sra_Operator => 1104, - Iir_Kind_Rol_Operator => 1109, - Iir_Kind_Ror_Operator => 1114, - Iir_Kind_Addition_Operator => 1119, - Iir_Kind_Substraction_Operator => 1124, - Iir_Kind_Concatenation_Operator => 1129, - Iir_Kind_Multiplication_Operator => 1134, - Iir_Kind_Division_Operator => 1139, - Iir_Kind_Modulus_Operator => 1144, - Iir_Kind_Remainder_Operator => 1149, - Iir_Kind_Exponentiation_Operator => 1154, - Iir_Kind_Function_Call => 1162, - Iir_Kind_Aggregate => 1168, - Iir_Kind_Parenthesis_Expression => 1171, - Iir_Kind_Qualified_Expression => 1175, - Iir_Kind_Type_Conversion => 1180, - Iir_Kind_Allocator_By_Expression => 1184, - Iir_Kind_Allocator_By_Subtype => 1189, - Iir_Kind_Selected_Element => 1195, - Iir_Kind_Dereference => 1200, - Iir_Kind_Implicit_Dereference => 1205, - Iir_Kind_Slice_Name => 1212, - Iir_Kind_Indexed_Name => 1218, - Iir_Kind_Psl_Expression => 1220, - Iir_Kind_Sensitized_Process_Statement => 1240, - Iir_Kind_Process_Statement => 1260, - Iir_Kind_Concurrent_Simple_Signal_Assignment => 1271, - Iir_Kind_Concurrent_Conditional_Signal_Assignment => 1282, - Iir_Kind_Concurrent_Selected_Signal_Assignment => 1294, - Iir_Kind_Concurrent_Assertion_Statement => 1302, - Iir_Kind_Concurrent_Procedure_Call_Statement => 1309, - Iir_Kind_Psl_Assert_Statement => 1322, - Iir_Kind_Psl_Cover_Statement => 1335, - Iir_Kind_Block_Statement => 1348, - Iir_Kind_If_Generate_Statement => 1358, - Iir_Kind_Case_Generate_Statement => 1367, - Iir_Kind_For_Generate_Statement => 1376, - Iir_Kind_Component_Instantiation_Statement => 1386, - Iir_Kind_Psl_Default_Clock => 1390, - Iir_Kind_Simple_Simultaneous_Statement => 1397, - Iir_Kind_Generate_Statement_Body => 1408, - Iir_Kind_If_Generate_Else_Clause => 1413, - Iir_Kind_Simple_Signal_Assignment_Statement => 1422, - Iir_Kind_Conditional_Signal_Assignment_Statement => 1431, - Iir_Kind_Null_Statement => 1435, - Iir_Kind_Assertion_Statement => 1442, - Iir_Kind_Report_Statement => 1448, - Iir_Kind_Wait_Statement => 1455, - Iir_Kind_Variable_Assignment_Statement => 1461, - Iir_Kind_Conditional_Variable_Assignment_Statement => 1467, - Iir_Kind_Return_Statement => 1473, - Iir_Kind_For_Loop_Statement => 1482, - Iir_Kind_While_Loop_Statement => 1490, - Iir_Kind_Next_Statement => 1496, - Iir_Kind_Exit_Statement => 1502, - Iir_Kind_Case_Statement => 1510, - Iir_Kind_Procedure_Call_Statement => 1516, - Iir_Kind_If_Statement => 1525, - Iir_Kind_Elsif => 1530, - Iir_Kind_Character_Literal => 1537, - Iir_Kind_Simple_Name => 1544, - Iir_Kind_Selected_Name => 1552, - Iir_Kind_Operator_Symbol => 1557, - Iir_Kind_Selected_By_All_Name => 1562, - Iir_Kind_Parenthesis_Name => 1566, - Iir_Kind_External_Constant_Name => 1574, - Iir_Kind_External_Signal_Name => 1582, - Iir_Kind_External_Variable_Name => 1590, - Iir_Kind_Package_Pathname => 1593, - Iir_Kind_Absolute_Pathname => 1594, - Iir_Kind_Relative_Pathname => 1595, - Iir_Kind_Pathname_Element => 1599, - Iir_Kind_Base_Attribute => 1601, - Iir_Kind_Left_Type_Attribute => 1606, - Iir_Kind_Right_Type_Attribute => 1611, - Iir_Kind_High_Type_Attribute => 1616, - Iir_Kind_Low_Type_Attribute => 1621, - Iir_Kind_Ascending_Type_Attribute => 1626, - Iir_Kind_Image_Attribute => 1632, - Iir_Kind_Value_Attribute => 1638, - Iir_Kind_Pos_Attribute => 1644, - Iir_Kind_Val_Attribute => 1650, - Iir_Kind_Succ_Attribute => 1656, - Iir_Kind_Pred_Attribute => 1662, - Iir_Kind_Leftof_Attribute => 1668, - Iir_Kind_Rightof_Attribute => 1674, - Iir_Kind_Delayed_Attribute => 1682, - Iir_Kind_Stable_Attribute => 1690, - Iir_Kind_Quiet_Attribute => 1698, - Iir_Kind_Transaction_Attribute => 1706, - Iir_Kind_Event_Attribute => 1710, - Iir_Kind_Active_Attribute => 1714, - Iir_Kind_Last_Event_Attribute => 1718, - Iir_Kind_Last_Active_Attribute => 1722, - Iir_Kind_Last_Value_Attribute => 1726, - Iir_Kind_Driving_Attribute => 1730, - Iir_Kind_Driving_Value_Attribute => 1734, - Iir_Kind_Behavior_Attribute => 1734, - Iir_Kind_Structure_Attribute => 1734, - Iir_Kind_Simple_Name_Attribute => 1741, - Iir_Kind_Instance_Name_Attribute => 1746, - Iir_Kind_Path_Name_Attribute => 1751, - Iir_Kind_Left_Array_Attribute => 1758, - Iir_Kind_Right_Array_Attribute => 1765, - Iir_Kind_High_Array_Attribute => 1772, - Iir_Kind_Low_Array_Attribute => 1779, - Iir_Kind_Length_Array_Attribute => 1786, - Iir_Kind_Ascending_Array_Attribute => 1793, - Iir_Kind_Range_Array_Attribute => 1800, - Iir_Kind_Reverse_Range_Array_Attribute => 1807, - Iir_Kind_Attribute_Name => 1815 + Iir_Kind_Signal_Attribute_Declaration => 953, + Iir_Kind_Identity_Operator => 957, + Iir_Kind_Negation_Operator => 961, + Iir_Kind_Absolute_Operator => 965, + Iir_Kind_Not_Operator => 969, + Iir_Kind_Condition_Operator => 973, + Iir_Kind_Reduction_And_Operator => 977, + Iir_Kind_Reduction_Or_Operator => 981, + Iir_Kind_Reduction_Nand_Operator => 985, + Iir_Kind_Reduction_Nor_Operator => 989, + Iir_Kind_Reduction_Xor_Operator => 993, + Iir_Kind_Reduction_Xnor_Operator => 997, + Iir_Kind_And_Operator => 1002, + Iir_Kind_Or_Operator => 1007, + Iir_Kind_Nand_Operator => 1012, + Iir_Kind_Nor_Operator => 1017, + Iir_Kind_Xor_Operator => 1022, + Iir_Kind_Xnor_Operator => 1027, + Iir_Kind_Equality_Operator => 1032, + Iir_Kind_Inequality_Operator => 1037, + Iir_Kind_Less_Than_Operator => 1042, + Iir_Kind_Less_Than_Or_Equal_Operator => 1047, + Iir_Kind_Greater_Than_Operator => 1052, + Iir_Kind_Greater_Than_Or_Equal_Operator => 1057, + Iir_Kind_Match_Equality_Operator => 1062, + Iir_Kind_Match_Inequality_Operator => 1067, + Iir_Kind_Match_Less_Than_Operator => 1072, + Iir_Kind_Match_Less_Than_Or_Equal_Operator => 1077, + Iir_Kind_Match_Greater_Than_Operator => 1082, + Iir_Kind_Match_Greater_Than_Or_Equal_Operator => 1087, + Iir_Kind_Sll_Operator => 1092, + Iir_Kind_Sla_Operator => 1097, + Iir_Kind_Srl_Operator => 1102, + Iir_Kind_Sra_Operator => 1107, + Iir_Kind_Rol_Operator => 1112, + Iir_Kind_Ror_Operator => 1117, + Iir_Kind_Addition_Operator => 1122, + Iir_Kind_Substraction_Operator => 1127, + Iir_Kind_Concatenation_Operator => 1132, + Iir_Kind_Multiplication_Operator => 1137, + Iir_Kind_Division_Operator => 1142, + Iir_Kind_Modulus_Operator => 1147, + Iir_Kind_Remainder_Operator => 1152, + Iir_Kind_Exponentiation_Operator => 1157, + Iir_Kind_Function_Call => 1165, + Iir_Kind_Aggregate => 1171, + Iir_Kind_Parenthesis_Expression => 1174, + Iir_Kind_Qualified_Expression => 1178, + Iir_Kind_Type_Conversion => 1183, + Iir_Kind_Allocator_By_Expression => 1187, + Iir_Kind_Allocator_By_Subtype => 1192, + Iir_Kind_Selected_Element => 1198, + Iir_Kind_Dereference => 1203, + Iir_Kind_Implicit_Dereference => 1208, + Iir_Kind_Slice_Name => 1215, + Iir_Kind_Indexed_Name => 1221, + Iir_Kind_Psl_Expression => 1223, + Iir_Kind_Sensitized_Process_Statement => 1243, + Iir_Kind_Process_Statement => 1263, + Iir_Kind_Concurrent_Simple_Signal_Assignment => 1274, + Iir_Kind_Concurrent_Conditional_Signal_Assignment => 1285, + Iir_Kind_Concurrent_Selected_Signal_Assignment => 1297, + Iir_Kind_Concurrent_Assertion_Statement => 1305, + Iir_Kind_Concurrent_Procedure_Call_Statement => 1312, + Iir_Kind_Psl_Assert_Statement => 1325, + Iir_Kind_Psl_Cover_Statement => 1338, + Iir_Kind_Block_Statement => 1351, + Iir_Kind_If_Generate_Statement => 1361, + Iir_Kind_Case_Generate_Statement => 1370, + Iir_Kind_For_Generate_Statement => 1379, + Iir_Kind_Component_Instantiation_Statement => 1389, + Iir_Kind_Psl_Default_Clock => 1393, + Iir_Kind_Simple_Simultaneous_Statement => 1400, + Iir_Kind_Generate_Statement_Body => 1411, + Iir_Kind_If_Generate_Else_Clause => 1416, + Iir_Kind_Simple_Signal_Assignment_Statement => 1425, + Iir_Kind_Conditional_Signal_Assignment_Statement => 1434, + Iir_Kind_Null_Statement => 1438, + Iir_Kind_Assertion_Statement => 1445, + Iir_Kind_Report_Statement => 1451, + Iir_Kind_Wait_Statement => 1458, + Iir_Kind_Variable_Assignment_Statement => 1464, + Iir_Kind_Conditional_Variable_Assignment_Statement => 1470, + Iir_Kind_Return_Statement => 1476, + Iir_Kind_For_Loop_Statement => 1485, + Iir_Kind_While_Loop_Statement => 1493, + Iir_Kind_Next_Statement => 1499, + Iir_Kind_Exit_Statement => 1505, + Iir_Kind_Case_Statement => 1513, + Iir_Kind_Procedure_Call_Statement => 1519, + Iir_Kind_If_Statement => 1528, + Iir_Kind_Elsif => 1533, + Iir_Kind_Character_Literal => 1540, + Iir_Kind_Simple_Name => 1547, + Iir_Kind_Selected_Name => 1555, + Iir_Kind_Operator_Symbol => 1560, + Iir_Kind_Selected_By_All_Name => 1565, + Iir_Kind_Parenthesis_Name => 1569, + Iir_Kind_External_Constant_Name => 1577, + Iir_Kind_External_Signal_Name => 1585, + Iir_Kind_External_Variable_Name => 1593, + Iir_Kind_Package_Pathname => 1596, + Iir_Kind_Absolute_Pathname => 1597, + Iir_Kind_Relative_Pathname => 1598, + Iir_Kind_Pathname_Element => 1602, + Iir_Kind_Base_Attribute => 1604, + Iir_Kind_Left_Type_Attribute => 1609, + Iir_Kind_Right_Type_Attribute => 1614, + Iir_Kind_High_Type_Attribute => 1619, + Iir_Kind_Low_Type_Attribute => 1624, + Iir_Kind_Ascending_Type_Attribute => 1629, + Iir_Kind_Image_Attribute => 1635, + Iir_Kind_Value_Attribute => 1641, + Iir_Kind_Pos_Attribute => 1647, + Iir_Kind_Val_Attribute => 1653, + Iir_Kind_Succ_Attribute => 1659, + Iir_Kind_Pred_Attribute => 1665, + Iir_Kind_Leftof_Attribute => 1671, + Iir_Kind_Rightof_Attribute => 1677, + Iir_Kind_Delayed_Attribute => 1686, + Iir_Kind_Stable_Attribute => 1695, + Iir_Kind_Quiet_Attribute => 1704, + Iir_Kind_Transaction_Attribute => 1713, + Iir_Kind_Event_Attribute => 1717, + Iir_Kind_Active_Attribute => 1721, + Iir_Kind_Last_Event_Attribute => 1725, + Iir_Kind_Last_Active_Attribute => 1729, + Iir_Kind_Last_Value_Attribute => 1733, + Iir_Kind_Driving_Attribute => 1737, + Iir_Kind_Driving_Value_Attribute => 1741, + Iir_Kind_Behavior_Attribute => 1741, + Iir_Kind_Structure_Attribute => 1741, + Iir_Kind_Simple_Name_Attribute => 1748, + Iir_Kind_Instance_Name_Attribute => 1753, + Iir_Kind_Path_Name_Attribute => 1758, + Iir_Kind_Left_Array_Attribute => 1765, + Iir_Kind_Right_Array_Attribute => 1772, + Iir_Kind_High_Array_Attribute => 1779, + Iir_Kind_Low_Array_Attribute => 1786, + Iir_Kind_Length_Array_Attribute => 1793, + Iir_Kind_Ascending_Array_Attribute => 1800, + Iir_Kind_Range_Array_Attribute => 1807, + Iir_Kind_Reverse_Range_Array_Attribute => 1814, + Iir_Kind_Attribute_Name => 1822 ); function Get_Fields (K : Iir_Kind) return Fields_Array @@ -5113,6 +5139,8 @@ package body Nodes_Meta is return Get_Guard_Expression (N); when Field_Guard_Decl => return Get_Guard_Decl (N); + when Field_Signal_Attribute_Chain => + return Get_Signal_Attribute_Chain (N); when Field_Block_Block_Configuration => return Get_Block_Block_Configuration (N); when Field_Package_Header => @@ -5185,6 +5213,10 @@ package body Nodes_Meta is return Get_Index_Subtype (N); when Field_Parameter => return Get_Parameter (N); + when Field_Attr_Chain => + return Get_Attr_Chain (N); + when Field_Signal_Attribute_Declaration => + return Get_Signal_Attribute_Declaration (N); when Field_Actual_Type => return Get_Actual_Type (N); when Field_Association_Chain => @@ -5501,6 +5533,8 @@ package body Nodes_Meta is Set_Guard_Expression (N, V); when Field_Guard_Decl => Set_Guard_Decl (N, V); + when Field_Signal_Attribute_Chain => + Set_Signal_Attribute_Chain (N, V); when Field_Block_Block_Configuration => Set_Block_Block_Configuration (N, V); when Field_Package_Header => @@ -5573,6 +5607,10 @@ package body Nodes_Meta is Set_Index_Subtype (N, V); when Field_Parameter => Set_Parameter (N, V); + when Field_Attr_Chain => + Set_Attr_Chain (N, V); + when Field_Signal_Attribute_Declaration => + Set_Signal_Attribute_Declaration (N, V); when Field_Actual_Type => Set_Actual_Type (N, V); when Field_Association_Chain => @@ -7032,6 +7070,7 @@ package body Nodes_Meta is | Iir_Kind_Interface_Package_Declaration | Iir_Kind_Interface_Function_Declaration | Iir_Kind_Interface_Procedure_Declaration + | Iir_Kind_Signal_Attribute_Declaration | Iir_Kind_Sensitized_Process_Statement | Iir_Kind_Process_Statement | Iir_Kind_Concurrent_Simple_Signal_Assignment @@ -7066,11 +7105,7 @@ package body Nodes_Meta is | Iir_Kind_If_Statement | Iir_Kind_External_Constant_Name | Iir_Kind_External_Signal_Name - | Iir_Kind_External_Variable_Name - | Iir_Kind_Delayed_Attribute - | Iir_Kind_Stable_Attribute - | Iir_Kind_Quiet_Attribute - | Iir_Kind_Transaction_Attribute => + | Iir_Kind_External_Variable_Name => return True; when others => return False; @@ -8801,6 +8836,11 @@ package body Nodes_Meta is return K = Iir_Kind_Guard_Signal_Declaration; end Has_Guard_Sensitivity_List; + function Has_Signal_Attribute_Chain (K : Iir_Kind) return Boolean is + begin + return K = Iir_Kind_Signal_Attribute_Declaration; + end Has_Signal_Attribute_Chain; + function Has_Block_Block_Configuration (K : Iir_Kind) return Boolean is begin return K = Iir_Kind_Block_Statement; @@ -8964,6 +9004,7 @@ package body Nodes_Meta is | Iir_Kind_Interface_Package_Declaration | Iir_Kind_Interface_Function_Declaration | Iir_Kind_Interface_Procedure_Declaration + | Iir_Kind_Signal_Attribute_Declaration | Iir_Kind_Sensitized_Process_Statement | Iir_Kind_Process_Statement | Iir_Kind_Concurrent_Simple_Signal_Assignment @@ -9597,6 +9638,32 @@ package body Nodes_Meta is end case; end Has_Parameter; + function Has_Attr_Chain (K : Iir_Kind) return Boolean is + begin + case K is + when Iir_Kind_Delayed_Attribute + | Iir_Kind_Stable_Attribute + | Iir_Kind_Quiet_Attribute + | Iir_Kind_Transaction_Attribute => + return True; + when others => + return False; + end case; + end Has_Attr_Chain; + + function Has_Signal_Attribute_Declaration (K : Iir_Kind) return Boolean is + begin + case K is + when Iir_Kind_Delayed_Attribute + | Iir_Kind_Stable_Attribute + | Iir_Kind_Quiet_Attribute + | Iir_Kind_Transaction_Attribute => + return True; + when others => + return False; + end case; + end Has_Signal_Attribute_Declaration; + function Has_Actual_Type (K : Iir_Kind) return Boolean is begin return K = Iir_Kind_Association_Element_By_Individual; diff --git a/src/vhdl/nodes_meta.ads b/src/vhdl/nodes_meta.ads index 44e56dbf1..49ae2c698 100644 --- a/src/vhdl/nodes_meta.ads +++ b/src/vhdl/nodes_meta.ads @@ -271,6 +271,7 @@ package Nodes_Meta is Field_Guard_Expression, Field_Guard_Decl, Field_Guard_Sensitivity_List, + Field_Signal_Attribute_Chain, Field_Block_Block_Configuration, Field_Package_Header, Field_Block_Header, @@ -311,6 +312,8 @@ package Nodes_Meta is Field_Suffix, Field_Index_Subtype, Field_Parameter, + Field_Attr_Chain, + Field_Signal_Attribute_Declaration, Field_Actual_Type, Field_Association_Chain, Field_Individual_Association_Chain, @@ -774,6 +777,7 @@ package Nodes_Meta is function Has_Guard_Expression (K : Iir_Kind) return Boolean; function Has_Guard_Decl (K : Iir_Kind) return Boolean; function Has_Guard_Sensitivity_List (K : Iir_Kind) return Boolean; + function Has_Signal_Attribute_Chain (K : Iir_Kind) return Boolean; function Has_Block_Block_Configuration (K : Iir_Kind) return Boolean; function Has_Package_Header (K : Iir_Kind) return Boolean; function Has_Block_Header (K : Iir_Kind) return Boolean; @@ -816,6 +820,8 @@ package Nodes_Meta is function Has_Suffix (K : Iir_Kind) return Boolean; function Has_Index_Subtype (K : Iir_Kind) return Boolean; function Has_Parameter (K : Iir_Kind) return Boolean; + function Has_Attr_Chain (K : Iir_Kind) return Boolean; + function Has_Signal_Attribute_Declaration (K : Iir_Kind) return Boolean; function Has_Actual_Type (K : Iir_Kind) return Boolean; function Has_Association_Chain (K : Iir_Kind) return Boolean; function Has_Individual_Association_Chain (K : Iir_Kind) return Boolean; diff --git a/src/vhdl/sem_decls.adb b/src/vhdl/sem_decls.adb index 517d69c6c..d8f4c7543 100644 --- a/src/vhdl/sem_decls.adb +++ b/src/vhdl/sem_decls.adb @@ -47,13 +47,14 @@ package body Sem_Decls is -- Region that can declare signals. Used to add implicit declarations. Current_Signals_Region : Implicit_Signal_Declaration_Type := - (Null_Iir, False, Null_Iir, Null_Iir); + (Null_Iir, Null_Iir, Null_Iir, False, Null_Iir); procedure Push_Signals_Declarative_Part (Cell: out Implicit_Signal_Declaration_Type; Decls_Parent : Iir) is begin Cell := Current_Signals_Region; - Current_Signals_Region := (Decls_Parent, False, Null_Iir, Null_Iir); + Current_Signals_Region := + (Decls_Parent, Null_Iir, Null_Iir, False, Null_Iir); end Push_Signals_Declarative_Part; procedure Pop_Signals_Declarative_Part @@ -62,30 +63,95 @@ package body Sem_Decls is Current_Signals_Region := Cell; end Pop_Signals_Declarative_Part; - procedure Add_Declaration_For_Implicit_Signal (Sig : Iir) is + -- Insert the implicit signal declaration after LAST_DECL. + procedure Insert_Implicit_Signal (Last_Decl : Iir) is begin + if Last_Decl = Null_Iir then + Set_Declaration_Chain (Current_Signals_Region.Decls_Parent, + Current_Signals_Region.Implicit_Decl); + else + Set_Chain (Last_Decl, Current_Signals_Region.Implicit_Decl); + end if; + end Insert_Implicit_Signal; + + -- Add SIG as an implicit declaration in the current region. + procedure Add_Declaration_For_Implicit_Signal (Sig : Iir) + is + Decl : Iir; + begin + -- We deal only with signal attribute. + pragma Assert (Get_Kind (Sig) in Iir_Kinds_Signal_Attribute); + -- There must be a declarative part for implicit signals. pragma Assert (Current_Signals_Region.Decls_Parent /= Null_Iir); - -- Chain must be empty. - pragma Assert (Get_Chain (Sig) = Null_Iir); + -- Attr_Chain must be empty. + pragma Assert (Get_Attr_Chain (Sig) = Null_Iir); - if Current_Signals_Region.Decls_Analyzed then - -- Just append. - if Current_Signals_Region.Last_Implicit_Decl = Null_Iir then - -- No declarations. - Set_Declaration_Chain (Current_Signals_Region.Decls_Parent, Sig); - else - -- Append to the last declaration. - Set_Chain (Current_Signals_Region.Last_Implicit_Decl, Sig); + if Current_Signals_Region.Implicit_Decl = Null_Iir then + -- Create the signal_attribute_declaration to hold all the implicit + -- signals. + Decl := Create_Iir (Iir_Kind_Signal_Attribute_Declaration); + Location_Copy (Decl, Sig); + Set_Parent (Decl, Current_Signals_Region.Decls_Parent); + + -- Save the implicit declaration. + Current_Signals_Region.Implicit_Decl := Decl; + + -- Append SIG (this is the first one). + Set_Signal_Attribute_Chain (Decl, Sig); + + if Current_Signals_Region.Decls_Analyzed then + -- Declarative region was completely analyzed. Just append DECL + -- at the end of declarations. + Insert_Implicit_Signal (Current_Signals_Region.Last_Decl); end if; - Current_Signals_Region.Last_Implicit_Decl := Sig; else - Sub_Chain_Append (Current_Signals_Region.First_Implicit_Decl, - Current_Signals_Region.Last_Implicit_Decl, Sig); + -- Append SIG. + Set_Attr_Chain (Current_Signals_Region.Last_Attribute_Signal, Sig); end if; + Current_Signals_Region.Last_Attribute_Signal := Sig; + + Set_Signal_Attribute_Declaration + (Sig, Current_Signals_Region.Implicit_Decl); end Add_Declaration_For_Implicit_Signal; + -- Insert pending implicit declarations after the last analyzed LAST_DECL, + -- and update it. Then the caller has to insert the declaration which + -- created the implicit declarations. + procedure Insert_Pending_Implicit_Declarations + (Parent : Iir; Last_Decl : in out Iir) is + begin + if Current_Signals_Region.Decls_Parent = Parent + and then Current_Signals_Region.Implicit_Decl /= Null_Iir + then + pragma Assert (not Current_Signals_Region.Decls_Analyzed); + + -- Add pending implicit declarations before the current one. + Insert_Implicit_Signal (Last_Decl); + Last_Decl := Current_Signals_Region.Implicit_Decl; + + -- Detach the implicit declaration. + Current_Signals_Region.Implicit_Decl := Null_Iir; + Current_Signals_Region.Last_Attribute_Signal := Null_Iir; + end if; + end Insert_Pending_Implicit_Declarations; + + -- Mark the end of declaration analysis. New implicit declarations will + -- simply be appended to the last declaration. + procedure End_Of_Declarations_For_Implicit_Declarations + (Parent : Iir; Last_Decl : Iir) is + begin + if Current_Signals_Region.Decls_Parent = Parent then + pragma Assert (not Current_Signals_Region.Decls_Analyzed); + + -- All declarations have been analyzed, new implicit declarations + -- will be appended. + Current_Signals_Region.Decls_Analyzed := True; + Current_Signals_Region.Last_Decl := Last_Decl; + end if; + end End_Of_Declarations_For_Implicit_Declarations; + -- Emit an error if the type of DECL is a file type, access type, -- protected type or if a subelement of DECL is an access type. procedure Check_Signal_Type (Decl : Iir) @@ -2980,21 +3046,9 @@ package body Sem_Decls is Check_Post_Attribute_Specification (Attr_Spec_Chain, Decl); end if; - if Current_Signals_Region.Decls_Parent = Parent - and then Current_Signals_Region.First_Implicit_Decl /= Null_Iir - then - -- Add pending implicit declarations before the current one. - if Last_Decl = Null_Iir then - Set_Declaration_Chain - (Parent, Current_Signals_Region.First_Implicit_Decl); - else - Set_Chain - (Last_Decl, Current_Signals_Region.First_Implicit_Decl); - end if; - Last_Decl := Current_Signals_Region.Last_Implicit_Decl; - Sub_Chain_Init (Current_Signals_Region.First_Implicit_Decl, - Current_Signals_Region.Last_Implicit_Decl); - end if; + -- Insert *before* DECL pending implicit signal declarations created + -- for DECL after LAST_DECL. This updates LAST_DECL. + Insert_Pending_Implicit_Declarations (Parent, Last_Decl); if Last_Decl = Null_Iir then -- Append now to handle expand names. @@ -3006,12 +3060,8 @@ package body Sem_Decls is Decl := Get_Chain (Decl); end loop; - if Current_Signals_Region.Decls_Parent = Parent then - -- All declarations have been analyzed, new implicit declarations - -- will be appended. - Current_Signals_Region.Decls_Analyzed := True; - Current_Signals_Region.Last_Implicit_Decl := Last_Decl; - end if; + -- Keep the point of insertion for implicit signal declarations. + End_Of_Declarations_For_Implicit_Declarations (Parent, Last_Decl); end Sem_Declaration_Chain; procedure Check_Full_Declaration (Decls_Parent : Iir; Decl: Iir) diff --git a/src/vhdl/sem_decls.ads b/src/vhdl/sem_decls.ads index 63e29ff6b..39c74d004 100644 --- a/src/vhdl/sem_decls.ads +++ b/src/vhdl/sem_decls.ads @@ -83,18 +83,23 @@ private -- Declaration or statement than will contain implicit declarations. Decls_Parent : Iir; + -- Set to the signal_attribute_declaration when created (ie when the + -- first attribute signal is added). + Implicit_Decl : Iir; + + -- Last attribute signal inserted in the current Implicit_Decl. + Last_Attribute_Signal : Iir; + -- If True, declarations of DECLS_PARENT have already been analyzed. -- So implicit declarations are appended to the parent, and the last - -- declaration is LAST_IMPLICIT_DECL. + -- declaration is LAST_DECL. -- If False, declarations are being analyzed. Implicit declarations - -- are saved in FIRST_IMPLICIT_DECL / LAST_IMPLICIT_DECL and will be + -- are appended to IMPLICIT_DECL/LAST_ATTRIBUTE_SIGNAL and will be -- inserted before the current declaration. Decls_Analyzed : Boolean; - -- If DECLS_ANALYZED is False, this is the chain of implicit - -- declarations. If True, LAST_IMPLICIT_DECL contains the last - -- declaration. - First_Implicit_Decl : Iir; - Last_Implicit_Decl : Iir; + -- Last declaration in the region. If an implicit_decl is createed, it + -- will be appended to LAST_DECL. + Last_Decl : Iir; end record; end Sem_Decls; diff --git a/src/vhdl/translate/trans-chap4.adb b/src/vhdl/translate/trans-chap4.adb index c8e847fc3..3fa188df4 100644 --- a/src/vhdl/translate/trans-chap4.adb +++ b/src/vhdl/translate/trans-chap4.adb @@ -1725,8 +1725,16 @@ package body Trans.Chap4 is when Iir_Kind_Attribute_Specification => Chap5.Translate_Attribute_Specification (Decl); - when Iir_Kinds_Signal_Attribute => - Chap4.Create_Implicit_Signal (Decl); + when Iir_Kind_Signal_Attribute_Declaration => + declare + Sig : Iir; + begin + Sig := Get_Signal_Attribute_Chain (Decl); + while Is_Valid (Sig) loop + Chap4.Create_Implicit_Signal (Sig); + Sig := Get_Attr_Chain (Sig); + end loop; + end; when Iir_Kind_Guard_Signal_Declaration => Create_Signal (Decl); @@ -2455,13 +2463,23 @@ package body Trans.Chap4 is | Iir_Kind_Procedure_Body => null; - when Iir_Kind_Stable_Attribute - | Iir_Kind_Quiet_Attribute - | Iir_Kind_Transaction_Attribute => - Elab_Signal_Attribute (Decl); - - when Iir_Kind_Delayed_Attribute => - Elab_Signal_Delayed_Attribute (Decl); + when Iir_Kind_Signal_Attribute_Declaration => + declare + Sig : Iir; + begin + Sig := Get_Signal_Attribute_Chain (Decl); + while Is_Valid (Sig) loop + case Iir_Kinds_Signal_Attribute (Get_Kind (Sig)) is + when Iir_Kind_Stable_Attribute + | Iir_Kind_Quiet_Attribute + | Iir_Kind_Transaction_Attribute => + Elab_Signal_Attribute (Sig); + when Iir_Kind_Delayed_Attribute => + Elab_Signal_Delayed_Attribute (Sig); + end case; + Sig := Get_Attr_Chain (Sig); + end loop; + end; when Iir_Kind_Group_Template_Declaration | Iir_Kind_Group_Declaration => diff --git a/src/vhdl/translate/trans-rtis.adb b/src/vhdl/translate/trans-rtis.adb index 3da305ff8..77c12a358 100644 --- a/src/vhdl/translate/trans-rtis.adb +++ b/src/vhdl/translate/trans-rtis.adb @@ -2109,17 +2109,12 @@ package body Trans.Rtis is -- Eg: array subtypes. null; when Iir_Kind_Signal_Declaration - | Iir_Kind_Interface_Signal_Declaration - | Iir_Kind_Constant_Declaration - | Iir_Kind_Interface_Constant_Declaration - | Iir_Kind_Variable_Declaration - | Iir_Kind_File_Declaration - | Iir_Kind_Transaction_Attribute - | Iir_Kind_Quiet_Attribute - | Iir_Kind_Stable_Attribute => - null; - when Iir_Kind_Delayed_Attribute => - -- FIXME: to be added. + | Iir_Kind_Interface_Signal_Declaration + | Iir_Kind_Constant_Declaration + | Iir_Kind_Interface_Constant_Declaration + | Iir_Kind_Variable_Declaration + | Iir_Kind_File_Declaration + | Iir_Kind_Signal_Attribute_Declaration => null; when Iir_Kind_Object_Alias_Declaration | Iir_Kind_Attribute_Declaration => @@ -2233,9 +2228,8 @@ package body Trans.Rtis is or else Get_Deferred_Declaration_Flag (Decl) then declare - Info : Object_Info_Acc; + Info : constant Object_Info_Acc := Get_Info (Decl); begin - Info := Get_Info (Decl); Generate_Object (Decl, Info.Object_Rti); Add_Rti_Node (Info.Object_Rti); end; @@ -2250,19 +2244,34 @@ package body Trans.Rtis is Add_Rti_Node (Info.Object_Rti); end; when Iir_Kind_Signal_Declaration - | Iir_Kind_Interface_Signal_Declaration - | Iir_Kind_Transaction_Attribute - | Iir_Kind_Quiet_Attribute - | Iir_Kind_Stable_Attribute => + | Iir_Kind_Interface_Signal_Declaration => declare Info : constant Signal_Info_Acc := Get_Info (Decl); begin Generate_Object (Decl, Info.Signal_Rti); Add_Rti_Node (Info.Signal_Rti); end; - when Iir_Kind_Delayed_Attribute => - -- FIXME: to be added. - null; + when Iir_Kind_Signal_Attribute_Declaration => + declare + Sig : Iir; + Info : Signal_Info_Acc; + begin + Sig := Get_Signal_Attribute_Chain (Decl); + while Is_Valid (Sig) loop + case Iir_Kinds_Signal_Attribute (Get_Kind (Sig)) is + when Iir_Kind_Stable_Attribute + | Iir_Kind_Quiet_Attribute + | Iir_Kind_Transaction_Attribute => + Info := Get_Info (Sig); + Generate_Object (Sig, Info.Signal_Rti); + Add_Rti_Node (Info.Signal_Rti); + when Iir_Kind_Delayed_Attribute => + null; + end case; + Sig := Get_Attr_Chain (Sig); + end loop; + end; + when Iir_Kind_Object_Alias_Declaration | Iir_Kind_Attribute_Declaration => declare -- cgit v1.2.3