Project

General

Profile

Statistics
| Branch: | Tag: | Revision:

lustrec-tests / vhdl_json / vhdl_files / 2-exportOK / ghdl / ghdl / testsuite / vests / vhdl-93 / ashenden / compliant / ch_13_fg_13_21.json @ 3fd18385

History | View | Annotate | Download (7.93 KB)

1
{
2
  "DESIGN_FILE" : {
3
    "design_units" : [{
4
      "contexts" : [["LIBRARY_CLAUSE", [["IDENTIFIER", "ieee"]]], ["USE_CLAUSE", [["SELECTED_NAME", [["SIMPLE_NAME", "ieee"], ["SIMPLE_NAME", "std_logic_1164"]]]]]], "library" : ["ENTITY_DECLARATION", {
5
        "name" : ["IDENTIFIER", "reg"], "generics" : [{
6
          "names" : [["IDENTIFIER", "t_setup"], ["IDENTIFIER", "t_hold"], ["IDENTIFIER", "t_pd"]], "typ" : {
7
            "name" : ["SIMPLE_NAME", "delay_length"]}
8
          }
9
        , {
10
          "names" : [["IDENTIFIER", "width"]], "typ" : {
11
            "name" : ["SIMPLE_NAME", "positive"]}
12
          }
13
        ], "ports" : [{
14
          "names" : [["IDENTIFIER", "clock"]], "mode" : ["in"], "typ" : {
15
            "name" : ["SIMPLE_NAME", "std_logic"]}
16
          }
17
        , {
18
          "names" : [["IDENTIFIER", "reset_n"]], "mode" : ["in"], "typ" : {
19
            "name" : ["SIMPLE_NAME", "std_logic"]}
20
          }
21
        , {
22
          "names" : [["IDENTIFIER", "data_in"]], "mode" : ["in"], "typ" : {
23
            "name" : ["SIMPLE_NAME", "std_logic_vector"], "const" : ["INDEX_CONSTRAINT", {
24
              "ranges" : [["RANGE_WITH_DIRECTION", {
25
                "direction" : "to", "from" : ["EXPRESSION", {
26
                  "args" : [["EXPRESSION", {
27
                    "args" : [["CONSTANT_VALUE", {
28
                      "value" : ["CST_LITERAL", "0"]}
29
                    ]]}
30
                  ]]}
31
                ], "_to" : ["EXPRESSION", {
32
                  "args" : [["EXPRESSION", {
33
                    "id" : "-", "args" : [["EXPRESSION", {
34
                      "args" : [["CALL", ["SIMPLE_NAME", "width"]]]}
35
                    ], ["EXPRESSION", {
36
                      "args" : [["CONSTANT_VALUE", {
37
                        "value" : ["CST_LITERAL", "1"]}
38
                      ]]}
39
                    ]]}
40
                  ]]}
41
                ]}
42
              ]]}
43
            ]}
44
          }
45
        , {
46
          "names" : [["IDENTIFIER", "data_out"]], "mode" : ["out"], "typ" : {
47
            "name" : ["SIMPLE_NAME", "std_logic_vector"], "const" : ["INDEX_CONSTRAINT", {
48
              "ranges" : [["RANGE_WITH_DIRECTION", {
49
                "direction" : "to", "from" : ["EXPRESSION", {
50
                  "args" : [["EXPRESSION", {
51
                    "args" : [["CONSTANT_VALUE", {
52
                      "value" : ["CST_LITERAL", "0"]}
53
                    ]]}
54
                  ]]}
55
                ], "_to" : ["EXPRESSION", {
56
                  "args" : [["EXPRESSION", {
57
                    "id" : "-", "args" : [["EXPRESSION", {
58
                      "args" : [["CALL", ["SIMPLE_NAME", "width"]]]}
59
                    ], ["EXPRESSION", {
60
                      "args" : [["CONSTANT_VALUE", {
61
                        "value" : ["CST_LITERAL", "1"]}
62
                      ]]}
63
                    ]]}
64
                  ]]}
65
                ]}
66
              ]]}
67
            ]}
68
          }
69
        ], "ENTITY_DECLARATIVE_PART" : [], "ENTITY_STATEMENT_PART" : []}
70
      ]}
71
    , {
72
      "contexts" : [], "library" : ["ARCHITECTURE_BODY", {
73
        "name" : ["IDENTIFIER", "gate_level"], "entity" : ["IDENTIFIER", "reg"], "ARCHITECTURE_DECLARATIVE_PART" : [], "ARCHITECTURE_STATEMENT_PART" : [["PROCESS_STATEMENT", {
74
          "id" : ["IDENTIFIER", "store"], "active_sigs" : [["SIMPLE_NAME", "clock"], ["SIMPLE_NAME", "reset_n"]], "PROCESS_STATEMENT_PART" : [["IF_STATEMENT", {
75
            "if_cases" : [{
76
              "if_cond" : ["EXPRESSION", {
77
                "id" : "or", "args" : [["EXPRESSION", {
78
                  "id" : "=", "args" : [["EXPRESSION", {
79
                    "args" : [["EXPRESSION", {
80
                      "args" : [["EXPRESSION", {
81
                        "args" : [["CALL", ["SIMPLE_NAME", "reset_n"]]]}
82
                      ]]}
83
                    ]]}
84
                  ], ["EXPRESSION", {
85
                    "args" : [["EXPRESSION", {
86
                      "args" : [["EXPRESSION", {
87
                        "args" : [["CONSTANT_VALUE", {
88
                          "value" : ["CST_LITERAL", "'0'"]}
89
                        ]]}
90
                      ]]}
91
                    ]]}
92
                  ]]}
93
                ], ["EXPRESSION", {
94
                  "id" : "=", "args" : [["EXPRESSION", {
95
                    "args" : [["EXPRESSION", {
96
                      "args" : [["EXPRESSION", {
97
                        "args" : [["CALL", ["SIMPLE_NAME", "reset_n"]]]}
98
                      ]]}
99
                    ]]}
100
                  ], ["EXPRESSION", {
101
                    "args" : [["EXPRESSION", {
102
                      "args" : [["EXPRESSION", {
103
                        "args" : [["CONSTANT_VALUE", {
104
                          "value" : ["CST_LITERAL", "'L'"]}
105
                        ]]}
106
                      ]]}
107
                    ]]}
108
                  ]]}
109
                ]]}
110
              ], "if_block" : [["SIGNAL_ASSIGNMENT_STATEMENT", {
111
                "lhs" : ["SIMPLE_NAME", "data_out"], "rhs" : [{
112
                  "value" : ["EXPRESSION", {
113
                    "args" : [["EXPRESSION", {
114
                      "args" : [["EXPRESSION", {
115
                        "args" : [["EXPRESSION", {
116
                          "args" : [["AGGREGATE", {
117
                            "elems" : [{
118
                              "choices" : [["OTHERS"]], "expr" : ["EXPRESSION", {
119
                                "args" : [["EXPRESSION", {
120
                                  "args" : [["EXPRESSION", {
121
                                    "args" : [["EXPRESSION", {
122
                                      "args" : [["CONSTANT_VALUE", {
123
                                        "value" : ["CST_LITERAL", "'0'"]}
124
                                      ]]}
125
                                    ]]}
126
                                  ]]}
127
                                ]]}
128
                              ]}
129
                            ]}
130
                          ]]}
131
                        ]]}
132
                      ]]}
133
                    ]]}
134
                  ], "delay" : ["EXPRESSION", {
135
                    "args" : [["EXPRESSION", {
136
                      "args" : [["EXPRESSION", {
137
                        "args" : [["EXPRESSION", {
138
                          "args" : [["CALL", ["SIMPLE_NAME", "t_pd"]]]}
139
                        ]]}
140
                      ]]}
141
                    ]]}
142
                  ]}
143
                ]}
144
              ]]}
145
            , {
146
              "if_cond" : ["EXPRESSION", {
147
                "args" : [["EXPRESSION", {
148
                  "args" : [["EXPRESSION", {
149
                    "args" : [["EXPRESSION", {
150
                      "args" : [["CALL", ["INDEXED_NAME", {
151
                        "id" : ["SIMPLE_NAME", "rising_edge"], "exprs" : [["EXPRESSION", {
152
                          "args" : [["EXPRESSION", {
153
                            "args" : [["EXPRESSION", {
154
                              "args" : [["EXPRESSION", {
155
                                "args" : [["CALL", ["SIMPLE_NAME", "clock"]]]}
156
                              ]]}
157
                            ]]}
158
                          ]]}
159
                        ]]}
160
                      ]]]}
161
                    ]]}
162
                  ]]}
163
                ]]}
164
              ], "if_block" : [["SIGNAL_ASSIGNMENT_STATEMENT", {
165
                "lhs" : ["SIMPLE_NAME", "data_out"], "rhs" : [{
166
                  "value" : ["EXPRESSION", {
167
                    "args" : [["EXPRESSION", {
168
                      "args" : [["EXPRESSION", {
169
                        "args" : [["EXPRESSION", {
170
                          "args" : [["CALL", ["SIMPLE_NAME", "data_in"]]]}
171
                        ]]}
172
                      ]]}
173
                    ]]}
174
                  ], "delay" : ["EXPRESSION", {
175
                    "args" : [["EXPRESSION", {
176
                      "args" : [["EXPRESSION", {
177
                        "args" : [["EXPRESSION", {
178
                          "args" : [["CALL", ["SIMPLE_NAME", "t_pd"]]]}
179
                        ]]}
180
                      ]]}
181
                    ]]}
182
                  ]}
183
                ]}
184
              ]]}
185
            ]}
186
          ]]}
187
        ]]}
188
      ]}
189
    ]}
190
  }