1 #ifndef MSP_GL_SL_SPIRVCONSTANTS_H_
2 #define MSP_GL_SL_SPIRVCONSTANTS_H_
10 SPIRV_MAGIC = 0x07230203,
11 SPIRV_MAGIC_REVERSED = 0x03022307,
12 SPIRV_GENERATOR_MSP = 29
20 OP_EXT_INST_IMPORT = 11,
24 OP_EXECUTION_MODE = 16,
33 OP_TYPE_SAMPLED_IMAGE = 27,
35 OP_TYPE_RUNTIME_ARRAY = 29,
38 OP_TYPE_FUNCTION = 33,
39 OP_CONSTANT_TRUE = 41,
40 OP_CONSTANT_FALSE = 42,
42 OP_CONSTANT_COMPOSITE = 44,
43 OP_SPEC_CONSTANT_TRUE = 48,
44 OP_SPEC_CONSTANT_FALSE = 49,
45 OP_SPEC_CONSTANT = 50,
46 OP_SPEC_CONSTANT_COMPOSITE = 51,
47 OP_SPEC_CONSTANT_OP = 52,
49 OP_FUNCTION_PARAMETER = 55,
51 OP_FUNCTION_CALL = 57,
57 OP_MEMBER_DECORATE = 72,
58 OP_VECTOR_SHUFFLE = 79,
59 OP_COMPOSITE_CONSTRUCT = 80,
60 OP_COMPOSITE_EXTRACT = 81,
62 OP_IMAGE_SAMPLE_IMPLICIT_LOD = 87,
63 OP_IMAGE_SAMPLE_EXPLICIT_LOD = 88,
64 OP_IMAGE_SAMPLE_DREF_IMPLICIT_LOD = 89,
65 OP_IMAGE_SAMPLE_DREF_EXPLICIT_LOD = 89,
68 OP_IMAGE_QUERY_SIZE_LOD = 103,
69 OP_CONVERT_F_TO_U = 109,
70 OP_CONVERT_F_TO_S = 110,
71 OP_CONVERT_S_TO_F = 111,
72 OP_CONVERT_U_TO_F = 112,
88 OP_VECTOR_TIMES_SCALAR = 142,
89 OP_MATRIX_TIMES_SCALAR = 143,
90 OP_VECTOR_TIMES_MATRIX = 144,
91 OP_MATRIX_TIMES_VECTOR = 145,
92 OP_MATRIX_TIMES_MATRIX = 146,
93 OP_OUTER_PRODUCT = 147,
99 OP_LOGICAL_EQUAL = 164,
100 OP_LOGICAL_NOT_EQUAL = 165,
102 OP_LOGICAL_AND = 167,
103 OP_LOGICAL_NOT = 168,
106 OP_I_NOT_EQUAL = 171,
107 OP_U_GREATER_THAN = 172,
108 OP_S_GREATER_THAN = 173,
109 OP_U_GREATER_THAN_EQUAL = 174,
110 OP_S_GREATER_THAN_EQUAL = 175,
111 OP_U_LESS_THAN = 176,
112 OP_S_LESS_THAN = 177,
113 OP_U_LESS_THAN_EQUAL = 178,
114 OP_S_LESS_THAN_EQUAL = 179,
115 OP_F_ORD_EQUAL = 180,
116 OP_F_ORD_NOT_EQUAL = 182,
117 OP_F_ORD_LESS_THAN = 184,
118 OP_F_ORD_GREATER_THAN = 186,
119 OP_F_ORD_LESS_THAN_EQUAL = 188,
120 OP_F_ORD_GREATER_THAN_EQUAL = 190,
121 OP_SHIFT_RIGHT_ARITHMETIC = 195,
122 OP_SHIFT_LEFT_LOGICAL = 196,
124 OP_BITWISE_XOR = 198,
125 OP_BITWISE_AND = 199,
127 OP_BIT_FIELD_INSERT = 201,
128 OP_BIT_FIELD_S_EXTRACT = 202,
129 OP_BIT_FIELD_U_EXTRACT = 203,
130 OP_BIT_REVERSE = 204,
137 OP_FWIDTH_FINE = 212,
138 OP_DP_DX_COARSE = 213,
139 OP_DP_DY_COARSE = 214,
140 OP_FWIDTH_COARSE = 215,
141 OP_EMIT_VERTEX = 218,
142 OP_END_PRIMITIVE = 219,
145 OP_SELECTION_MERGE = 247,
148 OP_BRANCH_CONDITIONAL = 250,
151 OP_RETURN_VALUE = 254,
159 CAP_IMAGE_CUBE_ARRAY = 34,
162 CAP_SAMPLED_CUBE_ARRAY = 45,
163 CAP_IMAGE_QUERY = 50,
164 CAP_DERIVATIVE_CONTROL = 51,
165 CAP_INTERPOLATION_FUNCTION = 52
168 enum SpirVExecutionMode
170 EXEC_ORIGIN_LOWER_LEFT = 8,
171 EXEC_INPUT_POINTS = 19,
172 EXEC_INPUT_LINES = 20,
173 EXEC_INPUT_LINES_ADJACENCY = 21,
175 EXEC_INPUT_TRIANGLES_ADJACENCY = 23,
176 EXEC_OUTPUT_VERTICES = 26,
177 EXEC_OUTPUT_POINTS = 27,
178 EXEC_OUTPUT_LINE_STRIP = 28,
179 EXEC_OUTPUT_TRIANGLE_STRIP = 29
182 enum SpirVStorageClass
184 STORAGE_UNIFORM_CONSTANT = 0,
198 DECO_ARRAY_STRIDE = 6,
199 DECO_MATRIX_STRIDE = 7,
203 DECO_DESCRIPTOR_SET = 34,
209 BUILTIN_POSITION = 0,
210 BUILTIN_POINT_SIZE = 1,
211 BUILTIN_CLIP_DISTANCE = 3,
212 BUILTIN_VERTEX_ID = 5,
213 BUILTIN_INSTANCE_ID = 6,
214 BUILTIN_PRIMITIVE_ID = 7,
215 BUILTIN_INVOCATION_ID = 8,
217 BUILTIN_FRAG_COORD = 15,
218 BUILTIN_POINT_COORD = 16,
219 BUILTIN_FRONT_FACING = 17,
220 BUILTIN_SAMPLE_ID = 18,
221 BUILTIN_SAMPLE_POSITION = 19,
222 BUILTIN_FRAG_DEPTH = 22
225 enum SpirVGlslStd450Opcode
228 GLSL450_ROUND_EVEN = 2,
237 GLSL450_RADIANS = 11,
238 GLSL450_DEGREES = 12,
258 GLSL450_INVERSE_SQRT = 32,
259 GLSL450_DETERMINANT = 33,
260 GLSL450_MATRIX_INVERSE = 34,
267 GLSL450_F_CLAMP = 43,
268 GLSL450_U_CLAMP = 44,
269 GLSL450_S_CLAMP = 45,
272 GLSL450_F_SMOOTH_STEP = 49,
275 GLSL450_DISTANCE = 67,
277 GLSL450_NORMALIZE = 69,
278 GLSL450_FACE_FORWARD = 70,
279 GLSL450_REFLECT = 71,
280 GLSL450_REFRACT = 72,
281 GLSL450_FIND_I_LSB = 73,
282 GLSL450_FIND_S_MSB = 74,
283 GLSL450_FIND_U_MSB = 75,
284 GLSL450_INTERPOLATE_AT_CENTROID = 76,
285 GLSL450_INTERPOLATE_AT_SAMPLE = 77,
286 GLSL450_INTERPOLATE_AT_OFFSET = 78