-
Notifications
You must be signed in to change notification settings - Fork 23
Expand file tree
/
Copy pathcommon-schema.json
More file actions
111 lines (109 loc) · 3.12 KB
/
common-schema.json
File metadata and controls
111 lines (109 loc) · 3.12 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "Common content used by multiple schemas (reduces copy & paste)",
"summaryDesc": {
"description": "Short summary of the normative rule (just a few words)"
},
"clarificationTextDesc": {
"description": "Provides text to supplement information available in the standards documentation.\nOnly use this until clarifying text is in the standards documentation or its authors have decided against adding it."
},
"clarificationLinkDesc": {
"description": "Provides link to clarification GitHub issue in the standards documentation repository"
},
"noteDesc": {
"description": "A non-normative note about the normative rule"
},
"descriptionDesc": {
"description": "Comprehensive description of the normative rule (sentence, paragraph, or longer)"
},
"kindRuleDesc": {
"description": "The kind of standards object associated with this normative rule\nChoices are extension, extension_dependency, instruction, csr, or csr_field."
},
"instanceRuleDesc": {
"description": "The name of a standards object of the specified kind associated with this normative rule"
},
"instancesRuleDesc": {
"description": "The names of standards objects of the specified kind associated with this normative rule"
},
"implDefBehaviorDesc": {
"description": "A normative rule that allows an implementation choices in how to meet the rule"
},
"implDefCategoryTypeDesc": {
"description": "Category of implementation-defined behavior (if any)"
},
"stringArray": {
"type": "array",
"items": { "type": "string" }
},
"ruleNamePattern" : {
"pattern": "^[a-zA-z][a-zA-z0-9_-]+$"
},
"implDefNamePattern" : {
"pattern": "^[A-Z][A-Z0-9_]+$"
},
"tagNamePattern" : {
"pattern": "^[a-zA-z][:a-zA-z0-9_-]+$"
},
"stdsObjectKind": {
"type": "string",
"enum": ["base", "extension", "extension_dependency", "instruction", "csr", "csr_field"]
},
"bases": {
"type": "string",
"enum": ["Any", "RV32I", "RV32E", "RV64I", "RV64E"]
},
"implDefBehavior": {
"type": "boolean"
},
"implDefCategoryType": {
"type": "string",
"enum": ["WARL", "WLRL"]
},
"ruleName": {
"type": "string",
"$ref": "#/ruleNamePattern"
},
"ruleNameArray": {
"type": "array",
"items": {
"type": "string",
"$ref": "#/ruleNamePattern"
}
},
"implDefName": {
"type": "string",
"$ref": "#/implDefNamePattern"
},
"implDefNameArray": {
"type": "array",
"items": {
"type": "string",
"$ref": "#/implDefNamePattern"
}
},
"tagName": {
"type": "string",
"$ref": "#/tagNamePattern"
},
"tagObject": {
"type": "object",
"properties": {
"name": { "$ref": "#/tagName" },
"context": {
"type": "boolean",
"description": "Indicates tag provided for context to provide clarity for the non-context tag(s)"
}
},
"required": ["name"],
"additionalProperties": false
},
"tagNameArray": {
"type": "array",
"items": {
"anyOf": [
{ "$ref": "#/tagName" },
{ "$ref": "#/tagObject" }
]
}
}
}