Project

General

Profile

Statistics
| Branch: | Tag: | Revision:

lustrec-tests / vhdl_json / vhdl_files / 2-exportOK / cnes_guidelines / rule / data / STD_06100_good.json @ 3fd18385

History | View | Annotate | Download (14.4 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"]]]]], ["USE_CLAUSE", [["SELECTED_NAME", [["SIMPLE_NAME", "IEEE"], ["SIMPLE_NAME", "numeric_std"]]]]]], "library" : ["ENTITY_DECLARATION", {
5
        "name" : ["IDENTIFIER", "STD_06100_good"], "ports" : [{
6
          "names" : [["IDENTIFIER", "i_Clock"]], "mode" : ["in"], "typ" : {
7
            "name" : ["SIMPLE_NAME", "std_logic"]}
8
          }
9
        , {
10
          "names" : [["IDENTIFIER", "i_Reset_n"]], "mode" : ["in"], "typ" : {
11
            "name" : ["SIMPLE_NAME", "std_logic"]}
12
          }
13
        , {
14
          "names" : [["IDENTIFIER", "i_Enable"]], "mode" : ["in"], "typ" : {
15
            "name" : ["SIMPLE_NAME", "std_logic"]}
16
          }
17
        , {
18
          "names" : [["IDENTIFIER", "i_Length"]], "mode" : ["in"], "typ" : {
19
            "name" : ["SIMPLE_NAME", "std_logic_vector"], "const" : ["INDEX_CONSTRAINT", {
20
              "ranges" : [["RANGE_WITH_DIRECTION", {
21
                "direction" : "downto", "from" : ["EXPRESSION", {
22
                  "args" : [["EXPRESSION", {
23
                    "args" : [["CONSTANT_VALUE", {
24
                      "value" : ["CST_LITERAL", "3"]}
25
                    ]]}
26
                  ]]}
27
                ], "_to" : ["EXPRESSION", {
28
                  "args" : [["EXPRESSION", {
29
                    "args" : [["CONSTANT_VALUE", {
30
                      "value" : ["CST_LITERAL", "0"]}
31
                    ]]}
32
                  ]]}
33
                ]}
34
              ]]}
35
            ]}
36
          }
37
        , {
38
          "names" : [["IDENTIFIER", "o_Count"]], "mode" : ["out"], "typ" : {
39
            "name" : ["SIMPLE_NAME", "std_logic_vector"], "const" : ["INDEX_CONSTRAINT", {
40
              "ranges" : [["RANGE_WITH_DIRECTION", {
41
                "direction" : "downto", "from" : ["EXPRESSION", {
42
                  "args" : [["EXPRESSION", {
43
                    "args" : [["CONSTANT_VALUE", {
44
                      "value" : ["CST_LITERAL", "3"]}
45
                    ]]}
46
                  ]]}
47
                ], "_to" : ["EXPRESSION", {
48
                  "args" : [["EXPRESSION", {
49
                    "args" : [["CONSTANT_VALUE", {
50
                      "value" : ["CST_LITERAL", "0"]}
51
                    ]]}
52
                  ]]}
53
                ]}
54
              ]]}
55
            ]}
56
          }
57
        ], "ENTITY_DECLARATIVE_PART" : [], "ENTITY_STATEMENT_PART" : []}
58
      ]}
59
    , {
60
      "contexts" : [], "library" : ["ARCHITECTURE_BODY", {
61
        "name" : ["IDENTIFIER", "Behavioral"], "entity" : ["IDENTIFIER", "STD_06100_good"], "ARCHITECTURE_DECLARATIVE_PART" : [{
62
          "declaration" : ["SIGNAL_DECLARATION", {
63
            "names" : [["IDENTIFIER", "Count"]], "typ" : {
64
              "name" : ["SIMPLE_NAME", "unsigned"], "const" : ["INDEX_CONSTRAINT", {
65
                "ranges" : [["RANGE_WITH_DIRECTION", {
66
                  "direction" : "downto", "from" : ["EXPRESSION", {
67
                    "args" : [["EXPRESSION", {
68
                      "args" : [["CONSTANT_VALUE", {
69
                        "value" : ["CST_LITERAL", "3"]}
70
                      ]]}
71
                    ]]}
72
                  ], "_to" : ["EXPRESSION", {
73
                    "args" : [["EXPRESSION", {
74
                      "args" : [["CONSTANT_VALUE", {
75
                        "value" : ["CST_LITERAL", "0"]}
76
                      ]]}
77
                    ]]}
78
                  ]}
79
                ]]}
80
              ]}
81
            }
82
          ]}
83
        , {
84
          "declaration" : ["SIGNAL_DECLARATION", {
85
            "names" : [["IDENTIFIER", "Count_Length"]], "typ" : {
86
              "name" : ["SIMPLE_NAME", "unsigned"], "const" : ["INDEX_CONSTRAINT", {
87
                "ranges" : [["RANGE_WITH_DIRECTION", {
88
                  "direction" : "downto", "from" : ["EXPRESSION", {
89
                    "args" : [["EXPRESSION", {
90
                      "args" : [["CONSTANT_VALUE", {
91
                        "value" : ["CST_LITERAL", "3"]}
92
                      ]]}
93
                    ]]}
94
                  ], "_to" : ["EXPRESSION", {
95
                    "args" : [["EXPRESSION", {
96
                      "args" : [["CONSTANT_VALUE", {
97
                        "value" : ["CST_LITERAL", "0"]}
98
                      ]]}
99
                    ]]}
100
                  ]}
101
                ]]}
102
              ]}
103
            }
104
          ]}
105
        ], "ARCHITECTURE_STATEMENT_PART" : [["CONDITIONAL_SIGNAL_ASSIGNMENT", {
106
          "postponed" : false, "lhs" : ["SIMPLE_NAME", "Count_Length"], "rhs" : [{
107
            "expr" : [{
108
              "value" : ["EXPRESSION", {
109
                "args" : [["EXPRESSION", {
110
                  "args" : [["EXPRESSION", {
111
                    "args" : [["EXPRESSION", {
112
                      "args" : [["CALL", ["INDEXED_NAME", {
113
                        "id" : ["SIMPLE_NAME", "unsigned"], "exprs" : [["EXPRESSION", {
114
                          "args" : [["EXPRESSION", {
115
                            "args" : [["EXPRESSION", {
116
                              "args" : [["EXPRESSION", {
117
                                "args" : [["CALL", ["SIMPLE_NAME", "i_Length"]]]}
118
                              ]]}
119
                            ]]}
120
                          ]]}
121
                        ]]}
122
                      ]]]}
123
                    ]]}
124
                  ]]}
125
                ]]}
126
              ]}
127
            ]}
128
          ]}
129
        ], ["PROCESS_STATEMENT", {
130
          "id" : ["IDENTIFIER", "P_Count"], "active_sigs" : [["SIMPLE_NAME", "i_Reset_n"], ["SIMPLE_NAME", "i_Clock"]], "PROCESS_STATEMENT_PART" : [["IF_STATEMENT", {
131
            "if_cases" : [{
132
              "if_cond" : ["EXPRESSION", {
133
                "args" : [["EXPRESSION", {
134
                  "args" : [["EXPRESSION", {
135
                    "args" : [["EXPRESSION", {
136
                      "args" : [["EXPRESSION", {
137
                        "id" : "=", "args" : [["EXPRESSION", {
138
                          "args" : [["EXPRESSION", {
139
                            "args" : [["EXPRESSION", {
140
                              "args" : [["CALL", ["SIMPLE_NAME", "i_Reset_n"]]]}
141
                            ]]}
142
                          ]]}
143
                        ], ["EXPRESSION", {
144
                          "args" : [["EXPRESSION", {
145
                            "args" : [["EXPRESSION", {
146
                              "args" : [["CONSTANT_VALUE", {
147
                                "value" : ["CST_LITERAL", "'0'"]}
148
                              ]]}
149
                            ]]}
150
                          ]]}
151
                        ]]}
152
                      ]]}
153
                    ]]}
154
                  ]]}
155
                ]]}
156
              ], "if_block" : [["SIGNAL_ASSIGNMENT_STATEMENT", {
157
                "lhs" : ["SIMPLE_NAME", "Count"], "rhs" : [{
158
                  "value" : ["EXPRESSION", {
159
                    "args" : [["EXPRESSION", {
160
                      "args" : [["EXPRESSION", {
161
                        "args" : [["EXPRESSION", {
162
                          "args" : [["AGGREGATE", {
163
                            "elems" : [{
164
                              "choices" : [["OTHERS"]], "expr" : ["EXPRESSION", {
165
                                "args" : [["EXPRESSION", {
166
                                  "args" : [["EXPRESSION", {
167
                                    "args" : [["EXPRESSION", {
168
                                      "args" : [["CONSTANT_VALUE", {
169
                                        "value" : ["CST_LITERAL", "'0'"]}
170
                                      ]]}
171
                                    ]]}
172
                                  ]]}
173
                                ]]}
174
                              ]}
175
                            ]}
176
                          ]]}
177
                        ]]}
178
                      ]]}
179
                    ]]}
180
                  ]}
181
                ]}
182
              ]]}
183
            , {
184
              "if_cond" : ["EXPRESSION", {
185
                "args" : [["EXPRESSION", {
186
                  "args" : [["EXPRESSION", {
187
                    "args" : [["EXPRESSION", {
188
                      "args" : [["EXPRESSION", {
189
                        "args" : [["EXPRESSION", {
190
                          "args" : [["EXPRESSION", {
191
                            "args" : [["EXPRESSION", {
192
                              "args" : [["CALL", ["INDEXED_NAME", {
193
                                "id" : ["SIMPLE_NAME", "rising_edge"], "exprs" : [["EXPRESSION", {
194
                                  "args" : [["EXPRESSION", {
195
                                    "args" : [["EXPRESSION", {
196
                                      "args" : [["EXPRESSION", {
197
                                        "args" : [["CALL", ["SIMPLE_NAME", "i_Clock"]]]}
198
                                      ]]}
199
                                    ]]}
200
                                  ]]}
201
                                ]]}
202
                              ]]]}
203
                            ]]}
204
                          ]]}
205
                        ]]}
206
                      ]]}
207
                    ]]}
208
                  ]]}
209
                ]]}
210
              ], "if_block" : [["IF_STATEMENT", {
211
                "if_cases" : [{
212
                  "if_cond" : ["EXPRESSION", {
213
                    "args" : [["EXPRESSION", {
214
                      "args" : [["EXPRESSION", {
215
                        "args" : [["EXPRESSION", {
216
                          "args" : [["EXPRESSION", {
217
                            "id" : ">=", "args" : [["EXPRESSION", {
218
                              "args" : [["EXPRESSION", {
219
                                "args" : [["EXPRESSION", {
220
                                  "args" : [["CALL", ["SIMPLE_NAME", "Count"]]]}
221
                                ]]}
222
                              ]]}
223
                            ], ["EXPRESSION", {
224
                              "args" : [["EXPRESSION", {
225
                                "args" : [["EXPRESSION", {
226
                                  "args" : [["CALL", ["SIMPLE_NAME", "Count_Length"]]]}
227
                                ]]}
228
                              ]]}
229
                            ]]}
230
                          ]]}
231
                        ]]}
232
                      ]]}
233
                    ]]}
234
                  ], "if_block" : [["SIGNAL_ASSIGNMENT_STATEMENT", {
235
                    "lhs" : ["SIMPLE_NAME", "Count"], "rhs" : [{
236
                      "value" : ["EXPRESSION", {
237
                        "args" : [["EXPRESSION", {
238
                          "args" : [["EXPRESSION", {
239
                            "args" : [["EXPRESSION", {
240
                              "args" : [["AGGREGATE", {
241
                                "elems" : [{
242
                                  "choices" : [["OTHERS"]], "expr" : ["EXPRESSION", {
243
                                    "args" : [["EXPRESSION", {
244
                                      "args" : [["EXPRESSION", {
245
                                        "args" : [["EXPRESSION", {
246
                                          "args" : [["CONSTANT_VALUE", {
247
                                            "value" : ["CST_LITERAL", "'0'"]}
248
                                          ]]}
249
                                        ]]}
250
                                      ]]}
251
                                    ]]}
252
                                  ]}
253
                                ]}
254
                              ]]}
255
                            ]]}
256
                          ]]}
257
                        ]]}
258
                      ]}
259
                    ]}
260
                  ]]}
261
                , {
262
                  "if_cond" : ["EXPRESSION", {
263
                    "args" : [["EXPRESSION", {
264
                      "args" : [["EXPRESSION", {
265
                        "args" : [["EXPRESSION", {
266
                          "args" : [["EXPRESSION", {
267
                            "id" : "=", "args" : [["EXPRESSION", {
268
                              "args" : [["EXPRESSION", {
269
                                "args" : [["EXPRESSION", {
270
                                  "args" : [["CALL", ["SIMPLE_NAME", "i_Enable"]]]}
271
                                ]]}
272
                              ]]}
273
                            ], ["EXPRESSION", {
274
                              "args" : [["EXPRESSION", {
275
                                "args" : [["EXPRESSION", {
276
                                  "args" : [["CONSTANT_VALUE", {
277
                                    "value" : ["CST_LITERAL", "'1'"]}
278
                                  ]]}
279
                                ]]}
280
                              ]]}
281
                            ]]}
282
                          ]]}
283
                        ]]}
284
                      ]]}
285
                    ]]}
286
                  ], "if_block" : [["SIGNAL_ASSIGNMENT_STATEMENT", {
287
                    "lhs" : ["SIMPLE_NAME", "Count"], "rhs" : [{
288
                      "value" : ["EXPRESSION", {
289
                        "args" : [["EXPRESSION", {
290
                          "args" : [["EXPRESSION", {
291
                            "args" : [["EXPRESSION", {
292
                              "id" : "+", "args" : [["EXPRESSION", {
293
                                "args" : [["CALL", ["SIMPLE_NAME", "Count"]]]}
294
                              ], ["EXPRESSION", {
295
                                "args" : [["CONSTANT_VALUE", {
296
                                  "value" : ["CST_LITERAL", "1"]}
297
                                ]]}
298
                              ]]}
299
                            ]]}
300
                          ]]}
301
                        ]]}
302
                      ]}
303
                    ]}
304
                  ]]}
305
                ]}
306
              ]]}
307
            ]}
308
          ]]}
309
        ], ["CONDITIONAL_SIGNAL_ASSIGNMENT", {
310
          "postponed" : false, "lhs" : ["SIMPLE_NAME", "o_Count"], "rhs" : [{
311
            "expr" : [{
312
              "value" : ["EXPRESSION", {
313
                "args" : [["EXPRESSION", {
314
                  "args" : [["EXPRESSION", {
315
                    "args" : [["EXPRESSION", {
316
                      "args" : [["CALL", ["INDEXED_NAME", {
317
                        "id" : ["SIMPLE_NAME", "std_logic_vector"], "exprs" : [["EXPRESSION", {
318
                          "args" : [["EXPRESSION", {
319
                            "args" : [["EXPRESSION", {
320
                              "args" : [["EXPRESSION", {
321
                                "args" : [["CALL", ["SIMPLE_NAME", "Count"]]]}
322
                              ]]}
323
                            ]]}
324
                          ]]}
325
                        ]]}
326
                      ]]]}
327
                    ]]}
328
                  ]]}
329
                ]]}
330
              ]}
331
            ]}
332
          ]}
333
        ]]}
334
      ]}
335
    ]}
336
  }