aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/rosa/package/spirv/0012-Add-NonSemanticGraphDebugInfo-instruction-set-591.patch
blob: 39c727b0a354bec01de103b341edc829e44cceed (plain)
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
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
From 3541d11cabd489bfa898ce2da631efab9870979b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?K=C3=A9vin=20Petit?= <kevin.petit@arm.com>
Date: Wed, 13 May 2026 16:59:08 +0100
Subject: [PATCH 12/26] Add NonSemanticGraphDebugInfo instruction set (#591)

Change-Id: Ibd080a73abc630fbd2b3068f9c22ab8c0e01c806

Signed-off-by: Kevin Petit <kevin.petit@arm.com>
---
 BUILD.bazel                                   |  6 ++++
 .../unified1/NonSemanticGraphDebugInfo.h      | 28 +++++++++++++++
 ...t.nonsemantic.graph.debuginfo.grammar.json | 35 +++++++++++++++++++
 tools/buildHeaders/bin/makeExtinstHeaders.py  |  1 +
 4 files changed, 70 insertions(+)
 create mode 100644 include/spirv/unified1/NonSemanticGraphDebugInfo.h
 create mode 100644 include/spirv/unified1/extinst.nonsemantic.graph.debuginfo.grammar.json

diff --git a/BUILD.bazel b/BUILD.bazel
index badf2c1..61ef7e8 100644
--- a/BUILD.bazel
+++ b/BUILD.bazel
@@ -138,6 +138,11 @@ filegroup(
     srcs = ["include/spirv/unified1/extinst.arm.motion-engine.100.grammar.json"],
 )
 
+filegroup(
+    name = "spirv_ext_inst_non_semantic_graph_debuginfo_grammar_unified1",
+    srcs = ["include/spirv/unified1/extinst.nonsemantic.graph.debuginfo.grammar.json"],
+)
+
 cc_library(
     name = "spirv_common_headers",
     hdrs = [
@@ -152,6 +157,7 @@ cc_library(
         "include/spirv/unified1/NonSemanticClspvReflection.h",
         "include/spirv/unified1/NonSemanticDebugBreak.h",
         "include/spirv/unified1/NonSemanticDebugPrintf.h",
+        "include/spirv/unified1/NonSemanticGraphDebugInfo.h",
         "include/spirv/unified1/NonSemanticShaderDebugInfo.h",
         "include/spirv/unified1/NonSemanticShaderDebugInfo100.h",
         "include/spirv/unified1/NonSemanticVkspReflection.h",
diff --git a/include/spirv/unified1/NonSemanticGraphDebugInfo.h b/include/spirv/unified1/NonSemanticGraphDebugInfo.h
new file mode 100644
index 0000000..3046842
--- /dev/null
+++ b/include/spirv/unified1/NonSemanticGraphDebugInfo.h
@@ -0,0 +1,28 @@
+// SPDX-FileCopyrightText: 2022-2026 Arm Ltd.
+// SPDX-License-Identifier: MIT
+
+#ifndef SPIRV_UNIFIED1_NonSemanticGraphDebugInfo_H_
+#define SPIRV_UNIFIED1_NonSemanticGraphDebugInfo_H_
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+enum {
+    NonSemanticGraphDebugInfoRevision = 1,
+    NonSemanticGraphDebugInfoRevision_BitWidthPadding = 0x7fffffff
+};
+
+enum NonSemanticGraphDebugInfoInstructions {
+    NonSemanticGraphDebugInfoDebugGraph = 1,
+    NonSemanticGraphDebugInfoDebugOperation = 2,
+    NonSemanticGraphDebugInfoDebugTensor = 3,
+    NonSemanticGraphDebugInfoInstructionsMax = 0x7fffffff
+};
+
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif // SPIRV_UNIFIED1_NonSemanticGraphDebugInfo_H_
diff --git a/include/spirv/unified1/extinst.nonsemantic.graph.debuginfo.grammar.json b/include/spirv/unified1/extinst.nonsemantic.graph.debuginfo.grammar.json
new file mode 100644
index 0000000..b740775
--- /dev/null
+++ b/include/spirv/unified1/extinst.nonsemantic.graph.debuginfo.grammar.json
@@ -0,0 +1,35 @@
+{
+  "copyright": [
+    "SPDX-FileCopyrightText: 2022-2026 Arm Ltd.",
+    "SPDX-License-Identifier: MIT"
+  ],
+  "revision" : 1,
+  "instructions" : [
+    {
+      "opname" : "DebugGraph",
+      "opcode" : 1,
+      "operands" : [
+        { "kind" : "IdRef", "name" : "Graph" },
+        { "kind" : "IdRef", "name" : "Name" }
+      ]
+    },
+    {
+      "opname" : "DebugOperation",
+      "opcode" : 2,
+      "operands" : [
+        { "kind" : "IdRef", "name" : "DebugGraph" },
+        { "kind" : "IdRef", "name" : "Name" },
+        { "kind" : "IdRef", "name" : "Instructions", "quantifier" : "*" }
+      ]
+    },
+    {
+      "opname" : "DebugTensor",
+      "opcode" : 3,
+      "operands" : [
+        { "kind" : "IdRef", "name" : "Tensor" },
+        { "kind" : "IdRef", "name" : "Name" },
+        { "kind" : "IdRef", "name" : "Index", "quantifier" : "?" }
+      ]
+    }
+  ]
+}
diff --git a/tools/buildHeaders/bin/makeExtinstHeaders.py b/tools/buildHeaders/bin/makeExtinstHeaders.py
index e5fd640..1c9fbfd 100755
--- a/tools/buildHeaders/bin/makeExtinstHeaders.py
+++ b/tools/buildHeaders/bin/makeExtinstHeaders.py
@@ -31,3 +31,4 @@ mk_extinst('NonSemanticDebugBreak', 'extinst.nonsemantic.debugbreak.grammar.json
 mk_extinst('NonSemanticVkspReflection', 'extinst.nonsemantic.vkspreflection.grammar.json')
 mk_extinst('TOSA', 'extinst.tosa.001000.1.grammar.json', 'TOSA.001000.1')
 mk_extinst('ArmMotionEngine', 'extinst.arm.motion-engine.100.grammar.json', 'ArmMotionEngine.100')
+mk_extinst('NonSemanticGraphDebugInfo', 'extinst.nonsemantic.graph.debuginfo.grammar.json')
-- 
2.54.0