File: SPIRVSymbolicOperands.td

package info (click to toggle)
llvm-toolchain-17 1%3A17.0.6-22
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,799,624 kB
  • sloc: cpp: 6,428,607; ansic: 1,383,196; asm: 793,408; python: 223,504; objc: 75,364; f90: 60,502; lisp: 33,869; pascal: 15,282; sh: 9,684; perl: 7,453; ml: 4,937; awk: 3,523; makefile: 2,889; javascript: 2,149; xml: 888; fortran: 619; cs: 573
file content (1535 lines) | stat: -rw-r--r-- 76,703 bytes parent folder | download | duplicates (9)
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
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
//===- SPIRVSymbolicOperands.td ----------------------------*- tablegen -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//
//
// This file defines symbolic/named operands for various SPIR-V instructions.
//
//===----------------------------------------------------------------------===//

include "llvm/TableGen/SearchableTable.td"

//===----------------------------------------------------------------------===//
// Lookup table containing symbolic operands with the following columns:
// - Category (Extension/Capability/BuiltIn/etc.)
// - Value (32-bit representation for binary emission)
// - Mnemonic (String representation for textual emission)
// - MinVersion
// - MaxVersion
//===----------------------------------------------------------------------===//

// Forward-declare classes used in SymbolicOperand
class OperandCategory;

class SymbolicOperand<OperandCategory category, bits<32> value, string mnemonic, bits<32> minVersion, bits<32> maxVersion> {
  OperandCategory Category = category;
  bits<32> Value = value;
  string Mnemonic = mnemonic;
  bits<32> MinVersion = minVersion;
  bits<32> MaxVersion = maxVersion;
}

def SymbolicOperands : GenericTable {
  let FilterClass = "SymbolicOperand";
  let Fields = ["Category", "Value", "Mnemonic", "MinVersion", "MaxVersion"];
  string TypeOf_Category = "OperandCategory";
  let PrimaryKey = ["Category", "Value"];
  // Function for looking up symbolic operands based on category and value.
  let PrimaryKeyName = "lookupSymbolicOperandByCategoryAndValue";
}

// Function for looking up symbolic operands based on just category.
def lookupSymbolicOperandByCategory : SearchIndex {
  let Table = SymbolicOperands;
  let Key = ["Category"];
}

// Function for looking up symbolic operands based on category and mnemonic.
def lookupSymbolicOperandByCategoryAndMnemonic : SearchIndex {
  let Table = SymbolicOperands;
  let Key = ["Category", "Mnemonic"];
}

//===----------------------------------------------------------------------===//
// Lookup table for matching symbolic operands (category + 32-bit value) to
// a SPIR-V extension.
//===----------------------------------------------------------------------===//

// Forward-declare classes used in ExtensionEntry
class Extension;

class ExtensionEntry<OperandCategory category, bits<32> value, Extension reqExtension> {
  OperandCategory Category = category;
  bits<32> Value = value;
  Extension ReqExtension = reqExtension;
}

def ExtensionEntries : GenericTable {
  let FilterClass = "ExtensionEntry";
  let Fields = ["Category", "Value", "ReqExtension"];
  string TypeOf_Category = "OperandCategory";
  string TypeOf_ReqExtension = "Extension";
  let PrimaryKey = ["Category", "Value"];
  // Function for looking up the extension by category + value.
  let PrimaryKeyName = "lookupExtensionByCategoryAndValue";
}

//===----------------------------------------------------------------------===//
// Lookup table for matching symbolic operands (category + 32-bit value) to
// SPIR-V capabilities. If an operand requires more than one capability, there
// will be multiple consecutive entries present in the table.
//===----------------------------------------------------------------------===//

// Forward-declare classes used in ExtensionEntry
class Capability;

class CapabilityEntry<OperandCategory category, bits<32> value, Capability reqCabaility> {
  OperandCategory Category = category;
  bits<32> Value = value;
  Capability ReqCapability = reqCabaility;
}

def CapabilityEntries : GenericTable {
  let FilterClass = "CapabilityEntry";
  let Fields = ["Category", "Value", "ReqCapability"];
  string TypeOf_Category = "OperandCategory";
  string TypeOf_ReqCapability = "Capability";
  let PrimaryKey = ["Category", "Value"];
  // Function for looking up a (the first) capability by category + value. Next
  // capabilities should be consecutive.
  let PrimaryKeyName = "lookupCapabilityByCategoryAndValue";
}

//===----------------------------------------------------------------------===//
// Multiclass used to define a SymbolicOperand and at the same time declare
// required extension and capabilities.
//===----------------------------------------------------------------------===//

multiclass SymbolicOperandWithRequirements<OperandCategory category, bits<32> value, string mnemonic, bits<32> minVersion, bits<32> maxVersion, list<Extension> reqExtensions, list<Capability> reqCapabilities> {
    assert !ge(!size(mnemonic), 1), "No mnemonic/string representation provided for symbolic operand with value " # value;
    def : SymbolicOperand<category, value, mnemonic, minVersion, maxVersion>;

    assert !le(!size(reqExtensions), 1), "Too many required extensions for a symbolic/named operand: " # mnemonic;
    if !eq(!size(reqExtensions), 1) then {
        def : ExtensionEntry<category, value, reqExtensions[0]>;
    }

    foreach capability = reqCapabilities in {
        def : CapabilityEntry<category, value, capability>;
    }
}

//===----------------------------------------------------------------------===//
// Enum defining different categories of symbolic/named operands.
//===----------------------------------------------------------------------===//

def OperandCategory : GenericEnum {
  let FilterClass = "OperandCategory";
}

class OperandCategory;

def ExtensionOperand : OperandCategory;
def CapabilityOperand : OperandCategory;
def SourceLanguageOperand : OperandCategory;
def AddressingModelOperand : OperandCategory;
def ExecutionModelOperand : OperandCategory;
def MemoryModelOperand : OperandCategory;
def ExecutionModeOperand : OperandCategory;
def StorageClassOperand : OperandCategory;
def DimOperand : OperandCategory;
def SamplerAddressingModeOperand : OperandCategory;
def SamplerFilterModeOperand : OperandCategory;
def ImageFormatOperand : OperandCategory;
def ImageChannelOrderOperand : OperandCategory;
def ImageChannelDataTypeOperand : OperandCategory;
def ImageOperandOperand : OperandCategory;
def FPFastMathModeOperand : OperandCategory;
def FPRoundingModeOperand : OperandCategory;
def LinkageTypeOperand : OperandCategory;
def AccessQualifierOperand : OperandCategory;
def FunctionParameterAttributeOperand : OperandCategory;
def DecorationOperand : OperandCategory;
def BuiltInOperand : OperandCategory;
def SelectionControlOperand : OperandCategory;
def LoopControlOperand : OperandCategory;
def FunctionControlOperand : OperandCategory;
def MemorySemanticsOperand : OperandCategory;
def MemoryOperandOperand : OperandCategory;
def ScopeOperand : OperandCategory;
def GroupOperationOperand : OperandCategory;
def KernelEnqueueFlagsOperand : OperandCategory;
def KernelProfilingInfoOperand : OperandCategory;
def OpcodeOperand : OperandCategory;

//===----------------------------------------------------------------------===//
// Multiclass used to define Extesions enum values and at the same time
// SymbolicOperand entries.
//===----------------------------------------------------------------------===//

def Extension : GenericEnum, Operand<i32> {
  let FilterClass = "Extension";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = "printExtension";
}

class Extension<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass ExtensionOperand<bits<32> value> {
  def NAME : Extension<NAME, value>;
  defm : SymbolicOperandWithRequirements<ExtensionOperand, value, NAME, 0, 0, [], []>;
}

defm SPV_AMD_shader_explicit_vertex_parameter : ExtensionOperand<1>;
defm SPV_AMD_shader_trinary_minmax_extension : ExtensionOperand<2>;
defm SPV_AMD_gcn_shader : ExtensionOperand<3>;
defm SPV_KHR_shader_ballot : ExtensionOperand<4>;
defm SPV_AMD_shader_ballot : ExtensionOperand<5>;
defm SPV_AMD_gpu_shader_half_float : ExtensionOperand<6>;
defm SPV_KHR_shader_draw_parameters : ExtensionOperand<7>;
defm SPV_KHR_subgroup_vote : ExtensionOperand<8>;
defm SPV_KHR_16bit_storeage : ExtensionOperand<9>;
defm SPV_KHR_device_group : ExtensionOperand<10>;
defm SPV_KHR_multiview : ExtensionOperand<11>;
defm SPV_NVX_multiview_per_view_attributes : ExtensionOperand<12>;
defm SPV_NV_viewport_array2 : ExtensionOperand<13>;
defm SPV_NV_stereo_view_rendering : ExtensionOperand<14>;
defm SPV_NV_sample_mask_override_coverage : ExtensionOperand<15>;
defm SPV_NV_geometry_shader_passthrough : ExtensionOperand<16>;
defm SPV_AMD_texture_gather_bias_lod : ExtensionOperand<17>;
defm SPV_KHR_storage_buffer_storage_class : ExtensionOperand<18>;
defm SPV_KHR_variable_pointers : ExtensionOperand<19>;
defm SPV_AMD_gpu_shader_int16 : ExtensionOperand<20>;
defm SPV_KHR_post_depth_coverage : ExtensionOperand<21>;
defm SPV_KHR_shader_atomic_counter_ops : ExtensionOperand<22>;
defm SPV_EXT_shader_stencil_export : ExtensionOperand<23>;
defm SPV_EXT_shader_viewport_index_layer : ExtensionOperand<24>;
defm SPV_AMD_shader_image_load_store_lod : ExtensionOperand<25>;
defm SPV_AMD_shader_fragment_mask : ExtensionOperand<26>;
defm SPV_EXT_fragment_fully_covered : ExtensionOperand<27>;
defm SPV_AMD_gpu_shader_half_float_fetch : ExtensionOperand<28>;
defm SPV_GOOGLE_decorate_string : ExtensionOperand<29>;
defm SPV_GOOGLE_hlsl_functionality1 : ExtensionOperand<30>;
defm SPV_NV_shader_subgroup_partitioned : ExtensionOperand<31>;
defm SPV_EXT_descriptor_indexing : ExtensionOperand<32>;
defm SPV_KHR_8bit_storage : ExtensionOperand<33>;
defm SPV_KHR_vulkan_memory_model : ExtensionOperand<34>;
defm SPV_NV_ray_tracing : ExtensionOperand<35>;
defm SPV_NV_compute_shader_derivatives : ExtensionOperand<36>;
defm SPV_NV_fragment_shader_barycentric : ExtensionOperand<37>;
defm SPV_NV_mesh_shader : ExtensionOperand<38>;
defm SPV_NV_shader_image_footprint : ExtensionOperand<39>;
defm SPV_NV_shading_rate : ExtensionOperand<40>;
defm SPV_INTEL_subgroups : ExtensionOperand<41>;
defm SPV_INTEL_media_block_io : ExtensionOperand<42>;
defm SPV_EXT_fragment_invocation_density : ExtensionOperand<44>;
defm SPV_KHR_no_integer_wrap_decoration : ExtensionOperand<45>;
defm SPV_KHR_float_controls : ExtensionOperand<46>;
defm SPV_EXT_physical_storage_buffer : ExtensionOperand<47>;
defm SPV_INTEL_fpga_memory_attributes : ExtensionOperand<48>;
defm SPV_NV_cooperative_matrix : ExtensionOperand<49>;
defm SPV_INTEL_shader_integer_functions2 : ExtensionOperand<50>;
defm SPV_INTEL_fpga_loop_controls : ExtensionOperand<51>;
defm SPV_EXT_fragment_shader_interlock : ExtensionOperand<52>;
defm SPV_NV_shader_sm_builtins : ExtensionOperand<53>;
defm SPV_KHR_shader_clock : ExtensionOperand<54>;
defm SPV_INTEL_unstructured_loop_controls : ExtensionOperand<55>;
defm SPV_EXT_demote_to_helper_invocation : ExtensionOperand<56>;
defm SPV_INTEL_fpga_reg : ExtensionOperand<57>;

//===----------------------------------------------------------------------===//
// Multiclass used to define Capabilities enum values and at the same time
// SymbolicOperand entries with string mnemonics, versioning, extensions, and
// capabilities.
//===----------------------------------------------------------------------===//

def Capability : GenericEnum, Operand<i32> {
  let FilterClass = "Capability";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class Capability<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass CapabilityOperand<bits<32> value, bits<32> minVersion, bits<32> maxVersion, list<Extension> reqExtensions, list<Capability> reqCapabilities> {
  def NAME : Capability<NAME, value>;
  defm : SymbolicOperandWithRequirements<CapabilityOperand, value, NAME, minVersion, maxVersion, reqExtensions, reqCapabilities>;
}

defm Matrix : CapabilityOperand<0, 0, 0, [], []>;
defm Shader : CapabilityOperand<1, 0, 0, [], [Matrix]>;
defm Geometry : CapabilityOperand<2, 0, 0, [], [Shader]>;
defm Tessellation : CapabilityOperand<3, 0, 0, [], [Shader]>;
defm Addresses : CapabilityOperand<4, 0, 0, [], []>;
defm Linkage : CapabilityOperand<5, 0, 0, [], []>;
defm Kernel : CapabilityOperand<6, 0, 0, [], []>;
defm Vector16 : CapabilityOperand<7, 0, 0, [], [Kernel]>;
defm Float16Buffer : CapabilityOperand<8, 0, 0, [], [Kernel]>;
defm Float16 : CapabilityOperand<9, 0, 0, [], []>;
defm Float64 : CapabilityOperand<10, 0, 0, [], []>;
defm Int64 : CapabilityOperand<11, 0, 0, [], []>;
defm Int64Atomics : CapabilityOperand<12, 0, 0, [], [Int64]>;
defm ImageBasic : CapabilityOperand<13, 0, 0, [], [Kernel]>;
defm ImageReadWrite : CapabilityOperand<14, 0, 0, [], [ImageBasic]>;
defm ImageMipmap : CapabilityOperand<15, 0, 0, [], [ImageBasic]>;
defm Pipes : CapabilityOperand<17, 0, 0, [], [Kernel]>;
defm Groups : CapabilityOperand<18, 0, 0, [], []>;
defm DeviceEnqueue : CapabilityOperand<19, 0, 0, [], []>;
defm LiteralSampler : CapabilityOperand<20, 0, 0, [], [Kernel]>;
defm AtomicStorage : CapabilityOperand<21, 0, 0, [], [Shader]>;
defm Int16 : CapabilityOperand<22, 0, 0, [], []>;
defm TessellationPointSize : CapabilityOperand<23, 0, 0, [], [Tessellation]>;
defm GeometryPointSize : CapabilityOperand<24, 0, 0, [], [Geometry]>;
defm ImageGatherExtended : CapabilityOperand<25, 0, 0, [], [Shader]>;
defm StorageImageMultisample : CapabilityOperand<27, 0, 0, [], [Shader]>;
defm UniformBufferArrayDynamicIndexing : CapabilityOperand<28, 0, 0, [], [Shader]>;
defm SampledImageArrayDymnamicIndexing : CapabilityOperand<29, 0, 0, [], [Shader]>;
defm ClipDistance : CapabilityOperand<32, 0, 0, [], [Shader]>;
defm CullDistance : CapabilityOperand<33, 0, 0, [], [Shader]>;
defm SampleRateShading : CapabilityOperand<35, 0, 0, [], [Shader]>;
defm SampledRect : CapabilityOperand<37, 0, 0, [], [Shader]>;
defm ImageRect : CapabilityOperand<36, 0, 0, [], [SampledRect]>;
defm GenericPointer : CapabilityOperand<38, 0, 0, [], [Addresses]>;
defm Int8 : CapabilityOperand<39, 0, 0, [], []>;
defm InputAttachment : CapabilityOperand<40, 0, 0, [], [Shader]>;
defm SparseResidency : CapabilityOperand<41, 0, 0, [], [Shader]>;
defm MinLod : CapabilityOperand<42, 0, 0, [], [Shader]>;
defm Sampled1D : CapabilityOperand<43, 0, 0, [], []>;
defm Image1D : CapabilityOperand<44, 0, 0, [], [Sampled1D]>;
defm SampledCubeArray : CapabilityOperand<45, 0, 0, [], [Shader]>;
defm ImageCubeArray : CapabilityOperand<34, 0, 0, [], [SampledCubeArray]>;
defm SampledBuffer : CapabilityOperand<46, 0, 0, [], []>;
defm ImageBuffer : CapabilityOperand<47, 0, 0, [], [SampledBuffer]>;
defm ImageMSArray : CapabilityOperand<48, 0, 0, [], [Shader]>;
defm StorageImageExtendedFormats : CapabilityOperand<49, 0, 0, [], [Shader]>;
defm ImageQuery : CapabilityOperand<50, 0, 0, [], [Shader]>;
defm DerivativeControl : CapabilityOperand<51, 0, 0, [], [Shader]>;
defm InterpolationFunction : CapabilityOperand<52, 0, 0, [], [Shader]>;
defm TransformFeedback : CapabilityOperand<53, 0, 0, [], [Shader]>;
defm GeometryStreams : CapabilityOperand<54, 0, 0, [], [Geometry]>;
defm StorageImageReadWithoutFormat : CapabilityOperand<55, 0, 0, [], [Shader]>;
defm StorageImageWriteWithoutFormat : CapabilityOperand<56, 0, 0, [], [Shader]>;
defm MultiViewport : CapabilityOperand<57, 0, 0, [], [Geometry]>;
defm SubgroupDispatch : CapabilityOperand<58, 0x10100, 0, [], [DeviceEnqueue]>;
defm NamedBarrier : CapabilityOperand<59, 0x10100, 0, [], [Kernel]>;
defm PipeStorage : CapabilityOperand<60, 0x10100, 0, [], [Pipes]>;
defm GroupNonUniform : CapabilityOperand<61, 0x10300, 0, [], []>;
defm GroupNonUniformVote : CapabilityOperand<62, 0x10300, 0, [], [GroupNonUniform]>;
defm GroupNonUniformArithmetic : CapabilityOperand<63, 0x10300, 0, [], [GroupNonUniform]>;
defm GroupNonUniformBallot : CapabilityOperand<64, 0x10300, 0, [], [GroupNonUniform]>;
defm GroupNonUniformShuffle : CapabilityOperand<65, 0x10300, 0, [], [GroupNonUniform]>;
defm GroupNonUniformShuffleRelative : CapabilityOperand<66, 0x10300, 0, [], [GroupNonUniform]>;
defm GroupNonUniformClustered : CapabilityOperand<67, 0x10300, 0, [], [GroupNonUniform]>;
defm GroupNonUniformQuad : CapabilityOperand<68, 0x10300, 0, [], [GroupNonUniform]>;
defm SubgroupBallotKHR : CapabilityOperand<4423, 0, 0, [SPV_KHR_shader_ballot], []>;
defm DrawParameters : CapabilityOperand<4427, 0x10300, 0, [SPV_KHR_shader_draw_parameters], [Shader]>;
defm SubgroupVoteKHR : CapabilityOperand<4431, 0, 0, [SPV_KHR_subgroup_vote], []>;
defm StorageBuffer16BitAccess : CapabilityOperand<4433, 0x10300, 0, [SPV_KHR_16bit_storeage], []>;
defm StorageUniform16 : CapabilityOperand<4434, 0x10300, 0, [SPV_KHR_16bit_storeage], [StorageBuffer16BitAccess]>;
defm StoragePushConstant16 : CapabilityOperand<4435, 0x10300, 0, [SPV_KHR_16bit_storeage], []>;
defm StorageInputOutput16 : CapabilityOperand<4436, 0x10300, 0, [SPV_KHR_16bit_storeage], []>;
defm DeviceGroup : CapabilityOperand<4437, 0x10300, 0, [SPV_KHR_device_group], []>;
defm MultiView : CapabilityOperand<4439, 0x10300, 0, [SPV_KHR_multiview], [Shader]>;
defm VariablePointersStorageBuffer : CapabilityOperand<4441, 0x10300, 0, [SPV_KHR_variable_pointers], [Shader]>;
defm VariablePointers : CapabilityOperand<4442, 0x10300, 0, [SPV_KHR_variable_pointers], [VariablePointersStorageBuffer]>;
defm AtomicStorageOps : CapabilityOperand<4445, 0, 0, [SPV_KHR_shader_atomic_counter_ops], []>;
defm SampleMaskPostDepthCoverage : CapabilityOperand<4447, 0, 0, [SPV_KHR_post_depth_coverage], []>;
defm StorageBuffer8BitAccess : CapabilityOperand<4448, 0, 0, [SPV_KHR_8bit_storage], []>;
defm UniformAndStorageBuffer8BitAccess : CapabilityOperand<4449, 0, 0, [SPV_KHR_8bit_storage], [StorageBuffer8BitAccess]>;
defm StoragePushConstant8 : CapabilityOperand<4450, 0, 0, [SPV_KHR_8bit_storage], []>;
defm DenormPreserve : CapabilityOperand<4464, 0x10400, 0, [SPV_KHR_float_controls], []>;
defm DenormFlushToZero : CapabilityOperand<4465, 0x10400, 0, [SPV_KHR_float_controls], []>;
defm SignedZeroInfNanPreserve : CapabilityOperand<4466, 0x10400, 0, [SPV_KHR_float_controls], []>;
defm RoundingModeRTE : CapabilityOperand<4467, 0x10400, 0, [SPV_KHR_float_controls], []>;
defm RoundingModeRTZ : CapabilityOperand<4468, 0x10400, 0, [SPV_KHR_float_controls], []>;
defm Float16ImageAMD : CapabilityOperand<5008, 0, 0, [], [Shader]>;
defm ImageGatherBiasLodAMD : CapabilityOperand<5009, 0, 0, [], [Shader]>;
defm FragmentMaskAMD : CapabilityOperand<5010, 0, 0, [], [Shader]>;
defm StencilExportEXT : CapabilityOperand<5013, 0, 0, [], [Shader]>;
defm ImageReadWriteLodAMD : CapabilityOperand<5015, 0, 0, [], [Shader]>;
defm SampleMaskOverrideCoverageNV : CapabilityOperand<5249, 0, 0, [], [SampleRateShading]>;
defm GeometryShaderPassthroughNV : CapabilityOperand<5251, 0, 0, [], [Geometry]>;
defm ShaderViewportIndexLayerEXT : CapabilityOperand<5254, 0, 0, [], [MultiViewport]>;
defm ShaderViewportMaskNV : CapabilityOperand<5255, 0, 0, [], [ShaderViewportIndexLayerEXT]>;
defm ShaderStereoViewNV : CapabilityOperand<5259, 0, 0, [], [ShaderViewportMaskNV]>;
defm PerViewAttributesNV : CapabilityOperand<5260, 0, 0, [], [MultiView]>;
defm FragmentFullyCoveredEXT : CapabilityOperand<5265, 0, 0, [], [Shader]>;
defm MeshShadingNV : CapabilityOperand<5266, 0, 0, [], [Shader]>;
defm ShaderNonUniformEXT : CapabilityOperand<5301, 0, 0, [], [Shader]>;
defm RuntimeDescriptorArrayEXT : CapabilityOperand<5302, 0, 0, [], [Shader]>;
defm InputAttachmentArrayDynamicIndexingEXT : CapabilityOperand<5303, 0, 0, [], [InputAttachment]>;
defm UniformTexelBufferArrayDynamicIndexingEXT : CapabilityOperand<5304, 0, 0, [], [SampledBuffer]>;
defm StorageTexelBufferArrayDynamicIndexingEXT : CapabilityOperand<5305, 0, 0, [], [ImageBuffer]>;
defm UniformBufferArrayNonUniformIndexingEXT : CapabilityOperand<5306, 0, 0, [], [ShaderNonUniformEXT]>;
defm SampledImageArrayNonUniformIndexingEXT : CapabilityOperand<5307, 0, 0, [], [ShaderNonUniformEXT]>;
defm StorageBufferArrayNonUniformIndexingEXT : CapabilityOperand<5308, 0, 0, [], [ShaderNonUniformEXT]>;
defm StorageImageArrayNonUniformIndexingEXT : CapabilityOperand<5309, 0, 0, [], [ShaderNonUniformEXT]>;
defm InputAttachmentArrayNonUniformIndexingEXT : CapabilityOperand<5310, 0, 0, [], [InputAttachment, ShaderNonUniformEXT]>;
defm UniformTexelBufferArrayNonUniformIndexingEXT : CapabilityOperand<5311, 0, 0, [], [SampledBuffer, ShaderNonUniformEXT]>;
defm StorageTexelBufferArrayNonUniformIndexingEXT : CapabilityOperand<5312, 0, 0, [], [ImageBuffer, ShaderNonUniformEXT]>;
defm RayTracingNV : CapabilityOperand<5340, 0, 0, [], [Shader]>;
defm SubgroupShuffleINTEL : CapabilityOperand<5568, 0, 0, [], []>;
defm SubgroupBufferBlockIOINTEL : CapabilityOperand<5569, 0, 0, [], []>;
defm SubgroupImageBlockIOINTEL : CapabilityOperand<5570, 0, 0, [], []>;
defm SubgroupImageMediaBlockIOINTEL : CapabilityOperand<5579, 0, 0, [], []>;
defm SubgroupAvcMotionEstimationINTEL : CapabilityOperand<5696, 0, 0, [], []>;
defm SubgroupAvcMotionEstimationIntraINTEL : CapabilityOperand<5697, 0, 0, [], []>;
defm SubgroupAvcMotionEstimationChromaINTEL : CapabilityOperand<5698, 0, 0, [], []>;
defm GroupNonUniformPartitionedNV : CapabilityOperand<5297, 0, 0, [], []>;
defm VulkanMemoryModelKHR : CapabilityOperand<5345, 0, 0, [], []>;
defm VulkanMemoryModelDeviceScopeKHR : CapabilityOperand<5346, 0, 0, [], []>;
defm ImageFootprintNV : CapabilityOperand<5282, 0, 0, [], []>;
defm FragmentBarycentricNV : CapabilityOperand<5284, 0, 0, [], []>;
defm ComputeDerivativeGroupQuadsNV : CapabilityOperand<5288, 0, 0, [], []>;
defm ComputeDerivativeGroupLinearNV : CapabilityOperand<5350, 0, 0, [], []>;
defm FragmentDensityEXT : CapabilityOperand<5291, 0, 0, [], [Shader]>;
defm PhysicalStorageBufferAddressesEXT : CapabilityOperand<5347, 0, 0, [], [Shader]>;
defm CooperativeMatrixNV : CapabilityOperand<5357, 0, 0, [], [Shader]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define SourceLanguage enum values and at the same time
// SymbolicOperand entries.
//===----------------------------------------------------------------------===//

def SourceLanguage : GenericEnum, Operand<i32> {
  let FilterClass = "SourceLanguage";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class SourceLanguage<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass SourceLanguageOperand<bits<32> value> {
  def : SourceLanguage<NAME, value>;
  defm : SymbolicOperandWithRequirements<SourceLanguageOperand, value, NAME, 0, 0, [], []>;
}

defm Unknown : SourceLanguageOperand<0>;
defm ESSL : SourceLanguageOperand<1>;
defm GLSL : SourceLanguageOperand<2>;
defm OpenCL_C : SourceLanguageOperand<3>;
defm OpenCL_CPP : SourceLanguageOperand<4>;
defm HLSL : SourceLanguageOperand<5>;

//===----------------------------------------------------------------------===//
// Multiclass used to define AddressingModel enum values and at the same time
// SymbolicOperand entries with string mnemonics, and capabilities.
//===----------------------------------------------------------------------===//

def AddressingModel : GenericEnum, Operand<i32> {
  let FilterClass = "AddressingModel";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class AddressingModel<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass AddressingModelOperand<bits<32> value, list<Capability> reqCapabilities> {
  def : AddressingModel<NAME, value>;
  defm : SymbolicOperandWithRequirements<AddressingModelOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm Logical : AddressingModelOperand<0, []>;
defm Physical32 : AddressingModelOperand<1, [Addresses]>;
defm Physical64 : AddressingModelOperand<2, [Addresses]>;
defm PhysicalStorageBuffer64EXT : AddressingModelOperand<5348, [PhysicalStorageBufferAddressesEXT]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define ExecutionModel enum values and at the same time
// SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def ExecutionModel : GenericEnum, Operand<i32> {
  let FilterClass = "ExecutionModel";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class ExecutionModel<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass ExecutionModelOperand<bits<32> value, list<Capability> reqCapabilities> {
  def : ExecutionModel<NAME, value>;
  defm : SymbolicOperandWithRequirements<ExecutionModelOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm Vertex : ExecutionModelOperand<0, [Shader]>;
defm TessellationControl: ExecutionModelOperand<1, [Tessellation]>;
defm TessellationEvaluation: ExecutionModelOperand<2, [Tessellation]>;
defm Geometry: ExecutionModelOperand<3, [Geometry]>;
defm Fragment: ExecutionModelOperand<4, [Shader]>;
defm GLCompute: ExecutionModelOperand<5, [Shader]>;
defm Kernel: ExecutionModelOperand<6, [Kernel]>;
defm TaskNV: ExecutionModelOperand<5267, [MeshShadingNV]>;
defm MeshNV: ExecutionModelOperand<5268, [MeshShadingNV]>;
defm RayGenerationNV: ExecutionModelOperand<5313, [RayTracingNV]>;
defm IntersectionNV: ExecutionModelOperand<5314, [RayTracingNV]>;
defm AnyHitNV: ExecutionModelOperand<5315, [RayTracingNV]>;
defm ClosestHitNV: ExecutionModelOperand<5316, [RayTracingNV]>;
defm MissNV: ExecutionModelOperand<5317, [RayTracingNV]>;
defm CallableNV: ExecutionModelOperand<5318, [RayTracingNV]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define MemoryModel enum values and at the same time
// SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def MemoryModel : GenericEnum, Operand<i32> {
  let FilterClass = "MemoryModel";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class MemoryModel<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass MemoryModelOperand<bits<32> value, list<Capability> reqCapabilities> {
  def : MemoryModel<NAME, value>;
  defm : SymbolicOperandWithRequirements<MemoryModelOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm Simple : MemoryModelOperand<0, [Shader]>;
defm GLSL450 : MemoryModelOperand<1, [Shader]>;
defm OpenCL : MemoryModelOperand<2, [Kernel]>;
defm VulkanKHR : MemoryModelOperand<3, [VulkanMemoryModelKHR]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define ExecutionMode enum values and at the same time
// SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def ExecutionMode : GenericEnum, Operand<i32> {
  let FilterClass = "ExecutionMode";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class ExecutionMode<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass ExecutionModeOperand<bits<32> value, list<Capability> reqCapabilities> {
  def : ExecutionMode<NAME, value>;
  defm : SymbolicOperandWithRequirements<ExecutionModeOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm Invocations : ExecutionModeOperand<0, [Geometry]>;
defm SpacingEqual : ExecutionModeOperand<1, [Tessellation]>;
defm SpacingFractionalEven : ExecutionModeOperand<2, [Tessellation]>;
defm SpacingFractionalOdd : ExecutionModeOperand<3, [Tessellation]>;
defm VertexOrderCw : ExecutionModeOperand<4, [Tessellation]>;
defm VertexOrderCcw : ExecutionModeOperand<5, [Tessellation]>;
defm PixelCenterInteger : ExecutionModeOperand<6, [Shader]>;
defm OriginUpperLeft : ExecutionModeOperand<7, [Shader]>;
defm OriginLowerLeft : ExecutionModeOperand<8, [Shader]>;
defm EarlyFragmentTests : ExecutionModeOperand<9, [Shader]>;
defm PointMode : ExecutionModeOperand<10, [Tessellation]>;
defm Xfb : ExecutionModeOperand<11, [TransformFeedback]>;
defm DepthReplacing : ExecutionModeOperand<12, [Shader]>;
defm DepthGreater : ExecutionModeOperand<14, [Shader]>;
defm DepthLess : ExecutionModeOperand<15, [Shader]>;
defm DepthUnchanged : ExecutionModeOperand<16, [Shader]>;
defm LocalSize : ExecutionModeOperand<17, []>;
defm LocalSizeHint : ExecutionModeOperand<18, [Kernel]>;
defm InputPoints : ExecutionModeOperand<19, [Geometry]>;
defm InputLines : ExecutionModeOperand<20, [Geometry]>;
defm InputLinesAdjacency : ExecutionModeOperand<21, [Geometry]>;
defm Triangles : ExecutionModeOperand<22, [Geometry]>;
defm InputTrianglesAdjacency : ExecutionModeOperand<23, [Geometry]>;
defm Quads : ExecutionModeOperand<24, [Tessellation]>;
defm Isolines : ExecutionModeOperand<25, [Tessellation]>;
defm OutputVertices : ExecutionModeOperand<26, [Geometry]>;
defm OutputPoints : ExecutionModeOperand<27, [Geometry]>;
defm OutputLineStrip : ExecutionModeOperand<28, [Geometry]>;
defm OutputTriangleStrip : ExecutionModeOperand<29, [Geometry]>;
defm VecTypeHint : ExecutionModeOperand<30, [Kernel]>;
defm ContractionOff : ExecutionModeOperand<31, [Kernel]>;
defm Initializer : ExecutionModeOperand<33, [Kernel]>;
defm Finalizer : ExecutionModeOperand<34, [Kernel]>;
defm SubgroupSize : ExecutionModeOperand<35, [SubgroupDispatch]>;
defm SubgroupsPerWorkgroup : ExecutionModeOperand<36, [SubgroupDispatch]>;
defm SubgroupsPerWorkgroupId : ExecutionModeOperand<37, [SubgroupDispatch]>;
defm LocalSizeId : ExecutionModeOperand<38, []>;
defm LocalSizeHintId : ExecutionModeOperand<39, [Kernel]>;
defm PostDepthCoverage : ExecutionModeOperand<4446, [SampleMaskPostDepthCoverage]>;
defm DenormPreserve : ExecutionModeOperand<4459, [DenormPreserve]>;
defm DenormFlushToZero : ExecutionModeOperand<4460, [DenormFlushToZero]>;
defm SignedZeroInfNanPreserve : ExecutionModeOperand<4461, [SignedZeroInfNanPreserve]>;
defm RoundingModeRTE : ExecutionModeOperand<4462, [RoundingModeRTE]>;
defm RoundingModeRTZ : ExecutionModeOperand<4463, [RoundingModeRTZ]>;
defm StencilRefReplacingEXT : ExecutionModeOperand<5027, [StencilExportEXT]>;
defm OutputLinesNV : ExecutionModeOperand<5269, [MeshShadingNV]>;
defm DerivativeGroupQuadsNV : ExecutionModeOperand<5289, [ComputeDerivativeGroupQuadsNV]>;
defm DerivativeGroupLinearNV : ExecutionModeOperand<5290, [ComputeDerivativeGroupLinearNV]>;
defm OutputTrianglesNV : ExecutionModeOperand<5298, [MeshShadingNV]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define StorageClass enum values and at the same time
// SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def StorageClass : GenericEnum, Operand<i32> {
  let FilterClass = "StorageClass";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class StorageClass<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass StorageClassOperand<bits<32> value, list<Capability> reqCapabilities> {
  def : StorageClass<NAME, value>;
  defm : SymbolicOperandWithRequirements<StorageClassOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm UniformConstant : StorageClassOperand<0, []>;
defm Input : StorageClassOperand<1, []>;
defm Uniform : StorageClassOperand<2, [Shader]>;
defm Output : StorageClassOperand<3, [Shader]>;
defm Workgroup : StorageClassOperand<4, []>;
defm CrossWorkgroup : StorageClassOperand<5, []>;
defm Private : StorageClassOperand<6, [Shader]>;
defm Function : StorageClassOperand<7, []>;
defm Generic : StorageClassOperand<8, [GenericPointer]>;
defm PushConstant : StorageClassOperand<9, [Shader]>;
defm AtomicCounter : StorageClassOperand<10, [AtomicStorage]>;
defm Image : StorageClassOperand<11, []>;
defm StorageBuffer : StorageClassOperand<12, [Shader]>;
defm CallableDataNV : StorageClassOperand<5328, [RayTracingNV]>;
defm IncomingCallableDataNV : StorageClassOperand<5329, [RayTracingNV]>;
defm RayPayloadNV : StorageClassOperand<5338, [RayTracingNV]>;
defm HitAttributeNV : StorageClassOperand<5339, [RayTracingNV]>;
defm IncomingRayPayloadNV : StorageClassOperand<5342, [RayTracingNV]>;
defm ShaderRecordBufferNV : StorageClassOperand<5343, [RayTracingNV]>;
defm PhysicalStorageBufferEXT : StorageClassOperand<5349, [PhysicalStorageBufferAddressesEXT]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define Dim enum values and at the same time
// SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def Dim : GenericEnum, Operand<i32> {
  let FilterClass = "Dim";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class Dim<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass DimOperand<bits<32> value, string mnemonic, list<Capability> reqCapabilities> {
  def NAME : Dim<NAME, value>;
  defm : SymbolicOperandWithRequirements<DimOperand, value, mnemonic, 0, 0, [], reqCapabilities>;
}

defm DIM_1D : DimOperand<0, "1D", [Sampled1D, Image1D]>;
defm DIM_2D : DimOperand<1, "2D", [Shader, Kernel, ImageMSArray]>;
defm DIM_3D : DimOperand<2, "3D", []>;
defm DIM_Cube : DimOperand<3, "Cube", [Shader, ImageCubeArray]>;
defm DIM_Rect : DimOperand<4, "Rect", [SampledRect, ImageRect]>;
defm DIM_Buffer : DimOperand<5, "Buffer", [SampledBuffer, ImageBuffer]>;
defm DIM_SubpassData : DimOperand<6, "SubpassData", [InputAttachment]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define SamplerAddressingMode enum values and at the same
// time SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def SamplerAddressingMode : GenericEnum, Operand<i32> {
  let FilterClass = "SamplerAddressingMode";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class SamplerAddressingMode<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass SamplerAddressingModeOperand<bits<32> value, list<Capability> reqCapabilities> {
  def : SamplerAddressingMode<NAME, value>;
  defm : SymbolicOperandWithRequirements<SamplerAddressingModeOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm None : SamplerAddressingModeOperand<0, [Kernel]>;
defm ClampToEdge : SamplerAddressingModeOperand<1, [Kernel]>;
defm Clamp : SamplerAddressingModeOperand<2, [Kernel]>;
defm Repeat : SamplerAddressingModeOperand<3, [Kernel]>;
defm RepeatMirrored : SamplerAddressingModeOperand<4, [Kernel]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define SamplerFilterMode enum values and at the same
// time SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def SamplerFilterMode : GenericEnum, Operand<i32> {
  let FilterClass = "SamplerFilterMode";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class SamplerFilterMode<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass SamplerFilterModeOperand<bits<32> value, list<Capability> reqCapabilities> {
  def : SamplerFilterMode<NAME, value>;
  defm : SymbolicOperandWithRequirements<SamplerFilterModeOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm Nearest : SamplerFilterModeOperand<0, [Kernel]>;
defm Linear : SamplerFilterModeOperand<1, [Kernel]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define ImageFormat enum values and at the same time
// SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def ImageFormat : GenericEnum, Operand<i32> {
  let FilterClass = "ImageFormat";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class ImageFormat<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass ImageFormatOperand<bits<32> value, list<Capability> reqCapabilities> {
  def NAME : ImageFormat<NAME, value>;
  defm : SymbolicOperandWithRequirements<ImageFormatOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm Unknown : ImageFormatOperand<0, []>;
defm Rgba32f : ImageFormatOperand<1, [Shader]>;
defm Rgba16f : ImageFormatOperand<2, [Shader]>;
defm R32f : ImageFormatOperand<3, [Shader]>;
defm Rgba8 : ImageFormatOperand<4, [Shader]>;
defm Rgba8Snorm : ImageFormatOperand<5, [Shader]>;
defm Rg32f : ImageFormatOperand<6, [StorageImageExtendedFormats]>;
defm Rg16f : ImageFormatOperand<7, [StorageImageExtendedFormats]>;
defm R11fG11fB10f : ImageFormatOperand<8, [StorageImageExtendedFormats]>;
defm R16f : ImageFormatOperand<9, [StorageImageExtendedFormats]>;
defm Rgba16 : ImageFormatOperand<10, [StorageImageExtendedFormats]>;
defm Rgb10A2 : ImageFormatOperand<11, [StorageImageExtendedFormats]>;
defm Rg16 : ImageFormatOperand<12, [StorageImageExtendedFormats]>;
defm Rg8 : ImageFormatOperand<13, [StorageImageExtendedFormats]>;
defm R16 : ImageFormatOperand<14, [StorageImageExtendedFormats]>;
defm R8 : ImageFormatOperand<15, [StorageImageExtendedFormats]>;
defm Rgba16Snorm : ImageFormatOperand<16, [StorageImageExtendedFormats]>;
defm Rg16Snorm : ImageFormatOperand<17, [StorageImageExtendedFormats]>;
defm Rg8Snorm : ImageFormatOperand<18, [StorageImageExtendedFormats]>;
defm R16Snorm : ImageFormatOperand<19, [StorageImageExtendedFormats]>;
defm R8Snorm : ImageFormatOperand<20, [StorageImageExtendedFormats]>;
defm Rgba32i : ImageFormatOperand<21, [Shader]>;
defm Rgba16i : ImageFormatOperand<22, [Shader]>;
defm Rgba8i : ImageFormatOperand<23, [Shader]>;
defm R32i : ImageFormatOperand<24, [Shader]>;
defm Rg32i : ImageFormatOperand<25, [StorageImageExtendedFormats]>;
defm Rg16i : ImageFormatOperand<26, [StorageImageExtendedFormats]>;
defm Rg8i : ImageFormatOperand<27, [StorageImageExtendedFormats]>;
defm R16i : ImageFormatOperand<28, [StorageImageExtendedFormats]>;
defm R8i : ImageFormatOperand<29, [StorageImageExtendedFormats]>;
defm Rgba32ui : ImageFormatOperand<30, [Shader]>;
defm Rgba16ui : ImageFormatOperand<31, [Shader]>;
defm Rgba8ui : ImageFormatOperand<32, [Shader]>;
defm R32ui : ImageFormatOperand<33, [Shader]>;
defm Rgb10a2ui : ImageFormatOperand<34, [StorageImageExtendedFormats]>;
defm Rg32ui : ImageFormatOperand<35, [StorageImageExtendedFormats]>;
defm Rg16ui : ImageFormatOperand<36, [StorageImageExtendedFormats]>;
defm Rg8ui : ImageFormatOperand<37, [StorageImageExtendedFormats]>;
defm R16ui : ImageFormatOperand<38, [StorageImageExtendedFormats]>;
defm R8ui : ImageFormatOperand<39, [StorageImageExtendedFormats]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define ImageChannelOrder enum values and at the same time
// SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def ImageChannelOrder : GenericEnum, Operand<i32> {
  let FilterClass = "ImageChannelOrder";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class ImageChannelOrder<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass ImageChannelOrderOperand<bits<32> value, list<Capability> reqCapabilities> {
  def : ImageChannelOrder<NAME, value>;
  defm : SymbolicOperandWithRequirements<ImageChannelOrderOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm R : ImageChannelOrderOperand<0, [Kernel]>;
defm A : ImageChannelOrderOperand<1, [Kernel]>;
defm RG : ImageChannelOrderOperand<2, [Kernel]>;
defm RA : ImageChannelOrderOperand<3, [Kernel]>;
defm RGB : ImageChannelOrderOperand<4, [Kernel]>;
defm RGBA : ImageChannelOrderOperand<5, [Kernel]>;
defm BGRA : ImageChannelOrderOperand<6, [Kernel]>;
defm ARGB : ImageChannelOrderOperand<7, [Kernel]>;
defm Intensity : ImageChannelOrderOperand<8, [Kernel]>;
defm Luminance : ImageChannelOrderOperand<9, [Kernel]>;
defm Rx : ImageChannelOrderOperand<10, [Kernel]>;
defm RGx : ImageChannelOrderOperand<11, [Kernel]>;
defm RGBx : ImageChannelOrderOperand<12, [Kernel]>;
defm Depth : ImageChannelOrderOperand<13, [Kernel]>;
defm DepthStencil : ImageChannelOrderOperand<14, [Kernel]>;
defm sRGB : ImageChannelOrderOperand<15, [Kernel]>;
defm sRGBx : ImageChannelOrderOperand<16, [Kernel]>;
defm sRGBA : ImageChannelOrderOperand<17, [Kernel]>;
defm sBGRA : ImageChannelOrderOperand<18, [Kernel]>;
defm ABGR : ImageChannelOrderOperand<19, [Kernel]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define ImageChannelDataType enum values and at the same
// time SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def ImageChannelDataType : GenericEnum, Operand<i32> {
  let FilterClass = "ImageChannelDataType";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class ImageChannelDataType<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass ImageChannelDataTypeOperand<bits<32> value, list<Capability> reqCapabilities> {
  def : ImageChannelDataType<NAME, value>;
  defm : SymbolicOperandWithRequirements<ImageChannelDataTypeOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm SnormInt8 : ImageChannelDataTypeOperand<0, []>;
defm SnormInt16 : ImageChannelDataTypeOperand<1, []>;
defm UnormInt8 : ImageChannelDataTypeOperand<2, [Kernel]>;
defm UnormInt16 : ImageChannelDataTypeOperand<3, [Kernel]>;
defm UnormShort565 : ImageChannelDataTypeOperand<4, [Kernel]>;
defm UnormShort555 : ImageChannelDataTypeOperand<5, [Kernel]>;
defm UnormInt101010 : ImageChannelDataTypeOperand<6, [Kernel]>;
defm SignedInt8 : ImageChannelDataTypeOperand<7, [Kernel]>;
defm SignedInt16 : ImageChannelDataTypeOperand<8, [Kernel]>;
defm SignedInt32 : ImageChannelDataTypeOperand<9, [Kernel]>;
defm UnsignedInt8 : ImageChannelDataTypeOperand<10, [Kernel]>;
defm UnsignedInt16 : ImageChannelDataTypeOperand<11, [Kernel]>;
defm UnsigendInt32 : ImageChannelDataTypeOperand<12, [Kernel]>;
defm HalfFloat : ImageChannelDataTypeOperand<13, [Kernel]>;
defm Float : ImageChannelDataTypeOperand<14, [Kernel]>;
defm UnormInt24 : ImageChannelDataTypeOperand<15, [Kernel]>;
defm UnormInt101010_2 : ImageChannelDataTypeOperand<16, [Kernel]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define ImageOperand enum values and at the same time
// SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def ImageOperand : GenericEnum, Operand<i32> {
  let FilterClass = "ImageOperand";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class ImageOperand<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass ImageOperandOperand<bits<32> value, list<Capability> reqCapabilities> {
  def : ImageOperand<NAME, value>;
  defm : SymbolicOperandWithRequirements<ImageOperandOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm None : ImageOperandOperand<0x0, []>;
defm Bias : ImageOperandOperand<0x1, [Shader]>;
defm Lod : ImageOperandOperand<0x2, []>;
defm Grad : ImageOperandOperand<0x4, []>;
defm ConstOffset : ImageOperandOperand<0x8, []>;
defm Offset : ImageOperandOperand<0x10, [ImageGatherExtended]>;
defm ConstOffsets : ImageOperandOperand<0x20, [ImageGatherExtended]>;
defm Sample : ImageOperandOperand<0x40, []>;
defm MinLod : ImageOperandOperand<0x80, [MinLod]>;
defm MakeTexelAvailableKHR : ImageOperandOperand<0x100, [VulkanMemoryModelKHR]>;
defm MakeTexelVisibleKHR : ImageOperandOperand<0x200, [VulkanMemoryModelKHR]>;
defm NonPrivateTexelKHR : ImageOperandOperand<0x400, [VulkanMemoryModelKHR]>;
defm VolatileTexelKHR : ImageOperandOperand<0x800, [VulkanMemoryModelKHR]>;
defm SignExtend : ImageOperandOperand<0x1000, []>;
defm ZeroExtend : ImageOperandOperand<0x2000, []>;

//===----------------------------------------------------------------------===//
// Multiclass used to define FPFastMathMode enum values and at the same time
// SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def FPFastMathMode : GenericEnum, Operand<i32> {
  let FilterClass = "FPFastMathMode";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class FPFastMathMode<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass FPFastMathModeOperand<bits<32> value, list<Capability> reqCapabilities> {
  def : FPFastMathMode<NAME, value>;
  defm : SymbolicOperandWithRequirements<FPFastMathModeOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm None : FPFastMathModeOperand<0x0, []>;
defm NotNaN : FPFastMathModeOperand<0x1, [Kernel]>;
defm NotInf : FPFastMathModeOperand<0x2, [Kernel]>;
defm NSZ : FPFastMathModeOperand<0x4, [Kernel]>;
defm AllowRecip : FPFastMathModeOperand<0x8, [Kernel]>;
defm Fast : FPFastMathModeOperand<0x10, [Kernel]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define FPRoundingMode enum values and at the same time
// SymbolicOperand entries with string mnemonics.
//===----------------------------------------------------------------------===//

def FPRoundingMode : GenericEnum, Operand<i32> {
  let FilterClass = "FPRoundingMode";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class FPRoundingMode<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass FPRoundingModeOperand<bits<32> value> {
  def NAME : FPRoundingMode<NAME, value>;
  defm : SymbolicOperandWithRequirements<FPRoundingModeOperand, value, NAME, 0, 0, [], []>;
}

defm RTE : FPRoundingModeOperand<0>;
defm RTZ : FPRoundingModeOperand<1>;
defm RTP : FPRoundingModeOperand<2>;
defm RTN : FPRoundingModeOperand<3>;

//===----------------------------------------------------------------------===//
// Multiclass used to define LinkageType enum values and at the same time
// SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def LinkageType : GenericEnum, Operand<i32> {
  let FilterClass = "LinkageType";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class LinkageType<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass LinkageTypeOperand<bits<32> value, list<Capability> reqCapabilities> {
  def : LinkageType<NAME, value>;
  defm : SymbolicOperandWithRequirements<LinkageTypeOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm Export : LinkageTypeOperand<0, [Linkage]>;
defm Import : LinkageTypeOperand<1, [Linkage]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define AccessQualifier enum values and at the same time
// SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def AccessQualifier : GenericEnum, Operand<i32> {
  let FilterClass = "AccessQualifier";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class AccessQualifier<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass AccessQualifierOperand<bits<32> value, list<Capability> reqCapabilities> {
  def NAME : AccessQualifier<NAME, value>;
  defm : SymbolicOperandWithRequirements<AccessQualifierOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm ReadOnly : AccessQualifierOperand<0, [Kernel]>;
defm WriteOnly : AccessQualifierOperand<1, [Kernel]>;
defm ReadWrite : AccessQualifierOperand<2, [Kernel]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define FunctionParameterAttribute enum values and at the
// same time SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def FunctionParameterAttribute : GenericEnum, Operand<i32> {
  let FilterClass = "FunctionParameterAttribute";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class FunctionParameterAttribute<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass FunctionParameterAttributeOperand<bits<32> value, list<Capability> reqCapabilities> {
  def : FunctionParameterAttribute<NAME, value>;
  defm : SymbolicOperandWithRequirements<FunctionParameterAttributeOperand, value, NAME, 0, 0, [], reqCapabilities>;
}

defm Zext : FunctionParameterAttributeOperand<0, [Kernel]>;
defm Sext : FunctionParameterAttributeOperand<1, [Kernel]>;
defm ByVal : FunctionParameterAttributeOperand<2, [Kernel]>;
defm Sret : FunctionParameterAttributeOperand<3, [Kernel]>;
defm NoAlias : FunctionParameterAttributeOperand<4, [Kernel]>;
defm NoCapture : FunctionParameterAttributeOperand<5, [Kernel]>;
defm NoWrite : FunctionParameterAttributeOperand<6, [Kernel]>;
defm NoReadWrite : FunctionParameterAttributeOperand<7, [Kernel]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define Decoration enum values and at the same time
// SymbolicOperand entries with string mnemonics, versioning, extensions and
// capabilities.
//===----------------------------------------------------------------------===//

def Decoration : GenericEnum, Operand<i32> {
  let FilterClass = "Decoration";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class Decoration<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass DecorationOperand<bits<32> value, bits<32> minVersion, bits<32> maxVersion, list<Extension> reqExtensions, list<Capability> reqCapabilities> {
  def : Decoration<NAME, value>;
  defm : SymbolicOperandWithRequirements<DecorationOperand, value, NAME, minVersion, maxVersion, reqExtensions, reqCapabilities>;
}

defm RelaxedPrecision : DecorationOperand<0, 0, 0, [], [Shader]>;
defm SpecId : DecorationOperand<1, 0, 0, [], [Shader, Kernel]>;
defm Block : DecorationOperand<2, 0, 0, [], [Shader]>;
defm BufferBlock : DecorationOperand<3, 0, 0, [], [Shader]>;
defm RowMajor : DecorationOperand<4, 0, 0, [], [Matrix]>;
defm ColMajor : DecorationOperand<5, 0, 0, [], [Matrix]>;
defm ArrayStride : DecorationOperand<6, 0, 0, [], [Shader]>;
defm MatrixStride : DecorationOperand<7, 0, 0, [], [Matrix]>;
defm GLSLShared : DecorationOperand<8, 0, 0, [], [Shader]>;
defm GLSLPacked : DecorationOperand<9, 0, 0, [], [Shader]>;
defm CPacked : DecorationOperand<10, 0, 0, [], [Kernel]>;
defm BuiltIn : DecorationOperand<11, 0, 0, [], []>;
defm NoPerspective : DecorationOperand<13, 0, 0, [], [Shader]>;
defm Flat : DecorationOperand<14, 0, 0, [], [Shader]>;
defm Patch : DecorationOperand<15, 0, 0, [], [Tessellation]>;
defm Centroid : DecorationOperand<16, 0, 0, [], [Shader]>;
defm Sample : DecorationOperand<17, 0, 0, [], [SampleRateShading]>;
defm Invariant : DecorationOperand<18, 0, 0, [], [Shader]>;
defm Restrict : DecorationOperand<19, 0, 0, [], []>;
defm Aliased : DecorationOperand<20, 0, 0, [], []>;
defm Volatile : DecorationOperand<21, 0, 0, [], []>;
defm Constant : DecorationOperand<22, 0, 0, [], [Kernel]>;
defm Coherent : DecorationOperand<23, 0, 0, [], []>;
defm NonWritable : DecorationOperand<24, 0, 0, [], []>;
defm NonReadable : DecorationOperand<25, 0, 0, [], []>;
defm Uniform : DecorationOperand<26, 0, 0, [], [Shader]>;
defm UniformId : DecorationOperand<27, 0, 0, [], [Shader]>;
defm SaturatedConversion : DecorationOperand<28, 0, 0, [], [Kernel]>;
defm Stream : DecorationOperand<29, 0, 0, [], [GeometryStreams]>;
defm Location : DecorationOperand<30, 0, 0, [], [Shader]>;
defm Component : DecorationOperand<31, 0, 0, [], [Shader]>;
defm Index : DecorationOperand<32, 0, 0, [], [Shader]>;
defm Binding : DecorationOperand<33, 0, 0, [], [Shader]>;
defm DescriptorSet : DecorationOperand<34, 0, 0, [], [Shader]>;
defm Offset : DecorationOperand<35, 0, 0, [], [Shader]>;
defm XfbBuffer : DecorationOperand<36, 0, 0, [], [TransformFeedback]>;
defm XfbStride : DecorationOperand<37, 0, 0, [], [TransformFeedback]>;
defm FuncParamAttr : DecorationOperand<38, 0, 0, [], [Kernel]>;
defm FPRoundingMode : DecorationOperand<39, 0, 0, [], []>;
defm FPFastMathMode : DecorationOperand<40, 0, 0, [], [Kernel]>;
defm LinkageAttributes : DecorationOperand<41, 0, 0, [], [Linkage]>;
defm NoContraction : DecorationOperand<42, 0, 0, [], [Shader]>;
defm InputAttachmentIndex : DecorationOperand<43, 0, 0, [], [InputAttachment]>;
defm Alignment : DecorationOperand<44, 0, 0, [], [Kernel]>;
defm MaxByteOffset : DecorationOperand<45, 0, 0, [], [Addresses]>;
defm AlignmentId : DecorationOperand<46, 0, 0, [], [Kernel]>;
defm MaxByteOffsetId : DecorationOperand<47, 0, 0, [], [Addresses]>;
defm NoSignedWrap : DecorationOperand<4469, 0x10400, 0, [SPV_KHR_no_integer_wrap_decoration], []>;
defm NoUnsignedWrap : DecorationOperand<4470, 0x10400, 0, [SPV_KHR_no_integer_wrap_decoration], []>;
defm ExplicitInterpAMD : DecorationOperand<4999, 0, 0, [], []>;
defm OverrideCoverageNV : DecorationOperand<5248, 0, 0, [], [SampleMaskOverrideCoverageNV]>;
defm PassthroughNV : DecorationOperand<5250, 0, 0, [], [GeometryShaderPassthroughNV]>;
defm ViewportRelativeNV : DecorationOperand<5252, 0, 0, [], [ShaderViewportMaskNV]>;
defm SecondaryViewportRelativeNV : DecorationOperand<5256, 0, 0, [], [ShaderStereoViewNV]>;
defm PerPrimitiveNV : DecorationOperand<5271, 0, 0, [], [MeshShadingNV]>;
defm PerViewNV : DecorationOperand<5272, 0, 0, [], [MeshShadingNV]>;
defm PerVertexNV : DecorationOperand<5273, 0, 0, [], [FragmentBarycentricNV]>;
defm NonUniformEXT : DecorationOperand<5300, 0, 0, [], [ShaderNonUniformEXT]>;
defm CountBuffer : DecorationOperand<5634, 0, 0, [], []>;
defm UserSemantic : DecorationOperand<5635, 0, 0, [], []>;
defm RestrictPointerEXT : DecorationOperand<5355, 0, 0, [], [PhysicalStorageBufferAddressesEXT]>;
defm AliasedPointerEXT : DecorationOperand<5356, 0, 0, [], [PhysicalStorageBufferAddressesEXT]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define BuiltIn enum values and at the same time
// SymbolicOperand entries with string mnemonics, versioning, extensions and
// capabilities.
//===----------------------------------------------------------------------===//

def BuiltIn : GenericEnum, Operand<i32> {
  let FilterClass = "BuiltIn";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class BuiltIn<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass BuiltInOperand<bits<32> value, bits<32> minVersion, bits<32> maxVersion, list<Extension> reqExtensions, list<Capability> reqCapabilities> {
  def NAME : BuiltIn<NAME, value>;
  defm : SymbolicOperandWithRequirements<BuiltInOperand, value, NAME, minVersion, maxVersion, reqExtensions, reqCapabilities>;
}

defm Position : BuiltInOperand<0, 0, 0, [], [Shader]>;
defm PointSize : BuiltInOperand<1, 0, 0, [], [Shader]>;
defm ClipDistanceVariable : BuiltInOperand<3, 0, 0, [], [ClipDistance]>;
defm CullDistanceVariable : BuiltInOperand<4, 0, 0, [], [CullDistance]>;
defm VertexId : BuiltInOperand<5, 0, 0, [], [Shader]>;
defm InstanceId : BuiltInOperand<6, 0, 0, [], [Shader]>;
defm PrimitiveId : BuiltInOperand<7, 0, 0, [], [Geometry, Tessellation, RayTracingNV]>;
defm InvocationId : BuiltInOperand<8, 0, 0, [], [Geometry, Tessellation]>;
defm Layer : BuiltInOperand<9, 0, 0, [], [Geometry]>;
defm ViewportIndex : BuiltInOperand<10, 0, 0, [], [MultiViewport]>;
defm TessLevelOuter : BuiltInOperand<11, 0, 0, [], [Tessellation]>;
defm TessLevelInner : BuiltInOperand<12, 0, 0, [], [Tessellation]>;
defm TessCoord : BuiltInOperand<13, 0, 0, [], [Tessellation]>;
defm PatchVertices : BuiltInOperand<14, 0, 0, [], [Tessellation]>;
defm FragCoord : BuiltInOperand<15, 0, 0, [], [Shader]>;
defm PointCoord : BuiltInOperand<16, 0, 0, [], [Shader]>;
defm FrontFacing : BuiltInOperand<17, 0, 0, [], [Shader]>;
defm SampleId : BuiltInOperand<18, 0, 0, [], [SampleRateShading]>;
defm SamplePosition : BuiltInOperand<19, 0, 0, [], [SampleRateShading]>;
defm SampleMask : BuiltInOperand<20, 0, 0, [], [Shader]>;
defm FragDepth : BuiltInOperand<22, 0, 0, [], [Shader]>;
defm HelperInvocation : BuiltInOperand<23, 0, 0, [], [Shader]>;
defm NumWorkgroups : BuiltInOperand<24, 0, 0, [], []>;
defm WorkgroupSize : BuiltInOperand<25, 0, 0, [], []>;
defm WorkgroupId : BuiltInOperand<26, 0, 0, [], []>;
defm LocalInvocationId : BuiltInOperand<27, 0, 0, [], []>;
defm GlobalInvocationId : BuiltInOperand<28, 0, 0, [], []>;
defm LocalInvocationIndex : BuiltInOperand<29, 0, 0, [], []>;
defm WorkDim : BuiltInOperand<30, 0, 0, [], [Kernel]>;
defm GlobalSize : BuiltInOperand<31, 0, 0, [], [Kernel]>;
defm EnqueuedWorkgroupSize : BuiltInOperand<32, 0, 0, [], [Kernel]>;
defm GlobalOffset : BuiltInOperand<33, 0, 0, [], [Kernel]>;
defm GlobalLinearId : BuiltInOperand<34, 0, 0, [], [Kernel]>;
defm SubgroupSize : BuiltInOperand<36, 0, 0, [], [Kernel, GroupNonUniform, SubgroupBallotKHR]>;
defm SubgroupMaxSize : BuiltInOperand<37, 0, 0, [], [Kernel]>;
defm NumSubgroups : BuiltInOperand<38, 0, 0, [], [Kernel, GroupNonUniform]>;
defm NumEnqueuedSubgroups : BuiltInOperand<39, 0, 0, [], [Kernel]>;
defm SubgroupId : BuiltInOperand<40, 0, 0, [], [Kernel, GroupNonUniform]>;
defm SubgroupLocalInvocationId : BuiltInOperand<41, 0, 0, [], [Kernel, GroupNonUniform, SubgroupBallotKHR]>;
defm VertexIndex : BuiltInOperand<42, 0, 0, [], [Shader]>;
defm InstanceIndex : BuiltInOperand<43, 0, 0, [], [Shader]>;
defm SubgroupEqMask : BuiltInOperand<4416, 0, 0, [], [SubgroupBallotKHR, GroupNonUniformBallot]>;
defm SubgroupGeMask : BuiltInOperand<4417, 0, 0, [], [SubgroupBallotKHR, GroupNonUniformBallot]>;
defm SubgroupGtMask : BuiltInOperand<4418, 0, 0, [], [SubgroupBallotKHR, GroupNonUniformBallot]>;
defm SubgroupLeMask : BuiltInOperand<4419, 0, 0, [], [SubgroupBallotKHR, GroupNonUniformBallot]>;
defm SubgroupLtMask : BuiltInOperand<4420, 0, 0, [], [SubgroupBallotKHR, GroupNonUniformBallot]>;
defm BaseVertex : BuiltInOperand<4424, 0, 0, [], [DrawParameters]>;
defm BaseInstance : BuiltInOperand<4425, 0, 0, [], [DrawParameters]>;
defm DrawIndex : BuiltInOperand<4426, 0, 0, [], [DrawParameters, MeshShadingNV]>;
defm DeviceIndex : BuiltInOperand<4438, 0, 0, [], [DeviceGroup]>;
defm ViewIndex : BuiltInOperand<4440, 0, 0, [], [MultiView]>;
defm BaryCoordNoPerspAMD : BuiltInOperand<4492, 0, 0, [], []>;
defm BaryCoordNoPerspCentroidAMD : BuiltInOperand<4493, 0, 0, [], []>;
defm BaryCoordNoPerspSampleAMD : BuiltInOperand<4494, 0, 0, [], []>;
defm BaryCoordSmoothAMD : BuiltInOperand<4495, 0, 0, [], []>;
defm BaryCoordSmoothCentroid : BuiltInOperand<4496, 0, 0, [], []>;
defm BaryCoordSmoothSample : BuiltInOperand<4497, 0, 0, [], []>;
defm BaryCoordPullModel : BuiltInOperand<4498, 0, 0, [], []>;
defm FragStencilRefEXT : BuiltInOperand<5014, 0, 0, [], [StencilExportEXT]>;
defm ViewportMaskNV : BuiltInOperand<5253, 0, 0, [], [ShaderViewportMaskNV, MeshShadingNV]>;
defm SecondaryPositionNV : BuiltInOperand<5257, 0, 0, [], [ShaderStereoViewNV]>;
defm SecondaryViewportMaskNV : BuiltInOperand<5258, 0, 0, [], [ShaderStereoViewNV]>;
defm PositionPerViewNV : BuiltInOperand<5261, 0, 0, [], [PerViewAttributesNV, MeshShadingNV]>;
defm ViewportMaskPerViewNV : BuiltInOperand<5262, 0, 0, [], [PerViewAttributesNV, MeshShadingNV]>;
defm FullyCoveredEXT : BuiltInOperand<5264, 0, 0, [], [FragmentFullyCoveredEXT]>;
defm TaskCountNV : BuiltInOperand<5274, 0, 0, [], [MeshShadingNV]>;
defm PrimitiveCountNV : BuiltInOperand<5275, 0, 0, [], [MeshShadingNV]>;
defm PrimitiveIndicesNV : BuiltInOperand<5276, 0, 0, [], [MeshShadingNV]>;
defm ClipDistancePerViewNV : BuiltInOperand<5277, 0, 0, [], [MeshShadingNV]>;
defm CullDistancePerViewNV : BuiltInOperand<5278, 0, 0, [], [MeshShadingNV]>;
defm LayerPerViewNV : BuiltInOperand<5279, 0, 0, [], [MeshShadingNV]>;
defm MeshViewCountNV : BuiltInOperand<5280, 0, 0, [], [MeshShadingNV]>;
defm MeshViewIndices : BuiltInOperand<5281, 0, 0, [], [MeshShadingNV]>;
defm BaryCoordNV : BuiltInOperand<5286, 0, 0, [], [FragmentBarycentricNV]>;
defm BaryCoordNoPerspNV : BuiltInOperand<5287, 0, 0, [], [FragmentBarycentricNV]>;
defm FragSizeEXT : BuiltInOperand<5292, 0, 0, [], [FragmentDensityEXT]>;
defm FragInvocationCountEXT : BuiltInOperand<5293, 0, 0, [], [FragmentDensityEXT]>;
defm LaunchIdNV : BuiltInOperand<5319, 0, 0, [], [RayTracingNV]>;
defm LaunchSizeNV : BuiltInOperand<5320, 0, 0, [], [RayTracingNV]>;
defm WorldRayOriginNV : BuiltInOperand<5321, 0, 0, [], [RayTracingNV]>;
defm WorldRayDirectionNV : BuiltInOperand<5322, 0, 0, [], [RayTracingNV]>;
defm ObjectRayOriginNV : BuiltInOperand<5323, 0, 0, [], [RayTracingNV]>;
defm ObjectRayDirectionNV : BuiltInOperand<5324, 0, 0, [], [RayTracingNV]>;
defm RayTminNV : BuiltInOperand<5325, 0, 0, [], [RayTracingNV]>;
defm RayTmaxNV : BuiltInOperand<5326, 0, 0, [], [RayTracingNV]>;
defm InstanceCustomIndexNV : BuiltInOperand<5327, 0, 0, [], [RayTracingNV]>;
defm ObjectToWorldNV : BuiltInOperand<5330, 0, 0, [], [RayTracingNV]>;
defm WorldToObjectNV : BuiltInOperand<5331, 0, 0, [], [RayTracingNV]>;
defm HitTNV : BuiltInOperand<5332, 0, 0, [], [RayTracingNV]>;
defm HitKindNV : BuiltInOperand<5333, 0, 0, [], [RayTracingNV]>;
defm IncomingRayFlagsNV : BuiltInOperand<5351, 0, 0, [], [RayTracingNV]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define SelectionControl enum values and at the same time
// SymbolicOperand entries with string mnemonics.
//===----------------------------------------------------------------------===//

def SelectionControl : GenericEnum, Operand<i32> {
  let FilterClass = "SelectionControl";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class SelectionControl<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass SelectionControlOperand<bits<32> value> {
  def : SelectionControl<NAME, value>;
  defm : SymbolicOperandWithRequirements<SelectionControlOperand, value, NAME, 0, 0, [], []>;
}

defm None : SelectionControlOperand<0x0>;
defm Flatten : SelectionControlOperand<0x1>;
defm DontFlatten : SelectionControlOperand<0x2>;

//===----------------------------------------------------------------------===//
// Multiclass used to define LoopControl enum values and at the same time
// SymbolicOperand entries with string mnemonics.
//===----------------------------------------------------------------------===//

def LoopControl : GenericEnum, Operand<i32> {
  let FilterClass = "LoopControl";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class LoopControl<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass LoopControlOperand<bits<32> value> {
  def : LoopControl<NAME, value>;
  defm : SymbolicOperandWithRequirements<LoopControlOperand, value, NAME, 0, 0, [], []>;
}

defm None : LoopControlOperand<0x0>;
defm Unroll : LoopControlOperand<0x1>;
defm DontUnroll : LoopControlOperand<0x2>;
defm DependencyInfinite : LoopControlOperand<0x4>;
defm DependencyLength : LoopControlOperand<0x8>;
defm MinIterations : LoopControlOperand<0x10>;
defm MaxIterations : LoopControlOperand<0x20>;
defm IterationMultiple : LoopControlOperand<0x40>;
defm PeelCount : LoopControlOperand<0x80>;
defm PartialCount : LoopControlOperand<0x100>;

//===----------------------------------------------------------------------===//
// Multiclass used to define FunctionControl enum values and at the same time
// SymbolicOperand entries with string mnemonics.
//===----------------------------------------------------------------------===//

def FunctionControl : GenericEnum, Operand<i32> {
  let FilterClass = "FunctionControl";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class FunctionControl<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass FunctionControlOperand<bits<32> value> {
  def : FunctionControl<NAME, value>;
  defm : SymbolicOperandWithRequirements<FunctionControlOperand, value, NAME, 0, 0, [], []>;
}

defm None : FunctionControlOperand<0x0>;
defm Inline : FunctionControlOperand<0x1>;
defm DontInline : FunctionControlOperand<0x2>;
defm Pure : FunctionControlOperand<0x4>;
defm Const : FunctionControlOperand<0x8>;

//===----------------------------------------------------------------------===//
// Multiclass used to define MemorySemantics enum values and at the same time
// SymbolicOperand entries with string mnemonics, versioning, extensions and
// capabilities.
//===----------------------------------------------------------------------===//

def MemorySemantics : GenericEnum, Operand<i32> {
  let FilterClass = "MemorySemantics";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class MemorySemantics<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass MemorySemanticsOperand<bits<32> value, bits<32> minVersion, bits<32> maxVersion, list<Extension> reqExtensions, list<Capability> reqCapabilities> {
  def : MemorySemantics<NAME, value>;
  defm : SymbolicOperandWithRequirements<MemorySemanticsOperand, value, NAME, minVersion, maxVersion, reqExtensions, reqCapabilities>;
}

defm None : MemorySemanticsOperand<0x0, 0, 0, [], []>;
defm Acquire : MemorySemanticsOperand<0x2, 0, 0, [], []>;
defm Release : MemorySemanticsOperand<0x4, 0, 0, [], []>;
defm AcquireRelease : MemorySemanticsOperand<0x8, 0, 0, [], []>;
defm SequentiallyConsistent : MemorySemanticsOperand<0x10, 0, 0, [], []>;
defm UniformMemory : MemorySemanticsOperand<0x40, 0, 0, [], [Shader]>;
defm SubgroupMemory : MemorySemanticsOperand<0x80, 0, 0, [], []>;
defm WorkgroupMemory : MemorySemanticsOperand<0x100, 0, 0, [], []>;
defm CrossWorkgroupMemory : MemorySemanticsOperand<0x200, 0, 0, [], []>;
defm AtomicCounterMemory : MemorySemanticsOperand<0x400, 0, 0, [], [AtomicStorage]>;
defm ImageMemory : MemorySemanticsOperand<0x800, 0, 0, [], []>;
defm OutputMemoryKHR : MemorySemanticsOperand<0x1000, 0, 0, [], [VulkanMemoryModelKHR]>;
defm MakeAvailableKHR : MemorySemanticsOperand<0x2000, 0, 0, [], [VulkanMemoryModelKHR]>;
defm MakeVisibleKHR : MemorySemanticsOperand<0x4000, 0, 0, [], [VulkanMemoryModelKHR]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define MemoryOperand enum values and at the same time
// SymbolicOperand entries with string mnemonics, versioning, extensions and
// capabilities.
//===----------------------------------------------------------------------===//

def MemoryOperand : GenericEnum, Operand<i32> {
  let FilterClass = "MemoryOperand";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class MemoryOperand<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass MemoryOperandOperand<bits<32> value, bits<32> minVersion, bits<32> maxVersion, list<Extension> reqExtensions, list<Capability> reqCapabilities> {
  def : MemoryOperand<NAME, value>;
  defm : SymbolicOperandWithRequirements<MemoryOperandOperand, value, NAME, minVersion, maxVersion, reqExtensions, reqCapabilities>;
}

defm None : MemoryOperandOperand<0x0, 0, 0, [], []>;
defm Volatile : MemoryOperandOperand<0x1, 0, 0, [], []>;
defm Aligned : MemoryOperandOperand<0x2, 0, 0, [], []>;
defm Nontemporal : MemoryOperandOperand<0x4, 0, 0, [], []>;
defm MakePointerAvailableKHR : MemoryOperandOperand<0x8, 0, 0, [], [VulkanMemoryModelKHR]>;
defm MakePointerVisibleKHR : MemoryOperandOperand<0x10, 0, 0, [], [VulkanMemoryModelKHR]>;
defm NonPrivatePointerKHR : MemoryOperandOperand<0x20, 0, 0, [], [VulkanMemoryModelKHR]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define Scope enum values and at the same time
// SymbolicOperand entries with string mnemonics, versioning, extensions and
// capabilities.
//===----------------------------------------------------------------------===//

def Scope : GenericEnum, Operand<i32> {
  let FilterClass = "Scope";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class Scope<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass ScopeOperand<bits<32> value, bits<32> minVersion, bits<32> maxVersion, list<Extension> reqExtensions, list<Capability> reqCapabilities> {
  def : Scope<NAME, value>;
  defm : SymbolicOperandWithRequirements<ScopeOperand, value, NAME, minVersion, maxVersion, reqExtensions, reqCapabilities>;
}

defm CrossDevice : ScopeOperand<0, 0, 0, [], []>;
defm Device : ScopeOperand<1, 0, 0, [], []>;
defm Workgroup : ScopeOperand<2, 0, 0, [], []>;
defm Subgroup : ScopeOperand<3, 0, 0, [], []>;
defm Invocation : ScopeOperand<4, 0, 0, [], []>;
defm QueueFamilyKHR : ScopeOperand<5, 0, 0, [], [VulkanMemoryModelKHR]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define GroupOperation enum values and at the same time
// SymbolicOperand entries with string mnemonics, versioning, extensions and
// capabilities.
//===----------------------------------------------------------------------===//

def GroupOperation : GenericEnum, Operand<i32> {
  let FilterClass = "GroupOperation";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class GroupOperation<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass GroupOperationOperand<bits<32> value, bits<32> minVersion, bits<32> maxVersion, list<Extension> reqExtensions, list<Capability> reqCapabilities> {
  def NAME : GroupOperation<NAME, value>;
  defm : SymbolicOperandWithRequirements<GroupOperationOperand, value, NAME, minVersion, maxVersion, reqExtensions, reqCapabilities>;
}

defm Reduce : GroupOperationOperand<0, 0, 0, [], [Kernel, GroupNonUniformArithmetic, GroupNonUniformBallot]>;
defm InclusiveScan : GroupOperationOperand<1, 0, 0, [], [Kernel, GroupNonUniformArithmetic, GroupNonUniformBallot]>;
defm ExclusiveScan : GroupOperationOperand<2, 0, 0, [], [Kernel, GroupNonUniformArithmetic, GroupNonUniformBallot]>;
defm ClusteredReduce : GroupOperationOperand<3, 0, 0, [], [GroupNonUniformClustered]>;
defm PartitionedReduceNV : GroupOperationOperand<6, 0, 0, [], [GroupNonUniformPartitionedNV]>;
defm PartitionedInclusiveScanNV : GroupOperationOperand<7, 0, 0, [], [GroupNonUniformPartitionedNV]>;
defm PartitionedExclusiveScanNV : GroupOperationOperand<8, 0, 0, [], [GroupNonUniformPartitionedNV]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define KernelEnqueueFlags enum values and at the same time
// SymbolicOperand entries with string mnemonics, versioning, extensions and
// capabilities.
//===----------------------------------------------------------------------===//

def KernelEnqueueFlags : GenericEnum, Operand<i32> {
  let FilterClass = "KernelEnqueueFlags";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class KernelEnqueueFlags<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass KernelEnqueueFlagsOperand<bits<32> value, bits<32> minVersion, bits<32> maxVersion, list<Extension> reqExtensions, list<Capability> reqCapabilities> {
  def : KernelEnqueueFlags<NAME, value>;
  defm : SymbolicOperandWithRequirements<KernelEnqueueFlagsOperand, value, NAME, minVersion, maxVersion, reqExtensions, reqCapabilities>;
}

defm NoWait : KernelEnqueueFlagsOperand<0, 0, 0, [], [Kernel]>;
defm WaitKernel : KernelEnqueueFlagsOperand<1, 0, 0, [], [Kernel]>;
defm WaitWorkGroup : KernelEnqueueFlagsOperand<2, 0, 0, [], [Kernel]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define KernelProfilingInfo enum values and at the same time
// SymbolicOperand entries with string mnemonics, versioning, extensions and
// capabilities.
//===----------------------------------------------------------------------===//

def KernelProfilingInfo : GenericEnum, Operand<i32> {
  let FilterClass = "KernelProfilingInfo";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class KernelProfilingInfo<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass KernelProfilingInfoOperand<bits<32> value, bits<32> minVersion, bits<32> maxVersion, list<Extension> reqExtensions, list<Capability> reqCapabilities> {
  def : KernelProfilingInfo<NAME, value>;
  defm : SymbolicOperandWithRequirements<KernelProfilingInfoOperand, value, NAME, minVersion, maxVersion, reqExtensions, reqCapabilities>;
}

defm None : KernelProfilingInfoOperand<0x0, 0, 0, [], []>;
defm CmdExecTime : KernelProfilingInfoOperand<0x1, 0, 0, [], [Kernel]>;

//===----------------------------------------------------------------------===//
// Multiclass used to define Opcode enum values and at the same time
// SymbolicOperand entries with string mnemonics and capabilities.
//===----------------------------------------------------------------------===//

def Opcode : GenericEnum, Operand<i32> {
  let FilterClass = "Opcode";
  let NameField = "Name";
  let ValueField = "Value";
  let PrintMethod = !strconcat("printSymbolicOperand<OperandCategory::", FilterClass, "Operand>");
}

class Opcode<string name, bits<32> value> {
  string Name = name;
  bits<32> Value = value;
}

multiclass OpcodeOperand<bits<32> value> {
  def : Opcode<NAME, value>;
  defm : SymbolicOperandWithRequirements<OpcodeOperand, value, NAME, 0, 0, [], []>;
}
// TODO: implement other mnemonics.
defm InBoundsPtrAccessChain : OpcodeOperand<70>;
defm PtrCastToGeneric : OpcodeOperand<121>;