authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2025-07-14 23:49:34-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2025-07-14 23:49:34-07:00
logac8f757cb371f25472db7c9674b3e2958d86f9ec
tree42ed3b5afc2cda5d7d117f522e24535bb80c6ab6
parentaa81c2df7c35be629e3dd4e8ea02b42b1cb027ac
parent4f5fa959aa80ce39828b8bf45098029ce818fda2

Merge remote-tracking branch 'origin/master' into wrangle-writer-buffering


125 files changed, 15812 insertions(+), 12357 deletions(-)

.github/workflows/ci.yaml+18
...@@ -50,6 +50,24 @@ jobs:...@@ -50,6 +50,24 @@ jobs:
50 uses: actions/checkout@v450 uses: actions/checkout@v4
51 - name: Build and Test51 - name: Build and Test
52 run: sh ci/aarch64-linux-release.sh52 run: sh ci/aarch64-linux-release.sh
53 riscv64-linux-debug:
54 if: ${{ github.event_name == 'push' }}
55 timeout-minutes: 1020
56 runs-on: [self-hosted, Linux, riscv64]
57 steps:
58 - name: Checkout
59 uses: actions/checkout@v4
60 - name: Build and Test
61 run: sh ci/riscv64-linux-debug.sh
62 riscv64-linux-release:
63 if: ${{ github.event_name == 'push' }}
64 timeout-minutes: 900
65 runs-on: [self-hosted, Linux, riscv64]
66 steps:
67 - name: Checkout
68 uses: actions/checkout@v4
69 - name: Build and Test
70 run: sh ci/riscv64-linux-release.sh
53 x86_64-macos-release:71 x86_64-macos-release:
54 runs-on: "macos-13"72 runs-on: "macos-13"
55 env:73 env:
ci/riscv64-linux-debug.sh created+58
...@@ -0,0 +1,58 @@
1#!/bin/sh
2
3# Requires cmake ninja-build
4
5set -x
6set -e
7
8ARCH="$(uname -m)"
9TARGET="$ARCH-linux-musl"
10MCPU="spacemit_x60"
11CACHE_BASENAME="zig+llvm+lld+clang-riscv64-linux-musl-0.15.0-dev.929+31e46be74"
12PREFIX="$HOME/deps/$CACHE_BASENAME"
13ZIG="$PREFIX/bin/zig"
14
15export PATH="$HOME/local/bin:$PATH"
16
17# Make the `zig version` number consistent.
18# This will affect the cmake command below.
19git fetch --unshallow || true
20git fetch --tags
21
22# Override the cache directories because they won't actually help other CI runs
23# which will be testing alternate versions of zig, and ultimately would just
24# fill up space on the hard drive for no reason.
25export ZIG_GLOBAL_CACHE_DIR="$PWD/zig-global-cache"
26export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
27
28mkdir build-debug
29cd build-debug
30
31export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
32export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
33
34cmake .. \
35 -DCMAKE_INSTALL_PREFIX="stage3-debug" \
36 -DCMAKE_PREFIX_PATH="$PREFIX" \
37 -DCMAKE_BUILD_TYPE=Debug \
38 -DZIG_TARGET_TRIPLE="$TARGET" \
39 -DZIG_TARGET_MCPU="$MCPU" \
40 -DZIG_STATIC=ON \
41 -DZIG_NO_LIB=ON \
42 -GNinja
43
44# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
45# so that installation and testing do not get affected by them.
46unset CC
47unset CXX
48
49ninja install
50
51# No -fqemu and -fwasmtime here as they're covered by the x86_64-linux scripts.
52stage3-debug/bin/zig build test-cases test-modules test-unit test-standalone test-c-abi test-link test-stack-traces test-asm-link test-llvm-ir docs \
53 --maxrss 34359738368 \
54 -Dstatic-llvm \
55 -Dskip-non-native \
56 -Dtarget=native-native-musl \
57 --search-prefix "$PREFIX" \
58 --zig-lib-dir "$PWD/../lib"
ci/riscv64-linux-release.sh created+58
...@@ -0,0 +1,58 @@
1#!/bin/sh
2
3# Requires cmake ninja-build
4
5set -x
6set -e
7
8ARCH="$(uname -m)"
9TARGET="$ARCH-linux-musl"
10MCPU="spacemit_x60"
11CACHE_BASENAME="zig+llvm+lld+clang-riscv64-linux-musl-0.15.0-dev.929+31e46be74"
12PREFIX="$HOME/deps/$CACHE_BASENAME"
13ZIG="$PREFIX/bin/zig"
14
15export PATH="$HOME/local/bin:$PATH"
16
17# Make the `zig version` number consistent.
18# This will affect the cmake command below.
19git fetch --unshallow || true
20git fetch --tags
21
22# Override the cache directories because they won't actually help other CI runs
23# which will be testing alternate versions of zig, and ultimately would just
24# fill up space on the hard drive for no reason.
25export ZIG_GLOBAL_CACHE_DIR="$PWD/zig-global-cache"
26export ZIG_LOCAL_CACHE_DIR="$PWD/zig-local-cache"
27
28mkdir build-release
29cd build-release
30
31export CC="$ZIG cc -target $TARGET -mcpu=$MCPU"
32export CXX="$ZIG c++ -target $TARGET -mcpu=$MCPU"
33
34cmake .. \
35 -DCMAKE_INSTALL_PREFIX="stage3-release" \
36 -DCMAKE_PREFIX_PATH="$PREFIX" \
37 -DCMAKE_BUILD_TYPE=Release \
38 -DZIG_TARGET_TRIPLE="$TARGET" \
39 -DZIG_TARGET_MCPU="$MCPU" \
40 -DZIG_STATIC=ON \
41 -DZIG_NO_LIB=ON \
42 -GNinja
43
44# Now cmake will use zig as the C/C++ compiler. We reset the environment variables
45# so that installation and testing do not get affected by them.
46unset CC
47unset CXX
48
49ninja install
50
51# No -fqemu and -fwasmtime here as they're covered by the x86_64-linux scripts.
52stage3-release/bin/zig build test-cases test-modules test-unit test-standalone test-c-abi test-link test-stack-traces test-asm-link test-llvm-ir docs \
53 --maxrss 34359738368 \
54 -Dstatic-llvm \
55 -Dskip-non-native \
56 -Dtarget=native-native-musl \
57 --search-prefix "$PREFIX" \
58 --zig-lib-dir "$PWD/../lib"
doc/langref/build_c.zig+2-1
...@@ -1,7 +1,8 @@...@@ -1,7 +1,8 @@
1const std = @import("std");1const std = @import("std");
22
3pub fn build(b: *std.Build) void {3pub fn build(b: *std.Build) void {
4 const lib = b.addSharedLibrary(.{4 const lib = b.addLibrary(.{
5 .linkage = .dynamic,
5 .name = "mathtest",6 .name = "mathtest",
6 .root_source_file = b.path("mathtest.zig"),7 .root_source_file = b.path("mathtest.zig"),
7 .version = .{ .major = 1, .minor = 0, .patch = 0 },8 .version = .{ .major = 1, .minor = 0, .patch = 0 },
doc/langref/test_noreturn_from_exit.zig+1-1
...@@ -3,7 +3,7 @@ const builtin = @import("builtin");...@@ -3,7 +3,7 @@ const builtin = @import("builtin");
3const native_arch = builtin.cpu.arch;3const native_arch = builtin.cpu.arch;
4const expect = std.testing.expect;4const expect = std.testing.expect;
55
6const WINAPI: std.builtin.CallingConvention = if (native_arch == .x86) .Stdcall else .C;6const WINAPI: std.builtin.CallingConvention = if (native_arch == .x86) .{ .x86_stdcall = .{} } else .c;
7extern "kernel32" fn ExitProcess(exit_code: c_uint) callconv(WINAPI) noreturn;7extern "kernel32" fn ExitProcess(exit_code: c_uint) callconv(WINAPI) noreturn;
88
9test "foo" {9test "foo" {
lib/compiler/aro/aro/Parser.zig+1-1
...@@ -8259,7 +8259,7 @@ fn charLiteral(p: *Parser) Error!Result {...@@ -8259,7 +8259,7 @@ fn charLiteral(p: *Parser) Error!Result {
8259 const slice = char_kind.contentSlice(p.tokSlice(p.tok_i));8259 const slice = char_kind.contentSlice(p.tokSlice(p.tok_i));
82608260
8261 var is_multichar = false;8261 var is_multichar = false;
8262 if (slice.len == 1 and std.ascii.isASCII(slice[0])) {8262 if (slice.len == 1 and std.ascii.isAscii(slice[0])) {
8263 // fast path: single unescaped ASCII char8263 // fast path: single unescaped ASCII char
8264 val = slice[0];8264 val = slice[0];
8265 } else {8265 } else {
lib/compiler/aro_translate_c.zig+1-1
...@@ -1820,7 +1820,7 @@ pub fn main() !void {...@@ -1820,7 +1820,7 @@ pub fn main() !void {
1820 var tree = translate(gpa, &aro_comp, args) catch |err| switch (err) {1820 var tree = translate(gpa, &aro_comp, args) catch |err| switch (err) {
1821 error.ParsingFailed, error.FatalError => renderErrorsAndExit(&aro_comp),1821 error.ParsingFailed, error.FatalError => renderErrorsAndExit(&aro_comp),
1822 error.OutOfMemory => return error.OutOfMemory,1822 error.OutOfMemory => return error.OutOfMemory,
1823 error.StreamTooLong => std.zig.fatal("An input file was larger than 4GiB", .{}),1823 error.StreamTooLong => std.process.fatal("An input file was larger than 4GiB", .{}),
1824 };1824 };
1825 defer tree.deinit(gpa);1825 defer tree.deinit(gpa);
18261826
lib/compiler/objcopy.zig+1-1
...@@ -7,7 +7,7 @@ const Allocator = std.mem.Allocator;...@@ -7,7 +7,7 @@ const Allocator = std.mem.Allocator;
7const File = std.fs.File;7const File = std.fs.File;
8const assert = std.debug.assert;8const assert = std.debug.assert;
99
10const fatal = std.zig.fatal;10const fatal = std.process.fatal;
11const Server = std.zig.Server;11const Server = std.zig.Server;
1212
13pub fn main() !void {13pub fn main() !void {
lib/std/Build.zig+7-314
...@@ -693,6 +693,7 @@ pub fn addOptions(b: *Build) *Step.Options {...@@ -693,6 +693,7 @@ pub fn addOptions(b: *Build) *Step.Options {
693693
694pub const ExecutableOptions = struct {694pub const ExecutableOptions = struct {
695 name: []const u8,695 name: []const u8,
696 root_module: *Module,
696 version: ?std.SemanticVersion = null,697 version: ?std.SemanticVersion = null,
697 linkage: ?std.builtin.LinkMode = null,698 linkage: ?std.builtin.LinkMode = null,
698 max_rss: usize = 0,699 max_rss: usize = 0,
...@@ -705,58 +706,12 @@ pub const ExecutableOptions = struct {...@@ -705,58 +706,12 @@ pub const ExecutableOptions = struct {
705 /// Can be set regardless of target. The `.manifest` file will be ignored706 /// Can be set regardless of target. The `.manifest` file will be ignored
706 /// if the target object format does not support embedded manifests.707 /// if the target object format does not support embedded manifests.
707 win32_manifest: ?LazyPath = null,708 win32_manifest: ?LazyPath = null,
708
709 /// Prefer populating this field (using e.g. `createModule`) instead of populating
710 /// the following fields (`root_source_file` etc). In a future release, those fields
711 /// will be removed, and this field will become non-optional.
712 root_module: ?*Module = null,
713
714 /// Deprecated; prefer populating `root_module`.
715 root_source_file: ?LazyPath = null,
716 /// Deprecated; prefer populating `root_module`.
717 target: ?ResolvedTarget = null,
718 /// Deprecated; prefer populating `root_module`.
719 optimize: std.builtin.OptimizeMode = .Debug,
720 /// Deprecated; prefer populating `root_module`.
721 code_model: std.builtin.CodeModel = .default,
722 /// Deprecated; prefer populating `root_module`.
723 link_libc: ?bool = null,
724 /// Deprecated; prefer populating `root_module`.
725 single_threaded: ?bool = null,
726 /// Deprecated; prefer populating `root_module`.
727 pic: ?bool = null,
728 /// Deprecated; prefer populating `root_module`.
729 strip: ?bool = null,
730 /// Deprecated; prefer populating `root_module`.
731 unwind_tables: ?std.builtin.UnwindTables = null,
732 /// Deprecated; prefer populating `root_module`.
733 omit_frame_pointer: ?bool = null,
734 /// Deprecated; prefer populating `root_module`.
735 sanitize_thread: ?bool = null,
736 /// Deprecated; prefer populating `root_module`.
737 error_tracing: ?bool = null,
738};709};
739710
740pub fn addExecutable(b: *Build, options: ExecutableOptions) *Step.Compile {711pub fn addExecutable(b: *Build, options: ExecutableOptions) *Step.Compile {
741 if (options.root_module != null and options.target != null) {
742 @panic("`root_module` and `target` cannot both be populated");
743 }
744 return .create(b, .{712 return .create(b, .{
745 .name = options.name,713 .name = options.name,
746 .root_module = options.root_module orelse b.createModule(.{714 .root_module = options.root_module,
747 .root_source_file = options.root_source_file,
748 .target = options.target orelse @panic("`root_module` and `target` cannot both be null"),
749 .optimize = options.optimize,
750 .link_libc = options.link_libc,
751 .single_threaded = options.single_threaded,
752 .pic = options.pic,
753 .strip = options.strip,
754 .unwind_tables = options.unwind_tables,
755 .omit_frame_pointer = options.omit_frame_pointer,
756 .sanitize_thread = options.sanitize_thread,
757 .error_tracing = options.error_tracing,
758 .code_model = options.code_model,
759 }),
760 .version = options.version,715 .version = options.version,
761 .kind = .exe,716 .kind = .exe,
762 .linkage = options.linkage,717 .linkage = options.linkage,
...@@ -770,62 +725,17 @@ pub fn addExecutable(b: *Build, options: ExecutableOptions) *Step.Compile {...@@ -770,62 +725,17 @@ pub fn addExecutable(b: *Build, options: ExecutableOptions) *Step.Compile {
770725
771pub const ObjectOptions = struct {726pub const ObjectOptions = struct {
772 name: []const u8,727 name: []const u8,
728 root_module: *Module,
773 max_rss: usize = 0,729 max_rss: usize = 0,
774 use_llvm: ?bool = null,730 use_llvm: ?bool = null,
775 use_lld: ?bool = null,731 use_lld: ?bool = null,
776 zig_lib_dir: ?LazyPath = null,732 zig_lib_dir: ?LazyPath = null,
777
778 /// Prefer populating this field (using e.g. `createModule`) instead of populating
779 /// the following fields (`root_source_file` etc). In a future release, those fields
780 /// will be removed, and this field will become non-optional.
781 root_module: ?*Module = null,
782
783 /// Deprecated; prefer populating `root_module`.
784 root_source_file: ?LazyPath = null,
785 /// Deprecated; prefer populating `root_module`.
786 target: ?ResolvedTarget = null,
787 /// Deprecated; prefer populating `root_module`.
788 optimize: std.builtin.OptimizeMode = .Debug,
789 /// Deprecated; prefer populating `root_module`.
790 code_model: std.builtin.CodeModel = .default,
791 /// Deprecated; prefer populating `root_module`.
792 link_libc: ?bool = null,
793 /// Deprecated; prefer populating `root_module`.
794 single_threaded: ?bool = null,
795 /// Deprecated; prefer populating `root_module`.
796 pic: ?bool = null,
797 /// Deprecated; prefer populating `root_module`.
798 strip: ?bool = null,
799 /// Deprecated; prefer populating `root_module`.
800 unwind_tables: ?std.builtin.UnwindTables = null,
801 /// Deprecated; prefer populating `root_module`.
802 omit_frame_pointer: ?bool = null,
803 /// Deprecated; prefer populating `root_module`.
804 sanitize_thread: ?bool = null,
805 /// Deprecated; prefer populating `root_module`.
806 error_tracing: ?bool = null,
807};733};
808734
809pub fn addObject(b: *Build, options: ObjectOptions) *Step.Compile {735pub fn addObject(b: *Build, options: ObjectOptions) *Step.Compile {
810 if (options.root_module != null and options.target != null) {
811 @panic("`root_module` and `target` cannot both be populated");
812 }
813 return .create(b, .{736 return .create(b, .{
814 .name = options.name,737 .name = options.name,
815 .root_module = options.root_module orelse b.createModule(.{738 .root_module = options.root_module,
816 .root_source_file = options.root_source_file,
817 .target = options.target orelse @panic("`root_module` and `target` cannot both be null"),
818 .optimize = options.optimize,
819 .link_libc = options.link_libc,
820 .single_threaded = options.single_threaded,
821 .pic = options.pic,
822 .strip = options.strip,
823 .unwind_tables = options.unwind_tables,
824 .omit_frame_pointer = options.omit_frame_pointer,
825 .sanitize_thread = options.sanitize_thread,
826 .error_tracing = options.error_tracing,
827 .code_model = options.code_model,
828 }),
829 .kind = .obj,739 .kind = .obj,
830 .max_rss = options.max_rss,740 .max_rss = options.max_rss,
831 .use_llvm = options.use_llvm,741 .use_llvm = options.use_llvm,
...@@ -834,153 +744,6 @@ pub fn addObject(b: *Build, options: ObjectOptions) *Step.Compile {...@@ -834,153 +744,6 @@ pub fn addObject(b: *Build, options: ObjectOptions) *Step.Compile {
834 });744 });
835}745}
836746
837pub const SharedLibraryOptions = struct {
838 name: []const u8,
839 version: ?std.SemanticVersion = null,
840 max_rss: usize = 0,
841 use_llvm: ?bool = null,
842 use_lld: ?bool = null,
843 zig_lib_dir: ?LazyPath = null,
844 /// Embed a `.manifest` file in the compilation if the object format supports it.
845 /// https://learn.microsoft.com/en-us/windows/win32/sbscs/manifest-files-reference
846 /// Manifest files must have the extension `.manifest`.
847 /// Can be set regardless of target. The `.manifest` file will be ignored
848 /// if the target object format does not support embedded manifests.
849 win32_manifest: ?LazyPath = null,
850
851 /// Prefer populating this field (using e.g. `createModule`) instead of populating
852 /// the following fields (`root_source_file` etc). In a future release, those fields
853 /// will be removed, and this field will become non-optional.
854 root_module: ?*Module = null,
855
856 /// Deprecated; prefer populating `root_module`.
857 root_source_file: ?LazyPath = null,
858 /// Deprecated; prefer populating `root_module`.
859 target: ?ResolvedTarget = null,
860 /// Deprecated; prefer populating `root_module`.
861 optimize: std.builtin.OptimizeMode = .Debug,
862 /// Deprecated; prefer populating `root_module`.
863 code_model: std.builtin.CodeModel = .default,
864 /// Deprecated; prefer populating `root_module`.
865 link_libc: ?bool = null,
866 /// Deprecated; prefer populating `root_module`.
867 single_threaded: ?bool = null,
868 /// Deprecated; prefer populating `root_module`.
869 pic: ?bool = null,
870 /// Deprecated; prefer populating `root_module`.
871 strip: ?bool = null,
872 /// Deprecated; prefer populating `root_module`.
873 unwind_tables: ?std.builtin.UnwindTables = null,
874 /// Deprecated; prefer populating `root_module`.
875 omit_frame_pointer: ?bool = null,
876 /// Deprecated; prefer populating `root_module`.
877 sanitize_thread: ?bool = null,
878 /// Deprecated; prefer populating `root_module`.
879 error_tracing: ?bool = null,
880};
881
882/// Deprecated: use `b.addLibrary(.{ ..., .linkage = .dynamic })` instead.
883pub fn addSharedLibrary(b: *Build, options: SharedLibraryOptions) *Step.Compile {
884 if (options.root_module != null and options.target != null) {
885 @panic("`root_module` and `target` cannot both be populated");
886 }
887 return .create(b, .{
888 .name = options.name,
889 .root_module = options.root_module orelse b.createModule(.{
890 .target = options.target orelse @panic("`root_module` and `target` cannot both be null"),
891 .optimize = options.optimize,
892 .root_source_file = options.root_source_file,
893 .link_libc = options.link_libc,
894 .single_threaded = options.single_threaded,
895 .pic = options.pic,
896 .strip = options.strip,
897 .unwind_tables = options.unwind_tables,
898 .omit_frame_pointer = options.omit_frame_pointer,
899 .sanitize_thread = options.sanitize_thread,
900 .error_tracing = options.error_tracing,
901 .code_model = options.code_model,
902 }),
903 .kind = .lib,
904 .linkage = .dynamic,
905 .version = options.version,
906 .max_rss = options.max_rss,
907 .use_llvm = options.use_llvm,
908 .use_lld = options.use_lld,
909 .zig_lib_dir = options.zig_lib_dir,
910 .win32_manifest = options.win32_manifest,
911 });
912}
913
914pub const StaticLibraryOptions = struct {
915 name: []const u8,
916 version: ?std.SemanticVersion = null,
917 max_rss: usize = 0,
918 use_llvm: ?bool = null,
919 use_lld: ?bool = null,
920 zig_lib_dir: ?LazyPath = null,
921
922 /// Prefer populating this field (using e.g. `createModule`) instead of populating
923 /// the following fields (`root_source_file` etc). In a future release, those fields
924 /// will be removed, and this field will become non-optional.
925 root_module: ?*Module = null,
926
927 /// Deprecated; prefer populating `root_module`.
928 root_source_file: ?LazyPath = null,
929 /// Deprecated; prefer populating `root_module`.
930 target: ?ResolvedTarget = null,
931 /// Deprecated; prefer populating `root_module`.
932 optimize: std.builtin.OptimizeMode = .Debug,
933 /// Deprecated; prefer populating `root_module`.
934 code_model: std.builtin.CodeModel = .default,
935 /// Deprecated; prefer populating `root_module`.
936 link_libc: ?bool = null,
937 /// Deprecated; prefer populating `root_module`.
938 single_threaded: ?bool = null,
939 /// Deprecated; prefer populating `root_module`.
940 pic: ?bool = null,
941 /// Deprecated; prefer populating `root_module`.
942 strip: ?bool = null,
943 /// Deprecated; prefer populating `root_module`.
944 unwind_tables: ?std.builtin.UnwindTables = null,
945 /// Deprecated; prefer populating `root_module`.
946 omit_frame_pointer: ?bool = null,
947 /// Deprecated; prefer populating `root_module`.
948 sanitize_thread: ?bool = null,
949 /// Deprecated; prefer populating `root_module`.
950 error_tracing: ?bool = null,
951};
952
953/// Deprecated: use `b.addLibrary(.{ ..., .linkage = .static })` instead.
954pub fn addStaticLibrary(b: *Build, options: StaticLibraryOptions) *Step.Compile {
955 if (options.root_module != null and options.target != null) {
956 @panic("`root_module` and `target` cannot both be populated");
957 }
958 return .create(b, .{
959 .name = options.name,
960 .root_module = options.root_module orelse b.createModule(.{
961 .target = options.target orelse @panic("`root_module` and `target` cannot both be null"),
962 .optimize = options.optimize,
963 .root_source_file = options.root_source_file,
964 .link_libc = options.link_libc,
965 .single_threaded = options.single_threaded,
966 .pic = options.pic,
967 .strip = options.strip,
968 .unwind_tables = options.unwind_tables,
969 .omit_frame_pointer = options.omit_frame_pointer,
970 .sanitize_thread = options.sanitize_thread,
971 .error_tracing = options.error_tracing,
972 .code_model = options.code_model,
973 }),
974 .kind = .lib,
975 .linkage = .static,
976 .version = options.version,
977 .max_rss = options.max_rss,
978 .use_llvm = options.use_llvm,
979 .use_lld = options.use_lld,
980 .zig_lib_dir = options.zig_lib_dir,
981 });
982}
983
984pub const LibraryOptions = struct {747pub const LibraryOptions = struct {
985 linkage: std.builtin.LinkMode = .static,748 linkage: std.builtin.LinkMode = .static,
986 name: []const u8,749 name: []const u8,
...@@ -1015,9 +778,8 @@ pub fn addLibrary(b: *Build, options: LibraryOptions) *Step.Compile {...@@ -1015,9 +778,8 @@ pub fn addLibrary(b: *Build, options: LibraryOptions) *Step.Compile {
1015778
1016pub const TestOptions = struct {779pub const TestOptions = struct {
1017 name: []const u8 = "test",780 name: []const u8 = "test",
781 root_module: *Module,
1018 max_rss: usize = 0,782 max_rss: usize = 0,
1019 /// Deprecated; use `.filters = &.{filter}` instead of `.filter = filter`.
1020 filter: ?[]const u8 = null,
1021 filters: []const []const u8 = &.{},783 filters: []const []const u8 = &.{},
1022 test_runner: ?Step.Compile.TestRunner = null,784 test_runner: ?Step.Compile.TestRunner = null,
1023 use_llvm: ?bool = null,785 use_llvm: ?bool = null,
...@@ -1027,38 +789,6 @@ pub const TestOptions = struct {...@@ -1027,38 +789,6 @@ pub const TestOptions = struct {
1027 /// The object must be linked separately.789 /// The object must be linked separately.
1028 /// Usually used in conjunction with a custom `test_runner`.790 /// Usually used in conjunction with a custom `test_runner`.
1029 emit_object: bool = false,791 emit_object: bool = false,
1030
1031 /// Prefer populating this field (using e.g. `createModule`) instead of populating
1032 /// the following fields (`root_source_file` etc). In a future release, those fields
1033 /// will be removed, and this field will become non-optional.
1034 root_module: ?*Module = null,
1035
1036 /// Deprecated; prefer populating `root_module`.
1037 root_source_file: ?LazyPath = null,
1038 /// Deprecated; prefer populating `root_module`.
1039 target: ?ResolvedTarget = null,
1040 /// Deprecated; prefer populating `root_module`.
1041 optimize: std.builtin.OptimizeMode = .Debug,
1042 /// Deprecated; prefer populating `root_module`.
1043 version: ?std.SemanticVersion = null,
1044 /// Deprecated; prefer populating `root_module`.
1045 link_libc: ?bool = null,
1046 /// Deprecated; prefer populating `root_module`.
1047 link_libcpp: ?bool = null,
1048 /// Deprecated; prefer populating `root_module`.
1049 single_threaded: ?bool = null,
1050 /// Deprecated; prefer populating `root_module`.
1051 pic: ?bool = null,
1052 /// Deprecated; prefer populating `root_module`.
1053 strip: ?bool = null,
1054 /// Deprecated; prefer populating `root_module`.
1055 unwind_tables: ?std.builtin.UnwindTables = null,
1056 /// Deprecated; prefer populating `root_module`.
1057 omit_frame_pointer: ?bool = null,
1058 /// Deprecated; prefer populating `root_module`.
1059 sanitize_thread: ?bool = null,
1060 /// Deprecated; prefer populating `root_module`.
1061 error_tracing: ?bool = null,
1062};792};
1063793
1064/// Creates an executable containing unit tests.794/// Creates an executable containing unit tests.
...@@ -1070,33 +800,12 @@ pub const TestOptions = struct {...@@ -1070,33 +800,12 @@ pub const TestOptions = struct {
1070/// two steps are separated because they are independently configured and800/// two steps are separated because they are independently configured and
1071/// cached.801/// cached.
1072pub fn addTest(b: *Build, options: TestOptions) *Step.Compile {802pub fn addTest(b: *Build, options: TestOptions) *Step.Compile {
1073 if (options.root_module != null and options.root_source_file != null) {
1074 @panic("`root_module` and `root_source_file` cannot both be populated");
1075 }
1076 return .create(b, .{803 return .create(b, .{
1077 .name = options.name,804 .name = options.name,
1078 .kind = if (options.emit_object) .test_obj else .@"test",805 .kind = if (options.emit_object) .test_obj else .@"test",
1079 .root_module = options.root_module orelse b.createModule(.{806 .root_module = options.root_module,
1080 .root_source_file = options.root_source_file orelse @panic("`root_module` and `root_source_file` cannot both be null"),
1081 .target = options.target orelse b.graph.host,
1082 .optimize = options.optimize,
1083 .link_libc = options.link_libc,
1084 .link_libcpp = options.link_libcpp,
1085 .single_threaded = options.single_threaded,
1086 .pic = options.pic,
1087 .strip = options.strip,
1088 .unwind_tables = options.unwind_tables,
1089 .omit_frame_pointer = options.omit_frame_pointer,
1090 .sanitize_thread = options.sanitize_thread,
1091 .error_tracing = options.error_tracing,
1092 }),
1093 .max_rss = options.max_rss,807 .max_rss = options.max_rss,
1094 .filters = if (options.filter != null and options.filters.len > 0) filters: {808 .filters = b.dupeStrings(options.filters),
1095 const filters = b.allocator.alloc([]const u8, 1 + options.filters.len) catch @panic("OOM");
1096 filters[0] = b.dupe(options.filter.?);
1097 for (filters[1..], options.filters) |*dest, source| dest.* = b.dupe(source);
1098 break :filters filters;
1099 } else b.dupeStrings(if (options.filter) |filter| &.{filter} else options.filters),
1100 .test_runner = options.test_runner,809 .test_runner = options.test_runner,
1101 .use_llvm = options.use_llvm,810 .use_llvm = options.use_llvm,
1102 .use_lld = options.use_lld,811 .use_lld = options.use_lld,
...@@ -1115,22 +824,6 @@ pub const AssemblyOptions = struct {...@@ -1115,22 +824,6 @@ pub const AssemblyOptions = struct {
1115 zig_lib_dir: ?LazyPath = null,824 zig_lib_dir: ?LazyPath = null,
1116};825};
1117826
1118/// Deprecated; prefer using `addObject` where the `root_module` has an empty
1119/// `root_source_file` and contains an assembly file via `Module.addAssemblyFile`.
1120pub fn addAssembly(b: *Build, options: AssemblyOptions) *Step.Compile {
1121 const root_module = b.createModule(.{
1122 .target = options.target,
1123 .optimize = options.optimize,
1124 });
1125 root_module.addAssemblyFile(options.source_file);
1126 return b.addObject(.{
1127 .name = options.name,
1128 .max_rss = options.max_rss,
1129 .zig_lib_dir = options.zig_lib_dir,
1130 .root_module = root_module,
1131 });
1132}
1133
1134/// This function creates a module and adds it to the package's module set, making827/// This function creates a module and adds it to the package's module set, making
1135/// it available to other packages which depend on this one.828/// it available to other packages which depend on this one.
1136/// `createModule` can be used instead to create a private module.829/// `createModule` can be used instead to create a private module.
lib/std/Build/Cache.zig+6-5
...@@ -661,7 +661,8 @@ pub const Manifest = struct {...@@ -661,7 +661,8 @@ pub const Manifest = struct {
661 } {661 } {
662 const gpa = self.cache.gpa;662 const gpa = self.cache.gpa;
663 const input_file_count = self.files.entries.len;663 const input_file_count = self.files.entries.len;
664 var manifest_reader = self.manifest_file.?.reader(&.{}); // Reads positionally from zero.664 var tiny_buffer: [1]u8 = undefined; // allows allocRemaining to detect limit exceeded
665 var manifest_reader = self.manifest_file.?.reader(&tiny_buffer); // Reads positionally from zero.
665 const limit: std.io.Limit = .limited(manifest_file_size_max);666 const limit: std.io.Limit = .limited(manifest_file_size_max);
666 const file_contents = manifest_reader.interface.allocRemaining(gpa, limit) catch |err| switch (err) {667 const file_contents = manifest_reader.interface.allocRemaining(gpa, limit) catch |err| switch (err) {
667 error.OutOfMemory => return error.OutOfMemory,668 error.OutOfMemory => return error.OutOfMemory,
...@@ -1326,7 +1327,7 @@ test "cache file and then recall it" {...@@ -1326,7 +1327,7 @@ test "cache file and then recall it" {
1326 // Wait for file timestamps to tick1327 // Wait for file timestamps to tick
1327 const initial_time = try testGetCurrentFileTimestamp(tmp.dir);1328 const initial_time = try testGetCurrentFileTimestamp(tmp.dir);
1328 while ((try testGetCurrentFileTimestamp(tmp.dir)) == initial_time) {1329 while ((try testGetCurrentFileTimestamp(tmp.dir)) == initial_time) {
1329 std.time.sleep(1);1330 std.Thread.sleep(1);
1330 }1331 }
13311332
1332 var digest1: HexDigest = undefined;1333 var digest1: HexDigest = undefined;
...@@ -1389,7 +1390,7 @@ test "check that changing a file makes cache fail" {...@@ -1389,7 +1390,7 @@ test "check that changing a file makes cache fail" {
1389 // Wait for file timestamps to tick1390 // Wait for file timestamps to tick
1390 const initial_time = try testGetCurrentFileTimestamp(tmp.dir);1391 const initial_time = try testGetCurrentFileTimestamp(tmp.dir);
1391 while ((try testGetCurrentFileTimestamp(tmp.dir)) == initial_time) {1392 while ((try testGetCurrentFileTimestamp(tmp.dir)) == initial_time) {
1392 std.time.sleep(1);1393 std.Thread.sleep(1);
1393 }1394 }
13941395
1395 var digest1: HexDigest = undefined;1396 var digest1: HexDigest = undefined;
...@@ -1501,7 +1502,7 @@ test "Manifest with files added after initial hash work" {...@@ -1501,7 +1502,7 @@ test "Manifest with files added after initial hash work" {
1501 // Wait for file timestamps to tick1502 // Wait for file timestamps to tick
1502 const initial_time = try testGetCurrentFileTimestamp(tmp.dir);1503 const initial_time = try testGetCurrentFileTimestamp(tmp.dir);
1503 while ((try testGetCurrentFileTimestamp(tmp.dir)) == initial_time) {1504 while ((try testGetCurrentFileTimestamp(tmp.dir)) == initial_time) {
1504 std.time.sleep(1);1505 std.Thread.sleep(1);
1505 }1506 }
15061507
1507 var digest1: HexDigest = undefined;1508 var digest1: HexDigest = undefined;
...@@ -1551,7 +1552,7 @@ test "Manifest with files added after initial hash work" {...@@ -1551,7 +1552,7 @@ test "Manifest with files added after initial hash work" {
1551 // Wait for file timestamps to tick1552 // Wait for file timestamps to tick
1552 const initial_time2 = try testGetCurrentFileTimestamp(tmp.dir);1553 const initial_time2 = try testGetCurrentFileTimestamp(tmp.dir);
1553 while ((try testGetCurrentFileTimestamp(tmp.dir)) == initial_time2) {1554 while ((try testGetCurrentFileTimestamp(tmp.dir)) == initial_time2) {
1554 std.time.sleep(1);1555 std.Thread.sleep(1);
1555 }1556 }
15561557
1557 {1558 {
lib/std/Build/Step/ConfigHeader.zig+3-6
...@@ -8,9 +8,6 @@ pub const Style = union(enum) {...@@ -8,9 +8,6 @@ pub const Style = union(enum) {
8 /// A configure format supported by autotools that uses `#undef foo` to8 /// A configure format supported by autotools that uses `#undef foo` to
9 /// mark lines that can be substituted with different values.9 /// mark lines that can be substituted with different values.
10 autoconf_undef: std.Build.LazyPath,10 autoconf_undef: std.Build.LazyPath,
11 /// Deprecated. Renamed to `autoconf_undef`.
12 /// To be removed after 0.14.0 is tagged.
13 autoconf: std.Build.LazyPath,
14 /// A configure format supported by autotools that uses `@FOO@` output variables.11 /// A configure format supported by autotools that uses `@FOO@` output variables.
15 autoconf_at: std.Build.LazyPath,12 autoconf_at: std.Build.LazyPath,
16 /// The configure format supported by CMake. It uses `@FOO@`, `${}` and13 /// The configure format supported by CMake. It uses `@FOO@`, `${}` and
...@@ -23,7 +20,7 @@ pub const Style = union(enum) {...@@ -23,7 +20,7 @@ pub const Style = union(enum) {
2320
24 pub fn getPath(style: Style) ?std.Build.LazyPath {21 pub fn getPath(style: Style) ?std.Build.LazyPath {
25 switch (style) {22 switch (style) {
26 .autoconf_undef, .autoconf, .autoconf_at, .cmake => |s| return s,23 .autoconf_undef, .autoconf_at, .cmake => |s| return s,
27 .blank, .nasm => return null,24 .blank, .nasm => return null,
28 }25 }
29 }26 }
...@@ -205,7 +202,7 @@ fn make(step: *Step, options: Step.MakeOptions) !void {...@@ -205,7 +202,7 @@ fn make(step: *Step, options: Step.MakeOptions) !void {
205 const asm_generated_line = "; " ++ header_text ++ "\n";202 const asm_generated_line = "; " ++ header_text ++ "\n";
206203
207 switch (config_header.style) {204 switch (config_header.style) {
208 .autoconf_undef, .autoconf, .autoconf_at => |file_source| {205 .autoconf_undef, .autoconf_at => |file_source| {
209 try bw.writeAll(c_generated_line);206 try bw.writeAll(c_generated_line);
210 const src_path = file_source.getPath2(b, step);207 const src_path = file_source.getPath2(b, step);
211 const contents = std.fs.cwd().readFileAlloc(src_path, arena, .limited(config_header.max_bytes)) catch |err| {208 const contents = std.fs.cwd().readFileAlloc(src_path, arena, .limited(config_header.max_bytes)) catch |err| {
...@@ -214,7 +211,7 @@ fn make(step: *Step, options: Step.MakeOptions) !void {...@@ -214,7 +211,7 @@ fn make(step: *Step, options: Step.MakeOptions) !void {
214 });211 });
215 };212 };
216 switch (config_header.style) {213 switch (config_header.style) {
217 .autoconf_undef, .autoconf => try render_autoconf_undef(step, contents, bw, config_header.values, src_path),214 .autoconf_undef => try render_autoconf_undef(step, contents, bw, config_header.values, src_path),
218 .autoconf_at => try render_autoconf_at(step, contents, &aw, config_header.values, src_path),215 .autoconf_at => try render_autoconf_at(step, contents, &aw, config_header.values, src_path),
219 else => unreachable,216 else => unreachable,
220 }217 }
lib/std/Build/Step/Run.zig+15-3
...@@ -1083,7 +1083,9 @@ fn runCommand(...@@ -1083,7 +1083,9 @@ fn runCommand(
1083 var interp_argv = std.ArrayList([]const u8).init(b.allocator);1083 var interp_argv = std.ArrayList([]const u8).init(b.allocator);
1084 defer interp_argv.deinit();1084 defer interp_argv.deinit();
10851085
1086 const result = spawnChildAndCollect(run, argv, has_side_effects, prog_node, fuzz_context) catch |err| term: {1086 var env_map = run.env_map orelse &b.graph.env_map;
1087
1088 const result = spawnChildAndCollect(run, argv, env_map, has_side_effects, prog_node, fuzz_context) catch |err| term: {
1087 // InvalidExe: cpu arch mismatch1089 // InvalidExe: cpu arch mismatch
1088 // FileNotFound: can happen with a wrong dynamic linker path1090 // FileNotFound: can happen with a wrong dynamic linker path
1089 if (err == error.InvalidExe or err == error.FileNotFound) interpret: {1091 if (err == error.InvalidExe or err == error.FileNotFound) interpret: {
...@@ -1116,6 +1118,15 @@ fn runCommand(...@@ -1116,6 +1118,15 @@ fn runCommand(
1116 if (b.enable_wine) {1118 if (b.enable_wine) {
1117 try interp_argv.append(bin_name);1119 try interp_argv.append(bin_name);
1118 try interp_argv.appendSlice(argv);1120 try interp_argv.appendSlice(argv);
1121
1122 // Wine's excessive stderr logging is only situationally helpful. Disable it by default, but
1123 // allow the user to override it (e.g. with `WINEDEBUG=err+all`) if desired.
1124 if (env_map.get("WINEDEBUG") == null) {
1125 // We don't own `env_map` at this point, so turn it into a copy before modifying it.
1126 env_map = arena.create(EnvMap) catch @panic("OOM");
1127 env_map.hash_map = try env_map.hash_map.cloneWithAllocator(arena);
1128 try env_map.put("WINEDEBUG", "-all");
1129 }
1119 } else {1130 } else {
1120 return failForeign(run, "-fwine", argv[0], exe);1131 return failForeign(run, "-fwine", argv[0], exe);
1121 }1132 }
...@@ -1211,7 +1222,7 @@ fn runCommand(...@@ -1211,7 +1222,7 @@ fn runCommand(
12111222
1212 try Step.handleVerbose2(step.owner, cwd, run.env_map, interp_argv.items);1223 try Step.handleVerbose2(step.owner, cwd, run.env_map, interp_argv.items);
12131224
1214 break :term spawnChildAndCollect(run, interp_argv.items, has_side_effects, prog_node, fuzz_context) catch |e| {1225 break :term spawnChildAndCollect(run, interp_argv.items, env_map, has_side_effects, prog_node, fuzz_context) catch |e| {
1215 if (!run.failing_to_execute_foreign_is_an_error) return error.MakeSkipped;1226 if (!run.failing_to_execute_foreign_is_an_error) return error.MakeSkipped;
12161227
1217 return step.fail("unable to spawn interpreter {s}: {s}", .{1228 return step.fail("unable to spawn interpreter {s}: {s}", .{
...@@ -1394,6 +1405,7 @@ const ChildProcResult = struct {...@@ -1394,6 +1405,7 @@ const ChildProcResult = struct {
1394fn spawnChildAndCollect(1405fn spawnChildAndCollect(
1395 run: *Run,1406 run: *Run,
1396 argv: []const []const u8,1407 argv: []const []const u8,
1408 env_map: *EnvMap,
1397 has_side_effects: bool,1409 has_side_effects: bool,
1398 prog_node: std.Progress.Node,1410 prog_node: std.Progress.Node,
1399 fuzz_context: ?FuzzContext,1411 fuzz_context: ?FuzzContext,
...@@ -1410,7 +1422,7 @@ fn spawnChildAndCollect(...@@ -1410,7 +1422,7 @@ fn spawnChildAndCollect(
1410 if (run.cwd) |lazy_cwd| {1422 if (run.cwd) |lazy_cwd| {
1411 child.cwd = lazy_cwd.getPath2(b, &run.step);1423 child.cwd = lazy_cwd.getPath2(b, &run.step);
1412 }1424 }
1413 child.env_map = run.env_map orelse &b.graph.env_map;1425 child.env_map = env_map;
1414 child.request_resource_usage_statistics = true;1426 child.request_resource_usage_statistics = true;
14151427
1416 child.stdin_behavior = switch (run.stdio) {1428 child.stdin_behavior = switch (run.stdio) {
lib/std/Build/Step/TranslateC.zig-13
...@@ -63,19 +63,6 @@ pub fn getOutput(translate_c: *TranslateC) std.Build.LazyPath {...@@ -63,19 +63,6 @@ pub fn getOutput(translate_c: *TranslateC) std.Build.LazyPath {
63 return .{ .generated = .{ .file = &translate_c.output_file } };63 return .{ .generated = .{ .file = &translate_c.output_file } };
64}64}
6565
66/// Deprecated: use `createModule` or `addModule` with `std.Build.addExecutable` instead.
67/// Creates a step to build an executable from the translated source.
68pub fn addExecutable(translate_c: *TranslateC, options: AddExecutableOptions) *Step.Compile {
69 return translate_c.step.owner.addExecutable(.{
70 .root_source_file = translate_c.getOutput(),
71 .name = options.name orelse "translated_c",
72 .version = options.version,
73 .target = options.target orelse translate_c.target,
74 .optimize = options.optimize orelse translate_c.optimize,
75 .linkage = options.linkage,
76 });
77}
78
79/// Creates a module from the translated source and adds it to the package's66/// Creates a module from the translated source and adds it to the package's
80/// module set making it available to other packages which depend on this one.67/// module set making it available to other packages which depend on this one.
81/// `createModule` can be used instead to create a private module.68/// `createModule` can be used instead to create a private module.
lib/std/Build/Watch.zig+1-1
...@@ -4,7 +4,7 @@ const Watch = @This();...@@ -4,7 +4,7 @@ const Watch = @This();
4const Step = std.Build.Step;4const Step = std.Build.Step;
5const Allocator = std.mem.Allocator;5const Allocator = std.mem.Allocator;
6const assert = std.debug.assert;6const assert = std.debug.assert;
7const fatal = std.zig.fatal;7const fatal = std.process.fatal;
88
9dir_table: DirTable,9dir_table: DirTable,
10os: Os,10os: Os,
lib/std/Io.zig+1
...@@ -494,6 +494,7 @@ pub fn PollFiles(comptime StreamEnum: type) type {...@@ -494,6 +494,7 @@ pub fn PollFiles(comptime StreamEnum: type) type {
494494
495test {495test {
496 _ = Reader;496 _ = Reader;
497 _ = Reader.Limited;
497 _ = Writer;498 _ = Writer;
498 _ = @import("Io/test.zig");499 _ = @import("Io/test.zig");
499}500}
lib/std/Io/Reader.zig+20-4
...@@ -99,7 +99,7 @@ pub const ShortError = error{...@@ -99,7 +99,7 @@ pub const ShortError = error{
9999
100pub const failing: Reader = .{100pub const failing: Reader = .{
101 .vtable = &.{101 .vtable = &.{
102 .read = failingStream,102 .stream = failingStream,
103 .discard = failingDiscard,103 .discard = failingDiscard,
104 },104 },
105 .buffer = &.{},105 .buffer = &.{},
...@@ -245,6 +245,7 @@ pub fn appendRemaining(...@@ -245,6 +245,7 @@ pub fn appendRemaining(
245 list: *std.ArrayListAlignedUnmanaged(u8, alignment),245 list: *std.ArrayListAlignedUnmanaged(u8, alignment),
246 limit: Limit,246 limit: Limit,
247) LimitedAllocError!void {247) LimitedAllocError!void {
248 assert(r.buffer.len != 0); // Needed to detect limit exceeded without losing data.
248 const buffer = r.buffer;249 const buffer = r.buffer;
249 const buffer_contents = buffer[r.seek..r.end];250 const buffer_contents = buffer[r.seek..r.end];
250 const copy_len = limit.minInt(buffer_contents.len);251 const copy_len = limit.minInt(buffer_contents.len);
...@@ -858,8 +859,10 @@ pub fn streamDelimiter(r: *Reader, w: *Writer, delimiter: u8) StreamError!usize...@@ -858,8 +859,10 @@ pub fn streamDelimiter(r: *Reader, w: *Writer, delimiter: u8) StreamError!usize
858/// Appends to `w` contents by reading from the stream until `delimiter` is found.859/// Appends to `w` contents by reading from the stream until `delimiter` is found.
859/// Does not write the delimiter itself.860/// Does not write the delimiter itself.
860///861///
861/// Returns number of bytes streamed, which may be zero. End of stream can be862/// Returns number of bytes streamed, which may be zero. If the stream reaches
862/// detected by checking if the next byte in the stream is the delimiter.863/// the end, the reader buffer will be empty when this function returns.
864/// Otherwise, it will have at least one byte buffered, starting with the
865/// delimiter.
863///866///
864/// Asserts buffer capacity of at least one. This function performs better with867/// Asserts buffer capacity of at least one. This function performs better with
865/// larger buffers.868/// larger buffers.
...@@ -1000,6 +1003,18 @@ pub fn fill(r: *Reader, n: usize) Error!void {...@@ -1000,6 +1003,18 @@ pub fn fill(r: *Reader, n: usize) Error!void {
1000 @branchHint(.likely);1003 @branchHint(.likely);
1001 return;1004 return;
1002 }1005 }
1006 return fillUnbuffered(r, n);
1007}
1008
1009/// This internal function is separated from `fill` to encourage optimizers to inline `fill`, hence
1010/// propagating its `@branchHint` to usage sites. If these functions are combined, `fill` is large
1011/// enough that LLVM is reluctant to inline it, forcing usages of APIs like `takeInt` to go through
1012/// an expensive runtime function call just to figure out that the data is, in fact, already in the
1013/// buffer.
1014///
1015/// Missing this optimization can result in wall-clock time for the most affected benchmarks
1016/// increasing by a factor of 5 or more.
1017fn fillUnbuffered(r: *Reader, n: usize) Error!void {
1003 if (r.seek + n <= r.buffer.len) while (true) {1018 if (r.seek + n <= r.buffer.len) while (true) {
1004 const end_cap = r.buffer[r.end..];1019 const end_cap = r.buffer[r.end..];
1005 var writer: Writer = .fixed(end_cap);1020 var writer: Writer = .fixed(end_cap);
...@@ -1645,11 +1660,12 @@ test "readAlloc when the backing reader provides one byte at a time" {...@@ -1645,11 +1660,12 @@ test "readAlloc when the backing reader provides one byte at a time" {
1645 }1660 }
1646 };1661 };
1647 const str = "This is a test";1662 const str = "This is a test";
1663 var tiny_buffer: [1]u8 = undefined;
1648 var one_byte_stream: OneByteReader = .{1664 var one_byte_stream: OneByteReader = .{
1649 .str = str,1665 .str = str,
1650 .i = 0,1666 .i = 0,
1651 .reader = .{1667 .reader = .{
1652 .buffer = &.{},1668 .buffer = &tiny_buffer,
1653 .vtable = &.{ .stream = OneByteReader.stream },1669 .vtable = &.{ .stream = OneByteReader.stream },
1654 .seek = 0,1670 .seek = 0,
1655 .end = 0,1671 .end = 0,
lib/std/Io/Reader/Limited.zig+22-6
...@@ -25,18 +25,34 @@ pub fn init(reader: *Reader, limit: Limit, buffer: []u8) Limited {...@@ -25,18 +25,34 @@ pub fn init(reader: *Reader, limit: Limit, buffer: []u8) Limited {
25 };25 };
26}26}
2727
28fn stream(context: ?*anyopaque, w: *Writer, limit: Limit) Reader.StreamError!usize {28fn stream(r: *Reader, w: *Writer, limit: Limit) Reader.StreamError!usize {
29 const l: *Limited = @alignCast(@ptrCast(context));29 const l: *Limited = @fieldParentPtr("interface", r);
30 const combined_limit = limit.min(l.remaining);30 const combined_limit = limit.min(l.remaining);
31 const n = try l.unlimited_reader.read(w, combined_limit);31 const n = try l.unlimited.stream(w, combined_limit);
32 l.remaining = l.remaining.subtract(n).?;32 l.remaining = l.remaining.subtract(n).?;
33 return n;33 return n;
34}34}
3535
36fn discard(context: ?*anyopaque, limit: Limit) Reader.Error!usize {36test stream {
37 const l: *Limited = @alignCast(@ptrCast(context));37 var orig_buf: [10]u8 = undefined;
38 @memcpy(&orig_buf, "test bytes");
39 var fixed: std.Io.Reader = .fixed(&orig_buf);
40
41 var limit_buf: [1]u8 = undefined;
42 var limited: std.Io.Reader.Limited = .init(&fixed, @enumFromInt(4), &limit_buf);
43
44 var result_buf: [10]u8 = undefined;
45 var fixed_writer: std.Io.Writer = .fixed(&result_buf);
46 const streamed = try limited.interface.stream(&fixed_writer, @enumFromInt(7));
47
48 try std.testing.expect(streamed == 4);
49 try std.testing.expectEqualStrings("test", result_buf[0..streamed]);
50}
51
52fn discard(r: *Reader, limit: Limit) Reader.Error!usize {
53 const l: *Limited = @fieldParentPtr("interface", r);
38 const combined_limit = limit.min(l.remaining);54 const combined_limit = limit.min(l.remaining);
39 const n = try l.unlimited_reader.discard(combined_limit);55 const n = try l.unlimited.discard(combined_limit);
40 l.remaining = l.remaining.subtract(n).?;56 l.remaining = l.remaining.subtract(n).?;
41 return n;57 return n;
42}58}
lib/std/Io/Writer.zig+40-2
...@@ -114,7 +114,10 @@ pub const FileError = error{...@@ -114,7 +114,10 @@ pub const FileError = error{
114/// Writes to `buffer` and returns `error.WriteFailed` when it is full.114/// Writes to `buffer` and returns `error.WriteFailed` when it is full.
115pub fn fixed(buffer: []u8) Writer {115pub fn fixed(buffer: []u8) Writer {
116 return .{116 return .{
117 .vtable = &.{ .drain = fixedDrain },117 .vtable = &.{
118 .drain = fixedDrain,
119 .flush = noopFlush,
120 },
118 .buffer = buffer,121 .buffer = buffer,
119 };122 };
120}123}
...@@ -244,6 +247,15 @@ pub fn noopFlush(w: *Writer) Error!void {...@@ -244,6 +247,15 @@ pub fn noopFlush(w: *Writer) Error!void {
244 _ = w;247 _ = w;
245}248}
246249
250test "fixed buffer flush" {
251 var buffer: [1]u8 = undefined;
252 var writer: std.io.Writer = .fixed(&buffer);
253
254 try writer.writeByte(10);
255 try writer.flush();
256 try testing.expectEqual(10, buffer[0]);
257}
258
247/// Calls `VTable.drain` but hides the last `preserve_length` bytes from the259/// Calls `VTable.drain` but hides the last `preserve_length` bytes from the
248/// implementation, keeping them buffered.260/// implementation, keeping them buffered.
249pub fn drainPreserve(w: *Writer, preserve_length: usize) Error!void {261pub fn drainPreserve(w: *Writer, preserve_length: usize) Error!void {
...@@ -381,6 +393,32 @@ pub fn writableVectorPosix(w: *Writer, buffer: []std.posix.iovec, limit: Limit)...@@ -381,6 +393,32 @@ pub fn writableVectorPosix(w: *Writer, buffer: []std.posix.iovec, limit: Limit)
381 return buffer[0..i];393 return buffer[0..i];
382}394}
383395
396pub fn writableVectorWsa(
397 w: *Writer,
398 buffer: []std.os.windows.ws2_32.WSABUF,
399 limit: Limit,
400) Error![]std.os.windows.ws2_32.WSABUF {
401 var it = try writableVectorIterator(w);
402 var i: usize = 0;
403 var remaining = limit;
404 while (it.next()) |full_buffer| {
405 if (!remaining.nonzero()) break;
406 if (buffer.len - i == 0) break;
407 const buf = remaining.slice(full_buffer);
408 if (buf.len == 0) continue;
409 if (std.math.cast(u32, buf.len)) |len| {
410 buffer[i] = .{ .buf = buf.ptr, .len = len };
411 i += 1;
412 remaining = remaining.subtract(len).?;
413 continue;
414 }
415 buffer[i] = .{ .buf = buf.ptr, .len = std.math.maxInt(u32) };
416 i += 1;
417 break;
418 }
419 return buffer[0..i];
420}
421
384pub fn ensureUnusedCapacity(w: *Writer, n: usize) Error!void {422pub fn ensureUnusedCapacity(w: *Writer, n: usize) Error!void {
385 _ = try writableSliceGreedy(w, n);423 _ = try writableSliceGreedy(w, n);
386}424}
...@@ -2150,7 +2188,7 @@ pub const Discarding = struct {...@@ -2150,7 +2188,7 @@ pub const Discarding = struct {
2150 pub fn drain(w: *Writer, data: []const []const u8, splat: usize) Error!usize {2188 pub fn drain(w: *Writer, data: []const []const u8, splat: usize) Error!usize {
2151 const d: *Discarding = @alignCast(@fieldParentPtr("writer", w));2189 const d: *Discarding = @alignCast(@fieldParentPtr("writer", w));
2152 const slice = data[0 .. data.len - 1];2190 const slice = data[0 .. data.len - 1];
2153 const pattern = data[slice.len..];2191 const pattern = data[slice.len];
2154 var written: usize = pattern.len * splat;2192 var written: usize = pattern.len * splat;
2155 for (slice) |bytes| written += bytes.len;2193 for (slice) |bytes| written += bytes.len;
2156 d.count += w.end + written;2194 d.count += w.end + written;
lib/std/Thread.zig+1-1
...@@ -58,7 +58,7 @@ pub fn sleep(nanoseconds: u64) void {...@@ -58,7 +58,7 @@ pub fn sleep(nanoseconds: u64) void {
58 const boot_services = std.os.uefi.system_table.boot_services.?;58 const boot_services = std.os.uefi.system_table.boot_services.?;
59 const us_from_ns = nanoseconds / std.time.ns_per_us;59 const us_from_ns = nanoseconds / std.time.ns_per_us;
60 const us = math.cast(usize, us_from_ns) orelse math.maxInt(usize);60 const us = math.cast(usize, us_from_ns) orelse math.maxInt(usize);
61 _ = boot_services.stall(us);61 boot_services.stall(us) catch unreachable;
62 return;62 return;
63 }63 }
6464
lib/std/Thread/Condition.zig+3-3
...@@ -130,7 +130,7 @@ const SingleThreadedImpl = struct {...@@ -130,7 +130,7 @@ const SingleThreadedImpl = struct {
130 unreachable; // deadlock detected130 unreachable; // deadlock detected
131 };131 };
132132
133 std.time.sleep(timeout_ns);133 std.Thread.sleep(timeout_ns);
134 return error.Timeout;134 return error.Timeout;
135 }135 }
136136
...@@ -348,7 +348,7 @@ test "wait and signal" {...@@ -348,7 +348,7 @@ test "wait and signal" {
348 }348 }
349349
350 while (true) {350 while (true) {
351 std.time.sleep(100 * std.time.ns_per_ms);351 std.Thread.sleep(100 * std.time.ns_per_ms);
352352
353 multi_wait.mutex.lock();353 multi_wait.mutex.lock();
354 defer multi_wait.mutex.unlock();354 defer multi_wait.mutex.unlock();
...@@ -405,7 +405,7 @@ test signal {...@@ -405,7 +405,7 @@ test signal {
405 }405 }
406406
407 while (true) {407 while (true) {
408 std.time.sleep(10 * std.time.ns_per_ms);408 std.Thread.sleep(10 * std.time.ns_per_ms);
409409
410 signal_test.mutex.lock();410 signal_test.mutex.lock();
411 defer signal_test.mutex.unlock();411 defer signal_test.mutex.unlock();
lib/std/Thread/Futex.zig+1-1
...@@ -116,7 +116,7 @@ const SingleThreadedImpl = struct {...@@ -116,7 +116,7 @@ const SingleThreadedImpl = struct {
116 unreachable; // deadlock detected116 unreachable; // deadlock detected
117 };117 };
118118
119 std.time.sleep(delay);119 std.Thread.sleep(delay);
120 return error.Timeout;120 return error.Timeout;
121 }121 }
122122
lib/std/Thread/ResetEvent.zig+1-1
...@@ -74,7 +74,7 @@ const SingleThreadedImpl = struct {...@@ -74,7 +74,7 @@ const SingleThreadedImpl = struct {
74 unreachable; // deadlock detected74 unreachable; // deadlock detected
75 };75 };
7676
77 std.time.sleep(timeout_ns);77 std.Thread.sleep(timeout_ns);
78 return error.Timeout;78 return error.Timeout;
79 }79 }
8080
lib/std/ascii.zig-3
...@@ -181,9 +181,6 @@ pub fn isAscii(c: u8) bool {...@@ -181,9 +181,6 @@ pub fn isAscii(c: u8) bool {
181 return c < 128;181 return c < 128;
182}182}
183183
184/// Deprecated: use `isAscii`
185pub const isASCII = isAscii;
186
187/// Uppercases the character and returns it as-is if already uppercase or not a letter.184/// Uppercases the character and returns it as-is if already uppercase or not a letter.
188pub fn toUpper(c: u8) u8 {185pub fn toUpper(c: u8) u8 {
189 const mask = @as(u8, @intFromBool(isLower(c))) << 5;186 const mask = @as(u8, @intFromBool(isLower(c))) << 5;
lib/std/atomic.zig-2
...@@ -10,8 +10,6 @@ pub fn Value(comptime T: type) type {...@@ -10,8 +10,6 @@ pub fn Value(comptime T: type) type {
10 return .{ .raw = value };10 return .{ .raw = value };
11 }11 }
1212
13 pub const fence = @compileError("@fence is deprecated, use other atomics to establish ordering");
14
15 pub inline fn load(self: *const Self, comptime order: AtomicOrder) T {13 pub inline fn load(self: *const Self, comptime order: AtomicOrder) T {
16 return @atomicLoad(T, &self.raw, order);14 return @atomicLoad(T, &self.raw, order);
17 }15 }
lib/std/builtin.zig-55
...@@ -156,9 +156,6 @@ pub const OptimizeMode = enum {...@@ -156,9 +156,6 @@ pub const OptimizeMode = enum {
156 ReleaseSmall,156 ReleaseSmall,
157};157};
158158
159/// Deprecated; use OptimizeMode.
160pub const Mode = OptimizeMode;
161
162/// The calling convention of a function defines how arguments and return values are passed, as well159/// The calling convention of a function defines how arguments and return values are passed, as well
163/// as any other requirements which callers and callees must respect, such as register preservation160/// as any other requirements which callers and callees must respect, such as register preservation
164/// and stack alignment.161/// and stack alignment.
...@@ -187,51 +184,6 @@ pub const CallingConvention = union(enum(u8)) {...@@ -187,51 +184,6 @@ pub const CallingConvention = union(enum(u8)) {
187 else => unreachable,184 else => unreachable,
188 };185 };
189186
190 /// Deprecated; use `.auto`.
191 pub const Unspecified: CallingConvention = .auto;
192 /// Deprecated; use `.c`.
193 pub const C: CallingConvention = .c;
194 /// Deprecated; use `.naked`.
195 pub const Naked: CallingConvention = .naked;
196 /// Deprecated; use `.@"inline"`.
197 pub const Inline: CallingConvention = .@"inline";
198 /// Deprecated; use `.x86_64_interrupt`, `.x86_interrupt`, or `.avr_interrupt`.
199 pub const Interrupt: CallingConvention = switch (builtin.target.cpu.arch) {
200 .x86_64 => .{ .x86_64_interrupt = .{} },
201 .x86 => .{ .x86_interrupt = .{} },
202 .avr => .avr_interrupt,
203 else => unreachable,
204 };
205 /// Deprecated; use `.avr_signal`.
206 pub const Signal: CallingConvention = .avr_signal;
207 /// Deprecated; use `.x86_stdcall`.
208 pub const Stdcall: CallingConvention = .{ .x86_stdcall = .{} };
209 /// Deprecated; use `.x86_fastcall`.
210 pub const Fastcall: CallingConvention = .{ .x86_fastcall = .{} };
211 /// Deprecated; use `.x86_64_vectorcall`, `.x86_vectorcall`, or `aarch64_vfabi`.
212 pub const Vectorcall: CallingConvention = switch (builtin.target.cpu.arch) {
213 .x86_64 => .{ .x86_64_vectorcall = .{} },
214 .x86 => .{ .x86_vectorcall = .{} },
215 .aarch64, .aarch64_be => .{ .aarch64_vfabi = .{} },
216 else => unreachable,
217 };
218 /// Deprecated; use `.x86_thiscall`.
219 pub const Thiscall: CallingConvention = .{ .x86_thiscall = .{} };
220 /// Deprecated; use `.arm_aapcs`.
221 pub const AAPCS: CallingConvention = .{ .arm_aapcs = .{} };
222 /// Deprecated; use `.arm_aapcs_vfp`.
223 pub const AAPCSVFP: CallingConvention = .{ .arm_aapcs_vfp = .{} };
224 /// Deprecated; use `.x86_64_sysv`.
225 pub const SysV: CallingConvention = .{ .x86_64_sysv = .{} };
226 /// Deprecated; use `.x86_64_win`.
227 pub const Win64: CallingConvention = .{ .x86_64_win = .{} };
228 /// Deprecated; use `.kernel`.
229 pub const Kernel: CallingConvention = .kernel;
230 /// Deprecated; use `.spirv_fragment`.
231 pub const Fragment: CallingConvention = .spirv_fragment;
232 /// Deprecated; use `.spirv_vertex`.
233 pub const Vertex: CallingConvention = .spirv_vertex;
234
235 /// The default Zig calling convention when neither `export` nor `inline` is specified.187 /// The default Zig calling convention when neither `export` nor `inline` is specified.
236 /// This calling convention makes no guarantees about stack alignment, registers, etc.188 /// This calling convention makes no guarantees about stack alignment, registers, etc.
237 /// It can only be used within this Zig compilation unit.189 /// It can only be used within this Zig compilation unit.
...@@ -1119,10 +1071,6 @@ pub const TestFn = struct {...@@ -1119,10 +1071,6 @@ pub const TestFn = struct {
1119 func: *const fn () anyerror!void,1071 func: *const fn () anyerror!void,
1120};1072};
11211073
1122/// Deprecated, use the `Panic` namespace instead.
1123/// To be deleted after 0.14.0 is released.
1124pub const PanicFn = fn ([]const u8, ?*StackTrace, ?usize) noreturn;
1125
1126/// This namespace is used by the Zig compiler to emit various kinds of safety1074/// This namespace is used by the Zig compiler to emit various kinds of safety
1127/// panics. These can be overridden by making a public `panic` namespace in the1075/// panics. These can be overridden by making a public `panic` namespace in the
1128/// root source file.1076/// root source file.
...@@ -1138,9 +1086,6 @@ pub const panic: type = p: {...@@ -1138,9 +1086,6 @@ pub const panic: type = p: {
1138 }1086 }
1139 break :p root.panic;1087 break :p root.panic;
1140 }1088 }
1141 if (@hasDecl(root, "Panic")) {
1142 break :p root.Panic; // Deprecated; use `panic` instead.
1143 }
1144 break :p switch (builtin.zig_backend) {1089 break :p switch (builtin.zig_backend) {
1145 .stage2_powerpc,1090 .stage2_powerpc,
1146 .stage2_riscv64,1091 .stage2_riscv64,
lib/std/c.zig+40-2
...@@ -4110,7 +4110,7 @@ pub const msghdr_const = switch (native_os) {...@@ -4110,7 +4110,7 @@ pub const msghdr_const = switch (native_os) {
4110 /// scatter/gather array4110 /// scatter/gather array
4111 iov: [*]const iovec_const,4111 iov: [*]const iovec_const,
4112 /// # elements in iov4112 /// # elements in iov
4113 iovlen: i32,4113 iovlen: u32,
4114 /// ancillary data4114 /// ancillary data
4115 control: ?*const anyopaque,4115 control: ?*const anyopaque,
4116 /// ancillary data buffer len4116 /// ancillary data buffer len
...@@ -4122,7 +4122,7 @@ pub const msghdr_const = switch (native_os) {...@@ -4122,7 +4122,7 @@ pub const msghdr_const = switch (native_os) {
4122 name: ?*const anyopaque,4122 name: ?*const anyopaque,
4123 namelen: socklen_t,4123 namelen: socklen_t,
4124 iov: [*]const iovec,4124 iov: [*]const iovec,
4125 iovlen: c_int,4125 iovlen: c_uint,
4126 control: ?*const anyopaque,4126 control: ?*const anyopaque,
4127 controllen: socklen_t,4127 controllen: socklen_t,
4128 flags: c_int,4128 flags: c_int,
...@@ -5625,6 +5625,43 @@ pub const MSG = switch (native_os) {...@@ -5625,6 +5625,43 @@ pub const MSG = switch (native_os) {
5625 pub const NOSIGNAL = 0x80;5625 pub const NOSIGNAL = 0x80;
5626 pub const EOR = 0x100;5626 pub const EOR = 0x100;
5627 },5627 },
5628 .freebsd => struct {
5629 pub const OOB = 0x00000001;
5630 pub const PEEK = 0x00000002;
5631 pub const DONTROUTE = 0x00000004;
5632 pub const EOR = 0x00000008;
5633 pub const TRUNC = 0x00000010;
5634 pub const CTRUNC = 0x00000020;
5635 pub const WAITALL = 0x00000040;
5636 pub const DONTWAIT = 0x00000080;
5637 pub const EOF = 0x00000100;
5638 pub const NOTIFICATION = 0x00002000;
5639 pub const NBIO = 0x00004000;
5640 pub const COMPAT = 0x00008000;
5641 pub const SOCALLBCK = 0x00010000;
5642 pub const NOSIGNAL = 0x00020000;
5643 pub const CMSG_CLOEXEC = 0x00040000;
5644 pub const WAITFORONE = 0x00080000;
5645 pub const MORETOCOME = 0x00100000;
5646 pub const TLSAPPDATA = 0x00200000;
5647 },
5648 .netbsd => struct {
5649 pub const OOB = 0x0001;
5650 pub const PEEK = 0x0002;
5651 pub const DONTROUTE = 0x0004;
5652 pub const EOR = 0x0008;
5653 pub const TRUNC = 0x0010;
5654 pub const CTRUNC = 0x0020;
5655 pub const WAITALL = 0x0040;
5656 pub const DONTWAIT = 0x0080;
5657 pub const BCAST = 0x0100;
5658 pub const MCAST = 0x0200;
5659 pub const NOSIGNAL = 0x0400;
5660 pub const CMSG_CLOEXEC = 0x0800;
5661 pub const NBIO = 0x1000;
5662 pub const WAITFORONE = 0x2000;
5663 pub const NOTIFICATION = 0x4000;
5664 },
5628 else => void,5665 else => void,
5629};5666};
5630pub const SOCK = switch (native_os) {5667pub const SOCK = switch (native_os) {
...@@ -10808,6 +10845,7 @@ pub extern "c" fn if_nametoindex([*:0]const u8) c_int;...@@ -10808,6 +10845,7 @@ pub extern "c" fn if_nametoindex([*:0]const u8) c_int;
1080810845
10809pub extern "c" fn getpid() pid_t;10846pub extern "c" fn getpid() pid_t;
10810pub extern "c" fn getppid() pid_t;10847pub extern "c" fn getppid() pid_t;
10848pub extern "c" fn setsid() pid_t;
1081110849
10812/// These are implementation defined but share identical values in at least musl and glibc:10850/// These are implementation defined but share identical values in at least musl and glibc:
10813/// - https://git.musl-libc.org/cgit/musl/tree/include/locale.h?id=ab31e9d6a0fa7c5c408856c89df2dfb12c344039#n1810851/// - https://git.musl-libc.org/cgit/musl/tree/include/locale.h?id=ab31e9d6a0fa7c5c408856c89df2dfb12c344039#n18
lib/std/crypto.zig+1-19
...@@ -103,7 +103,6 @@ pub const dh = struct {...@@ -103,7 +103,6 @@ pub const dh = struct {
103pub const kem = struct {103pub const kem = struct {
104 pub const kyber_d00 = @import("crypto/ml_kem.zig").d00;104 pub const kyber_d00 = @import("crypto/ml_kem.zig").d00;
105 pub const ml_kem = @import("crypto/ml_kem.zig").nist;105 pub const ml_kem = @import("crypto/ml_kem.zig").nist;
106 pub const ml_kem_01 = @compileError("deprecated: final version of the specification has been published, use ml_kem instead");
107};106};
108107
109/// Elliptic-curve arithmetic.108/// Elliptic-curve arithmetic.
...@@ -387,7 +386,7 @@ test "issue #4532: no index out of bounds" {...@@ -387,7 +386,7 @@ test "issue #4532: no index out of bounds" {
387386
388/// Sets a slice to zeroes.387/// Sets a slice to zeroes.
389/// Prevents the store from being optimized out.388/// Prevents the store from being optimized out.
390pub inline fn secureZero(comptime T: type, s: []volatile T) void {389pub fn secureZero(comptime T: type, s: []volatile T) void {
391 @memset(s, 0);390 @memset(s, 0);
392}391}
393392
...@@ -400,20 +399,3 @@ test secureZero {...@@ -400,20 +399,3 @@ test secureZero {
400399
401 try std.testing.expectEqualSlices(u8, &a, &b);400 try std.testing.expectEqualSlices(u8, &a, &b);
402}401}
403
404/// Deprecated in favor of `std.crypto`. To be removed after Zig 0.14.0 is released.
405///
406/// As a reminder, never use "utils" in a namespace (in any programming language).
407/// https://ziglang.org/documentation/0.13.0/#Avoid-Redundancy-in-Names
408pub const utils = struct {
409 /// Deprecated in favor of `std.crypto.secureZero`.
410 pub const secureZero = std.crypto.secureZero;
411 /// Deprecated in favor of `std.crypto.timing_safe.eql`.
412 pub const timingSafeEql = timing_safe.eql;
413 /// Deprecated in favor of `std.crypto.timing_safe.compare`.
414 pub const timingSafeCompare = timing_safe.compare;
415 /// Deprecated in favor of `std.crypto.timing_safe.add`.
416 pub const timingSafeAdd = timing_safe.add;
417 /// Deprecated in favor of `std.crypto.timing_safe.sub`.
418 pub const timingSafeSub = timing_safe.sub;
419};
lib/std/crypto/25519/curve25519.zig+2-2
...@@ -15,12 +15,12 @@ pub const Curve25519 = struct {...@@ -15,12 +15,12 @@ pub const Curve25519 = struct {
15 x: Fe,15 x: Fe,
1616
17 /// Decode a Curve25519 point from its compressed (X) coordinates.17 /// Decode a Curve25519 point from its compressed (X) coordinates.
18 pub inline fn fromBytes(s: [32]u8) Curve25519 {18 pub fn fromBytes(s: [32]u8) Curve25519 {
19 return .{ .x = Fe.fromBytes(s) };19 return .{ .x = Fe.fromBytes(s) };
20 }20 }
2121
22 /// Encode a Curve25519 point.22 /// Encode a Curve25519 point.
23 pub inline fn toBytes(p: Curve25519) [32]u8 {23 pub fn toBytes(p: Curve25519) [32]u8 {
24 return p.x.toBytes();24 return p.x.toBytes();
25 }25 }
2626
lib/std/crypto/25519/edwards25519.zig+3-3
...@@ -138,7 +138,7 @@ pub const Edwards25519 = struct {...@@ -138,7 +138,7 @@ pub const Edwards25519 = struct {
138 }138 }
139139
140 /// Flip the sign of the X coordinate.140 /// Flip the sign of the X coordinate.
141 pub inline fn neg(p: Edwards25519) Edwards25519 {141 pub fn neg(p: Edwards25519) Edwards25519 {
142 return .{ .x = p.x.neg(), .y = p.y, .z = p.z, .t = p.t.neg() };142 return .{ .x = p.x.neg(), .y = p.y, .z = p.z, .t = p.t.neg() };
143 }143 }
144144
...@@ -190,14 +190,14 @@ pub const Edwards25519 = struct {...@@ -190,14 +190,14 @@ pub const Edwards25519 = struct {
190 return q;190 return q;
191 }191 }
192192
193 inline fn cMov(p: *Edwards25519, a: Edwards25519, c: u64) void {193 fn cMov(p: *Edwards25519, a: Edwards25519, c: u64) void {
194 p.x.cMov(a.x, c);194 p.x.cMov(a.x, c);
195 p.y.cMov(a.y, c);195 p.y.cMov(a.y, c);
196 p.z.cMov(a.z, c);196 p.z.cMov(a.z, c);
197 p.t.cMov(a.t, c);197 p.t.cMov(a.t, c);
198 }198 }
199199
200 inline fn pcSelect(comptime n: usize, pc: *const [n]Edwards25519, b: u8) Edwards25519 {200 fn pcSelect(comptime n: usize, pc: *const [n]Edwards25519, b: u8) Edwards25519 {
201 var t = Edwards25519.identityElement;201 var t = Edwards25519.identityElement;
202 comptime var i: u8 = 1;202 comptime var i: u8 = 1;
203 inline while (i < pc.len) : (i += 1) {203 inline while (i < pc.len) : (i += 1) {
lib/std/crypto/25519/field.zig+11-11
...@@ -56,7 +56,7 @@ pub const Fe = struct {...@@ -56,7 +56,7 @@ pub const Fe = struct {
56 pub const edwards25519sqrtam2 = Fe{ .limbs = .{ 1693982333959686, 608509411481997, 2235573344831311, 947681270984193, 266558006233600 } };56 pub const edwards25519sqrtam2 = Fe{ .limbs = .{ 1693982333959686, 608509411481997, 2235573344831311, 947681270984193, 266558006233600 } };
5757
58 /// Return true if the field element is zero58 /// Return true if the field element is zero
59 pub inline fn isZero(fe: Fe) bool {59 pub fn isZero(fe: Fe) bool {
60 var reduced = fe;60 var reduced = fe;
61 reduced.reduce();61 reduced.reduce();
62 const limbs = reduced.limbs;62 const limbs = reduced.limbs;
...@@ -64,7 +64,7 @@ pub const Fe = struct {...@@ -64,7 +64,7 @@ pub const Fe = struct {
64 }64 }
6565
66 /// Return true if both field elements are equivalent66 /// Return true if both field elements are equivalent
67 pub inline fn equivalent(a: Fe, b: Fe) bool {67 pub fn equivalent(a: Fe, b: Fe) bool {
68 return a.sub(b).isZero();68 return a.sub(b).isZero();
69 }69 }
7070
...@@ -168,7 +168,7 @@ pub const Fe = struct {...@@ -168,7 +168,7 @@ pub const Fe = struct {
168 }168 }
169169
170 /// Add a field element170 /// Add a field element
171 pub inline fn add(a: Fe, b: Fe) Fe {171 pub fn add(a: Fe, b: Fe) Fe {
172 var fe: Fe = undefined;172 var fe: Fe = undefined;
173 comptime var i = 0;173 comptime var i = 0;
174 inline while (i < 5) : (i += 1) {174 inline while (i < 5) : (i += 1) {
...@@ -178,7 +178,7 @@ pub const Fe = struct {...@@ -178,7 +178,7 @@ pub const Fe = struct {
178 }178 }
179179
180 /// Subtract a field element180 /// Subtract a field element
181 pub inline fn sub(a: Fe, b: Fe) Fe {181 pub fn sub(a: Fe, b: Fe) Fe {
182 var fe = b;182 var fe = b;
183 comptime var i = 0;183 comptime var i = 0;
184 inline while (i < 4) : (i += 1) {184 inline while (i < 4) : (i += 1) {
...@@ -197,17 +197,17 @@ pub const Fe = struct {...@@ -197,17 +197,17 @@ pub const Fe = struct {
197 }197 }
198198
199 /// Negate a field element199 /// Negate a field element
200 pub inline fn neg(a: Fe) Fe {200 pub fn neg(a: Fe) Fe {
201 return zero.sub(a);201 return zero.sub(a);
202 }202 }
203203
204 /// Return true if a field element is negative204 /// Return true if a field element is negative
205 pub inline fn isNegative(a: Fe) bool {205 pub fn isNegative(a: Fe) bool {
206 return (a.toBytes()[0] & 1) != 0;206 return (a.toBytes()[0] & 1) != 0;
207 }207 }
208208
209 /// Conditonally replace a field element with `a` if `c` is positive209 /// Conditonally replace a field element with `a` if `c` is positive
210 pub inline fn cMov(fe: *Fe, a: Fe, c: u64) void {210 pub fn cMov(fe: *Fe, a: Fe, c: u64) void {
211 const mask: u64 = 0 -% c;211 const mask: u64 = 0 -% c;
212 var x = fe.*;212 var x = fe.*;
213 comptime var i = 0;213 comptime var i = 0;
...@@ -248,7 +248,7 @@ pub const Fe = struct {...@@ -248,7 +248,7 @@ pub const Fe = struct {
248 }248 }
249 }249 }
250250
251 inline fn _carry128(r: *[5]u128) Fe {251 fn _carry128(r: *[5]u128) Fe {
252 var rs: [5]u64 = undefined;252 var rs: [5]u64 = undefined;
253 comptime var i = 0;253 comptime var i = 0;
254 inline while (i < 4) : (i += 1) {254 inline while (i < 4) : (i += 1) {
...@@ -321,17 +321,17 @@ pub const Fe = struct {...@@ -321,17 +321,17 @@ pub const Fe = struct {
321 }321 }
322322
323 /// Square a field element323 /// Square a field element
324 pub inline fn sq(a: Fe) Fe {324 pub fn sq(a: Fe) Fe {
325 return _sq(a, false);325 return _sq(a, false);
326 }326 }
327327
328 /// Square and double a field element328 /// Square and double a field element
329 pub inline fn sq2(a: Fe) Fe {329 pub fn sq2(a: Fe) Fe {
330 return _sq(a, true);330 return _sq(a, true);
331 }331 }
332332
333 /// Multiply a field element with a small (32-bit) integer333 /// Multiply a field element with a small (32-bit) integer
334 pub inline fn mul32(a: Fe, comptime n: u32) Fe {334 pub fn mul32(a: Fe, comptime n: u32) Fe {
335 const sn = @as(u128, @intCast(n));335 const sn = @as(u128, @intCast(n));
336 var fe: Fe = undefined;336 var fe: Fe = undefined;
337 var x: u128 = 0;337 var x: u128 = 0;
lib/std/crypto/25519/ristretto255.zig+5-5
...@@ -42,7 +42,7 @@ pub const Ristretto255 = struct {...@@ -42,7 +42,7 @@ pub const Ristretto255 = struct {
42 }42 }
4343
44 /// Reject the neutral element.44 /// Reject the neutral element.
45 pub inline fn rejectIdentity(p: Ristretto255) IdentityElementError!void {45 pub fn rejectIdentity(p: Ristretto255) IdentityElementError!void {
46 return p.p.rejectIdentity();46 return p.p.rejectIdentity();
47 }47 }
4848
...@@ -141,24 +141,24 @@ pub const Ristretto255 = struct {...@@ -141,24 +141,24 @@ pub const Ristretto255 = struct {
141 }141 }
142142
143 /// Double a Ristretto255 element.143 /// Double a Ristretto255 element.
144 pub inline fn dbl(p: Ristretto255) Ristretto255 {144 pub fn dbl(p: Ristretto255) Ristretto255 {
145 return .{ .p = p.p.dbl() };145 return .{ .p = p.p.dbl() };
146 }146 }
147147
148 /// Add two Ristretto255 elements.148 /// Add two Ristretto255 elements.
149 pub inline fn add(p: Ristretto255, q: Ristretto255) Ristretto255 {149 pub fn add(p: Ristretto255, q: Ristretto255) Ristretto255 {
150 return .{ .p = p.p.add(q.p) };150 return .{ .p = p.p.add(q.p) };
151 }151 }
152152
153 /// Subtract two Ristretto255 elements.153 /// Subtract two Ristretto255 elements.
154 pub inline fn sub(p: Ristretto255, q: Ristretto255) Ristretto255 {154 pub fn sub(p: Ristretto255, q: Ristretto255) Ristretto255 {
155 return .{ .p = p.p.sub(q.p) };155 return .{ .p = p.p.sub(q.p) };
156 }156 }
157157
158 /// Multiply a Ristretto255 element with a scalar.158 /// Multiply a Ristretto255 element with a scalar.
159 /// Return error.WeakPublicKey if the resulting element is159 /// Return error.WeakPublicKey if the resulting element is
160 /// the identity element.160 /// the identity element.
161 pub inline fn mul(p: Ristretto255, s: [encoded_length]u8) (IdentityElementError || WeakPublicKeyError)!Ristretto255 {161 pub fn mul(p: Ristretto255, s: [encoded_length]u8) (IdentityElementError || WeakPublicKeyError)!Ristretto255 {
162 return .{ .p = try p.p.mul(s) };162 return .{ .p = try p.p.mul(s) };
163 }163 }
164164
lib/std/crypto/25519/scalar.zig+2-2
...@@ -50,7 +50,7 @@ pub fn reduce64(s: [64]u8) CompressedScalar {...@@ -50,7 +50,7 @@ pub fn reduce64(s: [64]u8) CompressedScalar {
5050
51/// Perform the X25519 "clamping" operation.51/// Perform the X25519 "clamping" operation.
52/// The scalar is then guaranteed to be a multiple of the cofactor.52/// The scalar is then guaranteed to be a multiple of the cofactor.
53pub inline fn clamp(s: *CompressedScalar) void {53pub fn clamp(s: *CompressedScalar) void {
54 s[0] &= 248;54 s[0] &= 248;
55 s[31] = (s[31] & 127) | 64;55 s[31] = (s[31] & 127) | 64;
56}56}
...@@ -514,7 +514,7 @@ pub const Scalar = struct {...@@ -514,7 +514,7 @@ pub const Scalar = struct {
514 }514 }
515515
516 /// Square a scalar `n` times516 /// Square a scalar `n` times
517 inline fn sqn(x: Scalar, comptime n: comptime_int) Scalar {517 fn sqn(x: Scalar, comptime n: comptime_int) Scalar {
518 var i: usize = 0;518 var i: usize = 0;
519 var t = x;519 var t = x;
520 while (i < n) : (i += 1) {520 while (i < n) : (i += 1) {
lib/std/crypto/aegis.zig+2-2
...@@ -104,7 +104,7 @@ fn State128X(comptime degree: u7) type {...@@ -104,7 +104,7 @@ fn State128X(comptime degree: u7) type {
104 return state;104 return state;
105 }105 }
106106
107 inline fn update(state: *State, d1: AesBlockVec, d2: AesBlockVec) void {107 fn update(state: *State, d1: AesBlockVec, d2: AesBlockVec) void {
108 const blocks = &state.blocks;108 const blocks = &state.blocks;
109 const tmp = blocks[7];109 const tmp = blocks[7];
110 comptime var i: usize = 7;110 comptime var i: usize = 7;
...@@ -413,7 +413,7 @@ fn State256X(comptime degree: u7) type {...@@ -413,7 +413,7 @@ fn State256X(comptime degree: u7) type {
413 return state;413 return state;
414 }414 }
415415
416 inline fn update(state: *State, d: AesBlockVec) void {416 fn update(state: *State, d: AesBlockVec) void {
417 const blocks = &state.blocks;417 const blocks = &state.blocks;
418 const tmp = blocks[5].encrypt(blocks[0]);418 const tmp = blocks[5].encrypt(blocks[0]);
419 comptime var i: usize = 5;419 comptime var i: usize = 5;
lib/std/crypto/aes/aesni.zig+26-26
...@@ -17,24 +17,24 @@ pub const Block = struct {...@@ -17,24 +17,24 @@ pub const Block = struct {
17 repr: Repr,17 repr: Repr,
1818
19 /// Convert a byte sequence into an internal representation.19 /// Convert a byte sequence into an internal representation.
20 pub inline fn fromBytes(bytes: *const [16]u8) Block {20 pub fn fromBytes(bytes: *const [16]u8) Block {
21 const repr = mem.bytesToValue(Repr, bytes);21 const repr = mem.bytesToValue(Repr, bytes);
22 return Block{ .repr = repr };22 return Block{ .repr = repr };
23 }23 }
2424
25 /// Convert the internal representation of a block into a byte sequence.25 /// Convert the internal representation of a block into a byte sequence.
26 pub inline fn toBytes(block: Block) [16]u8 {26 pub fn toBytes(block: Block) [16]u8 {
27 return mem.toBytes(block.repr);27 return mem.toBytes(block.repr);
28 }28 }
2929
30 /// XOR the block with a byte sequence.30 /// XOR the block with a byte sequence.
31 pub inline fn xorBytes(block: Block, bytes: *const [16]u8) [16]u8 {31 pub fn xorBytes(block: Block, bytes: *const [16]u8) [16]u8 {
32 const x = block.repr ^ fromBytes(bytes).repr;32 const x = block.repr ^ fromBytes(bytes).repr;
33 return mem.toBytes(x);33 return mem.toBytes(x);
34 }34 }
3535
36 /// Encrypt a block with a round key.36 /// Encrypt a block with a round key.
37 pub inline fn encrypt(block: Block, round_key: Block) Block {37 pub fn encrypt(block: Block, round_key: Block) Block {
38 return Block{38 return Block{
39 .repr = asm (39 .repr = asm (
40 \\ vaesenc %[rk], %[in], %[out]40 \\ vaesenc %[rk], %[in], %[out]
...@@ -46,7 +46,7 @@ pub const Block = struct {...@@ -46,7 +46,7 @@ pub const Block = struct {
46 }46 }
4747
48 /// Encrypt a block with the last round key.48 /// Encrypt a block with the last round key.
49 pub inline fn encryptLast(block: Block, round_key: Block) Block {49 pub fn encryptLast(block: Block, round_key: Block) Block {
50 return Block{50 return Block{
51 .repr = asm (51 .repr = asm (
52 \\ vaesenclast %[rk], %[in], %[out]52 \\ vaesenclast %[rk], %[in], %[out]
...@@ -58,7 +58,7 @@ pub const Block = struct {...@@ -58,7 +58,7 @@ pub const Block = struct {
58 }58 }
5959
60 /// Decrypt a block with a round key.60 /// Decrypt a block with a round key.
61 pub inline fn decrypt(block: Block, inv_round_key: Block) Block {61 pub fn decrypt(block: Block, inv_round_key: Block) Block {
62 return Block{62 return Block{
63 .repr = asm (63 .repr = asm (
64 \\ vaesdec %[rk], %[in], %[out]64 \\ vaesdec %[rk], %[in], %[out]
...@@ -70,7 +70,7 @@ pub const Block = struct {...@@ -70,7 +70,7 @@ pub const Block = struct {
70 }70 }
7171
72 /// Decrypt a block with the last round key.72 /// Decrypt a block with the last round key.
73 pub inline fn decryptLast(block: Block, inv_round_key: Block) Block {73 pub fn decryptLast(block: Block, inv_round_key: Block) Block {
74 return Block{74 return Block{
75 .repr = asm (75 .repr = asm (
76 \\ vaesdeclast %[rk], %[in], %[out]76 \\ vaesdeclast %[rk], %[in], %[out]
...@@ -82,17 +82,17 @@ pub const Block = struct {...@@ -82,17 +82,17 @@ pub const Block = struct {
82 }82 }
8383
84 /// Apply the bitwise XOR operation to the content of two blocks.84 /// Apply the bitwise XOR operation to the content of two blocks.
85 pub inline fn xorBlocks(block1: Block, block2: Block) Block {85 pub fn xorBlocks(block1: Block, block2: Block) Block {
86 return Block{ .repr = block1.repr ^ block2.repr };86 return Block{ .repr = block1.repr ^ block2.repr };
87 }87 }
8888
89 /// Apply the bitwise AND operation to the content of two blocks.89 /// Apply the bitwise AND operation to the content of two blocks.
90 pub inline fn andBlocks(block1: Block, block2: Block) Block {90 pub fn andBlocks(block1: Block, block2: Block) Block {
91 return Block{ .repr = block1.repr & block2.repr };91 return Block{ .repr = block1.repr & block2.repr };
92 }92 }
9393
94 /// Apply the bitwise OR operation to the content of two blocks.94 /// Apply the bitwise OR operation to the content of two blocks.
95 pub inline fn orBlocks(block1: Block, block2: Block) Block {95 pub fn orBlocks(block1: Block, block2: Block) Block {
96 return Block{ .repr = block1.repr | block2.repr };96 return Block{ .repr = block1.repr | block2.repr };
97 }97 }
9898
...@@ -112,7 +112,7 @@ pub const Block = struct {...@@ -112,7 +112,7 @@ pub const Block = struct {
112 };112 };
113113
114 /// Encrypt multiple blocks in parallel, each their own round key.114 /// Encrypt multiple blocks in parallel, each their own round key.
115 pub inline fn encryptParallel(comptime count: usize, blocks: [count]Block, round_keys: [count]Block) [count]Block {115 pub fn encryptParallel(comptime count: usize, blocks: [count]Block, round_keys: [count]Block) [count]Block {
116 comptime var i = 0;116 comptime var i = 0;
117 var out: [count]Block = undefined;117 var out: [count]Block = undefined;
118 inline while (i < count) : (i += 1) {118 inline while (i < count) : (i += 1) {
...@@ -122,7 +122,7 @@ pub const Block = struct {...@@ -122,7 +122,7 @@ pub const Block = struct {
122 }122 }
123123
124 /// Decrypt multiple blocks in parallel, each their own round key.124 /// Decrypt multiple blocks in parallel, each their own round key.
125 pub inline fn decryptParallel(comptime count: usize, blocks: [count]Block, round_keys: [count]Block) [count]Block {125 pub fn decryptParallel(comptime count: usize, blocks: [count]Block, round_keys: [count]Block) [count]Block {
126 comptime var i = 0;126 comptime var i = 0;
127 var out: [count]Block = undefined;127 var out: [count]Block = undefined;
128 inline while (i < count) : (i += 1) {128 inline while (i < count) : (i += 1) {
...@@ -132,7 +132,7 @@ pub const Block = struct {...@@ -132,7 +132,7 @@ pub const Block = struct {
132 }132 }
133133
134 /// Encrypt multiple blocks in parallel with the same round key.134 /// Encrypt multiple blocks in parallel with the same round key.
135 pub inline fn encryptWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {135 pub fn encryptWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {
136 comptime var i = 0;136 comptime var i = 0;
137 var out: [count]Block = undefined;137 var out: [count]Block = undefined;
138 inline while (i < count) : (i += 1) {138 inline while (i < count) : (i += 1) {
...@@ -142,7 +142,7 @@ pub const Block = struct {...@@ -142,7 +142,7 @@ pub const Block = struct {
142 }142 }
143143
144 /// Decrypt multiple blocks in parallel with the same round key.144 /// Decrypt multiple blocks in parallel with the same round key.
145 pub inline fn decryptWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {145 pub fn decryptWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {
146 comptime var i = 0;146 comptime var i = 0;
147 var out: [count]Block = undefined;147 var out: [count]Block = undefined;
148 inline while (i < count) : (i += 1) {148 inline while (i < count) : (i += 1) {
...@@ -152,7 +152,7 @@ pub const Block = struct {...@@ -152,7 +152,7 @@ pub const Block = struct {
152 }152 }
153153
154 /// Encrypt multiple blocks in parallel with the same last round key.154 /// Encrypt multiple blocks in parallel with the same last round key.
155 pub inline fn encryptLastWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {155 pub fn encryptLastWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {
156 comptime var i = 0;156 comptime var i = 0;
157 var out: [count]Block = undefined;157 var out: [count]Block = undefined;
158 inline while (i < count) : (i += 1) {158 inline while (i < count) : (i += 1) {
...@@ -162,7 +162,7 @@ pub const Block = struct {...@@ -162,7 +162,7 @@ pub const Block = struct {
162 }162 }
163163
164 /// Decrypt multiple blocks in parallel with the same last round key.164 /// Decrypt multiple blocks in parallel with the same last round key.
165 pub inline fn decryptLastWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {165 pub fn decryptLastWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {
166 comptime var i = 0;166 comptime var i = 0;
167 var out: [count]Block = undefined;167 var out: [count]Block = undefined;
168 inline while (i < count) : (i += 1) {168 inline while (i < count) : (i += 1) {
...@@ -200,7 +200,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -200,7 +200,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
200 pub const block_length: usize = blocks_count * 16;200 pub const block_length: usize = blocks_count * 16;
201201
202 /// Convert a byte sequence into an internal representation.202 /// Convert a byte sequence into an internal representation.
203 pub inline fn fromBytes(bytes: *const [blocks_count * 16]u8) Self {203 pub fn fromBytes(bytes: *const [blocks_count * 16]u8) Self {
204 var out: Self = undefined;204 var out: Self = undefined;
205 inline for (0..native_words) |i| {205 inline for (0..native_words) |i| {
206 out.repr[i] = mem.bytesToValue(Repr, bytes[i * native_word_size ..][0..native_word_size]);206 out.repr[i] = mem.bytesToValue(Repr, bytes[i * native_word_size ..][0..native_word_size]);
...@@ -209,7 +209,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -209,7 +209,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
209 }209 }
210210
211 /// Convert the internal representation of a block vector into a byte sequence.211 /// Convert the internal representation of a block vector into a byte sequence.
212 pub inline fn toBytes(block_vec: Self) [blocks_count * 16]u8 {212 pub fn toBytes(block_vec: Self) [blocks_count * 16]u8 {
213 var out: [blocks_count * 16]u8 = undefined;213 var out: [blocks_count * 16]u8 = undefined;
214 inline for (0..native_words) |i| {214 inline for (0..native_words) |i| {
215 out[i * native_word_size ..][0..native_word_size].* = mem.toBytes(block_vec.repr[i]);215 out[i * native_word_size ..][0..native_word_size].* = mem.toBytes(block_vec.repr[i]);
...@@ -218,7 +218,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -218,7 +218,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
218 }218 }
219219
220 /// XOR the block vector with a byte sequence.220 /// XOR the block vector with a byte sequence.
221 pub inline fn xorBytes(block_vec: Self, bytes: *const [blocks_count * 16]u8) [blocks_count * 16]u8 {221 pub fn xorBytes(block_vec: Self, bytes: *const [blocks_count * 16]u8) [blocks_count * 16]u8 {
222 var x: Self = undefined;222 var x: Self = undefined;
223 inline for (0..native_words) |i| {223 inline for (0..native_words) |i| {
224 x.repr[i] = block_vec.repr[i] ^ mem.bytesToValue(Repr, bytes[i * native_word_size ..][0..native_word_size]);224 x.repr[i] = block_vec.repr[i] ^ mem.bytesToValue(Repr, bytes[i * native_word_size ..][0..native_word_size]);
...@@ -227,7 +227,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -227,7 +227,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
227 }227 }
228228
229 /// Apply the forward AES operation to the block vector with a vector of round keys.229 /// Apply the forward AES operation to the block vector with a vector of round keys.
230 pub inline fn encrypt(block_vec: Self, round_key_vec: Self) Self {230 pub fn encrypt(block_vec: Self, round_key_vec: Self) Self {
231 var out: Self = undefined;231 var out: Self = undefined;
232 inline for (0..native_words) |i| {232 inline for (0..native_words) |i| {
233 out.repr[i] = asm (233 out.repr[i] = asm (
...@@ -241,7 +241,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -241,7 +241,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
241 }241 }
242242
243 /// Apply the forward AES operation to the block vector with a vector of last round keys.243 /// Apply the forward AES operation to the block vector with a vector of last round keys.
244 pub inline fn encryptLast(block_vec: Self, round_key_vec: Self) Self {244 pub fn encryptLast(block_vec: Self, round_key_vec: Self) Self {
245 var out: Self = undefined;245 var out: Self = undefined;
246 inline for (0..native_words) |i| {246 inline for (0..native_words) |i| {
247 out.repr[i] = asm (247 out.repr[i] = asm (
...@@ -255,7 +255,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -255,7 +255,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
255 }255 }
256256
257 /// Apply the inverse AES operation to the block vector with a vector of round keys.257 /// Apply the inverse AES operation to the block vector with a vector of round keys.
258 pub inline fn decrypt(block_vec: Self, inv_round_key_vec: Self) Self {258 pub fn decrypt(block_vec: Self, inv_round_key_vec: Self) Self {
259 var out: Self = undefined;259 var out: Self = undefined;
260 inline for (0..native_words) |i| {260 inline for (0..native_words) |i| {
261 out.repr[i] = asm (261 out.repr[i] = asm (
...@@ -269,7 +269,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -269,7 +269,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
269 }269 }
270270
271 /// Apply the inverse AES operation to the block vector with a vector of last round keys.271 /// Apply the inverse AES operation to the block vector with a vector of last round keys.
272 pub inline fn decryptLast(block_vec: Self, inv_round_key_vec: Self) Self {272 pub fn decryptLast(block_vec: Self, inv_round_key_vec: Self) Self {
273 var out: Self = undefined;273 var out: Self = undefined;
274 inline for (0..native_words) |i| {274 inline for (0..native_words) |i| {
275 out.repr[i] = asm (275 out.repr[i] = asm (
...@@ -283,7 +283,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -283,7 +283,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
283 }283 }
284284
285 /// Apply the bitwise XOR operation to the content of two block vectors.285 /// Apply the bitwise XOR operation to the content of two block vectors.
286 pub inline fn xorBlocks(block_vec1: Self, block_vec2: Self) Self {286 pub fn xorBlocks(block_vec1: Self, block_vec2: Self) Self {
287 var out: Self = undefined;287 var out: Self = undefined;
288 inline for (0..native_words) |i| {288 inline for (0..native_words) |i| {
289 out.repr[i] = block_vec1.repr[i] ^ block_vec2.repr[i];289 out.repr[i] = block_vec1.repr[i] ^ block_vec2.repr[i];
...@@ -292,7 +292,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -292,7 +292,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
292 }292 }
293293
294 /// Apply the bitwise AND operation to the content of two block vectors.294 /// Apply the bitwise AND operation to the content of two block vectors.
295 pub inline fn andBlocks(block_vec1: Self, block_vec2: Self) Self {295 pub fn andBlocks(block_vec1: Self, block_vec2: Self) Self {
296 var out: Self = undefined;296 var out: Self = undefined;
297 inline for (0..native_words) |i| {297 inline for (0..native_words) |i| {
298 out.repr[i] = block_vec1.repr[i] & block_vec2.repr[i];298 out.repr[i] = block_vec1.repr[i] & block_vec2.repr[i];
...@@ -301,7 +301,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -301,7 +301,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
301 }301 }
302302
303 /// Apply the bitwise OR operation to the content of two block vectors.303 /// Apply the bitwise OR operation to the content of two block vectors.
304 pub inline fn orBlocks(block_vec1: Self, block_vec2: Block) Self {304 pub fn orBlocks(block_vec1: Self, block_vec2: Block) Self {
305 var out: Self = undefined;305 var out: Self = undefined;
306 inline for (0..native_words) |i| {306 inline for (0..native_words) |i| {
307 out.repr[i] = block_vec1.repr[i] | block_vec2.repr[i];307 out.repr[i] = block_vec1.repr[i] | block_vec2.repr[i];
lib/std/crypto/aes/armcrypto.zig+26-26
...@@ -12,18 +12,18 @@ pub const Block = struct {...@@ -12,18 +12,18 @@ pub const Block = struct {
12 repr: Repr,12 repr: Repr,
1313
14 /// Convert a byte sequence into an internal representation.14 /// Convert a byte sequence into an internal representation.
15 pub inline fn fromBytes(bytes: *const [16]u8) Block {15 pub fn fromBytes(bytes: *const [16]u8) Block {
16 const repr = mem.bytesToValue(Repr, bytes);16 const repr = mem.bytesToValue(Repr, bytes);
17 return Block{ .repr = repr };17 return Block{ .repr = repr };
18 }18 }
1919
20 /// Convert the internal representation of a block into a byte sequence.20 /// Convert the internal representation of a block into a byte sequence.
21 pub inline fn toBytes(block: Block) [16]u8 {21 pub fn toBytes(block: Block) [16]u8 {
22 return mem.toBytes(block.repr);22 return mem.toBytes(block.repr);
23 }23 }
2424
25 /// XOR the block with a byte sequence.25 /// XOR the block with a byte sequence.
26 pub inline fn xorBytes(block: Block, bytes: *const [16]u8) [16]u8 {26 pub fn xorBytes(block: Block, bytes: *const [16]u8) [16]u8 {
27 const x = block.repr ^ fromBytes(bytes).repr;27 const x = block.repr ^ fromBytes(bytes).repr;
28 return mem.toBytes(x);28 return mem.toBytes(x);
29 }29 }
...@@ -31,7 +31,7 @@ pub const Block = struct {...@@ -31,7 +31,7 @@ pub const Block = struct {
31 const zero = @Vector(2, u64){ 0, 0 };31 const zero = @Vector(2, u64){ 0, 0 };
3232
33 /// Encrypt a block with a round key.33 /// Encrypt a block with a round key.
34 pub inline fn encrypt(block: Block, round_key: Block) Block {34 pub fn encrypt(block: Block, round_key: Block) Block {
35 return Block{35 return Block{
36 .repr = (asm (36 .repr = (asm (
37 \\ mov %[out].16b, %[in].16b37 \\ mov %[out].16b, %[in].16b
...@@ -45,7 +45,7 @@ pub const Block = struct {...@@ -45,7 +45,7 @@ pub const Block = struct {
45 }45 }
4646
47 /// Encrypt a block with the last round key.47 /// Encrypt a block with the last round key.
48 pub inline fn encryptLast(block: Block, round_key: Block) Block {48 pub fn encryptLast(block: Block, round_key: Block) Block {
49 return Block{49 return Block{
50 .repr = (asm (50 .repr = (asm (
51 \\ mov %[out].16b, %[in].16b51 \\ mov %[out].16b, %[in].16b
...@@ -58,7 +58,7 @@ pub const Block = struct {...@@ -58,7 +58,7 @@ pub const Block = struct {
58 }58 }
5959
60 /// Decrypt a block with a round key.60 /// Decrypt a block with a round key.
61 pub inline fn decrypt(block: Block, inv_round_key: Block) Block {61 pub fn decrypt(block: Block, inv_round_key: Block) Block {
62 return Block{62 return Block{
63 .repr = (asm (63 .repr = (asm (
64 \\ mov %[out].16b, %[in].16b64 \\ mov %[out].16b, %[in].16b
...@@ -72,7 +72,7 @@ pub const Block = struct {...@@ -72,7 +72,7 @@ pub const Block = struct {
72 }72 }
7373
74 /// Decrypt a block with the last round key.74 /// Decrypt a block with the last round key.
75 pub inline fn decryptLast(block: Block, inv_round_key: Block) Block {75 pub fn decryptLast(block: Block, inv_round_key: Block) Block {
76 return Block{76 return Block{
77 .repr = (asm (77 .repr = (asm (
78 \\ mov %[out].16b, %[in].16b78 \\ mov %[out].16b, %[in].16b
...@@ -85,17 +85,17 @@ pub const Block = struct {...@@ -85,17 +85,17 @@ pub const Block = struct {
85 }85 }
8686
87 /// Apply the bitwise XOR operation to the content of two blocks.87 /// Apply the bitwise XOR operation to the content of two blocks.
88 pub inline fn xorBlocks(block1: Block, block2: Block) Block {88 pub fn xorBlocks(block1: Block, block2: Block) Block {
89 return Block{ .repr = block1.repr ^ block2.repr };89 return Block{ .repr = block1.repr ^ block2.repr };
90 }90 }
9191
92 /// Apply the bitwise AND operation to the content of two blocks.92 /// Apply the bitwise AND operation to the content of two blocks.
93 pub inline fn andBlocks(block1: Block, block2: Block) Block {93 pub fn andBlocks(block1: Block, block2: Block) Block {
94 return Block{ .repr = block1.repr & block2.repr };94 return Block{ .repr = block1.repr & block2.repr };
95 }95 }
9696
97 /// Apply the bitwise OR operation to the content of two blocks.97 /// Apply the bitwise OR operation to the content of two blocks.
98 pub inline fn orBlocks(block1: Block, block2: Block) Block {98 pub fn orBlocks(block1: Block, block2: Block) Block {
99 return Block{ .repr = block1.repr | block2.repr };99 return Block{ .repr = block1.repr | block2.repr };
100 }100 }
101101
...@@ -105,7 +105,7 @@ pub const Block = struct {...@@ -105,7 +105,7 @@ pub const Block = struct {
105 pub const optimal_parallel_blocks = 6;105 pub const optimal_parallel_blocks = 6;
106106
107 /// Encrypt multiple blocks in parallel, each their own round key.107 /// Encrypt multiple blocks in parallel, each their own round key.
108 pub inline fn encryptParallel(comptime count: usize, blocks: [count]Block, round_keys: [count]Block) [count]Block {108 pub fn encryptParallel(comptime count: usize, blocks: [count]Block, round_keys: [count]Block) [count]Block {
109 comptime var i = 0;109 comptime var i = 0;
110 var out: [count]Block = undefined;110 var out: [count]Block = undefined;
111 inline while (i < count) : (i += 1) {111 inline while (i < count) : (i += 1) {
...@@ -115,7 +115,7 @@ pub const Block = struct {...@@ -115,7 +115,7 @@ pub const Block = struct {
115 }115 }
116116
117 /// Decrypt multiple blocks in parallel, each their own round key.117 /// Decrypt multiple blocks in parallel, each their own round key.
118 pub inline fn decryptParallel(comptime count: usize, blocks: [count]Block, round_keys: [count]Block) [count]Block {118 pub fn decryptParallel(comptime count: usize, blocks: [count]Block, round_keys: [count]Block) [count]Block {
119 comptime var i = 0;119 comptime var i = 0;
120 var out: [count]Block = undefined;120 var out: [count]Block = undefined;
121 inline while (i < count) : (i += 1) {121 inline while (i < count) : (i += 1) {
...@@ -125,7 +125,7 @@ pub const Block = struct {...@@ -125,7 +125,7 @@ pub const Block = struct {
125 }125 }
126126
127 /// Encrypt multiple blocks in parallel with the same round key.127 /// Encrypt multiple blocks in parallel with the same round key.
128 pub inline fn encryptWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {128 pub fn encryptWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {
129 comptime var i = 0;129 comptime var i = 0;
130 var out: [count]Block = undefined;130 var out: [count]Block = undefined;
131 inline while (i < count) : (i += 1) {131 inline while (i < count) : (i += 1) {
...@@ -135,7 +135,7 @@ pub const Block = struct {...@@ -135,7 +135,7 @@ pub const Block = struct {
135 }135 }
136136
137 /// Decrypt multiple blocks in parallel with the same round key.137 /// Decrypt multiple blocks in parallel with the same round key.
138 pub inline fn decryptWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {138 pub fn decryptWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {
139 comptime var i = 0;139 comptime var i = 0;
140 var out: [count]Block = undefined;140 var out: [count]Block = undefined;
141 inline while (i < count) : (i += 1) {141 inline while (i < count) : (i += 1) {
...@@ -145,7 +145,7 @@ pub const Block = struct {...@@ -145,7 +145,7 @@ pub const Block = struct {
145 }145 }
146146
147 /// Encrypt multiple blocks in parallel with the same last round key.147 /// Encrypt multiple blocks in parallel with the same last round key.
148 pub inline fn encryptLastWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {148 pub fn encryptLastWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {
149 comptime var i = 0;149 comptime var i = 0;
150 var out: [count]Block = undefined;150 var out: [count]Block = undefined;
151 inline while (i < count) : (i += 1) {151 inline while (i < count) : (i += 1) {
...@@ -155,7 +155,7 @@ pub const Block = struct {...@@ -155,7 +155,7 @@ pub const Block = struct {
155 }155 }
156156
157 /// Decrypt multiple blocks in parallel with the same last round key.157 /// Decrypt multiple blocks in parallel with the same last round key.
158 pub inline fn decryptLastWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {158 pub fn decryptLastWide(comptime count: usize, blocks: [count]Block, round_key: Block) [count]Block {
159 comptime var i = 0;159 comptime var i = 0;
160 var out: [count]Block = undefined;160 var out: [count]Block = undefined;
161 inline while (i < count) : (i += 1) {161 inline while (i < count) : (i += 1) {
...@@ -187,7 +187,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -187,7 +187,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
187 pub const block_length: usize = blocks_count * 16;187 pub const block_length: usize = blocks_count * 16;
188188
189 /// Convert a byte sequence into an internal representation.189 /// Convert a byte sequence into an internal representation.
190 pub inline fn fromBytes(bytes: *const [blocks_count * 16]u8) Self {190 pub fn fromBytes(bytes: *const [blocks_count * 16]u8) Self {
191 var out: Self = undefined;191 var out: Self = undefined;
192 inline for (0..native_words) |i| {192 inline for (0..native_words) |i| {
193 out.repr[i] = Block.fromBytes(bytes[i * native_word_size ..][0..native_word_size]);193 out.repr[i] = Block.fromBytes(bytes[i * native_word_size ..][0..native_word_size]);
...@@ -196,7 +196,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -196,7 +196,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
196 }196 }
197197
198 /// Convert the internal representation of a block vector into a byte sequence.198 /// Convert the internal representation of a block vector into a byte sequence.
199 pub inline fn toBytes(block_vec: Self) [blocks_count * 16]u8 {199 pub fn toBytes(block_vec: Self) [blocks_count * 16]u8 {
200 var out: [blocks_count * 16]u8 = undefined;200 var out: [blocks_count * 16]u8 = undefined;
201 inline for (0..native_words) |i| {201 inline for (0..native_words) |i| {
202 out[i * native_word_size ..][0..native_word_size].* = block_vec.repr[i].toBytes();202 out[i * native_word_size ..][0..native_word_size].* = block_vec.repr[i].toBytes();
...@@ -205,7 +205,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -205,7 +205,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
205 }205 }
206206
207 /// XOR the block vector with a byte sequence.207 /// XOR the block vector with a byte sequence.
208 pub inline fn xorBytes(block_vec: Self, bytes: *const [blocks_count * 16]u8) [32]u8 {208 pub fn xorBytes(block_vec: Self, bytes: *const [blocks_count * 16]u8) [32]u8 {
209 var out: Self = undefined;209 var out: Self = undefined;
210 inline for (0..native_words) |i| {210 inline for (0..native_words) |i| {
211 out.repr[i] = block_vec.repr[i].xorBytes(bytes[i * native_word_size ..][0..native_word_size]);211 out.repr[i] = block_vec.repr[i].xorBytes(bytes[i * native_word_size ..][0..native_word_size]);
...@@ -214,7 +214,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -214,7 +214,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
214 }214 }
215215
216 /// Apply the forward AES operation to the block vector with a vector of round keys.216 /// Apply the forward AES operation to the block vector with a vector of round keys.
217 pub inline fn encrypt(block_vec: Self, round_key_vec: Self) Self {217 pub fn encrypt(block_vec: Self, round_key_vec: Self) Self {
218 var out: Self = undefined;218 var out: Self = undefined;
219 inline for (0..native_words) |i| {219 inline for (0..native_words) |i| {
220 out.repr[i] = block_vec.repr[i].encrypt(round_key_vec.repr[i]);220 out.repr[i] = block_vec.repr[i].encrypt(round_key_vec.repr[i]);
...@@ -223,7 +223,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -223,7 +223,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
223 }223 }
224224
225 /// Apply the forward AES operation to the block vector with a vector of last round keys.225 /// Apply the forward AES operation to the block vector with a vector of last round keys.
226 pub inline fn encryptLast(block_vec: Self, round_key_vec: Self) Self {226 pub fn encryptLast(block_vec: Self, round_key_vec: Self) Self {
227 var out: Self = undefined;227 var out: Self = undefined;
228 inline for (0..native_words) |i| {228 inline for (0..native_words) |i| {
229 out.repr[i] = block_vec.repr[i].encryptLast(round_key_vec.repr[i]);229 out.repr[i] = block_vec.repr[i].encryptLast(round_key_vec.repr[i]);
...@@ -232,7 +232,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -232,7 +232,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
232 }232 }
233233
234 /// Apply the inverse AES operation to the block vector with a vector of round keys.234 /// Apply the inverse AES operation to the block vector with a vector of round keys.
235 pub inline fn decrypt(block_vec: Self, inv_round_key_vec: Self) Self {235 pub fn decrypt(block_vec: Self, inv_round_key_vec: Self) Self {
236 var out: Self = undefined;236 var out: Self = undefined;
237 inline for (0..native_words) |i| {237 inline for (0..native_words) |i| {
238 out.repr[i] = block_vec.repr[i].decrypt(inv_round_key_vec.repr[i]);238 out.repr[i] = block_vec.repr[i].decrypt(inv_round_key_vec.repr[i]);
...@@ -241,7 +241,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -241,7 +241,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
241 }241 }
242242
243 /// Apply the inverse AES operation to the block vector with a vector of last round keys.243 /// Apply the inverse AES operation to the block vector with a vector of last round keys.
244 pub inline fn decryptLast(block_vec: Self, inv_round_key_vec: Self) Self {244 pub fn decryptLast(block_vec: Self, inv_round_key_vec: Self) Self {
245 var out: Self = undefined;245 var out: Self = undefined;
246 inline for (0..native_words) |i| {246 inline for (0..native_words) |i| {
247 out.repr[i] = block_vec.repr[i].decryptLast(inv_round_key_vec.repr[i]);247 out.repr[i] = block_vec.repr[i].decryptLast(inv_round_key_vec.repr[i]);
...@@ -250,7 +250,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -250,7 +250,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
250 }250 }
251251
252 /// Apply the bitwise XOR operation to the content of two block vectors.252 /// Apply the bitwise XOR operation to the content of two block vectors.
253 pub inline fn xorBlocks(block_vec1: Self, block_vec2: Self) Self {253 pub fn xorBlocks(block_vec1: Self, block_vec2: Self) Self {
254 var out: Self = undefined;254 var out: Self = undefined;
255 inline for (0..native_words) |i| {255 inline for (0..native_words) |i| {
256 out.repr[i] = block_vec1.repr[i].xorBlocks(block_vec2.repr[i]);256 out.repr[i] = block_vec1.repr[i].xorBlocks(block_vec2.repr[i]);
...@@ -259,7 +259,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -259,7 +259,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
259 }259 }
260260
261 /// Apply the bitwise AND operation to the content of two block vectors.261 /// Apply the bitwise AND operation to the content of two block vectors.
262 pub inline fn andBlocks(block_vec1: Self, block_vec2: Self) Self {262 pub fn andBlocks(block_vec1: Self, block_vec2: Self) Self {
263 var out: Self = undefined;263 var out: Self = undefined;
264 inline for (0..native_words) |i| {264 inline for (0..native_words) |i| {
265 out.repr[i] = block_vec1.repr[i].andBlocks(block_vec2.repr[i]);265 out.repr[i] = block_vec1.repr[i].andBlocks(block_vec2.repr[i]);
...@@ -268,7 +268,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -268,7 +268,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
268 }268 }
269269
270 /// Apply the bitwise OR operation to the content of two block vectors.270 /// Apply the bitwise OR operation to the content of two block vectors.
271 pub inline fn orBlocks(block_vec1: Self, block_vec2: Block) Self {271 pub fn orBlocks(block_vec1: Self, block_vec2: Block) Self {
272 var out: Self = undefined;272 var out: Self = undefined;
273 inline for (0..native_words) |i| {273 inline for (0..native_words) |i| {
274 out.repr[i] = block_vec1.repr[i].orBlocks(block_vec2.repr[i]);274 out.repr[i] = block_vec1.repr[i].orBlocks(block_vec2.repr[i]);
lib/std/crypto/aes/soft.zig+22-22
...@@ -14,7 +14,7 @@ pub const Block = struct {...@@ -14,7 +14,7 @@ pub const Block = struct {
14 repr: Repr align(16),14 repr: Repr align(16),
1515
16 /// Convert a byte sequence into an internal representation.16 /// Convert a byte sequence into an internal representation.
17 pub inline fn fromBytes(bytes: *const [16]u8) Block {17 pub fn fromBytes(bytes: *const [16]u8) Block {
18 const s0 = mem.readInt(u32, bytes[0..4], .little);18 const s0 = mem.readInt(u32, bytes[0..4], .little);
19 const s1 = mem.readInt(u32, bytes[4..8], .little);19 const s1 = mem.readInt(u32, bytes[4..8], .little);
20 const s2 = mem.readInt(u32, bytes[8..12], .little);20 const s2 = mem.readInt(u32, bytes[8..12], .little);
...@@ -23,7 +23,7 @@ pub const Block = struct {...@@ -23,7 +23,7 @@ pub const Block = struct {
23 }23 }
2424
25 /// Convert the internal representation of a block into a byte sequence.25 /// Convert the internal representation of a block into a byte sequence.
26 pub inline fn toBytes(block: Block) [16]u8 {26 pub fn toBytes(block: Block) [16]u8 {
27 var bytes: [16]u8 = undefined;27 var bytes: [16]u8 = undefined;
28 mem.writeInt(u32, bytes[0..4], block.repr[0], .little);28 mem.writeInt(u32, bytes[0..4], block.repr[0], .little);
29 mem.writeInt(u32, bytes[4..8], block.repr[1], .little);29 mem.writeInt(u32, bytes[4..8], block.repr[1], .little);
...@@ -33,7 +33,7 @@ pub const Block = struct {...@@ -33,7 +33,7 @@ pub const Block = struct {
33 }33 }
3434
35 /// XOR the block with a byte sequence.35 /// XOR the block with a byte sequence.
36 pub inline fn xorBytes(block: Block, bytes: *const [16]u8) [16]u8 {36 pub fn xorBytes(block: Block, bytes: *const [16]u8) [16]u8 {
37 const block_bytes = block.toBytes();37 const block_bytes = block.toBytes();
38 var x: [16]u8 = undefined;38 var x: [16]u8 = undefined;
39 comptime var i: usize = 0;39 comptime var i: usize = 0;
...@@ -44,7 +44,7 @@ pub const Block = struct {...@@ -44,7 +44,7 @@ pub const Block = struct {
44 }44 }
4545
46 /// Encrypt a block with a round key.46 /// Encrypt a block with a round key.
47 pub inline fn encrypt(block: Block, round_key: Block) Block {47 pub fn encrypt(block: Block, round_key: Block) Block {
48 const s0 = block.repr[0];48 const s0 = block.repr[0];
49 const s1 = block.repr[1];49 const s1 = block.repr[1];
50 const s2 = block.repr[2];50 const s2 = block.repr[2];
...@@ -69,7 +69,7 @@ pub const Block = struct {...@@ -69,7 +69,7 @@ pub const Block = struct {
69 }69 }
7070
71 /// Encrypt a block with a round key *WITHOUT ANY PROTECTION AGAINST SIDE CHANNELS*71 /// Encrypt a block with a round key *WITHOUT ANY PROTECTION AGAINST SIDE CHANNELS*
72 pub inline fn encryptUnprotected(block: Block, round_key: Block) Block {72 pub fn encryptUnprotected(block: Block, round_key: Block) Block {
73 const s0 = block.repr[0];73 const s0 = block.repr[0];
74 const s1 = block.repr[1];74 const s1 = block.repr[1];
75 const s2 = block.repr[2];75 const s2 = block.repr[2];
...@@ -114,7 +114,7 @@ pub const Block = struct {...@@ -114,7 +114,7 @@ pub const Block = struct {
114 }114 }
115115
116 /// Encrypt a block with the last round key.116 /// Encrypt a block with the last round key.
117 pub inline fn encryptLast(block: Block, round_key: Block) Block {117 pub fn encryptLast(block: Block, round_key: Block) Block {
118 const s0 = block.repr[0];118 const s0 = block.repr[0];
119 const s1 = block.repr[1];119 const s1 = block.repr[1];
120 const s2 = block.repr[2];120 const s2 = block.repr[2];
...@@ -140,7 +140,7 @@ pub const Block = struct {...@@ -140,7 +140,7 @@ pub const Block = struct {
140 }140 }
141141
142 /// Decrypt a block with a round key.142 /// Decrypt a block with a round key.
143 pub inline fn decrypt(block: Block, round_key: Block) Block {143 pub fn decrypt(block: Block, round_key: Block) Block {
144 const s0 = block.repr[0];144 const s0 = block.repr[0];
145 const s1 = block.repr[1];145 const s1 = block.repr[1];
146 const s2 = block.repr[2];146 const s2 = block.repr[2];
...@@ -165,7 +165,7 @@ pub const Block = struct {...@@ -165,7 +165,7 @@ pub const Block = struct {
165 }165 }
166166
167 /// Decrypt a block with a round key *WITHOUT ANY PROTECTION AGAINST SIDE CHANNELS*167 /// Decrypt a block with a round key *WITHOUT ANY PROTECTION AGAINST SIDE CHANNELS*
168 pub inline fn decryptUnprotected(block: Block, round_key: Block) Block {168 pub fn decryptUnprotected(block: Block, round_key: Block) Block {
169 const s0 = block.repr[0];169 const s0 = block.repr[0];
170 const s1 = block.repr[1];170 const s1 = block.repr[1];
171 const s2 = block.repr[2];171 const s2 = block.repr[2];
...@@ -210,7 +210,7 @@ pub const Block = struct {...@@ -210,7 +210,7 @@ pub const Block = struct {
210 }210 }
211211
212 /// Decrypt a block with the last round key.212 /// Decrypt a block with the last round key.
213 pub inline fn decryptLast(block: Block, round_key: Block) Block {213 pub fn decryptLast(block: Block, round_key: Block) Block {
214 const s0 = block.repr[0];214 const s0 = block.repr[0];
215 const s1 = block.repr[1];215 const s1 = block.repr[1];
216 const s2 = block.repr[2];216 const s2 = block.repr[2];
...@@ -236,7 +236,7 @@ pub const Block = struct {...@@ -236,7 +236,7 @@ pub const Block = struct {
236 }236 }
237237
238 /// Apply the bitwise XOR operation to the content of two blocks.238 /// Apply the bitwise XOR operation to the content of two blocks.
239 pub inline fn xorBlocks(block1: Block, block2: Block) Block {239 pub fn xorBlocks(block1: Block, block2: Block) Block {
240 var x: Repr = undefined;240 var x: Repr = undefined;
241 comptime var i = 0;241 comptime var i = 0;
242 inline while (i < 4) : (i += 1) {242 inline while (i < 4) : (i += 1) {
...@@ -246,7 +246,7 @@ pub const Block = struct {...@@ -246,7 +246,7 @@ pub const Block = struct {
246 }246 }
247247
248 /// Apply the bitwise AND operation to the content of two blocks.248 /// Apply the bitwise AND operation to the content of two blocks.
249 pub inline fn andBlocks(block1: Block, block2: Block) Block {249 pub fn andBlocks(block1: Block, block2: Block) Block {
250 var x: Repr = undefined;250 var x: Repr = undefined;
251 comptime var i = 0;251 comptime var i = 0;
252 inline while (i < 4) : (i += 1) {252 inline while (i < 4) : (i += 1) {
...@@ -256,7 +256,7 @@ pub const Block = struct {...@@ -256,7 +256,7 @@ pub const Block = struct {
256 }256 }
257257
258 /// Apply the bitwise OR operation to the content of two blocks.258 /// Apply the bitwise OR operation to the content of two blocks.
259 pub inline fn orBlocks(block1: Block, block2: Block) Block {259 pub fn orBlocks(block1: Block, block2: Block) Block {
260 var x: Repr = undefined;260 var x: Repr = undefined;
261 comptime var i = 0;261 comptime var i = 0;
262 inline while (i < 4) : (i += 1) {262 inline while (i < 4) : (i += 1) {
...@@ -353,7 +353,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -353,7 +353,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
353 pub const block_length: usize = blocks_count * 16;353 pub const block_length: usize = blocks_count * 16;
354354
355 /// Convert a byte sequence into an internal representation.355 /// Convert a byte sequence into an internal representation.
356 pub inline fn fromBytes(bytes: *const [blocks_count * 16]u8) Self {356 pub fn fromBytes(bytes: *const [blocks_count * 16]u8) Self {
357 var out: Self = undefined;357 var out: Self = undefined;
358 for (0..native_words) |i| {358 for (0..native_words) |i| {
359 out.repr[i] = Block.fromBytes(bytes[i * native_word_size ..][0..native_word_size]);359 out.repr[i] = Block.fromBytes(bytes[i * native_word_size ..][0..native_word_size]);
...@@ -362,7 +362,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -362,7 +362,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
362 }362 }
363363
364 /// Convert the internal representation of a block vector into a byte sequence.364 /// Convert the internal representation of a block vector into a byte sequence.
365 pub inline fn toBytes(block_vec: Self) [blocks_count * 16]u8 {365 pub fn toBytes(block_vec: Self) [blocks_count * 16]u8 {
366 var out: [blocks_count * 16]u8 = undefined;366 var out: [blocks_count * 16]u8 = undefined;
367 for (0..native_words) |i| {367 for (0..native_words) |i| {
368 out[i * native_word_size ..][0..native_word_size].* = block_vec.repr[i].toBytes();368 out[i * native_word_size ..][0..native_word_size].* = block_vec.repr[i].toBytes();
...@@ -371,7 +371,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -371,7 +371,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
371 }371 }
372372
373 /// XOR the block vector with a byte sequence.373 /// XOR the block vector with a byte sequence.
374 pub inline fn xorBytes(block_vec: Self, bytes: *const [blocks_count * 16]u8) [32]u8 {374 pub fn xorBytes(block_vec: Self, bytes: *const [blocks_count * 16]u8) [32]u8 {
375 var out: Self = undefined;375 var out: Self = undefined;
376 for (0..native_words) |i| {376 for (0..native_words) |i| {
377 out.repr[i] = block_vec.repr[i].xorBytes(bytes[i * native_word_size ..][0..native_word_size]);377 out.repr[i] = block_vec.repr[i].xorBytes(bytes[i * native_word_size ..][0..native_word_size]);
...@@ -380,7 +380,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -380,7 +380,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
380 }380 }
381381
382 /// Apply the forward AES operation to the block vector with a vector of round keys.382 /// Apply the forward AES operation to the block vector with a vector of round keys.
383 pub inline fn encrypt(block_vec: Self, round_key_vec: Self) Self {383 pub fn encrypt(block_vec: Self, round_key_vec: Self) Self {
384 var out: Self = undefined;384 var out: Self = undefined;
385 for (0..native_words) |i| {385 for (0..native_words) |i| {
386 out.repr[i] = block_vec.repr[i].encrypt(round_key_vec.repr[i]);386 out.repr[i] = block_vec.repr[i].encrypt(round_key_vec.repr[i]);
...@@ -389,7 +389,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -389,7 +389,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
389 }389 }
390390
391 /// Apply the forward AES operation to the block vector with a vector of last round keys.391 /// Apply the forward AES operation to the block vector with a vector of last round keys.
392 pub inline fn encryptLast(block_vec: Self, round_key_vec: Self) Self {392 pub fn encryptLast(block_vec: Self, round_key_vec: Self) Self {
393 var out: Self = undefined;393 var out: Self = undefined;
394 for (0..native_words) |i| {394 for (0..native_words) |i| {
395 out.repr[i] = block_vec.repr[i].encryptLast(round_key_vec.repr[i]);395 out.repr[i] = block_vec.repr[i].encryptLast(round_key_vec.repr[i]);
...@@ -398,7 +398,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -398,7 +398,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
398 }398 }
399399
400 /// Apply the inverse AES operation to the block vector with a vector of round keys.400 /// Apply the inverse AES operation to the block vector with a vector of round keys.
401 pub inline fn decrypt(block_vec: Self, inv_round_key_vec: Self) Self {401 pub fn decrypt(block_vec: Self, inv_round_key_vec: Self) Self {
402 var out: Self = undefined;402 var out: Self = undefined;
403 for (0..native_words) |i| {403 for (0..native_words) |i| {
404 out.repr[i] = block_vec.repr[i].decrypt(inv_round_key_vec.repr[i]);404 out.repr[i] = block_vec.repr[i].decrypt(inv_round_key_vec.repr[i]);
...@@ -407,7 +407,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -407,7 +407,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
407 }407 }
408408
409 /// Apply the inverse AES operation to the block vector with a vector of last round keys.409 /// Apply the inverse AES operation to the block vector with a vector of last round keys.
410 pub inline fn decryptLast(block_vec: Self, inv_round_key_vec: Self) Self {410 pub fn decryptLast(block_vec: Self, inv_round_key_vec: Self) Self {
411 var out: Self = undefined;411 var out: Self = undefined;
412 for (0..native_words) |i| {412 for (0..native_words) |i| {
413 out.repr[i] = block_vec.repr[i].decryptLast(inv_round_key_vec.repr[i]);413 out.repr[i] = block_vec.repr[i].decryptLast(inv_round_key_vec.repr[i]);
...@@ -416,7 +416,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -416,7 +416,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
416 }416 }
417417
418 /// Apply the bitwise XOR operation to the content of two block vectors.418 /// Apply the bitwise XOR operation to the content of two block vectors.
419 pub inline fn xorBlocks(block_vec1: Self, block_vec2: Self) Self {419 pub fn xorBlocks(block_vec1: Self, block_vec2: Self) Self {
420 var out: Self = undefined;420 var out: Self = undefined;
421 for (0..native_words) |i| {421 for (0..native_words) |i| {
422 out.repr[i] = block_vec1.repr[i].xorBlocks(block_vec2.repr[i]);422 out.repr[i] = block_vec1.repr[i].xorBlocks(block_vec2.repr[i]);
...@@ -425,7 +425,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -425,7 +425,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
425 }425 }
426426
427 /// Apply the bitwise AND operation to the content of two block vectors.427 /// Apply the bitwise AND operation to the content of two block vectors.
428 pub inline fn andBlocks(block_vec1: Self, block_vec2: Self) Self {428 pub fn andBlocks(block_vec1: Self, block_vec2: Self) Self {
429 var out: Self = undefined;429 var out: Self = undefined;
430 for (0..native_words) |i| {430 for (0..native_words) |i| {
431 out.repr[i] = block_vec1.repr[i].andBlocks(block_vec2.repr[i]);431 out.repr[i] = block_vec1.repr[i].andBlocks(block_vec2.repr[i]);
...@@ -434,7 +434,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {...@@ -434,7 +434,7 @@ pub fn BlockVec(comptime blocks_count: comptime_int) type {
434 }434 }
435435
436 /// Apply the bitwise OR operation to the content of two block vectors.436 /// Apply the bitwise OR operation to the content of two block vectors.
437 pub inline fn orBlocks(block_vec1: Self, block_vec2: Block) Self {437 pub fn orBlocks(block_vec1: Self, block_vec2: Block) Self {
438 var out: Self = undefined;438 var out: Self = undefined;
439 for (0..native_words) |i| {439 for (0..native_words) |i| {
440 out.repr[i] = block_vec1.repr[i].orBlocks(block_vec2.repr[i]);440 out.repr[i] = block_vec1.repr[i].orBlocks(block_vec2.repr[i]);
lib/std/crypto/aes_gcm.zig+6
...@@ -21,6 +21,12 @@ fn AesGcm(comptime Aes: anytype) type {...@@ -21,6 +21,12 @@ fn AesGcm(comptime Aes: anytype) type {
2121
22 const zeros = [_]u8{0} ** 16;22 const zeros = [_]u8{0} ** 16;
2323
24 /// `c`: The ciphertext buffer to write the encrypted data to.
25 /// `tag`: The authentication tag buffer to write the computed tag to.
26 /// `m`: The plaintext message to encrypt.
27 /// `ad`: The associated data to authenticate.
28 /// `npub`: The nonce to use for encryption.
29 /// `key`: The encryption key.
24 pub fn encrypt(c: []u8, tag: *[tag_length]u8, m: []const u8, ad: []const u8, npub: [nonce_length]u8, key: [key_length]u8) void {30 pub fn encrypt(c: []u8, tag: *[tag_length]u8, m: []const u8, ad: []const u8, npub: [nonce_length]u8, key: [key_length]u8) void {
25 debug.assert(c.len == m.len);31 debug.assert(c.len == m.len);
26 debug.assert(m.len <= 16 * ((1 << 32) - 2));32 debug.assert(m.len <= 16 * ((1 << 32) - 2));
lib/std/crypto/aes_ocb.zig+3-3
...@@ -28,7 +28,7 @@ fn AesOcb(comptime Aes: anytype) type {...@@ -28,7 +28,7 @@ fn AesOcb(comptime Aes: anytype) type {
28 table: [56]Block align(16) = undefined,28 table: [56]Block align(16) = undefined,
29 upto: usize,29 upto: usize,
3030
31 inline fn double(l: Block) Block {31 fn double(l: Block) Block {
32 const l_ = mem.readInt(u128, &l, .big);32 const l_ = mem.readInt(u128, &l, .big);
33 const l_2 = (l_ << 1) ^ (0x87 & -%(l_ >> 127));33 const l_2 = (l_ << 1) ^ (0x87 & -%(l_ >> 127));
34 var l2: Block = undefined;34 var l2: Block = undefined;
...@@ -244,7 +244,7 @@ fn AesOcb(comptime Aes: anytype) type {...@@ -244,7 +244,7 @@ fn AesOcb(comptime Aes: anytype) type {
244 };244 };
245}245}
246246
247inline fn xorBlocks(x: Block, y: Block) Block {247fn xorBlocks(x: Block, y: Block) Block {
248 var z: Block = x;248 var z: Block = x;
249 for (&z, 0..) |*v, i| {249 for (&z, 0..) |*v, i| {
250 v.* = x[i] ^ y[i];250 v.* = x[i] ^ y[i];
...@@ -252,7 +252,7 @@ inline fn xorBlocks(x: Block, y: Block) Block {...@@ -252,7 +252,7 @@ inline fn xorBlocks(x: Block, y: Block) Block {
252 return z;252 return z;
253}253}
254254
255inline fn xorWith(x: *Block, y: Block) void {255fn xorWith(x: *Block, y: Block) void {
256 for (x, 0..) |*v, i| {256 for (x, 0..) |*v, i| {
257 v.* ^= y[i];257 v.* ^= y[i];
258 }258 }
lib/std/crypto/ascon.zig+4-4
...@@ -157,7 +157,7 @@ pub fn State(comptime endian: std.builtin.Endian) type {...@@ -157,7 +157,7 @@ pub fn State(comptime endian: std.builtin.Endian) type {
157 }157 }
158158
159 /// Apply a reduced-round permutation to the state.159 /// Apply a reduced-round permutation to the state.
160 pub inline fn permuteR(state: *Self, comptime rounds: u4) void {160 pub fn permuteR(state: *Self, comptime rounds: u4) void {
161 const rks = [16]u64{ 0x3c, 0x2d, 0x1e, 0x0f, 0xf0, 0xe1, 0xd2, 0xc3, 0xb4, 0xa5, 0x96, 0x87, 0x78, 0x69, 0x5a, 0x4b };161 const rks = [16]u64{ 0x3c, 0x2d, 0x1e, 0x0f, 0xf0, 0xe1, 0xd2, 0xc3, 0xb4, 0xa5, 0x96, 0x87, 0x78, 0x69, 0x5a, 0x4b };
162 inline for (rks[rks.len - rounds ..]) |rk| {162 inline for (rks[rks.len - rounds ..]) |rk| {
163 state.round(rk);163 state.round(rk);
...@@ -165,13 +165,13 @@ pub fn State(comptime endian: std.builtin.Endian) type {...@@ -165,13 +165,13 @@ pub fn State(comptime endian: std.builtin.Endian) type {
165 }165 }
166166
167 /// Apply a full-round permutation to the state.167 /// Apply a full-round permutation to the state.
168 pub inline fn permute(state: *Self) void {168 pub fn permute(state: *Self) void {
169 state.permuteR(12);169 state.permuteR(12);
170 }170 }
171171
172 /// Apply a permutation to the state and prevent backtracking.172 /// Apply a permutation to the state and prevent backtracking.
173 /// The rate is expressed in bytes and must be a multiple of the word size (8).173 /// The rate is expressed in bytes and must be a multiple of the word size (8).
174 pub inline fn permuteRatchet(state: *Self, comptime rounds: u4, comptime rate: u6) void {174 pub fn permuteRatchet(state: *Self, comptime rounds: u4, comptime rate: u6) void {
175 const capacity = block_bytes - rate;175 const capacity = block_bytes - rate;
176 debug.assert(capacity > 0 and capacity % 8 == 0); // capacity must be a multiple of 64 bits176 debug.assert(capacity > 0 and capacity % 8 == 0); // capacity must be a multiple of 64 bits
177 var mask: [capacity / 8]u64 = undefined;177 var mask: [capacity / 8]u64 = undefined;
...@@ -181,7 +181,7 @@ pub fn State(comptime endian: std.builtin.Endian) type {...@@ -181,7 +181,7 @@ pub fn State(comptime endian: std.builtin.Endian) type {
181 }181 }
182182
183 // Core Ascon permutation.183 // Core Ascon permutation.
184 inline fn round(state: *Self, rk: u64) void {184 fn round(state: *Self, rk: u64) void {
185 const x = &state.st;185 const x = &state.st;
186 x[2] ^= rk;186 x[2] ^= rk;
187187
lib/std/crypto/blake3.zig+3-3
...@@ -61,7 +61,7 @@ const CompressVectorized = struct {...@@ -61,7 +61,7 @@ const CompressVectorized = struct {
61 const Lane = @Vector(4, u32);61 const Lane = @Vector(4, u32);
62 const Rows = [4]Lane;62 const Rows = [4]Lane;
6363
64 inline fn g(comptime even: bool, rows: *Rows, m: Lane) void {64 fn g(comptime even: bool, rows: *Rows, m: Lane) void {
65 rows[0] +%= rows[1] +% m;65 rows[0] +%= rows[1] +% m;
66 rows[3] ^= rows[0];66 rows[3] ^= rows[0];
67 rows[3] = math.rotr(Lane, rows[3], if (even) 8 else 16);67 rows[3] = math.rotr(Lane, rows[3], if (even) 8 else 16);
...@@ -70,13 +70,13 @@ const CompressVectorized = struct {...@@ -70,13 +70,13 @@ const CompressVectorized = struct {
70 rows[1] = math.rotr(Lane, rows[1], if (even) 7 else 12);70 rows[1] = math.rotr(Lane, rows[1], if (even) 7 else 12);
71 }71 }
7272
73 inline fn diagonalize(rows: *Rows) void {73 fn diagonalize(rows: *Rows) void {
74 rows[0] = @shuffle(u32, rows[0], undefined, [_]i32{ 3, 0, 1, 2 });74 rows[0] = @shuffle(u32, rows[0], undefined, [_]i32{ 3, 0, 1, 2 });
75 rows[3] = @shuffle(u32, rows[3], undefined, [_]i32{ 2, 3, 0, 1 });75 rows[3] = @shuffle(u32, rows[3], undefined, [_]i32{ 2, 3, 0, 1 });
76 rows[2] = @shuffle(u32, rows[2], undefined, [_]i32{ 1, 2, 3, 0 });76 rows[2] = @shuffle(u32, rows[2], undefined, [_]i32{ 1, 2, 3, 0 });
77 }77 }
7878
79 inline fn undiagonalize(rows: *Rows) void {79 fn undiagonalize(rows: *Rows) void {
80 rows[0] = @shuffle(u32, rows[0], undefined, [_]i32{ 1, 2, 3, 0 });80 rows[0] = @shuffle(u32, rows[0], undefined, [_]i32{ 1, 2, 3, 0 });
81 rows[3] = @shuffle(u32, rows[3], undefined, [_]i32{ 2, 3, 0, 1 });81 rows[3] = @shuffle(u32, rows[3], undefined, [_]i32{ 2, 3, 0, 1 });
82 rows[2] = @shuffle(u32, rows[2], undefined, [_]i32{ 3, 0, 1, 2 });82 rows[2] = @shuffle(u32, rows[2], undefined, [_]i32{ 3, 0, 1, 2 });
lib/std/crypto/chacha20.zig+6-6
...@@ -151,7 +151,7 @@ fn ChaChaVecImpl(comptime rounds_nb: usize, comptime degree: comptime_int) type...@@ -151,7 +151,7 @@ fn ChaChaVecImpl(comptime rounds_nb: usize, comptime degree: comptime_int) type
151 }151 }
152 }152 }
153153
154 inline fn chacha20Core(x: *BlockVec, input: BlockVec) void {154 fn chacha20Core(x: *BlockVec, input: BlockVec) void {
155 x.* = input;155 x.* = input;
156156
157 const m0 = switch (degree) {157 const m0 = switch (degree) {
...@@ -215,7 +215,7 @@ fn ChaChaVecImpl(comptime rounds_nb: usize, comptime degree: comptime_int) type...@@ -215,7 +215,7 @@ fn ChaChaVecImpl(comptime rounds_nb: usize, comptime degree: comptime_int) type
215 }215 }
216 }216 }
217217
218 inline fn hashToBytes(comptime dm: usize, out: *[64 * dm]u8, x: BlockVec) void {218 fn hashToBytes(comptime dm: usize, out: *[64 * dm]u8, x: BlockVec) void {
219 for (0..dm) |d| {219 for (0..dm) |d| {
220 for (0..4) |i| {220 for (0..4) |i| {
221 mem.writeInt(u32, out[64 * d + 16 * i + 0 ..][0..4], x[i][0 + 4 * d], .little);221 mem.writeInt(u32, out[64 * d + 16 * i + 0 ..][0..4], x[i][0 + 4 * d], .little);
...@@ -226,7 +226,7 @@ fn ChaChaVecImpl(comptime rounds_nb: usize, comptime degree: comptime_int) type...@@ -226,7 +226,7 @@ fn ChaChaVecImpl(comptime rounds_nb: usize, comptime degree: comptime_int) type
226 }226 }
227 }227 }
228228
229 inline fn contextFeedback(x: *BlockVec, ctx: BlockVec) void {229 fn contextFeedback(x: *BlockVec, ctx: BlockVec) void {
230 x[0] +%= ctx[0];230 x[0] +%= ctx[0];
231 x[1] +%= ctx[1];231 x[1] +%= ctx[1];
232 x[2] +%= ctx[2];232 x[2] +%= ctx[2];
...@@ -365,7 +365,7 @@ fn ChaChaNonVecImpl(comptime rounds_nb: usize) type {...@@ -365,7 +365,7 @@ fn ChaChaNonVecImpl(comptime rounds_nb: usize) type {
365 };365 };
366 }366 }
367367
368 inline fn chacha20Core(x: *BlockVec, input: BlockVec) void {368 fn chacha20Core(x: *BlockVec, input: BlockVec) void {
369 x.* = input;369 x.* = input;
370370
371 const rounds = comptime [_]QuarterRound{371 const rounds = comptime [_]QuarterRound{
...@@ -394,7 +394,7 @@ fn ChaChaNonVecImpl(comptime rounds_nb: usize) type {...@@ -394,7 +394,7 @@ fn ChaChaNonVecImpl(comptime rounds_nb: usize) type {
394 }394 }
395 }395 }
396396
397 inline fn hashToBytes(out: *[64]u8, x: BlockVec) void {397 fn hashToBytes(out: *[64]u8, x: BlockVec) void {
398 for (0..4) |i| {398 for (0..4) |i| {
399 mem.writeInt(u32, out[16 * i + 0 ..][0..4], x[i * 4 + 0], .little);399 mem.writeInt(u32, out[16 * i + 0 ..][0..4], x[i * 4 + 0], .little);
400 mem.writeInt(u32, out[16 * i + 4 ..][0..4], x[i * 4 + 1], .little);400 mem.writeInt(u32, out[16 * i + 4 ..][0..4], x[i * 4 + 1], .little);
...@@ -403,7 +403,7 @@ fn ChaChaNonVecImpl(comptime rounds_nb: usize) type {...@@ -403,7 +403,7 @@ fn ChaChaNonVecImpl(comptime rounds_nb: usize) type {
403 }403 }
404 }404 }
405405
406 inline fn contextFeedback(x: *BlockVec, ctx: BlockVec) void {406 fn contextFeedback(x: *BlockVec, ctx: BlockVec) void {
407 for (0..16) |i| {407 for (0..16) |i| {
408 x[i] +%= ctx[i];408 x[i] +%= ctx[i];
409 }409 }
lib/std/crypto/codecs/base64_hex_ct.zig+7-7
...@@ -280,34 +280,34 @@ pub const base64 = struct {...@@ -280,34 +280,34 @@ pub const base64 = struct {
280 return DecoderWithIgnore{ .ignored_chars = ignored_chars };280 return DecoderWithIgnore{ .ignored_chars = ignored_chars };
281 }281 }
282282
283 inline fn eq(x: u8, y: u8) u8 {283 fn eq(x: u8, y: u8) u8 {
284 return ~@as(u8, @truncate((0 -% (@as(u16, x) ^ @as(u16, y))) >> 8));284 return ~@as(u8, @truncate((0 -% (@as(u16, x) ^ @as(u16, y))) >> 8));
285 }285 }
286286
287 inline fn gt(x: u8, y: u8) u8 {287 fn gt(x: u8, y: u8) u8 {
288 return @truncate((@as(u16, y) -% @as(u16, x)) >> 8);288 return @truncate((@as(u16, y) -% @as(u16, x)) >> 8);
289 }289 }
290290
291 inline fn ge(x: u8, y: u8) u8 {291 fn ge(x: u8, y: u8) u8 {
292 return ~gt(y, x);292 return ~gt(y, x);
293 }293 }
294294
295 inline fn lt(x: u8, y: u8) u8 {295 fn lt(x: u8, y: u8) u8 {
296 return gt(y, x);296 return gt(y, x);
297 }297 }
298298
299 inline fn le(x: u8, y: u8) u8 {299 fn le(x: u8, y: u8) u8 {
300 return ge(y, x);300 return ge(y, x);
301 }301 }
302302
303 inline fn charFromByte(x: u8, comptime urlsafe: bool) u8 {303 fn charFromByte(x: u8, comptime urlsafe: bool) u8 {
304 return (lt(x, 26) & (x +% 'A')) |304 return (lt(x, 26) & (x +% 'A')) |
305 (ge(x, 26) & lt(x, 52) & (x +% 'a' -% 26)) |305 (ge(x, 26) & lt(x, 52) & (x +% 'a' -% 26)) |
306 (ge(x, 52) & lt(x, 62) & (x +% '0' -% 52)) |306 (ge(x, 52) & lt(x, 62) & (x +% '0' -% 52)) |
307 (eq(x, 62) & '+') | (eq(x, 63) & if (urlsafe) '_' else '/');307 (eq(x, 62) & '+') | (eq(x, 63) & if (urlsafe) '_' else '/');
308 }308 }
309309
310 inline fn byteFromChar(c: u8, comptime urlsafe: bool) u8 {310 fn byteFromChar(c: u8, comptime urlsafe: bool) u8 {
311 const x =311 const x =
312 (ge(c, 'A') & le(c, 'Z') & (c -% 'A')) |312 (ge(c, 'A') & le(c, 'Z') & (c -% 'A')) |
313 (ge(c, 'a') & le(c, 'z') & (c -% 'a' +% 26)) |313 (ge(c, 'a') & le(c, 'z') & (c -% 'a' +% 26)) |
lib/std/crypto/ghash_polyval.zig+5-5
...@@ -89,7 +89,7 @@ fn Hash(comptime endian: std.builtin.Endian, comptime shift_key: bool) type {...@@ -89,7 +89,7 @@ fn Hash(comptime endian: std.builtin.Endian, comptime shift_key: bool) type {
89 const Selector = enum { lo, hi, hi_lo };89 const Selector = enum { lo, hi, hi_lo };
9090
91 // Carryless multiplication of two 64-bit integers for x86_64.91 // Carryless multiplication of two 64-bit integers for x86_64.
92 inline fn clmulPclmul(x: u128, y: u128, comptime half: Selector) u128 {92 fn clmulPclmul(x: u128, y: u128, comptime half: Selector) u128 {
93 switch (half) {93 switch (half) {
94 .hi => {94 .hi => {
95 const product = asm (95 const product = asm (
...@@ -122,7 +122,7 @@ fn Hash(comptime endian: std.builtin.Endian, comptime shift_key: bool) type {...@@ -122,7 +122,7 @@ fn Hash(comptime endian: std.builtin.Endian, comptime shift_key: bool) type {
122 }122 }
123123
124 // Carryless multiplication of two 64-bit integers for ARM crypto.124 // Carryless multiplication of two 64-bit integers for ARM crypto.
125 inline fn clmulPmull(x: u128, y: u128, comptime half: Selector) u128 {125 fn clmulPmull(x: u128, y: u128, comptime half: Selector) u128 {
126 switch (half) {126 switch (half) {
127 .hi => {127 .hi => {
128 const product = asm (128 const product = asm (
...@@ -231,7 +231,7 @@ fn Hash(comptime endian: std.builtin.Endian, comptime shift_key: bool) type {...@@ -231,7 +231,7 @@ fn Hash(comptime endian: std.builtin.Endian, comptime shift_key: bool) type {
231 mid: u128,231 mid: u128,
232 };232 };
233233
234 inline fn xor256(x: *I256, y: I256) void {234 fn xor256(x: *I256, y: I256) void {
235 x.* = I256{235 x.* = I256{
236 .hi = x.hi ^ y.hi,236 .hi = x.hi ^ y.hi,
237 .lo = x.lo ^ y.lo,237 .lo = x.lo ^ y.lo,
...@@ -249,7 +249,7 @@ fn Hash(comptime endian: std.builtin.Endian, comptime shift_key: bool) type {...@@ -249,7 +249,7 @@ fn Hash(comptime endian: std.builtin.Endian, comptime shift_key: bool) type {
249 }249 }
250250
251 // Multiply two 128-bit integers in GF(2^128).251 // Multiply two 128-bit integers in GF(2^128).
252 inline fn clmul128(x: u128, y: u128) I256 {252 fn clmul128(x: u128, y: u128) I256 {
253 if (mul_algorithm == .karatsuba) {253 if (mul_algorithm == .karatsuba) {
254 const x_hi = @as(u64, @truncate(x >> 64));254 const x_hi = @as(u64, @truncate(x >> 64));
255 const y_hi = @as(u64, @truncate(y >> 64));255 const y_hi = @as(u64, @truncate(y >> 64));
...@@ -273,7 +273,7 @@ fn Hash(comptime endian: std.builtin.Endian, comptime shift_key: bool) type {...@@ -273,7 +273,7 @@ fn Hash(comptime endian: std.builtin.Endian, comptime shift_key: bool) type {
273 // Reduce a 256-bit representative of a polynomial modulo the irreducible polynomial x^128 + x^127 + x^126 + x^121 + 1.273 // Reduce a 256-bit representative of a polynomial modulo the irreducible polynomial x^128 + x^127 + x^126 + x^121 + 1.
274 // This is done using Shay Gueron's black magic demysticated here:274 // This is done using Shay Gueron's black magic demysticated here:
275 // https://blog.quarkslab.com/reversing-a-finite-field-multiplication-optimization.html275 // https://blog.quarkslab.com/reversing-a-finite-field-multiplication-optimization.html
276 inline fn reduce(x: I256) u128 {276 fn reduce(x: I256) u128 {
277 const hi = x.hi ^ (x.mid >> 64);277 const hi = x.hi ^ (x.mid >> 64);
278 const lo = x.lo ^ (x.mid << 64);278 const lo = x.lo ^ (x.mid << 64);
279 const p64 = (((1 << 121) | (1 << 126) | (1 << 127)) >> 64);279 const p64 = (((1 << 121) | (1 << 126) | (1 << 127)) >> 64);
lib/std/crypto/pcurves/p256/p256_64.zig+4-4
...@@ -72,7 +72,7 @@ pub const NonMontgomeryDomainFieldElement = [4]u64;...@@ -72,7 +72,7 @@ pub const NonMontgomeryDomainFieldElement = [4]u64;
72/// Output Bounds:72/// Output Bounds:
73/// out1: [0x0 ~> 0xffffffffffffffff]73/// out1: [0x0 ~> 0xffffffffffffffff]
74/// out2: [0x0 ~> 0x1]74/// out2: [0x0 ~> 0x1]
75inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {75fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {
76 const x = @as(u128, arg2) +% arg3 +% arg1;76 const x = @as(u128, arg2) +% arg3 +% arg1;
77 out1.* = @truncate(x);77 out1.* = @truncate(x);
78 out2.* = @truncate(x >> 64);78 out2.* = @truncate(x >> 64);
...@@ -91,7 +91,7 @@ inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) vo...@@ -91,7 +91,7 @@ inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) vo
91/// Output Bounds:91/// Output Bounds:
92/// out1: [0x0 ~> 0xffffffffffffffff]92/// out1: [0x0 ~> 0xffffffffffffffff]
93/// out2: [0x0 ~> 0x1]93/// out2: [0x0 ~> 0x1]
94inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {94fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {
95 const x = @as(u128, arg2) -% arg3 -% arg1;95 const x = @as(u128, arg2) -% arg3 -% arg1;
96 out1.* = @truncate(x);96 out1.* = @truncate(x);
97 out2.* = @truncate(x >> 64);97 out2.* = @truncate(x >> 64);
...@@ -109,7 +109,7 @@ inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) v...@@ -109,7 +109,7 @@ inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) v
109/// Output Bounds:109/// Output Bounds:
110/// out1: [0x0 ~> 0xffffffffffffffff]110/// out1: [0x0 ~> 0xffffffffffffffff]
111/// out2: [0x0 ~> 0xffffffffffffffff]111/// out2: [0x0 ~> 0xffffffffffffffff]
112inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {112fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {
113 @setRuntimeSafety(mode == .Debug);113 @setRuntimeSafety(mode == .Debug);
114114
115 const x = @as(u128, arg1) * @as(u128, arg2);115 const x = @as(u128, arg1) * @as(u128, arg2);
...@@ -128,7 +128,7 @@ inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {...@@ -128,7 +128,7 @@ inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {
128/// arg3: [0x0 ~> 0xffffffffffffffff]128/// arg3: [0x0 ~> 0xffffffffffffffff]
129/// Output Bounds:129/// Output Bounds:
130/// out1: [0x0 ~> 0xffffffffffffffff]130/// out1: [0x0 ~> 0xffffffffffffffff]
131inline fn cmovznzU64(out1: *u64, arg1: u1, arg2: u64, arg3: u64) void {131fn cmovznzU64(out1: *u64, arg1: u1, arg2: u64, arg3: u64) void {
132 @setRuntimeSafety(mode == .Debug);132 @setRuntimeSafety(mode == .Debug);
133133
134 const mask = 0 -% @as(u64, arg1);134 const mask = 0 -% @as(u64, arg1);
lib/std/crypto/pcurves/p256/p256_scalar_64.zig+4-4
...@@ -72,7 +72,7 @@ pub const NonMontgomeryDomainFieldElement = [4]u64;...@@ -72,7 +72,7 @@ pub const NonMontgomeryDomainFieldElement = [4]u64;
72/// Output Bounds:72/// Output Bounds:
73/// out1: [0x0 ~> 0xffffffffffffffff]73/// out1: [0x0 ~> 0xffffffffffffffff]
74/// out2: [0x0 ~> 0x1]74/// out2: [0x0 ~> 0x1]
75inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {75fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {
76 const x = @as(u128, arg2) +% arg3 +% arg1;76 const x = @as(u128, arg2) +% arg3 +% arg1;
77 out1.* = @truncate(x);77 out1.* = @truncate(x);
78 out2.* = @truncate(x >> 64);78 out2.* = @truncate(x >> 64);
...@@ -91,7 +91,7 @@ inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) vo...@@ -91,7 +91,7 @@ inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) vo
91/// Output Bounds:91/// Output Bounds:
92/// out1: [0x0 ~> 0xffffffffffffffff]92/// out1: [0x0 ~> 0xffffffffffffffff]
93/// out2: [0x0 ~> 0x1]93/// out2: [0x0 ~> 0x1]
94inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {94fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {
95 const x = @as(u128, arg2) -% arg3 -% arg1;95 const x = @as(u128, arg2) -% arg3 -% arg1;
96 out1.* = @truncate(x);96 out1.* = @truncate(x);
97 out2.* = @truncate(x >> 64);97 out2.* = @truncate(x >> 64);
...@@ -109,7 +109,7 @@ inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) v...@@ -109,7 +109,7 @@ inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) v
109/// Output Bounds:109/// Output Bounds:
110/// out1: [0x0 ~> 0xffffffffffffffff]110/// out1: [0x0 ~> 0xffffffffffffffff]
111/// out2: [0x0 ~> 0xffffffffffffffff]111/// out2: [0x0 ~> 0xffffffffffffffff]
112inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {112fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {
113 @setRuntimeSafety(mode == .Debug);113 @setRuntimeSafety(mode == .Debug);
114114
115 const x = @as(u128, arg1) * @as(u128, arg2);115 const x = @as(u128, arg1) * @as(u128, arg2);
...@@ -128,7 +128,7 @@ inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {...@@ -128,7 +128,7 @@ inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {
128/// arg3: [0x0 ~> 0xffffffffffffffff]128/// arg3: [0x0 ~> 0xffffffffffffffff]
129/// Output Bounds:129/// Output Bounds:
130/// out1: [0x0 ~> 0xffffffffffffffff]130/// out1: [0x0 ~> 0xffffffffffffffff]
131inline fn cmovznzU64(out1: *u64, arg1: u1, arg2: u64, arg3: u64) void {131fn cmovznzU64(out1: *u64, arg1: u1, arg2: u64, arg3: u64) void {
132 @setRuntimeSafety(mode == .Debug);132 @setRuntimeSafety(mode == .Debug);
133133
134 const mask = 0 -% @as(u64, arg1);134 const mask = 0 -% @as(u64, arg1);
lib/std/crypto/pcurves/p384/p384_64.zig+4-4
...@@ -41,7 +41,7 @@ pub const NonMontgomeryDomainFieldElement = [6]u64;...@@ -41,7 +41,7 @@ pub const NonMontgomeryDomainFieldElement = [6]u64;
41/// Output Bounds:41/// Output Bounds:
42/// out1: [0x0 ~> 0xffffffffffffffff]42/// out1: [0x0 ~> 0xffffffffffffffff]
43/// out2: [0x0 ~> 0x1]43/// out2: [0x0 ~> 0x1]
44inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {44fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {
45 const x = @as(u128, arg2) +% arg3 +% arg1;45 const x = @as(u128, arg2) +% arg3 +% arg1;
46 out1.* = @truncate(x);46 out1.* = @truncate(x);
47 out2.* = @truncate(x >> 64);47 out2.* = @truncate(x >> 64);
...@@ -60,7 +60,7 @@ inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) vo...@@ -60,7 +60,7 @@ inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) vo
60/// Output Bounds:60/// Output Bounds:
61/// out1: [0x0 ~> 0xffffffffffffffff]61/// out1: [0x0 ~> 0xffffffffffffffff]
62/// out2: [0x0 ~> 0x1]62/// out2: [0x0 ~> 0x1]
63inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {63fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {
64 const x = @as(u128, arg2) -% arg3 -% arg1;64 const x = @as(u128, arg2) -% arg3 -% arg1;
65 out1.* = @truncate(x);65 out1.* = @truncate(x);
66 out2.* = @truncate(x >> 64);66 out2.* = @truncate(x >> 64);
...@@ -78,7 +78,7 @@ inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) v...@@ -78,7 +78,7 @@ inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) v
78/// Output Bounds:78/// Output Bounds:
79/// out1: [0x0 ~> 0xffffffffffffffff]79/// out1: [0x0 ~> 0xffffffffffffffff]
80/// out2: [0x0 ~> 0xffffffffffffffff]80/// out2: [0x0 ~> 0xffffffffffffffff]
81inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {81fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {
82 @setRuntimeSafety(mode == .Debug);82 @setRuntimeSafety(mode == .Debug);
8383
84 const x = @as(u128, arg1) * @as(u128, arg2);84 const x = @as(u128, arg1) * @as(u128, arg2);
...@@ -97,7 +97,7 @@ inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {...@@ -97,7 +97,7 @@ inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {
97/// arg3: [0x0 ~> 0xffffffffffffffff]97/// arg3: [0x0 ~> 0xffffffffffffffff]
98/// Output Bounds:98/// Output Bounds:
99/// out1: [0x0 ~> 0xffffffffffffffff]99/// out1: [0x0 ~> 0xffffffffffffffff]
100inline fn cmovznzU64(out1: *u64, arg1: u1, arg2: u64, arg3: u64) void {100fn cmovznzU64(out1: *u64, arg1: u1, arg2: u64, arg3: u64) void {
101 @setRuntimeSafety(mode == .Debug);101 @setRuntimeSafety(mode == .Debug);
102102
103 const mask = 0 -% @as(u64, arg1);103 const mask = 0 -% @as(u64, arg1);
lib/std/crypto/pcurves/p384/p384_scalar_64.zig+4-4
...@@ -41,7 +41,7 @@ pub const NonMontgomeryDomainFieldElement = [6]u64;...@@ -41,7 +41,7 @@ pub const NonMontgomeryDomainFieldElement = [6]u64;
41/// Output Bounds:41/// Output Bounds:
42/// out1: [0x0 ~> 0xffffffffffffffff]42/// out1: [0x0 ~> 0xffffffffffffffff]
43/// out2: [0x0 ~> 0x1]43/// out2: [0x0 ~> 0x1]
44inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {44fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {
45 const x = @as(u128, arg2) +% arg3 +% arg1;45 const x = @as(u128, arg2) +% arg3 +% arg1;
46 out1.* = @truncate(x);46 out1.* = @truncate(x);
47 out2.* = @truncate(x >> 64);47 out2.* = @truncate(x >> 64);
...@@ -60,7 +60,7 @@ inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) vo...@@ -60,7 +60,7 @@ inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) vo
60/// Output Bounds:60/// Output Bounds:
61/// out1: [0x0 ~> 0xffffffffffffffff]61/// out1: [0x0 ~> 0xffffffffffffffff]
62/// out2: [0x0 ~> 0x1]62/// out2: [0x0 ~> 0x1]
63inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {63fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {
64 const x = @as(u128, arg2) -% arg3 -% arg1;64 const x = @as(u128, arg2) -% arg3 -% arg1;
65 out1.* = @truncate(x);65 out1.* = @truncate(x);
66 out2.* = @truncate(x >> 64);66 out2.* = @truncate(x >> 64);
...@@ -78,7 +78,7 @@ inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) v...@@ -78,7 +78,7 @@ inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) v
78/// Output Bounds:78/// Output Bounds:
79/// out1: [0x0 ~> 0xffffffffffffffff]79/// out1: [0x0 ~> 0xffffffffffffffff]
80/// out2: [0x0 ~> 0xffffffffffffffff]80/// out2: [0x0 ~> 0xffffffffffffffff]
81inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {81fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {
82 @setRuntimeSafety(mode == .Debug);82 @setRuntimeSafety(mode == .Debug);
8383
84 const x = @as(u128, arg1) * @as(u128, arg2);84 const x = @as(u128, arg1) * @as(u128, arg2);
...@@ -97,7 +97,7 @@ inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {...@@ -97,7 +97,7 @@ inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {
97/// arg3: [0x0 ~> 0xffffffffffffffff]97/// arg3: [0x0 ~> 0xffffffffffffffff]
98/// Output Bounds:98/// Output Bounds:
99/// out1: [0x0 ~> 0xffffffffffffffff]99/// out1: [0x0 ~> 0xffffffffffffffff]
100inline fn cmovznzU64(out1: *u64, arg1: u1, arg2: u64, arg3: u64) void {100fn cmovznzU64(out1: *u64, arg1: u1, arg2: u64, arg3: u64) void {
101 @setRuntimeSafety(mode == .Debug);101 @setRuntimeSafety(mode == .Debug);
102102
103 const mask = 0 -% @as(u64, arg1);103 const mask = 0 -% @as(u64, arg1);
lib/std/crypto/pcurves/secp256k1/secp256k1_64.zig+4-4
...@@ -41,7 +41,7 @@ pub const NonMontgomeryDomainFieldElement = [4]u64;...@@ -41,7 +41,7 @@ pub const NonMontgomeryDomainFieldElement = [4]u64;
41/// Output Bounds:41/// Output Bounds:
42/// out1: [0x0 ~> 0xffffffffffffffff]42/// out1: [0x0 ~> 0xffffffffffffffff]
43/// out2: [0x0 ~> 0x1]43/// out2: [0x0 ~> 0x1]
44inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {44fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {
45 const x = @as(u128, arg2) +% arg3 +% arg1;45 const x = @as(u128, arg2) +% arg3 +% arg1;
46 out1.* = @truncate(x);46 out1.* = @truncate(x);
47 out2.* = @truncate(x >> 64);47 out2.* = @truncate(x >> 64);
...@@ -60,7 +60,7 @@ inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) vo...@@ -60,7 +60,7 @@ inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) vo
60/// Output Bounds:60/// Output Bounds:
61/// out1: [0x0 ~> 0xffffffffffffffff]61/// out1: [0x0 ~> 0xffffffffffffffff]
62/// out2: [0x0 ~> 0x1]62/// out2: [0x0 ~> 0x1]
63inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {63fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {
64 const x = @as(u128, arg2) -% arg3 -% arg1;64 const x = @as(u128, arg2) -% arg3 -% arg1;
65 out1.* = @truncate(x);65 out1.* = @truncate(x);
66 out2.* = @truncate(x >> 64);66 out2.* = @truncate(x >> 64);
...@@ -78,7 +78,7 @@ inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) v...@@ -78,7 +78,7 @@ inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) v
78/// Output Bounds:78/// Output Bounds:
79/// out1: [0x0 ~> 0xffffffffffffffff]79/// out1: [0x0 ~> 0xffffffffffffffff]
80/// out2: [0x0 ~> 0xffffffffffffffff]80/// out2: [0x0 ~> 0xffffffffffffffff]
81inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {81fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {
82 @setRuntimeSafety(mode == .Debug);82 @setRuntimeSafety(mode == .Debug);
8383
84 const x = @as(u128, arg1) * @as(u128, arg2);84 const x = @as(u128, arg1) * @as(u128, arg2);
...@@ -97,7 +97,7 @@ inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {...@@ -97,7 +97,7 @@ inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {
97/// arg3: [0x0 ~> 0xffffffffffffffff]97/// arg3: [0x0 ~> 0xffffffffffffffff]
98/// Output Bounds:98/// Output Bounds:
99/// out1: [0x0 ~> 0xffffffffffffffff]99/// out1: [0x0 ~> 0xffffffffffffffff]
100inline fn cmovznzU64(out1: *u64, arg1: u1, arg2: u64, arg3: u64) void {100fn cmovznzU64(out1: *u64, arg1: u1, arg2: u64, arg3: u64) void {
101 @setRuntimeSafety(mode == .Debug);101 @setRuntimeSafety(mode == .Debug);
102102
103 const mask = 0 -% @as(u64, arg1);103 const mask = 0 -% @as(u64, arg1);
lib/std/crypto/pcurves/secp256k1/secp256k1_scalar_64.zig+4-4
...@@ -41,7 +41,7 @@ pub const NonMontgomeryDomainFieldElement = [4]u64;...@@ -41,7 +41,7 @@ pub const NonMontgomeryDomainFieldElement = [4]u64;
41/// Output Bounds:41/// Output Bounds:
42/// out1: [0x0 ~> 0xffffffffffffffff]42/// out1: [0x0 ~> 0xffffffffffffffff]
43/// out2: [0x0 ~> 0x1]43/// out2: [0x0 ~> 0x1]
44inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {44fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {
45 const x = @as(u128, arg2) +% arg3 +% arg1;45 const x = @as(u128, arg2) +% arg3 +% arg1;
46 out1.* = @truncate(x);46 out1.* = @truncate(x);
47 out2.* = @truncate(x >> 64);47 out2.* = @truncate(x >> 64);
...@@ -60,7 +60,7 @@ inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) vo...@@ -60,7 +60,7 @@ inline fn addcarryxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) vo
60/// Output Bounds:60/// Output Bounds:
61/// out1: [0x0 ~> 0xffffffffffffffff]61/// out1: [0x0 ~> 0xffffffffffffffff]
62/// out2: [0x0 ~> 0x1]62/// out2: [0x0 ~> 0x1]
63inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {63fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) void {
64 const x = @as(u128, arg2) -% arg3 -% arg1;64 const x = @as(u128, arg2) -% arg3 -% arg1;
65 out1.* = @truncate(x);65 out1.* = @truncate(x);
66 out2.* = @truncate(x >> 64);66 out2.* = @truncate(x >> 64);
...@@ -78,7 +78,7 @@ inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) v...@@ -78,7 +78,7 @@ inline fn subborrowxU64(out1: *u64, out2: *u1, arg1: u1, arg2: u64, arg3: u64) v
78/// Output Bounds:78/// Output Bounds:
79/// out1: [0x0 ~> 0xffffffffffffffff]79/// out1: [0x0 ~> 0xffffffffffffffff]
80/// out2: [0x0 ~> 0xffffffffffffffff]80/// out2: [0x0 ~> 0xffffffffffffffff]
81inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {81fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {
82 @setRuntimeSafety(mode == .Debug);82 @setRuntimeSafety(mode == .Debug);
8383
84 const x = @as(u128, arg1) * @as(u128, arg2);84 const x = @as(u128, arg1) * @as(u128, arg2);
...@@ -97,7 +97,7 @@ inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {...@@ -97,7 +97,7 @@ inline fn mulxU64(out1: *u64, out2: *u64, arg1: u64, arg2: u64) void {
97/// arg3: [0x0 ~> 0xffffffffffffffff]97/// arg3: [0x0 ~> 0xffffffffffffffff]
98/// Output Bounds:98/// Output Bounds:
99/// out1: [0x0 ~> 0xffffffffffffffff]99/// out1: [0x0 ~> 0xffffffffffffffff]
100inline fn cmovznzU64(out1: *u64, arg1: u1, arg2: u64, arg3: u64) void {100fn cmovznzU64(out1: *u64, arg1: u1, arg2: u64, arg3: u64) void {
101 @setRuntimeSafety(mode == .Debug);101 @setRuntimeSafety(mode == .Debug);
102102
103 const mask = 0 -% @as(u64, arg1);103 const mask = 0 -% @as(u64, arg1);
lib/std/crypto/poly1305.zig+2-2
...@@ -31,13 +31,13 @@ pub const Poly1305 = struct {...@@ -31,13 +31,13 @@ pub const Poly1305 = struct {
31 };31 };
32 }32 }
3333
34 inline fn add(a: u64, b: u64, c: u1) struct { u64, u1 } {34 fn add(a: u64, b: u64, c: u1) struct { u64, u1 } {
35 const v1 = @addWithOverflow(a, b);35 const v1 = @addWithOverflow(a, b);
36 const v2 = @addWithOverflow(v1[0], c);36 const v2 = @addWithOverflow(v1[0], c);
37 return .{ v2[0], v1[1] | v2[1] };37 return .{ v2[0], v1[1] | v2[1] };
38 }38 }
3939
40 inline fn sub(a: u64, b: u64, c: u1) struct { u64, u1 } {40 fn sub(a: u64, b: u64, c: u1) struct { u64, u1 } {
41 const v1 = @subWithOverflow(a, b);41 const v1 = @subWithOverflow(a, b);
42 const v2 = @subWithOverflow(v1[0], c);42 const v2 = @subWithOverflow(v1[0], c);
43 return .{ v2[0], v1[1] | v2[1] };43 return .{ v2[0], v1[1] | v2[1] };
lib/std/crypto/salsa20.zig+3-3
...@@ -41,7 +41,7 @@ fn SalsaVecImpl(comptime rounds: comptime_int) type {...@@ -41,7 +41,7 @@ fn SalsaVecImpl(comptime rounds: comptime_int) type {
41 };41 };
42 }42 }
4343
44 inline fn salsaCore(x: *BlockVec, input: BlockVec, comptime feedback: bool) void {44 fn salsaCore(x: *BlockVec, input: BlockVec, comptime feedback: bool) void {
45 const n1n2n3n0 = Lane{ input[3][1], input[3][2], input[3][3], input[3][0] };45 const n1n2n3n0 = Lane{ input[3][1], input[3][2], input[3][3], input[3][0] };
46 const n1n2 = Half{ n1n2n3n0[0], n1n2n3n0[1] };46 const n1n2 = Half{ n1n2n3n0[0], n1n2n3n0[1] };
47 const n3n0 = Half{ n1n2n3n0[2], n1n2n3n0[3] };47 const n3n0 = Half{ n1n2n3n0[2], n1n2n3n0[3] };
...@@ -203,7 +203,7 @@ fn SalsaNonVecImpl(comptime rounds: comptime_int) type {...@@ -203,7 +203,7 @@ fn SalsaNonVecImpl(comptime rounds: comptime_int) type {
203 d: u6,203 d: u6,
204 };204 };
205205
206 inline fn Rp(a: usize, b: usize, c: usize, d: u6) QuarterRound {206 fn Rp(a: usize, b: usize, c: usize, d: u6) QuarterRound {
207 return QuarterRound{207 return QuarterRound{
208 .a = a,208 .a = a,
209 .b = b,209 .b = b,
...@@ -212,7 +212,7 @@ fn SalsaNonVecImpl(comptime rounds: comptime_int) type {...@@ -212,7 +212,7 @@ fn SalsaNonVecImpl(comptime rounds: comptime_int) type {
212 };212 };
213 }213 }
214214
215 inline fn salsaCore(x: *BlockVec, input: BlockVec, comptime feedback: bool) void {215 fn salsaCore(x: *BlockVec, input: BlockVec, comptime feedback: bool) void {
216 const arx_steps = comptime [_]QuarterRound{216 const arx_steps = comptime [_]QuarterRound{
217 Rp(4, 0, 12, 7), Rp(8, 4, 0, 9), Rp(12, 8, 4, 13), Rp(0, 12, 8, 18),217 Rp(4, 0, 12, 7), Rp(8, 4, 0, 9), Rp(12, 8, 4, 13), Rp(0, 12, 8, 18),
218 Rp(9, 5, 1, 7), Rp(13, 9, 5, 9), Rp(1, 13, 9, 13), Rp(5, 1, 13, 18),218 Rp(9, 5, 1, 7), Rp(13, 9, 5, 9), Rp(1, 13, 9, 13), Rp(5, 1, 13, 18),
lib/std/crypto/timing_safe.zig+1-1
...@@ -265,7 +265,7 @@ test classify {...@@ -265,7 +265,7 @@ test classify {
265265
266 // Comparing secret data must be done in constant time. The result266 // Comparing secret data must be done in constant time. The result
267 // is going to be considered as secret as well.267 // is going to be considered as secret as well.
268 var res = std.crypto.utils.timingSafeEql([32]u8, out, secret);268 var res = std.crypto.timing_safe.eql([32]u8, out, secret);
269269
270 // If we want to make a conditional jump based on a secret,270 // If we want to make a conditional jump based on a secret,
271 // it has to be declassified.271 // it has to be declassified.
lib/std/crypto/tls.zig+3-3
...@@ -593,11 +593,11 @@ pub fn hmac(comptime Hmac: type, message: []const u8, key: [Hmac.key_length]u8)...@@ -593,11 +593,11 @@ pub fn hmac(comptime Hmac: type, message: []const u8, key: [Hmac.key_length]u8)
593 return result;593 return result;
594}594}
595595
596pub inline fn extension(et: ExtensionType, bytes: anytype) [2 + 2 + bytes.len]u8 {596pub fn extension(et: ExtensionType, bytes: anytype) [2 + 2 + bytes.len]u8 {
597 return int(u16, @intFromEnum(et)) ++ array(u16, u8, bytes);597 return int(u16, @intFromEnum(et)) ++ array(u16, u8, bytes);
598}598}
599599
600pub inline fn array(600pub fn array(
601 comptime Len: type,601 comptime Len: type,
602 comptime Elem: type,602 comptime Elem: type,
603 elems: anytype,603 elems: anytype,
...@@ -622,7 +622,7 @@ pub inline fn array(...@@ -622,7 +622,7 @@ pub inline fn array(
622 return arr;622 return arr;
623}623}
624624
625pub inline fn int(comptime Int: type, val: Int) [@divExact(@bitSizeOf(Int), 8)]u8 {625pub fn int(comptime Int: type, val: Int) [@divExact(@bitSizeOf(Int), 8)]u8 {
626 var arr: [@divExact(@bitSizeOf(Int), 8)]u8 = undefined;626 var arr: [@divExact(@bitSizeOf(Int), 8)]u8 = undefined;
627 std.mem.writeInt(Int, &arr, val, .big);627 std.mem.writeInt(Int, &arr, val, .big);
628 return arr;628 return arr;
lib/std/crypto/tls/Client.zig+1-1
...@@ -1235,7 +1235,7 @@ fn logSecrets(w: *Writer, context: anytype, secrets: anytype) void {...@@ -1235,7 +1235,7 @@ fn logSecrets(w: *Writer, context: anytype, secrets: anytype) void {
1235 }) catch {};1235 }) catch {};
1236}1236}
12371237
1238inline fn big(x: anytype) @TypeOf(x) {1238fn big(x: anytype) @TypeOf(x) {
1239 return switch (native_endian) {1239 return switch (native_endian) {
1240 .big => x,1240 .big => x,
1241 .little => @byteSwap(x),1241 .little => @byteSwap(x),
lib/std/debug.zig+2-7
...@@ -231,10 +231,6 @@ pub fn print(comptime fmt: []const u8, args: anytype) void {...@@ -231,10 +231,6 @@ pub fn print(comptime fmt: []const u8, args: anytype) void {
231 nosuspend w.print(fmt, args) catch return;231 nosuspend w.print(fmt, args) catch return;
232}232}
233233
234pub fn getStderrMutex() *std.Thread.Mutex {
235 @compileError("deprecated. call std.debug.lockStdErr() and std.debug.unlockStdErr() instead which will integrate properly with std.Progress");
236}
237
238/// TODO multithreaded awareness234/// TODO multithreaded awareness
239var self_debug_info: ?SelfInfo = null;235var self_debug_info: ?SelfInfo = null;
240236
...@@ -658,9 +654,8 @@ pub fn defaultPanic(...@@ -658,9 +654,8 @@ pub fn defaultPanic(
658654
659 if (uefi.system_table.boot_services) |bs| {655 if (uefi.system_table.boot_services) |bs| {
660 // ExitData buffer must be allocated using boot_services.allocatePool (spec: page 220)656 // ExitData buffer must be allocated using boot_services.allocatePool (spec: page 220)
661 const exit_data: []u16 = uefi.raw_pool_allocator.alloc(u16, exit_msg.len + 1) catch @trap();657 const exit_data = uefi.raw_pool_allocator.dupeZ(u16, exit_msg) catch @trap();
662 @memcpy(exit_data, exit_msg[0..exit_data.len]); // Includes null terminator.658 bs.exit(uefi.handle, .aborted, exit_data) catch {};
663 _ = bs.exit(uefi.handle, .aborted, exit_data.len, exit_data.ptr);
664 }659 }
665 @trap();660 @trap();
666 },661 },
lib/std/fs.zig-10
...@@ -35,8 +35,6 @@ pub const realpathW = posix.realpathW;...@@ -35,8 +35,6 @@ pub const realpathW = posix.realpathW;
35pub const getAppDataDir = @import("fs/get_app_data_dir.zig").getAppDataDir;35pub const getAppDataDir = @import("fs/get_app_data_dir.zig").getAppDataDir;
36pub const GetAppDataDirError = @import("fs/get_app_data_dir.zig").GetAppDataDirError;36pub const GetAppDataDirError = @import("fs/get_app_data_dir.zig").GetAppDataDirError;
3737
38pub const MAX_PATH_BYTES = @compileError("deprecated; renamed to max_path_bytes");
39
40/// The maximum length of a file path that the operating system will accept.38/// The maximum length of a file path that the operating system will accept.
41///39///
42/// Paths, including those returned from file system operations, may be longer40/// Paths, including those returned from file system operations, may be longer
...@@ -90,9 +88,6 @@ pub const max_name_bytes = switch (native_os) {...@@ -90,9 +88,6 @@ pub const max_name_bytes = switch (native_os) {
90 @compileError("NAME_MAX not implemented for " ++ @tagName(native_os)),88 @compileError("NAME_MAX not implemented for " ++ @tagName(native_os)),
91};89};
9290
93/// Deprecated: use `max_name_bytes`
94pub const MAX_NAME_BYTES = max_name_bytes;
95
96pub const base64_alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_".*;91pub const base64_alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_".*;
9792
98/// Base64 encoder, replacing the standard `+/` with `-_` so that it can be used in a file name on any filesystem.93/// Base64 encoder, replacing the standard `+/` with `-_` so that it can be used in a file name on any filesystem.
...@@ -101,11 +96,6 @@ pub const base64_encoder = base64.Base64Encoder.init(base64_alphabet, null);...@@ -101,11 +96,6 @@ pub const base64_encoder = base64.Base64Encoder.init(base64_alphabet, null);
101/// Base64 decoder, replacing the standard `+/` with `-_` so that it can be used in a file name on any filesystem.96/// Base64 decoder, replacing the standard `+/` with `-_` so that it can be used in a file name on any filesystem.
102pub const base64_decoder = base64.Base64Decoder.init(base64_alphabet, null);97pub const base64_decoder = base64.Base64Decoder.init(base64_alphabet, null);
10398
104/// Deprecated. Use `cwd().atomicSymLink()` instead.
105pub fn atomicSymLink(_: Allocator, existing_path: []const u8, new_path: []const u8) !void {
106 try cwd().atomicSymLink(existing_path, new_path, .{});
107}
108
109/// Same as `Dir.updateFile`, except asserts that both `source_path` and `dest_path`99/// Same as `Dir.updateFile`, except asserts that both `source_path` and `dest_path`
110/// are absolute. See `Dir.updateFile` for a function that operates on both100/// are absolute. See `Dir.updateFile` for a function that operates on both
111/// absolute and relative paths.101/// absolute and relative paths.
lib/std/fs/Dir.zig-5
...@@ -1402,9 +1402,6 @@ pub fn setAsCwd(self: Dir) !void {...@@ -1402,9 +1402,6 @@ pub fn setAsCwd(self: Dir) !void {
1402 try posix.fchdir(self.fd);1402 try posix.fchdir(self.fd);
1403}1403}
14041404
1405/// Deprecated: use `OpenOptions`
1406pub const OpenDirOptions = OpenOptions;
1407
1408pub const OpenOptions = struct {1405pub const OpenOptions = struct {
1409 /// `true` means the opened directory can be used as the `Dir` parameter1406 /// `true` means the opened directory can be used as the `Dir` parameter
1410 /// for functions which operate based on an open directory handle. When `false`,1407 /// for functions which operate based on an open directory handle. When `false`,
...@@ -2511,8 +2508,6 @@ pub fn writeFile(self: Dir, options: WriteFileOptions) WriteFileError!void {...@@ -2511,8 +2508,6 @@ pub fn writeFile(self: Dir, options: WriteFileOptions) WriteFileError!void {
2511 try file.writeAll(options.data);2508 try file.writeAll(options.data);
2512}2509}
25132510
2514pub const writeFile2 = @compileError("deprecated; renamed to writeFile");
2515
2516pub const AccessError = posix.AccessError;2511pub const AccessError = posix.AccessError;
25172512
2518/// Test accessing `sub_path`.2513/// Test accessing `sub_path`.
lib/std/fs/File.zig+2-1
...@@ -1045,7 +1045,7 @@ pub const Reader = struct {...@@ -1045,7 +1045,7 @@ pub const Reader = struct {
1045 r.pos = offset;1045 r.pos = offset;
1046 },1046 },
1047 .streaming, .streaming_reading => {1047 .streaming, .streaming_reading => {
1048 if (offset >= r.pos) return Reader.seekBy(r, offset - r.pos);1048 if (offset >= r.pos) return Reader.seekBy(r, @intCast(offset - r.pos));
1049 if (r.seek_err) |err| return err;1049 if (r.seek_err) |err| return err;
1050 posix.lseek_SET(r.file.handle, offset) catch |err| {1050 posix.lseek_SET(r.file.handle, offset) catch |err| {
1051 r.seek_err = err;1051 r.seek_err = err;
...@@ -1333,6 +1333,7 @@ pub const Writer = struct {...@@ -1333,6 +1333,7 @@ pub const Writer = struct {
1333 .file = w.file,1333 .file = w.file,
1334 .mode = w.mode,1334 .mode = w.mode,
1335 .pos = w.pos,1335 .pos = w.pos,
1336 .interface = Reader.initInterface(w.interface.buffer),
1336 .seek_err = w.seek_err,1337 .seek_err = w.seek_err,
1337 };1338 };
1338 }1339 }
lib/std/hash.zig+1-2
...@@ -80,9 +80,8 @@ fn uint16(input: u16) u16 {...@@ -80,9 +80,8 @@ fn uint16(input: u16) u16 {
80 return x;80 return x;
81}81}
8282
83/// DEPRECATED: use std.hash.int()
84/// Source: https://github.com/skeeto/hash-prospector83/// Source: https://github.com/skeeto/hash-prospector
85pub fn uint32(input: u32) u32 {84fn uint32(input: u32) u32 {
86 var x: u32 = input;85 var x: u32 = input;
87 x = (x ^ (x >> 17)) *% 0xed5ad4bb;86 x = (x ^ (x >> 17)) *% 0xed5ad4bb;
88 x = (x ^ (x >> 11)) *% 0xac4c1b51;87 x = (x ^ (x >> 11)) *% 0xac4c1b51;
lib/std/http/test.zig+6-3
...@@ -150,7 +150,8 @@ test "HTTP server handles a chunked transfer coding request" {...@@ -150,7 +150,8 @@ test "HTTP server handles a chunked transfer coding request" {
150 "content-type: text/plain\r\n" ++150 "content-type: text/plain\r\n" ++
151 "\r\n" ++151 "\r\n" ++
152 "message from server!\n";152 "message from server!\n";
153 var stream_reader = stream.reader(&.{});153 var tiny_buffer: [1]u8 = undefined; // allows allocRemaining to detect limit exceeded
154 var stream_reader = stream.reader(&tiny_buffer);
154 const response = try stream_reader.interface().allocRemaining(gpa, .limited(expected_response.len));155 const response = try stream_reader.interface().allocRemaining(gpa, .limited(expected_response.len));
155 defer gpa.free(response);156 defer gpa.free(response);
156 try expectEqualStrings(expected_response, response);157 try expectEqualStrings(expected_response, response);
...@@ -288,7 +289,8 @@ test "Server.Request.respondStreaming non-chunked, unknown content-length" {...@@ -288,7 +289,8 @@ test "Server.Request.respondStreaming non-chunked, unknown content-length" {
288 var stream_writer = stream.writer(&.{});289 var stream_writer = stream.writer(&.{});
289 try stream_writer.interface.writeAll(request_bytes);290 try stream_writer.interface.writeAll(request_bytes);
290291
291 var stream_reader = stream.reader(&.{});292 var tiny_buffer: [1]u8 = undefined; // allows allocRemaining to detect limit exceeded
293 var stream_reader = stream.reader(&tiny_buffer);
292 const response = try stream_reader.interface().allocRemaining(gpa, .limited(8192));294 const response = try stream_reader.interface().allocRemaining(gpa, .limited(8192));
293 defer gpa.free(response);295 defer gpa.free(response);
294296
...@@ -358,7 +360,8 @@ test "receiving arbitrary http headers from the client" {...@@ -358,7 +360,8 @@ test "receiving arbitrary http headers from the client" {
358 var stream_writer = stream.writer(&.{});360 var stream_writer = stream.writer(&.{});
359 try stream_writer.interface.writeAll(request_bytes);361 try stream_writer.interface.writeAll(request_bytes);
360362
361 var stream_reader = stream.reader(&.{});363 var tiny_buffer: [1]u8 = undefined; // allows allocRemaining to detect limit exceeded
364 var stream_reader = stream.reader(&tiny_buffer);
362 const response = try stream_reader.interface().allocRemaining(gpa, .limited(8192));365 const response = try stream_reader.interface().allocRemaining(gpa, .limited(8192));
363 defer gpa.free(response);366 defer gpa.free(response);
364367
lib/std/math/big/int.zig-6
...@@ -2222,9 +2222,6 @@ pub const Const = struct {...@@ -2222,9 +2222,6 @@ pub const Const = struct {
2222 TargetTooSmall,2222 TargetTooSmall,
2223 };2223 };
22242224
2225 /// Deprecated; use `toInt`.
2226 pub const to = toInt;
2227
2228 /// Convert `self` to `Int`.2225 /// Convert `self` to `Int`.
2229 ///2226 ///
2230 /// Returns an error if self cannot be narrowed into the requested type without truncation.2227 /// Returns an error if self cannot be narrowed into the requested type without truncation.
...@@ -2855,9 +2852,6 @@ pub const Managed = struct {...@@ -2855,9 +2852,6 @@ pub const Managed = struct {
28552852
2856 pub const ConvertError = Const.ConvertError;2853 pub const ConvertError = Const.ConvertError;
28572854
2858 /// Deprecated; use `toInt`.
2859 pub const to = toInt;
2860
2861 /// Convert `self` to `Int`.2855 /// Convert `self` to `Int`.
2862 ///2856 ///
2863 /// Returns an error if self cannot be narrowed into the requested type without truncation.2857 /// Returns an error if self cannot be narrowed into the requested type without truncation.
lib/std/math/big/int_test.zig+1-1
...@@ -688,7 +688,7 @@ test "string set base 36" {...@@ -688,7 +688,7 @@ test "string set base 36" {
688 defer a.deinit();688 defer a.deinit();
689689
690 try a.setString(36, "fifvthrv1mzt79ez9");690 try a.setString(36, "fifvthrv1mzt79ez9");
691 try testing.expectEqual(123456789123456789123456789, try a.to(u128));691 try testing.expectEqual(123456789123456789123456789, try a.toInt(u128));
692}692}
693693
694test "string set bad char error" {694test "string set bad char error" {
lib/std/mem.zig-6
...@@ -2258,8 +2258,6 @@ test byteSwapAllFields {...@@ -2258,8 +2258,6 @@ test byteSwapAllFields {
2258 }, k);2258 }, k);
2259}2259}
22602260
2261pub const tokenize = @compileError("deprecated; use tokenizeAny, tokenizeSequence, or tokenizeScalar");
2262
2263/// Returns an iterator that iterates over the slices of `buffer` that are not2261/// Returns an iterator that iterates over the slices of `buffer` that are not
2264/// any of the items in `delimiters`.2262/// any of the items in `delimiters`.
2265///2263///
...@@ -2458,8 +2456,6 @@ test "tokenize (reset)" {...@@ -2458,8 +2456,6 @@ test "tokenize (reset)" {
2458 }2456 }
2459}2457}
24602458
2461pub const split = @compileError("deprecated; use splitSequence, splitAny, or splitScalar");
2462
2463/// Returns an iterator that iterates over the slices of `buffer` that2459/// Returns an iterator that iterates over the slices of `buffer` that
2464/// are separated by the byte sequence in `delimiter`.2460/// are separated by the byte sequence in `delimiter`.
2465///2461///
...@@ -2659,8 +2655,6 @@ test "split (reset)" {...@@ -2659,8 +2655,6 @@ test "split (reset)" {
2659 }2655 }
2660}2656}
26612657
2662pub const splitBackwards = @compileError("deprecated; use splitBackwardsSequence, splitBackwardsAny, or splitBackwardsScalar");
2663
2664/// Returns an iterator that iterates backwards over the slices of `buffer` that2658/// Returns an iterator that iterates backwards over the slices of `buffer` that
2665/// are separated by the sequence in `delimiter`.2659/// are separated by the sequence in `delimiter`.
2666///2660///
lib/std/meta.zig-23
...@@ -418,29 +418,6 @@ test fieldInfo {...@@ -418,29 +418,6 @@ test fieldInfo {
418 try testing.expect(comptime uf.type == u8);418 try testing.expect(comptime uf.type == u8);
419}419}
420420
421/// Deprecated: use @FieldType
422pub fn FieldType(comptime T: type, comptime field: FieldEnum(T)) type {
423 return @FieldType(T, @tagName(field));
424}
425
426test FieldType {
427 const S = struct {
428 a: u8,
429 b: u16,
430 };
431
432 const U = union {
433 c: u32,
434 d: *const u8,
435 };
436
437 try testing.expect(FieldType(S, .a) == u8);
438 try testing.expect(FieldType(S, .b) == u16);
439
440 try testing.expect(FieldType(U, .c) == u32);
441 try testing.expect(FieldType(U, .d) == *const u8);
442}
443
444pub fn fieldNames(comptime T: type) *const [fields(T).len][:0]const u8 {421pub fn fieldNames(comptime T: type) *const [fields(T).len][:0]const u8 {
445 return comptime blk: {422 return comptime blk: {
446 const fieldInfos = fields(T);423 const fieldInfos = fields(T);
lib/std/net.zig+162-144
...@@ -19,6 +19,7 @@ const File = std.fs.File;...@@ -19,6 +19,7 @@ const File = std.fs.File;
19// first release to support them.19// first release to support them.
20pub const has_unix_sockets = switch (native_os) {20pub const has_unix_sockets = switch (native_os) {
21 .windows => builtin.os.version_range.windows.isAtLeast(.win10_rs4) orelse false,21 .windows => builtin.os.version_range.windows.isAtLeast(.win10_rs4) orelse false,
22 .wasi => false,
22 else => true,23 else => true,
23};24};
2425
...@@ -217,8 +218,6 @@ pub const Address = extern union {...@@ -217,8 +218,6 @@ pub const Address = extern union {
217 /// Sets SO_REUSEADDR and SO_REUSEPORT on POSIX.218 /// Sets SO_REUSEADDR and SO_REUSEPORT on POSIX.
218 /// Sets SO_REUSEADDR on Windows, which is roughly equivalent.219 /// Sets SO_REUSEADDR on Windows, which is roughly equivalent.
219 reuse_address: bool = false,220 reuse_address: bool = false,
220 /// Deprecated. Does the same thing as reuse_address.
221 reuse_port: bool = false,
222 force_nonblocking: bool = false,221 force_nonblocking: bool = false,
223 };222 };
224223
...@@ -235,7 +234,7 @@ pub const Address = extern union {...@@ -235,7 +234,7 @@ pub const Address = extern union {
235 };234 };
236 errdefer s.stream.close();235 errdefer s.stream.close();
237236
238 if (options.reuse_address or options.reuse_port) {237 if (options.reuse_address) {
239 try posix.setsockopt(238 try posix.setsockopt(
240 sockfd,239 sockfd,
241 posix.SOL.SOCKET,240 posix.SOL.SOCKET,
...@@ -869,7 +868,7 @@ pub fn getAddressList(gpa: Allocator, name: []const u8, port: u16) GetAddressLis...@@ -869,7 +868,7 @@ pub fn getAddressList(gpa: Allocator, name: []const u8, port: u16) GetAddressLis
869 const name_c = try gpa.dupeZ(u8, name);868 const name_c = try gpa.dupeZ(u8, name);
870 defer gpa.free(name_c);869 defer gpa.free(name_c);
871870
872 const port_c = try std.fmt.allocPrintSentinel(gpa, "{}", .{port}, 0);871 const port_c = try std.fmt.allocPrintSentinel(gpa, "{d}", .{port}, 0);
873 defer gpa.free(port_c);872 defer gpa.free(port_c);
874873
875 const ws2_32 = windows.ws2_32;874 const ws2_32 = windows.ws2_32;
...@@ -1080,7 +1079,7 @@ fn linuxLookupName(...@@ -1080,7 +1079,7 @@ fn linuxLookupName(
1080 }1079 }
1081 } else {1080 } else {
1082 try canon.resize(gpa, 0);1081 try canon.resize(gpa, 0);
1083 try addrs.ensureUnusedCapacity(gpa, 1);1082 try addrs.ensureUnusedCapacity(gpa, 2);
1084 linuxLookupNameFromNull(addrs, family, flags, port);1083 linuxLookupNameFromNull(addrs, family, flags, port);
1085 }1084 }
1086 if (addrs.items.len == 0) return error.UnknownHostName;1085 if (addrs.items.len == 0) return error.UnknownHostName;
...@@ -1355,7 +1354,7 @@ fn parseHosts(...@@ -1355,7 +1354,7 @@ fn parseHosts(
1355 const line = br.takeDelimiterExclusive('\n') catch |err| switch (err) {1354 const line = br.takeDelimiterExclusive('\n') catch |err| switch (err) {
1356 error.StreamTooLong => {1355 error.StreamTooLong => {
1357 // Skip lines that are too long.1356 // Skip lines that are too long.
1358 br.discardDelimiterInclusive('\n') catch |e| switch (e) {1357 _ = br.discardDelimiterInclusive('\n') catch |e| switch (e) {
1359 error.EndOfStream => break,1358 error.EndOfStream => break,
1360 error.ReadFailed => return error.ReadFailed,1359 error.ReadFailed => return error.ReadFailed,
1361 };1360 };
...@@ -1398,6 +1397,25 @@ fn parseHosts(...@@ -1398,6 +1397,25 @@ fn parseHosts(
1398 }1397 }
1399}1398}
14001399
1400test parseHosts {
1401 if (builtin.os.tag == .wasi) {
1402 // TODO parsing addresses should not have OS dependencies
1403 return error.SkipZigTest;
1404 }
1405 var reader: std.io.Reader = .fixed(
1406 \\127.0.0.1 localhost
1407 \\::1 localhost
1408 \\127.0.0.2 abcd
1409 );
1410 var addrs: ArrayList(LookupAddr) = .empty;
1411 defer addrs.deinit(std.testing.allocator);
1412 var canon: ArrayList(u8) = .empty;
1413 defer canon.deinit(std.testing.allocator);
1414 try parseHosts(std.testing.allocator, &addrs, &canon, "abcd", posix.AF.UNSPEC, 1234, &reader);
1415 try std.testing.expectEqual(1, addrs.items.len);
1416 try std.testing.expectFmt("127.0.0.2:1234", "{f}", .{addrs.items[0].addr});
1417}
1418
1401pub fn isValidHostName(hostname: []const u8) bool {1419pub fn isValidHostName(hostname: []const u8) bool {
1402 if (hostname.len >= 254) return false;1420 if (hostname.len >= 254) return false;
1403 if (!std.unicode.utf8ValidateSlice(hostname)) return false;1421 if (!std.unicode.utf8ValidateSlice(hostname)) return false;
...@@ -1562,9 +1580,12 @@ const ResolvConf = struct {...@@ -1562,9 +1580,12 @@ const ResolvConf = struct {
1562 };1580 };
1563 }1581 }
15641582
1565 fn parse(rc: *ResolvConf, br: *io.Reader) !void {1583 const Directive = enum { options, nameserver, domain, search };
1584 const Option = enum { ndots, attempts, timeout };
1585
1586 fn parse(rc: *ResolvConf, reader: *io.Reader) !void {
1566 const gpa = rc.gpa;1587 const gpa = rc.gpa;
1567 while (br.takeSentinel('\n')) |line_with_comment| {1588 while (reader.takeSentinel('\n')) |line_with_comment| {
1568 const line = line: {1589 const line = line: {
1569 var split = mem.splitScalar(u8, line_with_comment, '#');1590 var split = mem.splitScalar(u8, line_with_comment, '#');
1570 break :line split.first();1591 break :line split.first();
...@@ -1572,8 +1593,8 @@ const ResolvConf = struct {...@@ -1572,8 +1593,8 @@ const ResolvConf = struct {
1572 var line_it = mem.tokenizeAny(u8, line, " \t");1593 var line_it = mem.tokenizeAny(u8, line, " \t");
15731594
1574 const token = line_it.next() orelse continue;1595 const token = line_it.next() orelse continue;
1575 if (mem.eql(u8, token, "options")) {1596 switch (std.meta.stringToEnum(Directive, token) orelse continue) {
1576 while (line_it.next()) |sub_tok| {1597 .options => while (line_it.next()) |sub_tok| {
1577 var colon_it = mem.splitScalar(u8, sub_tok, ':');1598 var colon_it = mem.splitScalar(u8, sub_tok, ':');
1578 const name = colon_it.first();1599 const name = colon_it.first();
1579 const value_txt = colon_it.next() orelse continue;1600 const value_txt = colon_it.next() orelse continue;
...@@ -1581,22 +1602,25 @@ const ResolvConf = struct {...@@ -1581,22 +1602,25 @@ const ResolvConf = struct {
1581 error.Overflow => 255,1602 error.Overflow => 255,
1582 error.InvalidCharacter => continue,1603 error.InvalidCharacter => continue,
1583 };1604 };
1584 if (mem.eql(u8, name, "ndots")) {1605 switch (std.meta.stringToEnum(Option, name) orelse continue) {
1585 rc.ndots = @min(value, 15);1606 .ndots => rc.ndots = @min(value, 15),
1586 } else if (mem.eql(u8, name, "attempts")) {1607 .attempts => rc.attempts = @min(value, 10),
1587 rc.attempts = @min(value, 10);1608 .timeout => rc.timeout = @min(value, 60),
1588 } else if (mem.eql(u8, name, "timeout")) {
1589 rc.timeout = @min(value, 60);
1590 }1609 }
1591 }1610 },
1592 } else if (mem.eql(u8, token, "nameserver")) {1611 .nameserver => {
1593 const ip_txt = line_it.next() orelse continue;1612 const ip_txt = line_it.next() orelse continue;
1594 try linuxLookupNameFromNumericUnspec(gpa, &rc.ns, ip_txt, 53);1613 try linuxLookupNameFromNumericUnspec(gpa, &rc.ns, ip_txt, 53);
1595 } else if (mem.eql(u8, token, "domain") or mem.eql(u8, token, "search")) {1614 },
1596 rc.search.items.len = 0;1615 .domain, .search => {
1597 try rc.search.appendSlice(gpa, line_it.rest());1616 rc.search.items.len = 0;
1617 try rc.search.appendSlice(gpa, line_it.rest());
1618 },
1598 }1619 }
1599 } else |err| return err;1620 } else |err| switch (err) {
1621 error.EndOfStream => if (reader.bufferedLen() != 0) return error.EndOfStream,
1622 else => |e| return e,
1623 }
16001624
1601 if (rc.ns.items.len == 0) {1625 if (rc.ns.items.len == 0) {
1602 return linuxLookupNameFromNumericUnspec(gpa, &rc.ns, "127.0.0.1", 53);1626 return linuxLookupNameFromNumericUnspec(gpa, &rc.ns, "127.0.0.1", 53);
...@@ -1849,9 +1873,15 @@ pub const Stream = struct {...@@ -1849,9 +1873,15 @@ pub const Stream = struct {
1849 }1873 }
1850 }1874 }
18511875
1852 const ReadError = posix.ReadError;1876 pub const ReadError = posix.ReadError || error{
1877 SocketNotBound,
1878 MessageTooBig,
1879 NetworkSubsystemFailed,
1880 ConnectionResetByPeer,
1881 SocketNotConnected,
1882 };
18531883
1854 const WriteError = posix.SendMsgError || error{1884 pub const WriteError = posix.SendMsgError || error{
1855 ConnectionResetByPeer,1885 ConnectionResetByPeer,
1856 SocketNotBound,1886 SocketNotBound,
1857 MessageTooBig,1887 MessageTooBig,
...@@ -1863,11 +1893,12 @@ pub const Stream = struct {...@@ -1863,11 +1893,12 @@ pub const Stream = struct {
18631893
1864 pub const Reader = switch (native_os) {1894 pub const Reader = switch (native_os) {
1865 .windows => struct {1895 .windows => struct {
1866 /// Use `interface` to access portably.1896 /// Use `interface` for portable code.
1867 interface_state: io.Reader,1897 interface_state: io.Reader,
1868 /// Use `getStream` to access portably.1898 /// Use `getStream` for portable code.
1869 net_stream: Stream,1899 net_stream: Stream,
1870 err: ?Error = null,1900 /// Use `getError` for portable code.
1901 error_state: ?Error,
18711902
1872 pub const Error = ReadError;1903 pub const Error = ReadError;
18731904
...@@ -1875,6 +1906,10 @@ pub const Stream = struct {...@@ -1875,6 +1906,10 @@ pub const Stream = struct {
1875 return r.stream;1906 return r.stream;
1876 }1907 }
18771908
1909 pub fn getError(r: *const Reader) ?Error {
1910 return r.error_state;
1911 }
1912
1878 pub fn interface(r: *Reader) *io.Reader {1913 pub fn interface(r: *Reader) *io.Reader {
1879 return &r.interface_state;1914 return &r.interface_state;
1880 }1915 }
...@@ -1882,22 +1917,33 @@ pub const Stream = struct {...@@ -1882,22 +1917,33 @@ pub const Stream = struct {
1882 pub fn init(net_stream: Stream, buffer: []u8) Reader {1917 pub fn init(net_stream: Stream, buffer: []u8) Reader {
1883 return .{1918 return .{
1884 .interface_state = .{1919 .interface_state = .{
1885 .context = undefined,
1886 .vtable = &.{ .stream = stream },1920 .vtable = &.{ .stream = stream },
1887 .buffer = buffer,1921 .buffer = buffer,
1922 .seek = 0,
1923 .end = 0,
1888 },1924 },
1889 .net_stream = net_stream,1925 .net_stream = net_stream,
1926 .error_state = null,
1890 };1927 };
1891 }1928 }
18921929
1893 fn stream(io_r: *io.Reader, io_w: *io.Writer, limit: io.Limit) io.Reader.StreamError!usize {1930 fn stream(io_r: *io.Reader, io_w: *io.Writer, limit: io.Limit) io.Reader.StreamError!usize {
1894 const r: *Reader = @fieldParentPtr("interface", io_r);1931 const r: *Reader = @alignCast(@fieldParentPtr("interface_state", io_r));
1895 var iovecs: [max_buffers_len]windows.WSABUF = undefined;1932 var iovecs: [max_buffers_len]windows.ws2_32.WSABUF = undefined;
1896 const bufs = io_w.writableVectorWsa(&iovecs, limit);1933 const bufs = try io_w.writableVectorWsa(&iovecs, limit);
1897 assert(bufs[0].len > 0);1934 assert(bufs[0].len != 0);
1935 const n = streamBufs(r, bufs) catch |err| {
1936 r.error_state = err;
1937 return error.ReadFailed;
1938 };
1939 if (n == 0) return error.EndOfStream;
1940 return n;
1941 }
1942
1943 fn streamBufs(r: *Reader, bufs: []windows.ws2_32.WSABUF) Error!u32 {
1898 var n: u32 = undefined;1944 var n: u32 = undefined;
1899 var flags: u32 = 0;1945 var flags: u32 = 0;
1900 const rc = windows.ws2_32.WSARecvFrom(r.net_stream.handle, bufs.ptr, bufs.len, &n, &flags, null, null, null, null);1946 const rc = windows.ws2_32.WSARecvFrom(r.net_stream.handle, bufs.ptr, @intCast(bufs.len), &n, &flags, null, null, null, null);
1901 if (rc != 0) switch (windows.ws2_32.WSAGetLastError()) {1947 if (rc != 0) switch (windows.ws2_32.WSAGetLastError()) {
1902 .WSAECONNRESET => return error.ConnectionResetByPeer,1948 .WSAECONNRESET => return error.ConnectionResetByPeer,
1903 .WSAEFAULT => unreachable, // a pointer is not completely contained in user address space.1949 .WSAEFAULT => unreachable, // a pointer is not completely contained in user address space.
...@@ -1913,11 +1959,11 @@ pub const Stream = struct {...@@ -1913,11 +1959,11 @@ pub const Stream = struct {
1913 .WSA_OPERATION_ABORTED => unreachable, // not using overlapped I/O1959 .WSA_OPERATION_ABORTED => unreachable, // not using overlapped I/O
1914 else => |err| return windows.unexpectedWSAError(err),1960 else => |err| return windows.unexpectedWSAError(err),
1915 };1961 };
1916 if (n == 0) return error.EndOfStream;
1917 return n;1962 return n;
1918 }1963 }
1919 },1964 },
1920 else => struct {1965 else => struct {
1966 /// Use `getStream`, `interface`, and `getError` for portable code.
1921 file_reader: File.Reader,1967 file_reader: File.Reader,
19221968
1923 pub const Error = ReadError;1969 pub const Error = ReadError;
...@@ -1940,6 +1986,10 @@ pub const Stream = struct {...@@ -1940,6 +1986,10 @@ pub const Stream = struct {
1940 pub fn getStream(r: *const Reader) Stream {1986 pub fn getStream(r: *const Reader) Stream {
1941 return .{ .handle = r.file_reader.file.handle };1987 return .{ .handle = r.file_reader.file.handle };
1942 }1988 }
1989
1990 pub fn getError(r: *const Reader) ?Error {
1991 return r.file_reader.err;
1992 }
1943 },1993 },
1944 };1994 };
19451995
...@@ -1949,6 +1999,8 @@ pub const Stream = struct {...@@ -1949,6 +1999,8 @@ pub const Stream = struct {
1949 interface: io.Writer,1999 interface: io.Writer,
1950 /// Use `getStream` for cross-platform support.2000 /// Use `getStream` for cross-platform support.
1951 stream: Stream,2001 stream: Stream,
2002 /// This field is present on all systems.
2003 err: ?Error = null,
19522004
1953 pub const Error = WriteError;2005 pub const Error = WriteError;
19542006
...@@ -1966,43 +2018,39 @@ pub const Stream = struct {...@@ -1966,43 +2018,39 @@ pub const Stream = struct {
1966 return w.stream;2018 return w.stream;
1967 }2019 }
19682020
2021 fn addWsaBuf(v: []windows.ws2_32.WSABUF, i: *u32, bytes: []const u8) void {
2022 const cap = std.math.maxInt(u32);
2023 var remaining = bytes;
2024 while (remaining.len > cap) {
2025 if (v.len - i.* == 0) return;
2026 v[i.*] = .{ .buf = @constCast(remaining.ptr), .len = cap };
2027 i.* += 1;
2028 remaining = remaining[cap..];
2029 } else {
2030 @branchHint(.likely);
2031 if (v.len - i.* == 0) return;
2032 v[i.*] = .{ .buf = @constCast(remaining.ptr), .len = @intCast(remaining.len) };
2033 i.* += 1;
2034 }
2035 }
2036
1969 fn drain(io_w: *io.Writer, data: []const []const u8, splat: usize) io.Writer.Error!usize {2037 fn drain(io_w: *io.Writer, data: []const []const u8, splat: usize) io.Writer.Error!usize {
1970 const w: *Writer = @fieldParentPtr("interface", io_w);2038 const w: *Writer = @alignCast(@fieldParentPtr("interface", io_w));
1971 const buffered = io_w.buffered();2039 const buffered = io_w.buffered();
1972 comptime assert(native_os == .windows);2040 comptime assert(native_os == .windows);
1973 var iovecs: [max_buffers_len]windows.WSABUF = undefined;2041 var iovecs: [max_buffers_len]windows.ws2_32.WSABUF = undefined;
1974 var len: u32 = 0;2042 var len: u32 = 0;
1975 if (buffered.len != 0) {2043 addWsaBuf(&iovecs, &len, buffered);
1976 iovecs[len] = .{2044 for (data[0 .. data.len - 1]) |bytes| addWsaBuf(&iovecs, &len, bytes);
1977 .buf = buffered.ptr,
1978 .len = buffered.len,
1979 };
1980 len += 1;
1981 }
1982 for (data) |bytes| {
1983 if (bytes.len == 0) continue;
1984 iovecs[len] = .{
1985 .buf = bytes.ptr,
1986 .len = bytes.len,
1987 };
1988 len += 1;
1989 if (iovecs.len - len == 0) break;
1990 }
1991 if (len == 0) return 0;
1992 const pattern = data[data.len - 1];2045 const pattern = data[data.len - 1];
1993 switch (splat) {2046 if (iovecs.len - len != 0) switch (splat) {
1994 0 => if (iovecs[len - 1].buf == data[data.len - 1].ptr) {2047 0 => {},
1995 len -= 1;2048 1 => addWsaBuf(&iovecs, &len, pattern),
1996 },
1997 1 => {},
1998 else => switch (pattern.len) {2049 else => switch (pattern.len) {
1999 0 => {},2050 0 => {},
2000 1 => memset: {2051 1 => {
2001 // Replace the 1-byte buffer with a bigger one.
2002 if (iovecs[len - 1].buf == data[data.len - 1].ptr) len -= 1;
2003 if (iovecs.len - len == 0) break :memset;
2004 const splat_buffer_candidate = io_w.buffer[io_w.end..];2052 const splat_buffer_candidate = io_w.buffer[io_w.end..];
2005 var backup_buffer: [32]u8 = undefined;2053 var backup_buffer: [64]u8 = undefined;
2006 const splat_buffer = if (splat_buffer_candidate.len >= backup_buffer.len)2054 const splat_buffer = if (splat_buffer_candidate.len >= backup_buffer.len)
2007 splat_buffer_candidate2055 splat_buffer_candidate
2008 else2056 else
...@@ -2010,31 +2058,29 @@ pub const Stream = struct {...@@ -2010,31 +2058,29 @@ pub const Stream = struct {
2010 const memset_len = @min(splat_buffer.len, splat);2058 const memset_len = @min(splat_buffer.len, splat);
2011 const buf = splat_buffer[0..memset_len];2059 const buf = splat_buffer[0..memset_len];
2012 @memset(buf, pattern[0]);2060 @memset(buf, pattern[0]);
2013 iovecs[len] = .{ .buf = buf.ptr, .len = buf.len };2061 addWsaBuf(&iovecs, &len, buf);
2014 len += 1;
2015 var remaining_splat = splat - buf.len;2062 var remaining_splat = splat - buf.len;
2016 while (remaining_splat > splat_buffer.len and len < iovecs.len) {2063 while (remaining_splat > splat_buffer.len and len < iovecs.len) {
2017 iovecs[len] = .{ .buf = splat_buffer.ptr, .len = splat_buffer.len };2064 addWsaBuf(&iovecs, &len, splat_buffer);
2018 remaining_splat -= splat_buffer.len;2065 remaining_splat -= splat_buffer.len;
2019 len += 1;
2020 }
2021 if (remaining_splat > 0 and iovecs.len - len != 0) {
2022 iovecs[len] = .{ .buf = splat_buffer.ptr, .len = remaining_splat };
2023 len += 1;
2024 }2066 }
2067 addWsaBuf(&iovecs, &len, splat_buffer[0..remaining_splat]);
2025 },2068 },
2026 else => for (0..splat - 1) |_| {2069 else => for (0..@min(splat, iovecs.len - len)) |_| {
2027 if (iovecs.len - len == 0) break;2070 addWsaBuf(&iovecs, &len, pattern);
2028 iovecs[len] = .{
2029 .buf = pattern.ptr,
2030 .len = pattern.len,
2031 };
2032 len += 1;
2033 },2071 },
2034 },2072 },
2035 }2073 };
2074 const n = sendBufs(w.stream.handle, iovecs[0..len]) catch |err| {
2075 w.err = err;
2076 return error.WriteFailed;
2077 };
2078 return io_w.consume(n);
2079 }
2080
2081 fn sendBufs(handle: Stream.Handle, bufs: []windows.ws2_32.WSABUF) Error!u32 {
2036 var n: u32 = undefined;2082 var n: u32 = undefined;
2037 const rc = windows.ws2_32.WSASend(w.stream.handle, &iovecs, len, &n, 0, null, null);2083 const rc = windows.ws2_32.WSASend(handle, bufs.ptr, @intCast(bufs.len), &n, 0, null, null);
2038 if (rc == windows.ws2_32.SOCKET_ERROR) switch (windows.ws2_32.WSAGetLastError()) {2084 if (rc == windows.ws2_32.SOCKET_ERROR) switch (windows.ws2_32.WSAGetLastError()) {
2039 .WSAECONNABORTED => return error.ConnectionResetByPeer,2085 .WSAECONNABORTED => return error.ConnectionResetByPeer,
2040 .WSAECONNRESET => return error.ConnectionResetByPeer,2086 .WSAECONNRESET => return error.ConnectionResetByPeer,
...@@ -2055,7 +2101,7 @@ pub const Stream = struct {...@@ -2055,7 +2101,7 @@ pub const Stream = struct {
2055 .WSA_OPERATION_ABORTED => unreachable, // not using overlapped I/O2101 .WSA_OPERATION_ABORTED => unreachable, // not using overlapped I/O
2056 else => |err| return windows.unexpectedWSAError(err),2102 else => |err| return windows.unexpectedWSAError(err),
2057 };2103 };
2058 return io_w.consume(n);2104 return n;
2059 }2105 }
2060 },2106 },
2061 else => struct {2107 else => struct {
...@@ -2084,95 +2130,68 @@ pub const Stream = struct {...@@ -2084,95 +2130,68 @@ pub const Stream = struct {
2084 return .{ .handle = w.file_writer.file.handle };2130 return .{ .handle = w.file_writer.file.handle };
2085 }2131 }
20862132
2133 fn addBuf(v: []posix.iovec_const, i: *@FieldType(posix.msghdr_const, "iovlen"), bytes: []const u8) void {
2134 // OS checks ptr addr before length so zero length vectors must be omitted.
2135 if (bytes.len == 0) return;
2136 if (v.len - i.* == 0) return;
2137 v[i.*] = .{ .base = bytes.ptr, .len = bytes.len };
2138 i.* += 1;
2139 }
2140
2087 fn drain(io_w: *io.Writer, data: []const []const u8, splat: usize) io.Writer.Error!usize {2141 fn drain(io_w: *io.Writer, data: []const []const u8, splat: usize) io.Writer.Error!usize {
2088 const w: *Writer = @fieldParentPtr("interface", io_w);2142 const w: *Writer = @alignCast(@fieldParentPtr("interface", io_w));
2089 const buffered = io_w.buffered();2143 const buffered = io_w.buffered();
2090 var iovecs: [max_buffers_len]std.posix.iovec_const = undefined;2144 var iovecs: [max_buffers_len]posix.iovec_const = undefined;
2091 var msg: posix.msghdr_const = msg: {2145 var msg: posix.msghdr_const = .{
2092 var i: usize = 0;2146 .name = null,
2093 if (buffered.len != 0) {2147 .namelen = 0,
2094 iovecs[i] = .{2148 .iov = &iovecs,
2095 .base = buffered.ptr,2149 .iovlen = 0,
2096 .len = buffered.len,2150 .control = null,
2097 };2151 .controllen = 0,
2098 i += 1;2152 .flags = 0,
2099 }
2100 for (data) |bytes| {
2101 // OS checks ptr addr before length so zero length vectors must be omitted.
2102 if (bytes.len == 0) continue;
2103 iovecs[i] = .{
2104 .base = bytes.ptr,
2105 .len = bytes.len,
2106 };
2107 i += 1;
2108 if (iovecs.len - i == 0) break;
2109 }
2110 break :msg .{
2111 .name = null,
2112 .namelen = 0,
2113 .iov = &iovecs,
2114 .iovlen = i,
2115 .control = null,
2116 .controllen = 0,
2117 .flags = 0,
2118 };
2119 };2153 };
2120 if (msg.iovlen == 0) return 0;2154 addBuf(&iovecs, &msg.iovlen, buffered);
2155 for (data[0 .. data.len - 1]) |bytes| addBuf(&iovecs, &msg.iovlen, bytes);
2121 const pattern = data[data.len - 1];2156 const pattern = data[data.len - 1];
2122 switch (splat) {2157 if (iovecs.len - msg.iovlen != 0) switch (splat) {
2123 0 => if (iovecs[msg.iovlen - 1].base == data[data.len - 1].ptr) {2158 0 => {},
2124 msg.iovlen -= 1;2159 1 => addBuf(&iovecs, &msg.iovlen, pattern),
2125 },
2126 1 => {},
2127 else => switch (pattern.len) {2160 else => switch (pattern.len) {
2128 0 => {},2161 0 => {},
2129 1 => memset: {2162 1 => {
2130 // Replace the 1-byte buffer with a bigger one.
2131 if (iovecs[msg.iovlen - 1].base == data[data.len - 1].ptr) msg.iovlen -= 1;
2132 if (iovecs.len - msg.iovlen == 0) break :memset;
2133 const splat_buffer_candidate = io_w.buffer[io_w.end..];2163 const splat_buffer_candidate = io_w.buffer[io_w.end..];
2134 var backup_buffer: [32]u8 = undefined;2164 var backup_buffer: [64]u8 = undefined;
2135 const splat_buffer = if (splat_buffer_candidate.len >= backup_buffer.len)2165 const splat_buffer = if (splat_buffer_candidate.len >= backup_buffer.len)
2136 splat_buffer_candidate2166 splat_buffer_candidate
2137 else2167 else
2138 &backup_buffer;2168 &backup_buffer;
2139 if (splat_buffer.len == 0) break :memset;
2140 const memset_len = @min(splat_buffer.len, splat);2169 const memset_len = @min(splat_buffer.len, splat);
2141 const buf = splat_buffer[0..memset_len];2170 const buf = splat_buffer[0..memset_len];
2142 @memset(buf, pattern[0]);2171 @memset(buf, pattern[0]);
2143 iovecs[msg.iovlen] = .{ .base = buf.ptr, .len = buf.len };2172 addBuf(&iovecs, &msg.iovlen, buf);
2144 msg.iovlen += 1;
2145 var remaining_splat = splat - buf.len;2173 var remaining_splat = splat - buf.len;
2146 while (remaining_splat > splat_buffer.len and iovecs.len - msg.iovlen != 0) {2174 while (remaining_splat > splat_buffer.len and iovecs.len - msg.iovlen != 0) {
2147 assert(buf.len == splat_buffer.len);2175 assert(buf.len == splat_buffer.len);
2148 iovecs[msg.iovlen] = .{ .base = splat_buffer.ptr, .len = splat_buffer.len };2176 addBuf(&iovecs, &msg.iovlen, splat_buffer);
2149 msg.iovlen += 1;
2150 remaining_splat -= splat_buffer.len;2177 remaining_splat -= splat_buffer.len;
2151 }2178 }
2152 if (remaining_splat > 0 and iovecs.len - msg.iovlen != 0) {2179 addBuf(&iovecs, &msg.iovlen, splat_buffer[0..remaining_splat]);
2153 iovecs[msg.iovlen] = .{ .base = splat_buffer.ptr, .len = remaining_splat };
2154 msg.iovlen += 1;
2155 }
2156 },2180 },
2157 else => for (0..splat - 1) |_| {2181 else => for (0..@min(splat, iovecs.len - msg.iovlen)) |_| {
2158 if (iovecs.len - msg.iovlen == 0) break;2182 addBuf(&iovecs, &msg.iovlen, pattern);
2159 iovecs[msg.iovlen] = .{
2160 .base = pattern.ptr,
2161 .len = pattern.len,
2162 };
2163 msg.iovlen += 1;
2164 },2183 },
2165 },2184 },
2166 }2185 };
2167 const flags = posix.MSG.NOSIGNAL;2186 const flags = posix.MSG.NOSIGNAL;
2168 return io_w.consume(std.posix.sendmsg(w.file_writer.file.handle, &msg, flags) catch |err| {2187 return io_w.consume(posix.sendmsg(w.file_writer.file.handle, &msg, flags) catch |err| {
2169 w.err = err;2188 w.err = err;
2170 return error.WriteFailed;2189 return error.WriteFailed;
2171 });2190 });
2172 }2191 }
21732192
2174 fn sendFile(io_w: *io.Writer, file_reader: *File.Reader, limit: io.Limit) io.Writer.FileError!usize {2193 fn sendFile(io_w: *io.Writer, file_reader: *File.Reader, limit: io.Limit) io.Writer.FileError!usize {
2175 const w: *Writer = @fieldParentPtr("interface", io_w);2194 const w: *Writer = @alignCast(@fieldParentPtr("interface", io_w));
2176 const n = try w.file_writer.interface.sendFileHeader(io_w.buffered(), file_reader, limit);2195 const n = try w.file_writer.interface.sendFileHeader(io_w.buffered(), file_reader, limit);
2177 return io_w.consume(n);2196 return io_w.consume(n);
2178 }2197 }
...@@ -2188,7 +2207,6 @@ pub const Stream = struct {...@@ -2188,7 +2207,6 @@ pub const Stream = struct {
2188 }2207 }
21892208
2190 const max_buffers_len = 8;2209 const max_buffers_len = 8;
2191 const splat_buffer_len = 256;
2192};2210};
21932211
2194pub const Server = struct {2212pub const Server = struct {
lib/std/net/test.zig+12-8
...@@ -208,7 +208,8 @@ test "listen on a port, send bytes, receive bytes" {...@@ -208,7 +208,8 @@ test "listen on a port, send bytes, receive bytes" {
208 const socket = try net.tcpConnectToAddress(server_address);208 const socket = try net.tcpConnectToAddress(server_address);
209 defer socket.close();209 defer socket.close();
210210
211 _ = try socket.writer().writeAll("Hello world!");211 var stream_writer = socket.writer(&.{});
212 try stream_writer.interface.writeAll("Hello world!");
212 }213 }
213 };214 };
214215
...@@ -218,7 +219,8 @@ test "listen on a port, send bytes, receive bytes" {...@@ -218,7 +219,8 @@ test "listen on a port, send bytes, receive bytes" {
218 var client = try server.accept();219 var client = try server.accept();
219 defer client.stream.close();220 defer client.stream.close();
220 var buf: [16]u8 = undefined;221 var buf: [16]u8 = undefined;
221 const n = try client.stream.reader().read(&buf);222 var stream_reader = client.stream.reader(&.{});
223 const n = try stream_reader.interface().readSliceShort(&buf);
222224
223 try testing.expectEqual(@as(usize, 12), n);225 try testing.expectEqual(@as(usize, 12), n);
224 try testing.expectEqualSlices(u8, "Hello world!", buf[0..n]);226 try testing.expectEqualSlices(u8, "Hello world!", buf[0..n]);
...@@ -232,10 +234,10 @@ test "listen on an in use port" {...@@ -232,10 +234,10 @@ test "listen on an in use port" {
232234
233 const localhost = try net.Address.parseIp("127.0.0.1", 0);235 const localhost = try net.Address.parseIp("127.0.0.1", 0);
234236
235 var server1 = try localhost.listen(.{ .reuse_port = true });237 var server1 = try localhost.listen(.{ .reuse_address = true });
236 defer server1.deinit();238 defer server1.deinit();
237239
238 var server2 = try server1.listen_address.listen(.{ .reuse_port = true });240 var server2 = try server1.listen_address.listen(.{ .reuse_address = true });
239 defer server2.deinit();241 defer server2.deinit();
240}242}
241243
...@@ -299,7 +301,8 @@ test "listen on a unix socket, send bytes, receive bytes" {...@@ -299,7 +301,8 @@ test "listen on a unix socket, send bytes, receive bytes" {
299 const socket = try net.connectUnixSocket(path);301 const socket = try net.connectUnixSocket(path);
300 defer socket.close();302 defer socket.close();
301303
302 _ = try socket.writer().writeAll("Hello world!");304 var stream_writer = socket.writer(&.{});
305 try stream_writer.interface.writeAll("Hello world!");
303 }306 }
304 };307 };
305308
...@@ -309,13 +312,14 @@ test "listen on a unix socket, send bytes, receive bytes" {...@@ -309,13 +312,14 @@ test "listen on a unix socket, send bytes, receive bytes" {
309 var client = try server.accept();312 var client = try server.accept();
310 defer client.stream.close();313 defer client.stream.close();
311 var buf: [16]u8 = undefined;314 var buf: [16]u8 = undefined;
312 const n = try client.stream.reader().read(&buf);315 var stream_reader = client.stream.reader(&.{});
316 const n = try stream_reader.interface().readSliceShort(&buf);
313317
314 try testing.expectEqual(@as(usize, 12), n);318 try testing.expectEqual(@as(usize, 12), n);
315 try testing.expectEqualSlices(u8, "Hello world!", buf[0..n]);319 try testing.expectEqualSlices(u8, "Hello world!", buf[0..n]);
316}320}
317321
318test "listen on a unix socket with reuse_port option" {322test "listen on a unix socket with reuse_address option" {
319 if (!net.has_unix_sockets) return error.SkipZigTest;323 if (!net.has_unix_sockets) return error.SkipZigTest;
320 // Windows doesn't implement reuse port option.324 // Windows doesn't implement reuse port option.
321 if (builtin.os.tag == .windows) return error.SkipZigTest;325 if (builtin.os.tag == .windows) return error.SkipZigTest;
...@@ -326,7 +330,7 @@ test "listen on a unix socket with reuse_port option" {...@@ -326,7 +330,7 @@ test "listen on a unix socket with reuse_port option" {
326 const socket_addr = try net.Address.initUnix(socket_path);330 const socket_addr = try net.Address.initUnix(socket_path);
327 defer std.fs.cwd().deleteFile(socket_path) catch {};331 defer std.fs.cwd().deleteFile(socket_path) catch {};
328332
329 var server = try socket_addr.listen(.{ .reuse_port = true });333 var server = try socket_addr.listen(.{ .reuse_address = true });
330 server.deinit();334 server.deinit();
331}335}
332336
lib/std/os/uefi.zig+49-3
...@@ -24,9 +24,51 @@ pub var handle: Handle = undefined;...@@ -24,9 +24,51 @@ pub var handle: Handle = undefined;
24/// A pointer to the EFI System Table that is passed to the EFI image's entry point.24/// A pointer to the EFI System Table that is passed to the EFI image's entry point.
25pub var system_table: *tables.SystemTable = undefined;25pub var system_table: *tables.SystemTable = undefined;
2626
27/// UEFI's memory interfaces exclusively act on 4096-byte pages.
28pub const Page = [4096]u8;
29
27/// A handle to an event structure.30/// A handle to an event structure.
28pub const Event = *opaque {};31pub const Event = *opaque {};
2932
33pub const EventRegistration = *const opaque {};
34
35pub const EventType = packed struct(u32) {
36 lo_context: u8 = 0,
37 /// If an event of this type is not already in the signaled state, then
38 /// the event’s NotificationFunction will be queued at the event’s NotifyTpl
39 /// whenever the event is being waited on via EFI_BOOT_SERVICES.WaitForEvent()
40 /// or EFI_BOOT_SERVICES.CheckEvent() .
41 wait: bool = false,
42 /// The event’s NotifyFunction is queued whenever the event is signaled.
43 signal: bool = false,
44 hi_context: u20 = 0,
45 /// The event is allocated from runtime memory. If an event is to be signaled
46 /// after the call to EFI_BOOT_SERVICES.ExitBootServices() the event’s data
47 /// structure and notification function need to be allocated from runtime
48 /// memory.
49 runtime: bool = false,
50 timer: bool = false,
51
52 /// This event should not be combined with any other event types. This event
53 /// type is functionally equivalent to the EFI_EVENT_GROUP_EXIT_BOOT_SERVICES
54 /// event group.
55 pub const signal_exit_boot_services: EventType = .{
56 .signal = true,
57 .lo_context = 1,
58 };
59
60 /// The event is to be notified by the system when SetVirtualAddressMap()
61 /// is performed. This event type is a composite of EVT_NOTIFY_SIGNAL,
62 /// EVT_RUNTIME, and EVT_RUNTIME_CONTEXT and should not be combined with
63 /// any other event types.
64 pub const signal_virtual_address_change: EventType = .{
65 .runtime = true,
66 .hi_context = 0x20000,
67 .signal = true,
68 .lo_context = 2,
69 };
70};
71
30/// The calling convention used for all external functions part of the UEFI API.72/// The calling convention used for all external functions part of the UEFI API.
31pub const cc: std.builtin.CallingConvention = switch (@import("builtin").target.cpu.arch) {73pub const cc: std.builtin.CallingConvention = switch (@import("builtin").target.cpu.arch) {
32 .x86_64 => .{ .x86_64_win = .{} },74 .x86_64 => .{ .x86_64_win = .{} },
...@@ -52,7 +94,11 @@ pub const IpAddress = extern union {...@@ -52,7 +94,11 @@ pub const IpAddress = extern union {
5294
53/// GUIDs are align(8) unless otherwise specified.95/// GUIDs are align(8) unless otherwise specified.
54pub const Guid = extern struct {96pub const Guid = extern struct {
55 time_low: u32,97 comptime {
98 std.debug.assert(std.mem.Alignment.of(Guid) == .@"8");
99 }
100
101 time_low: u32 align(8),
56 time_mid: u16,102 time_mid: u16,
57 time_high_and_version: u16,103 time_high_and_version: u16,
58 clock_seq_high_and_reserved: u8,104 clock_seq_high_and_reserved: u8,
...@@ -60,7 +106,7 @@ pub const Guid = extern struct {...@@ -60,7 +106,7 @@ pub const Guid = extern struct {
60 node: [6]u8,106 node: [6]u8,
61107
62 /// Format GUID into hexadecimal lowercase xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx format108 /// Format GUID into hexadecimal lowercase xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx format
63 pub fn format(self: @This(), writer: *std.io.Writer) std.io.Writer.Error!void {109 pub fn format(self: Guid, writer: *std.io.Writer) std.io.Writer.Error!void {
64 const time_low = @byteSwap(self.time_low);110 const time_low = @byteSwap(self.time_low);
65 const time_mid = @byteSwap(self.time_mid);111 const time_mid = @byteSwap(self.time_mid);
66 const time_high_and_version = @byteSwap(self.time_high_and_version);112 const time_high_and_version = @byteSwap(self.time_high_and_version);
...@@ -75,7 +121,7 @@ pub const Guid = extern struct {...@@ -75,7 +121,7 @@ pub const Guid = extern struct {
75 });121 });
76 }122 }
77123
78 pub fn eql(a: std.os.uefi.Guid, b: std.os.uefi.Guid) bool {124 pub fn eql(a: Guid, b: Guid) bool {
79 return a.time_low == b.time_low and125 return a.time_low == b.time_low and
80 a.time_mid == b.time_mid and126 a.time_mid == b.time_mid and
81 a.time_high_and_version == b.time_high_and_version and127 a.time_high_and_version == b.time_high_and_version and
lib/std/os/uefi/pool_allocator.zig+14-10
...@@ -28,14 +28,16 @@ const UefiPoolAllocator = struct {...@@ -28,14 +28,16 @@ const UefiPoolAllocator = struct {
2828
29 const full_len = metadata_len + len;29 const full_len = metadata_len + len;
3030
31 var unaligned_ptr: [*]align(8) u8 = undefined;31 const unaligned_slice = uefi.system_table.boot_services.?.allocatePool(
32 if (uefi.system_table.boot_services.?.allocatePool(uefi.efi_pool_memory_type, full_len, &unaligned_ptr) != .success) return null;32 uefi.efi_pool_memory_type,
33 full_len,
34 ) catch return null;
3335
34 const unaligned_addr = @intFromPtr(unaligned_ptr);36 const unaligned_addr = @intFromPtr(unaligned_slice.ptr);
35 const aligned_addr = mem.alignForward(usize, unaligned_addr + @sizeOf(usize), ptr_align);37 const aligned_addr = mem.alignForward(usize, unaligned_addr + @sizeOf(usize), ptr_align);
3638
37 const aligned_ptr = unaligned_ptr + (aligned_addr - unaligned_addr);39 const aligned_ptr = unaligned_slice.ptr + (aligned_addr - unaligned_addr);
38 getHeader(aligned_ptr).* = unaligned_ptr;40 getHeader(aligned_ptr).* = unaligned_slice.ptr;
3941
40 return aligned_ptr;42 return aligned_ptr;
41 }43 }
...@@ -76,7 +78,7 @@ const UefiPoolAllocator = struct {...@@ -76,7 +78,7 @@ const UefiPoolAllocator = struct {
76 ) void {78 ) void {
77 _ = alignment;79 _ = alignment;
78 _ = ret_addr;80 _ = ret_addr;
79 _ = uefi.system_table.boot_services.?.freePool(getHeader(buf.ptr).*);81 uefi.system_table.boot_services.?.freePool(getHeader(buf.ptr).*) catch unreachable;
80 }82 }
81};83};
8284
...@@ -117,10 +119,12 @@ fn uefi_alloc(...@@ -117,10 +119,12 @@ fn uefi_alloc(
117119
118 std.debug.assert(@intFromEnum(alignment) <= 3);120 std.debug.assert(@intFromEnum(alignment) <= 3);
119121
120 var ptr: [*]align(8) u8 = undefined;122 const slice = uefi.system_table.boot_services.?.allocatePool(
121 if (uefi.system_table.boot_services.?.allocatePool(uefi.efi_pool_memory_type, len, &ptr) != .success) return null;123 uefi.efi_pool_memory_type,
124 len,
125 ) catch return null;
122126
123 return ptr;127 return slice.ptr;
124}128}
125129
126fn uefi_resize(130fn uefi_resize(
...@@ -161,5 +165,5 @@ fn uefi_free(...@@ -161,5 +165,5 @@ fn uefi_free(
161) void {165) void {
162 _ = alignment;166 _ = alignment;
163 _ = ret_addr;167 _ = ret_addr;
164 _ = uefi.system_table.boot_services.?.freePool(@alignCast(buf.ptr));168 uefi.system_table.boot_services.?.freePool(@alignCast(buf.ptr)) catch unreachable;
165}169}
lib/std/os/uefi/tables.zig+200-28
...@@ -1,3 +1,12 @@...@@ -1,3 +1,12 @@
1const std = @import("std");
2const uefi = std.os.uefi;
3const Handle = uefi.Handle;
4const Event = uefi.Event;
5const Guid = uefi.Guid;
6const cc = uefi.cc;
7const math = std.math;
8const assert = std.debug.assert;
9
1pub const BootServices = @import("tables/boot_services.zig").BootServices;10pub const BootServices = @import("tables/boot_services.zig").BootServices;
2pub const RuntimeServices = @import("tables/runtime_services.zig").RuntimeServices;11pub const RuntimeServices = @import("tables/runtime_services.zig").RuntimeServices;
3pub const ConfigurationTable = @import("tables/configuration_table.zig").ConfigurationTable;12pub const ConfigurationTable = @import("tables/configuration_table.zig").ConfigurationTable;
...@@ -7,29 +16,90 @@ pub const TableHeader = @import("tables/table_header.zig").TableHeader;...@@ -7,29 +16,90 @@ pub const TableHeader = @import("tables/table_header.zig").TableHeader;
7pub const EventNotify = *const fn (event: Event, ctx: *anyopaque) callconv(cc) void;16pub const EventNotify = *const fn (event: Event, ctx: *anyopaque) callconv(cc) void;
817
9pub const TimerDelay = enum(u32) {18pub const TimerDelay = enum(u32) {
10 timer_cancel,19 cancel,
11 timer_periodic,20 periodic,
12 timer_relative,21 relative,
13};22};
1423
15pub const MemoryType = enum(u32) {24pub const MemoryType = enum(u32) {
25 pub const Oem = math.IntFittingRange(
26 0,
27 @intFromEnum(MemoryType.oem_end) - @intFromEnum(MemoryType.oem_start),
28 );
29 pub const Vendor = math.IntFittingRange(
30 0,
31 @intFromEnum(MemoryType.vendor_end) - @intFromEnum(MemoryType.vendor_start),
32 );
33
34 /// can only be allocated using .allocate_any_pages mode unless you are explicitly targeting an interface that states otherwise
16 reserved_memory_type,35 reserved_memory_type,
17 loader_code,36 loader_code,
18 loader_data,37 loader_data,
19 boot_services_code,38 boot_services_code,
20 boot_services_data,39 boot_services_data,
40 /// can only be allocated using .allocate_any_pages mode unless you are explicitly targeting an interface that states otherwise
21 runtime_services_code,41 runtime_services_code,
42 /// can only be allocated using .allocate_any_pages mode unless you are explicitly targeting an interface that states otherwise
22 runtime_services_data,43 runtime_services_data,
23 conventional_memory,44 conventional_memory,
24 unusable_memory,45 unusable_memory,
46 /// can only be allocated using .allocate_any_pages mode unless you are explicitly targeting an interface that states otherwise
25 acpi_reclaim_memory,47 acpi_reclaim_memory,
48 /// can only be allocated using .allocate_any_pages mode unless you are explicitly targeting an interface that states otherwise
26 acpi_memory_nvs,49 acpi_memory_nvs,
27 memory_mapped_io,50 memory_mapped_io,
28 memory_mapped_io_port_space,51 memory_mapped_io_port_space,
29 pal_code,52 pal_code,
30 persistent_memory,53 persistent_memory,
54 unaccepted_memory,
31 max_memory_type,55 max_memory_type,
56 invalid_start,
57 invalid_end = 0x6FFFFFFF,
58 /// MemoryType values in the range 0x70000000..0x7FFFFFFF are reserved for OEM use.
59 oem_start = 0x70000000,
60 oem_end = 0x7FFFFFFF,
61 /// MemoryType values in the range 0x80000000..0xFFFFFFFF are reserved for use by UEFI
62 /// OS loaders that are provided by operating system vendors.
63 vendor_start = 0x80000000,
64 vendor_end = 0xFFFFFFFF,
32 _,65 _,
66
67 pub fn fromOem(value: Oem) MemoryType {
68 const oem_start = @intFromEnum(MemoryType.oem_start);
69 return @enumFromInt(oem_start + value);
70 }
71
72 pub fn toOem(memtype: MemoryType) ?Oem {
73 const as_int = @intFromEnum(memtype);
74 const oem_start = @intFromEnum(MemoryType.oem_start);
75 if (as_int < oem_start) return null;
76 if (as_int > @intFromEnum(MemoryType.oem_end)) return null;
77 return @truncate(as_int - oem_start);
78 }
79
80 pub fn fromVendor(value: Vendor) MemoryType {
81 const vendor_start = @intFromEnum(MemoryType.vendor_start);
82 return @enumFromInt(vendor_start + value);
83 }
84
85 pub fn toVendor(memtype: MemoryType) ?Vendor {
86 const as_int = @intFromEnum(memtype);
87 const vendor_start = @intFromEnum(MemoryType.vendor_start);
88 if (as_int < @intFromEnum(MemoryType.vendor_end)) return null;
89 if (as_int > @intFromEnum(MemoryType.vendor_end)) return null;
90 return @truncate(as_int - vendor_start);
91 }
92
93 pub fn format(self: MemoryType, w: *std.io.Writer) std.io.WriteError!void {
94 if (self.toOem()) |oemval|
95 try w.print("OEM({X})", .{oemval})
96 else if (self.toVendor()) |vendorval|
97 try w.print("Vendor({X})", .{vendorval})
98 else if (std.enums.tagName(MemoryType, self)) |name|
99 try w.print("{s}", .{name})
100 else
101 try w.print("INVALID({X})", .{@intFromEnum(self)});
102 }
33};103};
34104
35pub const MemoryDescriptorAttribute = packed struct(u64) {105pub const MemoryDescriptorAttribute = packed struct(u64) {
...@@ -51,6 +121,8 @@ pub const MemoryDescriptorAttribute = packed struct(u64) {...@@ -51,6 +121,8 @@ pub const MemoryDescriptorAttribute = packed struct(u64) {
51 memory_runtime: bool,121 memory_runtime: bool,
52};122};
53123
124pub const MemoryMapKey = enum(usize) { _ };
125
54pub const MemoryDescriptor = extern struct {126pub const MemoryDescriptor = extern struct {
55 type: MemoryType,127 type: MemoryType,
56 physical_start: u64,128 physical_start: u64,
...@@ -59,20 +131,121 @@ pub const MemoryDescriptor = extern struct {...@@ -59,20 +131,121 @@ pub const MemoryDescriptor = extern struct {
59 attribute: MemoryDescriptorAttribute,131 attribute: MemoryDescriptorAttribute,
60};132};
61133
134pub const MemoryMapInfo = struct {
135 key: MemoryMapKey,
136 descriptor_size: usize,
137 descriptor_version: u32,
138 /// The number of descriptors in the map.
139 len: usize,
140};
141
142pub const MemoryMapSlice = struct {
143 info: MemoryMapInfo,
144 ptr: [*]align(@alignOf(MemoryDescriptor)) u8,
145
146 pub fn iterator(self: MemoryMapSlice) MemoryDescriptorIterator {
147 return .{ .ctx = self };
148 }
149
150 pub fn get(self: MemoryMapSlice, index: usize) ?*MemoryDescriptor {
151 if (index >= self.info.len) return null;
152 return self.getUnchecked(index);
153 }
154
155 pub fn getUnchecked(self: MemoryMapSlice, index: usize) *MemoryDescriptor {
156 const offset: usize = index * self.info.descriptor_size;
157 return @alignCast(@ptrCast(self.ptr[offset..]));
158 }
159};
160
161pub const MemoryDescriptorIterator = struct {
162 ctx: MemoryMapSlice,
163 index: usize = 0,
164
165 pub fn next(self: *MemoryDescriptorIterator) ?*MemoryDescriptor {
166 const md = self.ctx.get(self.index) orelse return null;
167 self.index += 1;
168 return md;
169 }
170};
171
62pub const LocateSearchType = enum(u32) {172pub const LocateSearchType = enum(u32) {
63 all_handles,173 all_handles,
64 by_register_notify,174 by_register_notify,
65 by_protocol,175 by_protocol,
66};176};
67177
68pub const OpenProtocolAttributes = packed struct(u32) {178pub const LocateSearch = union(LocateSearchType) {
69 by_handle_protocol: bool = false,179 all_handles,
70 get_protocol: bool = false,180 by_register_notify: uefi.EventRegistration,
71 test_protocol: bool = false,181 by_protocol: *const Guid,
72 by_child_controller: bool = false,182};
73 by_driver: bool = false,183
74 exclusive: bool = false,184pub const OpenProtocolAttributes = enum(u32) {
75 reserved: u26 = 0,185 pub const Bits = packed struct(u32) {
186 by_handle_protocol: bool = false,
187 get_protocol: bool = false,
188 test_protocol: bool = false,
189 by_child_controller: bool = false,
190 by_driver: bool = false,
191 exclusive: bool = false,
192 reserved: u26 = 0,
193 };
194
195 by_handle_protocol = @bitCast(Bits{ .by_handle_protocol = true }),
196 get_protocol = @bitCast(Bits{ .get_protocol = true }),
197 test_protocol = @bitCast(Bits{ .test_protocol = true }),
198 by_child_controller = @bitCast(Bits{ .by_child_controller = true }),
199 by_driver = @bitCast(Bits{ .by_driver = true }),
200 by_driver_exclusive = @bitCast(Bits{ .by_driver = true, .exclusive = true }),
201 exclusive = @bitCast(Bits{ .exclusive = true }),
202 _,
203
204 pub fn fromBits(bits: Bits) OpenProtocolAttributes {
205 return @bitCast(bits);
206 }
207
208 pub fn toBits(self: OpenProtocolAttributes) Bits {
209 return @bitCast(self);
210 }
211};
212
213pub const OpenProtocolArgs = union(OpenProtocolAttributes) {
214 /// Used in the implementation of `handleProtocol`.
215 by_handle_protocol: struct { agent: ?Handle = null, controller: ?Handle = null },
216 /// Used by a driver to get a protocol interface from a handle. Care must be
217 /// taken when using this open mode because the driver that opens a protocol
218 /// interface in this manner will not be informed if the protocol interface
219 /// is uninstalled or reinstalled. The caller is also not required to close
220 /// the protocol interface with `closeProtocol`.
221 get_protocol: struct { agent: ?Handle = null, controller: ?Handle = null },
222 /// Used by a driver to test for the existence of a protocol interface on a
223 /// handle. The caller only use the return status code. The caller is also
224 /// not required to close the protocol interface with `closeProtocol`.
225 test_protocol: struct { agent: ?Handle = null, controller: ?Handle = null },
226 /// Used by bus drivers to show that a protocol interface is being used by one
227 /// of the child controllers of a bus. This information is used by
228 /// `BootServices.connectController` to recursively connect all child controllers
229 /// and by `BootServices.disconnectController` to get the list of child
230 /// controllers that a bus driver created.
231 by_child_controller: struct { agent: Handle, controller: Handle },
232 /// Used by a driver to gain access to a protocol interface. When this mode
233 /// is used, the driver’s Stop() function will be called by
234 /// `BootServices.disconnectController` if the protocol interface is reinstalled
235 /// or uninstalled. Once a protocol interface is opened by a driver with this
236 /// attribute, no other drivers will be allowed to open the same protocol interface
237 /// with the `.by_driver` attribute.
238 by_driver: struct { agent: Handle, controller: Handle },
239 /// Used by a driver to gain exclusive access to a protocol interface. If any
240 /// other drivers have the protocol interface opened with an attribute of
241 /// `.by_driver`, then an attempt will be made to remove them with
242 /// `BootServices.disconnectController`.
243 by_driver_exclusive: struct { agent: Handle, controller: Handle },
244 /// Used by applications to gain exclusive access to a protocol interface. If
245 /// any drivers have the protocol interface opened with an attribute of
246 /// `.by_driver`, then an attempt will be made to remove them by calling the
247 /// driver’s Stop() function.
248 exclusive: struct { agent: Handle, controller: ?Handle = null },
76};249};
77250
78pub const ProtocolInformationEntry = extern struct {251pub const ProtocolInformationEntry = extern struct {
...@@ -83,19 +256,25 @@ pub const ProtocolInformationEntry = extern struct {...@@ -83,19 +256,25 @@ pub const ProtocolInformationEntry = extern struct {
83};256};
84257
85pub const InterfaceType = enum(u32) {258pub const InterfaceType = enum(u32) {
86 efi_native_interface,259 native,
260};
261
262pub const AllocateLocation = union(AllocateType) {
263 any,
264 max_address: [*]align(4096) uefi.Page,
265 address: [*]align(4096) uefi.Page,
87};266};
88267
89pub const AllocateType = enum(u32) {268pub const AllocateType = enum(u32) {
90 allocate_any_pages,269 any,
91 allocate_max_address,270 max_address,
92 allocate_address,271 address,
93};272};
94273
95pub const PhysicalAddress = u64;274pub const PhysicalAddress = u64;
96275
97pub const CapsuleHeader = extern struct {276pub const CapsuleHeader = extern struct {
98 capsule_guid: Guid align(8),277 capsule_guid: Guid,
99 header_size: u32,278 header_size: u32,
100 flags: u32,279 flags: u32,
101 capsule_image_size: u32,280 capsule_image_size: u32,
...@@ -110,13 +289,13 @@ pub const UefiCapsuleBlockDescriptor = extern struct {...@@ -110,13 +289,13 @@ pub const UefiCapsuleBlockDescriptor = extern struct {
110};289};
111290
112pub const ResetType = enum(u32) {291pub const ResetType = enum(u32) {
113 reset_cold,292 cold,
114 reset_warm,293 warm,
115 reset_shutdown,294 shutdown,
116 reset_platform_specific,295 platform_specific,
117};296};
118297
119pub const global_variable align(8) = Guid{298pub const global_variable = Guid{
120 .time_low = 0x8be4df61,299 .time_low = 0x8be4df61,
121 .time_mid = 0x93ca,300 .time_mid = 0x93ca,
122 .time_high_and_version = 0x11d2,301 .time_high_and_version = 0x11d2,
...@@ -128,10 +307,3 @@ pub const global_variable align(8) = Guid{...@@ -128,10 +307,3 @@ pub const global_variable align(8) = Guid{
128test {307test {
129 std.testing.refAllDeclsRecursive(@This());308 std.testing.refAllDeclsRecursive(@This());
130}309}
131
132const std = @import("std");
133const uefi = std.os.uefi;
134const Handle = uefi.Handle;
135const Event = uefi.Event;
136const Guid = uefi.Guid;
137const cc = uefi.cc;
lib/std/os/uefi/tables/boot_services.zig+1141-68
...@@ -1,21 +1,31 @@...@@ -1,21 +1,31 @@
1const std = @import("std");1const std = @import("std");
2const uefi = std.os.uefi;2const uefi = std.os.uefi;
3const Event = uefi.Event;3const Event = uefi.Event;
4const EventRegistration = uefi.EventRegistration;
4const Guid = uefi.Guid;5const Guid = uefi.Guid;
5const Handle = uefi.Handle;6const Handle = uefi.Handle;
7const Page = uefi.Page;
8const Pages = uefi.Pages;
6const Status = uefi.Status;9const Status = uefi.Status;
7const TableHeader = uefi.tables.TableHeader;10const TableHeader = uefi.tables.TableHeader;
8const DevicePathProtocol = uefi.protocol.DevicePath;11const DevicePathProtocol = uefi.protocol.DevicePath;
12const AllocateLocation = uefi.tables.AllocateLocation;
9const AllocateType = uefi.tables.AllocateType;13const AllocateType = uefi.tables.AllocateType;
10const MemoryType = uefi.tables.MemoryType;14const MemoryType = uefi.tables.MemoryType;
11const MemoryDescriptor = uefi.tables.MemoryDescriptor;15const MemoryDescriptor = uefi.tables.MemoryDescriptor;
16const MemoryMapKey = uefi.tables.MemoryMapKey;
17const MemoryMapInfo = uefi.tables.MemoryMapInfo;
18const MemoryMapSlice = uefi.tables.MemoryMapSlice;
12const TimerDelay = uefi.tables.TimerDelay;19const TimerDelay = uefi.tables.TimerDelay;
13const InterfaceType = uefi.tables.InterfaceType;20const InterfaceType = uefi.tables.InterfaceType;
21const LocateSearch = uefi.tables.LocateSearch;
14const LocateSearchType = uefi.tables.LocateSearchType;22const LocateSearchType = uefi.tables.LocateSearchType;
23const OpenProtocolArgs = uefi.tables.OpenProtocolArgs;
15const OpenProtocolAttributes = uefi.tables.OpenProtocolAttributes;24const OpenProtocolAttributes = uefi.tables.OpenProtocolAttributes;
16const ProtocolInformationEntry = uefi.tables.ProtocolInformationEntry;25const ProtocolInformationEntry = uefi.tables.ProtocolInformationEntry;
17const EventNotify = uefi.tables.EventNotify;26const EventNotify = uefi.tables.EventNotify;
18const cc = uefi.cc;27const cc = uefi.cc;
28const Error = Status.Error;
1929
20/// Boot services are services provided by the system's firmware until the operating system takes30/// Boot services are services provided by the system's firmware until the operating system takes
21/// over control over the hardware by calling exitBootServices.31/// over control over the hardware by calling exitBootServices.
...@@ -32,173 +42,1236 @@ pub const BootServices = extern struct {...@@ -32,173 +42,1236 @@ pub const BootServices = extern struct {
32 hdr: TableHeader,42 hdr: TableHeader,
3343
34 /// Raises a task's priority level and returns its previous level.44 /// Raises a task's priority level and returns its previous level.
35 raiseTpl: *const fn (new_tpl: usize) callconv(cc) usize,45 raiseTpl: *const fn (new_tpl: TaskPriorityLevel) callconv(cc) TaskPriorityLevel,
3646
37 /// Restores a task's priority level to its previous value.47 /// Restores a task's priority level to its previous value.
38 restoreTpl: *const fn (old_tpl: usize) callconv(cc) void,48 restoreTpl: *const fn (old_tpl: TaskPriorityLevel) callconv(cc) void,
3949
40 /// Allocates memory pages from the system.50 /// Allocates memory pages from the system.
41 allocatePages: *const fn (alloc_type: AllocateType, mem_type: MemoryType, pages: usize, memory: *[*]align(4096) u8) callconv(cc) Status,51 _allocatePages: *const fn (alloc_type: AllocateType, mem_type: MemoryType, pages: usize, memory: *[*]align(4096) Page) callconv(cc) Status,
4252
43 /// Frees memory pages.53 /// Frees memory pages.
44 freePages: *const fn (memory: [*]align(4096) u8, pages: usize) callconv(cc) Status,54 _freePages: *const fn (memory: [*]align(4096) Page, pages: usize) callconv(cc) Status,
4555
46 /// Returns the current memory map.56 /// Returns the current memory map.
47 getMemoryMap: *const fn (mmap_size: *usize, mmap: ?[*]MemoryDescriptor, map_key: *usize, descriptor_size: *usize, descriptor_version: *u32) callconv(cc) Status,57 _getMemoryMap: *const fn (mmap_size: *usize, mmap: ?[*]align(@alignOf(MemoryDescriptor)) u8, map_key: *MemoryMapKey, descriptor_size: *usize, descriptor_version: *u32) callconv(cc) Status,
4858
49 /// Allocates pool memory.59 /// Allocates pool memory.
50 allocatePool: *const fn (pool_type: MemoryType, size: usize, buffer: *[*]align(8) u8) callconv(cc) Status,60 _allocatePool: *const fn (pool_type: MemoryType, size: usize, buffer: *[*]align(8) u8) callconv(cc) Status,
5161
52 /// Returns pool memory to the system.62 /// Returns pool memory to the system.
53 freePool: *const fn (buffer: [*]align(8) u8) callconv(cc) Status,63 _freePool: *const fn (buffer: [*]align(8) u8) callconv(cc) Status,
5464
55 /// Creates an event.65 /// Creates an event.
56 createEvent: *const fn (type: u32, notify_tpl: usize, notify_func: ?*const fn (Event, ?*anyopaque) callconv(cc) void, notify_ctx: ?*const anyopaque, event: *Event) callconv(cc) Status,66 _createEvent: *const fn (type: u32, notify_tpl: TaskPriorityLevel, notify_func: ?*const fn (Event, ?*anyopaque) callconv(cc) void, notify_ctx: ?*anyopaque, event: *Event) callconv(cc) Status,
5767
58 /// Sets the type of timer and the trigger time for a timer event.68 /// Sets the type of timer and the trigger time for a timer event.
59 setTimer: *const fn (event: Event, type: TimerDelay, trigger_time: u64) callconv(cc) Status,69 _setTimer: *const fn (event: Event, type: TimerDelay, trigger_time: u64) callconv(cc) Status,
6070
61 /// Stops execution until an event is signaled.71 /// Stops execution until an event is signaled.
62 waitForEvent: *const fn (event_len: usize, events: [*]const Event, index: *usize) callconv(cc) Status,72 _waitForEvent: *const fn (event_len: usize, events: [*]const Event, index: *usize) callconv(cc) Status,
6373
64 /// Signals an event.74 /// Signals an event.
65 signalEvent: *const fn (event: Event) callconv(cc) Status,75 _signalEvent: *const fn (event: Event) callconv(cc) Status,
6676
67 /// Closes an event.77 /// Closes an event.
68 closeEvent: *const fn (event: Event) callconv(cc) Status,78 _closeEvent: *const fn (event: Event) callconv(cc) Status,
6979
70 /// Checks whether an event is in the signaled state.80 /// Checks whether an event is in the signaled state.
71 checkEvent: *const fn (event: Event) callconv(cc) Status,81 _checkEvent: *const fn (event: Event) callconv(cc) Status,
7282
73 /// Installs a protocol interface on a device handle. If the handle does not exist, it is created83 /// Installs a protocol interface on a device handle. If the handle does not exist, it is created
74 /// and added to the list of handles in the system. installMultipleProtocolInterfaces()84 /// and added to the list of handles in the system. installMultipleProtocolInterfaces()
75 /// performs more error checking than installProtocolInterface(), so its use is recommended over this.85 /// performs more error checking than installProtocolInterface(), so its use is recommended over this.
76 installProtocolInterface: *const fn (handle: Handle, protocol: *align(8) const Guid, interface_type: InterfaceType, interface: *anyopaque) callconv(cc) Status,86 _installProtocolInterface: *const fn (handle: Handle, protocol: *const Guid, interface_type: InterfaceType, interface: *anyopaque) callconv(cc) Status,
7787
78 /// Reinstalls a protocol interface on a device handle88 /// Reinstalls a protocol interface on a device handle
79 reinstallProtocolInterface: *const fn (handle: Handle, protocol: *align(8) const Guid, old_interface: *anyopaque, new_interface: *anyopaque) callconv(cc) Status,89 _reinstallProtocolInterface: *const fn (handle: Handle, protocol: *const Guid, old_interface: *anyopaque, new_interface: *anyopaque) callconv(cc) Status,
8090
81 /// Removes a protocol interface from a device handle. Usage of91 /// Removes a protocol interface from a device handle. Usage of
82 /// uninstallMultipleProtocolInterfaces is recommended over this.92 /// uninstallMultipleProtocolInterfaces is recommended over this.
83 uninstallProtocolInterface: *const fn (handle: Handle, protocol: *align(8) const Guid, interface: *anyopaque) callconv(cc) Status,93 _uninstallProtocolInterface: *const fn (handle: Handle, protocol: *const Guid, interface: *anyopaque) callconv(cc) Status,
8494
85 /// Queries a handle to determine if it supports a specified protocol.95 /// Queries a handle to determine if it supports a specified protocol.
86 handleProtocol: *const fn (handle: Handle, protocol: *align(8) const Guid, interface: *?*anyopaque) callconv(cc) Status,96 _handleProtocol: *const fn (handle: Handle, protocol: *const Guid, interface: *?*anyopaque) callconv(cc) Status,
8797
88 reserved: *anyopaque,98 _reserved: *anyopaque,
8999
90 /// Creates an event that is to be signaled whenever an interface is installed for a specified protocol.100 /// Creates an event that is to be signaled whenever an interface is installed for a specified protocol.
91 registerProtocolNotify: *const fn (protocol: *align(8) const Guid, event: Event, registration: **anyopaque) callconv(cc) Status,101 _registerProtocolNotify: *const fn (protocol: *const Guid, event: Event, registration: *EventRegistration) callconv(cc) Status,
92102
93 /// Returns an array of handles that support a specified protocol.103 /// Returns an array of handles that support a specified protocol.
94 locateHandle: *const fn (search_type: LocateSearchType, protocol: ?*align(8) const Guid, search_key: ?*const anyopaque, buffer_size: *usize, buffer: [*]Handle) callconv(cc) Status,104 _locateHandle: *const fn (search_type: LocateSearchType, protocol: ?*const Guid, search_key: ?*const anyopaque, buffer_size: *usize, buffer: ?[*]Handle) callconv(cc) Status,
95105
96 /// Locates the handle to a device on the device path that supports the specified protocol106 /// Locates the handle to a device on the device path that supports the specified protocol
97 locateDevicePath: *const fn (protocols: *align(8) const Guid, device_path: **const DevicePathProtocol, device: *?Handle) callconv(cc) Status,107 _locateDevicePath: *const fn (protocols: *const Guid, device_path: **const DevicePathProtocol, device: *?Handle) callconv(cc) Status,
98108
99 /// Adds, updates, or removes a configuration table entry from the EFI System Table.109 /// Adds, updates, or removes a configuration table entry from the EFI System Table.
100 installConfigurationTable: *const fn (guid: *align(8) const Guid, table: ?*anyopaque) callconv(cc) Status,110 _installConfigurationTable: *const fn (guid: *const Guid, table: ?*anyopaque) callconv(cc) Status,
101111
102 /// Loads an EFI image into memory.112 /// Loads an EFI image into memory.
103 loadImage: *const fn (boot_policy: bool, parent_image_handle: Handle, device_path: ?*const DevicePathProtocol, source_buffer: ?[*]const u8, source_size: usize, image_handle: *?Handle) callconv(cc) Status,113 _loadImage: *const fn (boot_policy: bool, parent_image_handle: Handle, device_path: ?*const DevicePathProtocol, source_buffer: ?[*]const u8, source_size: usize, image_handle: *Handle) callconv(cc) Status,
104114
105 /// Transfers control to a loaded image's entry point.115 /// Transfers control to a loaded image's entry point.
106 startImage: *const fn (image_handle: Handle, exit_data_size: ?*usize, exit_data: ?*[*]u16) callconv(cc) Status,116 _startImage: *const fn (image_handle: Handle, exit_data_size: ?*usize, exit_data: ?*[*]u16) callconv(cc) Status,
107117
108 /// Terminates a loaded EFI image and returns control to boot services.118 /// Terminates a loaded EFI image and returns control to boot services.
109 exit: *const fn (image_handle: Handle, exit_status: Status, exit_data_size: usize, exit_data: ?*const anyopaque) callconv(cc) Status,119 _exit: *const fn (image_handle: Handle, exit_status: Status, exit_data_size: usize, exit_data: ?[*]align(2) const u8) callconv(cc) Status,
110120
111 /// Unloads an image.121 /// Unloads an image.
112 unloadImage: *const fn (image_handle: Handle) callconv(cc) Status,122 _unloadImage: *const fn (image_handle: Handle) callconv(cc) Status,
113123
114 /// Terminates all boot services.124 /// Terminates all boot services.
115 exitBootServices: *const fn (image_handle: Handle, map_key: usize) callconv(cc) Status,125 _exitBootServices: *const fn (image_handle: Handle, map_key: MemoryMapKey) callconv(cc) Status,
116126
117 /// Returns a monotonically increasing count for the platform.127 /// Returns a monotonically increasing count for the platform.
118 getNextMonotonicCount: *const fn (count: *u64) callconv(cc) Status,128 _getNextMonotonicCount: *const fn (count: *u64) callconv(cc) Status,
119129
120 /// Induces a fine-grained stall.130 /// Induces a fine-grained stall.
121 stall: *const fn (microseconds: usize) callconv(cc) Status,131 _stall: *const fn (microseconds: usize) callconv(cc) Status,
122132
123 /// Sets the system's watchdog timer.133 /// Sets the system's watchdog timer.
124 setWatchdogTimer: *const fn (timeout: usize, watchdog_code: u64, data_size: usize, watchdog_data: ?[*]const u16) callconv(cc) Status,134 _setWatchdogTimer: *const fn (timeout: usize, watchdog_code: u64, data_size: usize, watchdog_data: ?[*]const u16) callconv(cc) Status,
125135
126 /// Connects one or more drives to a controller.136 /// Connects one or more drives to a controller.
127 connectController: *const fn (controller_handle: Handle, driver_image_handle: ?Handle, remaining_device_path: ?*DevicePathProtocol, recursive: bool) callconv(cc) Status,137 _connectController: *const fn (controller_handle: Handle, driver_image_handle: ?[*:null]?Handle, remaining_device_path: ?*const DevicePathProtocol, recursive: bool) callconv(cc) Status,
128138
129 // Disconnects one or more drivers from a controller139 // Disconnects one or more drivers from a controller
130 disconnectController: *const fn (controller_handle: Handle, driver_image_handle: ?Handle, child_handle: ?Handle) callconv(cc) Status,140 _disconnectController: *const fn (controller_handle: Handle, driver_image_handle: ?Handle, child_handle: ?Handle) callconv(cc) Status,
131141
132 /// Queries a handle to determine if it supports a specified protocol.142 /// Queries a handle to determine if it supports a specified protocol.
133 openProtocol: *const fn (handle: Handle, protocol: *align(8) const Guid, interface: *?*anyopaque, agent_handle: ?Handle, controller_handle: ?Handle, attributes: OpenProtocolAttributes) callconv(cc) Status,143 _openProtocol: *const fn (handle: Handle, protocol: *const Guid, interface: ?*?*anyopaque, agent_handle: ?Handle, controller_handle: ?Handle, attributes: OpenProtocolAttributes) callconv(cc) Status,
134144
135 /// Closes a protocol on a handle that was opened using openProtocol().145 /// Closes a protocol on a handle that was opened using openProtocol().
136 closeProtocol: *const fn (handle: Handle, protocol: *align(8) const Guid, agent_handle: Handle, controller_handle: ?Handle) callconv(cc) Status,146 _closeProtocol: *const fn (handle: Handle, protocol: *const Guid, agent_handle: Handle, controller_handle: ?Handle) callconv(cc) Status,
137147
138 /// Retrieves the list of agents that currently have a protocol interface opened.148 /// Retrieves the list of agents that currently have a protocol interface opened.
139 openProtocolInformation: *const fn (handle: Handle, protocol: *align(8) const Guid, entry_buffer: *[*]ProtocolInformationEntry, entry_count: *usize) callconv(cc) Status,149 _openProtocolInformation: *const fn (handle: Handle, protocol: *const Guid, entry_buffer: *[*]ProtocolInformationEntry, entry_count: *usize) callconv(cc) Status,
140150
141 /// Retrieves the list of protocol interface GUIDs that are installed on a handle in a buffer allocated from pool.151 /// Retrieves the list of protocol interface GUIDs that are installed on a handle in a buffer allocated from pool.
142 protocolsPerHandle: *const fn (handle: Handle, protocol_buffer: *[*]*align(8) const Guid, protocol_buffer_count: *usize) callconv(cc) Status,152 _protocolsPerHandle: *const fn (handle: Handle, protocol_buffer: *[*]*const Guid, protocol_buffer_count: *usize) callconv(cc) Status,
143153
144 /// Returns an array of handles that support the requested protocol in a buffer allocated from pool.154 /// Returns an array of handles that support the requested protocol in a buffer allocated from pool.
145 locateHandleBuffer: *const fn (search_type: LocateSearchType, protocol: ?*align(8) const Guid, search_key: ?*const anyopaque, num_handles: *usize, buffer: *[*]Handle) callconv(cc) Status,155 _locateHandleBuffer: *const fn (search_type: LocateSearchType, protocol: ?*const Guid, search_key: ?*const anyopaque, num_handles: *usize, buffer: *[*]Handle) callconv(cc) Status,
146156
147 /// Returns the first protocol instance that matches the given protocol.157 /// Returns the first protocol instance that matches the given protocol.
148 locateProtocol: *const fn (protocol: *align(8) const Guid, registration: ?*const anyopaque, interface: *?*anyopaque) callconv(cc) Status,158 _locateProtocol: *const fn (protocol: *const Guid, registration: ?EventRegistration, interface: *?*const anyopaque) callconv(cc) Status,
149159
150 /// Installs one or more protocol interfaces into the boot services environment160 /// Installs one or more protocol interfaces into the boot services environment
151 // TODO: use callconv(cc) instead once that works161 // TODO: use callconv(cc) instead once that works
152 installMultipleProtocolInterfaces: *const fn (handle: *Handle, ...) callconv(.c) Status,162 _installMultipleProtocolInterfaces: *const fn (handle: *Handle, ...) callconv(.c) Status,
153163
154 /// Removes one or more protocol interfaces into the boot services environment164 /// Removes one or more protocol interfaces into the boot services environment
155 // TODO: use callconv(cc) instead once that works165 // TODO: use callconv(cc) instead once that works
156 uninstallMultipleProtocolInterfaces: *const fn (handle: *Handle, ...) callconv(.c) Status,166 _uninstallMultipleProtocolInterfaces: *const fn (handle: *Handle, ...) callconv(.c) Status,
157167
158 /// Computes and returns a 32-bit CRC for a data buffer.168 /// Computes and returns a 32-bit CRC for a data buffer.
159 calculateCrc32: *const fn (data: [*]const u8, data_size: usize, *u32) callconv(cc) Status,169 _calculateCrc32: *const fn (data: [*]const u8, data_size: usize, *u32) callconv(cc) Status,
160170
161 /// Copies the contents of one buffer to another buffer171 /// Copies the contents of one buffer to another buffer
162 copyMem: *const fn (dest: [*]u8, src: [*]const u8, len: usize) callconv(cc) void,172 _copyMem: *const fn (dest: [*]u8, src: [*]const u8, len: usize) callconv(cc) void,
163173
164 /// Fills a buffer with a specified value174 /// Fills a buffer with a specified value
165 setMem: *const fn (buffer: [*]u8, size: usize, value: u8) callconv(cc) void,175 _setMem: *const fn (buffer: [*]u8, size: usize, value: u8) callconv(cc) void,
166176
167 /// Creates an event in a group.177 /// Creates an event in a group.
168 createEventEx: *const fn (type: u32, notify_tpl: usize, notify_func: EventNotify, notify_ctx: *const anyopaque, event_group: *align(8) const Guid, event: *Event) callconv(cc) Status,178 _createEventEx: *const fn (type: u32, notify_tpl: usize, notify_func: EventNotify, notify_ctx: *const anyopaque, event_group: *const Guid, event: *Event) callconv(cc) Status,
179
180 pub const AllocatePagesError = uefi.UnexpectedError || error{
181 OutOfResources,
182 InvalidParameter,
183 NotFound,
184 };
185
186 pub const FreePagesError = uefi.UnexpectedError || error{
187 NotFound,
188 InvalidParameter,
189 };
190
191 pub const GetMemoryMapError = uefi.UnexpectedError || error{
192 InvalidParameter,
193 BufferTooSmall,
194 };
195
196 pub const AllocatePoolError = uefi.UnexpectedError || error{
197 OutOfResources,
198 InvalidParameter,
199 };
200
201 pub const FreePoolError = uefi.UnexpectedError || error{
202 InvalidParameter,
203 };
204
205 pub const CreateEventError = uefi.UnexpectedError || error{
206 InvalidParameter,
207 OutOfResources,
208 };
209
210 pub const SetTimerError = uefi.UnexpectedError || error{
211 InvalidParameter,
212 };
213
214 pub const WaitForEventError = uefi.UnexpectedError || error{
215 InvalidParameter,
216 Unsupported,
217 };
218
219 pub const CheckEventError = uefi.UnexpectedError || error{
220 InvalidParameter,
221 };
222
223 pub const ReinstallProtocolInterfaceError = uefi.UnexpectedError || error{
224 NotFound,
225 AccessDenied,
226 InvalidParameter,
227 };
228
229 pub const HandleProtocolError = uefi.UnexpectedError || error{
230 Unsupported,
231 };
232
233 pub const RegisterProtocolNotifyError = uefi.UnexpectedError || error{
234 OutOfResources,
235 InvalidParameter,
236 };
237
238 pub const NumHandlesError = uefi.UnexpectedError || error{
239 OutOfResources,
240 };
241
242 pub const LocateHandleError = uefi.UnexpectedError || error{
243 BufferTooSmall,
244 InvalidParameter,
245 };
246
247 pub const LocateDevicePathError = uefi.UnexpectedError || error{
248 NotFound,
249 InvalidParameter,
250 };
251
252 pub const InstallConfigurationTableError = uefi.UnexpectedError || error{
253 InvalidParameter,
254 OutOfResources,
255 };
256
257 pub const UninstallConfigurationTableError = InstallConfigurationTableError || error{
258 NotFound,
259 };
260
261 pub const LoadImageError = uefi.UnexpectedError || error{
262 NotFound,
263 InvalidParameter,
264 Unsupported,
265 OutOfResources,
266 LoadError,
267 DeviceError,
268 AccessDenied,
269 SecurityViolation,
270 };
271
272 pub const StartImageError = uefi.UnexpectedError || error{
273 InvalidParameter,
274 SecurityViolation,
275 };
276
277 pub const ExitError = uefi.UnexpectedError || error{
278 InvalidParameter,
279 };
280
281 pub const ExitBootServicesError = uefi.UnexpectedError || error{
282 InvalidParameter,
283 };
284
285 pub const GetNextMonotonicCountError = uefi.UnexpectedError || error{
286 DeviceError,
287 InvalidParameter,
288 };
289
290 pub const SetWatchdogTimerError = uefi.UnexpectedError || error{
291 InvalidParameter,
292 Unsupported,
293 DeviceError,
294 };
295
296 pub const ConnectControllerError = uefi.UnexpectedError || error{
297 InvalidParameter,
298 NotFound,
299 SecurityViolation,
300 };
301
302 pub const DisconnectControllerError = uefi.UnexpectedError || error{
303 InvalidParameter,
304 OutOfResources,
305 DeviceError,
306 };
307
308 pub const OpenProtocolError = uefi.UnexpectedError || error{
309 InvalidParameter,
310 Unsupported,
311 AccessDenied,
312 AlreadyStarted,
313 };
314
315 pub const CloseProtocolError = uefi.UnexpectedError || error{
316 InvalidParameter,
317 NotFound,
318 };
319
320 pub const OpenProtocolInformationError = uefi.UnexpectedError || error{
321 OutOfResources,
322 };
323
324 pub const ProtocolsPerHandleError = uefi.UnexpectedError || error{
325 InvalidParameter,
326 OutOfResources,
327 };
328
329 pub const LocateHandleBufferError = uefi.UnexpectedError || error{
330 InvalidParameter,
331 OutOfResources,
332 };
333
334 pub const LocateProtocolError = uefi.UnexpectedError || error{
335 InvalidParameter,
336 };
337
338 pub const InstallProtocolInterfacesError = uefi.UnexpectedError || error{
339 AlreadyStarted,
340 OutOfResources,
341 InvalidParameter,
342 };
343
344 pub const UninstallProtocolInterfacesError = uefi.UnexpectedError || error{
345 InvalidParameter,
346 };
347
348 pub const CalculateCrc32Error = uefi.UnexpectedError || error{
349 InvalidParameter,
350 };
351
352 /// Allocates pages of memory.
353 ///
354 /// This function scans the memory map to locate free pages. When it finds a
355 /// physically contiguous block of pages that is large enough and also satisfies
356 /// the allocation requirements of `alloc_type`, it changes the memory map to
357 /// indicate that the pages are now of type `mem_type`.
358 ///
359 /// In general, UEFI OS loaders and UEFI applications should allocate memory
360 /// (and pool) of type `.loader_data`. UEFI boot service drivers must allocate
361 /// memory (and pool) of type `.boot_services_data`. UREFI runtime drivers
362 /// should allocate memory (and pool) of type `.runtime_services_data`
363 /// (although such allocation can only be made during boot services time).
364 ///
365 /// Allocation requests of `.allocate_any_pages` allocate any available range
366 /// of pages that satisfies the request.
367 ///
368 /// Allocation requests of `.allocate_max_address` allocate any available range
369 /// of pages whose uppermost address is less than or equal to the address
370 /// pointed to by the input.
371 ///
372 /// Allocation requests of `.allocate_address` allocate pages at the address
373 /// pointed to by the input.
374 pub fn allocatePages(
375 self: *BootServices,
376 location: AllocateLocation,
377 mem_type: MemoryType,
378 pages: usize,
379 ) AllocatePagesError![]align(4096) Page {
380 var ptr: [*]align(4096) Page = switch (location) {
381 .any => undefined,
382 .address, .max_address => |ptr| ptr,
383 };
384
385 switch (self._allocatePages(
386 std.meta.activeTag(location),
387 mem_type,
388 pages,
389 &ptr,
390 )) {
391 .success => return ptr[0..pages],
392 .out_of_resources => return error.OutOfResources,
393 .invalid_parameter => return error.InvalidParameter,
394 .not_found => return error.NotFound,
395 else => |status| return uefi.unexpectedStatus(status),
396 }
397 }
398
399 pub fn freePages(self: *BootServices, pages: []align(4096) Page) FreePagesError!void {
400 switch (self._freePages(pages.ptr, pages.len)) {
401 .success => {},
402 .not_found => return error.NotFound,
403 .invalid_parameter => return error.InvalidParameter,
404 else => |status| return uefi.unexpectedStatus(status),
405 }
406 }
407
408 pub fn getMemoryMapInfo(self: *const BootServices) uefi.UnexpectedError!MemoryMapInfo {
409 var info: MemoryMapInfo = undefined;
410 info.len = 0;
411
412 switch (self._getMemoryMap(
413 &info.len,
414 null,
415 &info.key,
416 &info.descriptor_size,
417 &info.descriptor_version,
418 )) {
419 .success, .buffer_too_small => {
420 info.len = @divExact(info.len, info.descriptor_size);
421 return info;
422 },
423 else => |status| return uefi.unexpectedStatus(status),
424 }
425 }
426
427 pub fn getMemoryMap(
428 self: *const BootServices,
429 buffer: []align(@alignOf(MemoryDescriptor)) u8,
430 ) GetMemoryMapError!MemoryMapSlice {
431 var info: MemoryMapInfo = undefined;
432 info.len = buffer.len;
433
434 switch (self._getMemoryMap(
435 &info.len,
436 buffer.ptr,
437 &info.key,
438 &info.descriptor_size,
439 &info.descriptor_version,
440 )) {
441 .success => {
442 info.len = @divExact(info.len, info.descriptor_size);
443 return .{ .info = info, .ptr = buffer.ptr };
444 },
445 .buffer_too_small => return error.BufferTooSmall,
446 .invalid_parameter => return error.InvalidParameter,
447 else => |status| return uefi.unexpectedStatus(status),
448 }
449 }
450
451 /// Allocates a memory region of `size` bytes from memory of type `pool_type`
452 /// and returns the allocated memory. Allocates pages from `.conventional_memory`
453 /// as needed to grow the requested pool type.
454 pub fn allocatePool(
455 self: *BootServices,
456 pool_type: MemoryType,
457 size: usize,
458 ) AllocatePoolError![]align(8) u8 {
459 var ptr: [*]align(8) u8 = undefined;
460
461 switch (self._allocatePool(pool_type, size, &ptr)) {
462 .success => return ptr[0..size],
463 .out_of_resources => return error.OutOfResources,
464 .invalid_parameter => return error.InvalidParameter,
465 else => |status| return uefi.unexpectedStatus(status),
466 }
467 }
468
469 pub fn freePool(self: *BootServices, ptr: [*]align(8) u8) FreePoolError!void {
470 switch (self._freePool(ptr)) {
471 .success => {},
472 .invalid_parameter => return error.InvalidParameter,
473 else => |status| return uefi.unexpectedStatus(status),
474 }
475 }
476
477 pub fn createEvent(
478 self: *BootServices,
479 event_type: uefi.EventType,
480 notify_opts: NotifyOpts,
481 ) CreateEventError!Event {
482 var evt: Event = undefined;
483
484 switch (self._createEvent(
485 @bitCast(event_type),
486 notify_opts.tpl,
487 notify_opts.function,
488 notify_opts.context,
489 &evt,
490 )) {
491 .success => return evt,
492 .invalid_parameter => return error.InvalidParameter,
493 .out_of_resources => return error.OutOfResources,
494 else => |status| return uefi.unexpectedStatus(status),
495 }
496 }
497
498 /// Cancels any previous time trigger setting for the event, and sets a new
499 /// trigger timer for the event.
500 ///
501 /// Returns `error.InvalidParameter` if the event is not a timer event.
502 pub fn setTimer(
503 self: *BootServices,
504 event: Event,
505 @"type": TimerDelay,
506 trigger_time: u64,
507 ) SetTimerError!void {
508 switch (self._setTimer(event, @"type", trigger_time)) {
509 .success => {},
510 .invalid_parameter => return error.InvalidParameter,
511 else => |status| return uefi.unexpectedStatus(status),
512 }
513 }
514
515 /// Returns the event that was signaled, along with its index in the slice.
516 pub fn waitForEvent(
517 self: *BootServices,
518 events: []const Event,
519 ) WaitForEventError!struct { *const Event, usize } {
520 var idx: usize = undefined;
521 switch (self._waitForEvent(events.len, events.ptr, &idx)) {
522 .success => return .{ &events[idx], idx },
523 .invalid_parameter => return error.InvalidParameter,
524 .unsupported => return error.Unsupported,
525 else => |status| return uefi.unexpectedStatus(status),
526 }
527 }
528
529 /// If `event` is `EventType.signal`, then the event’s notification function
530 /// is scheduled to be invoked at the event’s notification task priority level.
531 /// This function may be invoked from any task priority level.
532 ///
533 /// If the supplied Event is a part of an event group, then all of the events
534 /// in the event group are also signaled and their notification functions are
535 /// scheduled.
536 ///
537 /// When signaling an event group, it is possible to create an event in the
538 /// group, signal it and then close the event to remove it from the group.
539 pub fn signalEvent(self: *BootServices, event: Event) uefi.UnexpectedError!void {
540 switch (self._signalEvent(event)) {
541 .success => {},
542 else => |status| return uefi.unexpectedStatus(status),
543 }
544 }
545
546 pub fn closeEvent(self: *BootServices, event: Event) uefi.UnexpectedError!void {
547 switch (self._closeEvent(event)) {
548 .success => {},
549 else => |status| return uefi.unexpectedStatus(status),
550 }
551 }
552
553 /// Checks to see whether an event is signaled.
554 ///
555 /// The underlying function is equivalent to this pseudo-code:
556 /// ```
557 /// if (event.type.signal)
558 /// return error.InvalidParameter;
559 ///
560 /// if (event.signaled) {
561 /// event.signaled = false;
562 /// return true;
563 /// }
564 ///
565 /// const notify = event.notification_function orelse return false;
566 /// notify();
567 ///
568 /// if (event.signaled) {
569 /// event.signaled = false;
570 /// return true;
571 /// }
572 ///
573 /// return false;
574 /// ```
575 pub fn checkEvent(self: *BootServices, event: Event) CheckEventError!bool {
576 switch (self._checkEvent(event)) {
577 .success => return true,
578 .not_ready => return false,
579 .invalid_parameter => return error.InvalidParameter,
580 else => |status| return uefi.unexpectedStatus(status),
581 }
582 }
583
584 /// See `installProtocolInterfaces`.
585 ///
586 /// Does not call `self._installProtocolInterface`, because
587 /// `self._installMultipleProtocolInterfaces` performs more error checks.
588 pub fn installProtocolInterface(
589 self: *BootServices,
590 handle: ?Handle,
591 interface: anytype,
592 ) InstallProtocolInterfacesError!Handle {
593 return self.installProtocolInterfaces(handle, .{
594 interface,
595 });
596 }
597
598 /// Reinstalls a protocol interface on a device handle.
599 ///
600 /// `new` may be the same as `old`. If it is, the registered protocol notifications
601 /// occur for the handle without replacing the interface on the handle.
602 ///
603 /// Any process that has registered to wait for the installation of the interface
604 /// is notified.
605 ///
606 /// The caller is responsible for ensuring that there are no references to `old`
607 /// if it is being removed.
608 pub fn reinstallProtocolInterface(
609 self: *BootServices,
610 handle: Handle,
611 Protocol: type,
612 old: ?*const Protocol,
613 new: ?*const Protocol,
614 ) ReinstallProtocolInterfaceError!void {
615 if (!@hasDecl(Protocol, "guid"))
616 @compileError("protocol is missing guid");
617
618 switch (self._reinstallProtocolInterface(
619 handle,
620 &Protocol.guid,
621 old,
622 new,
623 )) {
624 .success => {},
625 .not_found => return error.NotFound,
626 .access_denied => return error.AccessDenied,
627 .invalid_parameter => return error.InvalidParameter,
628 else => |status| return uefi.unexpectedStatus(status),
629 }
630 }
631
632 /// See `uninstallProtocolInterfaces`.
633 ///
634 /// Does not call `self._uninstallProtocolInterface`, because
635 /// `self._uninstallMultipleProtocolInterfaces` performs more error checks.
636 pub fn uninstallProtocolInterface(
637 self: *BootServices,
638 handle: Handle,
639 interface: anytype,
640 ) UninstallProtocolInterfacesError!void {
641 return self.uninstallProtocolInterfaces(handle, .{
642 interface,
643 });
644 }
645
646 /// Returns a pointer to the `Protocol` interface if it's supported by the
647 /// handle.
648 ///
649 /// Note that UEFI implementations are no longer required to implement this
650 /// function, so it's implemented using `openProtocol` instead.
651 pub fn handleProtocol(
652 self: *BootServices,
653 Protocol: type,
654 handle: Handle,
655 ) HandleProtocolError!?*Protocol {
656 // per https://uefi.org/specs/UEFI/2.10/07_Services_Boot_Services.html#efi-boot-services-handleprotocol
657 // handleProtocol is basically `openProtocol` where:
658 // 1. agent_handle is `uefi.handle` (aka handle passed to `EfiMain`)
659 // 2. controller_handle is `null`
660 // 3. attributes is `EFI_OPEN_PROTOCOL_BY_HANDLE_PROTOCOL`
661
662 return self.openProtocol(
663 Protocol,
664 handle,
665 .{ .by_handle_protocol = .{ .agent = uefi.handle } },
666 ) catch |err| switch (err) {
667 error.AlreadyStarted => return uefi.unexpectedStatus(.already_started),
668 error.AccessDenied => return uefi.unexpectedStatus(.access_denied),
669 error.InvalidParameter => return uefi.unexpectedStatus(.invalid_parameter),
670 else => return @errorCast(err),
671 };
672 }
673
674 pub fn registerProtocolNotify(
675 self: *BootServices,
676 Protocol: type,
677 event: Event,
678 ) RegisterProtocolNotifyError!EventRegistration {
679 if (!@hasDecl(Protocol, "guid"))
680 @compileError("Protocol is missing guid");
681
682 var registration: EventRegistration = undefined;
683 switch (self._registerProtocolNotify(
684 &Protocol.guid,
685 event,
686 &registration,
687 )) {
688 .success => return registration,
689 .out_of_resources => return error.OutOfResources,
690 .invalid_parameter => return error.InvalidParameter,
691 else => |status| return uefi.unexpectedStatus(status),
692 }
693 }
694
695 /// Returns the number of handles that match the given search criteria.
696 pub fn locateHandleLen(self: *const BootServices, search: LocateSearch) NumHandlesError!usize {
697 var len: usize = 0;
698 switch (self._locateHandle(
699 std.meta.activeTag(search),
700 if (search == .by_protocol) search.by_protocol else null,
701 if (search == .by_register_notify) search.by_register_notify else null,
702 &len,
703 null,
704 )) {
705 .success => return @divExact(len, @sizeOf(Handle)),
706 .out_of_resources => return error.OutOfResources,
707 else => |status| return uefi.unexpectedStatus(status),
708 }
709 }
710
711 /// To determine the necessary size of `buffer`, call `locateHandleLen` first.
712 pub fn locateHandle(
713 self: *BootServices,
714 search: LocateSearch,
715 buffer: []Handle,
716 ) LocateHandleError![]Handle {
717 var len: usize = @sizeOf(Handle) * buffer.len;
718 switch (self._locateHandle(
719 std.meta.activeTag(search),
720 if (search == .by_protocol) search.by_protocol else null,
721 if (search == .by_register_notify) search.by_register_notify else null,
722 &len,
723 buffer.ptr,
724 )) {
725 .success => return buffer[0..@divExact(len, @sizeOf(Handle))],
726 .not_found => return buffer[0..0],
727 .buffer_too_small => return error.BufferTooSmall,
728 .invalid_parameter => return error.InvalidParameter,
729 else => |status| return uefi.unexpectedStatus(status),
730 }
731 }
732
733 /// Locates all devices on `device_path` that support `Protocol`. Once the closest
734 /// match to `device_path` is found, it returns the unmatched device path and handle.
735 pub fn locateDevicePath(
736 self: *const BootServices,
737 device_path: *const DevicePathProtocol,
738 Protocol: type,
739 ) LocateHandleError!?struct { *const DevicePathProtocol, Handle } {
740 if (!@hasDecl(Protocol, "guid"))
741 @compileError("Protocol is missing guid");
742
743 var dev_path = device_path;
744 var device: ?Handle = undefined;
745 switch (self._locateDevicePath(
746 &Protocol.guid,
747 &dev_path,
748 &device,
749 )) {
750 .success => return .{ dev_path, device.? },
751 .not_found => return null,
752 .invalid_parameter => return error.InvalidParameter,
753 else => |status| return uefi.unexpectedStatus(status),
754 }
755 }
756
757 pub fn installConfigurationTable(
758 self: *BootServices,
759 guid: *const Guid,
760 table: *anyopaque,
761 ) InstallConfigurationTableError!void {
762 switch (self._installConfigurationTable(
763 guid,
764 table,
765 )) {
766 .success => {},
767 .invalid_parameter => return error.InvalidParameter,
768 .out_of_resources => return error.OutOfResources,
769 else => |status| return uefi.unexpectedStatus(status),
770 }
771 }
772
773 pub fn uninstallConfigurationTable(
774 self: *BootServices,
775 guid: *const Guid,
776 ) UninstallConfigurationTableError!void {
777 switch (self._installConfigurationTable(
778 guid,
779 null,
780 )) {
781 .success => {},
782 .not_found => return error.NotFound,
783 .invalid_parameter => return error.InvalidParameter,
784 .out_of_resources => return error.OutOfResources,
785 else => |status| return uefi.unexpectedStatus(status),
786 }
787 }
788
789 pub const LoadImageSource = union(enum) {
790 buffer: []const u8,
791 device_path: *const DevicePathProtocol,
792 };
793
794 pub fn loadImage(
795 self: *BootServices,
796 boot_policy: bool,
797 parent_image: Handle,
798 source: LoadImageSource,
799 ) LoadImageError!Handle {
800 var handle: Handle = undefined;
801
802 switch (self._loadImage(
803 boot_policy,
804 parent_image,
805 if (source == .device_path) source.device_path else null,
806 if (source == .buffer) source.buffer.ptr else null,
807 if (source == .buffer) source.buffer.len else 0,
808 &handle,
809 )) {
810 .success => return handle,
811 .not_found => return error.NotFound,
812 .invalid_parameter => return error.InvalidParameter,
813 .unsupported => return error.Unsupported,
814 .out_of_resources => return error.OutOfResources,
815 .load_error => return error.LoadError,
816 .device_error => return error.DeviceError,
817 .access_denied => return error.AccessDenied,
818 .security_violation => return error.SecurityViolation,
819 else => |status| return uefi.unexpectedStatus(status),
820 }
821 }
822
823 pub fn startImage(self: *BootServices, image: Handle) StartImageError!ImageExitData {
824 var exit_data_size: usize = undefined;
825 var exit_data: [*]u16 = undefined;
826
827 const exit_code = switch (self._startImage(
828 image,
829 &exit_data_size,
830 &exit_data,
831 )) {
832 .invalid_parameter => return error.InvalidParameter,
833 .security_violation => return error.SecurityViolation,
834 else => |exit_code| exit_code,
835 };
836
837 if (exit_data_size == 0) return .{
838 .code = exit_code,
839 .description = null,
840 .data = null,
841 };
842
843 const description_ptr: [*:0]const u16 = @ptrCast(exit_data);
844 const description = std.mem.sliceTo(description_ptr, 0);
845
846 return ImageExitData{
847 .code = exit_code,
848 .description = description,
849 .data = exit_data[description.len + 1 .. exit_data_size],
850 };
851 }
852
853 /// `message` must be allocated using `allocatePool`.
854 pub fn exit(
855 self: *BootServices,
856 handle: Handle,
857 status: Status,
858 message: ?[:0]const u16,
859 ) ExitError!void {
860 switch (self._exit(
861 handle,
862 status,
863 if (message) |msg| (2 * msg.len) + 1 else 0,
864 if (message) |msg| @ptrCast(msg.ptr) else null,
865 )) {
866 .success => {},
867 .invalid_parameter => return error.InvalidParameter,
868 else => |exit_status| return uefi.unexpectedStatus(exit_status),
869 }
870 }
871
872 /// `message` should be a null-terminated u16 string followed by binary data
873 /// allocated using `allocatePool`.
874 pub fn exitWithData(
875 self: *BootServices,
876 handle: Handle,
877 status: Status,
878 data: []align(2) const u8,
879 ) ExitError!void {
880 switch (self._exit(handle, status, data.len, data.ptr)) {
881 .success => {},
882 .invalid_parameter => return error.InvalidParameter,
883 else => |exit_status| return uefi.unexpectedStatus(exit_status),
884 }
885 }
886
887 /// The result is the exit code of the unload handler. Any error codes are
888 /// `try/catch`-able, leaving only success and warning codes as the result.
889 pub fn unloadImage(
890 self: *BootServices,
891 image: Handle,
892 ) Status.Error!Status {
893 const status = self._unloadImage(image);
894 try status.err();
895 return status;
896 }
897
898 pub fn exitBootServices(
899 self: *BootServices,
900 image: Handle,
901 map_key: MemoryMapKey,
902 ) ExitBootServicesError!void {
903 switch (self._exitBootServices(image, map_key)) {
904 .success => {},
905 .invalid_parameter => return error.InvalidParameter,
906 else => |status| return uefi.unexpectedStatus(status),
907 }
908 }
909
910 pub fn getNextMonotonicCount(
911 self: *const BootServices,
912 count: *u64,
913 ) GetNextMonotonicCountError!void {
914 switch (self._getNextMonotonicCount(count)) {
915 .success => {},
916 .device_error => return error.DeviceError,
917 .invalid_parameter => return error.InvalidParameter,
918 else => |status| return uefi.unexpectedStatus(status),
919 }
920 }
921
922 pub fn stall(self: *const BootServices, microseconds: usize) uefi.UnexpectedError!void {
923 switch (self._stall(microseconds)) {
924 .success => {},
925 else => |status| return uefi.unexpectedStatus(status),
926 }
927 }
928
929 pub fn setWatchdogTimer(
930 self: *BootServices,
931 timeout: usize,
932 watchdog_code: u64,
933 data: ?[]const u16,
934 ) SetWatchdogTimerError!void {
935 switch (self._setWatchdogTimer(
936 timeout,
937 watchdog_code,
938 if (data) |d| d.len else 0,
939 if (data) |d| d.ptr else null,
940 )) {
941 .success => {},
942 .invalid_parameter => return error.InvalidParameter,
943 .unsupported => return error.Unsupported,
944 .device_error => return error.DeviceError,
945 else => |status| return uefi.unexpectedStatus(status),
946 }
947 }
948
949 /// `driver_image` should be a null-terminated ordered list of handles.
950 pub fn connectController(
951 self: *BootServices,
952 controller: Handle,
953 driver_image: ?[*:null]?Handle,
954 remaining_device_path: ?*const DevicePathProtocol,
955 recursive: bool,
956 ) ConnectControllerError!void {
957 switch (self._connectController(
958 controller,
959 driver_image,
960 remaining_device_path,
961 recursive,
962 )) {
963 .success => {},
964 .invalid_parameter => return error.InvalidParameter,
965 .not_found => return error.NotFound,
966 .security_violation => return error.SecurityViolation,
967 else => |status| return uefi.unexpectedStatus(status),
968 }
969 }
970
971 pub fn disconnectController(
972 self: *BootServices,
973 controller: Handle,
974 driver_image: ?Handle,
975 child: ?Handle,
976 ) DisconnectControllerError!void {
977 switch (self._disconnectController(
978 controller,
979 driver_image,
980 child,
981 )) {
982 .success => {},
983 .invalid_parameter => return error.InvalidParameter,
984 .out_of_resources => return error.OutOfResources,
985 .device_error => return error.DeviceError,
986 else => |status| return uefi.unexpectedStatus(status),
987 }
988 }
169989
170 /// Opens a protocol with a structure as the loaded image for a UEFI application990 /// Opens a protocol with a structure as the loaded image for a UEFI application
171 pub fn openProtocolSt(self: *BootServices, comptime protocol: type, handle: Handle) !*protocol {991 ///
172 if (!@hasDecl(protocol, "guid"))992 /// If `flag` is `.test_protocol`, then the only valid return value is `null`,
173 @compileError("Protocol is missing guid!");993 /// and `Status.unsupported` is returned. Otherwise, if `_openProtocol` returns
994 /// `Status.unsupported`, then `null` is returned.
995 pub fn openProtocol(
996 self: *BootServices,
997 Protocol: type,
998 handle: Handle,
999 attributes: OpenProtocolArgs,
1000 ) OpenProtocolError!?*Protocol {
1001 if (!@hasDecl(Protocol, "guid"))
1002 @compileError("Protocol is missing guid: " ++ @typeName(Protocol));
1741003
175 var ptr: ?*protocol = undefined;1004 const agent_handle: ?Handle, const controller_handle: ?Handle = switch (attributes) {
1005 inline else => |arg| .{ arg.agent, arg.controller },
1006 };
1761007
177 try self.openProtocol(1008 var ptr: ?*Protocol = undefined;
1009
1010 switch (self._openProtocol(
178 handle,1011 handle,
179 &protocol.guid,1012 &Protocol.guid,
180 @as(*?*anyopaque, @ptrCast(&ptr)),1013 @as(*?*anyopaque, @ptrCast(&ptr)),
181 // Invoking handle (loaded image)1014 agent_handle,
182 uefi.handle,1015 controller_handle,
183 // Control handle (null as not a driver)1016 std.meta.activeTag(attributes),
184 null,1017 )) {
185 uefi.tables.OpenProtocolAttributes{ .by_handle_protocol = true },1018 .success => return if (attributes == .test_protocol) null else ptr,
186 ).err();1019 .unsupported => return if (attributes == .test_protocol) error.Unsupported else null,
1020 .access_denied => return error.AccessDenied,
1021 .already_started => return error.AlreadyStarted,
1022 else => |status| return uefi.unexpectedStatus(status),
1023 }
1024 }
1025
1026 pub fn closeProtocol(
1027 self: *BootServices,
1028 handle: Handle,
1029 Protocol: type,
1030 agent: Handle,
1031 controller: ?Handle,
1032 ) CloseProtocolError!void {
1033 if (!@hasDecl(Protocol, "guid"))
1034 @compileError("protocol is missing guid: " ++ @typeName(Protocol));
1035
1036 switch (self._closeProtocol(
1037 handle,
1038 &Protocol.guid,
1039 agent,
1040 controller,
1041 )) {
1042 .success => {},
1043 .invalid_parameter => return error.InvalidParameter,
1044 .not_found => return error.NotFound,
1045 else => |status| return uefi.unexpectedStatus(status),
1046 }
1047 }
1048
1049 pub fn openProtocolInformation(
1050 self: *const BootServices,
1051 handle: Handle,
1052 Protocol: type,
1053 ) OpenProtocolInformationError!?[]ProtocolInformationEntry {
1054 var entries: [*]ProtocolInformationEntry = undefined;
1055 var len: usize = undefined;
1056
1057 switch (self._openProtocolInformation(
1058 handle,
1059 &Protocol.guid,
1060 &entries,
1061 &len,
1062 )) {
1063 .success => return entries[0..len],
1064 .not_found => return null,
1065 .out_of_resources => return error.OutOfResources,
1066 else => |status| return uefi.unexpectedStatus(status),
1067 }
1068 }
1069
1070 pub fn protocolsPerHandle(
1071 self: *const BootServices,
1072 handle: Handle,
1073 ) ProtocolsPerHandleError![]*const Guid {
1074 var guids: [*]*const Guid = undefined;
1075 var len: usize = undefined;
1076
1077 switch (self._protocolsPerHandle(
1078 handle,
1079 &guids,
1080 &len,
1081 )) {
1082 .success => return guids[0..len],
1083 .invalid_parameter => return error.InvalidParameter,
1084 .out_of_resources => return error.OutOfResources,
1085 else => |status| return uefi.unexpectedStatus(status),
1086 }
1087 }
1088
1089 pub fn locateHandleBuffer(
1090 self: *const BootServices,
1091 search: LocateSearch,
1092 ) LocateHandleBufferError!?[]Handle {
1093 var handles: [*]Handle = undefined;
1094 var len: usize = undefined;
1095
1096 switch (self._locateHandleBuffer(
1097 std.meta.activeTag(search),
1098 if (search == .by_protocol) search.by_protocol else null,
1099 if (search == .by_register_notify) search.by_register_notify else null,
1100 &len,
1101 &handles,
1102 )) {
1103 .success => return handles[0..len],
1104 .invalid_parameter => return error.InvalidParameter,
1105 .not_found => return null,
1106 .out_of_resources => return error.OutOfResources,
1107 else => |status| return uefi.unexpectedStatus(status),
1108 }
1109 }
1110
1111 pub fn locateProtocol(
1112 self: *const BootServices,
1113 Protocol: type,
1114 registration: ?EventRegistration,
1115 ) LocateProtocolError!?*Protocol {
1116 var interface: *Protocol = undefined;
1117
1118 switch (self._locateProtocol(
1119 &Protocol.guid,
1120 registration,
1121 @ptrCast(&interface),
1122 )) {
1123 .success => return interface,
1124 .not_found => return null,
1125 .invalid_parameter => return error.InvalidParameter,
1126 else => |status| return uefi.unexpectedStatus(status),
1127 }
1128 }
1129
1130 /// Installs a set of protocol interfaces into the boot services environment.
1131 ///
1132 /// This function's final argument should be a tuple of pointers to protocol
1133 /// interfaces. For example:
1134 ///
1135 /// ```
1136 /// const handle = try boot_services.installProtocolInterfaces(null, .{
1137 /// &my_interface_1,
1138 /// &my_interface_2,
1139 /// });
1140 /// ```
1141 ///
1142 /// The underlying function accepts a vararg list of pairs of Guid pointers
1143 /// and opaque pointers to the interface. To provide a guid, the interface
1144 /// types should declare a `guid` constant like so:
1145 ///
1146 /// ```
1147 /// pub const guid: uefi.Guid = .{ ... };
1148 /// ```
1149 ///
1150 /// See `std.os.uefi.protocol` for examples of protocol type definitions.
1151 pub fn installProtocolInterfaces(
1152 self: *BootServices,
1153 handle: ?Handle,
1154 interfaces: anytype,
1155 ) InstallProtocolInterfacesError!Handle {
1156 var hdl: ?Handle = handle;
1157 const args_tuple = protocolInterfaces(&hdl, interfaces);
1158
1159 switch (@call(
1160 .auto,
1161 self._installMultipleProtocolInterfaces,
1162 args_tuple,
1163 )) {
1164 .success => return hdl.?,
1165 .already_started => return error.AlreadyStarted,
1166 .out_of_resources => return error.OutOfResources,
1167 .invalid_parameter => return error.InvalidParameter,
1168 else => |status| return uefi.unexpectedStatus(status),
1169 }
1170 }
1171
1172 pub fn uninstallProtocolInterfaces(
1173 self: *BootServices,
1174 handle: Handle,
1175 interfaces: anytype,
1176 ) UninstallProtocolInterfacesError!void {
1177 const args_tuple = protocolInterfaces(handle, interfaces);
1871178
188 return ptr.?;1179 switch (@call(
1180 .auto,
1181 self._uninstallMultipleProtocolInterfaces,
1182 args_tuple,
1183 )) {
1184 .success => {},
1185 .invalid_parameter => return error.InvalidParameter,
1186 else => |status| return uefi.unexpectedStatus(status),
1187 }
1188 }
1189
1190 pub fn calculateCrc32(
1191 self: *const BootServices,
1192 data: []const u8,
1193 ) CalculateCrc32Error!u32 {
1194 var value: u32 = undefined;
1195 switch (self._calculateCrc32(data.ptr, data.len, &value)) {
1196 .success => return value,
1197 .invalid_parameter => return error.InvalidParameter,
1198 else => |status| return uefi.unexpectedStatus(status),
1199 }
189 }1200 }
1901201
191 pub const signature: u64 = 0x56524553544f4f42;1202 pub const signature: u64 = 0x56524553544f4f42;
1921203
193 pub const event_timer: u32 = 0x80000000;1204 pub const NotifyOpts = struct {
194 pub const event_runtime: u32 = 0x40000000;1205 tpl: TaskPriorityLevel = .application,
195 pub const event_notify_wait: u32 = 0x00000100;1206 function: ?*const fn (Event, ?*anyopaque) callconv(cc) void = null,
196 pub const event_notify_signal: u32 = 0x00000200;1207 context: ?*anyopaque = null,
197 pub const event_signal_exit_boot_services: u32 = 0x00000201;1208 };
198 pub const event_signal_virtual_address_change: u32 = 0x00000202;1209
1991210 pub const TaskPriorityLevel = enum(usize) {
200 pub const tpl_application: usize = 4;1211 application = 4,
201 pub const tpl_callback: usize = 8;1212 callback = 8,
202 pub const tpl_notify: usize = 16;1213 notify = 16,
203 pub const tpl_high_level: usize = 31;1214 high_level = 31,
1215 _,
1216 };
1217
1218 pub const ImageExitData = struct {
1219 code: Status,
1220 description: ?[:0]const u16,
1221 data: ?[]const u16,
1222 };
204};1223};
1224
1225fn protocolInterfaces(
1226 handle_arg: anytype,
1227 interfaces: anytype,
1228) ProtocolInterfaces(@TypeOf(handle_arg), @TypeOf(interfaces)) {
1229 var result: ProtocolInterfaces(
1230 @TypeOf(handle_arg),
1231 @TypeOf(interfaces),
1232 ) = undefined;
1233 result[0] = handle_arg;
1234
1235 var idx: usize = 1;
1236 inline for (interfaces) |interface| {
1237 const InterfacePtr = @TypeOf(interface);
1238 const Interface = switch (@typeInfo(InterfacePtr)) {
1239 .pointer => |pointer| pointer.child,
1240 else => @compileError("expected tuple of '*const Protocol', got " ++ @typeName(InterfacePtr)),
1241 };
1242
1243 if (!@hasDecl(Interface, "guid"))
1244 @compileError("protocol interface '" ++ @typeName(Interface) ++
1245 "' does not declare a 'const guid: uefi.Guid'.");
1246
1247 switch (@typeInfo(Interface)) {
1248 .@"struct" => |struct_info| if (struct_info.layout != .@"extern")
1249 @compileLog("protocol interface '" ++ @typeName(Interface) ++
1250 "' is not extern - this is likely a mistake"),
1251 else => @compileError("protocol interface must be a struct, got " ++ @typeName(Interface)),
1252 }
1253
1254 result[idx] = &Interface.guid;
1255 result[idx + 1] = @ptrCast(interface);
1256 idx += 2;
1257 }
1258
1259 return result;
1260}
1261
1262fn ProtocolInterfaces(HandleType: type, Interfaces: type) type {
1263 const interfaces_type_info = @typeInfo(Interfaces);
1264 if (interfaces_type_info != .@"struct" or !interfaces_type_info.@"struct".is_tuple)
1265 @compileError("expected tuple of protocol interfaces, got " ++ @typeName(Interfaces));
1266 const interfaces_info = interfaces_type_info.@"struct";
1267
1268 var tuple_types: [interfaces_info.fields.len * 2 + 1]type = undefined;
1269 tuple_types[0] = HandleType;
1270 var idx = 1;
1271 while (idx < tuple_types.len) : (idx += 2) {
1272 tuple_types[idx] = *const Guid;
1273 tuple_types[idx + 1] = *const anyopaque;
1274 }
1275
1276 return std.meta.Tuple(tuple_types[0..]);
1277}
lib/std/os/uefi/tables/configuration_table.zig+9-9
...@@ -5,7 +5,7 @@ pub const ConfigurationTable = extern struct {...@@ -5,7 +5,7 @@ pub const ConfigurationTable = extern struct {
5 vendor_guid: Guid,5 vendor_guid: Guid,
6 vendor_table: *anyopaque,6 vendor_table: *anyopaque,
77
8 pub const acpi_20_table_guid align(8) = Guid{8 pub const acpi_20_table_guid: Guid = .{
9 .time_low = 0x8868e871,9 .time_low = 0x8868e871,
10 .time_mid = 0xe4f1,10 .time_mid = 0xe4f1,
11 .time_high_and_version = 0x11d3,11 .time_high_and_version = 0x11d3,
...@@ -13,7 +13,7 @@ pub const ConfigurationTable = extern struct {...@@ -13,7 +13,7 @@ pub const ConfigurationTable = extern struct {
13 .clock_seq_low = 0x22,13 .clock_seq_low = 0x22,
14 .node = [_]u8{ 0x00, 0x80, 0xc7, 0x3c, 0x88, 0x81 },14 .node = [_]u8{ 0x00, 0x80, 0xc7, 0x3c, 0x88, 0x81 },
15 };15 };
16 pub const acpi_10_table_guid align(8) = Guid{16 pub const acpi_10_table_guid: Guid = .{
17 .time_low = 0xeb9d2d30,17 .time_low = 0xeb9d2d30,
18 .time_mid = 0x2d88,18 .time_mid = 0x2d88,
19 .time_high_and_version = 0x11d3,19 .time_high_and_version = 0x11d3,
...@@ -21,7 +21,7 @@ pub const ConfigurationTable = extern struct {...@@ -21,7 +21,7 @@ pub const ConfigurationTable = extern struct {
21 .clock_seq_low = 0x16,21 .clock_seq_low = 0x16,
22 .node = [_]u8{ 0x00, 0x90, 0x27, 0x3f, 0xc1, 0x4d },22 .node = [_]u8{ 0x00, 0x90, 0x27, 0x3f, 0xc1, 0x4d },
23 };23 };
24 pub const sal_system_table_guid align(8) = Guid{24 pub const sal_system_table_guid: Guid = .{
25 .time_low = 0xeb9d2d32,25 .time_low = 0xeb9d2d32,
26 .time_mid = 0x2d88,26 .time_mid = 0x2d88,
27 .time_high_and_version = 0x113d,27 .time_high_and_version = 0x113d,
...@@ -29,7 +29,7 @@ pub const ConfigurationTable = extern struct {...@@ -29,7 +29,7 @@ pub const ConfigurationTable = extern struct {
29 .clock_seq_low = 0x16,29 .clock_seq_low = 0x16,
30 .node = [_]u8{ 0x00, 0x90, 0x27, 0x3f, 0xc1, 0x4d },30 .node = [_]u8{ 0x00, 0x90, 0x27, 0x3f, 0xc1, 0x4d },
31 };31 };
32 pub const smbios_table_guid align(8) = Guid{32 pub const smbios_table_guid: Guid = .{
33 .time_low = 0xeb9d2d31,33 .time_low = 0xeb9d2d31,
34 .time_mid = 0x2d88,34 .time_mid = 0x2d88,
35 .time_high_and_version = 0x11d3,35 .time_high_and_version = 0x11d3,
...@@ -37,7 +37,7 @@ pub const ConfigurationTable = extern struct {...@@ -37,7 +37,7 @@ pub const ConfigurationTable = extern struct {
37 .clock_seq_low = 0x16,37 .clock_seq_low = 0x16,
38 .node = [_]u8{ 0x00, 0x90, 0x27, 0x3f, 0xc1, 0x4d },38 .node = [_]u8{ 0x00, 0x90, 0x27, 0x3f, 0xc1, 0x4d },
39 };39 };
40 pub const smbios3_table_guid align(8) = Guid{40 pub const smbios3_table_guid: Guid = .{
41 .time_low = 0xf2fd1544,41 .time_low = 0xf2fd1544,
42 .time_mid = 0x9794,42 .time_mid = 0x9794,
43 .time_high_and_version = 0x4a2c,43 .time_high_and_version = 0x4a2c,
...@@ -45,7 +45,7 @@ pub const ConfigurationTable = extern struct {...@@ -45,7 +45,7 @@ pub const ConfigurationTable = extern struct {
45 .clock_seq_low = 0x2e,45 .clock_seq_low = 0x2e,
46 .node = [_]u8{ 0xe5, 0xbb, 0xcf, 0x20, 0xe3, 0x94 },46 .node = [_]u8{ 0xe5, 0xbb, 0xcf, 0x20, 0xe3, 0x94 },
47 };47 };
48 pub const mps_table_guid align(8) = Guid{48 pub const mps_table_guid: Guid = .{
49 .time_low = 0xeb9d2d2f,49 .time_low = 0xeb9d2d2f,
50 .time_mid = 0x2d88,50 .time_mid = 0x2d88,
51 .time_high_and_version = 0x11d3,51 .time_high_and_version = 0x11d3,
...@@ -53,7 +53,7 @@ pub const ConfigurationTable = extern struct {...@@ -53,7 +53,7 @@ pub const ConfigurationTable = extern struct {
53 .clock_seq_low = 0x16,53 .clock_seq_low = 0x16,
54 .node = [_]u8{ 0x00, 0x90, 0x27, 0x3f, 0xc1, 0x4d },54 .node = [_]u8{ 0x00, 0x90, 0x27, 0x3f, 0xc1, 0x4d },
55 };55 };
56 pub const json_config_data_table_guid align(8) = Guid{56 pub const json_config_data_table_guid: Guid = .{
57 .time_low = 0x87367f87,57 .time_low = 0x87367f87,
58 .time_mid = 0x1119,58 .time_mid = 0x1119,
59 .time_high_and_version = 0x41ce,59 .time_high_and_version = 0x41ce,
...@@ -61,7 +61,7 @@ pub const ConfigurationTable = extern struct {...@@ -61,7 +61,7 @@ pub const ConfigurationTable = extern struct {
61 .clock_seq_low = 0xec,61 .clock_seq_low = 0xec,
62 .node = [_]u8{ 0x8b, 0xe0, 0x11, 0x1f, 0x55, 0x8a },62 .node = [_]u8{ 0x8b, 0xe0, 0x11, 0x1f, 0x55, 0x8a },
63 };63 };
64 pub const json_capsule_data_table_guid align(8) = Guid{64 pub const json_capsule_data_table_guid: Guid = .{
65 .time_low = 0x35e7a725,65 .time_low = 0x35e7a725,
66 .time_mid = 0x8dd2,66 .time_mid = 0x8dd2,
67 .time_high_and_version = 0x4cac,67 .time_high_and_version = 0x4cac,
...@@ -69,7 +69,7 @@ pub const ConfigurationTable = extern struct {...@@ -69,7 +69,7 @@ pub const ConfigurationTable = extern struct {
69 .clock_seq_low = 0x11,69 .clock_seq_low = 0x11,
70 .node = [_]u8{ 0x33, 0xcd, 0xa8, 0x10, 0x90, 0x56 },70 .node = [_]u8{ 0x33, 0xcd, 0xa8, 0x10, 0x90, 0x56 },
71 };71 };
72 pub const json_capsule_result_table_guid align(8) = Guid{72 pub const json_capsule_result_table_guid: Guid = .{
73 .time_low = 0xdbc461c3,73 .time_low = 0xdbc461c3,
74 .time_mid = 0xb3de,74 .time_mid = 0xb3de,
75 .time_high_and_version = 0x422a,75 .time_high_and_version = 0x422a,
lib/std/os/uefi/tables/runtime_services.zig+477-14
...@@ -6,10 +6,12 @@ const Time = uefi.Time;...@@ -6,10 +6,12 @@ const Time = uefi.Time;
6const TimeCapabilities = uefi.TimeCapabilities;6const TimeCapabilities = uefi.TimeCapabilities;
7const Status = uefi.Status;7const Status = uefi.Status;
8const MemoryDescriptor = uefi.tables.MemoryDescriptor;8const MemoryDescriptor = uefi.tables.MemoryDescriptor;
9const MemoryMapSlice = uefi.tables.MemoryMapSlice;
9const ResetType = uefi.tables.ResetType;10const ResetType = uefi.tables.ResetType;
10const CapsuleHeader = uefi.tables.CapsuleHeader;11const CapsuleHeader = uefi.tables.CapsuleHeader;
11const PhysicalAddress = uefi.tables.PhysicalAddress;12const PhysicalAddress = uefi.tables.PhysicalAddress;
12const cc = uefi.cc;13const cc = uefi.cc;
14const Error = Status.Error;
1315
14/// Runtime services are provided by the firmware before and after exitBootServices has been called.16/// Runtime services are provided by the firmware before and after exitBootServices has been called.
15///17///
...@@ -23,50 +25,511 @@ pub const RuntimeServices = extern struct {...@@ -23,50 +25,511 @@ pub const RuntimeServices = extern struct {
23 hdr: TableHeader,25 hdr: TableHeader,
2426
25 /// Returns the current time and date information, and the time-keeping capabilities of the hardware platform.27 /// Returns the current time and date information, and the time-keeping capabilities of the hardware platform.
26 getTime: *const fn (time: *uefi.Time, capabilities: ?*TimeCapabilities) callconv(cc) Status,28 _getTime: *const fn (time: *Time, capabilities: ?*TimeCapabilities) callconv(cc) Status,
2729
28 /// Sets the current local time and date information30 /// Sets the current local time and date information
29 setTime: *const fn (time: *uefi.Time) callconv(cc) Status,31 _setTime: *const fn (time: *const Time) callconv(cc) Status,
3032
31 /// Returns the current wakeup alarm clock setting33 /// Returns the current wakeup alarm clock setting
32 getWakeupTime: *const fn (enabled: *bool, pending: *bool, time: *uefi.Time) callconv(cc) Status,34 _getWakeupTime: *const fn (enabled: *bool, pending: *bool, time: *Time) callconv(cc) Status,
3335
34 /// Sets the system wakeup alarm clock time36 /// Sets the system wakeup alarm clock time
35 setWakeupTime: *const fn (enable: *bool, time: ?*uefi.Time) callconv(cc) Status,37 _setWakeupTime: *const fn (enable: bool, time: ?*const Time) callconv(cc) Status,
3638
37 /// Changes the runtime addressing mode of EFI firmware from physical to virtual.39 /// Changes the runtime addressing mode of EFI firmware from physical to virtual.
38 setVirtualAddressMap: *const fn (mmap_size: usize, descriptor_size: usize, descriptor_version: u32, virtual_map: [*]MemoryDescriptor) callconv(cc) Status,40 _setVirtualAddressMap: *const fn (mmap_size: usize, descriptor_size: usize, descriptor_version: u32, virtual_map: [*]align(@alignOf(MemoryDescriptor)) u8) callconv(cc) Status,
3941
40 /// Determines the new virtual address that is to be used on subsequent memory accesses.42 /// Determines the new virtual address that is to be used on subsequent memory accesses.
41 convertPointer: *const fn (debug_disposition: usize, address: **anyopaque) callconv(cc) Status,43 _convertPointer: *const fn (debug_disposition: DebugDisposition, address: *?*anyopaque) callconv(cc) Status,
4244
43 /// Returns the value of a variable.45 /// Returns the value of a variable.
44 getVariable: *const fn (var_name: [*:0]const u16, vendor_guid: *align(8) const Guid, attributes: ?*u32, data_size: *usize, data: ?*anyopaque) callconv(cc) Status,46 _getVariable: *const fn (var_name: [*:0]const u16, vendor_guid: *const Guid, attributes: ?*VariableAttributes, data_size: *usize, data: ?*anyopaque) callconv(cc) Status,
4547
46 /// Enumerates the current variable names.48 /// Enumerates the current variable names.
47 getNextVariableName: *const fn (var_name_size: *usize, var_name: [*:0]u16, vendor_guid: *align(8) Guid) callconv(cc) Status,49 _getNextVariableName: *const fn (var_name_size: *usize, var_name: ?[*:0]const u16, vendor_guid: *Guid) callconv(cc) Status,
4850
49 /// Sets the value of a variable.51 /// Sets the value of a variable.
50 setVariable: *const fn (var_name: [*:0]const u16, vendor_guid: *align(8) const Guid, attributes: u32, data_size: usize, data: *anyopaque) callconv(cc) Status,52 _setVariable: *const fn (var_name: [*:0]const u16, vendor_guid: *const Guid, attributes: VariableAttributes, data_size: usize, data: [*]const u8) callconv(cc) Status,
5153
52 /// Return the next high 32 bits of the platform's monotonic counter54 /// Return the next high 32 bits of the platform's monotonic counter
53 getNextHighMonotonicCount: *const fn (high_count: *u32) callconv(cc) Status,55 _getNextHighMonotonicCount: *const fn (high_count: *u32) callconv(cc) Status,
5456
55 /// Resets the entire platform.57 /// Resets the entire platform.
56 resetSystem: *const fn (reset_type: ResetType, reset_status: Status, data_size: usize, reset_data: ?*const anyopaque) callconv(cc) noreturn,58 _resetSystem: *const fn (reset_type: ResetType, reset_status: Status, data_size: usize, reset_data: ?[*]const u16) callconv(cc) noreturn,
5759
58 /// Passes capsules to the firmware with both virtual and physical mapping.60 /// Passes capsules to the firmware with both virtual and physical mapping.
59 /// Depending on the intended consumption, the firmware may process the capsule immediately.61 /// Depending on the intended consumption, the firmware may process the capsule immediately.
60 /// If the payload should persist across a system reset, the reset value returned from62 /// If the payload should persist across a system reset, the reset value returned from
61 /// `queryCapsuleCapabilities` must be passed into resetSystem and will cause the capsule63 /// `queryCapsuleCapabilities` must be passed into resetSystem and will cause the capsule
62 /// to be processed by the firmware as part of the reset process.64 /// to be processed by the firmware as part of the reset process.
63 updateCapsule: *const fn (capsule_header_array: **CapsuleHeader, capsule_count: usize, scatter_gather_list: PhysicalAddress) callconv(cc) Status,65 _updateCapsule: *const fn (capsule_header_array: [*]*const CapsuleHeader, capsule_count: usize, scatter_gather_list: PhysicalAddress) callconv(cc) Status,
6466
65 /// Returns if the capsule can be supported via `updateCapsule`67 /// Returns if the capsule can be supported via `updateCapsule`
66 queryCapsuleCapabilities: *const fn (capsule_header_array: **CapsuleHeader, capsule_count: usize, maximum_capsule_size: *usize, reset_type: ResetType) callconv(cc) Status,68 _queryCapsuleCapabilities: *const fn (capsule_header_array: [*]*const CapsuleHeader, capsule_count: usize, maximum_capsule_size: *usize, reset_type: *ResetType) callconv(cc) Status,
6769
68 /// Returns information about the EFI variables70 /// Returns information about the EFI variables
69 queryVariableInfo: *const fn (attributes: *u32, maximum_variable_storage_size: *u64, remaining_variable_storage_size: *u64, maximum_variable_size: *u64) callconv(cc) Status,71 _queryVariableInfo: *const fn (attributes: VariableAttributes, maximum_variable_storage_size: *u64, remaining_variable_storage_size: *u64, maximum_variable_size: *u64) callconv(cc) Status,
72
73 pub const GetTimeError = uefi.UnexpectedError || error{
74 DeviceError,
75 Unsupported,
76 };
77
78 pub const SetTimeError = uefi.UnexpectedError || error{
79 DeviceError,
80 Unsupported,
81 };
82
83 pub const GetWakeupTimeError = uefi.UnexpectedError || error{
84 DeviceError,
85 Unsupported,
86 };
87
88 pub const SetWakeupTimeError = uefi.UnexpectedError || error{
89 InvalidParameter,
90 DeviceError,
91 Unsupported,
92 };
93
94 pub const SetVirtualAddressMapError = uefi.UnexpectedError || error{
95 Unsupported,
96 NoMapping,
97 NotFound,
98 };
99
100 pub const ConvertPointerError = uefi.UnexpectedError || error{
101 InvalidParameter,
102 Unsupported,
103 };
104
105 pub const GetVariableSizeError = uefi.UnexpectedError || error{
106 DeviceError,
107 Unsupported,
108 };
109
110 pub const GetVariableError = GetVariableSizeError || error{
111 BufferTooSmall,
112 };
113
114 pub const SetVariableError = uefi.UnexpectedError || error{
115 InvalidParameter,
116 OutOfResources,
117 DeviceError,
118 WriteProtected,
119 SecurityViolation,
120 NotFound,
121 Unsupported,
122 };
123
124 pub const GetNextHighMonotonicCountError = uefi.UnexpectedError || error{
125 DeviceError,
126 Unsupported,
127 };
128
129 pub const UpdateCapsuleError = uefi.UnexpectedError || error{
130 InvalidParameter,
131 DeviceError,
132 Unsupported,
133 OutOfResources,
134 };
135
136 pub const QueryCapsuleCapabilitiesError = uefi.UnexpectedError || error{
137 Unsupported,
138 OutOfResources,
139 };
140
141 pub const QueryVariableInfoError = uefi.UnexpectedError || error{
142 InvalidParameter,
143 Unsupported,
144 };
145
146 /// Returns the current time and the time capabilities of the platform.
147 pub fn getTime(
148 self: *const RuntimeServices,
149 ) GetTimeError!struct { Time, TimeCapabilities } {
150 var time: Time = undefined;
151 var capabilities: TimeCapabilities = undefined;
152
153 switch (self._getTime(&time, &capabilities)) {
154 .success => return .{ time, capabilities },
155 .device_error => return error.DeviceError,
156 .unsupported => return error.Unsupported,
157 else => |status| return uefi.unexpectedStatus(status),
158 }
159 }
160
161 pub fn setTime(self: *RuntimeServices, time: *const Time) SetTimeError!void {
162 switch (self._setTime(time)) {
163 .success => {},
164 .device_error => return error.DeviceError,
165 .unsupported => return error.Unsupported,
166 else => |status| return uefi.unexpectedStatus(status),
167 }
168 }
169
170 pub const GetWakeupTime = struct {
171 enabled: bool,
172 pending: bool,
173 time: Time,
174 };
175
176 pub fn getWakeupTime(
177 self: *const RuntimeServices,
178 ) GetWakeupTimeError!GetWakeupTime {
179 var result: GetWakeupTime = undefined;
180 switch (self._getWakeupTime(
181 &result.enabled,
182 &result.pending,
183 &result.time,
184 )) {
185 .success => return result,
186 .device_error => return error.DeviceError,
187 .unsupported => return error.Unsupported,
188 else => |status| return uefi.unexpectedStatus(status),
189 }
190 }
191
192 pub const SetWakeupTime = union(enum) {
193 enabled: *const Time,
194 disabled,
195 };
196
197 pub fn setWakeupTime(
198 self: *RuntimeServices,
199 set: SetWakeupTime,
200 ) SetWakeupTimeError!void {
201 switch (self._setWakeupTime(
202 set != .disabled,
203 if (set == .enabled) set.enabled else null,
204 )) {
205 .success => {},
206 .invalid_parameter => return error.InvalidParameter,
207 .device_error => return error.DeviceError,
208 .unsupported => return error.Unsupported,
209 else => |status| return uefi.unexpectedStatus(status),
210 }
211 }
212
213 pub fn setVirtualAddressMap(
214 self: *RuntimeServices,
215 map: MemoryMapSlice,
216 ) SetVirtualAddressMapError!void {
217 switch (self._setVirtualAddressMap(
218 map.info.len * map.info.descriptor_size,
219 map.info.descriptor_size,
220 map.info.descriptor_version,
221 @ptrCast(map.ptr),
222 )) {
223 .success => {},
224 .unsupported => return error.Unsupported,
225 .no_mapping => return error.NoMapping,
226 .not_found => return error.NotFound,
227 else => |status| return uefi.unexpectedStatus(status),
228 }
229 }
230
231 pub fn convertPointer(
232 self: *const RuntimeServices,
233 comptime disposition: DebugDisposition,
234 cvt: @FieldType(PointerConversion, @tagName(disposition)),
235 ) ConvertPointerError!?@FieldType(PointerConversion, @tagName(disposition)) {
236 var pointer = cvt;
237
238 switch (self._convertPointer(disposition, @ptrCast(&pointer))) {
239 .success => return pointer,
240 .not_found => return null,
241 .invalid_parameter => return error.InvalidParameter,
242 .unsupported => return error.Unsupported,
243 else => |status| return uefi.unexpectedStatus(status),
244 }
245 }
246
247 /// Returns the length of the variable's data and its attributes.
248 pub fn getVariableSize(
249 self: *const RuntimeServices,
250 name: [*:0]const u16,
251 guid: *const Guid,
252 ) GetVariableSizeError!?struct { usize, VariableAttributes } {
253 var size: usize = 0;
254 var attrs: VariableAttributes = undefined;
255
256 switch (self._getVariable(
257 name,
258 guid,
259 &attrs,
260 &size,
261 null,
262 )) {
263 .buffer_too_small => return .{ size, attrs },
264 .not_found => return null,
265 .device_error => return error.DeviceError,
266 .unsupported => return error.Unsupported,
267 else => |status| return uefi.unexpectedStatus(status),
268 }
269 }
270
271 /// To determine the minimum necessary buffer size for the variable, call
272 /// `getVariableSize` first.
273 pub fn getVariable(
274 self: *const RuntimeServices,
275 name: [*:0]const u16,
276 guid: *const Guid,
277 buffer: []u8,
278 ) GetVariableError!?struct { []u8, VariableAttributes } {
279 var attrs: VariableAttributes = undefined;
280 var len = buffer.len;
281
282 switch (self._getVariable(
283 name,
284 guid,
285 &attrs,
286 &len,
287 buffer.ptr,
288 )) {
289 .success => return .{ buffer[0..len], attrs },
290 .not_found => return null,
291 .buffer_too_small => return error.BufferTooSmall,
292 .device_error => return error.DeviceError,
293 .unsupported => return error.Unsupported,
294 else => |status| return uefi.unexpectedStatus(status),
295 }
296 }
297
298 pub fn variableNameIterator(
299 self: *const RuntimeServices,
300 buffer: []u16,
301 ) VariableNameIterator {
302 buffer[0] = 0;
303 return .{
304 .services = self,
305 .buffer = buffer,
306 .guid = undefined,
307 };
308 }
309
310 pub fn setVariable(
311 self: *RuntimeServices,
312 name: [*:0]const u16,
313 guid: *const Guid,
314 attributes: VariableAttributes,
315 data: []const u8,
316 ) SetVariableError!void {
317 switch (self._setVariable(
318 name,
319 guid,
320 attributes,
321 data.len,
322 data.ptr,
323 )) {
324 .success => {},
325 .invalid_parameter => return error.InvalidParameter,
326 .out_of_resources => return error.OutOfResources,
327 .device_error => return error.DeviceError,
328 .write_protected => return error.WriteProtected,
329 .security_violation => return error.SecurityViolation,
330 .not_found => return error.NotFound,
331 .unsupported => return error.Unsupported,
332 else => |status| return uefi.unexpectedStatus(status),
333 }
334 }
335
336 pub fn getNextHighMonotonicCount(self: *const RuntimeServices) GetNextHighMonotonicCountError!u32 {
337 var cnt: u32 = undefined;
338 switch (self._getNextHighMonotonicCount(&cnt)) {
339 .success => return cnt,
340 .device_error => return error.DeviceError,
341 .unsupported => return error.Unsupported,
342 else => |status| return uefi.unexpectedStatus(status),
343 }
344 }
345
346 pub fn resetSystem(
347 self: *RuntimeServices,
348 reset_type: ResetType,
349 reset_status: Status,
350 data: ?[]align(2) const u8,
351 ) noreturn {
352 self._resetSystem(
353 reset_type,
354 reset_status,
355 if (data) |d| d.len else 0,
356 if (data) |d| @alignCast(@ptrCast(d.ptr)) else null,
357 );
358 }
359
360 pub fn updateCapsule(
361 self: *RuntimeServices,
362 capsules: []*const CapsuleHeader,
363 scatter_gather_list: PhysicalAddress,
364 ) UpdateCapsuleError!void {
365 switch (self._updateCapsule(
366 capsules.ptr,
367 capsules.len,
368 scatter_gather_list,
369 )) {
370 .success => {},
371 .invalid_parameter => return error.InvalidParameter,
372 .device_error => return error.DeviceError,
373 .unsupported => return error.Unsupported,
374 .out_of_resources => return error.OutOfResources,
375 else => |status| return uefi.unexpectedStatus(status),
376 }
377 }
378
379 pub fn queryCapsuleCapabilities(
380 self: *const RuntimeServices,
381 capsules: []*const CapsuleHeader,
382 ) QueryCapsuleCapabilitiesError!struct { u64, ResetType } {
383 var max_capsule_size: u64 = undefined;
384 var reset_type: ResetType = undefined;
385
386 switch (self._queryCapsuleCapabilities(
387 capsules.ptr,
388 capsules.len,
389 &max_capsule_size,
390 &reset_type,
391 )) {
392 .success => return .{ max_capsule_size, reset_type },
393 .unsupported => return error.Unsupported,
394 .out_of_resources => return error.OutOfResources,
395 else => |status| return uefi.unexpectedStatus(status),
396 }
397 }
398
399 pub fn queryVariableInfo(
400 self: *const RuntimeServices,
401 // Note: .append_write is ignored
402 attributes: VariableAttributes,
403 ) QueryVariableInfoError!VariableInfo {
404 var res: VariableInfo = undefined;
405
406 switch (self._queryVariableInfo(
407 attributes,
408 &res.max_variable_storage_size,
409 &res.remaining_variable_storage_size,
410 &res.max_variable_size,
411 )) {
412 .success => return res,
413 .invalid_parameter => return error.InvalidParameter,
414 .unsupported => return error.Unsupported,
415 else => |status| return uefi.unexpectedStatus(status),
416 }
417 }
418
419 pub const DebugDisposition = enum(usize) {
420 const Bits = packed struct(usize) {
421 optional_ptr: bool = false,
422 _pad: std.meta.Int(.unsigned, @bitSizeOf(usize) - 1) = 0,
423 };
424
425 pointer = @bitCast(Bits{}),
426 optional = @bitCast(Bits{ .optional_ptr = true }),
427 _,
428 };
429
430 pub const PointerConversion = union(DebugDisposition) {
431 pointer: *anyopaque,
432 optional: ?*anyopaque,
433 };
434
435 pub const VariableAttributes = packed struct(u32) {
436 non_volatile: bool = false,
437 bootservice_access: bool = false,
438 runtime_access: bool = false,
439 hardware_error_record: bool = false,
440 /// Note: deprecated and should be considered reserved.
441 authenticated_write_access: bool = false,
442 time_based_authenticated_write_access: bool = false,
443 append_write: bool = false,
444 /// Indicates that the variable payload begins with a EFI_VARIABLE_AUTHENTICATION_3
445 /// structure, and potentially more structures as indicated by fields of
446 /// this structure.
447 enhanced_authenticated_access: bool = false,
448 _pad: u24 = 0,
449 };
450
451 pub const VariableAuthentication3 = extern struct {
452 version: u8 = 1,
453 type: Type,
454 metadata_size: u32,
455 flags: Flags,
456
457 pub fn payloadConst(self: *const VariableAuthentication3) []const u8 {
458 return @constCast(self).payload();
459 }
460
461 pub fn payload(self: *VariableAuthentication3) []u8 {
462 var ptr: [*]u8 = @ptrCast(self);
463 return ptr[@sizeOf(VariableAuthentication3)..self.metadata_size];
464 }
465
466 pub const Flags = packed struct(u32) {
467 update_cert: bool = false,
468 _pad: u31 = 0,
469 };
470
471 pub const Type = enum(u8) {
472 timestamp = 1,
473 nonce = 2,
474 _,
475 };
476 };
477
478 pub const VariableInfo = struct {
479 max_variable_storage_size: u64,
480 remaining_variable_storage_size: u64,
481 max_variable_size: u64,
482 };
483
484 pub const VariableNameIterator = struct {
485 pub const NextSizeError = uefi.UnexpectedError || error{
486 DeviceError,
487 Unsupported,
488 };
489
490 pub const IterateVariableNameError = NextSizeError || error{
491 BufferTooSmall,
492 };
493
494 services: *const RuntimeServices,
495 buffer: []u16,
496 guid: Guid,
497
498 pub fn nextSize(self: *VariableNameIterator) NextSizeError!?usize {
499 var len: usize = 0;
500 switch (self.services._getNextVariableName(
501 &len,
502 null,
503 &self.guid,
504 )) {
505 .buffer_too_small => return len,
506 .not_found => return null,
507 .device_error => return error.DeviceError,
508 .unsupported => return error.Unsupported,
509 else => |status| return uefi.unexpectedStatus(status),
510 }
511 }
512
513 /// Call `nextSize` to get the length of the next variable name and check
514 /// if `buffer` is large enough to hold the name.
515 pub fn next(
516 self: *VariableNameIterator,
517 ) IterateVariableNameError!?[:0]const u16 {
518 var len = self.buffer.len;
519 switch (self.services._getNextVariableName(
520 &len,
521 @ptrCast(self.buffer.ptr),
522 &self.guid,
523 )) {
524 .success => return self.buffer[0 .. len - 1 :0],
525 .not_found => return null,
526 .buffer_too_small => return error.BufferTooSmall,
527 .device_error => return error.DeviceError,
528 .unsupported => return error.Unsupported,
529 else => |status| return uefi.unexpectedStatus(status),
530 }
531 }
532 };
70533
71 pub const signature: u64 = 0x56524553544e5552;534 pub const signature: u64 = 0x56524553544e5552;
72};535};
lib/std/os/windows.zig+1-4
...@@ -146,7 +146,7 @@ pub fn OpenFile(sub_path_w: []const u16, options: OpenFileOptions) OpenError!HAN...@@ -146,7 +146,7 @@ pub fn OpenFile(sub_path_w: []const u16, options: OpenFileOptions) OpenError!HAN
146 // call has failed. There is not really a sane way to handle146 // call has failed. There is not really a sane way to handle
147 // this other than retrying the creation after the OS finishes147 // this other than retrying the creation after the OS finishes
148 // the deletion.148 // the deletion.
149 std.time.sleep(std.time.ns_per_ms);149 std.Thread.sleep(std.time.ns_per_ms);
150 continue;150 continue;
151 },151 },
152 .VIRUS_INFECTED, .VIRUS_DELETED => return error.AntivirusInterference,152 .VIRUS_INFECTED, .VIRUS_DELETED => return error.AntivirusInterference,
...@@ -2848,9 +2848,6 @@ pub const STD_OUTPUT_HANDLE = maxInt(DWORD) - 11 + 1;...@@ -2848,9 +2848,6 @@ pub const STD_OUTPUT_HANDLE = maxInt(DWORD) - 11 + 1;
2848/// The standard error device. Initially, this is the active console screen buffer, CONOUT$.2848/// The standard error device. Initially, this is the active console screen buffer, CONOUT$.
2849pub const STD_ERROR_HANDLE = maxInt(DWORD) - 12 + 1;2849pub const STD_ERROR_HANDLE = maxInt(DWORD) - 12 + 1;
28502850
2851/// Deprecated; use `std.builtin.CallingConvention.winapi` instead.
2852pub const WINAPI: std.builtin.CallingConvention = .winapi;
2853
2854pub const BOOL = c_int;2851pub const BOOL = c_int;
2855pub const BOOLEAN = BYTE;2852pub const BOOLEAN = BYTE;
2856pub const BYTE = u8;2853pub const BYTE = u8;
lib/std/posix.zig+20-4
...@@ -772,12 +772,12 @@ pub fn exit(status: u8) noreturn {...@@ -772,12 +772,12 @@ pub fn exit(status: u8) noreturn {
772 if (native_os == .uefi) {772 if (native_os == .uefi) {
773 const uefi = std.os.uefi;773 const uefi = std.os.uefi;
774 // exit() is only available if exitBootServices() has not been called yet.774 // exit() is only available if exitBootServices() has not been called yet.
775 // This call to exit should not fail, so we don't care about its return value.775 // This call to exit should not fail, so we catch-ignore errors.
776 if (uefi.system_table.boot_services) |bs| {776 if (uefi.system_table.boot_services) |bs| {
777 _ = bs.exit(uefi.handle, @enumFromInt(status), 0, null);777 bs.exit(uefi.handle, @enumFromInt(status), null) catch {};
778 }778 }
779 // If we can't exit, reboot the system instead.779 // If we can't exit, reboot the system instead.
780 uefi.system_table.runtime_services.resetSystem(.reset_cold, @enumFromInt(status), 0, null);780 uefi.system_table.runtime_services.resetSystem(.cold, @enumFromInt(status), null);
781 }781 }
782 system.exit(status);782 system.exit(status);
783}783}
...@@ -6088,6 +6088,9 @@ pub const SendError = error{...@@ -6088,6 +6088,9 @@ pub const SendError = error{
60886088
6089 /// The local network interface used to reach the destination is down.6089 /// The local network interface used to reach the destination is down.
6090 NetworkSubsystemFailed,6090 NetworkSubsystemFailed,
6091
6092 /// The destination address is not listening.
6093 ConnectionRefused,
6091} || UnexpectedError;6094} || UnexpectedError;
60926095
6093pub const SendMsgError = SendError || error{6096pub const SendMsgError = SendError || error{
...@@ -6315,7 +6318,6 @@ pub fn send(...@@ -6315,7 +6318,6 @@ pub fn send(
6315 error.AddressNotAvailable => unreachable,6318 error.AddressNotAvailable => unreachable,
6316 error.SocketNotConnected => unreachable,6319 error.SocketNotConnected => unreachable,
6317 error.UnreachableAddress => unreachable,6320 error.UnreachableAddress => unreachable,
6318 error.ConnectionRefused => unreachable,
6319 else => |e| return e,6321 else => |e| return e,
6320 };6322 };
6321}6323}
...@@ -6986,6 +6988,20 @@ pub fn tcsetpgrp(handle: fd_t, pgrp: pid_t) TermioSetPgrpError!void {...@@ -6986,6 +6988,20 @@ pub fn tcsetpgrp(handle: fd_t, pgrp: pid_t) TermioSetPgrpError!void {
6986 }6988 }
6987}6989}
69886990
6991pub const SetSidError = error{
6992 /// The calling process is already a process group leader, or the process group ID of a process other than the calling process matches the process ID of the calling process.
6993 PermissionDenied,
6994} || UnexpectedError;
6995
6996pub fn setsid() SetSidError!pid_t {
6997 const rc = system.setsid();
6998 switch (errno(rc)) {
6999 .SUCCESS => return rc,
7000 .PERM => return error.PermissionDenied,
7001 else => |err| return unexpectedErrno(err),
7002 }
7003}
7004
6989pub fn signalfd(fd: fd_t, mask: *const sigset_t, flags: u32) !fd_t {7005pub fn signalfd(fd: fd_t, mask: *const sigset_t, flags: u32) !fd_t {
6990 const rc = system.signalfd(fd, mask, flags);7006 const rc = system.signalfd(fd, mask, flags);
6991 switch (errno(rc)) {7007 switch (errno(rc)) {
lib/std/posix/test.zig+1-1
...@@ -1161,7 +1161,7 @@ test "POSIX file locking with fcntl" {...@@ -1161,7 +1161,7 @@ test "POSIX file locking with fcntl" {
1161 posix.exit(0);1161 posix.exit(0);
1162 } else {1162 } else {
1163 // parent waits for child to get shared lock:1163 // parent waits for child to get shared lock:
1164 std.time.sleep(1 * std.time.ns_per_ms);1164 std.Thread.sleep(1 * std.time.ns_per_ms);
1165 // parent expects deadlock when attempting to upgrade the shared lock to exclusive:1165 // parent expects deadlock when attempting to upgrade the shared lock to exclusive:
1166 struct_flock.start = 1;1166 struct_flock.start = 1;
1167 struct_flock.type = posix.F.WRLCK;1167 struct_flock.type = posix.F.WRLCK;
lib/std/time.zig+2-9
...@@ -8,9 +8,6 @@ const posix = std.posix;...@@ -8,9 +8,6 @@ const posix = std.posix;
88
9pub const epoch = @import("time/epoch.zig");9pub const epoch = @import("time/epoch.zig");
1010
11/// Deprecated: moved to std.Thread.sleep
12pub const sleep = std.Thread.sleep;
13
14/// Get a calendar timestamp, in seconds, relative to UTC 1970-01-01.11/// Get a calendar timestamp, in seconds, relative to UTC 1970-01-01.
15/// Precision of timing depends on the hardware and operating system.12/// Precision of timing depends on the hardware and operating system.
16/// The return value is signed because it is possible to have a date that is13/// The return value is signed because it is possible to have a date that is
...@@ -59,9 +56,7 @@ pub fn nanoTimestamp() i128 {...@@ -59,9 +56,7 @@ pub fn nanoTimestamp() i128 {
59 return ns;56 return ns;
60 },57 },
61 .uefi => {58 .uefi => {
62 var value: std.os.uefi.Time = undefined;59 const value, _ = std.os.uefi.system_table.runtime_services.getTime() catch return 0;
63 const status = std.os.uefi.system_table.runtime_services.getTime(&value, null);
64 assert(status == .success);
65 return value.toEpoch();60 return value.toEpoch();
66 },61 },
67 else => {62 else => {
...@@ -144,9 +139,7 @@ pub const Instant = struct {...@@ -144,9 +139,7 @@ pub const Instant = struct {
144 return .{ .timestamp = ns };139 return .{ .timestamp = ns };
145 },140 },
146 .uefi => {141 .uefi => {
147 var value: std.os.uefi.Time = undefined;142 const value, _ = std.os.uefi.system_table.runtime_services.getTime() catch return error.Unsupported;
148 const status = std.os.uefi.system_table.runtime_services.getTime(&value, null);
149 if (status != .success) return error.Unsupported;
150 return .{ .timestamp = value.toEpoch() };143 return .{ .timestamp = value.toEpoch() };
151 },144 },
152 // On darwin, use UPTIME_RAW instead of MONOTONIC as it ticks while145 // On darwin, use UPTIME_RAW instead of MONOTONIC as it ticks while
lib/std/unicode.zig-10
...@@ -972,8 +972,6 @@ pub fn utf16LeToUtf8ArrayList(result: *std.ArrayList(u8), utf16le: []const u16)...@@ -972,8 +972,6 @@ pub fn utf16LeToUtf8ArrayList(result: *std.ArrayList(u8), utf16le: []const u16)
972 return utf16LeToUtf8ArrayListImpl(result, utf16le, .cannot_encode_surrogate_half);972 return utf16LeToUtf8ArrayListImpl(result, utf16le, .cannot_encode_surrogate_half);
973}973}
974974
975pub const utf16leToUtf8Alloc = @compileError("deprecated; renamed to utf16LeToUtf8Alloc");
976
977/// Caller must free returned memory.975/// Caller must free returned memory.
978pub fn utf16LeToUtf8Alloc(allocator: mem.Allocator, utf16le: []const u16) Utf16LeToUtf8AllocError![]u8 {976pub fn utf16LeToUtf8Alloc(allocator: mem.Allocator, utf16le: []const u16) Utf16LeToUtf8AllocError![]u8 {
979 // optimistically guess that it will all be ascii.977 // optimistically guess that it will all be ascii.
...@@ -984,8 +982,6 @@ pub fn utf16LeToUtf8Alloc(allocator: mem.Allocator, utf16le: []const u16) Utf16L...@@ -984,8 +982,6 @@ pub fn utf16LeToUtf8Alloc(allocator: mem.Allocator, utf16le: []const u16) Utf16L
984 return result.toOwnedSlice();982 return result.toOwnedSlice();
985}983}
986984
987pub const utf16leToUtf8AllocZ = @compileError("deprecated; renamed to utf16LeToUtf8AllocZ");
988
989/// Caller must free returned memory.985/// Caller must free returned memory.
990pub fn utf16LeToUtf8AllocZ(allocator: mem.Allocator, utf16le: []const u16) Utf16LeToUtf8AllocError![:0]u8 {986pub fn utf16LeToUtf8AllocZ(allocator: mem.Allocator, utf16le: []const u16) Utf16LeToUtf8AllocError![:0]u8 {
991 // optimistically guess that it will all be ascii (and allocate space for the null terminator)987 // optimistically guess that it will all be ascii (and allocate space for the null terminator)
...@@ -1054,8 +1050,6 @@ fn utf16LeToUtf8Impl(utf8: []u8, utf16le: []const u16, comptime surrogates: Surr...@@ -1054,8 +1050,6 @@ fn utf16LeToUtf8Impl(utf8: []u8, utf16le: []const u16, comptime surrogates: Surr
1054 return dest_index;1050 return dest_index;
1055}1051}
10561052
1057pub const utf16leToUtf8 = @compileError("deprecated; renamed to utf16LeToUtf8");
1058
1059pub fn utf16LeToUtf8(utf8: []u8, utf16le: []const u16) Utf16LeToUtf8Error!usize {1053pub fn utf16LeToUtf8(utf8: []u8, utf16le: []const u16) Utf16LeToUtf8Error!usize {
1060 return utf16LeToUtf8Impl(utf8, utf16le, .cannot_encode_surrogate_half);1054 return utf16LeToUtf8Impl(utf8, utf16le, .cannot_encode_surrogate_half);
1061}1055}
...@@ -1175,8 +1169,6 @@ pub fn utf8ToUtf16LeAlloc(allocator: mem.Allocator, utf8: []const u8) error{ Inv...@@ -1175,8 +1169,6 @@ pub fn utf8ToUtf16LeAlloc(allocator: mem.Allocator, utf8: []const u8) error{ Inv
1175 return result.toOwnedSlice();1169 return result.toOwnedSlice();
1176}1170}
11771171
1178pub const utf8ToUtf16LeWithNull = @compileError("deprecated; renamed to utf8ToUtf16LeAllocZ");
1179
1180pub fn utf8ToUtf16LeAllocZ(allocator: mem.Allocator, utf8: []const u8) error{ InvalidUtf8, OutOfMemory }![:0]u16 {1172pub fn utf8ToUtf16LeAllocZ(allocator: mem.Allocator, utf8: []const u8) error{ InvalidUtf8, OutOfMemory }![:0]u16 {
1181 // optimistically guess that it will not require surrogate pairs1173 // optimistically guess that it will not require surrogate pairs
1182 var result = try std.ArrayList(u16).initCapacity(allocator, utf8.len + 1);1174 var result = try std.ArrayList(u16).initCapacity(allocator, utf8.len + 1);
...@@ -1487,8 +1479,6 @@ fn formatUtf16Le(utf16le: []const u16, writer: *std.io.Writer) std.io.Writer.Err...@@ -1487,8 +1479,6 @@ fn formatUtf16Le(utf16le: []const u16, writer: *std.io.Writer) std.io.Writer.Err
1487 try writer.writeAll(buf[0..u8len]);1479 try writer.writeAll(buf[0..u8len]);
1488}1480}
14891481
1490pub const fmtUtf16le = @compileError("deprecated; renamed to fmtUtf16Le");
1491
1492/// Return a Formatter for a (potentially ill-formed) UTF-16 LE string,1482/// Return a Formatter for a (potentially ill-formed) UTF-16 LE string,
1493/// which will be converted to UTF-8 during formatting.1483/// which will be converted to UTF-8 during formatting.
1494/// Unpaired surrogates are replaced by the replacement character (U+FFFD).1484/// Unpaired surrogates are replaced by the replacement character (U+FFFD).
lib/std/valgrind.zig-12
...@@ -200,18 +200,6 @@ pub fn nonSimdCall3(func: fn (usize, usize, usize, usize) usize, a1: usize, a2:...@@ -200,18 +200,6 @@ pub fn nonSimdCall3(func: fn (usize, usize, usize, usize) usize, a1: usize, a2:
200 return doClientRequestExpr(0, .ClientCall3, @intFromPtr(func), a1, a2, a3, 0);200 return doClientRequestExpr(0, .ClientCall3, @intFromPtr(func), a1, a2, a3, 0);
201}201}
202202
203/// Deprecated: use `nonSimdCall0`
204pub const nonSIMDCall0 = nonSimdCall0;
205
206/// Deprecated: use `nonSimdCall1`
207pub const nonSIMDCall1 = nonSimdCall1;
208
209/// Deprecated: use `nonSimdCall2`
210pub const nonSIMDCall2 = nonSimdCall2;
211
212/// Deprecated: use `nonSimdCall3`
213pub const nonSIMDCall3 = nonSimdCall3;
214
215/// Counts the number of errors that have been recorded by a tool. Nb:203/// Counts the number of errors that have been recorded by a tool. Nb:
216/// the tool must record the errors with VG_(maybe_record_error)() or204/// the tool must record the errors with VG_(maybe_record_error)() or
217/// VG_(unique_error)() for them to be counted.205/// VG_(unique_error)() for them to be counted.
lib/std/valgrind/callgrind.zig-2
...@@ -10,8 +10,6 @@ pub const ClientRequest = enum(usize) {...@@ -10,8 +10,6 @@ pub const ClientRequest = enum(usize) {
10 StopInstrumentation,10 StopInstrumentation,
11};11};
1212
13pub const CallgrindClientRequest = @compileError("std.valgrind.callgrind.CallgrindClientRequest renamed to std.valgrind.callgrind.ClientRequest");
14
15fn doClientRequestExpr(default: usize, request: ClientRequest, a1: usize, a2: usize, a3: usize, a4: usize, a5: usize) usize {13fn doClientRequestExpr(default: usize, request: ClientRequest, a1: usize, a2: usize, a3: usize, a4: usize, a5: usize) usize {
16 return valgrind.doClientRequest(default, @as(usize, @intCast(@intFromEnum(request))), a1, a2, a3, a4, a5);14 return valgrind.doClientRequest(default, @as(usize, @intCast(@intFromEnum(request))), a1, a2, a3, a4, a5);
17}15}
lib/std/valgrind/memcheck.zig-2
...@@ -20,8 +20,6 @@ pub const ClientRequest = enum(usize) {...@@ -20,8 +20,6 @@ pub const ClientRequest = enum(usize) {
20 DisableAddrErrorReportingInRange,20 DisableAddrErrorReportingInRange,
21};21};
2222
23pub const MemCheckClientRequest = @compileError("std.valgrind.memcheck.MemCheckClientRequest renamed to std.valgrind.memcheck.ClientRequest");
24
25fn doClientRequestExpr(default: usize, request: ClientRequest, a1: usize, a2: usize, a3: usize, a4: usize, a5: usize) usize {23fn doClientRequestExpr(default: usize, request: ClientRequest, a1: usize, a2: usize, a3: usize, a4: usize, a5: usize) usize {
26 return valgrind.doClientRequest(default, @as(usize, @intCast(@intFromEnum(request))), a1, a2, a3, a4, a5);24 return valgrind.doClientRequest(default, @as(usize, @intCast(@intFromEnum(request))), a1, a2, a3, a4, a5);
27}25}
lib/std/zig.zig+6-10
...@@ -23,7 +23,6 @@ pub const Zir = @import("zig/Zir.zig");...@@ -23,7 +23,6 @@ pub const Zir = @import("zig/Zir.zig");
23pub const Zoir = @import("zig/Zoir.zig");23pub const Zoir = @import("zig/Zoir.zig");
24pub const ZonGen = @import("zig/ZonGen.zig");24pub const ZonGen = @import("zig/ZonGen.zig");
25pub const system = @import("zig/system.zig");25pub const system = @import("zig/system.zig");
26pub const CrossTarget = @compileError("deprecated; use std.Target.Query");
27pub const BuiltinFn = @import("zig/BuiltinFn.zig");26pub const BuiltinFn = @import("zig/BuiltinFn.zig");
28pub const AstRlAnnotate = @import("zig/AstRlAnnotate.zig");27pub const AstRlAnnotate = @import("zig/AstRlAnnotate.zig");
29pub const LibCInstallation = @import("zig/LibCInstallation.zig");28pub const LibCInstallation = @import("zig/LibCInstallation.zig");
...@@ -596,7 +595,7 @@ pub fn putAstErrorsIntoBundle(...@@ -596,7 +595,7 @@ pub fn putAstErrorsIntoBundle(
596595
597pub fn resolveTargetQueryOrFatal(target_query: std.Target.Query) std.Target {596pub fn resolveTargetQueryOrFatal(target_query: std.Target.Query) std.Target {
598 return std.zig.system.resolveTargetQuery(target_query) catch |err|597 return std.zig.system.resolveTargetQuery(target_query) catch |err|
599 fatal("unable to resolve target: {s}", .{@errorName(err)});598 std.process.fatal("unable to resolve target: {s}", .{@errorName(err)});
600}599}
601600
602pub fn parseTargetQueryOrReportFatalError(601pub fn parseTargetQueryOrReportFatalError(
...@@ -620,7 +619,7 @@ pub fn parseTargetQueryOrReportFatalError(...@@ -620,7 +619,7 @@ pub fn parseTargetQueryOrReportFatalError(
620 @tagName(diags.arch.?), help_text.items,619 @tagName(diags.arch.?), help_text.items,
621 });620 });
622 }621 }
623 fatal("unknown CPU: '{s}'", .{diags.cpu_name.?});622 std.process.fatal("unknown CPU: '{s}'", .{diags.cpu_name.?});
624 },623 },
625 error.UnknownCpuFeature => {624 error.UnknownCpuFeature => {
626 help: {625 help: {
...@@ -633,7 +632,7 @@ pub fn parseTargetQueryOrReportFatalError(...@@ -633,7 +632,7 @@ pub fn parseTargetQueryOrReportFatalError(
633 @tagName(diags.arch.?), help_text.items,632 @tagName(diags.arch.?), help_text.items,
634 });633 });
635 }634 }
636 fatal("unknown CPU feature: '{s}'", .{diags.unknown_feature_name.?});635 std.process.fatal("unknown CPU feature: '{s}'", .{diags.unknown_feature_name.?});
637 },636 },
638 error.UnknownObjectFormat => {637 error.UnknownObjectFormat => {
639 help: {638 help: {
...@@ -644,7 +643,7 @@ pub fn parseTargetQueryOrReportFatalError(...@@ -644,7 +643,7 @@ pub fn parseTargetQueryOrReportFatalError(
644 }643 }
645 std.log.info("available object formats:\n{s}", .{help_text.items});644 std.log.info("available object formats:\n{s}", .{help_text.items});
646 }645 }
647 fatal("unknown object format: '{s}'", .{opts.object_format.?});646 std.process.fatal("unknown object format: '{s}'", .{opts.object_format.?});
648 },647 },
649 error.UnknownArchitecture => {648 error.UnknownArchitecture => {
650 help: {649 help: {
...@@ -655,17 +654,14 @@ pub fn parseTargetQueryOrReportFatalError(...@@ -655,17 +654,14 @@ pub fn parseTargetQueryOrReportFatalError(
655 }654 }
656 std.log.info("available architectures:\n{s} native\n", .{help_text.items});655 std.log.info("available architectures:\n{s} native\n", .{help_text.items});
657 }656 }
658 fatal("unknown architecture: '{s}'", .{diags.unknown_architecture_name.?});657 std.process.fatal("unknown architecture: '{s}'", .{diags.unknown_architecture_name.?});
659 },658 },
660 else => |e| fatal("unable to parse target query '{s}': {s}", .{659 else => |e| std.process.fatal("unable to parse target query '{s}': {s}", .{
661 opts.arch_os_abi, @errorName(e),660 opts.arch_os_abi, @errorName(e),
662 }),661 }),
663 };662 };
664}663}
665664
666/// Deprecated; see `std.process.fatal`.
667pub const fatal = std.process.fatal;
668
669/// Collects all the environment variables that Zig could possibly inspect, so665/// Collects all the environment variables that Zig could possibly inspect, so
670/// that we can do reflection on this and print them with `zig env`.666/// that we can do reflection on this and print them with `zig env`.
671pub const EnvVar = enum {667pub const EnvVar = enum {
lib/std/zig/c_translation.zig-3
...@@ -254,9 +254,6 @@ test "sizeof" {...@@ -254,9 +254,6 @@ test "sizeof" {
254254
255pub const CIntLiteralBase = enum { decimal, octal, hex };255pub const CIntLiteralBase = enum { decimal, octal, hex };
256256
257/// Deprecated: use `CIntLiteralBase`
258pub const CIntLiteralRadix = CIntLiteralBase;
259
260fn PromoteIntLiteralReturnType(comptime SuffixType: type, comptime number: comptime_int, comptime base: CIntLiteralBase) type {257fn PromoteIntLiteralReturnType(comptime SuffixType: type, comptime number: comptime_int, comptime base: CIntLiteralBase) type {
261 const signed_decimal = [_]type{ c_int, c_long, c_longlong, c_ulonglong };258 const signed_decimal = [_]type{ c_int, c_long, c_longlong, c_ulonglong };
262 const signed_oct_hex = [_]type{ c_int, c_uint, c_long, c_ulong, c_longlong, c_ulonglong };259 const signed_oct_hex = [_]type{ c_int, c_uint, c_long, c_ulong, c_longlong, c_ulonglong };
lib/std/zig/llvm/Builder.zig+31-31
...@@ -2037,7 +2037,7 @@ pub const Alignment = enum(u6) {...@@ -2037,7 +2037,7 @@ pub const Alignment = enum(u6) {
20372037
2038 pub fn format(p: Prefixed, w: *Writer) Writer.Error!void {2038 pub fn format(p: Prefixed, w: *Writer) Writer.Error!void {
2039 const byte_units = p.alignment.toByteUnits() orelse return;2039 const byte_units = p.alignment.toByteUnits() orelse return;
2040 return w.print("{s}align ({d})", .{ p.prefix, byte_units });2040 return w.print("{s}align {d}", .{ p.prefix, byte_units });
2041 }2041 }
2042 };2042 };
20432043
...@@ -2384,7 +2384,7 @@ pub const Global = struct {...@@ -2384,7 +2384,7 @@ pub const Global = struct {
2384 };2384 };
2385 fn format(data: FormatData, w: *Writer) Writer.Error!void {2385 fn format(data: FormatData, w: *Writer) Writer.Error!void {
2386 try w.print("@{f}", .{2386 try w.print("@{f}", .{
2387 data.global.unwrap(data.builder).name(data.builder).fmt(data.builder, null),2387 data.global.unwrap(data.builder).name(data.builder).fmt(data.builder, .quote_unless_valid_identifier),
2388 });2388 });
2389 }2389 }
2390 pub fn fmt(self: Index, builder: *const Builder) std.fmt.Formatter(FormatData, format) {2390 pub fn fmt(self: Index, builder: *const Builder) std.fmt.Formatter(FormatData, format) {
...@@ -8401,7 +8401,7 @@ pub const Metadata = enum(u32) {...@@ -8401,7 +8401,7 @@ pub const Metadata = enum(u32) {
8401 }, w);8401 }, w);
8402 },8402 },
8403 .string => |node| try w.print("{s}{f}", .{8403 .string => |node| try w.print("{s}{f}", .{
8404 @as([]const u8, if (is_specialized) "" else "!"), node.fmt(builder),8404 @as([]const u8, if (is_specialized) "!" else ""), node.fmt(builder),
8405 }),8405 }),
8406 inline .bool, .u32, .u64 => |node| try w.print("{}", .{node}),8406 inline .bool, .u32, .u64 => |node| try w.print("{}", .{node}),
8407 inline .di_flags, .sp_flags => |node| try w.print("{f}", .{node}),8407 inline .di_flags, .sp_flags => |node| try w.print("{f}", .{node}),
...@@ -9782,7 +9782,7 @@ pub fn print(self: *Builder, w: *Writer) (Writer.Error || Allocator.Error)!void...@@ -9782,7 +9782,7 @@ pub fn print(self: *Builder, w: *Writer) (Writer.Error || Allocator.Error)!void
9782 instruction_index.name(&function).fmt(self),9782 instruction_index.name(&function).fmt(self),
9783 @tagName(tag),9783 @tagName(tag),
9784 extra.lhs.fmt(function_index, self, .{ .percent = true }),9784 extra.lhs.fmt(function_index, self, .{ .percent = true }),
9785 extra.rhs.fmt(function_index, self, .{ .percent = true }),9785 extra.rhs.fmt(function_index, self, .{}),
9786 });9786 });
9787 },9787 },
9788 .addrspacecast,9788 .addrspacecast,
...@@ -10638,7 +10638,7 @@ fn fnTypeAssumeCapacity(...@@ -10638,7 +10638,7 @@ fn fnTypeAssumeCapacity(
10638 const Adapter = struct {10638 const Adapter = struct {
10639 builder: *const Builder,10639 builder: *const Builder,
10640 pub fn hash(_: @This(), key: Key) u32 {10640 pub fn hash(_: @This(), key: Key) u32 {
10641 var hasher = std.hash.Wyhash.init(comptime std.hash.uint32(@intFromEnum(tag)));10641 var hasher = std.hash.Wyhash.init(comptime std.hash.int(@intFromEnum(tag)));
10642 hasher.update(std.mem.asBytes(&key.ret));10642 hasher.update(std.mem.asBytes(&key.ret));
10643 hasher.update(std.mem.sliceAsBytes(key.params));10643 hasher.update(std.mem.sliceAsBytes(key.params));
10644 return @truncate(hasher.final());10644 return @truncate(hasher.final());
...@@ -10698,7 +10698,7 @@ fn vectorTypeAssumeCapacity(...@@ -10698,7 +10698,7 @@ fn vectorTypeAssumeCapacity(
10698 builder: *const Builder,10698 builder: *const Builder,
10699 pub fn hash(_: @This(), key: Type.Vector) u32 {10699 pub fn hash(_: @This(), key: Type.Vector) u32 {
10700 return @truncate(std.hash.Wyhash.hash(10700 return @truncate(std.hash.Wyhash.hash(
10701 comptime std.hash.uint32(@intFromEnum(tag)),10701 comptime std.hash.int(@intFromEnum(tag)),
10702 std.mem.asBytes(&key),10702 std.mem.asBytes(&key),
10703 ));10703 ));
10704 }10704 }
...@@ -10727,7 +10727,7 @@ fn arrayTypeAssumeCapacity(self: *Builder, len: u64, child: Type) Type {...@@ -10727,7 +10727,7 @@ fn arrayTypeAssumeCapacity(self: *Builder, len: u64, child: Type) Type {
10727 builder: *const Builder,10727 builder: *const Builder,
10728 pub fn hash(_: @This(), key: Type.Vector) u32 {10728 pub fn hash(_: @This(), key: Type.Vector) u32 {
10729 return @truncate(std.hash.Wyhash.hash(10729 return @truncate(std.hash.Wyhash.hash(
10730 comptime std.hash.uint32(@intFromEnum(Type.Tag.small_array)),10730 comptime std.hash.int(@intFromEnum(Type.Tag.small_array)),
10731 std.mem.asBytes(&key),10731 std.mem.asBytes(&key),
10732 ));10732 ));
10733 }10733 }
...@@ -10753,7 +10753,7 @@ fn arrayTypeAssumeCapacity(self: *Builder, len: u64, child: Type) Type {...@@ -10753,7 +10753,7 @@ fn arrayTypeAssumeCapacity(self: *Builder, len: u64, child: Type) Type {
10753 builder: *const Builder,10753 builder: *const Builder,
10754 pub fn hash(_: @This(), key: Type.Array) u32 {10754 pub fn hash(_: @This(), key: Type.Array) u32 {
10755 return @truncate(std.hash.Wyhash.hash(10755 return @truncate(std.hash.Wyhash.hash(
10756 comptime std.hash.uint32(@intFromEnum(Type.Tag.array)),10756 comptime std.hash.int(@intFromEnum(Type.Tag.array)),
10757 std.mem.asBytes(&key),10757 std.mem.asBytes(&key),
10758 ));10758 ));
10759 }10759 }
...@@ -10794,7 +10794,7 @@ fn structTypeAssumeCapacity(...@@ -10794,7 +10794,7 @@ fn structTypeAssumeCapacity(
10794 builder: *const Builder,10794 builder: *const Builder,
10795 pub fn hash(_: @This(), key: []const Type) u32 {10795 pub fn hash(_: @This(), key: []const Type) u32 {
10796 return @truncate(std.hash.Wyhash.hash(10796 return @truncate(std.hash.Wyhash.hash(
10797 comptime std.hash.uint32(@intFromEnum(tag)),10797 comptime std.hash.int(@intFromEnum(tag)),
10798 std.mem.sliceAsBytes(key),10798 std.mem.sliceAsBytes(key),
10799 ));10799 ));
10800 }10800 }
...@@ -10826,7 +10826,7 @@ fn opaqueTypeAssumeCapacity(self: *Builder, name: String) Type {...@@ -10826,7 +10826,7 @@ fn opaqueTypeAssumeCapacity(self: *Builder, name: String) Type {
10826 builder: *const Builder,10826 builder: *const Builder,
10827 pub fn hash(_: @This(), key: String) u32 {10827 pub fn hash(_: @This(), key: String) u32 {
10828 return @truncate(std.hash.Wyhash.hash(10828 return @truncate(std.hash.Wyhash.hash(
10829 comptime std.hash.uint32(@intFromEnum(Type.Tag.named_structure)),10829 comptime std.hash.int(@intFromEnum(Type.Tag.named_structure)),
10830 std.mem.asBytes(&key),10830 std.mem.asBytes(&key),
10831 ));10831 ));
10832 }10832 }
...@@ -10887,7 +10887,7 @@ fn getOrPutTypeNoExtraAssumeCapacity(self: *Builder, item: Type.Item) struct { n...@@ -10887,7 +10887,7 @@ fn getOrPutTypeNoExtraAssumeCapacity(self: *Builder, item: Type.Item) struct { n
10887 builder: *const Builder,10887 builder: *const Builder,
10888 pub fn hash(_: @This(), key: Type.Item) u32 {10888 pub fn hash(_: @This(), key: Type.Item) u32 {
10889 return @truncate(std.hash.Wyhash.hash(10889 return @truncate(std.hash.Wyhash.hash(
10890 comptime std.hash.uint32(@intFromEnum(Type.Tag.simple)),10890 comptime std.hash.int(@intFromEnum(Type.Tag.simple)),
10891 std.mem.asBytes(&key),10891 std.mem.asBytes(&key),
10892 ));10892 ));
10893 }10893 }
...@@ -11021,7 +11021,7 @@ fn bigIntConstAssumeCapacity(...@@ -11021,7 +11021,7 @@ fn bigIntConstAssumeCapacity(
11021 const Adapter = struct {11021 const Adapter = struct {
11022 builder: *const Builder,11022 builder: *const Builder,
11023 pub fn hash(_: @This(), key: Key) u32 {11023 pub fn hash(_: @This(), key: Key) u32 {
11024 var hasher = std.hash.Wyhash.init(std.hash.uint32(@intFromEnum(key.tag)));11024 var hasher = std.hash.Wyhash.init(std.hash.int(@intFromEnum(key.tag)));
11025 hasher.update(std.mem.asBytes(&key.type));11025 hasher.update(std.mem.asBytes(&key.type));
11026 hasher.update(std.mem.sliceAsBytes(key.limbs));11026 hasher.update(std.mem.sliceAsBytes(key.limbs));
11027 return @truncate(hasher.final());11027 return @truncate(hasher.final());
...@@ -11084,7 +11084,7 @@ fn doubleConstAssumeCapacity(self: *Builder, val: f64) Constant {...@@ -11084,7 +11084,7 @@ fn doubleConstAssumeCapacity(self: *Builder, val: f64) Constant {
11084 builder: *const Builder,11084 builder: *const Builder,
11085 pub fn hash(_: @This(), key: f64) u32 {11085 pub fn hash(_: @This(), key: f64) u32 {
11086 return @truncate(std.hash.Wyhash.hash(11086 return @truncate(std.hash.Wyhash.hash(
11087 comptime std.hash.uint32(@intFromEnum(Constant.Tag.double)),11087 comptime std.hash.int(@intFromEnum(Constant.Tag.double)),
11088 std.mem.asBytes(&key),11088 std.mem.asBytes(&key),
11089 ));11089 ));
11090 }11090 }
...@@ -11115,7 +11115,7 @@ fn fp128ConstAssumeCapacity(self: *Builder, val: f128) Constant {...@@ -11115,7 +11115,7 @@ fn fp128ConstAssumeCapacity(self: *Builder, val: f128) Constant {
11115 builder: *const Builder,11115 builder: *const Builder,
11116 pub fn hash(_: @This(), key: f128) u32 {11116 pub fn hash(_: @This(), key: f128) u32 {
11117 return @truncate(std.hash.Wyhash.hash(11117 return @truncate(std.hash.Wyhash.hash(
11118 comptime std.hash.uint32(@intFromEnum(Constant.Tag.fp128)),11118 comptime std.hash.int(@intFromEnum(Constant.Tag.fp128)),
11119 std.mem.asBytes(&key),11119 std.mem.asBytes(&key),
11120 ));11120 ));
11121 }11121 }
...@@ -11149,7 +11149,7 @@ fn x86_fp80ConstAssumeCapacity(self: *Builder, val: f80) Constant {...@@ -11149,7 +11149,7 @@ fn x86_fp80ConstAssumeCapacity(self: *Builder, val: f80) Constant {
11149 builder: *const Builder,11149 builder: *const Builder,
11150 pub fn hash(_: @This(), key: f80) u32 {11150 pub fn hash(_: @This(), key: f80) u32 {
11151 return @truncate(std.hash.Wyhash.hash(11151 return @truncate(std.hash.Wyhash.hash(
11152 comptime std.hash.uint32(@intFromEnum(Constant.Tag.x86_fp80)),11152 comptime std.hash.int(@intFromEnum(Constant.Tag.x86_fp80)),
11153 std.mem.asBytes(&key)[0..10],11153 std.mem.asBytes(&key)[0..10],
11154 ));11154 ));
11155 }11155 }
...@@ -11182,7 +11182,7 @@ fn ppc_fp128ConstAssumeCapacity(self: *Builder, val: [2]f64) Constant {...@@ -11182,7 +11182,7 @@ fn ppc_fp128ConstAssumeCapacity(self: *Builder, val: [2]f64) Constant {
11182 builder: *const Builder,11182 builder: *const Builder,
11183 pub fn hash(_: @This(), key: [2]f64) u32 {11183 pub fn hash(_: @This(), key: [2]f64) u32 {
11184 return @truncate(std.hash.Wyhash.hash(11184 return @truncate(std.hash.Wyhash.hash(
11185 comptime std.hash.uint32(@intFromEnum(Constant.Tag.ppc_fp128)),11185 comptime std.hash.int(@intFromEnum(Constant.Tag.ppc_fp128)),
11186 std.mem.asBytes(&key),11186 std.mem.asBytes(&key),
11187 ));11187 ));
11188 }11188 }
...@@ -11317,7 +11317,7 @@ fn splatConstAssumeCapacity(self: *Builder, ty: Type, val: Constant) Constant {...@@ -11317,7 +11317,7 @@ fn splatConstAssumeCapacity(self: *Builder, ty: Type, val: Constant) Constant {
11317 builder: *const Builder,11317 builder: *const Builder,
11318 pub fn hash(_: @This(), key: Constant.Splat) u32 {11318 pub fn hash(_: @This(), key: Constant.Splat) u32 {
11319 return @truncate(std.hash.Wyhash.hash(11319 return @truncate(std.hash.Wyhash.hash(
11320 comptime std.hash.uint32(@intFromEnum(Constant.Tag.splat)),11320 comptime std.hash.int(@intFromEnum(Constant.Tag.splat)),
11321 std.mem.asBytes(&key),11321 std.mem.asBytes(&key),
11322 ));11322 ));
11323 }11323 }
...@@ -11420,7 +11420,7 @@ fn blockAddrConstAssumeCapacity(...@@ -11420,7 +11420,7 @@ fn blockAddrConstAssumeCapacity(
11420 builder: *const Builder,11420 builder: *const Builder,
11421 pub fn hash(_: @This(), key: Constant.BlockAddress) u32 {11421 pub fn hash(_: @This(), key: Constant.BlockAddress) u32 {
11422 return @truncate(std.hash.Wyhash.hash(11422 return @truncate(std.hash.Wyhash.hash(
11423 comptime std.hash.uint32(@intFromEnum(Constant.Tag.blockaddress)),11423 comptime std.hash.int(@intFromEnum(Constant.Tag.blockaddress)),
11424 std.mem.asBytes(&key),11424 std.mem.asBytes(&key),
11425 ));11425 ));
11426 }11426 }
...@@ -11546,7 +11546,7 @@ fn castConstAssumeCapacity(self: *Builder, tag: Constant.Tag, val: Constant, ty:...@@ -11546,7 +11546,7 @@ fn castConstAssumeCapacity(self: *Builder, tag: Constant.Tag, val: Constant, ty:
11546 builder: *const Builder,11546 builder: *const Builder,
11547 pub fn hash(_: @This(), key: Key) u32 {11547 pub fn hash(_: @This(), key: Key) u32 {
11548 return @truncate(std.hash.Wyhash.hash(11548 return @truncate(std.hash.Wyhash.hash(
11549 std.hash.uint32(@intFromEnum(key.tag)),11549 std.hash.int(@intFromEnum(key.tag)),
11550 std.mem.asBytes(&key.cast),11550 std.mem.asBytes(&key.cast),
11551 ));11551 ));
11552 }11552 }
...@@ -11621,7 +11621,7 @@ fn gepConstAssumeCapacity(...@@ -11621,7 +11621,7 @@ fn gepConstAssumeCapacity(
11621 const Adapter = struct {11621 const Adapter = struct {
11622 builder: *const Builder,11622 builder: *const Builder,
11623 pub fn hash(_: @This(), key: Key) u32 {11623 pub fn hash(_: @This(), key: Key) u32 {
11624 var hasher = std.hash.Wyhash.init(comptime std.hash.uint32(@intFromEnum(tag)));11624 var hasher = std.hash.Wyhash.init(comptime std.hash.int(@intFromEnum(tag)));
11625 hasher.update(std.mem.asBytes(&key.type));11625 hasher.update(std.mem.asBytes(&key.type));
11626 hasher.update(std.mem.asBytes(&key.base));11626 hasher.update(std.mem.asBytes(&key.base));
11627 hasher.update(std.mem.asBytes(&key.inrange));11627 hasher.update(std.mem.asBytes(&key.inrange));
...@@ -11685,7 +11685,7 @@ fn binConstAssumeCapacity(...@@ -11685,7 +11685,7 @@ fn binConstAssumeCapacity(
11685 builder: *const Builder,11685 builder: *const Builder,
11686 pub fn hash(_: @This(), key: Key) u32 {11686 pub fn hash(_: @This(), key: Key) u32 {
11687 return @truncate(std.hash.Wyhash.hash(11687 return @truncate(std.hash.Wyhash.hash(
11688 std.hash.uint32(@intFromEnum(key.tag)),11688 std.hash.int(@intFromEnum(key.tag)),
11689 std.mem.asBytes(&key.extra),11689 std.mem.asBytes(&key.extra),
11690 ));11690 ));
11691 }11691 }
...@@ -11723,7 +11723,7 @@ fn asmConstAssumeCapacity(...@@ -11723,7 +11723,7 @@ fn asmConstAssumeCapacity(
11723 builder: *const Builder,11723 builder: *const Builder,
11724 pub fn hash(_: @This(), key: Key) u32 {11724 pub fn hash(_: @This(), key: Key) u32 {
11725 return @truncate(std.hash.Wyhash.hash(11725 return @truncate(std.hash.Wyhash.hash(
11726 std.hash.uint32(@intFromEnum(key.tag)),11726 std.hash.int(@intFromEnum(key.tag)),
11727 std.mem.asBytes(&key.extra),11727 std.mem.asBytes(&key.extra),
11728 ));11728 ));
11729 }11729 }
...@@ -11773,7 +11773,7 @@ fn getOrPutConstantNoExtraAssumeCapacity(...@@ -11773,7 +11773,7 @@ fn getOrPutConstantNoExtraAssumeCapacity(
11773 builder: *const Builder,11773 builder: *const Builder,
11774 pub fn hash(_: @This(), key: Constant.Item) u32 {11774 pub fn hash(_: @This(), key: Constant.Item) u32 {
11775 return @truncate(std.hash.Wyhash.hash(11775 return @truncate(std.hash.Wyhash.hash(
11776 std.hash.uint32(@intFromEnum(key.tag)),11776 std.hash.int(@intFromEnum(key.tag)),
11777 std.mem.asBytes(&key.data),11777 std.mem.asBytes(&key.data),
11778 ));11778 ));
11779 }11779 }
...@@ -11804,7 +11804,7 @@ fn getOrPutConstantAggregateAssumeCapacity(...@@ -11804,7 +11804,7 @@ fn getOrPutConstantAggregateAssumeCapacity(
11804 const Adapter = struct {11804 const Adapter = struct {
11805 builder: *const Builder,11805 builder: *const Builder,
11806 pub fn hash(_: @This(), key: Key) u32 {11806 pub fn hash(_: @This(), key: Key) u32 {
11807 var hasher = std.hash.Wyhash.init(std.hash.uint32(@intFromEnum(key.tag)));11807 var hasher = std.hash.Wyhash.init(std.hash.int(@intFromEnum(key.tag)));
11808 hasher.update(std.mem.asBytes(&key.type));11808 hasher.update(std.mem.asBytes(&key.type));
11809 hasher.update(std.mem.sliceAsBytes(key.vals));11809 hasher.update(std.mem.sliceAsBytes(key.vals));
11810 return @truncate(hasher.final());11810 return @truncate(hasher.final());
...@@ -12421,7 +12421,7 @@ fn metadataSimpleAssumeCapacity(self: *Builder, tag: Metadata.Tag, value: anytyp...@@ -12421,7 +12421,7 @@ fn metadataSimpleAssumeCapacity(self: *Builder, tag: Metadata.Tag, value: anytyp
12421 const Adapter = struct {12421 const Adapter = struct {
12422 builder: *const Builder,12422 builder: *const Builder,
12423 pub fn hash(_: @This(), key: Key) u32 {12423 pub fn hash(_: @This(), key: Key) u32 {
12424 var hasher = std.hash.Wyhash.init(std.hash.uint32(@intFromEnum(key.tag)));12424 var hasher = std.hash.Wyhash.init(std.hash.int(@intFromEnum(key.tag)));
12425 inline for (std.meta.fields(@TypeOf(value))) |field| {12425 inline for (std.meta.fields(@TypeOf(value))) |field| {
12426 hasher.update(std.mem.asBytes(&@field(key.value, field.name)));12426 hasher.update(std.mem.asBytes(&@field(key.value, field.name)));
12427 }12427 }
...@@ -12457,7 +12457,7 @@ fn metadataDistinctAssumeCapacity(self: *Builder, tag: Metadata.Tag, value: anyt...@@ -12457,7 +12457,7 @@ fn metadataDistinctAssumeCapacity(self: *Builder, tag: Metadata.Tag, value: anyt
12457 const Adapter = struct {12457 const Adapter = struct {
12458 pub fn hash(_: @This(), key: Key) u32 {12458 pub fn hash(_: @This(), key: Key) u32 {
12459 return @truncate(std.hash.Wyhash.hash(12459 return @truncate(std.hash.Wyhash.hash(
12460 std.hash.uint32(@intFromEnum(key.tag)),12460 std.hash.int(@intFromEnum(key.tag)),
12461 std.mem.asBytes(&key.index),12461 std.mem.asBytes(&key.index),
12462 ));12462 ));
12463 }12463 }
...@@ -12853,7 +12853,7 @@ fn debugEnumeratorAssumeCapacity(...@@ -12853,7 +12853,7 @@ fn debugEnumeratorAssumeCapacity(
12853 const Adapter = struct {12853 const Adapter = struct {
12854 builder: *const Builder,12854 builder: *const Builder,
12855 pub fn hash(_: @This(), key: Key) u32 {12855 pub fn hash(_: @This(), key: Key) u32 {
12856 var hasher = std.hash.Wyhash.init(std.hash.uint32(@intFromEnum(key.tag)));12856 var hasher = std.hash.Wyhash.init(std.hash.int(@intFromEnum(key.tag)));
12857 hasher.update(std.mem.asBytes(&key.name));12857 hasher.update(std.mem.asBytes(&key.name));
12858 hasher.update(std.mem.asBytes(&key.bit_width));12858 hasher.update(std.mem.asBytes(&key.bit_width));
12859 hasher.update(std.mem.sliceAsBytes(key.value.limbs));12859 hasher.update(std.mem.sliceAsBytes(key.value.limbs));
...@@ -12935,7 +12935,7 @@ fn debugExpressionAssumeCapacity(...@@ -12935,7 +12935,7 @@ fn debugExpressionAssumeCapacity(
12935 const Adapter = struct {12935 const Adapter = struct {
12936 builder: *const Builder,12936 builder: *const Builder,
12937 pub fn hash(_: @This(), key: Key) u32 {12937 pub fn hash(_: @This(), key: Key) u32 {
12938 var hasher = comptime std.hash.Wyhash.init(std.hash.uint32(@intFromEnum(Metadata.Tag.expression)));12938 var hasher = comptime std.hash.Wyhash.init(std.hash.int(@intFromEnum(Metadata.Tag.expression)));
12939 hasher.update(std.mem.sliceAsBytes(key.elements));12939 hasher.update(std.mem.sliceAsBytes(key.elements));
12940 return @truncate(hasher.final());12940 return @truncate(hasher.final());
12941 }12941 }
...@@ -12981,7 +12981,7 @@ fn metadataTupleAssumeCapacity(...@@ -12981,7 +12981,7 @@ fn metadataTupleAssumeCapacity(
12981 const Adapter = struct {12981 const Adapter = struct {
12982 builder: *const Builder,12982 builder: *const Builder,
12983 pub fn hash(_: @This(), key: Key) u32 {12983 pub fn hash(_: @This(), key: Key) u32 {
12984 var hasher = comptime std.hash.Wyhash.init(std.hash.uint32(@intFromEnum(Metadata.Tag.tuple)));12984 var hasher = comptime std.hash.Wyhash.init(std.hash.int(@intFromEnum(Metadata.Tag.tuple)));
12985 hasher.update(std.mem.sliceAsBytes(key.elements));12985 hasher.update(std.mem.sliceAsBytes(key.elements));
12986 return @truncate(hasher.final());12986 return @truncate(hasher.final());
12987 }12987 }
...@@ -13029,7 +13029,7 @@ fn strTupleAssumeCapacity(...@@ -13029,7 +13029,7 @@ fn strTupleAssumeCapacity(
13029 const Adapter = struct {13029 const Adapter = struct {
13030 builder: *const Builder,13030 builder: *const Builder,
13031 pub fn hash(_: @This(), key: Key) u32 {13031 pub fn hash(_: @This(), key: Key) u32 {
13032 var hasher = comptime std.hash.Wyhash.init(std.hash.uint32(@intFromEnum(Metadata.Tag.tuple)));13032 var hasher = comptime std.hash.Wyhash.init(std.hash.int(@intFromEnum(Metadata.Tag.tuple)));
13033 hasher.update(std.mem.sliceAsBytes(key.elements));13033 hasher.update(std.mem.sliceAsBytes(key.elements));
13034 return @truncate(hasher.final());13034 return @truncate(hasher.final());
13035 }13035 }
...@@ -13159,7 +13159,7 @@ fn metadataConstantAssumeCapacity(self: *Builder, constant: Constant) Metadata {...@@ -13159,7 +13159,7 @@ fn metadataConstantAssumeCapacity(self: *Builder, constant: Constant) Metadata {
13159 const Adapter = struct {13159 const Adapter = struct {
13160 builder: *const Builder,13160 builder: *const Builder,
13161 pub fn hash(_: @This(), key: Constant) u32 {13161 pub fn hash(_: @This(), key: Constant) u32 {
13162 var hasher = comptime std.hash.Wyhash.init(std.hash.uint32(@intFromEnum(Metadata.Tag.constant)));13162 var hasher = comptime std.hash.Wyhash.init(std.hash.int(@intFromEnum(Metadata.Tag.constant)));
13163 hasher.update(std.mem.asBytes(&key));13163 hasher.update(std.mem.asBytes(&key));
13164 return @truncate(hasher.final());13164 return @truncate(hasher.final());
13165 }13165 }
src/Compilation.zig+3-1
...@@ -1029,7 +1029,9 @@ pub const CObject = struct {...@@ -1029,7 +1029,9 @@ pub const CObject = struct {
10291029
1030 pub fn destroy(bundle: *Bundle, gpa: Allocator) void {1030 pub fn destroy(bundle: *Bundle, gpa: Allocator) void {
1031 for (bundle.file_names.values()) |file_name| gpa.free(file_name);1031 for (bundle.file_names.values()) |file_name| gpa.free(file_name);
1032 bundle.file_names.deinit(gpa);
1032 for (bundle.category_names.values()) |category_name| gpa.free(category_name);1033 for (bundle.category_names.values()) |category_name| gpa.free(category_name);
1034 bundle.category_names.deinit(gpa);
1033 for (bundle.diags) |*diag| diag.deinit(gpa);1035 for (bundle.diags) |*diag| diag.deinit(gpa);
1034 gpa.free(bundle.diags);1036 gpa.free(bundle.diags);
1035 gpa.destroy(bundle);1037 gpa.destroy(bundle);
...@@ -3040,7 +3042,7 @@ fn flush(...@@ -3040,7 +3042,7 @@ fn flush(
3040 // If there's an output file, it wants to decide where the LLVM object goes!3042 // If there's an output file, it wants to decide where the LLVM object goes!
3041 const sub_prog_node = comp.link_prog_node.start("LLVM Emit Object", 0);3043 const sub_prog_node = comp.link_prog_node.start("LLVM Emit Object", 0);
3042 defer sub_prog_node.end();3044 defer sub_prog_node.end();
3043 try llvm_object.emit(.{3045 try llvm_object.emit(.{ .zcu = zcu, .tid = tid }, .{
3044 .pre_ir_path = comp.verbose_llvm_ir,3046 .pre_ir_path = comp.verbose_llvm_ir,
3045 .pre_bc_path = comp.verbose_llvm_bc,3047 .pre_bc_path = comp.verbose_llvm_bc,
30463048
src/IncrementalDebugServer.zig+4-3
...@@ -55,14 +55,15 @@ fn runThread(ids: *IncrementalDebugServer) void {...@@ -55,14 +55,15 @@ fn runThread(ids: *IncrementalDebugServer) void {
55 const conn = server.accept() catch @panic("IncrementalDebugServer: failed to accept");55 const conn = server.accept() catch @panic("IncrementalDebugServer: failed to accept");
56 defer conn.stream.close();56 defer conn.stream.close();
5757
58 var stream_reader = conn.stream.reader(&cmd_buf);
59
58 while (ids.running.load(.monotonic)) {60 while (ids.running.load(.monotonic)) {
59 conn.stream.writeAll("zig> ") catch @panic("IncrementalDebugServer: failed to write");61 conn.stream.writeAll("zig> ") catch @panic("IncrementalDebugServer: failed to write");
60 var fbs = std.io.fixedBufferStream(&cmd_buf);62 const untrimmed = stream_reader.interface().takeSentinel('\n') catch |err| switch (err) {
61 conn.stream.reader().streamUntilDelimiter(fbs.writer(), '\n', cmd_buf.len) catch |err| switch (err) {
62 error.EndOfStream => break,63 error.EndOfStream => break,
63 else => @panic("IncrementalDebugServer: failed to read command"),64 else => @panic("IncrementalDebugServer: failed to read command"),
64 };65 };
65 const cmd_and_arg = std.mem.trim(u8, fbs.getWritten(), " \t\r\n");66 const cmd_and_arg = std.mem.trim(u8, untrimmed, " \t\r\n");
66 const cmd: []const u8, const arg: []const u8 = if (std.mem.indexOfScalar(u8, cmd_and_arg, ' ')) |i|67 const cmd: []const u8, const arg: []const u8 = if (std.mem.indexOfScalar(u8, cmd_and_arg, ' ')) |i|
67 .{ cmd_and_arg[0..i], cmd_and_arg[i + 1 ..] }68 .{ cmd_and_arg[0..i], cmd_and_arg[i + 1 ..] }
68 else69 else
src/InternPool.zig+4-4
...@@ -1861,7 +1861,7 @@ pub const NullTerminatedString = enum(u32) {...@@ -1861,7 +1861,7 @@ pub const NullTerminatedString = enum(u32) {
18611861
1862 pub fn hash(ctx: @This(), a: NullTerminatedString) u32 {1862 pub fn hash(ctx: @This(), a: NullTerminatedString) u32 {
1863 _ = ctx;1863 _ = ctx;
1864 return std.hash.uint32(@intFromEnum(a));1864 return std.hash.int(@intFromEnum(a));
1865 }1865 }
1866 };1866 };
18671867
...@@ -4740,7 +4740,7 @@ pub const Index = enum(u32) {...@@ -4740,7 +4740,7 @@ pub const Index = enum(u32) {
47404740
4741 pub fn hash(ctx: @This(), a: Index) u32 {4741 pub fn hash(ctx: @This(), a: Index) u32 {
4742 _ = ctx;4742 _ = ctx;
4743 return std.hash.uint32(@intFromEnum(a));4743 return std.hash.int(@intFromEnum(a));
4744 }4744 }
4745 };4745 };
47464746
...@@ -12725,7 +12725,7 @@ const GlobalErrorSet = struct {...@@ -12725,7 +12725,7 @@ const GlobalErrorSet = struct {
12725 name: NullTerminatedString,12725 name: NullTerminatedString,
12726 ) Allocator.Error!GlobalErrorSet.Index {12726 ) Allocator.Error!GlobalErrorSet.Index {
12727 if (name == .empty) return .none;12727 if (name == .empty) return .none;
12728 const hash = std.hash.uint32(@intFromEnum(name));12728 const hash = std.hash.int(@intFromEnum(name));
12729 var map = ges.shared.map.acquire();12729 var map = ges.shared.map.acquire();
12730 const Map = @TypeOf(map);12730 const Map = @TypeOf(map);
12731 var map_mask = map.header().mask();12731 var map_mask = map.header().mask();
...@@ -12818,7 +12818,7 @@ const GlobalErrorSet = struct {...@@ -12818,7 +12818,7 @@ const GlobalErrorSet = struct {
12818 name: NullTerminatedString,12818 name: NullTerminatedString,
12819 ) ?GlobalErrorSet.Index {12819 ) ?GlobalErrorSet.Index {
12820 if (name == .empty) return .none;12820 if (name == .empty) return .none;
12821 const hash = std.hash.uint32(@intFromEnum(name));12821 const hash = std.hash.int(@intFromEnum(name));
12822 const map = ges.shared.map.acquire();12822 const map = ges.shared.map.acquire();
12823 const map_mask = map.header().mask();12823 const map_mask = map.header().mask();
12824 const names_items = ges.shared.names.acquire().view().items(.@"0");12824 const names_items = ges.shared.names.acquire().view().items(.@"0");
src/Sema.zig+3-12
...@@ -9705,7 +9705,6 @@ fn funcCommon(...@@ -9705,7 +9705,6 @@ fn funcCommon(
9705 func_inst,9705 func_inst,
9706 cc_src,9706 cc_src,
9707 is_noinline,9707 is_noinline,
9708 is_generic,
9709 );9708 );
9710 }9709 }
97119710
...@@ -9745,7 +9744,6 @@ fn funcCommon(...@@ -9745,7 +9744,6 @@ fn funcCommon(
9745 func_inst,9744 func_inst,
9746 cc_src,9745 cc_src,
9747 is_noinline,9746 is_noinline,
9748 is_generic,
9749 );9747 );
9750 }9748 }
97519749
...@@ -9762,7 +9760,6 @@ fn funcCommon(...@@ -9762,7 +9760,6 @@ fn funcCommon(
9762 func_inst,9760 func_inst,
9763 cc_src,9761 cc_src,
9764 is_noinline,9762 is_noinline,
9765 is_generic,
9766 );9763 );
9767}9764}
97689765
...@@ -9779,7 +9776,6 @@ fn finishFunc(...@@ -9779,7 +9776,6 @@ fn finishFunc(
9779 func_inst: Zir.Inst.Index,9776 func_inst: Zir.Inst.Index,
9780 cc_src: LazySrcLoc,9777 cc_src: LazySrcLoc,
9781 is_noinline: bool,9778 is_noinline: bool,
9782 is_generic: bool,
9783) CompileError!Air.Inst.Ref {9779) CompileError!Air.Inst.Ref {
9784 const pt = sema.pt;9780 const pt = sema.pt;
9785 const zcu = pt.zcu;9781 const zcu = pt.zcu;
...@@ -9911,13 +9907,6 @@ fn finishFunc(...@@ -9911,13 +9907,6 @@ fn finishFunc(
9911 }),9907 }),
9912 }9908 }
99139909
9914 if (!is_generic and sema.wantErrorReturnTracing(return_type)) {
9915 // Make sure that StackTrace's fields are resolved so that the backend can
9916 // lower this fn type.
9917 const unresolved_stack_trace_ty = try sema.getBuiltinType(block.nodeOffset(.zero), .StackTrace);
9918 try unresolved_stack_trace_ty.resolveFields(pt);
9919 }
9920
9921 return Air.internedToRef(if (opt_func_index != .none) opt_func_index else func_ty);9910 return Air.internedToRef(if (opt_func_index != .none) opt_func_index else func_ty);
9922}9911}
99239912
...@@ -13052,8 +13041,10 @@ fn analyzeSwitchRuntimeBlock(...@@ -13052,8 +13041,10 @@ fn analyzeSwitchRuntimeBlock(
13052 sema.air_extra.appendSliceAssumeCapacity(@ptrCast(cases_extra.items));13041 sema.air_extra.appendSliceAssumeCapacity(@ptrCast(cases_extra.items));
13053 sema.air_extra.appendSliceAssumeCapacity(@ptrCast(else_body));13042 sema.air_extra.appendSliceAssumeCapacity(@ptrCast(else_body));
1305413043
13044 const has_any_continues = spa.operand == .loop and child_block.label.?.merges.extra_insts.items.len > 0;
13045
13055 return try child_block.addInst(.{13046 return try child_block.addInst(.{
13056 .tag = if (spa.operand == .loop) .loop_switch_br else .switch_br,13047 .tag = if (has_any_continues) .loop_switch_br else .switch_br,
13057 .data = .{ .pl_op = .{13048 .data = .{ .pl_op = .{
13058 .operand = operand,13049 .operand = operand,
13059 .payload = payload_index,13050 .payload = payload_index,
src/Zcu.zig+2-2
...@@ -808,7 +808,7 @@ pub const Namespace = struct {...@@ -808,7 +808,7 @@ pub const Namespace = struct {
808808
809 pub fn hash(ctx: NavNameContext, nav: InternPool.Nav.Index) u32 {809 pub fn hash(ctx: NavNameContext, nav: InternPool.Nav.Index) u32 {
810 const name = ctx.zcu.intern_pool.getNav(nav).name;810 const name = ctx.zcu.intern_pool.getNav(nav).name;
811 return std.hash.uint32(@intFromEnum(name));811 return std.hash.int(@intFromEnum(name));
812 }812 }
813813
814 pub fn eql(ctx: NavNameContext, a_nav: InternPool.Nav.Index, b_nav: InternPool.Nav.Index, b_index: usize) bool {814 pub fn eql(ctx: NavNameContext, a_nav: InternPool.Nav.Index, b_nav: InternPool.Nav.Index, b_index: usize) bool {
...@@ -824,7 +824,7 @@ pub const Namespace = struct {...@@ -824,7 +824,7 @@ pub const Namespace = struct {
824824
825 pub fn hash(ctx: NameAdapter, s: InternPool.NullTerminatedString) u32 {825 pub fn hash(ctx: NameAdapter, s: InternPool.NullTerminatedString) u32 {
826 _ = ctx;826 _ = ctx;
827 return std.hash.uint32(@intFromEnum(s));827 return std.hash.int(@intFromEnum(s));
828 }828 }
829829
830 pub fn eql(ctx: NameAdapter, a: InternPool.NullTerminatedString, b_nav: InternPool.Nav.Index, b_index: usize) bool {830 pub fn eql(ctx: NameAdapter, a: InternPool.NullTerminatedString, b_nav: InternPool.Nav.Index, b_index: usize) bool {
src/arch/wasm/CodeGen.zig+4-4
...@@ -3975,7 +3975,7 @@ fn airSwitchBr(cg: *CodeGen, inst: Air.Inst.Index, is_dispatch_loop: bool) Inner...@@ -3975,7 +3975,7 @@ fn airSwitchBr(cg: *CodeGen, inst: Air.Inst.Index, is_dispatch_loop: bool) Inner
3975 var width_bigint: std.math.big.int.Mutable = .{ .limbs = limbs, .positive = undefined, .len = undefined };3975 var width_bigint: std.math.big.int.Mutable = .{ .limbs = limbs, .positive = undefined, .len = undefined };
3976 width_bigint.sub(max_bigint, min_bigint);3976 width_bigint.sub(max_bigint, min_bigint);
3977 width_bigint.addScalar(width_bigint.toConst(), 1);3977 width_bigint.addScalar(width_bigint.toConst(), 1);
3978 break :width width_bigint.toConst().to(u32) catch null;3978 break :width width_bigint.toConst().toInt(u32) catch null;
3979 };3979 };
39803980
3981 try cg.startBlock(.block, .empty); // whole switch block start3981 try cg.startBlock(.block, .empty); // whole switch block start
...@@ -4016,7 +4016,7 @@ fn airSwitchBr(cg: *CodeGen, inst: Air.Inst.Index, is_dispatch_loop: bool) Inner...@@ -4016,7 +4016,7 @@ fn airSwitchBr(cg: *CodeGen, inst: Air.Inst.Index, is_dispatch_loop: bool) Inner
4016 const val_bigint = val.toBigInt(&val_space, zcu);4016 const val_bigint = val.toBigInt(&val_space, zcu);
4017 var index_bigint: std.math.big.int.Mutable = .{ .limbs = limbs, .positive = undefined, .len = undefined };4017 var index_bigint: std.math.big.int.Mutable = .{ .limbs = limbs, .positive = undefined, .len = undefined };
4018 index_bigint.sub(val_bigint, min_bigint);4018 index_bigint.sub(val_bigint, min_bigint);
4019 branch_list[index_bigint.toConst().to(u32) catch unreachable] = case.idx;4019 branch_list[index_bigint.toConst().toInt(u32) catch unreachable] = case.idx;
4020 }4020 }
4021 for (case.ranges) |range| {4021 for (case.ranges) |range| {
4022 var low_space: Value.BigIntSpace = undefined;4022 var low_space: Value.BigIntSpace = undefined;
...@@ -4025,9 +4025,9 @@ fn airSwitchBr(cg: *CodeGen, inst: Air.Inst.Index, is_dispatch_loop: bool) Inner...@@ -4025,9 +4025,9 @@ fn airSwitchBr(cg: *CodeGen, inst: Air.Inst.Index, is_dispatch_loop: bool) Inner
4025 const high_bigint = Value.fromInterned(range[1].toInterned().?).toBigInt(&high_space, zcu);4025 const high_bigint = Value.fromInterned(range[1].toInterned().?).toBigInt(&high_space, zcu);
4026 var index_bigint: std.math.big.int.Mutable = .{ .limbs = limbs, .positive = undefined, .len = undefined };4026 var index_bigint: std.math.big.int.Mutable = .{ .limbs = limbs, .positive = undefined, .len = undefined };
4027 index_bigint.sub(low_bigint, min_bigint);4027 index_bigint.sub(low_bigint, min_bigint);
4028 const start = index_bigint.toConst().to(u32) catch unreachable;4028 const start = index_bigint.toConst().toInt(u32) catch unreachable;
4029 index_bigint.sub(high_bigint, min_bigint);4029 index_bigint.sub(high_bigint, min_bigint);
4030 const end = (index_bigint.toConst().to(u32) catch unreachable) + 1;4030 const end = (index_bigint.toConst().toInt(u32) catch unreachable) + 1;
4031 @memset(branch_list[start..end], case.idx);4031 @memset(branch_list[start..end], case.idx);
4032 }4032 }
4033 }4033 }
src/arch/wasm/Mir.zig+2-2
...@@ -687,7 +687,7 @@ pub fn lower(mir: *const Mir, wasm: *Wasm, code: *std.ArrayListUnmanaged(u8)) st...@@ -687,7 +687,7 @@ pub fn lower(mir: *const Mir, wasm: *Wasm, code: *std.ArrayListUnmanaged(u8)) st
687 const sp_global: Wasm.GlobalIndex = .stack_pointer;687 const sp_global: Wasm.GlobalIndex = .stack_pointer;
688 // load stack pointer688 // load stack pointer
689 code.appendAssumeCapacity(@intFromEnum(std.wasm.Opcode.global_get));689 code.appendAssumeCapacity(@intFromEnum(std.wasm.Opcode.global_get));
690 std.leb.writeULEB128(code.fixedWriter(), @intFromEnum(sp_global)) catch unreachable;690 std.leb.writeUleb128(code.fixedWriter(), @intFromEnum(sp_global)) catch unreachable;
691 // store stack pointer so we can restore it when we return from the function691 // store stack pointer so we can restore it when we return from the function
692 code.appendAssumeCapacity(@intFromEnum(std.wasm.Opcode.local_tee));692 code.appendAssumeCapacity(@intFromEnum(std.wasm.Opcode.local_tee));
693 leb.writeUleb128(code.fixedWriter(), mir.prologue.sp_local) catch unreachable;693 leb.writeUleb128(code.fixedWriter(), mir.prologue.sp_local) catch unreachable;
...@@ -710,7 +710,7 @@ pub fn lower(mir: *const Mir, wasm: *Wasm, code: *std.ArrayListUnmanaged(u8)) st...@@ -710,7 +710,7 @@ pub fn lower(mir: *const Mir, wasm: *Wasm, code: *std.ArrayListUnmanaged(u8)) st
710 // Store the current stack pointer value into the global stack pointer so other function calls will710 // Store the current stack pointer value into the global stack pointer so other function calls will
711 // start from this value instead and not overwrite the current stack.711 // start from this value instead and not overwrite the current stack.
712 code.appendAssumeCapacity(@intFromEnum(std.wasm.Opcode.global_set));712 code.appendAssumeCapacity(@intFromEnum(std.wasm.Opcode.global_set));
713 std.leb.writeULEB128(code.fixedWriter(), @intFromEnum(sp_global)) catch unreachable;713 std.leb.writeUleb128(code.fixedWriter(), @intFromEnum(sp_global)) catch unreachable;
714 }714 }
715715
716 var emit: Emit = .{716 var emit: Emit = .{
src/arch/x86_64/CodeGen.zig+4-4
...@@ -179277,7 +179277,7 @@ fn lowerSwitchBr(...@@ -179277,7 +179277,7 @@ fn lowerSwitchBr(
179277 var table_len_bigint: std.math.big.int.Mutable = .{ .limbs = limbs, .positive = undefined, .len = undefined };179277 var table_len_bigint: std.math.big.int.Mutable = .{ .limbs = limbs, .positive = undefined, .len = undefined };
179278 table_len_bigint.sub(max_bigint, min_bigint);179278 table_len_bigint.sub(max_bigint, min_bigint);
179279 assert(table_len_bigint.positive); // min <= max179279 assert(table_len_bigint.positive); // min <= max
179280 break :table_len @as(u11, table_len_bigint.toConst().to(u10) catch break :table) + 1; // no more than a 1024 entry table179280 break :table_len @as(u11, table_len_bigint.toConst().toInt(u10) catch break :table) + 1; // no more than a 1024 entry table
179281 };179281 };
179282 assert(prong_items <= table_len); // each prong item introduces at least one unique integer to the range179282 assert(prong_items <= table_len); // each prong item introduces at least one unique integer to the range
179283 if (prong_items < table_len >> 2) break :table; // no more than 75% waste179283 if (prong_items < table_len >> 2) break :table; // no more than 75% waste
...@@ -179353,7 +179353,7 @@ fn lowerSwitchBr(...@@ -179353,7 +179353,7 @@ fn lowerSwitchBr(
179353 const val_bigint = val.toBigInt(&val_space, zcu);179353 const val_bigint = val.toBigInt(&val_space, zcu);
179354 var index_bigint: std.math.big.int.Mutable = .{ .limbs = limbs, .positive = undefined, .len = undefined };179354 var index_bigint: std.math.big.int.Mutable = .{ .limbs = limbs, .positive = undefined, .len = undefined };
179355 index_bigint.sub(val_bigint, min_bigint);179355 index_bigint.sub(val_bigint, min_bigint);
179356 table[index_bigint.toConst().to(u10) catch unreachable] = @intCast(cg.mir_instructions.len);179356 table[index_bigint.toConst().toInt(u10) catch unreachable] = @intCast(cg.mir_instructions.len);
179357 }179357 }
179358 for (case.ranges) |range| {179358 for (case.ranges) |range| {
179359 var low_space: Value.BigIntSpace = undefined;179359 var low_space: Value.BigIntSpace = undefined;
...@@ -179362,9 +179362,9 @@ fn lowerSwitchBr(...@@ -179362,9 +179362,9 @@ fn lowerSwitchBr(
179362 const high_bigint = Value.fromInterned(range[1].toInterned().?).toBigInt(&high_space, zcu);179362 const high_bigint = Value.fromInterned(range[1].toInterned().?).toBigInt(&high_space, zcu);
179363 var index_bigint: std.math.big.int.Mutable = .{ .limbs = limbs, .positive = undefined, .len = undefined };179363 var index_bigint: std.math.big.int.Mutable = .{ .limbs = limbs, .positive = undefined, .len = undefined };
179364 index_bigint.sub(low_bigint, min_bigint);179364 index_bigint.sub(low_bigint, min_bigint);
179365 const start = index_bigint.toConst().to(u10) catch unreachable;179365 const start = index_bigint.toConst().toInt(u10) catch unreachable;
179366 index_bigint.sub(high_bigint, min_bigint);179366 index_bigint.sub(high_bigint, min_bigint);
179367 const end = @as(u11, index_bigint.toConst().to(u10) catch unreachable) + 1;179367 const end = @as(u11, index_bigint.toConst().toInt(u10) catch unreachable) + 1;
179368 @memset(table[start..end], @intCast(cg.mir_instructions.len));179368 @memset(table[start..end], @intCast(cg.mir_instructions.len));
179369 }179369 }
179370 }179370 }
src/codegen/llvm.zig+609-610
...@@ -494,8 +494,6 @@ pub const Object = struct {...@@ -494,8 +494,6 @@ pub const Object = struct {
494 gpa: Allocator,494 gpa: Allocator,
495 builder: Builder,495 builder: Builder,
496496
497 pt: Zcu.PerThread,
498
499 debug_compile_unit: Builder.Metadata,497 debug_compile_unit: Builder.Metadata,
500498
501 debug_enums_fwd_ref: Builder.Metadata,499 debug_enums_fwd_ref: Builder.Metadata,
...@@ -626,10 +624,6 @@ pub const Object = struct {...@@ -626,10 +624,6 @@ pub const Object = struct {
626 obj.* = .{624 obj.* = .{
627 .gpa = gpa,625 .gpa = gpa,
628 .builder = builder,626 .builder = builder,
629 .pt = .{
630 .zcu = comp.zcu.?,
631 .tid = .main,
632 },
633 .debug_compile_unit = debug_compile_unit,627 .debug_compile_unit = debug_compile_unit,
634 .debug_enums_fwd_ref = debug_enums_fwd_ref,628 .debug_enums_fwd_ref = debug_enums_fwd_ref,
635 .debug_globals_fwd_ref = debug_globals_fwd_ref,629 .debug_globals_fwd_ref = debug_globals_fwd_ref,
...@@ -669,11 +663,10 @@ pub const Object = struct {...@@ -669,11 +663,10 @@ pub const Object = struct {
669 self.* = undefined;663 self.* = undefined;
670 }664 }
671665
672 fn genErrorNameTable(o: *Object) Allocator.Error!void {666 fn genErrorNameTable(o: *Object, pt: Zcu.PerThread) Allocator.Error!void {
673 // If o.error_name_table is null, then it was not referenced by any instructions.667 // If o.error_name_table is null, then it was not referenced by any instructions.
674 if (o.error_name_table == .none) return;668 if (o.error_name_table == .none) return;
675669
676 const pt = o.pt;
677 const zcu = pt.zcu;670 const zcu = pt.zcu;
678 const ip = &zcu.intern_pool;671 const ip = &zcu.intern_pool;
679672
...@@ -683,8 +676,8 @@ pub const Object = struct {...@@ -683,8 +676,8 @@ pub const Object = struct {
683676
684 // TODO: Address space677 // TODO: Address space
685 const slice_ty = Type.slice_const_u8_sentinel_0;678 const slice_ty = Type.slice_const_u8_sentinel_0;
686 const llvm_usize_ty = try o.lowerType(Type.usize);679 const llvm_usize_ty = try o.lowerType(pt, Type.usize);
687 const llvm_slice_ty = try o.lowerType(slice_ty);680 const llvm_slice_ty = try o.lowerType(pt, slice_ty);
688 const llvm_table_ty = try o.builder.arrayType(1 + error_name_list.len, llvm_slice_ty);681 const llvm_table_ty = try o.builder.arrayType(1 + error_name_list.len, llvm_slice_ty);
689682
690 llvm_errors[0] = try o.builder.undefConst(llvm_slice_ty);683 llvm_errors[0] = try o.builder.undefConst(llvm_slice_ty);
...@@ -721,11 +714,11 @@ pub const Object = struct {...@@ -721,11 +714,11 @@ pub const Object = struct {
721 try o.error_name_table.setInitializer(table_variable_index.toConst(&o.builder), &o.builder);714 try o.error_name_table.setInitializer(table_variable_index.toConst(&o.builder), &o.builder);
722 }715 }
723716
724 fn genCmpLtErrorsLenFunction(o: *Object) !void {717 fn genCmpLtErrorsLenFunction(o: *Object, pt: Zcu.PerThread) !void {
725 // If there is no such function in the module, it means the source code does not need it.718 // If there is no such function in the module, it means the source code does not need it.
726 const name = o.builder.strtabStringIfExists(lt_errors_fn_name) orelse return;719 const name = o.builder.strtabStringIfExists(lt_errors_fn_name) orelse return;
727 const llvm_fn = o.builder.getGlobal(name) orelse return;720 const llvm_fn = o.builder.getGlobal(name) orelse return;
728 const errors_len = o.pt.zcu.intern_pool.global_error_set.getNamesFromMainThread().len;721 const errors_len = pt.zcu.intern_pool.global_error_set.getNamesFromMainThread().len;
729722
730 var wip = try Builder.WipFunction.init(&o.builder, .{723 var wip = try Builder.WipFunction.init(&o.builder, .{
731 .function = llvm_fn.ptrConst(&o.builder).kind.function,724 .function = llvm_fn.ptrConst(&o.builder).kind.function,
...@@ -740,17 +733,17 @@ pub const Object = struct {...@@ -740,17 +733,17 @@ pub const Object = struct {
740 // }733 // }
741734
742 const lhs = wip.arg(0);735 const lhs = wip.arg(0);
743 const rhs = try o.builder.intValue(try o.errorIntType(), errors_len);736 const rhs = try o.builder.intValue(try o.errorIntType(pt), errors_len);
744 const is_lt = try wip.icmp(.ule, lhs, rhs, "");737 const is_lt = try wip.icmp(.ule, lhs, rhs, "");
745 _ = try wip.ret(is_lt);738 _ = try wip.ret(is_lt);
746 try wip.finish();739 try wip.finish();
747 }740 }
748741
749 fn genModuleLevelAssembly(object: *Object) Allocator.Error!void {742 fn genModuleLevelAssembly(object: *Object, pt: Zcu.PerThread) Allocator.Error!void {
750 const b = &object.builder;743 const b = &object.builder;
751 const gpa = b.gpa;744 const gpa = b.gpa;
752 b.module_asm.clearRetainingCapacity();745 b.module_asm.clearRetainingCapacity();
753 for (object.pt.zcu.global_assembly.values()) |assembly| {746 for (pt.zcu.global_assembly.values()) |assembly| {
754 try b.module_asm.ensureUnusedCapacity(gpa, assembly.len + 1);747 try b.module_asm.ensureUnusedCapacity(gpa, assembly.len + 1);
755 b.module_asm.appendSliceAssumeCapacity(assembly);748 b.module_asm.appendSliceAssumeCapacity(assembly);
756 b.module_asm.appendAssumeCapacity('\n');749 b.module_asm.appendAssumeCapacity('\n');
...@@ -776,15 +769,15 @@ pub const Object = struct {...@@ -776,15 +769,15 @@ pub const Object = struct {
776 lto: std.zig.LtoMode,769 lto: std.zig.LtoMode,
777 };770 };
778771
779 pub fn emit(o: *Object, options: EmitOptions) error{ LinkFailure, OutOfMemory }!void {772 pub fn emit(o: *Object, pt: Zcu.PerThread, options: EmitOptions) error{ LinkFailure, OutOfMemory }!void {
780 const zcu = o.pt.zcu;773 const zcu = pt.zcu;
781 const comp = zcu.comp;774 const comp = zcu.comp;
782 const diags = &comp.link_diags;775 const diags = &comp.link_diags;
783776
784 {777 {
785 try o.genErrorNameTable();778 try o.genErrorNameTable(pt);
786 try o.genCmpLtErrorsLenFunction();779 try o.genCmpLtErrorsLenFunction(pt);
787 try o.genModuleLevelAssembly();780 try o.genModuleLevelAssembly(pt);
788781
789 if (o.used.items.len > 0) {782 if (o.used.items.len > 0) {
790 const array_llvm_ty = try o.builder.arrayType(o.used.items.len, .ptr);783 const array_llvm_ty = try o.builder.arrayType(o.used.items.len, .ptr);
...@@ -807,7 +800,7 @@ pub const Object = struct {...@@ -807,7 +800,7 @@ pub const Object = struct {
807 const fwd_ref = o.debug_unresolved_namespace_scopes.values()[i];800 const fwd_ref = o.debug_unresolved_namespace_scopes.values()[i];
808801
809 const namespace = zcu.namespacePtr(namespace_index);802 const namespace = zcu.namespacePtr(namespace_index);
810 const debug_type = try o.lowerDebugType(Type.fromInterned(namespace.owner_type));803 const debug_type = try o.lowerDebugType(pt, Type.fromInterned(namespace.owner_type));
811804
812 o.builder.debugForwardReferenceSetType(fwd_ref, debug_type);805 o.builder.debugForwardReferenceSetType(fwd_ref, debug_type);
813 }806 }
...@@ -1140,7 +1133,6 @@ pub const Object = struct {...@@ -1140,7 +1133,6 @@ pub const Object = struct {
1140 air: *const Air,1133 air: *const Air,
1141 liveness: *const Air.Liveness,1134 liveness: *const Air.Liveness,
1142 ) !void {1135 ) !void {
1143 assert(std.meta.eql(pt, o.pt));
1144 const zcu = pt.zcu;1136 const zcu = pt.zcu;
1145 const comp = zcu.comp;1137 const comp = zcu.comp;
1146 const ip = &zcu.intern_pool;1138 const ip = &zcu.intern_pool;
...@@ -1155,10 +1147,11 @@ pub const Object = struct {...@@ -1155,10 +1147,11 @@ pub const Object = struct {
1155 var ng: NavGen = .{1147 var ng: NavGen = .{
1156 .object = o,1148 .object = o,
1157 .nav_index = func.owner_nav,1149 .nav_index = func.owner_nav,
1150 .pt = pt,
1158 .err_msg = null,1151 .err_msg = null,
1159 };1152 };
11601153
1161 const function_index = try o.resolveLlvmFunction(func.owner_nav);1154 const function_index = try o.resolveLlvmFunction(pt, func.owner_nav);
11621155
1163 var attributes = try function_index.ptrConst(&o.builder).attributes.toWip(&o.builder);1156 var attributes = try function_index.ptrConst(&o.builder).attributes.toWip(&o.builder);
1164 defer attributes.deinit(&o.builder);1157 defer attributes.deinit(&o.builder);
...@@ -1272,7 +1265,7 @@ pub const Object = struct {...@@ -1272,7 +1265,7 @@ pub const Object = struct {
1272 defer args.deinit(gpa);1265 defer args.deinit(gpa);
12731266
1274 {1267 {
1275 var it = iterateParamTypes(o, fn_info);1268 var it = iterateParamTypes(o, pt, fn_info);
1276 while (try it.next()) |lowering| {1269 while (try it.next()) |lowering| {
1277 try args.ensureUnusedCapacity(gpa, 1);1270 try args.ensureUnusedCapacity(gpa, 1);
12781271
...@@ -1293,13 +1286,13 @@ pub const Object = struct {...@@ -1293,13 +1286,13 @@ pub const Object = struct {
1293 } else {1286 } else {
1294 args.appendAssumeCapacity(param);1287 args.appendAssumeCapacity(param);
12951288
1296 try o.addByValParamAttrs(&attributes, param_ty, param_index, fn_info, llvm_arg_i);1289 try o.addByValParamAttrs(pt, &attributes, param_ty, param_index, fn_info, llvm_arg_i);
1297 }1290 }
1298 llvm_arg_i += 1;1291 llvm_arg_i += 1;
1299 },1292 },
1300 .byref => {1293 .byref => {
1301 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);1294 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);
1302 const param_llvm_ty = try o.lowerType(param_ty);1295 const param_llvm_ty = try o.lowerType(pt, param_ty);
1303 const param = wip.arg(llvm_arg_i);1296 const param = wip.arg(llvm_arg_i);
1304 const alignment = param_ty.abiAlignment(zcu).toLlvm();1297 const alignment = param_ty.abiAlignment(zcu).toLlvm();
13051298
...@@ -1314,7 +1307,7 @@ pub const Object = struct {...@@ -1314,7 +1307,7 @@ pub const Object = struct {
1314 },1307 },
1315 .byref_mut => {1308 .byref_mut => {
1316 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);1309 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);
1317 const param_llvm_ty = try o.lowerType(param_ty);1310 const param_llvm_ty = try o.lowerType(pt, param_ty);
1318 const param = wip.arg(llvm_arg_i);1311 const param = wip.arg(llvm_arg_i);
1319 const alignment = param_ty.abiAlignment(zcu).toLlvm();1312 const alignment = param_ty.abiAlignment(zcu).toLlvm();
13201313
...@@ -1333,7 +1326,7 @@ pub const Object = struct {...@@ -1333,7 +1326,7 @@ pub const Object = struct {
1333 const param = wip.arg(llvm_arg_i);1326 const param = wip.arg(llvm_arg_i);
1334 llvm_arg_i += 1;1327 llvm_arg_i += 1;
13351328
1336 const param_llvm_ty = try o.lowerType(param_ty);1329 const param_llvm_ty = try o.lowerType(pt, param_ty);
1337 const alignment = param_ty.abiAlignment(zcu).toLlvm();1330 const alignment = param_ty.abiAlignment(zcu).toLlvm();
1338 const arg_ptr = try buildAllocaInner(&wip, param_llvm_ty, alignment, target);1331 const arg_ptr = try buildAllocaInner(&wip, param_llvm_ty, alignment, target);
1339 _ = try wip.store(.normal, param, arg_ptr, alignment);1332 _ = try wip.store(.normal, param, arg_ptr, alignment);
...@@ -1372,7 +1365,7 @@ pub const Object = struct {...@@ -1372,7 +1365,7 @@ pub const Object = struct {
1372 const len_param = wip.arg(llvm_arg_i);1365 const len_param = wip.arg(llvm_arg_i);
1373 llvm_arg_i += 1;1366 llvm_arg_i += 1;
13741367
1375 const slice_llvm_ty = try o.lowerType(param_ty);1368 const slice_llvm_ty = try o.lowerType(pt, param_ty);
1376 args.appendAssumeCapacity(1369 args.appendAssumeCapacity(
1377 try wip.buildAggregate(slice_llvm_ty, &.{ ptr_param, len_param }, ""),1370 try wip.buildAggregate(slice_llvm_ty, &.{ ptr_param, len_param }, ""),
1378 );1371 );
...@@ -1381,7 +1374,7 @@ pub const Object = struct {...@@ -1381,7 +1374,7 @@ pub const Object = struct {
1381 assert(!it.byval_attr);1374 assert(!it.byval_attr);
1382 const field_types = it.types_buffer[0..it.types_len];1375 const field_types = it.types_buffer[0..it.types_len];
1383 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);1376 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);
1384 const param_llvm_ty = try o.lowerType(param_ty);1377 const param_llvm_ty = try o.lowerType(pt, param_ty);
1385 const param_alignment = param_ty.abiAlignment(zcu).toLlvm();1378 const param_alignment = param_ty.abiAlignment(zcu).toLlvm();
1386 const arg_ptr = try buildAllocaInner(&wip, param_llvm_ty, param_alignment, target);1379 const arg_ptr = try buildAllocaInner(&wip, param_llvm_ty, param_alignment, target);
1387 const llvm_ty = try o.builder.structType(.normal, field_types);1380 const llvm_ty = try o.builder.structType(.normal, field_types);
...@@ -1402,7 +1395,7 @@ pub const Object = struct {...@@ -1402,7 +1395,7 @@ pub const Object = struct {
1402 },1395 },
1403 .float_array => {1396 .float_array => {
1404 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);1397 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);
1405 const param_llvm_ty = try o.lowerType(param_ty);1398 const param_llvm_ty = try o.lowerType(pt, param_ty);
1406 const param = wip.arg(llvm_arg_i);1399 const param = wip.arg(llvm_arg_i);
1407 llvm_arg_i += 1;1400 llvm_arg_i += 1;
14081401
...@@ -1417,7 +1410,7 @@ pub const Object = struct {...@@ -1417,7 +1410,7 @@ pub const Object = struct {
1417 },1410 },
1418 .i32_array, .i64_array => {1411 .i32_array, .i64_array => {
1419 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);1412 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);
1420 const param_llvm_ty = try o.lowerType(param_ty);1413 const param_llvm_ty = try o.lowerType(pt, param_ty);
1421 const param = wip.arg(llvm_arg_i);1414 const param = wip.arg(llvm_arg_i);
1422 llvm_arg_i += 1;1415 llvm_arg_i += 1;
14231416
...@@ -1435,11 +1428,11 @@ pub const Object = struct {...@@ -1435,11 +1428,11 @@ pub const Object = struct {
1435 }1428 }
14361429
1437 const file, const subprogram = if (!wip.strip) debug_info: {1430 const file, const subprogram = if (!wip.strip) debug_info: {
1438 const file = try o.getDebugFile(file_scope);1431 const file = try o.getDebugFile(pt, file_scope);
14391432
1440 const line_number = zcu.navSrcLine(func.owner_nav) + 1;1433 const line_number = zcu.navSrcLine(func.owner_nav) + 1;
1441 const is_internal_linkage = ip.indexToKey(nav.status.fully_resolved.val) != .@"extern";1434 const is_internal_linkage = ip.indexToKey(nav.status.fully_resolved.val) != .@"extern";
1442 const debug_decl_type = try o.lowerDebugType(fn_ty);1435 const debug_decl_type = try o.lowerDebugType(pt, fn_ty);
14431436
1444 const subprogram = try o.builder.debugSubprogram(1437 const subprogram = try o.builder.debugSubprogram(
1445 file,1438 file,
...@@ -1569,10 +1562,10 @@ pub const Object = struct {...@@ -1569,10 +1562,10 @@ pub const Object = struct {
1569 }1562 }
15701563
1571 pub fn updateNav(self: *Object, pt: Zcu.PerThread, nav_index: InternPool.Nav.Index) !void {1564 pub fn updateNav(self: *Object, pt: Zcu.PerThread, nav_index: InternPool.Nav.Index) !void {
1572 assert(std.meta.eql(pt, self.pt));
1573 var ng: NavGen = .{1565 var ng: NavGen = .{
1574 .object = self,1566 .object = self,
1575 .nav_index = nav_index,1567 .nav_index = nav_index,
1568 .pt = pt,
1576 .err_msg = null,1569 .err_msg = null,
1577 };1570 };
1578 ng.genDecl() catch |err| switch (err) {1571 ng.genDecl() catch |err| switch (err) {
...@@ -1590,11 +1583,10 @@ pub const Object = struct {...@@ -1590,11 +1583,10 @@ pub const Object = struct {
1590 exported: Zcu.Exported,1583 exported: Zcu.Exported,
1591 export_indices: []const Zcu.Export.Index,1584 export_indices: []const Zcu.Export.Index,
1592 ) link.File.UpdateExportsError!void {1585 ) link.File.UpdateExportsError!void {
1593 assert(std.meta.eql(pt, self.pt));
1594 const zcu = pt.zcu;1586 const zcu = pt.zcu;
1595 const nav_index = switch (exported) {1587 const nav_index = switch (exported) {
1596 .nav => |nav| nav,1588 .nav => |nav| nav,
1597 .uav => |uav| return updateExportedValue(self, zcu, uav, export_indices),1589 .uav => |uav| return updateExportedValue(self, pt, uav, export_indices),
1598 };1590 };
1599 const ip = &zcu.intern_pool;1591 const ip = &zcu.intern_pool;
1600 const global_index = self.nav_map.get(nav_index).?;1592 const global_index = self.nav_map.get(nav_index).?;
...@@ -1635,10 +1627,11 @@ pub const Object = struct {...@@ -1635,10 +1627,11 @@ pub const Object = struct {
16351627
1636 fn updateExportedValue(1628 fn updateExportedValue(
1637 o: *Object,1629 o: *Object,
1638 zcu: *Zcu,1630 pt: Zcu.PerThread,
1639 exported_value: InternPool.Index,1631 exported_value: InternPool.Index,
1640 export_indices: []const Zcu.Export.Index,1632 export_indices: []const Zcu.Export.Index,
1641 ) link.File.UpdateExportsError!void {1633 ) link.File.UpdateExportsError!void {
1634 const zcu = pt.zcu;
1642 const gpa = zcu.gpa;1635 const gpa = zcu.gpa;
1643 const ip = &zcu.intern_pool;1636 const ip = &zcu.intern_pool;
1644 const main_exp_name = try o.builder.strtabString(export_indices[0].ptr(zcu).opts.name.toSlice(ip));1637 const main_exp_name = try o.builder.strtabString(export_indices[0].ptr(zcu).opts.name.toSlice(ip));
...@@ -1652,13 +1645,13 @@ pub const Object = struct {...@@ -1652,13 +1645,13 @@ pub const Object = struct {
1652 const llvm_addr_space = toLlvmAddressSpace(.generic, o.target);1645 const llvm_addr_space = toLlvmAddressSpace(.generic, o.target);
1653 const variable_index = try o.builder.addVariable(1646 const variable_index = try o.builder.addVariable(
1654 main_exp_name,1647 main_exp_name,
1655 try o.lowerType(Type.fromInterned(ip.typeOf(exported_value))),1648 try o.lowerType(pt, Type.fromInterned(ip.typeOf(exported_value))),
1656 llvm_addr_space,1649 llvm_addr_space,
1657 );1650 );
1658 const global_index = variable_index.ptrConst(&o.builder).global;1651 const global_index = variable_index.ptrConst(&o.builder).global;
1659 gop.value_ptr.* = global_index;1652 gop.value_ptr.* = global_index;
1660 // This line invalidates `gop`.1653 // This line invalidates `gop`.
1661 const init_val = o.lowerValue(exported_value) catch |err| switch (err) {1654 const init_val = o.lowerValue(pt, exported_value) catch |err| switch (err) {
1662 error.OutOfMemory => return error.OutOfMemory,1655 error.OutOfMemory => return error.OutOfMemory,
1663 error.CodegenFail => return error.AnalysisFail,1656 error.CodegenFail => return error.AnalysisFail,
1664 };1657 };
...@@ -1761,14 +1754,13 @@ pub const Object = struct {...@@ -1761,14 +1754,13 @@ pub const Object = struct {
1761 }1754 }
1762 }1755 }
17631756
1764 fn getDebugFile(o: *Object, file_index: Zcu.File.Index) Allocator.Error!Builder.Metadata {1757 fn getDebugFile(o: *Object, pt: Zcu.PerThread, file_index: Zcu.File.Index) Allocator.Error!Builder.Metadata {
1765 const gpa = o.gpa;1758 const gpa = o.gpa;
1766 const gop = try o.debug_file_map.getOrPut(gpa, file_index);1759 const gop = try o.debug_file_map.getOrPut(gpa, file_index);
1767 errdefer assert(o.debug_file_map.remove(file_index));1760 errdefer assert(o.debug_file_map.remove(file_index));
1768 if (gop.found_existing) return gop.value_ptr.*;1761 if (gop.found_existing) return gop.value_ptr.*;
1769 const zcu = o.pt.zcu;1762 const path = pt.zcu.fileByIndex(file_index).path;
1770 const path = zcu.fileByIndex(file_index).path;1763 const abs_path = try path.toAbsolute(pt.zcu.comp.dirs, gpa);
1771 const abs_path = try path.toAbsolute(zcu.comp.dirs, gpa);
1772 defer gpa.free(abs_path);1764 defer gpa.free(abs_path);
17731765
1774 gop.value_ptr.* = try o.builder.debugFile(1766 gop.value_ptr.* = try o.builder.debugFile(
...@@ -1780,13 +1772,13 @@ pub const Object = struct {...@@ -1780,13 +1772,13 @@ pub const Object = struct {
17801772
1781 pub fn lowerDebugType(1773 pub fn lowerDebugType(
1782 o: *Object,1774 o: *Object,
1775 pt: Zcu.PerThread,
1783 ty: Type,1776 ty: Type,
1784 ) Allocator.Error!Builder.Metadata {1777 ) Allocator.Error!Builder.Metadata {
1785 assert(!o.builder.strip);1778 assert(!o.builder.strip);
17861779
1787 const gpa = o.gpa;1780 const gpa = o.gpa;
1788 const target = o.target;1781 const target = o.target;
1789 const pt = o.pt;
1790 const zcu = pt.zcu;1782 const zcu = pt.zcu;
1791 const ip = &zcu.intern_pool;1783 const ip = &zcu.intern_pool;
17921784
...@@ -1806,7 +1798,7 @@ pub const Object = struct {...@@ -1806,7 +1798,7 @@ pub const Object = struct {
1806 .int => {1798 .int => {
1807 const info = ty.intInfo(zcu);1799 const info = ty.intInfo(zcu);
1808 assert(info.bits != 0);1800 assert(info.bits != 0);
1809 const name = try o.allocTypeName(ty);1801 const name = try o.allocTypeName(pt, ty);
1810 defer gpa.free(name);1802 defer gpa.free(name);
1811 const builder_name = try o.builder.metadataString(name);1803 const builder_name = try o.builder.metadataString(name);
1812 const debug_bits = ty.abiSize(zcu) * 8; // lldb cannot handle non-byte sized types1804 const debug_bits = ty.abiSize(zcu) * 8; // lldb cannot handle non-byte sized types
...@@ -1819,7 +1811,7 @@ pub const Object = struct {...@@ -1819,7 +1811,7 @@ pub const Object = struct {
1819 },1811 },
1820 .@"enum" => {1812 .@"enum" => {
1821 if (!ty.hasRuntimeBitsIgnoreComptime(zcu)) {1813 if (!ty.hasRuntimeBitsIgnoreComptime(zcu)) {
1822 const debug_enum_type = try o.makeEmptyNamespaceDebugType(ty);1814 const debug_enum_type = try o.makeEmptyNamespaceDebugType(pt, ty);
1823 try o.debug_type_map.put(gpa, ty, debug_enum_type);1815 try o.debug_type_map.put(gpa, ty, debug_enum_type);
1824 return debug_enum_type;1816 return debug_enum_type;
1825 }1817 }
...@@ -1847,13 +1839,13 @@ pub const Object = struct {...@@ -1847,13 +1839,13 @@ pub const Object = struct {
1847 );1839 );
1848 }1840 }
18491841
1850 const file = try o.getDebugFile(ty.typeDeclInstAllowGeneratedTag(zcu).?.resolveFile(ip));1842 const file = try o.getDebugFile(pt, ty.typeDeclInstAllowGeneratedTag(zcu).?.resolveFile(ip));
1851 const scope = if (ty.getParentNamespace(zcu).unwrap()) |parent_namespace|1843 const scope = if (ty.getParentNamespace(zcu).unwrap()) |parent_namespace|
1852 try o.namespaceToDebugScope(parent_namespace)1844 try o.namespaceToDebugScope(pt, parent_namespace)
1853 else1845 else
1854 file;1846 file;
18551847
1856 const name = try o.allocTypeName(ty);1848 const name = try o.allocTypeName(pt, ty);
1857 defer gpa.free(name);1849 defer gpa.free(name);
18581850
1859 const debug_enum_type = try o.builder.debugEnumerationType(1851 const debug_enum_type = try o.builder.debugEnumerationType(
...@@ -1861,7 +1853,7 @@ pub const Object = struct {...@@ -1861,7 +1853,7 @@ pub const Object = struct {
1861 file,1853 file,
1862 scope,1854 scope,
1863 ty.typeDeclSrcLine(zcu).? + 1, // Line1855 ty.typeDeclSrcLine(zcu).? + 1, // Line
1864 try o.lowerDebugType(int_ty),1856 try o.lowerDebugType(pt, int_ty),
1865 ty.abiSize(zcu) * 8,1857 ty.abiSize(zcu) * 8,
1866 (ty.abiAlignment(zcu).toByteUnits() orelse 0) * 8,1858 (ty.abiAlignment(zcu).toByteUnits() orelse 0) * 8,
1867 try o.builder.metadataTuple(enumerators),1859 try o.builder.metadataTuple(enumerators),
...@@ -1873,7 +1865,7 @@ pub const Object = struct {...@@ -1873,7 +1865,7 @@ pub const Object = struct {
1873 },1865 },
1874 .float => {1866 .float => {
1875 const bits = ty.floatBits(target);1867 const bits = ty.floatBits(target);
1876 const name = try o.allocTypeName(ty);1868 const name = try o.allocTypeName(pt, ty);
1877 defer gpa.free(name);1869 defer gpa.free(name);
1878 const debug_float_type = try o.builder.debugFloatType(1870 const debug_float_type = try o.builder.debugFloatType(
1879 try o.builder.metadataString(name),1871 try o.builder.metadataString(name),
...@@ -1918,7 +1910,7 @@ pub const Object = struct {...@@ -1918,7 +1910,7 @@ pub const Object = struct {
1918 },1910 },
1919 },1911 },
1920 });1912 });
1921 const debug_ptr_type = try o.lowerDebugType(bland_ptr_ty);1913 const debug_ptr_type = try o.lowerDebugType(pt, bland_ptr_ty);
1922 try o.debug_type_map.put(gpa, ty, debug_ptr_type);1914 try o.debug_type_map.put(gpa, ty, debug_ptr_type);
1923 return debug_ptr_type;1915 return debug_ptr_type;
1924 }1916 }
...@@ -1932,7 +1924,7 @@ pub const Object = struct {...@@ -1932,7 +1924,7 @@ pub const Object = struct {
1932 const ptr_ty = ty.slicePtrFieldType(zcu);1924 const ptr_ty = ty.slicePtrFieldType(zcu);
1933 const len_ty = Type.usize;1925 const len_ty = Type.usize;
19341926
1935 const name = try o.allocTypeName(ty);1927 const name = try o.allocTypeName(pt, ty);
1936 defer gpa.free(name);1928 defer gpa.free(name);
1937 const line = 0;1929 const line = 0;
19381930
...@@ -1948,7 +1940,7 @@ pub const Object = struct {...@@ -1948,7 +1940,7 @@ pub const Object = struct {
1948 .none, // File1940 .none, // File
1949 debug_fwd_ref,1941 debug_fwd_ref,
1950 0, // Line1942 0, // Line
1951 try o.lowerDebugType(ptr_ty),1943 try o.lowerDebugType(pt, ptr_ty),
1952 ptr_size * 8,1944 ptr_size * 8,
1953 (ptr_align.toByteUnits() orelse 0) * 8,1945 (ptr_align.toByteUnits() orelse 0) * 8,
1954 0, // Offset1946 0, // Offset
...@@ -1959,7 +1951,7 @@ pub const Object = struct {...@@ -1959,7 +1951,7 @@ pub const Object = struct {
1959 .none, // File1951 .none, // File
1960 debug_fwd_ref,1952 debug_fwd_ref,
1961 0, // Line1953 0, // Line
1962 try o.lowerDebugType(len_ty),1954 try o.lowerDebugType(pt, len_ty),
1963 len_size * 8,1955 len_size * 8,
1964 (len_align.toByteUnits() orelse 0) * 8,1956 (len_align.toByteUnits() orelse 0) * 8,
1965 len_offset * 8,1957 len_offset * 8,
...@@ -1988,9 +1980,9 @@ pub const Object = struct {...@@ -1988,9 +1980,9 @@ pub const Object = struct {
1988 return debug_slice_type;1980 return debug_slice_type;
1989 }1981 }
19901982
1991 const debug_elem_ty = try o.lowerDebugType(Type.fromInterned(ptr_info.child));1983 const debug_elem_ty = try o.lowerDebugType(pt, Type.fromInterned(ptr_info.child));
19921984
1993 const name = try o.allocTypeName(ty);1985 const name = try o.allocTypeName(pt, ty);
1994 defer gpa.free(name);1986 defer gpa.free(name);
19951987
1996 const debug_ptr_type = try o.builder.debugPointerType(1988 const debug_ptr_type = try o.builder.debugPointerType(
...@@ -2022,12 +2014,12 @@ pub const Object = struct {...@@ -2022,12 +2014,12 @@ pub const Object = struct {
2022 return debug_opaque_type;2014 return debug_opaque_type;
2023 }2015 }
20242016
2025 const name = try o.allocTypeName(ty);2017 const name = try o.allocTypeName(pt, ty);
2026 defer gpa.free(name);2018 defer gpa.free(name);
20272019
2028 const file = try o.getDebugFile(ty.typeDeclInstAllowGeneratedTag(zcu).?.resolveFile(ip));2020 const file = try o.getDebugFile(pt, ty.typeDeclInstAllowGeneratedTag(zcu).?.resolveFile(ip));
2029 const scope = if (ty.getParentNamespace(zcu).unwrap()) |parent_namespace|2021 const scope = if (ty.getParentNamespace(zcu).unwrap()) |parent_namespace|
2030 try o.namespaceToDebugScope(parent_namespace)2022 try o.namespaceToDebugScope(pt, parent_namespace)
2031 else2023 else
2032 file;2024 file;
20332025
...@@ -2050,7 +2042,7 @@ pub const Object = struct {...@@ -2050,7 +2042,7 @@ pub const Object = struct {
2050 .none, // File2042 .none, // File
2051 .none, // Scope2043 .none, // Scope
2052 0, // Line2044 0, // Line
2053 try o.lowerDebugType(ty.childType(zcu)),2045 try o.lowerDebugType(pt, ty.childType(zcu)),
2054 ty.abiSize(zcu) * 8,2046 ty.abiSize(zcu) * 8,
2055 (ty.abiAlignment(zcu).toByteUnits() orelse 0) * 8,2047 (ty.abiAlignment(zcu).toByteUnits() orelse 0) * 8,
2056 try o.builder.metadataTuple(&.{2048 try o.builder.metadataTuple(&.{
...@@ -2073,7 +2065,7 @@ pub const Object = struct {...@@ -2073,7 +2065,7 @@ pub const Object = struct {
2073 .int => blk: {2065 .int => blk: {
2074 const info = elem_ty.intInfo(zcu);2066 const info = elem_ty.intInfo(zcu);
2075 assert(info.bits != 0);2067 assert(info.bits != 0);
2076 const name = try o.allocTypeName(ty);2068 const name = try o.allocTypeName(pt, ty);
2077 defer gpa.free(name);2069 defer gpa.free(name);
2078 const builder_name = try o.builder.metadataString(name);2070 const builder_name = try o.builder.metadataString(name);
2079 break :blk switch (info.signedness) {2071 break :blk switch (info.signedness) {
...@@ -2085,7 +2077,7 @@ pub const Object = struct {...@@ -2085,7 +2077,7 @@ pub const Object = struct {
2085 try o.builder.metadataString("bool"),2077 try o.builder.metadataString("bool"),
2086 1,2078 1,
2087 ),2079 ),
2088 else => try o.lowerDebugType(ty.childType(zcu)),2080 else => try o.lowerDebugType(pt, ty.childType(zcu)),
2089 };2081 };
20902082
2091 const debug_vector_type = try o.builder.debugVectorType(2083 const debug_vector_type = try o.builder.debugVectorType(
...@@ -2108,7 +2100,7 @@ pub const Object = struct {...@@ -2108,7 +2100,7 @@ pub const Object = struct {
2108 return debug_vector_type;2100 return debug_vector_type;
2109 },2101 },
2110 .optional => {2102 .optional => {
2111 const name = try o.allocTypeName(ty);2103 const name = try o.allocTypeName(pt, ty);
2112 defer gpa.free(name);2104 defer gpa.free(name);
2113 const child_ty = ty.optionalChild(zcu);2105 const child_ty = ty.optionalChild(zcu);
2114 if (!child_ty.hasRuntimeBitsIgnoreComptime(zcu)) {2106 if (!child_ty.hasRuntimeBitsIgnoreComptime(zcu)) {
...@@ -2126,7 +2118,7 @@ pub const Object = struct {...@@ -2126,7 +2118,7 @@ pub const Object = struct {
2126 try o.debug_type_map.put(gpa, ty, debug_fwd_ref);2118 try o.debug_type_map.put(gpa, ty, debug_fwd_ref);
21272119
2128 if (ty.optionalReprIsPayload(zcu)) {2120 if (ty.optionalReprIsPayload(zcu)) {
2129 const debug_optional_type = try o.lowerDebugType(child_ty);2121 const debug_optional_type = try o.lowerDebugType(pt, child_ty);
21302122
2131 o.builder.debugForwardReferenceSetType(debug_fwd_ref, debug_optional_type);2123 o.builder.debugForwardReferenceSetType(debug_fwd_ref, debug_optional_type);
21322124
...@@ -2149,7 +2141,7 @@ pub const Object = struct {...@@ -2149,7 +2141,7 @@ pub const Object = struct {
2149 .none, // File2141 .none, // File
2150 debug_fwd_ref,2142 debug_fwd_ref,
2151 0, // Line2143 0, // Line
2152 try o.lowerDebugType(child_ty),2144 try o.lowerDebugType(pt, child_ty),
2153 payload_size * 8,2145 payload_size * 8,
2154 (payload_align.toByteUnits() orelse 0) * 8,2146 (payload_align.toByteUnits() orelse 0) * 8,
2155 0, // Offset2147 0, // Offset
...@@ -2160,7 +2152,7 @@ pub const Object = struct {...@@ -2160,7 +2152,7 @@ pub const Object = struct {
2160 .none,2152 .none,
2161 debug_fwd_ref,2153 debug_fwd_ref,
2162 0,2154 0,
2163 try o.lowerDebugType(non_null_ty),2155 try o.lowerDebugType(pt, non_null_ty),
2164 non_null_size * 8,2156 non_null_size * 8,
2165 (non_null_align.toByteUnits() orelse 0) * 8,2157 (non_null_align.toByteUnits() orelse 0) * 8,
2166 non_null_offset * 8,2158 non_null_offset * 8,
...@@ -2192,12 +2184,12 @@ pub const Object = struct {...@@ -2192,12 +2184,12 @@ pub const Object = struct {
2192 const payload_ty = ty.errorUnionPayload(zcu);2184 const payload_ty = ty.errorUnionPayload(zcu);
2193 if (!payload_ty.hasRuntimeBitsIgnoreComptime(zcu)) {2185 if (!payload_ty.hasRuntimeBitsIgnoreComptime(zcu)) {
2194 // TODO: Maybe remove?2186 // TODO: Maybe remove?
2195 const debug_error_union_type = try o.lowerDebugType(Type.anyerror);2187 const debug_error_union_type = try o.lowerDebugType(pt, Type.anyerror);
2196 try o.debug_type_map.put(gpa, ty, debug_error_union_type);2188 try o.debug_type_map.put(gpa, ty, debug_error_union_type);
2197 return debug_error_union_type;2189 return debug_error_union_type;
2198 }2190 }
21992191
2200 const name = try o.allocTypeName(ty);2192 const name = try o.allocTypeName(pt, ty);
2201 defer gpa.free(name);2193 defer gpa.free(name);
22022194
2203 const error_size = Type.anyerror.abiSize(zcu);2195 const error_size = Type.anyerror.abiSize(zcu);
...@@ -2229,7 +2221,7 @@ pub const Object = struct {...@@ -2229,7 +2221,7 @@ pub const Object = struct {
2229 .none, // File2221 .none, // File
2230 debug_fwd_ref,2222 debug_fwd_ref,
2231 0, // Line2223 0, // Line
2232 try o.lowerDebugType(Type.anyerror),2224 try o.lowerDebugType(pt, Type.anyerror),
2233 error_size * 8,2225 error_size * 8,
2234 (error_align.toByteUnits() orelse 0) * 8,2226 (error_align.toByteUnits() orelse 0) * 8,
2235 error_offset * 8,2227 error_offset * 8,
...@@ -2239,7 +2231,7 @@ pub const Object = struct {...@@ -2239,7 +2231,7 @@ pub const Object = struct {
2239 .none, // File2231 .none, // File
2240 debug_fwd_ref,2232 debug_fwd_ref,
2241 0, // Line2233 0, // Line
2242 try o.lowerDebugType(payload_ty),2234 try o.lowerDebugType(pt, payload_ty),
2243 payload_size * 8,2235 payload_size * 8,
2244 (payload_align.toByteUnits() orelse 0) * 8,2236 (payload_align.toByteUnits() orelse 0) * 8,
2245 payload_offset * 8,2237 payload_offset * 8,
...@@ -2270,7 +2262,7 @@ pub const Object = struct {...@@ -2270,7 +2262,7 @@ pub const Object = struct {
2270 return debug_error_set;2262 return debug_error_set;
2271 },2263 },
2272 .@"struct" => {2264 .@"struct" => {
2273 const name = try o.allocTypeName(ty);2265 const name = try o.allocTypeName(pt, ty);
2274 defer gpa.free(name);2266 defer gpa.free(name);
22752267
2276 if (zcu.typeToPackedStruct(ty)) |struct_type| {2268 if (zcu.typeToPackedStruct(ty)) |struct_type| {
...@@ -2315,7 +2307,7 @@ pub const Object = struct {...@@ -2315,7 +2307,7 @@ pub const Object = struct {
2315 .none, // File2307 .none, // File
2316 debug_fwd_ref,2308 debug_fwd_ref,
2317 0,2309 0,
2318 try o.lowerDebugType(Type.fromInterned(field_ty)),2310 try o.lowerDebugType(pt, Type.fromInterned(field_ty)),
2319 field_size * 8,2311 field_size * 8,
2320 (field_align.toByteUnits() orelse 0) * 8,2312 (field_align.toByteUnits() orelse 0) * 8,
2321 field_offset * 8,2313 field_offset * 8,
...@@ -2347,7 +2339,7 @@ pub const Object = struct {...@@ -2347,7 +2339,7 @@ pub const Object = struct {
2347 // into. Therefore we can satisfy this by making an empty namespace,2339 // into. Therefore we can satisfy this by making an empty namespace,
2348 // rather than changing the frontend to unnecessarily resolve the2340 // rather than changing the frontend to unnecessarily resolve the
2349 // struct field types.2341 // struct field types.
2350 const debug_struct_type = try o.makeEmptyNamespaceDebugType(ty);2342 const debug_struct_type = try o.makeEmptyNamespaceDebugType(pt, ty);
2351 try o.debug_type_map.put(gpa, ty, debug_struct_type);2343 try o.debug_type_map.put(gpa, ty, debug_struct_type);
2352 return debug_struct_type;2344 return debug_struct_type;
2353 }2345 }
...@@ -2356,7 +2348,7 @@ pub const Object = struct {...@@ -2356,7 +2348,7 @@ pub const Object = struct {
2356 }2348 }
23572349
2358 if (!ty.hasRuntimeBitsIgnoreComptime(zcu)) {2350 if (!ty.hasRuntimeBitsIgnoreComptime(zcu)) {
2359 const debug_struct_type = try o.makeEmptyNamespaceDebugType(ty);2351 const debug_struct_type = try o.makeEmptyNamespaceDebugType(pt, ty);
2360 try o.debug_type_map.put(gpa, ty, debug_struct_type);2352 try o.debug_type_map.put(gpa, ty, debug_struct_type);
2361 return debug_struct_type;2353 return debug_struct_type;
2362 }2354 }
...@@ -2388,7 +2380,7 @@ pub const Object = struct {...@@ -2388,7 +2380,7 @@ pub const Object = struct {
2388 .none, // File2380 .none, // File
2389 debug_fwd_ref,2381 debug_fwd_ref,
2390 0, // Line2382 0, // Line
2391 try o.lowerDebugType(field_ty),2383 try o.lowerDebugType(pt, field_ty),
2392 field_size * 8,2384 field_size * 8,
2393 (field_align.toByteUnits() orelse 0) * 8,2385 (field_align.toByteUnits() orelse 0) * 8,
2394 field_offset * 8,2386 field_offset * 8,
...@@ -2415,7 +2407,7 @@ pub const Object = struct {...@@ -2415,7 +2407,7 @@ pub const Object = struct {
2415 return debug_struct_type;2407 return debug_struct_type;
2416 },2408 },
2417 .@"union" => {2409 .@"union" => {
2418 const name = try o.allocTypeName(ty);2410 const name = try o.allocTypeName(pt, ty);
2419 defer gpa.free(name);2411 defer gpa.free(name);
24202412
2421 const union_type = ip.loadUnionType(ty.toIntern());2413 const union_type = ip.loadUnionType(ty.toIntern());
...@@ -2423,7 +2415,7 @@ pub const Object = struct {...@@ -2423,7 +2415,7 @@ pub const Object = struct {
2423 !ty.hasRuntimeBitsIgnoreComptime(zcu) or2415 !ty.hasRuntimeBitsIgnoreComptime(zcu) or
2424 !union_type.haveLayout(ip))2416 !union_type.haveLayout(ip))
2425 {2417 {
2426 const debug_union_type = try o.makeEmptyNamespaceDebugType(ty);2418 const debug_union_type = try o.makeEmptyNamespaceDebugType(pt, ty);
2427 try o.debug_type_map.put(gpa, ty, debug_union_type);2419 try o.debug_type_map.put(gpa, ty, debug_union_type);
2428 return debug_union_type;2420 return debug_union_type;
2429 }2421 }
...@@ -2445,7 +2437,7 @@ pub const Object = struct {...@@ -2445,7 +2437,7 @@ pub const Object = struct {
2445 ty.abiSize(zcu) * 8,2437 ty.abiSize(zcu) * 8,
2446 (ty.abiAlignment(zcu).toByteUnits() orelse 0) * 8,2438 (ty.abiAlignment(zcu).toByteUnits() orelse 0) * 8,
2447 try o.builder.metadataTuple(2439 try o.builder.metadataTuple(
2448 &.{try o.lowerDebugType(Type.fromInterned(union_type.enum_tag_ty))},2440 &.{try o.lowerDebugType(pt, Type.fromInterned(union_type.enum_tag_ty))},
2449 ),2441 ),
2450 );2442 );
24512443
...@@ -2484,7 +2476,7 @@ pub const Object = struct {...@@ -2484,7 +2476,7 @@ pub const Object = struct {
2484 .none, // File2476 .none, // File
2485 debug_union_fwd_ref,2477 debug_union_fwd_ref,
2486 0, // Line2478 0, // Line
2487 try o.lowerDebugType(Type.fromInterned(field_ty)),2479 try o.lowerDebugType(pt, Type.fromInterned(field_ty)),
2488 field_size * 8,2480 field_size * 8,
2489 (field_align.toByteUnits() orelse 0) * 8,2481 (field_align.toByteUnits() orelse 0) * 8,
2490 0, // Offset2482 0, // Offset
...@@ -2534,7 +2526,7 @@ pub const Object = struct {...@@ -2534,7 +2526,7 @@ pub const Object = struct {
2534 .none, // File2526 .none, // File
2535 debug_fwd_ref,2527 debug_fwd_ref,
2536 0, // Line2528 0, // Line
2537 try o.lowerDebugType(Type.fromInterned(union_type.enum_tag_ty)),2529 try o.lowerDebugType(pt, Type.fromInterned(union_type.enum_tag_ty)),
2538 layout.tag_size * 8,2530 layout.tag_size * 8,
2539 (layout.tag_align.toByteUnits() orelse 0) * 8,2531 (layout.tag_align.toByteUnits() orelse 0) * 8,
2540 tag_offset * 8,2532 tag_offset * 8,
...@@ -2588,19 +2580,19 @@ pub const Object = struct {...@@ -2588,19 +2580,19 @@ pub const Object = struct {
2588 if (Type.fromInterned(fn_info.return_type).hasRuntimeBitsIgnoreComptime(zcu)) {2580 if (Type.fromInterned(fn_info.return_type).hasRuntimeBitsIgnoreComptime(zcu)) {
2589 const sret = firstParamSRet(fn_info, zcu, target);2581 const sret = firstParamSRet(fn_info, zcu, target);
2590 const ret_ty = if (sret) Type.void else Type.fromInterned(fn_info.return_type);2582 const ret_ty = if (sret) Type.void else Type.fromInterned(fn_info.return_type);
2591 debug_param_types.appendAssumeCapacity(try o.lowerDebugType(ret_ty));2583 debug_param_types.appendAssumeCapacity(try o.lowerDebugType(pt, ret_ty));
25922584
2593 if (sret) {2585 if (sret) {
2594 const ptr_ty = try pt.singleMutPtrType(Type.fromInterned(fn_info.return_type));2586 const ptr_ty = try pt.singleMutPtrType(Type.fromInterned(fn_info.return_type));
2595 debug_param_types.appendAssumeCapacity(try o.lowerDebugType(ptr_ty));2587 debug_param_types.appendAssumeCapacity(try o.lowerDebugType(pt, ptr_ty));
2596 }2588 }
2597 } else {2589 } else {
2598 debug_param_types.appendAssumeCapacity(try o.lowerDebugType(Type.void));2590 debug_param_types.appendAssumeCapacity(try o.lowerDebugType(pt, Type.void));
2599 }2591 }
26002592
2601 if (fn_info.cc == .auto and zcu.comp.config.any_error_tracing) {2593 if (fn_info.cc == .auto and zcu.comp.config.any_error_tracing) {
2602 const ptr_ty = try pt.singleMutPtrType(try o.getStackTraceType());2594 // Stack trace pointer.
2603 debug_param_types.appendAssumeCapacity(try o.lowerDebugType(ptr_ty));2595 debug_param_types.appendAssumeCapacity(try o.lowerDebugType(pt, .fromInterned(.ptr_usize_type)));
2604 }2596 }
26052597
2606 for (0..fn_info.param_types.len) |i| {2598 for (0..fn_info.param_types.len) |i| {
...@@ -2609,9 +2601,9 @@ pub const Object = struct {...@@ -2609,9 +2601,9 @@ pub const Object = struct {
26092601
2610 if (isByRef(param_ty, zcu)) {2602 if (isByRef(param_ty, zcu)) {
2611 const ptr_ty = try pt.singleMutPtrType(param_ty);2603 const ptr_ty = try pt.singleMutPtrType(param_ty);
2612 debug_param_types.appendAssumeCapacity(try o.lowerDebugType(ptr_ty));2604 debug_param_types.appendAssumeCapacity(try o.lowerDebugType(pt, ptr_ty));
2613 } else {2605 } else {
2614 debug_param_types.appendAssumeCapacity(try o.lowerDebugType(param_ty));2606 debug_param_types.appendAssumeCapacity(try o.lowerDebugType(pt, param_ty));
2615 }2607 }
2616 }2608 }
26172609
...@@ -2634,10 +2626,10 @@ pub const Object = struct {...@@ -2634,10 +2626,10 @@ pub const Object = struct {
2634 }2626 }
2635 }2627 }
26362628
2637 fn namespaceToDebugScope(o: *Object, namespace_index: InternPool.NamespaceIndex) !Builder.Metadata {2629 fn namespaceToDebugScope(o: *Object, pt: Zcu.PerThread, namespace_index: InternPool.NamespaceIndex) !Builder.Metadata {
2638 const zcu = o.pt.zcu;2630 const zcu = pt.zcu;
2639 const namespace = zcu.namespacePtr(namespace_index);2631 const namespace = zcu.namespacePtr(namespace_index);
2640 if (namespace.parent == .none) return try o.getDebugFile(namespace.file_scope);2632 if (namespace.parent == .none) return try o.getDebugFile(pt, namespace.file_scope);
26412633
2642 const gop = try o.debug_unresolved_namespace_scopes.getOrPut(o.gpa, namespace_index);2634 const gop = try o.debug_unresolved_namespace_scopes.getOrPut(o.gpa, namespace_index);
26432635
...@@ -2646,12 +2638,12 @@ pub const Object = struct {...@@ -2646,12 +2638,12 @@ pub const Object = struct {
2646 return gop.value_ptr.*;2638 return gop.value_ptr.*;
2647 }2639 }
26482640
2649 fn makeEmptyNamespaceDebugType(o: *Object, ty: Type) !Builder.Metadata {2641 fn makeEmptyNamespaceDebugType(o: *Object, pt: Zcu.PerThread, ty: Type) !Builder.Metadata {
2650 const zcu = o.pt.zcu;2642 const zcu = pt.zcu;
2651 const ip = &zcu.intern_pool;2643 const ip = &zcu.intern_pool;
2652 const file = try o.getDebugFile(ty.typeDeclInstAllowGeneratedTag(zcu).?.resolveFile(ip));2644 const file = try o.getDebugFile(pt, ty.typeDeclInstAllowGeneratedTag(zcu).?.resolveFile(ip));
2653 const scope = if (ty.getParentNamespace(zcu).unwrap()) |parent_namespace|2645 const scope = if (ty.getParentNamespace(zcu).unwrap()) |parent_namespace|
2654 try o.namespaceToDebugScope(parent_namespace)2646 try o.namespaceToDebugScope(pt, parent_namespace)
2655 else2647 else
2656 file;2648 file;
2657 return o.builder.debugStructType(2649 return o.builder.debugStructType(
...@@ -2666,31 +2658,10 @@ pub const Object = struct {...@@ -2666,31 +2658,10 @@ pub const Object = struct {
2666 );2658 );
2667 }2659 }
26682660
2669 fn getStackTraceType(o: *Object) Allocator.Error!Type {2661 fn allocTypeName(o: *Object, pt: Zcu.PerThread, ty: Type) Allocator.Error![:0]const u8 {
2670 const pt = o.pt;
2671 const zcu = pt.zcu;
2672 const ip = &zcu.intern_pool;
2673
2674 const std_file_index = zcu.module_roots.get(zcu.std_mod).?.unwrap().?;
2675 const builtin_str = try ip.getOrPutString(zcu.gpa, pt.tid, "builtin", .no_embedded_nulls);
2676 const std_file_root_type = Type.fromInterned(zcu.fileRootType(std_file_index));
2677 const std_namespace = ip.namespacePtr(std_file_root_type.getNamespaceIndex(zcu));
2678 const builtin_nav = std_namespace.pub_decls.getKeyAdapted(builtin_str, Zcu.Namespace.NameAdapter{ .zcu = zcu }).?;
2679
2680 const stack_trace_str = try ip.getOrPutString(zcu.gpa, pt.tid, "StackTrace", .no_embedded_nulls);
2681 // buffer is only used for int_type, `builtin` is a struct.
2682 const builtin_ty = zcu.navValue(builtin_nav).toType();
2683 const builtin_namespace = zcu.namespacePtr(builtin_ty.getNamespaceIndex(zcu));
2684 const stack_trace_nav = builtin_namespace.pub_decls.getKeyAdapted(stack_trace_str, Zcu.Namespace.NameAdapter{ .zcu = zcu }).?;
2685
2686 // Sema should have ensured that StackTrace was analyzed.
2687 return zcu.navValue(stack_trace_nav).toType();
2688 }
2689
2690 fn allocTypeName(o: *Object, ty: Type) Allocator.Error![:0]const u8 {
2691 var aw: std.io.Writer.Allocating = .init(o.gpa);2662 var aw: std.io.Writer.Allocating = .init(o.gpa);
2692 defer aw.deinit();2663 defer aw.deinit();
2693 ty.print(&aw.writer, o.pt) catch |err| switch (err) {2664 ty.print(&aw.writer, pt) catch |err| switch (err) {
2694 error.WriteFailed => return error.OutOfMemory,2665 error.WriteFailed => return error.OutOfMemory,
2695 };2666 };
2696 return aw.toOwnedSliceSentinel(0);2667 return aw.toOwnedSliceSentinel(0);
...@@ -2701,9 +2672,9 @@ pub const Object = struct {...@@ -2701,9 +2672,9 @@ pub const Object = struct {
2701 /// completed, so if any attributes rely on that, they must be done in updateFunc, not here.2672 /// completed, so if any attributes rely on that, they must be done in updateFunc, not here.
2702 fn resolveLlvmFunction(2673 fn resolveLlvmFunction(
2703 o: *Object,2674 o: *Object,
2675 pt: Zcu.PerThread,
2704 nav_index: InternPool.Nav.Index,2676 nav_index: InternPool.Nav.Index,
2705 ) Allocator.Error!Builder.Function.Index {2677 ) Allocator.Error!Builder.Function.Index {
2706 const pt = o.pt;
2707 const zcu = pt.zcu;2678 const zcu = pt.zcu;
2708 const ip = &zcu.intern_pool;2679 const ip = &zcu.intern_pool;
2709 const gpa = o.gpa;2680 const gpa = o.gpa;
...@@ -2722,7 +2693,7 @@ pub const Object = struct {...@@ -2722,7 +2693,7 @@ pub const Object = struct {
2722 else2693 else
2723 .{ false, .none };2694 .{ false, .none };
2724 const function_index = try o.builder.addFunction(2695 const function_index = try o.builder.addFunction(
2725 try o.lowerType(ty),2696 try o.lowerType(pt, ty),
2726 try o.builder.strtabString((if (is_extern) nav.name else nav.fqn).toSlice(ip)),2697 try o.builder.strtabString((if (is_extern) nav.name else nav.fqn).toSlice(ip)),
2727 toLlvmAddressSpace(nav.getAddrspace(), target),2698 toLlvmAddressSpace(nav.getAddrspace(), target),
2728 );2699 );
...@@ -2755,7 +2726,7 @@ pub const Object = struct {...@@ -2755,7 +2726,7 @@ pub const Object = struct {
2755 try attributes.addParamAttr(llvm_arg_i, .nonnull, &o.builder);2726 try attributes.addParamAttr(llvm_arg_i, .nonnull, &o.builder);
2756 try attributes.addParamAttr(llvm_arg_i, .@"noalias", &o.builder);2727 try attributes.addParamAttr(llvm_arg_i, .@"noalias", &o.builder);
27572728
2758 const raw_llvm_ret_ty = try o.lowerType(Type.fromInterned(fn_info.return_type));2729 const raw_llvm_ret_ty = try o.lowerType(pt, Type.fromInterned(fn_info.return_type));
2759 try attributes.addParamAttr(llvm_arg_i, .{ .sret = raw_llvm_ret_ty }, &o.builder);2730 try attributes.addParamAttr(llvm_arg_i, .{ .sret = raw_llvm_ret_ty }, &o.builder);
27602731
2761 llvm_arg_i += 1;2732 llvm_arg_i += 1;
...@@ -2862,19 +2833,19 @@ pub const Object = struct {...@@ -2862,19 +2833,19 @@ pub const Object = struct {
2862 // Add parameter attributes. We handle only the case of extern functions (no body)2833 // Add parameter attributes. We handle only the case of extern functions (no body)
2863 // because functions with bodies are handled in `updateFunc`.2834 // because functions with bodies are handled in `updateFunc`.
2864 if (is_extern) {2835 if (is_extern) {
2865 var it = iterateParamTypes(o, fn_info);2836 var it = iterateParamTypes(o, pt, fn_info);
2866 it.llvm_index = llvm_arg_i;2837 it.llvm_index = llvm_arg_i;
2867 while (try it.next()) |lowering| switch (lowering) {2838 while (try it.next()) |lowering| switch (lowering) {
2868 .byval => {2839 .byval => {
2869 const param_index = it.zig_index - 1;2840 const param_index = it.zig_index - 1;
2870 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[param_index]);2841 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[param_index]);
2871 if (!isByRef(param_ty, zcu)) {2842 if (!isByRef(param_ty, zcu)) {
2872 try o.addByValParamAttrs(&attributes, param_ty, param_index, fn_info, it.llvm_index - 1);2843 try o.addByValParamAttrs(pt, &attributes, param_ty, param_index, fn_info, it.llvm_index - 1);
2873 }2844 }
2874 },2845 },
2875 .byref => {2846 .byref => {
2876 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);2847 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);
2877 const param_llvm_ty = try o.lowerType(param_ty);2848 const param_llvm_ty = try o.lowerType(pt, param_ty);
2878 const alignment = param_ty.abiAlignment(zcu);2849 const alignment = param_ty.abiAlignment(zcu);
2879 try o.addByRefParamAttrs(&attributes, it.llvm_index - 1, alignment.toLlvm(), it.byval_attr, param_llvm_ty);2850 try o.addByRefParamAttrs(&attributes, it.llvm_index - 1, alignment.toLlvm(), it.byval_attr, param_llvm_ty);
2880 },2851 },
...@@ -2969,6 +2940,7 @@ pub const Object = struct {...@@ -2969,6 +2940,7 @@ pub const Object = struct {
29692940
2970 fn resolveGlobalUav(2941 fn resolveGlobalUav(
2971 o: *Object,2942 o: *Object,
2943 pt: Zcu.PerThread,
2972 uav: InternPool.Index,2944 uav: InternPool.Index,
2973 llvm_addr_space: Builder.AddrSpace,2945 llvm_addr_space: Builder.AddrSpace,
2974 alignment: InternPool.Alignment,2946 alignment: InternPool.Alignment,
...@@ -2986,17 +2958,17 @@ pub const Object = struct {...@@ -2986,17 +2958,17 @@ pub const Object = struct {
2986 }2958 }
2987 errdefer assert(o.uav_map.remove(uav));2959 errdefer assert(o.uav_map.remove(uav));
29882960
2989 const zcu = o.pt.zcu;2961 const zcu = pt.zcu;
2990 const decl_ty = zcu.intern_pool.typeOf(uav);2962 const decl_ty = zcu.intern_pool.typeOf(uav);
29912963
2992 const variable_index = try o.builder.addVariable(2964 const variable_index = try o.builder.addVariable(
2993 try o.builder.strtabStringFmt("__anon_{d}", .{@intFromEnum(uav)}),2965 try o.builder.strtabStringFmt("__anon_{d}", .{@intFromEnum(uav)}),
2994 try o.lowerType(Type.fromInterned(decl_ty)),2966 try o.lowerType(pt, Type.fromInterned(decl_ty)),
2995 llvm_addr_space,2967 llvm_addr_space,
2996 );2968 );
2997 gop.value_ptr.* = variable_index.ptrConst(&o.builder).global;2969 gop.value_ptr.* = variable_index.ptrConst(&o.builder).global;
29982970
2999 try variable_index.setInitializer(try o.lowerValue(uav), &o.builder);2971 try variable_index.setInitializer(try o.lowerValue(pt, uav), &o.builder);
3000 variable_index.setLinkage(.internal, &o.builder);2972 variable_index.setLinkage(.internal, &o.builder);
3001 variable_index.setMutability(.constant, &o.builder);2973 variable_index.setMutability(.constant, &o.builder);
3002 variable_index.setUnnamedAddr(.unnamed_addr, &o.builder);2974 variable_index.setUnnamedAddr(.unnamed_addr, &o.builder);
...@@ -3006,13 +2978,13 @@ pub const Object = struct {...@@ -3006,13 +2978,13 @@ pub const Object = struct {
30062978
3007 fn resolveGlobalNav(2979 fn resolveGlobalNav(
3008 o: *Object,2980 o: *Object,
2981 pt: Zcu.PerThread,
3009 nav_index: InternPool.Nav.Index,2982 nav_index: InternPool.Nav.Index,
3010 ) Allocator.Error!Builder.Variable.Index {2983 ) Allocator.Error!Builder.Variable.Index {
3011 const gop = try o.nav_map.getOrPut(o.gpa, nav_index);2984 const gop = try o.nav_map.getOrPut(o.gpa, nav_index);
3012 if (gop.found_existing) return gop.value_ptr.ptr(&o.builder).kind.variable;2985 if (gop.found_existing) return gop.value_ptr.ptr(&o.builder).kind.variable;
3013 errdefer assert(o.nav_map.remove(nav_index));2986 errdefer assert(o.nav_map.remove(nav_index));
30142987
3015 const pt = o.pt;
3016 const zcu = pt.zcu;2988 const zcu = pt.zcu;
3017 const ip = &zcu.intern_pool;2989 const ip = &zcu.intern_pool;
3018 const nav = ip.getNav(nav_index);2990 const nav = ip.getNav(nav_index);
...@@ -3033,7 +3005,7 @@ pub const Object = struct {...@@ -3033,7 +3005,7 @@ pub const Object = struct {
3033 .strong, .weak => nav.name,3005 .strong, .weak => nav.name,
3034 .link_once => unreachable,3006 .link_once => unreachable,
3035 }.toSlice(ip)),3007 }.toSlice(ip)),
3036 try o.lowerType(Type.fromInterned(nav.typeOf(ip))),3008 try o.lowerType(pt, Type.fromInterned(nav.typeOf(ip))),
3037 toLlvmGlobalAddressSpace(nav.getAddrspace(), zcu.getTarget()),3009 toLlvmGlobalAddressSpace(nav.getAddrspace(), zcu.getTarget()),
3038 );3010 );
3039 gop.value_ptr.* = variable_index.ptrConst(&o.builder).global;3011 gop.value_ptr.* = variable_index.ptrConst(&o.builder).global;
...@@ -3062,12 +3034,11 @@ pub const Object = struct {...@@ -3062,12 +3034,11 @@ pub const Object = struct {
3062 return variable_index;3034 return variable_index;
3063 }3035 }
30643036
3065 fn errorIntType(o: *Object) Allocator.Error!Builder.Type {3037 fn errorIntType(o: *Object, pt: Zcu.PerThread) Allocator.Error!Builder.Type {
3066 return o.builder.intType(o.pt.zcu.errorSetBits());3038 return o.builder.intType(pt.zcu.errorSetBits());
3067 }3039 }
30683040
3069 fn lowerType(o: *Object, t: Type) Allocator.Error!Builder.Type {3041 fn lowerType(o: *Object, pt: Zcu.PerThread, t: Type) Allocator.Error!Builder.Type {
3070 const pt = o.pt;
3071 const zcu = pt.zcu;3042 const zcu = pt.zcu;
3072 const target = zcu.getTarget();3043 const target = zcu.getTarget();
3073 const ip = &zcu.intern_pool;3044 const ip = &zcu.intern_pool;
...@@ -3123,7 +3094,7 @@ pub const Object = struct {...@@ -3123,7 +3094,7 @@ pub const Object = struct {
3123 .bool_type => .i1,3094 .bool_type => .i1,
3124 .void_type => .void,3095 .void_type => .void,
3125 .type_type => unreachable,3096 .type_type => unreachable,
3126 .anyerror_type => try o.errorIntType(),3097 .anyerror_type => try o.errorIntType(pt),
3127 .comptime_int_type,3098 .comptime_int_type,
3128 .comptime_float_type,3099 .comptime_float_type,
3129 .noreturn_type,3100 .noreturn_type,
...@@ -3141,11 +3112,11 @@ pub const Object = struct {...@@ -3141,11 +3112,11 @@ pub const Object = struct {
3141 => .ptr,3112 => .ptr,
3142 .slice_const_u8_type,3113 .slice_const_u8_type,
3143 .slice_const_u8_sentinel_0_type,3114 .slice_const_u8_sentinel_0_type,
3144 => try o.builder.structType(.normal, &.{ .ptr, try o.lowerType(Type.usize) }),3115 => try o.builder.structType(.normal, &.{ .ptr, try o.lowerType(pt, Type.usize) }),
3145 .optional_noreturn_type => unreachable,3116 .optional_noreturn_type => unreachable,
3146 .anyerror_void_error_union_type,3117 .anyerror_void_error_union_type,
3147 .adhoc_inferred_error_set_type,3118 .adhoc_inferred_error_set_type,
3148 => try o.errorIntType(),3119 => try o.errorIntType(pt),
3149 .generic_poison_type,3120 .generic_poison_type,
3150 .empty_tuple_type,3121 .empty_tuple_type,
3151 => unreachable,3122 => unreachable,
...@@ -3182,24 +3153,24 @@ pub const Object = struct {...@@ -3182,24 +3153,24 @@ pub const Object = struct {
3182 .one, .many, .c => ptr_ty,3153 .one, .many, .c => ptr_ty,
3183 .slice => try o.builder.structType(.normal, &.{3154 .slice => try o.builder.structType(.normal, &.{
3184 ptr_ty,3155 ptr_ty,
3185 try o.lowerType(Type.usize),3156 try o.lowerType(pt, Type.usize),
3186 }),3157 }),
3187 };3158 };
3188 },3159 },
3189 .array_type => |array_type| o.builder.arrayType(3160 .array_type => |array_type| o.builder.arrayType(
3190 array_type.lenIncludingSentinel(),3161 array_type.lenIncludingSentinel(),
3191 try o.lowerType(Type.fromInterned(array_type.child)),3162 try o.lowerType(pt, Type.fromInterned(array_type.child)),
3192 ),3163 ),
3193 .vector_type => |vector_type| o.builder.vectorType(3164 .vector_type => |vector_type| o.builder.vectorType(
3194 .normal,3165 .normal,
3195 vector_type.len,3166 vector_type.len,
3196 try o.lowerType(Type.fromInterned(vector_type.child)),3167 try o.lowerType(pt, Type.fromInterned(vector_type.child)),
3197 ),3168 ),
3198 .opt_type => |child_ty| {3169 .opt_type => |child_ty| {
3199 // Must stay in sync with `opt_payload` logic in `lowerPtr`.3170 // Must stay in sync with `opt_payload` logic in `lowerPtr`.
3200 if (!Type.fromInterned(child_ty).hasRuntimeBitsIgnoreComptime(zcu)) return .i8;3171 if (!Type.fromInterned(child_ty).hasRuntimeBitsIgnoreComptime(zcu)) return .i8;
32013172
3202 const payload_ty = try o.lowerType(Type.fromInterned(child_ty));3173 const payload_ty = try o.lowerType(pt, Type.fromInterned(child_ty));
3203 if (t.optionalReprIsPayload(zcu)) return payload_ty;3174 if (t.optionalReprIsPayload(zcu)) return payload_ty;
32043175
3205 comptime assert(optional_layout_version == 3);3176 comptime assert(optional_layout_version == 3);
...@@ -3218,17 +3189,16 @@ pub const Object = struct {...@@ -3218,17 +3189,16 @@ pub const Object = struct {
3218 .error_union_type => |error_union_type| {3189 .error_union_type => |error_union_type| {
3219 // Must stay in sync with `codegen.errUnionPayloadOffset`.3190 // Must stay in sync with `codegen.errUnionPayloadOffset`.
3220 // See logic in `lowerPtr`.3191 // See logic in `lowerPtr`.
3221 const error_type = try o.errorIntType();3192 const error_type = try o.errorIntType(pt);
3222 if (!Type.fromInterned(error_union_type.payload_type).hasRuntimeBitsIgnoreComptime(zcu))3193 if (!Type.fromInterned(error_union_type.payload_type).hasRuntimeBitsIgnoreComptime(zcu))
3223 return error_type;3194 return error_type;
3224 const payload_type = try o.lowerType(Type.fromInterned(error_union_type.payload_type));3195 const payload_type = try o.lowerType(pt, Type.fromInterned(error_union_type.payload_type));
3225 const err_int_ty = try o.pt.errorIntType();
32263196
3227 const payload_align = Type.fromInterned(error_union_type.payload_type).abiAlignment(zcu);3197 const payload_align = Type.fromInterned(error_union_type.payload_type).abiAlignment(zcu);
3228 const error_align = err_int_ty.abiAlignment(zcu);3198 const error_align: InternPool.Alignment = .fromByteUnits(std.zig.target.intAlignment(target, zcu.errorSetBits()));
32293199
3230 const payload_size = Type.fromInterned(error_union_type.payload_type).abiSize(zcu);3200 const payload_size = Type.fromInterned(error_union_type.payload_type).abiSize(zcu);
3231 const error_size = err_int_ty.abiSize(zcu);3201 const error_size = std.zig.target.intByteSize(target, zcu.errorSetBits());
32323202
3233 var fields: [3]Builder.Type = undefined;3203 var fields: [3]Builder.Type = undefined;
3234 var fields_len: usize = 2;3204 var fields_len: usize = 2;
...@@ -3262,7 +3232,7 @@ pub const Object = struct {...@@ -3262,7 +3232,7 @@ pub const Object = struct {
3262 const struct_type = ip.loadStructType(t.toIntern());3232 const struct_type = ip.loadStructType(t.toIntern());
32633233
3264 if (struct_type.layout == .@"packed") {3234 if (struct_type.layout == .@"packed") {
3265 const int_ty = try o.lowerType(Type.fromInterned(struct_type.backingIntTypeUnordered(ip)));3235 const int_ty = try o.lowerType(pt, Type.fromInterned(struct_type.backingIntTypeUnordered(ip)));
3266 try o.type_map.put(o.gpa, t.toIntern(), int_ty);3236 try o.type_map.put(o.gpa, t.toIntern(), int_ty);
3267 return int_ty;3237 return int_ty;
3268 }3238 }
...@@ -3312,7 +3282,7 @@ pub const Object = struct {...@@ -3312,7 +3282,7 @@ pub const Object = struct {
3312 .struct_ty = t.toIntern(),3282 .struct_ty = t.toIntern(),
3313 .field_index = field_index,3283 .field_index = field_index,
3314 }, @intCast(llvm_field_types.items.len));3284 }, @intCast(llvm_field_types.items.len));
3315 try llvm_field_types.append(o.gpa, try o.lowerType(field_ty));3285 try llvm_field_types.append(o.gpa, try o.lowerType(pt, field_ty));
33163286
3317 offset += field_ty.abiSize(zcu);3287 offset += field_ty.abiSize(zcu);
3318 }3288 }
...@@ -3382,7 +3352,7 @@ pub const Object = struct {...@@ -3382,7 +3352,7 @@ pub const Object = struct {
3382 .struct_ty = t.toIntern(),3352 .struct_ty = t.toIntern(),
3383 .field_index = @intCast(field_index),3353 .field_index = @intCast(field_index),
3384 }, @intCast(llvm_field_types.items.len));3354 }, @intCast(llvm_field_types.items.len));
3385 try llvm_field_types.append(o.gpa, try o.lowerType(Type.fromInterned(field_ty)));3355 try llvm_field_types.append(o.gpa, try o.lowerType(pt, Type.fromInterned(field_ty)));
33863356
3387 offset += Type.fromInterned(field_ty).abiSize(zcu);3357 offset += Type.fromInterned(field_ty).abiSize(zcu);
3388 }3358 }
...@@ -3410,13 +3380,13 @@ pub const Object = struct {...@@ -3410,13 +3380,13 @@ pub const Object = struct {
3410 }3380 }
34113381
3412 if (layout.payload_size == 0) {3382 if (layout.payload_size == 0) {
3413 const enum_tag_ty = try o.lowerType(Type.fromInterned(union_obj.enum_tag_ty));3383 const enum_tag_ty = try o.lowerType(pt, Type.fromInterned(union_obj.enum_tag_ty));
3414 try o.type_map.put(o.gpa, t.toIntern(), enum_tag_ty);3384 try o.type_map.put(o.gpa, t.toIntern(), enum_tag_ty);
3415 return enum_tag_ty;3385 return enum_tag_ty;
3416 }3386 }
34173387
3418 const aligned_field_ty = Type.fromInterned(union_obj.field_types.get(ip)[layout.most_aligned_field]);3388 const aligned_field_ty = Type.fromInterned(union_obj.field_types.get(ip)[layout.most_aligned_field]);
3419 const aligned_field_llvm_ty = try o.lowerType(aligned_field_ty);3389 const aligned_field_llvm_ty = try o.lowerType(pt, aligned_field_ty);
34203390
3421 const payload_ty = ty: {3391 const payload_ty = ty: {
3422 if (layout.most_aligned_field_size == layout.payload_size) {3392 if (layout.most_aligned_field_size == layout.payload_size) {
...@@ -3442,7 +3412,7 @@ pub const Object = struct {...@@ -3442,7 +3412,7 @@ pub const Object = struct {
3442 );3412 );
3443 return ty;3413 return ty;
3444 }3414 }
3445 const enum_tag_ty = try o.lowerType(Type.fromInterned(union_obj.enum_tag_ty));3415 const enum_tag_ty = try o.lowerType(pt, Type.fromInterned(union_obj.enum_tag_ty));
34463416
3447 // Put the tag before or after the payload depending on which one's3417 // Put the tag before or after the payload depending on which one's
3448 // alignment is greater.3418 // alignment is greater.
...@@ -3477,9 +3447,9 @@ pub const Object = struct {...@@ -3477,9 +3447,9 @@ pub const Object = struct {
3477 }3447 }
3478 return gop.value_ptr.*;3448 return gop.value_ptr.*;
3479 },3449 },
3480 .enum_type => try o.lowerType(Type.fromInterned(ip.loadEnumType(t.toIntern()).tag_ty)),3450 .enum_type => try o.lowerType(pt, Type.fromInterned(ip.loadEnumType(t.toIntern()).tag_ty)),
3481 .func_type => |func_type| try o.lowerTypeFn(func_type),3451 .func_type => |func_type| try o.lowerTypeFn(pt, func_type),
3482 .error_set_type, .inferred_error_set_type => try o.errorIntType(),3452 .error_set_type, .inferred_error_set_type => try o.errorIntType(pt),
3483 // values, not types3453 // values, not types
3484 .undef,3454 .undef,
3485 .simple_value,3455 .simple_value,
...@@ -3508,8 +3478,7 @@ pub const Object = struct {...@@ -3508,8 +3478,7 @@ pub const Object = struct {
3508 /// Use this instead of lowerType when you want to handle correctly the case of elem_ty3478 /// Use this instead of lowerType when you want to handle correctly the case of elem_ty
3509 /// being a zero bit type, but it should still be lowered as an i8 in such case.3479 /// being a zero bit type, but it should still be lowered as an i8 in such case.
3510 /// There are other similar cases handled here as well.3480 /// There are other similar cases handled here as well.
3511 fn lowerPtrElemTy(o: *Object, elem_ty: Type) Allocator.Error!Builder.Type {3481 fn lowerPtrElemTy(o: *Object, pt: Zcu.PerThread, elem_ty: Type) Allocator.Error!Builder.Type {
3512 const pt = o.pt;
3513 const zcu = pt.zcu;3482 const zcu = pt.zcu;
3514 const lower_elem_ty = switch (elem_ty.zigTypeTag(zcu)) {3483 const lower_elem_ty = switch (elem_ty.zigTypeTag(zcu)) {
3515 .@"opaque" => true,3484 .@"opaque" => true,
...@@ -3517,15 +3486,14 @@ pub const Object = struct {...@@ -3517,15 +3486,14 @@ pub const Object = struct {
3517 .array => elem_ty.childType(zcu).hasRuntimeBitsIgnoreComptime(zcu),3486 .array => elem_ty.childType(zcu).hasRuntimeBitsIgnoreComptime(zcu),
3518 else => elem_ty.hasRuntimeBitsIgnoreComptime(zcu),3487 else => elem_ty.hasRuntimeBitsIgnoreComptime(zcu),
3519 };3488 };
3520 return if (lower_elem_ty) try o.lowerType(elem_ty) else .i8;3489 return if (lower_elem_ty) try o.lowerType(pt, elem_ty) else .i8;
3521 }3490 }
35223491
3523 fn lowerTypeFn(o: *Object, fn_info: InternPool.Key.FuncType) Allocator.Error!Builder.Type {3492 fn lowerTypeFn(o: *Object, pt: Zcu.PerThread, fn_info: InternPool.Key.FuncType) Allocator.Error!Builder.Type {
3524 const pt = o.pt;
3525 const zcu = pt.zcu;3493 const zcu = pt.zcu;
3526 const ip = &zcu.intern_pool;3494 const ip = &zcu.intern_pool;
3527 const target = zcu.getTarget();3495 const target = zcu.getTarget();
3528 const ret_ty = try lowerFnRetTy(o, fn_info);3496 const ret_ty = try lowerFnRetTy(o, pt, fn_info);
35293497
3530 var llvm_params: std.ArrayListUnmanaged(Builder.Type) = .empty;3498 var llvm_params: std.ArrayListUnmanaged(Builder.Type) = .empty;
3531 defer llvm_params.deinit(o.gpa);3499 defer llvm_params.deinit(o.gpa);
...@@ -3535,16 +3503,17 @@ pub const Object = struct {...@@ -3535,16 +3503,17 @@ pub const Object = struct {
3535 }3503 }
35363504
3537 if (fn_info.cc == .auto and zcu.comp.config.any_error_tracing) {3505 if (fn_info.cc == .auto and zcu.comp.config.any_error_tracing) {
3538 const ptr_ty = try pt.singleMutPtrType(try o.getStackTraceType());3506 const stack_trace_ty = zcu.builtin_decl_values.get(.StackTrace);
3539 try llvm_params.append(o.gpa, try o.lowerType(ptr_ty));3507 const ptr_ty = try pt.ptrType(.{ .child = stack_trace_ty });
3508 try llvm_params.append(o.gpa, try o.lowerType(pt, ptr_ty));
3540 }3509 }
35413510
3542 var it = iterateParamTypes(o, fn_info);3511 var it = iterateParamTypes(o, pt, fn_info);
3543 while (try it.next()) |lowering| switch (lowering) {3512 while (try it.next()) |lowering| switch (lowering) {
3544 .no_bits => continue,3513 .no_bits => continue,
3545 .byval => {3514 .byval => {
3546 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);3515 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);
3547 try llvm_params.append(o.gpa, try o.lowerType(param_ty));3516 try llvm_params.append(o.gpa, try o.lowerType(pt, param_ty));
3548 },3517 },
3549 .byref, .byref_mut => {3518 .byref, .byref_mut => {
3550 try llvm_params.append(o.gpa, .ptr);3519 try llvm_params.append(o.gpa, .ptr);
...@@ -3559,7 +3528,7 @@ pub const Object = struct {...@@ -3559,7 +3528,7 @@ pub const Object = struct {
3559 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);3528 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);
3560 try llvm_params.appendSlice(o.gpa, &.{3529 try llvm_params.appendSlice(o.gpa, &.{
3561 try o.builder.ptrType(toLlvmAddressSpace(param_ty.ptrAddressSpace(zcu), target)),3530 try o.builder.ptrType(toLlvmAddressSpace(param_ty.ptrAddressSpace(zcu), target)),
3562 try o.lowerType(Type.usize),3531 try o.lowerType(pt, Type.usize),
3563 });3532 });
3564 },3533 },
3565 .multiple_llvm_types => {3534 .multiple_llvm_types => {
...@@ -3567,7 +3536,7 @@ pub const Object = struct {...@@ -3567,7 +3536,7 @@ pub const Object = struct {
3567 },3536 },
3568 .float_array => |count| {3537 .float_array => |count| {
3569 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);3538 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[it.zig_index - 1]);
3570 const float_ty = try o.lowerType(aarch64_c_abi.getFloatArrayType(param_ty, zcu).?);3539 const float_ty = try o.lowerType(pt, aarch64_c_abi.getFloatArrayType(param_ty, zcu).?);
3571 try llvm_params.append(o.gpa, try o.builder.arrayType(count, float_ty));3540 try llvm_params.append(o.gpa, try o.builder.arrayType(count, float_ty));
3572 },3541 },
3573 .i32_array, .i64_array => |arr_len| {3542 .i32_array, .i64_array => |arr_len| {
...@@ -3586,8 +3555,7 @@ pub const Object = struct {...@@ -3586,8 +3555,7 @@ pub const Object = struct {
3586 );3555 );
3587 }3556 }
35883557
3589 fn lowerValueToInt(o: *Object, llvm_int_ty: Builder.Type, arg_val: InternPool.Index) Error!Builder.Constant {3558 fn lowerValueToInt(o: *Object, pt: Zcu.PerThread, llvm_int_ty: Builder.Type, arg_val: InternPool.Index) Error!Builder.Constant {
3590 const pt = o.pt;
3591 const zcu = pt.zcu;3559 const zcu = pt.zcu;
3592 const ip = &zcu.intern_pool;3560 const ip = &zcu.intern_pool;
3593 const target = zcu.getTarget();3561 const target = zcu.getTarget();
...@@ -3600,23 +3568,23 @@ pub const Object = struct {...@@ -3600,23 +3568,23 @@ pub const Object = struct {
3600 const ty = Type.fromInterned(val_key.typeOf());3568 const ty = Type.fromInterned(val_key.typeOf());
3601 switch (val_key) {3569 switch (val_key) {
3602 .@"extern" => |@"extern"| {3570 .@"extern" => |@"extern"| {
3603 const function_index = try o.resolveLlvmFunction(@"extern".owner_nav);3571 const function_index = try o.resolveLlvmFunction(pt, @"extern".owner_nav);
3604 const ptr = function_index.ptrConst(&o.builder).global.toConst();3572 const ptr = function_index.ptrConst(&o.builder).global.toConst();
3605 return o.builder.convConst(ptr, llvm_int_ty);3573 return o.builder.convConst(ptr, llvm_int_ty);
3606 },3574 },
3607 .func => |func| {3575 .func => |func| {
3608 const function_index = try o.resolveLlvmFunction(func.owner_nav);3576 const function_index = try o.resolveLlvmFunction(pt, func.owner_nav);
3609 const ptr = function_index.ptrConst(&o.builder).global.toConst();3577 const ptr = function_index.ptrConst(&o.builder).global.toConst();
3610 return o.builder.convConst(ptr, llvm_int_ty);3578 return o.builder.convConst(ptr, llvm_int_ty);
3611 },3579 },
3612 .ptr => return o.builder.convConst(try o.lowerPtr(arg_val, 0), llvm_int_ty),3580 .ptr => return o.builder.convConst(try o.lowerPtr(pt, arg_val, 0), llvm_int_ty),
3613 .aggregate => switch (ip.indexToKey(ty.toIntern())) {3581 .aggregate => switch (ip.indexToKey(ty.toIntern())) {
3614 .struct_type, .vector_type => {},3582 .struct_type, .vector_type => {},
3615 else => unreachable,3583 else => unreachable,
3616 },3584 },
3617 .un => |un| {3585 .un => |un| {
3618 const layout = ty.unionGetLayout(zcu);3586 const layout = ty.unionGetLayout(zcu);
3619 if (layout.payload_size == 0) return o.lowerValue(un.tag);3587 if (layout.payload_size == 0) return o.lowerValue(pt, un.tag);
36203588
3621 const union_obj = zcu.typeToUnion(ty).?;3589 const union_obj = zcu.typeToUnion(ty).?;
3622 const container_layout = union_obj.flagsUnordered(ip).layout;3590 const container_layout = union_obj.flagsUnordered(ip).layout;
...@@ -3626,7 +3594,7 @@ pub const Object = struct {...@@ -3626,7 +3594,7 @@ pub const Object = struct {
3626 var need_unnamed = false;3594 var need_unnamed = false;
3627 if (un.tag == .none) {3595 if (un.tag == .none) {
3628 assert(layout.tag_size == 0);3596 assert(layout.tag_size == 0);
3629 const union_val = try o.lowerValueToInt(llvm_int_ty, un.val);3597 const union_val = try o.lowerValueToInt(pt, llvm_int_ty, un.val);
36303598
3631 need_unnamed = true;3599 need_unnamed = true;
3632 return union_val;3600 return union_val;
...@@ -3634,7 +3602,7 @@ pub const Object = struct {...@@ -3634,7 +3602,7 @@ pub const Object = struct {
3634 const field_index = zcu.unionTagFieldIndex(union_obj, Value.fromInterned(un.tag)).?;3602 const field_index = zcu.unionTagFieldIndex(union_obj, Value.fromInterned(un.tag)).?;
3635 const field_ty = Type.fromInterned(union_obj.field_types.get(ip)[field_index]);3603 const field_ty = Type.fromInterned(union_obj.field_types.get(ip)[field_index]);
3636 if (!field_ty.hasRuntimeBits(zcu)) return o.builder.intConst(llvm_int_ty, 0);3604 if (!field_ty.hasRuntimeBits(zcu)) return o.builder.intConst(llvm_int_ty, 0);
3637 return o.lowerValueToInt(llvm_int_ty, un.val);3605 return o.lowerValueToInt(pt, llvm_int_ty, un.val);
3638 },3606 },
3639 .simple_value => |simple_value| switch (simple_value) {3607 .simple_value => |simple_value| switch (simple_value) {
3640 .false, .true => {},3608 .false, .true => {},
...@@ -3678,8 +3646,7 @@ pub const Object = struct {...@@ -3678,8 +3646,7 @@ pub const Object = struct {
3678 });3646 });
3679 }3647 }
36803648
3681 fn lowerValue(o: *Object, arg_val: InternPool.Index) Error!Builder.Constant {3649 fn lowerValue(o: *Object, pt: Zcu.PerThread, arg_val: InternPool.Index) Error!Builder.Constant {
3682 const pt = o.pt;
3683 const zcu = pt.zcu;3650 const zcu = pt.zcu;
3684 const ip = &zcu.intern_pool;3651 const ip = &zcu.intern_pool;
3685 const target = zcu.getTarget();3652 const target = zcu.getTarget();
...@@ -3688,7 +3655,7 @@ pub const Object = struct {...@@ -3688,7 +3655,7 @@ pub const Object = struct {
3688 const val_key = ip.indexToKey(val.toIntern());3655 const val_key = ip.indexToKey(val.toIntern());
36893656
3690 if (val.isUndefDeep(zcu)) {3657 if (val.isUndefDeep(zcu)) {
3691 return o.builder.undefConst(try o.lowerType(Type.fromInterned(val_key.typeOf())));3658 return o.builder.undefConst(try o.lowerType(pt, Type.fromInterned(val_key.typeOf())));
3692 }3659 }
36933660
3694 const ty = Type.fromInterned(val_key.typeOf());3661 const ty = Type.fromInterned(val_key.typeOf());
...@@ -3727,21 +3694,21 @@ pub const Object = struct {...@@ -3727,21 +3694,21 @@ pub const Object = struct {
3727 .empty_enum_value,3694 .empty_enum_value,
3728 => unreachable, // non-runtime values3695 => unreachable, // non-runtime values
3729 .@"extern" => |@"extern"| {3696 .@"extern" => |@"extern"| {
3730 const function_index = try o.resolveLlvmFunction(@"extern".owner_nav);3697 const function_index = try o.resolveLlvmFunction(pt, @"extern".owner_nav);
3731 return function_index.ptrConst(&o.builder).global.toConst();3698 return function_index.ptrConst(&o.builder).global.toConst();
3732 },3699 },
3733 .func => |func| {3700 .func => |func| {
3734 const function_index = try o.resolveLlvmFunction(func.owner_nav);3701 const function_index = try o.resolveLlvmFunction(pt, func.owner_nav);
3735 return function_index.ptrConst(&o.builder).global.toConst();3702 return function_index.ptrConst(&o.builder).global.toConst();
3736 },3703 },
3737 .int => {3704 .int => {
3738 var bigint_space: Value.BigIntSpace = undefined;3705 var bigint_space: Value.BigIntSpace = undefined;
3739 const bigint = val.toBigInt(&bigint_space, zcu);3706 const bigint = val.toBigInt(&bigint_space, zcu);
3740 return lowerBigInt(o, ty, bigint);3707 return lowerBigInt(o, pt, ty, bigint);
3741 },3708 },
3742 .err => |err| {3709 .err => |err| {
3743 const int = try pt.getErrorValue(err.name);3710 const int = try pt.getErrorValue(err.name);
3744 const llvm_int = try o.builder.intConst(try o.errorIntType(), int);3711 const llvm_int = try o.builder.intConst(try o.errorIntType(pt), int);
3745 return llvm_int;3712 return llvm_int;
3746 },3713 },
3747 .error_union => |error_union| {3714 .error_union => |error_union| {
...@@ -3756,13 +3723,13 @@ pub const Object = struct {...@@ -3756,13 +3723,13 @@ pub const Object = struct {
3756 const payload_type = ty.errorUnionPayload(zcu);3723 const payload_type = ty.errorUnionPayload(zcu);
3757 if (!payload_type.hasRuntimeBitsIgnoreComptime(zcu)) {3724 if (!payload_type.hasRuntimeBitsIgnoreComptime(zcu)) {
3758 // We use the error type directly as the type.3725 // We use the error type directly as the type.
3759 return o.lowerValue(err_val);3726 return o.lowerValue(pt, err_val);
3760 }3727 }
37613728
3762 const payload_align = payload_type.abiAlignment(zcu);3729 const payload_align = payload_type.abiAlignment(zcu);
3763 const error_align = err_int_ty.abiAlignment(zcu);3730 const error_align = err_int_ty.abiAlignment(zcu);
3764 const llvm_error_value = try o.lowerValue(err_val);3731 const llvm_error_value = try o.lowerValue(pt, err_val);
3765 const llvm_payload_value = try o.lowerValue(switch (error_union.val) {3732 const llvm_payload_value = try o.lowerValue(pt, switch (error_union.val) {
3766 .err_name => try pt.intern(.{ .undef = payload_type.toIntern() }),3733 .err_name => try pt.intern(.{ .undef = payload_type.toIntern() }),
3767 .payload => |payload| payload,3734 .payload => |payload| payload,
3768 });3735 });
...@@ -3779,7 +3746,7 @@ pub const Object = struct {...@@ -3779,7 +3746,7 @@ pub const Object = struct {
3779 fields[0] = vals[0].typeOf(&o.builder);3746 fields[0] = vals[0].typeOf(&o.builder);
3780 fields[1] = vals[1].typeOf(&o.builder);3747 fields[1] = vals[1].typeOf(&o.builder);
37813748
3782 const llvm_ty = try o.lowerType(ty);3749 const llvm_ty = try o.lowerType(pt, ty);
3783 const llvm_ty_fields = llvm_ty.structFields(&o.builder);3750 const llvm_ty_fields = llvm_ty.structFields(&o.builder);
3784 if (llvm_ty_fields.len > 2) {3751 if (llvm_ty_fields.len > 2) {
3785 assert(llvm_ty_fields.len == 3);3752 assert(llvm_ty_fields.len == 3);
...@@ -3791,7 +3758,7 @@ pub const Object = struct {...@@ -3791,7 +3758,7 @@ pub const Object = struct {
3791 fields[0..llvm_ty_fields.len],3758 fields[0..llvm_ty_fields.len],
3792 ), vals[0..llvm_ty_fields.len]);3759 ), vals[0..llvm_ty_fields.len]);
3793 },3760 },
3794 .enum_tag => |enum_tag| o.lowerValue(enum_tag.int),3761 .enum_tag => |enum_tag| o.lowerValue(pt, enum_tag.int),
3795 .float => switch (ty.floatBits(target)) {3762 .float => switch (ty.floatBits(target)) {
3796 16 => if (backendSupportsF16(target))3763 16 => if (backendSupportsF16(target))
3797 try o.builder.halfConst(val.toFloat(f16, zcu))3764 try o.builder.halfConst(val.toFloat(f16, zcu))
...@@ -3806,10 +3773,10 @@ pub const Object = struct {...@@ -3806,10 +3773,10 @@ pub const Object = struct {
3806 128 => try o.builder.fp128Const(val.toFloat(f128, zcu)),3773 128 => try o.builder.fp128Const(val.toFloat(f128, zcu)),
3807 else => unreachable,3774 else => unreachable,
3808 },3775 },
3809 .ptr => try o.lowerPtr(arg_val, 0),3776 .ptr => try o.lowerPtr(pt, arg_val, 0),
3810 .slice => |slice| return o.builder.structConst(try o.lowerType(ty), &.{3777 .slice => |slice| return o.builder.structConst(try o.lowerType(pt, ty), &.{
3811 try o.lowerValue(slice.ptr),3778 try o.lowerValue(pt, slice.ptr),
3812 try o.lowerValue(slice.len),3779 try o.lowerValue(pt, slice.len),
3813 }),3780 }),
3814 .opt => |opt| {3781 .opt => |opt| {
3815 comptime assert(optional_layout_version == 3);3782 comptime assert(optional_layout_version == 3);
...@@ -3819,7 +3786,7 @@ pub const Object = struct {...@@ -3819,7 +3786,7 @@ pub const Object = struct {
3819 if (!payload_ty.hasRuntimeBitsIgnoreComptime(zcu)) {3786 if (!payload_ty.hasRuntimeBitsIgnoreComptime(zcu)) {
3820 return non_null_bit;3787 return non_null_bit;
3821 }3788 }
3822 const llvm_ty = try o.lowerType(ty);3789 const llvm_ty = try o.lowerType(pt, ty);
3823 if (ty.optionalReprIsPayload(zcu)) return switch (opt.val) {3790 if (ty.optionalReprIsPayload(zcu)) return switch (opt.val) {
3824 .none => switch (llvm_ty.tag(&o.builder)) {3791 .none => switch (llvm_ty.tag(&o.builder)) {
3825 .integer => try o.builder.intConst(llvm_ty, 0),3792 .integer => try o.builder.intConst(llvm_ty, 0),
...@@ -3827,13 +3794,13 @@ pub const Object = struct {...@@ -3827,13 +3794,13 @@ pub const Object = struct {
3827 .structure => try o.builder.zeroInitConst(llvm_ty),3794 .structure => try o.builder.zeroInitConst(llvm_ty),
3828 else => unreachable,3795 else => unreachable,
3829 },3796 },
3830 else => |payload| try o.lowerValue(payload),3797 else => |payload| try o.lowerValue(pt, payload),
3831 };3798 };
3832 assert(payload_ty.zigTypeTag(zcu) != .@"fn");3799 assert(payload_ty.zigTypeTag(zcu) != .@"fn");
38333800
3834 var fields: [3]Builder.Type = undefined;3801 var fields: [3]Builder.Type = undefined;
3835 var vals: [3]Builder.Constant = undefined;3802 var vals: [3]Builder.Constant = undefined;
3836 vals[0] = try o.lowerValue(switch (opt.val) {3803 vals[0] = try o.lowerValue(pt, switch (opt.val) {
3837 .none => try pt.intern(.{ .undef = payload_ty.toIntern() }),3804 .none => try pt.intern(.{ .undef = payload_ty.toIntern() }),
3838 else => |payload| payload,3805 else => |payload| payload,
3839 });3806 });
...@@ -3858,7 +3825,7 @@ pub const Object = struct {...@@ -3858,7 +3825,7 @@ pub const Object = struct {
3858 bytes.toSlice(array_type.lenIncludingSentinel(), ip),3825 bytes.toSlice(array_type.lenIncludingSentinel(), ip),
3859 )),3826 )),
3860 .elems => |elems| {3827 .elems => |elems| {
3861 const array_ty = try o.lowerType(ty);3828 const array_ty = try o.lowerType(pt, ty);
3862 const elem_ty = array_ty.childType(&o.builder);3829 const elem_ty = array_ty.childType(&o.builder);
3863 assert(elems.len == array_ty.aggregateLen(&o.builder));3830 assert(elems.len == array_ty.aggregateLen(&o.builder));
38643831
...@@ -3878,7 +3845,7 @@ pub const Object = struct {...@@ -3878,7 +3845,7 @@ pub const Object = struct {
38783845
3879 var need_unnamed = false;3846 var need_unnamed = false;
3880 for (vals, fields, elems) |*result_val, *result_field, elem| {3847 for (vals, fields, elems) |*result_val, *result_field, elem| {
3881 result_val.* = try o.lowerValue(elem);3848 result_val.* = try o.lowerValue(pt, elem);
3882 result_field.* = result_val.typeOf(&o.builder);3849 result_field.* = result_val.typeOf(&o.builder);
3883 if (result_field.* != elem_ty) need_unnamed = true;3850 if (result_field.* != elem_ty) need_unnamed = true;
3884 }3851 }
...@@ -3890,7 +3857,7 @@ pub const Object = struct {...@@ -3890,7 +3857,7 @@ pub const Object = struct {
3890 .repeated_elem => |elem| {3857 .repeated_elem => |elem| {
3891 const len: usize = @intCast(array_type.len);3858 const len: usize = @intCast(array_type.len);
3892 const len_including_sentinel: usize = @intCast(array_type.lenIncludingSentinel());3859 const len_including_sentinel: usize = @intCast(array_type.lenIncludingSentinel());
3893 const array_ty = try o.lowerType(ty);3860 const array_ty = try o.lowerType(pt, ty);
3894 const elem_ty = array_ty.childType(&o.builder);3861 const elem_ty = array_ty.childType(&o.builder);
38953862
3896 const ExpectedContents = extern struct {3863 const ExpectedContents = extern struct {
...@@ -3908,12 +3875,12 @@ pub const Object = struct {...@@ -3908,12 +3875,12 @@ pub const Object = struct {
3908 defer allocator.free(fields);3875 defer allocator.free(fields);
39093876
3910 var need_unnamed = false;3877 var need_unnamed = false;
3911 @memset(vals[0..len], try o.lowerValue(elem));3878 @memset(vals[0..len], try o.lowerValue(pt, elem));
3912 @memset(fields[0..len], vals[0].typeOf(&o.builder));3879 @memset(fields[0..len], vals[0].typeOf(&o.builder));
3913 if (fields[0] != elem_ty) need_unnamed = true;3880 if (fields[0] != elem_ty) need_unnamed = true;
39143881
3915 if (array_type.sentinel != .none) {3882 if (array_type.sentinel != .none) {
3916 vals[len] = try o.lowerValue(array_type.sentinel);3883 vals[len] = try o.lowerValue(pt, array_type.sentinel);
3917 fields[len] = vals[len].typeOf(&o.builder);3884 fields[len] = vals[len].typeOf(&o.builder);
3918 if (fields[len] != elem_ty) need_unnamed = true;3885 if (fields[len] != elem_ty) need_unnamed = true;
3919 }3886 }
...@@ -3925,7 +3892,7 @@ pub const Object = struct {...@@ -3925,7 +3892,7 @@ pub const Object = struct {
3925 },3892 },
3926 },3893 },
3927 .vector_type => |vector_type| {3894 .vector_type => |vector_type| {
3928 const vector_ty = try o.lowerType(ty);3895 const vector_ty = try o.lowerType(pt, ty);
3929 switch (aggregate.storage) {3896 switch (aggregate.storage) {
3930 .bytes, .elems => {3897 .bytes, .elems => {
3931 const ExpectedContents = [Builder.expected_fields_len]Builder.Constant;3898 const ExpectedContents = [Builder.expected_fields_len]Builder.Constant;
...@@ -3942,7 +3909,7 @@ pub const Object = struct {...@@ -3942,7 +3909,7 @@ pub const Object = struct {
3942 result_val.* = try o.builder.intConst(.i8, byte);3909 result_val.* = try o.builder.intConst(.i8, byte);
3943 },3910 },
3944 .elems => |elems| for (vals, elems) |*result_val, elem| {3911 .elems => |elems| for (vals, elems) |*result_val, elem| {
3945 result_val.* = try o.lowerValue(elem);3912 result_val.* = try o.lowerValue(pt, elem);
3946 },3913 },
3947 .repeated_elem => unreachable,3914 .repeated_elem => unreachable,
3948 }3915 }
...@@ -3950,12 +3917,12 @@ pub const Object = struct {...@@ -3950,12 +3917,12 @@ pub const Object = struct {
3950 },3917 },
3951 .repeated_elem => |elem| return o.builder.splatConst(3918 .repeated_elem => |elem| return o.builder.splatConst(
3952 vector_ty,3919 vector_ty,
3953 try o.lowerValue(elem),3920 try o.lowerValue(pt, elem),
3954 ),3921 ),
3955 }3922 }
3956 },3923 },
3957 .tuple_type => |tuple| {3924 .tuple_type => |tuple| {
3958 const struct_ty = try o.lowerType(ty);3925 const struct_ty = try o.lowerType(pt, ty);
3959 const llvm_len = struct_ty.aggregateLen(&o.builder);3926 const llvm_len = struct_ty.aggregateLen(&o.builder);
39603927
3961 const ExpectedContents = extern struct {3928 const ExpectedContents = extern struct {
...@@ -4001,7 +3968,7 @@ pub const Object = struct {...@@ -4001,7 +3968,7 @@ pub const Object = struct {
4001 }3968 }
40023969
4003 vals[llvm_index] =3970 vals[llvm_index] =
4004 try o.lowerValue((try val.fieldValue(pt, field_index)).toIntern());3971 try o.lowerValue(pt, (try val.fieldValue(pt, field_index)).toIntern());
4005 fields[llvm_index] = vals[llvm_index].typeOf(&o.builder);3972 fields[llvm_index] = vals[llvm_index].typeOf(&o.builder);
4006 if (fields[llvm_index] != struct_ty.structFields(&o.builder)[llvm_index])3973 if (fields[llvm_index] != struct_ty.structFields(&o.builder)[llvm_index])
4007 need_unnamed = true;3974 need_unnamed = true;
...@@ -4030,14 +3997,14 @@ pub const Object = struct {...@@ -4030,14 +3997,14 @@ pub const Object = struct {
4030 .struct_type => {3997 .struct_type => {
4031 const struct_type = ip.loadStructType(ty.toIntern());3998 const struct_type = ip.loadStructType(ty.toIntern());
4032 assert(struct_type.haveLayout(ip));3999 assert(struct_type.haveLayout(ip));
4033 const struct_ty = try o.lowerType(ty);4000 const struct_ty = try o.lowerType(pt, ty);
4034 if (struct_type.layout == .@"packed") {4001 if (struct_type.layout == .@"packed") {
4035 comptime assert(Type.packed_struct_layout_version == 2);4002 comptime assert(Type.packed_struct_layout_version == 2);
40364003
4037 const bits = ty.bitSize(zcu);4004 const bits = ty.bitSize(zcu);
4038 const llvm_int_ty = try o.builder.intType(@intCast(bits));4005 const llvm_int_ty = try o.builder.intType(@intCast(bits));
40394006
4040 return o.lowerValueToInt(llvm_int_ty, arg_val);4007 return o.lowerValueToInt(pt, llvm_int_ty, arg_val);
4041 }4008 }
4042 const llvm_len = struct_ty.aggregateLen(&o.builder);4009 const llvm_len = struct_ty.aggregateLen(&o.builder);
40434010
...@@ -4085,6 +4052,7 @@ pub const Object = struct {...@@ -4085,6 +4052,7 @@ pub const Object = struct {
4085 }4052 }
40864053
4087 vals[llvm_index] = try o.lowerValue(4054 vals[llvm_index] = try o.lowerValue(
4055 pt,
4088 (try val.fieldValue(pt, field_index)).toIntern(),4056 (try val.fieldValue(pt, field_index)).toIntern(),
4089 );4057 );
4090 fields[llvm_index] = vals[llvm_index].typeOf(&o.builder);4058 fields[llvm_index] = vals[llvm_index].typeOf(&o.builder);
...@@ -4115,9 +4083,9 @@ pub const Object = struct {...@@ -4115,9 +4083,9 @@ pub const Object = struct {
4115 else => unreachable,4083 else => unreachable,
4116 },4084 },
4117 .un => |un| {4085 .un => |un| {
4118 const union_ty = try o.lowerType(ty);4086 const union_ty = try o.lowerType(pt, ty);
4119 const layout = ty.unionGetLayout(zcu);4087 const layout = ty.unionGetLayout(zcu);
4120 if (layout.payload_size == 0) return o.lowerValue(un.tag);4088 if (layout.payload_size == 0) return o.lowerValue(pt, un.tag);
41214089
4122 const union_obj = zcu.typeToUnion(ty).?;4090 const union_obj = zcu.typeToUnion(ty).?;
4123 const container_layout = union_obj.flagsUnordered(ip).layout;4091 const container_layout = union_obj.flagsUnordered(ip).layout;
...@@ -4131,7 +4099,7 @@ pub const Object = struct {...@@ -4131,7 +4099,7 @@ pub const Object = struct {
4131 const bits = ty.bitSize(zcu);4099 const bits = ty.bitSize(zcu);
4132 const llvm_int_ty = try o.builder.intType(@intCast(bits));4100 const llvm_int_ty = try o.builder.intType(@intCast(bits));
41334101
4134 return o.lowerValueToInt(llvm_int_ty, arg_val);4102 return o.lowerValueToInt(pt, llvm_int_ty, arg_val);
4135 }4103 }
41364104
4137 // Sometimes we must make an unnamed struct because LLVM does4105 // Sometimes we must make an unnamed struct because LLVM does
...@@ -4144,7 +4112,7 @@ pub const Object = struct {...@@ -4144,7 +4112,7 @@ pub const Object = struct {
4144 const padding_len = layout.payload_size;4112 const padding_len = layout.payload_size;
4145 break :p try o.builder.undefConst(try o.builder.arrayType(padding_len, .i8));4113 break :p try o.builder.undefConst(try o.builder.arrayType(padding_len, .i8));
4146 }4114 }
4147 const payload = try o.lowerValue(un.val);4115 const payload = try o.lowerValue(pt, un.val);
4148 const payload_ty = payload.typeOf(&o.builder);4116 const payload_ty = payload.typeOf(&o.builder);
4149 if (payload_ty != union_ty.structFields(&o.builder)[4117 if (payload_ty != union_ty.structFields(&o.builder)[
4150 @intFromBool(layout.tag_align.compare(.gte, layout.payload_align))4118 @intFromBool(layout.tag_align.compare(.gte, layout.payload_align))
...@@ -4163,10 +4131,10 @@ pub const Object = struct {...@@ -4163,10 +4131,10 @@ pub const Object = struct {
4163 const bits = ty.bitSize(zcu);4131 const bits = ty.bitSize(zcu);
4164 const llvm_int_ty = try o.builder.intType(@intCast(bits));4132 const llvm_int_ty = try o.builder.intType(@intCast(bits));
41654133
4166 return o.lowerValueToInt(llvm_int_ty, arg_val);4134 return o.lowerValueToInt(pt, llvm_int_ty, arg_val);
4167 }4135 }
41684136
4169 const union_val = try o.lowerValue(un.val);4137 const union_val = try o.lowerValue(pt, un.val);
4170 need_unnamed = true;4138 need_unnamed = true;
4171 break :p union_val;4139 break :p union_val;
4172 };4140 };
...@@ -4176,7 +4144,7 @@ pub const Object = struct {...@@ -4176,7 +4144,7 @@ pub const Object = struct {
4176 try o.builder.structType(union_ty.structKind(&o.builder), &.{payload_ty})4144 try o.builder.structType(union_ty.structKind(&o.builder), &.{payload_ty})
4177 else4145 else
4178 union_ty, &.{payload});4146 union_ty, &.{payload});
4179 const tag = try o.lowerValue(un.tag);4147 const tag = try o.lowerValue(pt, un.tag);
4180 const tag_ty = tag.typeOf(&o.builder);4148 const tag_ty = tag.typeOf(&o.builder);
4181 var fields: [3]Builder.Type = undefined;4149 var fields: [3]Builder.Type = undefined;
4182 var vals: [3]Builder.Constant = undefined;4150 var vals: [3]Builder.Constant = undefined;
...@@ -4204,48 +4172,50 @@ pub const Object = struct {...@@ -4204,48 +4172,50 @@ pub const Object = struct {
42044172
4205 fn lowerBigInt(4173 fn lowerBigInt(
4206 o: *Object,4174 o: *Object,
4175 pt: Zcu.PerThread,
4207 ty: Type,4176 ty: Type,
4208 bigint: std.math.big.int.Const,4177 bigint: std.math.big.int.Const,
4209 ) Allocator.Error!Builder.Constant {4178 ) Allocator.Error!Builder.Constant {
4210 const zcu = o.pt.zcu;4179 const zcu = pt.zcu;
4211 return o.builder.bigIntConst(try o.builder.intType(ty.intInfo(zcu).bits), bigint);4180 return o.builder.bigIntConst(try o.builder.intType(ty.intInfo(zcu).bits), bigint);
4212 }4181 }
42134182
4214 fn lowerPtr(4183 fn lowerPtr(
4215 o: *Object,4184 o: *Object,
4185 pt: Zcu.PerThread,
4216 ptr_val: InternPool.Index,4186 ptr_val: InternPool.Index,
4217 prev_offset: u64,4187 prev_offset: u64,
4218 ) Error!Builder.Constant {4188 ) Error!Builder.Constant {
4219 const pt = o.pt;
4220 const zcu = pt.zcu;4189 const zcu = pt.zcu;
4221 const ptr = zcu.intern_pool.indexToKey(ptr_val).ptr;4190 const ptr = zcu.intern_pool.indexToKey(ptr_val).ptr;
4222 const offset: u64 = prev_offset + ptr.byte_offset;4191 const offset: u64 = prev_offset + ptr.byte_offset;
4223 return switch (ptr.base_addr) {4192 return switch (ptr.base_addr) {
4224 .nav => |nav| {4193 .nav => |nav| {
4225 const base_ptr = try o.lowerNavRefValue(nav);4194 const base_ptr = try o.lowerNavRefValue(pt, nav);
4226 return o.builder.gepConst(.inbounds, .i8, base_ptr, null, &.{4195 return o.builder.gepConst(.inbounds, .i8, base_ptr, null, &.{
4227 try o.builder.intConst(.i64, offset),4196 try o.builder.intConst(.i64, offset),
4228 });4197 });
4229 },4198 },
4230 .uav => |uav| {4199 .uav => |uav| {
4231 const base_ptr = try o.lowerUavRef(uav);4200 const base_ptr = try o.lowerUavRef(pt, uav);
4232 return o.builder.gepConst(.inbounds, .i8, base_ptr, null, &.{4201 return o.builder.gepConst(.inbounds, .i8, base_ptr, null, &.{
4233 try o.builder.intConst(.i64, offset),4202 try o.builder.intConst(.i64, offset),
4234 });4203 });
4235 },4204 },
4236 .int => try o.builder.castConst(4205 .int => try o.builder.castConst(
4237 .inttoptr,4206 .inttoptr,
4238 try o.builder.intConst(try o.lowerType(Type.usize), offset),4207 try o.builder.intConst(try o.lowerType(pt, Type.usize), offset),
4239 try o.lowerType(Type.fromInterned(ptr.ty)),4208 try o.lowerType(pt, Type.fromInterned(ptr.ty)),
4240 ),4209 ),
4241 .eu_payload => |eu_ptr| try o.lowerPtr(4210 .eu_payload => |eu_ptr| try o.lowerPtr(
4211 pt,
4242 eu_ptr,4212 eu_ptr,
4243 offset + @import("../codegen.zig").errUnionPayloadOffset(4213 offset + @import("../codegen.zig").errUnionPayloadOffset(
4244 Value.fromInterned(eu_ptr).typeOf(zcu).childType(zcu),4214 Value.fromInterned(eu_ptr).typeOf(zcu).childType(zcu),
4245 zcu,4215 zcu,
4246 ),4216 ),
4247 ),4217 ),
4248 .opt_payload => |opt_ptr| try o.lowerPtr(opt_ptr, offset),4218 .opt_payload => |opt_ptr| try o.lowerPtr(pt, opt_ptr, offset),
4249 .field => |field| {4219 .field => |field| {
4250 const agg_ty = Value.fromInterned(field.base).typeOf(zcu).childType(zcu);4220 const agg_ty = Value.fromInterned(field.base).typeOf(zcu).childType(zcu);
4251 const field_off: u64 = switch (agg_ty.zigTypeTag(zcu)) {4221 const field_off: u64 = switch (agg_ty.zigTypeTag(zcu)) {
...@@ -4263,7 +4233,7 @@ pub const Object = struct {...@@ -4263,7 +4233,7 @@ pub const Object = struct {
4263 },4233 },
4264 else => unreachable,4234 else => unreachable,
4265 };4235 };
4266 return o.lowerPtr(field.base, offset + field_off);4236 return o.lowerPtr(pt, field.base, offset + field_off);
4267 },4237 },
4268 .arr_elem, .comptime_field, .comptime_alloc => unreachable,4238 .arr_elem, .comptime_field, .comptime_alloc => unreachable,
4269 };4239 };
...@@ -4273,9 +4243,9 @@ pub const Object = struct {...@@ -4273,9 +4243,9 @@ pub const Object = struct {
4273 /// Maybe the logic could be unified.4243 /// Maybe the logic could be unified.
4274 fn lowerUavRef(4244 fn lowerUavRef(
4275 o: *Object,4245 o: *Object,
4246 pt: Zcu.PerThread,
4276 uav: InternPool.Key.Ptr.BaseAddr.Uav,4247 uav: InternPool.Key.Ptr.BaseAddr.Uav,
4277 ) Error!Builder.Constant {4248 ) Error!Builder.Constant {
4278 const pt = o.pt;
4279 const zcu = pt.zcu;4249 const zcu = pt.zcu;
4280 const ip = &zcu.intern_pool;4250 const ip = &zcu.intern_pool;
4281 const uav_val = uav.val;4251 const uav_val = uav.val;
...@@ -4292,25 +4262,24 @@ pub const Object = struct {...@@ -4292,25 +4262,24 @@ pub const Object = struct {
42924262
4293 const is_fn_body = uav_ty.zigTypeTag(zcu) == .@"fn";4263 const is_fn_body = uav_ty.zigTypeTag(zcu) == .@"fn";
4294 if ((!is_fn_body and !uav_ty.hasRuntimeBits(zcu)) or4264 if ((!is_fn_body and !uav_ty.hasRuntimeBits(zcu)) or
4295 (is_fn_body and zcu.typeToFunc(uav_ty).?.is_generic)) return o.lowerPtrToVoid(ptr_ty);4265 (is_fn_body and zcu.typeToFunc(uav_ty).?.is_generic)) return o.lowerPtrToVoid(pt, ptr_ty);
42964266
4297 if (is_fn_body)4267 if (is_fn_body)
4298 @panic("TODO");4268 @panic("TODO");
42994269
4300 const llvm_addr_space = toLlvmAddressSpace(ptr_ty.ptrAddressSpace(zcu), target);4270 const llvm_addr_space = toLlvmAddressSpace(ptr_ty.ptrAddressSpace(zcu), target);
4301 const alignment = ptr_ty.ptrAlignment(zcu);4271 const alignment = ptr_ty.ptrAlignment(zcu);
4302 const llvm_global = (try o.resolveGlobalUav(uav.val, llvm_addr_space, alignment)).ptrConst(&o.builder).global;4272 const llvm_global = (try o.resolveGlobalUav(pt, uav.val, llvm_addr_space, alignment)).ptrConst(&o.builder).global;
43034273
4304 const llvm_val = try o.builder.convConst(4274 const llvm_val = try o.builder.convConst(
4305 llvm_global.toConst(),4275 llvm_global.toConst(),
4306 try o.builder.ptrType(llvm_addr_space),4276 try o.builder.ptrType(llvm_addr_space),
4307 );4277 );
43084278
4309 return o.builder.convConst(llvm_val, try o.lowerType(ptr_ty));4279 return o.builder.convConst(llvm_val, try o.lowerType(pt, ptr_ty));
4310 }4280 }
43114281
4312 fn lowerNavRefValue(o: *Object, nav_index: InternPool.Nav.Index) Allocator.Error!Builder.Constant {4282 fn lowerNavRefValue(o: *Object, pt: Zcu.PerThread, nav_index: InternPool.Nav.Index) Allocator.Error!Builder.Constant {
4313 const pt = o.pt;
4314 const zcu = pt.zcu;4283 const zcu = pt.zcu;
4315 const ip = &zcu.intern_pool;4284 const ip = &zcu.intern_pool;
43164285
...@@ -4323,24 +4292,24 @@ pub const Object = struct {...@@ -4323,24 +4292,24 @@ pub const Object = struct {
4323 if ((!is_fn_body and !nav_ty.hasRuntimeBits(zcu)) or4292 if ((!is_fn_body and !nav_ty.hasRuntimeBits(zcu)) or
4324 (is_fn_body and zcu.typeToFunc(nav_ty).?.is_generic))4293 (is_fn_body and zcu.typeToFunc(nav_ty).?.is_generic))
4325 {4294 {
4326 return o.lowerPtrToVoid(ptr_ty);4295 return o.lowerPtrToVoid(pt, ptr_ty);
4327 }4296 }
43284297
4329 const llvm_global = if (is_fn_body)4298 const llvm_global = if (is_fn_body)
4330 (try o.resolveLlvmFunction(nav_index)).ptrConst(&o.builder).global4299 (try o.resolveLlvmFunction(pt, nav_index)).ptrConst(&o.builder).global
4331 else4300 else
4332 (try o.resolveGlobalNav(nav_index)).ptrConst(&o.builder).global;4301 (try o.resolveGlobalNav(pt, nav_index)).ptrConst(&o.builder).global;
43334302
4334 const llvm_val = try o.builder.convConst(4303 const llvm_val = try o.builder.convConst(
4335 llvm_global.toConst(),4304 llvm_global.toConst(),
4336 try o.builder.ptrType(toLlvmAddressSpace(nav.getAddrspace(), zcu.getTarget())),4305 try o.builder.ptrType(toLlvmAddressSpace(nav.getAddrspace(), zcu.getTarget())),
4337 );4306 );
43384307
4339 return o.builder.convConst(llvm_val, try o.lowerType(ptr_ty));4308 return o.builder.convConst(llvm_val, try o.lowerType(pt, ptr_ty));
4340 }4309 }
43414310
4342 fn lowerPtrToVoid(o: *Object, ptr_ty: Type) Allocator.Error!Builder.Constant {4311 fn lowerPtrToVoid(o: *Object, pt: Zcu.PerThread, ptr_ty: Type) Allocator.Error!Builder.Constant {
4343 const zcu = o.pt.zcu;4312 const zcu = pt.zcu;
4344 // Even though we are pointing at something which has zero bits (e.g. `void`),4313 // Even though we are pointing at something which has zero bits (e.g. `void`),
4345 // Pointers are defined to have bits. So we must return something here.4314 // Pointers are defined to have bits. So we must return something here.
4346 // The value cannot be undefined, because we use the `nonnull` annotation4315 // The value cannot be undefined, because we use the `nonnull` annotation
...@@ -4358,8 +4327,8 @@ pub const Object = struct {...@@ -4358,8 +4327,8 @@ pub const Object = struct {
4358 64 => 0xaaaaaaaa_aaaaaaaa,4327 64 => 0xaaaaaaaa_aaaaaaaa,
4359 else => unreachable,4328 else => unreachable,
4360 };4329 };
4361 const llvm_usize = try o.lowerType(Type.usize);4330 const llvm_usize = try o.lowerType(pt, Type.usize);
4362 const llvm_ptr_ty = try o.lowerType(ptr_ty);4331 const llvm_ptr_ty = try o.lowerType(pt, ptr_ty);
4363 return o.builder.castConst(.inttoptr, try o.builder.intConst(llvm_usize, int), llvm_ptr_ty);4332 return o.builder.castConst(.inttoptr, try o.builder.intConst(llvm_usize, int), llvm_ptr_ty);
4364 }4333 }
43654334
...@@ -4367,8 +4336,7 @@ pub const Object = struct {...@@ -4367,8 +4336,7 @@ pub const Object = struct {
4367 /// widen it before using it and then truncate the result.4336 /// widen it before using it and then truncate the result.
4368 /// RMW exchange of floating-point values is bitcasted to same-sized integer4337 /// RMW exchange of floating-point values is bitcasted to same-sized integer
4369 /// types to work around a LLVM deficiency when targeting ARM/AArch64.4338 /// types to work around a LLVM deficiency when targeting ARM/AArch64.
4370 fn getAtomicAbiType(o: *Object, ty: Type, is_rmw_xchg: bool) Allocator.Error!Builder.Type {4339 fn getAtomicAbiType(o: *Object, pt: Zcu.PerThread, ty: Type, is_rmw_xchg: bool) Allocator.Error!Builder.Type {
4371 const pt = o.pt;
4372 const zcu = pt.zcu;4340 const zcu = pt.zcu;
4373 const int_ty = switch (ty.zigTypeTag(zcu)) {4341 const int_ty = switch (ty.zigTypeTag(zcu)) {
4374 .int => ty,4342 .int => ty,
...@@ -4390,13 +4358,13 @@ pub const Object = struct {...@@ -4390,13 +4358,13 @@ pub const Object = struct {
43904358
4391 fn addByValParamAttrs(4359 fn addByValParamAttrs(
4392 o: *Object,4360 o: *Object,
4361 pt: Zcu.PerThread,
4393 attributes: *Builder.FunctionAttributes.Wip,4362 attributes: *Builder.FunctionAttributes.Wip,
4394 param_ty: Type,4363 param_ty: Type,
4395 param_index: u32,4364 param_index: u32,
4396 fn_info: InternPool.Key.FuncType,4365 fn_info: InternPool.Key.FuncType,
4397 llvm_arg_i: u32,4366 llvm_arg_i: u32,
4398 ) Allocator.Error!void {4367 ) Allocator.Error!void {
4399 const pt = o.pt;
4400 const zcu = pt.zcu;4368 const zcu = pt.zcu;
4401 if (param_ty.isPtrAtRuntime(zcu)) {4369 if (param_ty.isPtrAtRuntime(zcu)) {
4402 const ptr_info = param_ty.ptrInfo(zcu);4370 const ptr_info = param_ty.ptrInfo(zcu);
...@@ -4416,7 +4384,7 @@ pub const Object = struct {...@@ -4416,7 +4384,7 @@ pub const Object = struct {
4416 .x86_64_interrupt,4384 .x86_64_interrupt,
4417 .x86_interrupt,4385 .x86_interrupt,
4418 => {4386 => {
4419 const child_type = try lowerType(o, Type.fromInterned(ptr_info.child));4387 const child_type = try lowerType(o, pt, Type.fromInterned(ptr_info.child));
4420 try attributes.addParamAttr(llvm_arg_i, .{ .byval = child_type }, &o.builder);4388 try attributes.addParamAttr(llvm_arg_i, .{ .byval = child_type }, &o.builder);
4421 },4389 },
4422 }4390 }
...@@ -4455,14 +4423,14 @@ pub const Object = struct {...@@ -4455,14 +4423,14 @@ pub const Object = struct {
4455 });4423 });
4456 }4424 }
44574425
4458 fn getCmpLtErrorsLenFunction(o: *Object) !Builder.Function.Index {4426 fn getCmpLtErrorsLenFunction(o: *Object, pt: Zcu.PerThread) !Builder.Function.Index {
4459 const name = try o.builder.strtabString(lt_errors_fn_name);4427 const name = try o.builder.strtabString(lt_errors_fn_name);
4460 if (o.builder.getGlobal(name)) |llvm_fn| return llvm_fn.ptrConst(&o.builder).kind.function;4428 if (o.builder.getGlobal(name)) |llvm_fn| return llvm_fn.ptrConst(&o.builder).kind.function;
44614429
4462 const zcu = o.pt.zcu;4430 const zcu = pt.zcu;
4463 const target = &zcu.root_mod.resolved_target.result;4431 const target = &zcu.root_mod.resolved_target.result;
4464 const function_index = try o.builder.addFunction(4432 const function_index = try o.builder.addFunction(
4465 try o.builder.fnType(.i1, &.{try o.errorIntType()}, .normal),4433 try o.builder.fnType(.i1, &.{try o.errorIntType(pt)}, .normal),
4466 name,4434 name,
4467 toLlvmAddressSpace(.generic, target),4435 toLlvmAddressSpace(.generic, target),
4468 );4436 );
...@@ -4477,8 +4445,7 @@ pub const Object = struct {...@@ -4477,8 +4445,7 @@ pub const Object = struct {
4477 return function_index;4445 return function_index;
4478 }4446 }
44794447
4480 fn getEnumTagNameFunction(o: *Object, enum_ty: Type) !Builder.Function.Index {4448 fn getEnumTagNameFunction(o: *Object, pt: Zcu.PerThread, enum_ty: Type) !Builder.Function.Index {
4481 const pt = o.pt;
4482 const zcu = pt.zcu;4449 const zcu = pt.zcu;
4483 const ip = &zcu.intern_pool;4450 const ip = &zcu.intern_pool;
4484 const enum_type = ip.loadEnumType(enum_ty.toIntern());4451 const enum_type = ip.loadEnumType(enum_ty.toIntern());
...@@ -4487,11 +4454,11 @@ pub const Object = struct {...@@ -4487,11 +4454,11 @@ pub const Object = struct {
4487 if (gop.found_existing) return gop.value_ptr.ptrConst(&o.builder).kind.function;4454 if (gop.found_existing) return gop.value_ptr.ptrConst(&o.builder).kind.function;
4488 errdefer assert(o.enum_tag_name_map.remove(enum_ty.toIntern()));4455 errdefer assert(o.enum_tag_name_map.remove(enum_ty.toIntern()));
44894456
4490 const usize_ty = try o.lowerType(Type.usize);4457 const usize_ty = try o.lowerType(pt, Type.usize);
4491 const ret_ty = try o.lowerType(Type.slice_const_u8_sentinel_0);4458 const ret_ty = try o.lowerType(pt, Type.slice_const_u8_sentinel_0);
4492 const target = &zcu.root_mod.resolved_target.result;4459 const target = &zcu.root_mod.resolved_target.result;
4493 const function_index = try o.builder.addFunction(4460 const function_index = try o.builder.addFunction(
4494 try o.builder.fnType(ret_ty, &.{try o.lowerType(Type.fromInterned(enum_type.tag_ty))}, .normal),4461 try o.builder.fnType(ret_ty, &.{try o.lowerType(pt, Type.fromInterned(enum_type.tag_ty))}, .normal),
4495 try o.builder.strtabStringFmt("__zig_tag_name_{f}", .{enum_type.name.fmt(ip)}),4462 try o.builder.strtabStringFmt("__zig_tag_name_{f}", .{enum_type.name.fmt(ip)}),
4496 toLlvmAddressSpace(.generic, target),4463 toLlvmAddressSpace(.generic, target),
4497 );4464 );
...@@ -4536,6 +4503,7 @@ pub const Object = struct {...@@ -4536,6 +4503,7 @@ pub const Object = struct {
45364503
4537 const return_block = try wip.block(1, "Name");4504 const return_block = try wip.block(1, "Name");
4538 const this_tag_int_value = try o.lowerValue(4505 const this_tag_int_value = try o.lowerValue(
4506 pt,
4539 (try pt.enumValueFieldIndex(enum_ty, @intCast(field_index))).toIntern(),4507 (try pt.enumValueFieldIndex(enum_ty, @intCast(field_index))).toIntern(),
4540 );4508 );
4541 try wip_switch.addCase(this_tag_int_value, return_block, &wip);4509 try wip_switch.addCase(this_tag_int_value, return_block, &wip);
...@@ -4555,10 +4523,11 @@ pub const Object = struct {...@@ -4555,10 +4523,11 @@ pub const Object = struct {
4555pub const NavGen = struct {4523pub const NavGen = struct {
4556 object: *Object,4524 object: *Object,
4557 nav_index: InternPool.Nav.Index,4525 nav_index: InternPool.Nav.Index,
4526 pt: Zcu.PerThread,
4558 err_msg: ?*Zcu.ErrorMsg,4527 err_msg: ?*Zcu.ErrorMsg,
45594528
4560 fn ownerModule(ng: NavGen) *Package.Module {4529 fn ownerModule(ng: NavGen) *Package.Module {
4561 return ng.object.pt.zcu.navFileScope(ng.nav_index).mod.?;4530 return ng.pt.zcu.navFileScope(ng.nav_index).mod.?;
4562 }4531 }
45634532
4564 fn todo(ng: *NavGen, comptime format: []const u8, args: anytype) Error {4533 fn todo(ng: *NavGen, comptime format: []const u8, args: anytype) Error {
...@@ -4566,14 +4535,14 @@ pub const NavGen = struct {...@@ -4566,14 +4535,14 @@ pub const NavGen = struct {
4566 assert(ng.err_msg == null);4535 assert(ng.err_msg == null);
4567 const o = ng.object;4536 const o = ng.object;
4568 const gpa = o.gpa;4537 const gpa = o.gpa;
4569 const src_loc = o.pt.zcu.navSrcLoc(ng.nav_index);4538 const src_loc = ng.pt.zcu.navSrcLoc(ng.nav_index);
4570 ng.err_msg = try Zcu.ErrorMsg.create(gpa, src_loc, "TODO (LLVM): " ++ format, args);4539 ng.err_msg = try Zcu.ErrorMsg.create(gpa, src_loc, "TODO (LLVM): " ++ format, args);
4571 return error.CodegenFail;4540 return error.CodegenFail;
4572 }4541 }
45734542
4574 fn genDecl(ng: *NavGen) !void {4543 fn genDecl(ng: *NavGen) !void {
4575 const o = ng.object;4544 const o = ng.object;
4576 const pt = o.pt;4545 const pt = ng.pt;
4577 const zcu = pt.zcu;4546 const zcu = pt.zcu;
4578 const ip = &zcu.intern_pool;4547 const ip = &zcu.intern_pool;
4579 const nav_index = ng.nav_index;4548 const nav_index = ng.nav_index;
...@@ -4588,16 +4557,16 @@ pub const NavGen = struct {...@@ -4588,16 +4557,16 @@ pub const NavGen = struct {
4588 const ty = Type.fromInterned(nav.typeOf(ip));4557 const ty = Type.fromInterned(nav.typeOf(ip));
45894558
4590 if (linkage != .internal and ip.isFunctionType(ty.toIntern())) {4559 if (linkage != .internal and ip.isFunctionType(ty.toIntern())) {
4591 _ = try o.resolveLlvmFunction(owner_nav);4560 _ = try o.resolveLlvmFunction(pt, owner_nav);
4592 } else {4561 } else {
4593 const variable_index = try o.resolveGlobalNav(nav_index);4562 const variable_index = try o.resolveGlobalNav(pt, nav_index);
4594 variable_index.setAlignment(pt.navAlignment(nav_index).toLlvm(), &o.builder);4563 variable_index.setAlignment(pt.navAlignment(nav_index).toLlvm(), &o.builder);
4595 if (resolved.@"linksection".toSlice(ip)) |section|4564 if (resolved.@"linksection".toSlice(ip)) |section|
4596 variable_index.setSection(try o.builder.string(section), &o.builder);4565 variable_index.setSection(try o.builder.string(section), &o.builder);
4597 if (is_const) variable_index.setMutability(.constant, &o.builder);4566 if (is_const) variable_index.setMutability(.constant, &o.builder);
4598 try variable_index.setInitializer(switch (init_val) {4567 try variable_index.setInitializer(switch (init_val) {
4599 .none => .no_init,4568 .none => .no_init,
4600 else => try o.lowerValue(init_val),4569 else => try o.lowerValue(pt, init_val),
4601 }, &o.builder);4570 }, &o.builder);
4602 variable_index.setVisibility(visibility, &o.builder);4571 variable_index.setVisibility(visibility, &o.builder);
46034572
...@@ -4609,7 +4578,7 @@ pub const NavGen = struct {...@@ -4609,7 +4578,7 @@ pub const NavGen = struct {
4609 const line_number = zcu.navSrcLine(nav_index) + 1;4578 const line_number = zcu.navSrcLine(nav_index) + 1;
46104579
4611 if (!mod.strip) {4580 if (!mod.strip) {
4612 const debug_file = try o.getDebugFile(file_scope);4581 const debug_file = try o.getDebugFile(pt, file_scope);
46134582
4614 const debug_global_var = try o.builder.debugGlobalVar(4583 const debug_global_var = try o.builder.debugGlobalVar(
4615 try o.builder.metadataString(nav.name.toSlice(ip)), // Name4584 try o.builder.metadataString(nav.name.toSlice(ip)), // Name
...@@ -4617,7 +4586,7 @@ pub const NavGen = struct {...@@ -4617,7 +4586,7 @@ pub const NavGen = struct {
4617 debug_file, // File4586 debug_file, // File
4618 debug_file, // Scope4587 debug_file, // Scope
4619 line_number,4588 line_number,
4620 try o.lowerDebugType(ty),4589 try o.lowerDebugType(pt, ty),
4621 variable_index,4590 variable_index,
4622 .{ .local = linkage == .internal },4591 .{ .local = linkage == .internal },
4623 );4592 );
...@@ -4814,16 +4783,17 @@ pub const FuncGen = struct {...@@ -4814,16 +4783,17 @@ pub const FuncGen = struct {
4814 const gop = try self.func_inst_table.getOrPut(gpa, inst);4783 const gop = try self.func_inst_table.getOrPut(gpa, inst);
4815 if (gop.found_existing) return gop.value_ptr.*;4784 if (gop.found_existing) return gop.value_ptr.*;
48164785
4817 const llvm_val = try self.resolveValue((try self.air.value(inst, self.ng.object.pt)).?);4786 const llvm_val = try self.resolveValue((try self.air.value(inst, self.ng.pt)).?);
4818 gop.value_ptr.* = llvm_val.toValue();4787 gop.value_ptr.* = llvm_val.toValue();
4819 return llvm_val.toValue();4788 return llvm_val.toValue();
4820 }4789 }
48214790
4822 fn resolveValue(self: *FuncGen, val: Value) Error!Builder.Constant {4791 fn resolveValue(self: *FuncGen, val: Value) Error!Builder.Constant {
4823 const o = self.ng.object;4792 const o = self.ng.object;
4824 const zcu = o.pt.zcu;4793 const pt = self.ng.pt;
4794 const zcu = pt.zcu;
4825 const ty = val.typeOf(zcu);4795 const ty = val.typeOf(zcu);
4826 const llvm_val = try o.lowerValue(val.toIntern());4796 const llvm_val = try o.lowerValue(pt, val.toIntern());
4827 if (!isByRef(ty, zcu)) return llvm_val;4797 if (!isByRef(ty, zcu)) return llvm_val;
48284798
4829 // We have an LLVM value but we need to create a global constant and4799 // We have an LLVM value but we need to create a global constant and
...@@ -4847,7 +4817,7 @@ pub const FuncGen = struct {...@@ -4847,7 +4817,7 @@ pub const FuncGen = struct {
48474817
4848 fn genBody(self: *FuncGen, body: []const Air.Inst.Index, coverage_point: Air.CoveragePoint) Error!void {4818 fn genBody(self: *FuncGen, body: []const Air.Inst.Index, coverage_point: Air.CoveragePoint) Error!void {
4849 const o = self.ng.object;4819 const o = self.ng.object;
4850 const zcu = o.pt.zcu;4820 const zcu = self.ng.pt.zcu;
4851 const ip = &zcu.intern_pool;4821 const ip = &zcu.intern_pool;
4852 const air_tags = self.air.instructions.items(.tag);4822 const air_tags = self.air.instructions.items(.tag);
4853 switch (coverage_point) {4823 switch (coverage_point) {
...@@ -5173,7 +5143,7 @@ pub const FuncGen = struct {...@@ -5173,7 +5143,7 @@ pub const FuncGen = struct {
51735143
5174 if (maybe_inline_func) |inline_func| {5144 if (maybe_inline_func) |inline_func| {
5175 const o = self.ng.object;5145 const o = self.ng.object;
5176 const pt = o.pt;5146 const pt = self.ng.pt;
5177 const zcu = pt.zcu;5147 const zcu = pt.zcu;
5178 const ip = &zcu.intern_pool;5148 const ip = &zcu.intern_pool;
51795149
...@@ -5182,7 +5152,7 @@ pub const FuncGen = struct {...@@ -5182,7 +5152,7 @@ pub const FuncGen = struct {
5182 const file_scope = zcu.navFileScopeIndex(func.owner_nav);5152 const file_scope = zcu.navFileScopeIndex(func.owner_nav);
5183 const mod = zcu.fileByIndex(file_scope).mod.?;5153 const mod = zcu.fileByIndex(file_scope).mod.?;
51845154
5185 self.file = try o.getDebugFile(file_scope);5155 self.file = try o.getDebugFile(pt, file_scope);
51865156
5187 const line_number = zcu.navSrcLine(func.owner_nav) + 1;5157 const line_number = zcu.navSrcLine(func.owner_nav) + 1;
5188 self.inlined = self.wip.debug_location;5158 self.inlined = self.wip.debug_location;
...@@ -5198,7 +5168,7 @@ pub const FuncGen = struct {...@@ -5198,7 +5168,7 @@ pub const FuncGen = struct {
5198 try o.builder.metadataString(nav.fqn.toSlice(&zcu.intern_pool)),5168 try o.builder.metadataString(nav.fqn.toSlice(&zcu.intern_pool)),
5199 line_number,5169 line_number,
5200 line_number + func.lbrace_line,5170 line_number + func.lbrace_line,
5201 try o.lowerDebugType(fn_ty),5171 try o.lowerDebugType(pt, fn_ty),
5202 .{5172 .{
5203 .di_flags = .{ .StaticMember = true },5173 .di_flags = .{ .StaticMember = true },
5204 .sp_flags = .{5174 .sp_flags = .{
...@@ -5255,7 +5225,7 @@ pub const FuncGen = struct {...@@ -5255,7 +5225,7 @@ pub const FuncGen = struct {
5255 const extra = self.air.extraData(Air.Call, pl_op.payload);5225 const extra = self.air.extraData(Air.Call, pl_op.payload);
5256 const args: []const Air.Inst.Ref = @ptrCast(self.air.extra.items[extra.end..][0..extra.data.args_len]);5226 const args: []const Air.Inst.Ref = @ptrCast(self.air.extra.items[extra.end..][0..extra.data.args_len]);
5257 const o = self.ng.object;5227 const o = self.ng.object;
5258 const pt = o.pt;5228 const pt = self.ng.pt;
5259 const zcu = pt.zcu;5229 const zcu = pt.zcu;
5260 const ip = &zcu.intern_pool;5230 const ip = &zcu.intern_pool;
5261 const callee_ty = self.typeOf(pl_op.operand);5231 const callee_ty = self.typeOf(pl_op.operand);
...@@ -5287,7 +5257,7 @@ pub const FuncGen = struct {...@@ -5287,7 +5257,7 @@ pub const FuncGen = struct {
5287 }5257 }
52885258
5289 const ret_ptr = if (!sret) null else blk: {5259 const ret_ptr = if (!sret) null else blk: {
5290 const llvm_ret_ty = try o.lowerType(return_type);5260 const llvm_ret_ty = try o.lowerType(pt, return_type);
5291 try attributes.addParamAttr(0, .{ .sret = llvm_ret_ty }, &o.builder);5261 try attributes.addParamAttr(0, .{ .sret = llvm_ret_ty }, &o.builder);
52925262
5293 const alignment = return_type.abiAlignment(zcu).toLlvm();5263 const alignment = return_type.abiAlignment(zcu).toLlvm();
...@@ -5302,14 +5272,14 @@ pub const FuncGen = struct {...@@ -5302,14 +5272,14 @@ pub const FuncGen = struct {
5302 try llvm_args.append(self.err_ret_trace);5272 try llvm_args.append(self.err_ret_trace);
5303 }5273 }
53045274
5305 var it = iterateParamTypes(o, fn_info);5275 var it = iterateParamTypes(o, pt, fn_info);
5306 while (try it.nextCall(self, args)) |lowering| switch (lowering) {5276 while (try it.nextCall(self, args)) |lowering| switch (lowering) {
5307 .no_bits => continue,5277 .no_bits => continue,
5308 .byval => {5278 .byval => {
5309 const arg = args[it.zig_index - 1];5279 const arg = args[it.zig_index - 1];
5310 const param_ty = self.typeOf(arg);5280 const param_ty = self.typeOf(arg);
5311 const llvm_arg = try self.resolveInst(arg);5281 const llvm_arg = try self.resolveInst(arg);
5312 const llvm_param_ty = try o.lowerType(param_ty);5282 const llvm_param_ty = try o.lowerType(pt, param_ty);
5313 if (isByRef(param_ty, zcu)) {5283 if (isByRef(param_ty, zcu)) {
5314 const alignment = param_ty.abiAlignment(zcu).toLlvm();5284 const alignment = param_ty.abiAlignment(zcu).toLlvm();
5315 const loaded = try self.wip.load(.normal, llvm_param_ty, llvm_arg, alignment, "");5285 const loaded = try self.wip.load(.normal, llvm_param_ty, llvm_arg, alignment, "");
...@@ -5338,7 +5308,7 @@ pub const FuncGen = struct {...@@ -5338,7 +5308,7 @@ pub const FuncGen = struct {
5338 const llvm_arg = try self.resolveInst(arg);5308 const llvm_arg = try self.resolveInst(arg);
53395309
5340 const alignment = param_ty.abiAlignment(zcu).toLlvm();5310 const alignment = param_ty.abiAlignment(zcu).toLlvm();
5341 const param_llvm_ty = try o.lowerType(param_ty);5311 const param_llvm_ty = try o.lowerType(pt, param_ty);
5342 const arg_ptr = try self.buildAlloca(param_llvm_ty, alignment);5312 const arg_ptr = try self.buildAlloca(param_llvm_ty, alignment);
5343 if (isByRef(param_ty, zcu)) {5313 if (isByRef(param_ty, zcu)) {
5344 const loaded = try self.wip.load(.normal, param_llvm_ty, llvm_arg, alignment, "");5314 const loaded = try self.wip.load(.normal, param_llvm_ty, llvm_arg, alignment, "");
...@@ -5409,7 +5379,7 @@ pub const FuncGen = struct {...@@ -5409,7 +5379,7 @@ pub const FuncGen = struct {
5409 llvm_arg = ptr;5379 llvm_arg = ptr;
5410 }5380 }
54115381
5412 const float_ty = try o.lowerType(aarch64_c_abi.getFloatArrayType(arg_ty, zcu).?);5382 const float_ty = try o.lowerType(pt, aarch64_c_abi.getFloatArrayType(arg_ty, zcu).?);
5413 const array_ty = try o.builder.arrayType(count, float_ty);5383 const array_ty = try o.builder.arrayType(count, float_ty);
54145384
5415 const loaded = try self.wip.load(.normal, array_ty, llvm_arg, alignment, "");5385 const loaded = try self.wip.load(.normal, array_ty, llvm_arg, alignment, "");
...@@ -5436,7 +5406,7 @@ pub const FuncGen = struct {...@@ -5436,7 +5406,7 @@ pub const FuncGen = struct {
54365406
5437 {5407 {
5438 // Add argument attributes.5408 // Add argument attributes.
5439 it = iterateParamTypes(o, fn_info);5409 it = iterateParamTypes(o, pt, fn_info);
5440 it.llvm_index += @intFromBool(sret);5410 it.llvm_index += @intFromBool(sret);
5441 it.llvm_index += @intFromBool(err_return_tracing);5411 it.llvm_index += @intFromBool(err_return_tracing);
5442 while (try it.next()) |lowering| switch (lowering) {5412 while (try it.next()) |lowering| switch (lowering) {
...@@ -5444,13 +5414,13 @@ pub const FuncGen = struct {...@@ -5444,13 +5414,13 @@ pub const FuncGen = struct {
5444 const param_index = it.zig_index - 1;5414 const param_index = it.zig_index - 1;
5445 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[param_index]);5415 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[param_index]);
5446 if (!isByRef(param_ty, zcu)) {5416 if (!isByRef(param_ty, zcu)) {
5447 try o.addByValParamAttrs(&attributes, param_ty, param_index, fn_info, it.llvm_index - 1);5417 try o.addByValParamAttrs(pt, &attributes, param_ty, param_index, fn_info, it.llvm_index - 1);
5448 }5418 }
5449 },5419 },
5450 .byref => {5420 .byref => {
5451 const param_index = it.zig_index - 1;5421 const param_index = it.zig_index - 1;
5452 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[param_index]);5422 const param_ty = Type.fromInterned(fn_info.param_types.get(ip)[param_index]);
5453 const param_llvm_ty = try o.lowerType(param_ty);5423 const param_llvm_ty = try o.lowerType(pt, param_ty);
5454 const alignment = param_ty.abiAlignment(zcu).toLlvm();5424 const alignment = param_ty.abiAlignment(zcu).toLlvm();
5455 try o.addByRefParamAttrs(&attributes, it.llvm_index - 1, alignment, it.byval_attr, param_llvm_ty);5425 try o.addByRefParamAttrs(&attributes, it.llvm_index - 1, alignment, it.byval_attr, param_llvm_ty);
5456 },5426 },
...@@ -5502,7 +5472,7 @@ pub const FuncGen = struct {...@@ -5502,7 +5472,7 @@ pub const FuncGen = struct {
5502 },5472 },
5503 toLlvmCallConvTag(fn_info.cc, target).?,5473 toLlvmCallConvTag(fn_info.cc, target).?,
5504 try attributes.finish(&o.builder),5474 try attributes.finish(&o.builder),
5505 try o.lowerType(zig_fn_ty),5475 try o.lowerType(pt, zig_fn_ty),
5506 llvm_fn,5476 llvm_fn,
5507 llvm_args.items,5477 llvm_args.items,
5508 "",5478 "",
...@@ -5516,7 +5486,7 @@ pub const FuncGen = struct {...@@ -5516,7 +5486,7 @@ pub const FuncGen = struct {
5516 return .none;5486 return .none;
5517 }5487 }
55185488
5519 const llvm_ret_ty = try o.lowerType(return_type);5489 const llvm_ret_ty = try o.lowerType(pt, return_type);
5520 if (ret_ptr) |rp| {5490 if (ret_ptr) |rp| {
5521 if (isByRef(return_type, zcu)) {5491 if (isByRef(return_type, zcu)) {
5522 return rp;5492 return rp;
...@@ -5527,7 +5497,7 @@ pub const FuncGen = struct {...@@ -5527,7 +5497,7 @@ pub const FuncGen = struct {
5527 }5497 }
5528 }5498 }
55295499
5530 const abi_ret_ty = try lowerFnRetTy(o, fn_info);5500 const abi_ret_ty = try lowerFnRetTy(o, pt, fn_info);
55315501
5532 if (abi_ret_ty != llvm_ret_ty) {5502 if (abi_ret_ty != llvm_ret_ty) {
5533 // In this case the function return type is honoring the calling convention by having5503 // In this case the function return type is honoring the calling convention by having
...@@ -5556,11 +5526,12 @@ pub const FuncGen = struct {...@@ -5556,11 +5526,12 @@ pub const FuncGen = struct {
55565526
5557 fn buildSimplePanic(fg: *FuncGen, panic_id: Zcu.SimplePanicId) !void {5527 fn buildSimplePanic(fg: *FuncGen, panic_id: Zcu.SimplePanicId) !void {
5558 const o = fg.ng.object;5528 const o = fg.ng.object;
5559 const zcu = o.pt.zcu;5529 const pt = fg.ng.pt;
5530 const zcu = pt.zcu;
5560 const target = zcu.getTarget();5531 const target = zcu.getTarget();
5561 const panic_func = zcu.funcInfo(zcu.builtin_decl_values.get(panic_id.toBuiltin()));5532 const panic_func = zcu.funcInfo(zcu.builtin_decl_values.get(panic_id.toBuiltin()));
5562 const fn_info = zcu.typeToFunc(.fromInterned(panic_func.ty)).?;5533 const fn_info = zcu.typeToFunc(.fromInterned(panic_func.ty)).?;
5563 const panic_global = try o.resolveLlvmFunction(panic_func.owner_nav);5534 const panic_global = try o.resolveLlvmFunction(pt, panic_func.owner_nav);
55645535
5565 const has_err_trace = zcu.comp.config.any_error_tracing and fn_info.cc == .auto;5536 const has_err_trace = zcu.comp.config.any_error_tracing and fn_info.cc == .auto;
5566 if (has_err_trace) assert(fg.err_ret_trace != .none);5537 if (has_err_trace) assert(fg.err_ret_trace != .none);
...@@ -5579,7 +5550,7 @@ pub const FuncGen = struct {...@@ -5579,7 +5550,7 @@ pub const FuncGen = struct {
55795550
5580 fn airRet(self: *FuncGen, inst: Air.Inst.Index, safety: bool) !void {5551 fn airRet(self: *FuncGen, inst: Air.Inst.Index, safety: bool) !void {
5581 const o = self.ng.object;5552 const o = self.ng.object;
5582 const pt = o.pt;5553 const pt = self.ng.pt;
5583 const zcu = pt.zcu;5554 const zcu = pt.zcu;
5584 const ip = &zcu.intern_pool;5555 const ip = &zcu.intern_pool;
5585 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;5556 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;
...@@ -5599,7 +5570,7 @@ pub const FuncGen = struct {...@@ -5599,7 +5570,7 @@ pub const FuncGen = struct {
5599 // https://github.com/ziglang/zig/issues/153375570 // https://github.com/ziglang/zig/issues/15337
5600 break :undef;5571 break :undef;
5601 }5572 }
5602 const len = try o.builder.intValue(try o.lowerType(Type.usize), ret_ty.abiSize(zcu));5573 const len = try o.builder.intValue(try o.lowerType(pt, Type.usize), ret_ty.abiSize(zcu));
5603 _ = try self.wip.callMemSet(5574 _ = try self.wip.callMemSet(
5604 self.ret_ptr,5575 self.ret_ptr,
5605 ptr_ty.ptrAlignment(zcu).toLlvm(),5576 ptr_ty.ptrAlignment(zcu).toLlvm(),
...@@ -5635,14 +5606,14 @@ pub const FuncGen = struct {...@@ -5635,14 +5606,14 @@ pub const FuncGen = struct {
5635 // Functions with an empty error set are emitted with an error code5606 // Functions with an empty error set are emitted with an error code
5636 // return type and return zero so they can be function pointers coerced5607 // return type and return zero so they can be function pointers coerced
5637 // to functions that return anyerror.5608 // to functions that return anyerror.
5638 _ = try self.wip.ret(try o.builder.intValue(try o.errorIntType(), 0));5609 _ = try self.wip.ret(try o.builder.intValue(try o.errorIntType(pt), 0));
5639 } else {5610 } else {
5640 _ = try self.wip.retVoid();5611 _ = try self.wip.retVoid();
5641 }5612 }
5642 return;5613 return;
5643 }5614 }
56445615
5645 const abi_ret_ty = try lowerFnRetTy(o, fn_info);5616 const abi_ret_ty = try lowerFnRetTy(o, pt, fn_info);
5646 const operand = try self.resolveInst(un_op);5617 const operand = try self.resolveInst(un_op);
5647 const val_is_undef = if (try self.air.value(un_op, pt)) |val| val.isUndefDeep(zcu) else false;5618 const val_is_undef = if (try self.air.value(un_op, pt)) |val| val.isUndefDeep(zcu) else false;
5648 const alignment = ret_ty.abiAlignment(zcu).toLlvm();5619 const alignment = ret_ty.abiAlignment(zcu).toLlvm();
...@@ -5650,7 +5621,7 @@ pub const FuncGen = struct {...@@ -5650,7 +5621,7 @@ pub const FuncGen = struct {
5650 if (val_is_undef and safety) {5621 if (val_is_undef and safety) {
5651 const llvm_ret_ty = operand.typeOfWip(&self.wip);5622 const llvm_ret_ty = operand.typeOfWip(&self.wip);
5652 const rp = try self.buildAlloca(llvm_ret_ty, alignment);5623 const rp = try self.buildAlloca(llvm_ret_ty, alignment);
5653 const len = try o.builder.intValue(try o.lowerType(Type.usize), ret_ty.abiSize(zcu));5624 const len = try o.builder.intValue(try o.lowerType(pt, Type.usize), ret_ty.abiSize(zcu));
5654 _ = try self.wip.callMemSet(5625 _ = try self.wip.callMemSet(
5655 rp,5626 rp,
5656 alignment,5627 alignment,
...@@ -5688,7 +5659,7 @@ pub const FuncGen = struct {...@@ -5688,7 +5659,7 @@ pub const FuncGen = struct {
56885659
5689 fn airRetLoad(self: *FuncGen, inst: Air.Inst.Index) !void {5660 fn airRetLoad(self: *FuncGen, inst: Air.Inst.Index) !void {
5690 const o = self.ng.object;5661 const o = self.ng.object;
5691 const pt = o.pt;5662 const pt = self.ng.pt;
5692 const zcu = pt.zcu;5663 const zcu = pt.zcu;
5693 const ip = &zcu.intern_pool;5664 const ip = &zcu.intern_pool;
5694 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;5665 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;
...@@ -5700,7 +5671,7 @@ pub const FuncGen = struct {...@@ -5700,7 +5671,7 @@ pub const FuncGen = struct {
5700 // Functions with an empty error set are emitted with an error code5671 // Functions with an empty error set are emitted with an error code
5701 // return type and return zero so they can be function pointers coerced5672 // return type and return zero so they can be function pointers coerced
5702 // to functions that return anyerror.5673 // to functions that return anyerror.
5703 _ = try self.wip.ret(try o.builder.intValue(try o.errorIntType(), 0));5674 _ = try self.wip.ret(try o.builder.intValue(try o.errorIntType(pt), 0));
5704 } else {5675 } else {
5705 _ = try self.wip.retVoid();5676 _ = try self.wip.retVoid();
5706 }5677 }
...@@ -5711,7 +5682,7 @@ pub const FuncGen = struct {...@@ -5711,7 +5682,7 @@ pub const FuncGen = struct {
5711 return;5682 return;
5712 }5683 }
5713 const ptr = try self.resolveInst(un_op);5684 const ptr = try self.resolveInst(un_op);
5714 const abi_ret_ty = try lowerFnRetTy(o, fn_info);5685 const abi_ret_ty = try lowerFnRetTy(o, pt, fn_info);
5715 const alignment = ret_ty.abiAlignment(zcu).toLlvm();5686 const alignment = ret_ty.abiAlignment(zcu).toLlvm();
5716 _ = try self.wip.ret(try self.wip.load(.normal, abi_ret_ty, ptr, alignment, ""));5687 _ = try self.wip.ret(try self.wip.load(.normal, abi_ret_ty, ptr, alignment, ""));
5717 return;5688 return;
...@@ -5719,22 +5690,23 @@ pub const FuncGen = struct {...@@ -5719,22 +5690,23 @@ pub const FuncGen = struct {
57195690
5720 fn airCVaArg(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {5691 fn airCVaArg(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
5721 const o = self.ng.object;5692 const o = self.ng.object;
5693 const pt = self.ng.pt;
5722 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;5694 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
5723 const list = try self.resolveInst(ty_op.operand);5695 const list = try self.resolveInst(ty_op.operand);
5724 const arg_ty = ty_op.ty.toType();5696 const arg_ty = ty_op.ty.toType();
5725 const llvm_arg_ty = try o.lowerType(arg_ty);5697 const llvm_arg_ty = try o.lowerType(pt, arg_ty);
57265698
5727 return self.wip.vaArg(list, llvm_arg_ty, "");5699 return self.wip.vaArg(list, llvm_arg_ty, "");
5728 }5700 }
57295701
5730 fn airCVaCopy(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {5702 fn airCVaCopy(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
5731 const o = self.ng.object;5703 const o = self.ng.object;
5732 const pt = o.pt;5704 const pt = self.ng.pt;
5733 const zcu = pt.zcu;5705 const zcu = pt.zcu;
5734 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;5706 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
5735 const src_list = try self.resolveInst(ty_op.operand);5707 const src_list = try self.resolveInst(ty_op.operand);
5736 const va_list_ty = ty_op.ty.toType();5708 const va_list_ty = ty_op.ty.toType();
5737 const llvm_va_list_ty = try o.lowerType(va_list_ty);5709 const llvm_va_list_ty = try o.lowerType(pt, va_list_ty);
57385710
5739 const result_alignment = va_list_ty.abiAlignment(pt.zcu).toLlvm();5711 const result_alignment = va_list_ty.abiAlignment(pt.zcu).toLlvm();
5740 const dest_list = try self.buildAlloca(llvm_va_list_ty, result_alignment);5712 const dest_list = try self.buildAlloca(llvm_va_list_ty, result_alignment);
...@@ -5756,10 +5728,10 @@ pub const FuncGen = struct {...@@ -5756,10 +5728,10 @@ pub const FuncGen = struct {
57565728
5757 fn airCVaStart(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {5729 fn airCVaStart(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
5758 const o = self.ng.object;5730 const o = self.ng.object;
5759 const pt = o.pt;5731 const pt = self.ng.pt;
5760 const zcu = pt.zcu;5732 const zcu = pt.zcu;
5761 const va_list_ty = self.typeOfIndex(inst);5733 const va_list_ty = self.typeOfIndex(inst);
5762 const llvm_va_list_ty = try o.lowerType(va_list_ty);5734 const llvm_va_list_ty = try o.lowerType(pt, va_list_ty);
57635735
5764 const result_alignment = va_list_ty.abiAlignment(pt.zcu).toLlvm();5736 const result_alignment = va_list_ty.abiAlignment(pt.zcu).toLlvm();
5765 const dest_list = try self.buildAlloca(llvm_va_list_ty, result_alignment);5737 const dest_list = try self.buildAlloca(llvm_va_list_ty, result_alignment);
...@@ -5799,9 +5771,10 @@ pub const FuncGen = struct {...@@ -5799,9 +5771,10 @@ pub const FuncGen = struct {
57995771
5800 fn airCmpLtErrorsLen(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {5772 fn airCmpLtErrorsLen(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
5801 const o = self.ng.object;5773 const o = self.ng.object;
5774 const pt = self.ng.pt;
5802 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;5775 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;
5803 const operand = try self.resolveInst(un_op);5776 const operand = try self.resolveInst(un_op);
5804 const llvm_fn = try o.getCmpLtErrorsLenFunction();5777 const llvm_fn = try o.getCmpLtErrorsLenFunction(pt);
5805 return self.wip.call(5778 return self.wip.call(
5806 .normal,5779 .normal,
5807 .fastcc,5780 .fastcc,
...@@ -5822,7 +5795,7 @@ pub const FuncGen = struct {...@@ -5822,7 +5795,7 @@ pub const FuncGen = struct {
5822 rhs: Builder.Value,5795 rhs: Builder.Value,
5823 ) Allocator.Error!Builder.Value {5796 ) Allocator.Error!Builder.Value {
5824 const o = self.ng.object;5797 const o = self.ng.object;
5825 const pt = o.pt;5798 const pt = self.ng.pt;
5826 const zcu = pt.zcu;5799 const zcu = pt.zcu;
5827 const ip = &zcu.intern_pool;5800 const ip = &zcu.intern_pool;
5828 const scalar_ty = operand_ty.scalarType(zcu);5801 const scalar_ty = operand_ty.scalarType(zcu);
...@@ -5839,7 +5812,7 @@ pub const FuncGen = struct {...@@ -5839,7 +5812,7 @@ pub const FuncGen = struct {
5839 // We need to emit instructions to check for equality/inequality5812 // We need to emit instructions to check for equality/inequality
5840 // of optionals that are not pointers.5813 // of optionals that are not pointers.
5841 const is_by_ref = isByRef(scalar_ty, zcu);5814 const is_by_ref = isByRef(scalar_ty, zcu);
5842 const opt_llvm_ty = try o.lowerType(scalar_ty);5815 const opt_llvm_ty = try o.lowerType(pt, scalar_ty);
5843 const lhs_non_null = try self.optCmpNull(.ne, opt_llvm_ty, lhs, is_by_ref, .normal);5816 const lhs_non_null = try self.optCmpNull(.ne, opt_llvm_ty, lhs, is_by_ref, .normal);
5844 const rhs_non_null = try self.optCmpNull(.ne, opt_llvm_ty, rhs, is_by_ref, .normal);5817 const rhs_non_null = try self.optCmpNull(.ne, opt_llvm_ty, rhs, is_by_ref, .normal);
5845 const llvm_i2 = try o.builder.intType(2);5818 const llvm_i2 = try o.builder.intType(2);
...@@ -5936,7 +5909,7 @@ pub const FuncGen = struct {...@@ -5936,7 +5909,7 @@ pub const FuncGen = struct {
5936 body: []const Air.Inst.Index,5909 body: []const Air.Inst.Index,
5937 ) !Builder.Value {5910 ) !Builder.Value {
5938 const o = self.ng.object;5911 const o = self.ng.object;
5939 const pt = o.pt;5912 const pt = self.ng.pt;
5940 const zcu = pt.zcu;5913 const zcu = pt.zcu;
5941 const inst_ty = self.typeOfIndex(inst);5914 const inst_ty = self.typeOfIndex(inst);
59425915
...@@ -5963,7 +5936,7 @@ pub const FuncGen = struct {...@@ -5963,7 +5936,7 @@ pub const FuncGen = struct {
59635936
5964 // Create a phi node only if the block returns a value.5937 // Create a phi node only if the block returns a value.
5965 if (have_block_result) {5938 if (have_block_result) {
5966 const raw_llvm_ty = try o.lowerType(inst_ty);5939 const raw_llvm_ty = try o.lowerType(pt, inst_ty);
5967 const llvm_ty: Builder.Type = ty: {5940 const llvm_ty: Builder.Type = ty: {
5968 // If the zig tag type is a function, this represents an actual function body; not5941 // If the zig tag type is a function, this represents an actual function body; not
5969 // a pointer to it. LLVM IR allows the call instruction to use function bodies instead5942 // a pointer to it. LLVM IR allows the call instruction to use function bodies instead
...@@ -5986,8 +5959,7 @@ pub const FuncGen = struct {...@@ -5986,8 +5959,7 @@ pub const FuncGen = struct {
5986 }5959 }
59875960
5988 fn airBr(self: *FuncGen, inst: Air.Inst.Index) !void {5961 fn airBr(self: *FuncGen, inst: Air.Inst.Index) !void {
5989 const o = self.ng.object;5962 const zcu = self.ng.pt.zcu;
5990 const zcu = o.pt.zcu;
5991 const branch = self.air.instructions.items(.data)[@intFromEnum(inst)].br;5963 const branch = self.air.instructions.items(.data)[@intFromEnum(inst)].br;
5992 const block = self.blocks.get(branch.block_inst).?;5964 const block = self.blocks.get(branch.block_inst).?;
59935965
...@@ -6017,7 +5989,7 @@ pub const FuncGen = struct {...@@ -6017,7 +5989,7 @@ pub const FuncGen = struct {
6017 dispatch_info: SwitchDispatchInfo,5989 dispatch_info: SwitchDispatchInfo,
6018 ) !void {5990 ) !void {
6019 const o = self.ng.object;5991 const o = self.ng.object;
6020 const pt = o.pt;5992 const pt = self.ng.pt;
6021 const zcu = pt.zcu;5993 const zcu = pt.zcu;
6022 const cond_ty = self.typeOf(cond_ref);5994 const cond_ty = self.typeOf(cond_ref);
6023 const switch_br = self.air.unwrapSwitch(switch_inst);5995 const switch_br = self.air.unwrapSwitch(switch_inst);
...@@ -6081,7 +6053,7 @@ pub const FuncGen = struct {...@@ -6081,7 +6053,7 @@ pub const FuncGen = struct {
6081 const table_index = try self.wip.cast(6053 const table_index = try self.wip.cast(
6082 .zext,6054 .zext,
6083 try self.wip.bin(.@"sub nuw", cond, jmp_table.min.toValue(), ""),6055 try self.wip.bin(.@"sub nuw", cond, jmp_table.min.toValue(), ""),
6084 try o.lowerType(Type.usize),6056 try o.lowerType(pt, Type.usize),
6085 "",6057 "",
6086 );6058 );
6087 const target_ptr_ptr = try self.wip.gep(6059 const target_ptr_ptr = try self.wip.gep(
...@@ -6108,7 +6080,7 @@ pub const FuncGen = struct {...@@ -6108,7 +6080,7 @@ pub const FuncGen = struct {
6108 // The switch prongs will correspond to our scalar cases. Ranges will6080 // The switch prongs will correspond to our scalar cases. Ranges will
6109 // be handled by conditional branches in the `else` prong.6081 // be handled by conditional branches in the `else` prong.
61106082
6111 const llvm_usize = try o.lowerType(Type.usize);6083 const llvm_usize = try o.lowerType(pt, Type.usize);
6112 const cond_int = if (cond.typeOfWip(&self.wip).isPointer(&o.builder))6084 const cond_int = if (cond.typeOfWip(&self.wip).isPointer(&o.builder))
6113 try self.wip.cast(.ptrtoint, cond, llvm_usize, "")6085 try self.wip.cast(.ptrtoint, cond, llvm_usize, "")
6114 else6086 else
...@@ -6268,8 +6240,7 @@ pub const FuncGen = struct {...@@ -6268,8 +6240,7 @@ pub const FuncGen = struct {
6268 }6240 }
62696241
6270 fn airTry(self: *FuncGen, body_tail: []const Air.Inst.Index, err_cold: bool) !Builder.Value {6242 fn airTry(self: *FuncGen, body_tail: []const Air.Inst.Index, err_cold: bool) !Builder.Value {
6271 const o = self.ng.object;6243 const pt = self.ng.pt;
6272 const pt = o.pt;
6273 const zcu = pt.zcu;6244 const zcu = pt.zcu;
6274 const inst = body_tail[0];6245 const inst = body_tail[0];
6275 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;6246 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
...@@ -6284,8 +6255,7 @@ pub const FuncGen = struct {...@@ -6284,8 +6255,7 @@ pub const FuncGen = struct {
6284 }6255 }
62856256
6286 fn airTryPtr(self: *FuncGen, inst: Air.Inst.Index, err_cold: bool) !Builder.Value {6257 fn airTryPtr(self: *FuncGen, inst: Air.Inst.Index, err_cold: bool) !Builder.Value {
6287 const o = self.ng.object;6258 const zcu = self.ng.pt.zcu;
6288 const zcu = o.pt.zcu;
6289 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;6259 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
6290 const extra = self.air.extraData(Air.TryPtr, ty_pl.payload);6260 const extra = self.air.extraData(Air.TryPtr, ty_pl.payload);
6291 const err_union_ptr = try self.resolveInst(extra.data.ptr);6261 const err_union_ptr = try self.resolveInst(extra.data.ptr);
...@@ -6309,12 +6279,12 @@ pub const FuncGen = struct {...@@ -6309,12 +6279,12 @@ pub const FuncGen = struct {
6309 err_cold: bool,6279 err_cold: bool,
6310 ) !Builder.Value {6280 ) !Builder.Value {
6311 const o = fg.ng.object;6281 const o = fg.ng.object;
6312 const pt = o.pt;6282 const pt = fg.ng.pt;
6313 const zcu = pt.zcu;6283 const zcu = pt.zcu;
6314 const payload_ty = err_union_ty.errorUnionPayload(zcu);6284 const payload_ty = err_union_ty.errorUnionPayload(zcu);
6315 const payload_has_bits = payload_ty.hasRuntimeBitsIgnoreComptime(zcu);6285 const payload_has_bits = payload_ty.hasRuntimeBitsIgnoreComptime(zcu);
6316 const err_union_llvm_ty = try o.lowerType(err_union_ty);6286 const err_union_llvm_ty = try o.lowerType(pt, err_union_ty);
6317 const error_type = try o.errorIntType();6287 const error_type = try o.errorIntType(pt);
63186288
6319 if (!err_union_ty.errorUnionSet(zcu).errorSetIsEmpty(zcu)) {6289 if (!err_union_ty.errorUnionSet(zcu).errorSetIsEmpty(zcu)) {
6320 const loaded = loaded: {6290 const loaded = loaded: {
...@@ -6378,7 +6348,8 @@ pub const FuncGen = struct {...@@ -6378,7 +6348,8 @@ pub const FuncGen = struct {
63786348
6379 fn airSwitchBr(self: *FuncGen, inst: Air.Inst.Index, is_dispatch_loop: bool) !void {6349 fn airSwitchBr(self: *FuncGen, inst: Air.Inst.Index, is_dispatch_loop: bool) !void {
6380 const o = self.ng.object;6350 const o = self.ng.object;
6381 const zcu = o.pt.zcu;6351 const pt = self.ng.pt;
6352 const zcu = pt.zcu;
63826353
6383 const switch_br = self.air.unwrapSwitch(inst);6354 const switch_br = self.air.unwrapSwitch(inst);
63846355
...@@ -6483,8 +6454,8 @@ pub const FuncGen = struct {...@@ -6483,8 +6454,8 @@ pub const FuncGen = struct {
6483 const table_includes_else = item_count != table_len;6454 const table_includes_else = item_count != table_len;
64846455
6485 break :jmp_table .{6456 break :jmp_table .{
6486 .min = try o.lowerValue(min.toIntern()),6457 .min = try o.lowerValue(pt, min.toIntern()),
6487 .max = try o.lowerValue(max.toIntern()),6458 .max = try o.lowerValue(pt, max.toIntern()),
6488 .in_bounds_hint = if (table_includes_else) .none else switch (switch_br.getElseHint()) {6459 .in_bounds_hint = if (table_includes_else) .none else switch (switch_br.getElseHint()) {
6489 .none, .cold => .none,6460 .none, .cold => .none,
6490 .unpredictable => .unpredictable,6461 .unpredictable => .unpredictable,
...@@ -6591,7 +6562,7 @@ pub const FuncGen = struct {...@@ -6591,7 +6562,7 @@ pub const FuncGen = struct {
6591 }6562 }
65926563
6593 fn switchCaseItemRange(self: *FuncGen, switch_br: Air.UnwrappedSwitch) [2]Value {6564 fn switchCaseItemRange(self: *FuncGen, switch_br: Air.UnwrappedSwitch) [2]Value {
6594 const zcu = self.ng.object.pt.zcu;6565 const zcu = self.ng.pt.zcu;
6595 var it = switch_br.iterateCases();6566 var it = switch_br.iterateCases();
6596 var min: ?Value = null;6567 var min: ?Value = null;
6597 var max: ?Value = null;6568 var max: ?Value = null;
...@@ -6633,18 +6604,18 @@ pub const FuncGen = struct {...@@ -6633,18 +6604,18 @@ pub const FuncGen = struct {
66336604
6634 fn airArrayToSlice(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {6605 fn airArrayToSlice(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
6635 const o = self.ng.object;6606 const o = self.ng.object;
6636 const pt = o.pt;6607 const pt = self.ng.pt;
6637 const zcu = pt.zcu;6608 const zcu = pt.zcu;
6638 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;6609 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
6639 const operand_ty = self.typeOf(ty_op.operand);6610 const operand_ty = self.typeOf(ty_op.operand);
6640 const array_ty = operand_ty.childType(zcu);6611 const array_ty = operand_ty.childType(zcu);
6641 const llvm_usize = try o.lowerType(Type.usize);6612 const llvm_usize = try o.lowerType(pt, Type.usize);
6642 const len = try o.builder.intValue(llvm_usize, array_ty.arrayLen(zcu));6613 const len = try o.builder.intValue(llvm_usize, array_ty.arrayLen(zcu));
6643 const slice_llvm_ty = try o.lowerType(self.typeOfIndex(inst));6614 const slice_llvm_ty = try o.lowerType(pt, self.typeOfIndex(inst));
6644 const operand = try self.resolveInst(ty_op.operand);6615 const operand = try self.resolveInst(ty_op.operand);
6645 if (!array_ty.hasRuntimeBitsIgnoreComptime(zcu))6616 if (!array_ty.hasRuntimeBitsIgnoreComptime(zcu))
6646 return self.wip.buildAggregate(slice_llvm_ty, &.{ operand, len }, "");6617 return self.wip.buildAggregate(slice_llvm_ty, &.{ operand, len }, "");
6647 const ptr = try self.wip.gep(.inbounds, try o.lowerType(array_ty), operand, &.{6618 const ptr = try self.wip.gep(.inbounds, try o.lowerType(pt, array_ty), operand, &.{
6648 try o.builder.intValue(llvm_usize, 0), try o.builder.intValue(llvm_usize, 0),6619 try o.builder.intValue(llvm_usize, 0), try o.builder.intValue(llvm_usize, 0),
6649 }, "");6620 }, "");
6650 return self.wip.buildAggregate(slice_llvm_ty, &.{ ptr, len }, "");6621 return self.wip.buildAggregate(slice_llvm_ty, &.{ ptr, len }, "");
...@@ -6652,7 +6623,7 @@ pub const FuncGen = struct {...@@ -6652,7 +6623,7 @@ pub const FuncGen = struct {
66526623
6653 fn airFloatFromInt(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {6624 fn airFloatFromInt(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
6654 const o = self.ng.object;6625 const o = self.ng.object;
6655 const pt = o.pt;6626 const pt = self.ng.pt;
6656 const zcu = pt.zcu;6627 const zcu = pt.zcu;
6657 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;6628 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
66586629
...@@ -6663,7 +6634,7 @@ pub const FuncGen = struct {...@@ -6663,7 +6634,7 @@ pub const FuncGen = struct {
66636634
6664 const dest_ty = self.typeOfIndex(inst);6635 const dest_ty = self.typeOfIndex(inst);
6665 const dest_scalar_ty = dest_ty.scalarType(zcu);6636 const dest_scalar_ty = dest_ty.scalarType(zcu);
6666 const dest_llvm_ty = try o.lowerType(dest_ty);6637 const dest_llvm_ty = try o.lowerType(pt, dest_ty);
6667 const target = zcu.getTarget();6638 const target = zcu.getTarget();
66686639
6669 if (intrinsicsAllowed(dest_scalar_ty, target)) return self.wip.conv(6640 if (intrinsicsAllowed(dest_scalar_ty, target)) return self.wip.conv(
...@@ -6719,7 +6690,7 @@ pub const FuncGen = struct {...@@ -6719,7 +6690,7 @@ pub const FuncGen = struct {
6719 _ = fast;6690 _ = fast;
67206691
6721 const o = self.ng.object;6692 const o = self.ng.object;
6722 const pt = o.pt;6693 const pt = self.ng.pt;
6723 const zcu = pt.zcu;6694 const zcu = pt.zcu;
6724 const target = zcu.getTarget();6695 const target = zcu.getTarget();
6725 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;6696 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
...@@ -6730,7 +6701,7 @@ pub const FuncGen = struct {...@@ -6730,7 +6701,7 @@ pub const FuncGen = struct {
67306701
6731 const dest_ty = self.typeOfIndex(inst);6702 const dest_ty = self.typeOfIndex(inst);
6732 const dest_scalar_ty = dest_ty.scalarType(zcu);6703 const dest_scalar_ty = dest_ty.scalarType(zcu);
6733 const dest_llvm_ty = try o.lowerType(dest_ty);6704 const dest_llvm_ty = try o.lowerType(pt, dest_ty);
67346705
6735 if (intrinsicsAllowed(operand_scalar_ty, target)) {6706 if (intrinsicsAllowed(operand_scalar_ty, target)) {
6736 // TODO set fast math flag6707 // TODO set fast math flag
...@@ -6762,7 +6733,7 @@ pub const FuncGen = struct {...@@ -6762,7 +6733,7 @@ pub const FuncGen = struct {
6762 compiler_rt_dest_abbrev,6733 compiler_rt_dest_abbrev,
6763 });6734 });
67646735
6765 const operand_llvm_ty = try o.lowerType(operand_ty);6736 const operand_llvm_ty = try o.lowerType(pt, operand_ty);
6766 const libc_fn = try self.getLibcFunction(fn_name, &.{operand_llvm_ty}, libc_ret_ty);6737 const libc_fn = try self.getLibcFunction(fn_name, &.{operand_llvm_ty}, libc_ret_ty);
6767 var result = try self.wip.call(6738 var result = try self.wip.call(
6768 .normal,6739 .normal,
...@@ -6780,16 +6751,15 @@ pub const FuncGen = struct {...@@ -6780,16 +6751,15 @@ pub const FuncGen = struct {
6780 }6751 }
67816752
6782 fn sliceOrArrayPtr(fg: *FuncGen, ptr: Builder.Value, ty: Type) Allocator.Error!Builder.Value {6753 fn sliceOrArrayPtr(fg: *FuncGen, ptr: Builder.Value, ty: Type) Allocator.Error!Builder.Value {
6783 const o = fg.ng.object;6754 const zcu = fg.ng.pt.zcu;
6784 const zcu = o.pt.zcu;
6785 return if (ty.isSlice(zcu)) fg.wip.extractValue(ptr, &.{0}, "") else ptr;6755 return if (ty.isSlice(zcu)) fg.wip.extractValue(ptr, &.{0}, "") else ptr;
6786 }6756 }
67876757
6788 fn sliceOrArrayLenInBytes(fg: *FuncGen, ptr: Builder.Value, ty: Type) Allocator.Error!Builder.Value {6758 fn sliceOrArrayLenInBytes(fg: *FuncGen, ptr: Builder.Value, ty: Type) Allocator.Error!Builder.Value {
6789 const o = fg.ng.object;6759 const o = fg.ng.object;
6790 const pt = o.pt;6760 const pt = fg.ng.pt;
6791 const zcu = pt.zcu;6761 const zcu = pt.zcu;
6792 const llvm_usize = try o.lowerType(Type.usize);6762 const llvm_usize = try o.lowerType(pt, Type.usize);
6793 switch (ty.ptrSize(zcu)) {6763 switch (ty.ptrSize(zcu)) {
6794 .slice => {6764 .slice => {
6795 const len = try fg.wip.extractValue(ptr, &.{1}, "");6765 const len = try fg.wip.extractValue(ptr, &.{1}, "");
...@@ -6817,18 +6787,19 @@ pub const FuncGen = struct {...@@ -6817,18 +6787,19 @@ pub const FuncGen = struct {
68176787
6818 fn airPtrSliceFieldPtr(self: *FuncGen, inst: Air.Inst.Index, index: c_uint) !Builder.Value {6788 fn airPtrSliceFieldPtr(self: *FuncGen, inst: Air.Inst.Index, index: c_uint) !Builder.Value {
6819 const o = self.ng.object;6789 const o = self.ng.object;
6820 const zcu = o.pt.zcu;6790 const pt = self.ng.pt;
6791 const zcu = pt.zcu;
6821 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;6792 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
6822 const slice_ptr = try self.resolveInst(ty_op.operand);6793 const slice_ptr = try self.resolveInst(ty_op.operand);
6823 const slice_ptr_ty = self.typeOf(ty_op.operand);6794 const slice_ptr_ty = self.typeOf(ty_op.operand);
6824 const slice_llvm_ty = try o.lowerPtrElemTy(slice_ptr_ty.childType(zcu));6795 const slice_llvm_ty = try o.lowerPtrElemTy(pt, slice_ptr_ty.childType(zcu));
68256796
6826 return self.wip.gepStruct(slice_llvm_ty, slice_ptr, index, "");6797 return self.wip.gepStruct(slice_llvm_ty, slice_ptr, index, "");
6827 }6798 }
68286799
6829 fn airSliceElemVal(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {6800 fn airSliceElemVal(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {
6830 const o = self.ng.object;6801 const o = self.ng.object;
6831 const pt = o.pt;6802 const pt = self.ng.pt;
6832 const zcu = pt.zcu;6803 const zcu = pt.zcu;
6833 const inst = body_tail[0];6804 const inst = body_tail[0];
6834 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;6805 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
...@@ -6836,7 +6807,7 @@ pub const FuncGen = struct {...@@ -6836,7 +6807,7 @@ pub const FuncGen = struct {
6836 const slice = try self.resolveInst(bin_op.lhs);6807 const slice = try self.resolveInst(bin_op.lhs);
6837 const index = try self.resolveInst(bin_op.rhs);6808 const index = try self.resolveInst(bin_op.rhs);
6838 const elem_ty = slice_ty.childType(zcu);6809 const elem_ty = slice_ty.childType(zcu);
6839 const llvm_elem_ty = try o.lowerPtrElemTy(elem_ty);6810 const llvm_elem_ty = try o.lowerPtrElemTy(pt, elem_ty);
6840 const base_ptr = try self.wip.extractValue(slice, &.{0}, "");6811 const base_ptr = try self.wip.extractValue(slice, &.{0}, "");
6841 const ptr = try self.wip.gep(.inbounds, llvm_elem_ty, base_ptr, &.{index}, "");6812 const ptr = try self.wip.gep(.inbounds, llvm_elem_ty, base_ptr, &.{index}, "");
6842 if (isByRef(elem_ty, zcu)) {6813 if (isByRef(elem_ty, zcu)) {
...@@ -6856,21 +6827,22 @@ pub const FuncGen = struct {...@@ -6856,21 +6827,22 @@ pub const FuncGen = struct {
68566827
6857 fn airSliceElemPtr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {6828 fn airSliceElemPtr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
6858 const o = self.ng.object;6829 const o = self.ng.object;
6859 const zcu = o.pt.zcu;6830 const pt = self.ng.pt;
6831 const zcu = pt.zcu;
6860 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;6832 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
6861 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;6833 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;
6862 const slice_ty = self.typeOf(bin_op.lhs);6834 const slice_ty = self.typeOf(bin_op.lhs);
68636835
6864 const slice = try self.resolveInst(bin_op.lhs);6836 const slice = try self.resolveInst(bin_op.lhs);
6865 const index = try self.resolveInst(bin_op.rhs);6837 const index = try self.resolveInst(bin_op.rhs);
6866 const llvm_elem_ty = try o.lowerPtrElemTy(slice_ty.childType(zcu));6838 const llvm_elem_ty = try o.lowerPtrElemTy(pt, slice_ty.childType(zcu));
6867 const base_ptr = try self.wip.extractValue(slice, &.{0}, "");6839 const base_ptr = try self.wip.extractValue(slice, &.{0}, "");
6868 return self.wip.gep(.inbounds, llvm_elem_ty, base_ptr, &.{index}, "");6840 return self.wip.gep(.inbounds, llvm_elem_ty, base_ptr, &.{index}, "");
6869 }6841 }
68706842
6871 fn airArrayElemVal(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {6843 fn airArrayElemVal(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {
6872 const o = self.ng.object;6844 const o = self.ng.object;
6873 const pt = o.pt;6845 const pt = self.ng.pt;
6874 const zcu = pt.zcu;6846 const zcu = pt.zcu;
6875 const inst = body_tail[0];6847 const inst = body_tail[0];
68766848
...@@ -6878,11 +6850,11 @@ pub const FuncGen = struct {...@@ -6878,11 +6850,11 @@ pub const FuncGen = struct {
6878 const array_ty = self.typeOf(bin_op.lhs);6850 const array_ty = self.typeOf(bin_op.lhs);
6879 const array_llvm_val = try self.resolveInst(bin_op.lhs);6851 const array_llvm_val = try self.resolveInst(bin_op.lhs);
6880 const rhs = try self.resolveInst(bin_op.rhs);6852 const rhs = try self.resolveInst(bin_op.rhs);
6881 const array_llvm_ty = try o.lowerType(array_ty);6853 const array_llvm_ty = try o.lowerType(pt, array_ty);
6882 const elem_ty = array_ty.childType(zcu);6854 const elem_ty = array_ty.childType(zcu);
6883 if (isByRef(array_ty, zcu)) {6855 if (isByRef(array_ty, zcu)) {
6884 const indices: [2]Builder.Value = .{6856 const indices: [2]Builder.Value = .{
6885 try o.builder.intValue(try o.lowerType(Type.usize), 0), rhs,6857 try o.builder.intValue(try o.lowerType(pt, Type.usize), 0), rhs,
6886 };6858 };
6887 if (isByRef(elem_ty, zcu)) {6859 if (isByRef(elem_ty, zcu)) {
6888 const elem_ptr =6860 const elem_ptr =
...@@ -6903,19 +6875,19 @@ pub const FuncGen = struct {...@@ -6903,19 +6875,19 @@ pub const FuncGen = struct {
69036875
6904 fn airPtrElemVal(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {6876 fn airPtrElemVal(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {
6905 const o = self.ng.object;6877 const o = self.ng.object;
6906 const pt = o.pt;6878 const pt = self.ng.pt;
6907 const zcu = pt.zcu;6879 const zcu = pt.zcu;
6908 const inst = body_tail[0];6880 const inst = body_tail[0];
6909 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;6881 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
6910 const ptr_ty = self.typeOf(bin_op.lhs);6882 const ptr_ty = self.typeOf(bin_op.lhs);
6911 const elem_ty = ptr_ty.childType(zcu);6883 const elem_ty = ptr_ty.childType(zcu);
6912 const llvm_elem_ty = try o.lowerPtrElemTy(elem_ty);6884 const llvm_elem_ty = try o.lowerPtrElemTy(pt, elem_ty);
6913 const base_ptr = try self.resolveInst(bin_op.lhs);6885 const base_ptr = try self.resolveInst(bin_op.lhs);
6914 const rhs = try self.resolveInst(bin_op.rhs);6886 const rhs = try self.resolveInst(bin_op.rhs);
6915 // TODO: when we go fully opaque pointers in LLVM 16 we can remove this branch6887 // TODO: when we go fully opaque pointers in LLVM 16 we can remove this branch
6916 const ptr = try self.wip.gep(.inbounds, llvm_elem_ty, base_ptr, if (ptr_ty.isSinglePointer(zcu))6888 const ptr = try self.wip.gep(.inbounds, llvm_elem_ty, base_ptr, if (ptr_ty.isSinglePointer(zcu))
6917 // If this is a single-item pointer to an array, we need another index in the GEP.6889 // If this is a single-item pointer to an array, we need another index in the GEP.
6918 &.{ try o.builder.intValue(try o.lowerType(Type.usize), 0), rhs }6890 &.{ try o.builder.intValue(try o.lowerType(pt, Type.usize), 0), rhs }
6919 else6891 else
6920 &.{rhs}, "");6892 &.{rhs}, "");
6921 if (isByRef(elem_ty, zcu)) {6893 if (isByRef(elem_ty, zcu)) {
...@@ -6934,7 +6906,7 @@ pub const FuncGen = struct {...@@ -6934,7 +6906,7 @@ pub const FuncGen = struct {
69346906
6935 fn airPtrElemPtr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {6907 fn airPtrElemPtr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
6936 const o = self.ng.object;6908 const o = self.ng.object;
6937 const pt = o.pt;6909 const pt = self.ng.pt;
6938 const zcu = pt.zcu;6910 const zcu = pt.zcu;
6939 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;6911 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
6940 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;6912 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;
...@@ -6948,10 +6920,10 @@ pub const FuncGen = struct {...@@ -6948,10 +6920,10 @@ pub const FuncGen = struct {
6948 const elem_ptr = ty_pl.ty.toType();6920 const elem_ptr = ty_pl.ty.toType();
6949 if (elem_ptr.ptrInfo(zcu).flags.vector_index != .none) return base_ptr;6921 if (elem_ptr.ptrInfo(zcu).flags.vector_index != .none) return base_ptr;
69506922
6951 const llvm_elem_ty = try o.lowerPtrElemTy(elem_ty);6923 const llvm_elem_ty = try o.lowerPtrElemTy(pt, elem_ty);
6952 return self.wip.gep(.inbounds, llvm_elem_ty, base_ptr, if (ptr_ty.isSinglePointer(zcu))6924 return self.wip.gep(.inbounds, llvm_elem_ty, base_ptr, if (ptr_ty.isSinglePointer(zcu))
6953 // If this is a single-item pointer to an array, we need another index in the GEP.6925 // If this is a single-item pointer to an array, we need another index in the GEP.
6954 &.{ try o.builder.intValue(try o.lowerType(Type.usize), 0), rhs }6926 &.{ try o.builder.intValue(try o.lowerType(pt, Type.usize), 0), rhs }
6955 else6927 else
6956 &.{rhs}, "");6928 &.{rhs}, "");
6957 }6929 }
...@@ -6977,7 +6949,7 @@ pub const FuncGen = struct {...@@ -6977,7 +6949,7 @@ pub const FuncGen = struct {
69776949
6978 fn airStructFieldVal(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {6950 fn airStructFieldVal(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {
6979 const o = self.ng.object;6951 const o = self.ng.object;
6980 const pt = o.pt;6952 const pt = self.ng.pt;
6981 const zcu = pt.zcu;6953 const zcu = pt.zcu;
6982 const inst = body_tail[0];6954 const inst = body_tail[0];
6983 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;6955 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
...@@ -6999,7 +6971,7 @@ pub const FuncGen = struct {...@@ -6999,7 +6971,7 @@ pub const FuncGen = struct {
6999 const shift_amt =6971 const shift_amt =
7000 try o.builder.intValue(containing_int.typeOfWip(&self.wip), bit_offset);6972 try o.builder.intValue(containing_int.typeOfWip(&self.wip), bit_offset);
7001 const shifted_value = try self.wip.bin(.lshr, containing_int, shift_amt, "");6973 const shifted_value = try self.wip.bin(.lshr, containing_int, shift_amt, "");
7002 const elem_llvm_ty = try o.lowerType(field_ty);6974 const elem_llvm_ty = try o.lowerType(pt, field_ty);
7003 if (field_ty.zigTypeTag(zcu) == .float or field_ty.zigTypeTag(zcu) == .vector) {6975 if (field_ty.zigTypeTag(zcu) == .float or field_ty.zigTypeTag(zcu) == .vector) {
7004 const same_size_int = try o.builder.intType(@intCast(field_ty.bitSize(zcu)));6976 const same_size_int = try o.builder.intType(@intCast(field_ty.bitSize(zcu)));
7005 const truncated_int =6977 const truncated_int =
...@@ -7021,7 +6993,7 @@ pub const FuncGen = struct {...@@ -7021,7 +6993,7 @@ pub const FuncGen = struct {
7021 .@"union" => {6993 .@"union" => {
7022 assert(struct_ty.containerLayout(zcu) == .@"packed");6994 assert(struct_ty.containerLayout(zcu) == .@"packed");
7023 const containing_int = struct_llvm_val;6995 const containing_int = struct_llvm_val;
7024 const elem_llvm_ty = try o.lowerType(field_ty);6996 const elem_llvm_ty = try o.lowerType(pt, field_ty);
7025 if (field_ty.zigTypeTag(zcu) == .float or field_ty.zigTypeTag(zcu) == .vector) {6997 if (field_ty.zigTypeTag(zcu) == .float or field_ty.zigTypeTag(zcu) == .vector) {
7026 const same_size_int = try o.builder.intType(@intCast(field_ty.bitSize(zcu)));6998 const same_size_int = try o.builder.intType(@intCast(field_ty.bitSize(zcu)));
7027 const truncated_int =6999 const truncated_int =
...@@ -7043,7 +7015,7 @@ pub const FuncGen = struct {...@@ -7043,7 +7015,7 @@ pub const FuncGen = struct {
7043 .@"struct" => {7015 .@"struct" => {
7044 const layout = struct_ty.containerLayout(zcu);7016 const layout = struct_ty.containerLayout(zcu);
7045 assert(layout != .@"packed");7017 assert(layout != .@"packed");
7046 const struct_llvm_ty = try o.lowerType(struct_ty);7018 const struct_llvm_ty = try o.lowerType(pt, struct_ty);
7047 const llvm_field_index = o.llvmFieldIndex(struct_ty, field_index).?;7019 const llvm_field_index = o.llvmFieldIndex(struct_ty, field_index).?;
7048 const field_ptr =7020 const field_ptr =
7049 try self.wip.gepStruct(struct_llvm_ty, struct_llvm_val, llvm_field_index, "");7021 try self.wip.gepStruct(struct_llvm_ty, struct_llvm_val, llvm_field_index, "");
...@@ -7064,7 +7036,7 @@ pub const FuncGen = struct {...@@ -7064,7 +7036,7 @@ pub const FuncGen = struct {
7064 }7036 }
7065 },7037 },
7066 .@"union" => {7038 .@"union" => {
7067 const union_llvm_ty = try o.lowerType(struct_ty);7039 const union_llvm_ty = try o.lowerType(pt, struct_ty);
7068 const layout = struct_ty.unionGetLayout(zcu);7040 const layout = struct_ty.unionGetLayout(zcu);
7069 const payload_index = @intFromBool(layout.tag_align.compare(.gte, layout.payload_align));7041 const payload_index = @intFromBool(layout.tag_align.compare(.gte, layout.payload_align));
7070 const field_ptr =7042 const field_ptr =
...@@ -7083,7 +7055,7 @@ pub const FuncGen = struct {...@@ -7083,7 +7055,7 @@ pub const FuncGen = struct {
70837055
7084 fn airFieldParentPtr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {7056 fn airFieldParentPtr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
7085 const o = self.ng.object;7057 const o = self.ng.object;
7086 const pt = o.pt;7058 const pt = self.ng.pt;
7087 const zcu = pt.zcu;7059 const zcu = pt.zcu;
7088 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;7060 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
7089 const extra = self.air.extraData(Air.FieldParentPtr, ty_pl.payload).data;7061 const extra = self.air.extraData(Air.FieldParentPtr, ty_pl.payload).data;
...@@ -7094,8 +7066,8 @@ pub const FuncGen = struct {...@@ -7094,8 +7066,8 @@ pub const FuncGen = struct {
7094 const field_offset = parent_ty.structFieldOffset(extra.field_index, zcu);7066 const field_offset = parent_ty.structFieldOffset(extra.field_index, zcu);
7095 if (field_offset == 0) return field_ptr;7067 if (field_offset == 0) return field_ptr;
70967068
7097 const res_ty = try o.lowerType(ty_pl.ty.toType());7069 const res_ty = try o.lowerType(pt, ty_pl.ty.toType());
7098 const llvm_usize = try o.lowerType(Type.usize);7070 const llvm_usize = try o.lowerType(pt, Type.usize);
70997071
7100 const field_ptr_int = try self.wip.cast(.ptrtoint, field_ptr, llvm_usize, "");7072 const field_ptr_int = try self.wip.cast(.ptrtoint, field_ptr, llvm_usize, "");
7101 const base_ptr_int = try self.wip.bin(7073 const base_ptr_int = try self.wip.bin(
...@@ -7151,7 +7123,8 @@ pub const FuncGen = struct {...@@ -7151,7 +7123,8 @@ pub const FuncGen = struct {
71517123
7152 fn airDbgVarPtr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {7124 fn airDbgVarPtr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
7153 const o = self.ng.object;7125 const o = self.ng.object;
7154 const zcu = o.pt.zcu;7126 const pt = self.ng.pt;
7127 const zcu = pt.zcu;
7155 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;7128 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
7156 const operand = try self.resolveInst(pl_op.operand);7129 const operand = try self.resolveInst(pl_op.operand);
7157 const name: Air.NullTerminatedString = @enumFromInt(pl_op.payload);7130 const name: Air.NullTerminatedString = @enumFromInt(pl_op.payload);
...@@ -7162,7 +7135,7 @@ pub const FuncGen = struct {...@@ -7162,7 +7135,7 @@ pub const FuncGen = struct {
7162 self.file,7135 self.file,
7163 self.scope,7136 self.scope,
7164 self.prev_dbg_line,7137 self.prev_dbg_line,
7165 try o.lowerDebugType(ptr_ty.childType(zcu)),7138 try o.lowerDebugType(pt, ptr_ty.childType(zcu)),
7166 );7139 );
71677140
7168 _ = try self.wip.callIntrinsic(7141 _ = try self.wip.callIntrinsic(
...@@ -7183,6 +7156,7 @@ pub const FuncGen = struct {...@@ -7183,6 +7156,7 @@ pub const FuncGen = struct {
71837156
7184 fn airDbgVarVal(self: *FuncGen, inst: Air.Inst.Index, is_arg: bool) !Builder.Value {7157 fn airDbgVarVal(self: *FuncGen, inst: Air.Inst.Index, is_arg: bool) !Builder.Value {
7185 const o = self.ng.object;7158 const o = self.ng.object;
7159 const pt = self.ng.pt;
7186 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;7160 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
7187 const operand = try self.resolveInst(pl_op.operand);7161 const operand = try self.resolveInst(pl_op.operand);
7188 const operand_ty = self.typeOf(pl_op.operand);7162 const operand_ty = self.typeOf(pl_op.operand);
...@@ -7193,7 +7167,7 @@ pub const FuncGen = struct {...@@ -7193,7 +7167,7 @@ pub const FuncGen = struct {
7193 self.file,7167 self.file,
7194 self.scope,7168 self.scope,
7195 self.prev_dbg_line,7169 self.prev_dbg_line,
7196 try o.lowerDebugType(operand_ty),7170 try o.lowerDebugType(pt, operand_ty),
7197 arg_no: {7171 arg_no: {
7198 self.arg_inline_index += 1;7172 self.arg_inline_index += 1;
7199 break :arg_no self.arg_inline_index;7173 break :arg_no self.arg_inline_index;
...@@ -7203,10 +7177,10 @@ pub const FuncGen = struct {...@@ -7203,10 +7177,10 @@ pub const FuncGen = struct {
7203 self.file,7177 self.file,
7204 self.scope,7178 self.scope,
7205 self.prev_dbg_line,7179 self.prev_dbg_line,
7206 try o.lowerDebugType(operand_ty),7180 try o.lowerDebugType(pt, operand_ty),
7207 );7181 );
72087182
7209 const zcu = o.pt.zcu;7183 const zcu = pt.zcu;
7210 const owner_mod = self.ng.ownerModule();7184 const owner_mod = self.ng.ownerModule();
7211 if (isByRef(operand_ty, zcu)) {7185 if (isByRef(operand_ty, zcu)) {
7212 _ = try self.wip.callIntrinsic(7186 _ = try self.wip.callIntrinsic(
...@@ -7296,7 +7270,7 @@ pub const FuncGen = struct {...@@ -7296,7 +7270,7 @@ pub const FuncGen = struct {
7296 // This stores whether we need to add an elementtype attribute and7270 // This stores whether we need to add an elementtype attribute and
7297 // if so, the element type itself.7271 // if so, the element type itself.
7298 const llvm_param_attrs = try arena.alloc(Builder.Type, max_param_count);7272 const llvm_param_attrs = try arena.alloc(Builder.Type, max_param_count);
7299 const pt = o.pt;7273 const pt = self.ng.pt;
7300 const zcu = pt.zcu;7274 const zcu = pt.zcu;
7301 const target = zcu.getTarget();7275 const target = zcu.getTarget();
73027276
...@@ -7326,7 +7300,7 @@ pub const FuncGen = struct {...@@ -7326,7 +7300,7 @@ pub const FuncGen = struct {
7326 const output_inst = try self.resolveInst(output);7300 const output_inst = try self.resolveInst(output);
7327 const output_ty = self.typeOf(output);7301 const output_ty = self.typeOf(output);
7328 assert(output_ty.zigTypeTag(zcu) == .pointer);7302 assert(output_ty.zigTypeTag(zcu) == .pointer);
7329 const elem_llvm_ty = try o.lowerPtrElemTy(output_ty.childType(zcu));7303 const elem_llvm_ty = try o.lowerPtrElemTy(pt, output_ty.childType(zcu));
73307304
7331 switch (constraint[0]) {7305 switch (constraint[0]) {
7332 '=' => {},7306 '=' => {},
...@@ -7364,7 +7338,7 @@ pub const FuncGen = struct {...@@ -7364,7 +7338,7 @@ pub const FuncGen = struct {
7364 is_indirect.* = false;7338 is_indirect.* = false;
73657339
7366 const ret_ty = self.typeOfIndex(inst);7340 const ret_ty = self.typeOfIndex(inst);
7367 llvm_ret_types[llvm_ret_i] = try o.lowerType(ret_ty);7341 llvm_ret_types[llvm_ret_i] = try o.lowerType(pt, ret_ty);
7368 llvm_ret_i += 1;7342 llvm_ret_i += 1;
7369 }7343 }
73707344
...@@ -7406,7 +7380,7 @@ pub const FuncGen = struct {...@@ -7406,7 +7380,7 @@ pub const FuncGen = struct {
7406 llvm_param_types[llvm_param_i] = arg_llvm_value.typeOfWip(&self.wip);7380 llvm_param_types[llvm_param_i] = arg_llvm_value.typeOfWip(&self.wip);
7407 } else {7381 } else {
7408 const alignment = arg_ty.abiAlignment(zcu).toLlvm();7382 const alignment = arg_ty.abiAlignment(zcu).toLlvm();
7409 const arg_llvm_ty = try o.lowerType(arg_ty);7383 const arg_llvm_ty = try o.lowerType(pt, arg_ty);
7410 const load_inst =7384 const load_inst =
7411 try self.wip.load(.normal, arg_llvm_ty, arg_llvm_value, alignment, "");7385 try self.wip.load(.normal, arg_llvm_ty, arg_llvm_value, alignment, "");
7412 llvm_param_values[llvm_param_i] = load_inst;7386 llvm_param_values[llvm_param_i] = load_inst;
...@@ -7447,7 +7421,7 @@ pub const FuncGen = struct {...@@ -7447,7 +7421,7 @@ pub const FuncGen = struct {
7447 llvm_param_attrs[llvm_param_i] = if (constraint[0] == '*') blk: {7421 llvm_param_attrs[llvm_param_i] = if (constraint[0] == '*') blk: {
7448 if (!is_by_ref) self.maybeMarkAllowZeroAccess(arg_ty.ptrInfo(zcu));7422 if (!is_by_ref) self.maybeMarkAllowZeroAccess(arg_ty.ptrInfo(zcu));
74497423
7450 break :blk try o.lowerPtrElemTy(if (is_by_ref) arg_ty else arg_ty.childType(zcu));7424 break :blk try o.lowerPtrElemTy(pt, if (is_by_ref) arg_ty else arg_ty.childType(zcu));
7451 } else .none;7425 } else .none;
74527426
7453 llvm_param_i += 1;7427 llvm_param_i += 1;
...@@ -7465,7 +7439,7 @@ pub const FuncGen = struct {...@@ -7465,7 +7439,7 @@ pub const FuncGen = struct {
7465 if (constraint[0] != '+') continue;7439 if (constraint[0] != '+') continue;
74667440
7467 const rw_ty = self.typeOf(output);7441 const rw_ty = self.typeOf(output);
7468 const llvm_elem_ty = try o.lowerPtrElemTy(rw_ty.childType(zcu));7442 const llvm_elem_ty = try o.lowerPtrElemTy(pt, rw_ty.childType(zcu));
7469 if (is_indirect) {7443 if (is_indirect) {
7470 llvm_param_values[llvm_param_i] = llvm_rw_val;7444 llvm_param_values[llvm_param_i] = llvm_rw_val;
7471 llvm_param_types[llvm_param_i] = llvm_rw_val.typeOfWip(&self.wip);7445 llvm_param_types[llvm_param_i] = llvm_rw_val.typeOfWip(&self.wip);
...@@ -7663,13 +7637,13 @@ pub const FuncGen = struct {...@@ -7663,13 +7637,13 @@ pub const FuncGen = struct {
7663 cond: Builder.IntegerCondition,7637 cond: Builder.IntegerCondition,
7664 ) !Builder.Value {7638 ) !Builder.Value {
7665 const o = self.ng.object;7639 const o = self.ng.object;
7666 const pt = o.pt;7640 const pt = self.ng.pt;
7667 const zcu = pt.zcu;7641 const zcu = pt.zcu;
7668 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;7642 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;
7669 const operand = try self.resolveInst(un_op);7643 const operand = try self.resolveInst(un_op);
7670 const operand_ty = self.typeOf(un_op);7644 const operand_ty = self.typeOf(un_op);
7671 const optional_ty = if (operand_is_ptr) operand_ty.childType(zcu) else operand_ty;7645 const optional_ty = if (operand_is_ptr) operand_ty.childType(zcu) else operand_ty;
7672 const optional_llvm_ty = try o.lowerType(optional_ty);7646 const optional_llvm_ty = try o.lowerType(pt, optional_ty);
7673 const payload_ty = optional_ty.optionalChild(zcu);7647 const payload_ty = optional_ty.optionalChild(zcu);
76747648
7675 const access_kind: Builder.MemoryAccessKind =7649 const access_kind: Builder.MemoryAccessKind =
...@@ -7714,14 +7688,14 @@ pub const FuncGen = struct {...@@ -7714,14 +7688,14 @@ pub const FuncGen = struct {
7714 operand_is_ptr: bool,7688 operand_is_ptr: bool,
7715 ) !Builder.Value {7689 ) !Builder.Value {
7716 const o = self.ng.object;7690 const o = self.ng.object;
7717 const pt = o.pt;7691 const pt = self.ng.pt;
7718 const zcu = pt.zcu;7692 const zcu = pt.zcu;
7719 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;7693 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;
7720 const operand = try self.resolveInst(un_op);7694 const operand = try self.resolveInst(un_op);
7721 const operand_ty = self.typeOf(un_op);7695 const operand_ty = self.typeOf(un_op);
7722 const err_union_ty = if (operand_is_ptr) operand_ty.childType(zcu) else operand_ty;7696 const err_union_ty = if (operand_is_ptr) operand_ty.childType(zcu) else operand_ty;
7723 const payload_ty = err_union_ty.errorUnionPayload(zcu);7697 const payload_ty = err_union_ty.errorUnionPayload(zcu);
7724 const error_type = try o.errorIntType();7698 const error_type = try o.errorIntType(pt);
7725 const zero = try o.builder.intValue(error_type, 0);7699 const zero = try o.builder.intValue(error_type, 0);
77267700
7727 const access_kind: Builder.MemoryAccessKind =7701 const access_kind: Builder.MemoryAccessKind =
...@@ -7740,7 +7714,7 @@ pub const FuncGen = struct {...@@ -7740,7 +7714,7 @@ pub const FuncGen = struct {
77407714
7741 if (!payload_ty.hasRuntimeBitsIgnoreComptime(zcu)) {7715 if (!payload_ty.hasRuntimeBitsIgnoreComptime(zcu)) {
7742 const loaded = if (operand_is_ptr)7716 const loaded = if (operand_is_ptr)
7743 try self.wip.load(access_kind, try o.lowerType(err_union_ty), operand, .default, "")7717 try self.wip.load(access_kind, try o.lowerType(pt, err_union_ty), operand, .default, "")
7744 else7718 else
7745 operand;7719 operand;
7746 return self.wip.icmp(cond, loaded, zero, "");7720 return self.wip.icmp(cond, loaded, zero, "");
...@@ -7749,7 +7723,7 @@ pub const FuncGen = struct {...@@ -7749,7 +7723,7 @@ pub const FuncGen = struct {
7749 const err_field_index = try errUnionErrorOffset(payload_ty, pt);7723 const err_field_index = try errUnionErrorOffset(payload_ty, pt);
77507724
7751 const loaded = if (operand_is_ptr or isByRef(err_union_ty, zcu)) loaded: {7725 const loaded = if (operand_is_ptr or isByRef(err_union_ty, zcu)) loaded: {
7752 const err_union_llvm_ty = try o.lowerType(err_union_ty);7726 const err_union_llvm_ty = try o.lowerType(pt, err_union_ty);
7753 const err_field_ptr =7727 const err_field_ptr =
7754 try self.wip.gepStruct(err_union_llvm_ty, operand, err_field_index, "");7728 try self.wip.gepStruct(err_union_llvm_ty, operand, err_field_index, "");
7755 break :loaded try self.wip.load(access_kind, error_type, err_field_ptr, .default, "");7729 break :loaded try self.wip.load(access_kind, error_type, err_field_ptr, .default, "");
...@@ -7759,7 +7733,7 @@ pub const FuncGen = struct {...@@ -7759,7 +7733,7 @@ pub const FuncGen = struct {
77597733
7760 fn airOptionalPayloadPtr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {7734 fn airOptionalPayloadPtr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
7761 const o = self.ng.object;7735 const o = self.ng.object;
7762 const pt = o.pt;7736 const pt = self.ng.pt;
7763 const zcu = pt.zcu;7737 const zcu = pt.zcu;
7764 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;7738 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
7765 const operand = try self.resolveInst(ty_op.operand);7739 const operand = try self.resolveInst(ty_op.operand);
...@@ -7774,14 +7748,14 @@ pub const FuncGen = struct {...@@ -7774,14 +7748,14 @@ pub const FuncGen = struct {
7774 // The payload and the optional are the same value.7748 // The payload and the optional are the same value.
7775 return operand;7749 return operand;
7776 }7750 }
7777 return self.wip.gepStruct(try o.lowerType(optional_ty), operand, 0, "");7751 return self.wip.gepStruct(try o.lowerType(pt, optional_ty), operand, 0, "");
7778 }7752 }
77797753
7780 fn airOptionalPayloadPtrSet(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {7754 fn airOptionalPayloadPtrSet(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
7781 comptime assert(optional_layout_version == 3);7755 comptime assert(optional_layout_version == 3);
77827756
7783 const o = self.ng.object;7757 const o = self.ng.object;
7784 const pt = o.pt;7758 const pt = self.ng.pt;
7785 const zcu = pt.zcu;7759 const zcu = pt.zcu;
7786 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;7760 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
7787 const operand = try self.resolveInst(ty_op.operand);7761 const operand = try self.resolveInst(ty_op.operand);
...@@ -7807,7 +7781,7 @@ pub const FuncGen = struct {...@@ -7807,7 +7781,7 @@ pub const FuncGen = struct {
7807 }7781 }
78087782
7809 // First set the non-null bit.7783 // First set the non-null bit.
7810 const optional_llvm_ty = try o.lowerType(optional_ty);7784 const optional_llvm_ty = try o.lowerType(pt, optional_ty);
7811 const non_null_ptr = try self.wip.gepStruct(optional_llvm_ty, operand, 1, "");7785 const non_null_ptr = try self.wip.gepStruct(optional_llvm_ty, operand, 1, "");
78127786
7813 self.maybeMarkAllowZeroAccess(optional_ptr_ty.ptrInfo(zcu));7787 self.maybeMarkAllowZeroAccess(optional_ptr_ty.ptrInfo(zcu));
...@@ -7823,7 +7797,7 @@ pub const FuncGen = struct {...@@ -7823,7 +7797,7 @@ pub const FuncGen = struct {
78237797
7824 fn airOptionalPayload(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {7798 fn airOptionalPayload(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {
7825 const o = self.ng.object;7799 const o = self.ng.object;
7826 const pt = o.pt;7800 const pt = self.ng.pt;
7827 const zcu = pt.zcu;7801 const zcu = pt.zcu;
7828 const inst = body_tail[0];7802 const inst = body_tail[0];
7829 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;7803 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
...@@ -7837,7 +7811,7 @@ pub const FuncGen = struct {...@@ -7837,7 +7811,7 @@ pub const FuncGen = struct {
7837 return operand;7811 return operand;
7838 }7812 }
78397813
7840 const opt_llvm_ty = try o.lowerType(optional_ty);7814 const opt_llvm_ty = try o.lowerType(pt, optional_ty);
7841 const can_elide_load = if (isByRef(payload_ty, zcu)) self.canElideLoad(body_tail) else false;7815 const can_elide_load = if (isByRef(payload_ty, zcu)) self.canElideLoad(body_tail) else false;
7842 return self.optPayloadHandle(opt_llvm_ty, operand, optional_ty, can_elide_load);7816 return self.optPayloadHandle(opt_llvm_ty, operand, optional_ty, can_elide_load);
7843 }7817 }
...@@ -7848,7 +7822,7 @@ pub const FuncGen = struct {...@@ -7848,7 +7822,7 @@ pub const FuncGen = struct {
7848 operand_is_ptr: bool,7822 operand_is_ptr: bool,
7849 ) !Builder.Value {7823 ) !Builder.Value {
7850 const o = self.ng.object;7824 const o = self.ng.object;
7851 const pt = o.pt;7825 const pt = self.ng.pt;
7852 const zcu = pt.zcu;7826 const zcu = pt.zcu;
7853 const inst = body_tail[0];7827 const inst = body_tail[0];
7854 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;7828 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
...@@ -7862,7 +7836,7 @@ pub const FuncGen = struct {...@@ -7862,7 +7836,7 @@ pub const FuncGen = struct {
7862 return if (operand_is_ptr) operand else .none;7836 return if (operand_is_ptr) operand else .none;
7863 }7837 }
7864 const offset = try errUnionPayloadOffset(payload_ty, pt);7838 const offset = try errUnionPayloadOffset(payload_ty, pt);
7865 const err_union_llvm_ty = try o.lowerType(err_union_ty);7839 const err_union_llvm_ty = try o.lowerType(pt, err_union_ty);
7866 if (operand_is_ptr) {7840 if (operand_is_ptr) {
7867 return self.wip.gepStruct(err_union_llvm_ty, operand, offset, "");7841 return self.wip.gepStruct(err_union_llvm_ty, operand, offset, "");
7868 } else if (isByRef(err_union_ty, zcu)) {7842 } else if (isByRef(err_union_ty, zcu)) {
...@@ -7884,12 +7858,12 @@ pub const FuncGen = struct {...@@ -7884,12 +7858,12 @@ pub const FuncGen = struct {
7884 operand_is_ptr: bool,7858 operand_is_ptr: bool,
7885 ) !Builder.Value {7859 ) !Builder.Value {
7886 const o = self.ng.object;7860 const o = self.ng.object;
7887 const pt = o.pt;7861 const pt = self.ng.pt;
7888 const zcu = pt.zcu;7862 const zcu = pt.zcu;
7889 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;7863 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
7890 const operand = try self.resolveInst(ty_op.operand);7864 const operand = try self.resolveInst(ty_op.operand);
7891 const operand_ty = self.typeOf(ty_op.operand);7865 const operand_ty = self.typeOf(ty_op.operand);
7892 const error_type = try o.errorIntType();7866 const error_type = try o.errorIntType(pt);
7893 const err_union_ty = if (operand_is_ptr) operand_ty.childType(zcu) else operand_ty;7867 const err_union_ty = if (operand_is_ptr) operand_ty.childType(zcu) else operand_ty;
7894 if (err_union_ty.errorUnionSet(zcu).errorSetIsEmpty(zcu)) {7868 if (err_union_ty.errorUnionSet(zcu).errorSetIsEmpty(zcu)) {
7895 if (operand_is_ptr) {7869 if (operand_is_ptr) {
...@@ -7916,7 +7890,7 @@ pub const FuncGen = struct {...@@ -7916,7 +7890,7 @@ pub const FuncGen = struct {
7916 if (operand_is_ptr or isByRef(err_union_ty, zcu)) {7890 if (operand_is_ptr or isByRef(err_union_ty, zcu)) {
7917 if (operand_is_ptr) self.maybeMarkAllowZeroAccess(operand_ty.ptrInfo(zcu));7891 if (operand_is_ptr) self.maybeMarkAllowZeroAccess(operand_ty.ptrInfo(zcu));
79187892
7919 const err_union_llvm_ty = try o.lowerType(err_union_ty);7893 const err_union_llvm_ty = try o.lowerType(pt, err_union_ty);
7920 const err_field_ptr = try self.wip.gepStruct(err_union_llvm_ty, operand, offset, "");7894 const err_field_ptr = try self.wip.gepStruct(err_union_llvm_ty, operand, offset, "");
7921 return self.wip.load(access_kind, error_type, err_field_ptr, .default, "");7895 return self.wip.load(access_kind, error_type, err_field_ptr, .default, "");
7922 }7896 }
...@@ -7926,7 +7900,7 @@ pub const FuncGen = struct {...@@ -7926,7 +7900,7 @@ pub const FuncGen = struct {
79267900
7927 fn airErrUnionPayloadPtrSet(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {7901 fn airErrUnionPayloadPtrSet(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
7928 const o = self.ng.object;7902 const o = self.ng.object;
7929 const pt = o.pt;7903 const pt = self.ng.pt;
7930 const zcu = pt.zcu;7904 const zcu = pt.zcu;
7931 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;7905 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
7932 const operand = try self.resolveInst(ty_op.operand);7906 const operand = try self.resolveInst(ty_op.operand);
...@@ -7934,7 +7908,7 @@ pub const FuncGen = struct {...@@ -7934,7 +7908,7 @@ pub const FuncGen = struct {
7934 const err_union_ty = err_union_ptr_ty.childType(zcu);7908 const err_union_ty = err_union_ptr_ty.childType(zcu);
79357909
7936 const payload_ty = err_union_ty.errorUnionPayload(zcu);7910 const payload_ty = err_union_ty.errorUnionPayload(zcu);
7937 const non_error_val = try o.builder.intValue(try o.errorIntType(), 0);7911 const non_error_val = try o.builder.intValue(try o.errorIntType(pt), 0);
79387912
7939 const access_kind: Builder.MemoryAccessKind =7913 const access_kind: Builder.MemoryAccessKind =
7940 if (err_union_ptr_ty.isVolatilePtr(zcu)) .@"volatile" else .normal;7914 if (err_union_ptr_ty.isVolatilePtr(zcu)) .@"volatile" else .normal;
...@@ -7945,7 +7919,7 @@ pub const FuncGen = struct {...@@ -7945,7 +7919,7 @@ pub const FuncGen = struct {
7945 _ = try self.wip.store(access_kind, non_error_val, operand, .default);7919 _ = try self.wip.store(access_kind, non_error_val, operand, .default);
7946 return operand;7920 return operand;
7947 }7921 }
7948 const err_union_llvm_ty = try o.lowerType(err_union_ty);7922 const err_union_llvm_ty = try o.lowerType(pt, err_union_ty);
7949 {7923 {
7950 self.maybeMarkAllowZeroAccess(err_union_ptr_ty.ptrInfo(zcu));7924 self.maybeMarkAllowZeroAccess(err_union_ptr_ty.ptrInfo(zcu));
79517925
...@@ -7976,14 +7950,14 @@ pub const FuncGen = struct {...@@ -7976,14 +7950,14 @@ pub const FuncGen = struct {
79767950
7977 fn airSaveErrReturnTraceIndex(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {7951 fn airSaveErrReturnTraceIndex(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
7978 const o = self.ng.object;7952 const o = self.ng.object;
7979 const pt = o.pt;7953 const pt = self.ng.pt;
7980 const zcu = pt.zcu;7954 const zcu = pt.zcu;
79817955
7982 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;7956 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
7983 const struct_ty = ty_pl.ty.toType();7957 const struct_ty = ty_pl.ty.toType();
7984 const field_index = ty_pl.payload;7958 const field_index = ty_pl.payload;
79857959
7986 const struct_llvm_ty = try o.lowerType(struct_ty);7960 const struct_llvm_ty = try o.lowerType(pt, struct_ty);
7987 const llvm_field_index = o.llvmFieldIndex(struct_ty, field_index).?;7961 const llvm_field_index = o.llvmFieldIndex(struct_ty, field_index).?;
7988 assert(self.err_ret_trace != .none);7962 assert(self.err_ret_trace != .none);
7989 const field_ptr =7963 const field_ptr =
...@@ -8022,7 +7996,7 @@ pub const FuncGen = struct {...@@ -8022,7 +7996,7 @@ pub const FuncGen = struct {
80227996
8023 fn airWrapOptional(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {7997 fn airWrapOptional(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {
8024 const o = self.ng.object;7998 const o = self.ng.object;
8025 const pt = o.pt;7999 const pt = self.ng.pt;
8026 const zcu = pt.zcu;8000 const zcu = pt.zcu;
8027 const inst = body_tail[0];8001 const inst = body_tail[0];
8028 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;8002 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
...@@ -8033,7 +8007,7 @@ pub const FuncGen = struct {...@@ -8033,7 +8007,7 @@ pub const FuncGen = struct {
8033 const operand = try self.resolveInst(ty_op.operand);8007 const operand = try self.resolveInst(ty_op.operand);
8034 const optional_ty = self.typeOfIndex(inst);8008 const optional_ty = self.typeOfIndex(inst);
8035 if (optional_ty.optionalReprIsPayload(zcu)) return operand;8009 if (optional_ty.optionalReprIsPayload(zcu)) return operand;
8036 const llvm_optional_ty = try o.lowerType(optional_ty);8010 const llvm_optional_ty = try o.lowerType(pt, optional_ty);
8037 if (isByRef(optional_ty, zcu)) {8011 if (isByRef(optional_ty, zcu)) {
8038 const directReturn = self.isNextRet(body_tail);8012 const directReturn = self.isNextRet(body_tail);
8039 const optional_ptr = if (directReturn)8013 const optional_ptr = if (directReturn)
...@@ -8056,7 +8030,7 @@ pub const FuncGen = struct {...@@ -8056,7 +8030,7 @@ pub const FuncGen = struct {
80568030
8057 fn airWrapErrUnionPayload(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {8031 fn airWrapErrUnionPayload(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {
8058 const o = self.ng.object;8032 const o = self.ng.object;
8059 const pt = o.pt;8033 const pt = self.ng.pt;
8060 const zcu = pt.zcu;8034 const zcu = pt.zcu;
8061 const inst = body_tail[0];8035 const inst = body_tail[0];
8062 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;8036 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
...@@ -8066,8 +8040,8 @@ pub const FuncGen = struct {...@@ -8066,8 +8040,8 @@ pub const FuncGen = struct {
8066 if (!payload_ty.hasRuntimeBitsIgnoreComptime(zcu)) {8040 if (!payload_ty.hasRuntimeBitsIgnoreComptime(zcu)) {
8067 return operand;8041 return operand;
8068 }8042 }
8069 const ok_err_code = try o.builder.intValue(try o.errorIntType(), 0);8043 const ok_err_code = try o.builder.intValue(try o.errorIntType(pt), 0);
8070 const err_un_llvm_ty = try o.lowerType(err_un_ty);8044 const err_un_llvm_ty = try o.lowerType(pt, err_un_ty);
80718045
8072 const payload_offset = try errUnionPayloadOffset(payload_ty, pt);8046 const payload_offset = try errUnionPayloadOffset(payload_ty, pt);
8073 const error_offset = try errUnionErrorOffset(payload_ty, pt);8047 const error_offset = try errUnionErrorOffset(payload_ty, pt);
...@@ -8098,7 +8072,7 @@ pub const FuncGen = struct {...@@ -8098,7 +8072,7 @@ pub const FuncGen = struct {
80988072
8099 fn airWrapErrUnionErr(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {8073 fn airWrapErrUnionErr(self: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {
8100 const o = self.ng.object;8074 const o = self.ng.object;
8101 const pt = o.pt;8075 const pt = self.ng.pt;
8102 const zcu = pt.zcu;8076 const zcu = pt.zcu;
8103 const inst = body_tail[0];8077 const inst = body_tail[0];
8104 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;8078 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
...@@ -8106,7 +8080,7 @@ pub const FuncGen = struct {...@@ -8106,7 +8080,7 @@ pub const FuncGen = struct {
8106 const payload_ty = err_un_ty.errorUnionPayload(zcu);8080 const payload_ty = err_un_ty.errorUnionPayload(zcu);
8107 const operand = try self.resolveInst(ty_op.operand);8081 const operand = try self.resolveInst(ty_op.operand);
8108 if (!payload_ty.hasRuntimeBitsIgnoreComptime(zcu)) return operand;8082 if (!payload_ty.hasRuntimeBitsIgnoreComptime(zcu)) return operand;
8109 const err_un_llvm_ty = try o.lowerType(err_un_ty);8083 const err_un_llvm_ty = try o.lowerType(pt, err_un_ty);
81108084
8111 const payload_offset = try errUnionPayloadOffset(payload_ty, pt);8085 const payload_offset = try errUnionPayloadOffset(payload_ty, pt);
8112 const error_offset = try errUnionErrorOffset(payload_ty, pt);8086 const error_offset = try errUnionErrorOffset(payload_ty, pt);
...@@ -8139,9 +8113,10 @@ pub const FuncGen = struct {...@@ -8139,9 +8113,10 @@ pub const FuncGen = struct {
81398113
8140 fn airWasmMemorySize(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {8114 fn airWasmMemorySize(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
8141 const o = self.ng.object;8115 const o = self.ng.object;
8116 const pt = self.ng.pt;
8142 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;8117 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
8143 const index = pl_op.payload;8118 const index = pl_op.payload;
8144 const llvm_usize = try o.lowerType(Type.usize);8119 const llvm_usize = try o.lowerType(pt, Type.usize);
8145 return self.wip.callIntrinsic(.normal, .none, .@"wasm.memory.size", &.{llvm_usize}, &.{8120 return self.wip.callIntrinsic(.normal, .none, .@"wasm.memory.size", &.{llvm_usize}, &.{
8146 try o.builder.intValue(.i32, index),8121 try o.builder.intValue(.i32, index),
8147 }, "");8122 }, "");
...@@ -8149,9 +8124,10 @@ pub const FuncGen = struct {...@@ -8149,9 +8124,10 @@ pub const FuncGen = struct {
81498124
8150 fn airWasmMemoryGrow(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {8125 fn airWasmMemoryGrow(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
8151 const o = self.ng.object;8126 const o = self.ng.object;
8127 const pt = self.ng.pt;
8152 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;8128 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
8153 const index = pl_op.payload;8129 const index = pl_op.payload;
8154 const llvm_isize = try o.lowerType(Type.isize);8130 const llvm_isize = try o.lowerType(pt, Type.isize);
8155 return self.wip.callIntrinsic(.normal, .none, .@"wasm.memory.grow", &.{llvm_isize}, &.{8131 return self.wip.callIntrinsic(.normal, .none, .@"wasm.memory.grow", &.{llvm_isize}, &.{
8156 try o.builder.intValue(.i32, index), try self.resolveInst(pl_op.operand),8132 try o.builder.intValue(.i32, index), try self.resolveInst(pl_op.operand),
8157 }, "");8133 }, "");
...@@ -8159,7 +8135,7 @@ pub const FuncGen = struct {...@@ -8159,7 +8135,7 @@ pub const FuncGen = struct {
81598135
8160 fn airVectorStoreElem(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {8136 fn airVectorStoreElem(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
8161 const o = self.ng.object;8137 const o = self.ng.object;
8162 const pt = o.pt;8138 const pt = self.ng.pt;
8163 const zcu = pt.zcu;8139 const zcu = pt.zcu;
8164 const data = self.air.instructions.items(.data)[@intFromEnum(inst)].vector_store_elem;8140 const data = self.air.instructions.items(.data)[@intFromEnum(inst)].vector_store_elem;
8165 const extra = self.air.extraData(Air.Bin, data.payload).data;8141 const extra = self.air.extraData(Air.Bin, data.payload).data;
...@@ -8175,7 +8151,7 @@ pub const FuncGen = struct {...@@ -8175,7 +8151,7 @@ pub const FuncGen = struct {
8175 // https://github.com/ziglang/zig/issues/18652#issuecomment-24528449088151 // https://github.com/ziglang/zig/issues/18652#issuecomment-2452844908
8176 const access_kind: Builder.MemoryAccessKind =8152 const access_kind: Builder.MemoryAccessKind =
8177 if (vector_ptr_ty.isVolatilePtr(zcu)) .@"volatile" else .normal;8153 if (vector_ptr_ty.isVolatilePtr(zcu)) .@"volatile" else .normal;
8178 const elem_llvm_ty = try o.lowerType(vector_ptr_ty.childType(zcu));8154 const elem_llvm_ty = try o.lowerType(pt, vector_ptr_ty.childType(zcu));
8179 const alignment = vector_ptr_ty.ptrAlignment(zcu).toLlvm();8155 const alignment = vector_ptr_ty.ptrAlignment(zcu).toLlvm();
8180 const loaded = try self.wip.load(access_kind, elem_llvm_ty, vector_ptr, alignment, "");8156 const loaded = try self.wip.load(access_kind, elem_llvm_ty, vector_ptr, alignment, "");
81818157
...@@ -8186,14 +8162,16 @@ pub const FuncGen = struct {...@@ -8186,14 +8162,16 @@ pub const FuncGen = struct {
81868162
8187 fn airRuntimeNavPtr(fg: *FuncGen, inst: Air.Inst.Index) !Builder.Value {8163 fn airRuntimeNavPtr(fg: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
8188 const o = fg.ng.object;8164 const o = fg.ng.object;
8165 const pt = fg.ng.pt;
8189 const ty_nav = fg.air.instructions.items(.data)[@intFromEnum(inst)].ty_nav;8166 const ty_nav = fg.air.instructions.items(.data)[@intFromEnum(inst)].ty_nav;
8190 const llvm_ptr_const = try o.lowerNavRefValue(ty_nav.nav);8167 const llvm_ptr_const = try o.lowerNavRefValue(pt, ty_nav.nav);
8191 return llvm_ptr_const.toValue();8168 return llvm_ptr_const.toValue();
8192 }8169 }
81938170
8194 fn airMin(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {8171 fn airMin(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
8195 const o = self.ng.object;8172 const o = self.ng.object;
8196 const zcu = o.pt.zcu;8173 const pt = self.ng.pt;
8174 const zcu = pt.zcu;
8197 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8175 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8198 const lhs = try self.resolveInst(bin_op.lhs);8176 const lhs = try self.resolveInst(bin_op.lhs);
8199 const rhs = try self.resolveInst(bin_op.rhs);8177 const rhs = try self.resolveInst(bin_op.rhs);
...@@ -8205,7 +8183,7 @@ pub const FuncGen = struct {...@@ -8205,7 +8183,7 @@ pub const FuncGen = struct {
8205 .normal,8183 .normal,
8206 .none,8184 .none,
8207 if (scalar_ty.isSignedInt(zcu)) .smin else .umin,8185 if (scalar_ty.isSignedInt(zcu)) .smin else .umin,
8208 &.{try o.lowerType(inst_ty)},8186 &.{try o.lowerType(pt, inst_ty)},
8209 &.{ lhs, rhs },8187 &.{ lhs, rhs },
8210 "",8188 "",
8211 );8189 );
...@@ -8213,7 +8191,8 @@ pub const FuncGen = struct {...@@ -8213,7 +8191,8 @@ pub const FuncGen = struct {
82138191
8214 fn airMax(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {8192 fn airMax(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
8215 const o = self.ng.object;8193 const o = self.ng.object;
8216 const zcu = o.pt.zcu;8194 const pt = self.ng.pt;
8195 const zcu = pt.zcu;
8217 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8196 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8218 const lhs = try self.resolveInst(bin_op.lhs);8197 const lhs = try self.resolveInst(bin_op.lhs);
8219 const rhs = try self.resolveInst(bin_op.rhs);8198 const rhs = try self.resolveInst(bin_op.rhs);
...@@ -8225,7 +8204,7 @@ pub const FuncGen = struct {...@@ -8225,7 +8204,7 @@ pub const FuncGen = struct {
8225 .normal,8204 .normal,
8226 .none,8205 .none,
8227 if (scalar_ty.isSignedInt(zcu)) .smax else .umax,8206 if (scalar_ty.isSignedInt(zcu)) .smax else .umax,
8228 &.{try o.lowerType(inst_ty)},8207 &.{try o.lowerType(pt, inst_ty)},
8229 &.{ lhs, rhs },8208 &.{ lhs, rhs },
8230 "",8209 "",
8231 );8210 );
...@@ -8233,17 +8212,17 @@ pub const FuncGen = struct {...@@ -8233,17 +8212,17 @@ pub const FuncGen = struct {
82338212
8234 fn airSlice(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {8213 fn airSlice(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
8235 const o = self.ng.object;8214 const o = self.ng.object;
8215 const pt = self.ng.pt;
8236 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;8216 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
8237 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;8217 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;
8238 const ptr = try self.resolveInst(bin_op.lhs);8218 const ptr = try self.resolveInst(bin_op.lhs);
8239 const len = try self.resolveInst(bin_op.rhs);8219 const len = try self.resolveInst(bin_op.rhs);
8240 const inst_ty = self.typeOfIndex(inst);8220 const inst_ty = self.typeOfIndex(inst);
8241 return self.wip.buildAggregate(try o.lowerType(inst_ty), &.{ ptr, len }, "");8221 return self.wip.buildAggregate(try o.lowerType(pt, inst_ty), &.{ ptr, len }, "");
8242 }8222 }
82438223
8244 fn airAdd(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {8224 fn airAdd(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {
8245 const o = self.ng.object;8225 const zcu = self.ng.pt.zcu;
8246 const zcu = o.pt.zcu;
8247 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8226 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8248 const lhs = try self.resolveInst(bin_op.lhs);8227 const lhs = try self.resolveInst(bin_op.lhs);
8249 const rhs = try self.resolveInst(bin_op.rhs);8228 const rhs = try self.resolveInst(bin_op.rhs);
...@@ -8261,7 +8240,8 @@ pub const FuncGen = struct {...@@ -8261,7 +8240,8 @@ pub const FuncGen = struct {
8261 unsigned_intrinsic: Builder.Intrinsic,8240 unsigned_intrinsic: Builder.Intrinsic,
8262 ) !Builder.Value {8241 ) !Builder.Value {
8263 const o = fg.ng.object;8242 const o = fg.ng.object;
8264 const zcu = o.pt.zcu;8243 const pt = fg.ng.pt;
8244 const zcu = pt.zcu;
82658245
8266 const bin_op = fg.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8246 const bin_op = fg.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8267 const lhs = try fg.resolveInst(bin_op.lhs);8247 const lhs = try fg.resolveInst(bin_op.lhs);
...@@ -8270,7 +8250,7 @@ pub const FuncGen = struct {...@@ -8270,7 +8250,7 @@ pub const FuncGen = struct {
8270 const scalar_ty = inst_ty.scalarType(zcu);8250 const scalar_ty = inst_ty.scalarType(zcu);
82718251
8272 const intrinsic = if (scalar_ty.isSignedInt(zcu)) signed_intrinsic else unsigned_intrinsic;8252 const intrinsic = if (scalar_ty.isSignedInt(zcu)) signed_intrinsic else unsigned_intrinsic;
8273 const llvm_inst_ty = try o.lowerType(inst_ty);8253 const llvm_inst_ty = try o.lowerType(pt, inst_ty);
8274 const results =8254 const results =
8275 try fg.wip.callIntrinsic(.normal, .none, intrinsic, &.{llvm_inst_ty}, &.{ lhs, rhs }, "");8255 try fg.wip.callIntrinsic(.normal, .none, intrinsic, &.{llvm_inst_ty}, &.{ lhs, rhs }, "");
82768256
...@@ -8309,7 +8289,8 @@ pub const FuncGen = struct {...@@ -8309,7 +8289,8 @@ pub const FuncGen = struct {
83098289
8310 fn airAddSat(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {8290 fn airAddSat(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
8311 const o = self.ng.object;8291 const o = self.ng.object;
8312 const zcu = o.pt.zcu;8292 const pt = self.ng.pt;
8293 const zcu = pt.zcu;
8313 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8294 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8314 const lhs = try self.resolveInst(bin_op.lhs);8295 const lhs = try self.resolveInst(bin_op.lhs);
8315 const rhs = try self.resolveInst(bin_op.rhs);8296 const rhs = try self.resolveInst(bin_op.rhs);
...@@ -8321,15 +8302,14 @@ pub const FuncGen = struct {...@@ -8321,15 +8302,14 @@ pub const FuncGen = struct {
8321 .normal,8302 .normal,
8322 .none,8303 .none,
8323 if (scalar_ty.isSignedInt(zcu)) .@"sadd.sat" else .@"uadd.sat",8304 if (scalar_ty.isSignedInt(zcu)) .@"sadd.sat" else .@"uadd.sat",
8324 &.{try o.lowerType(inst_ty)},8305 &.{try o.lowerType(pt, inst_ty)},
8325 &.{ lhs, rhs },8306 &.{ lhs, rhs },
8326 "",8307 "",
8327 );8308 );
8328 }8309 }
83298310
8330 fn airSub(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {8311 fn airSub(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {
8331 const o = self.ng.object;8312 const zcu = self.ng.pt.zcu;
8332 const zcu = o.pt.zcu;
8333 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8313 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8334 const lhs = try self.resolveInst(bin_op.lhs);8314 const lhs = try self.resolveInst(bin_op.lhs);
8335 const rhs = try self.resolveInst(bin_op.rhs);8315 const rhs = try self.resolveInst(bin_op.rhs);
...@@ -8350,7 +8330,8 @@ pub const FuncGen = struct {...@@ -8350,7 +8330,8 @@ pub const FuncGen = struct {
83508330
8351 fn airSubSat(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {8331 fn airSubSat(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
8352 const o = self.ng.object;8332 const o = self.ng.object;
8353 const zcu = o.pt.zcu;8333 const pt = self.ng.pt;
8334 const zcu = pt.zcu;
8354 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8335 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8355 const lhs = try self.resolveInst(bin_op.lhs);8336 const lhs = try self.resolveInst(bin_op.lhs);
8356 const rhs = try self.resolveInst(bin_op.rhs);8337 const rhs = try self.resolveInst(bin_op.rhs);
...@@ -8362,15 +8343,14 @@ pub const FuncGen = struct {...@@ -8362,15 +8343,14 @@ pub const FuncGen = struct {
8362 .normal,8343 .normal,
8363 .none,8344 .none,
8364 if (scalar_ty.isSignedInt(zcu)) .@"ssub.sat" else .@"usub.sat",8345 if (scalar_ty.isSignedInt(zcu)) .@"ssub.sat" else .@"usub.sat",
8365 &.{try o.lowerType(inst_ty)},8346 &.{try o.lowerType(pt, inst_ty)},
8366 &.{ lhs, rhs },8347 &.{ lhs, rhs },
8367 "",8348 "",
8368 );8349 );
8369 }8350 }
83708351
8371 fn airMul(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {8352 fn airMul(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {
8372 const o = self.ng.object;8353 const zcu = self.ng.pt.zcu;
8373 const zcu = o.pt.zcu;
8374 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8354 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8375 const lhs = try self.resolveInst(bin_op.lhs);8355 const lhs = try self.resolveInst(bin_op.lhs);
8376 const rhs = try self.resolveInst(bin_op.rhs);8356 const rhs = try self.resolveInst(bin_op.rhs);
...@@ -8391,7 +8371,8 @@ pub const FuncGen = struct {...@@ -8391,7 +8371,8 @@ pub const FuncGen = struct {
83918371
8392 fn airMulSat(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {8372 fn airMulSat(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
8393 const o = self.ng.object;8373 const o = self.ng.object;
8394 const zcu = o.pt.zcu;8374 const pt = self.ng.pt;
8375 const zcu = pt.zcu;
8395 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8376 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8396 const lhs = try self.resolveInst(bin_op.lhs);8377 const lhs = try self.resolveInst(bin_op.lhs);
8397 const rhs = try self.resolveInst(bin_op.rhs);8378 const rhs = try self.resolveInst(bin_op.rhs);
...@@ -8403,7 +8384,7 @@ pub const FuncGen = struct {...@@ -8403,7 +8384,7 @@ pub const FuncGen = struct {
8403 .normal,8384 .normal,
8404 .none,8385 .none,
8405 if (scalar_ty.isSignedInt(zcu)) .@"smul.fix.sat" else .@"umul.fix.sat",8386 if (scalar_ty.isSignedInt(zcu)) .@"smul.fix.sat" else .@"umul.fix.sat",
8406 &.{try o.lowerType(inst_ty)},8387 &.{try o.lowerType(pt, inst_ty)},
8407 &.{ lhs, rhs, .@"0" },8388 &.{ lhs, rhs, .@"0" },
8408 "",8389 "",
8409 );8390 );
...@@ -8419,8 +8400,7 @@ pub const FuncGen = struct {...@@ -8419,8 +8400,7 @@ pub const FuncGen = struct {
8419 }8400 }
84208401
8421 fn airDivTrunc(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {8402 fn airDivTrunc(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {
8422 const o = self.ng.object;8403 const zcu = self.ng.pt.zcu;
8423 const zcu = o.pt.zcu;
8424 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8404 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8425 const lhs = try self.resolveInst(bin_op.lhs);8405 const lhs = try self.resolveInst(bin_op.lhs);
8426 const rhs = try self.resolveInst(bin_op.rhs);8406 const rhs = try self.resolveInst(bin_op.rhs);
...@@ -8436,7 +8416,8 @@ pub const FuncGen = struct {...@@ -8436,7 +8416,8 @@ pub const FuncGen = struct {
84368416
8437 fn airDivFloor(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {8417 fn airDivFloor(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {
8438 const o = self.ng.object;8418 const o = self.ng.object;
8439 const zcu = o.pt.zcu;8419 const pt = self.ng.pt;
8420 const zcu = pt.zcu;
8440 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8421 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8441 const lhs = try self.resolveInst(bin_op.lhs);8422 const lhs = try self.resolveInst(bin_op.lhs);
8442 const rhs = try self.resolveInst(bin_op.rhs);8423 const rhs = try self.resolveInst(bin_op.rhs);
...@@ -8448,7 +8429,7 @@ pub const FuncGen = struct {...@@ -8448,7 +8429,7 @@ pub const FuncGen = struct {
8448 return self.buildFloatOp(.floor, fast, inst_ty, 1, .{result});8429 return self.buildFloatOp(.floor, fast, inst_ty, 1, .{result});
8449 }8430 }
8450 if (scalar_ty.isSignedInt(zcu)) {8431 if (scalar_ty.isSignedInt(zcu)) {
8451 const inst_llvm_ty = try o.lowerType(inst_ty);8432 const inst_llvm_ty = try o.lowerType(pt, inst_ty);
84528433
8453 const ExpectedContents = [std.math.big.int.calcTwosCompLimbCount(256)]std.math.big.Limb;8434 const ExpectedContents = [std.math.big.int.calcTwosCompLimbCount(256)]std.math.big.Limb;
8454 var stack align(@max(8435 var stack align(@max(
...@@ -8485,8 +8466,7 @@ pub const FuncGen = struct {...@@ -8485,8 +8466,7 @@ pub const FuncGen = struct {
8485 }8466 }
84868467
8487 fn airDivExact(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {8468 fn airDivExact(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {
8488 const o = self.ng.object;8469 const zcu = self.ng.pt.zcu;
8489 const zcu = o.pt.zcu;
8490 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8470 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8491 const lhs = try self.resolveInst(bin_op.lhs);8471 const lhs = try self.resolveInst(bin_op.lhs);
8492 const rhs = try self.resolveInst(bin_op.rhs);8472 const rhs = try self.resolveInst(bin_op.rhs);
...@@ -8503,8 +8483,7 @@ pub const FuncGen = struct {...@@ -8503,8 +8483,7 @@ pub const FuncGen = struct {
8503 }8483 }
85048484
8505 fn airRem(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {8485 fn airRem(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {
8506 const o = self.ng.object;8486 const zcu = self.ng.pt.zcu;
8507 const zcu = o.pt.zcu;
8508 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8487 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8509 const lhs = try self.resolveInst(bin_op.lhs);8488 const lhs = try self.resolveInst(bin_op.lhs);
8510 const rhs = try self.resolveInst(bin_op.rhs);8489 const rhs = try self.resolveInst(bin_op.rhs);
...@@ -8521,12 +8500,13 @@ pub const FuncGen = struct {...@@ -8521,12 +8500,13 @@ pub const FuncGen = struct {
85218500
8522 fn airMod(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {8501 fn airMod(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {
8523 const o = self.ng.object;8502 const o = self.ng.object;
8524 const zcu = o.pt.zcu;8503 const pt = self.ng.pt;
8504 const zcu = pt.zcu;
8525 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;8505 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
8526 const lhs = try self.resolveInst(bin_op.lhs);8506 const lhs = try self.resolveInst(bin_op.lhs);
8527 const rhs = try self.resolveInst(bin_op.rhs);8507 const rhs = try self.resolveInst(bin_op.rhs);
8528 const inst_ty = self.typeOfIndex(inst);8508 const inst_ty = self.typeOfIndex(inst);
8529 const inst_llvm_ty = try o.lowerType(inst_ty);8509 const inst_llvm_ty = try o.lowerType(pt, inst_ty);
8530 const scalar_ty = inst_ty.scalarType(zcu);8510 const scalar_ty = inst_ty.scalarType(zcu);
85318511
8532 if (scalar_ty.isRuntimeFloat()) {8512 if (scalar_ty.isRuntimeFloat()) {
...@@ -8574,17 +8554,18 @@ pub const FuncGen = struct {...@@ -8574,17 +8554,18 @@ pub const FuncGen = struct {
85748554
8575 fn airPtrAdd(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {8555 fn airPtrAdd(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
8576 const o = self.ng.object;8556 const o = self.ng.object;
8577 const zcu = o.pt.zcu;8557 const pt = self.ng.pt;
8558 const zcu = pt.zcu;
8578 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;8559 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
8579 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;8560 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;
8580 const ptr = try self.resolveInst(bin_op.lhs);8561 const ptr = try self.resolveInst(bin_op.lhs);
8581 const offset = try self.resolveInst(bin_op.rhs);8562 const offset = try self.resolveInst(bin_op.rhs);
8582 const ptr_ty = self.typeOf(bin_op.lhs);8563 const ptr_ty = self.typeOf(bin_op.lhs);
8583 const llvm_elem_ty = try o.lowerPtrElemTy(ptr_ty.childType(zcu));8564 const llvm_elem_ty = try o.lowerPtrElemTy(pt, ptr_ty.childType(zcu));
8584 switch (ptr_ty.ptrSize(zcu)) {8565 switch (ptr_ty.ptrSize(zcu)) {
8585 // It's a pointer to an array, so according to LLVM we need an extra GEP index.8566 // It's a pointer to an array, so according to LLVM we need an extra GEP index.
8586 .one => return self.wip.gep(.inbounds, llvm_elem_ty, ptr, &.{8567 .one => return self.wip.gep(.inbounds, llvm_elem_ty, ptr, &.{
8587 try o.builder.intValue(try o.lowerType(Type.usize), 0), offset,8568 try o.builder.intValue(try o.lowerType(pt, Type.usize), 0), offset,
8588 }, ""),8569 }, ""),
8589 .c, .many => return self.wip.gep(.inbounds, llvm_elem_ty, ptr, &.{offset}, ""),8570 .c, .many => return self.wip.gep(.inbounds, llvm_elem_ty, ptr, &.{offset}, ""),
8590 .slice => {8571 .slice => {
...@@ -8596,18 +8577,19 @@ pub const FuncGen = struct {...@@ -8596,18 +8577,19 @@ pub const FuncGen = struct {
85968577
8597 fn airPtrSub(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {8578 fn airPtrSub(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
8598 const o = self.ng.object;8579 const o = self.ng.object;
8599 const zcu = o.pt.zcu;8580 const pt = self.ng.pt;
8581 const zcu = pt.zcu;
8600 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;8582 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
8601 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;8583 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;
8602 const ptr = try self.resolveInst(bin_op.lhs);8584 const ptr = try self.resolveInst(bin_op.lhs);
8603 const offset = try self.resolveInst(bin_op.rhs);8585 const offset = try self.resolveInst(bin_op.rhs);
8604 const negative_offset = try self.wip.neg(offset, "");8586 const negative_offset = try self.wip.neg(offset, "");
8605 const ptr_ty = self.typeOf(bin_op.lhs);8587 const ptr_ty = self.typeOf(bin_op.lhs);
8606 const llvm_elem_ty = try o.lowerPtrElemTy(ptr_ty.childType(zcu));8588 const llvm_elem_ty = try o.lowerPtrElemTy(pt, ptr_ty.childType(zcu));
8607 switch (ptr_ty.ptrSize(zcu)) {8589 switch (ptr_ty.ptrSize(zcu)) {
8608 // It's a pointer to an array, so according to LLVM we need an extra GEP index.8590 // It's a pointer to an array, so according to LLVM we need an extra GEP index.
8609 .one => return self.wip.gep(.inbounds, llvm_elem_ty, ptr, &.{8591 .one => return self.wip.gep(.inbounds, llvm_elem_ty, ptr, &.{
8610 try o.builder.intValue(try o.lowerType(Type.usize), 0), negative_offset,8592 try o.builder.intValue(try o.lowerType(pt, Type.usize), 0), negative_offset,
8611 }, ""),8593 }, ""),
8612 .c, .many => return self.wip.gep(.inbounds, llvm_elem_ty, ptr, &.{negative_offset}, ""),8594 .c, .many => return self.wip.gep(.inbounds, llvm_elem_ty, ptr, &.{negative_offset}, ""),
8613 .slice => {8595 .slice => {
...@@ -8624,7 +8606,7 @@ pub const FuncGen = struct {...@@ -8624,7 +8606,7 @@ pub const FuncGen = struct {
8624 unsigned_intrinsic: Builder.Intrinsic,8606 unsigned_intrinsic: Builder.Intrinsic,
8625 ) !Builder.Value {8607 ) !Builder.Value {
8626 const o = self.ng.object;8608 const o = self.ng.object;
8627 const pt = o.pt;8609 const pt = self.ng.pt;
8628 const zcu = pt.zcu;8610 const zcu = pt.zcu;
8629 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;8611 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
8630 const extra = self.air.extraData(Air.Bin, ty_pl.payload).data;8612 const extra = self.air.extraData(Air.Bin, ty_pl.payload).data;
...@@ -8637,8 +8619,8 @@ pub const FuncGen = struct {...@@ -8637,8 +8619,8 @@ pub const FuncGen = struct {
8637 const inst_ty = self.typeOfIndex(inst);8619 const inst_ty = self.typeOfIndex(inst);
86388620
8639 const intrinsic = if (scalar_ty.isSignedInt(zcu)) signed_intrinsic else unsigned_intrinsic;8621 const intrinsic = if (scalar_ty.isSignedInt(zcu)) signed_intrinsic else unsigned_intrinsic;
8640 const llvm_inst_ty = try o.lowerType(inst_ty);8622 const llvm_inst_ty = try o.lowerType(pt, inst_ty);
8641 const llvm_lhs_ty = try o.lowerType(lhs_ty);8623 const llvm_lhs_ty = try o.lowerType(pt, lhs_ty);
8642 const results =8624 const results =
8643 try self.wip.callIntrinsic(.normal, .none, intrinsic, &.{llvm_lhs_ty}, &.{ lhs, rhs }, "");8625 try self.wip.callIntrinsic(.normal, .none, intrinsic, &.{llvm_lhs_ty}, &.{ lhs, rhs }, "");
86448626
...@@ -8718,7 +8700,7 @@ pub const FuncGen = struct {...@@ -8718,7 +8700,7 @@ pub const FuncGen = struct {
8718 return o.builder.addFunction(8700 return o.builder.addFunction(
8719 try o.builder.fnType(return_type, param_types, .normal),8701 try o.builder.fnType(return_type, param_types, .normal),
8720 fn_name,8702 fn_name,
8721 toLlvmAddressSpace(.generic, o.pt.zcu.getTarget()),8703 toLlvmAddressSpace(.generic, self.ng.pt.zcu.getTarget()),
8722 );8704 );
8723 }8705 }
87248706
...@@ -8732,10 +8714,11 @@ pub const FuncGen = struct {...@@ -8732,10 +8714,11 @@ pub const FuncGen = struct {
8732 params: [2]Builder.Value,8714 params: [2]Builder.Value,
8733 ) !Builder.Value {8715 ) !Builder.Value {
8734 const o = self.ng.object;8716 const o = self.ng.object;
8735 const zcu = o.pt.zcu;8717 const pt = self.ng.pt;
8718 const zcu = pt.zcu;
8736 const target = zcu.getTarget();8719 const target = zcu.getTarget();
8737 const scalar_ty = ty.scalarType(zcu);8720 const scalar_ty = ty.scalarType(zcu);
8738 const scalar_llvm_ty = try o.lowerType(scalar_ty);8721 const scalar_llvm_ty = try o.lowerType(pt, scalar_ty);
87398722
8740 if (intrinsicsAllowed(scalar_ty, target)) {8723 if (intrinsicsAllowed(scalar_ty, target)) {
8741 const cond: Builder.FloatCondition = switch (pred) {8724 const cond: Builder.FloatCondition = switch (pred) {
...@@ -8838,10 +8821,11 @@ pub const FuncGen = struct {...@@ -8838,10 +8821,11 @@ pub const FuncGen = struct {
8838 params: [params_len]Builder.Value,8821 params: [params_len]Builder.Value,
8839 ) !Builder.Value {8822 ) !Builder.Value {
8840 const o = self.ng.object;8823 const o = self.ng.object;
8841 const zcu = o.pt.zcu;8824 const pt = self.ng.pt;
8825 const zcu = pt.zcu;
8842 const target = zcu.getTarget();8826 const target = zcu.getTarget();
8843 const scalar_ty = ty.scalarType(zcu);8827 const scalar_ty = ty.scalarType(zcu);
8844 const llvm_ty = try o.lowerType(ty);8828 const llvm_ty = try o.lowerType(pt, ty);
88458829
8846 if (op != .tan and intrinsicsAllowed(scalar_ty, target)) switch (op) {8830 if (op != .tan and intrinsicsAllowed(scalar_ty, target)) switch (op) {
8847 // Some operations are dedicated LLVM instructions, not available as intrinsics8831 // Some operations are dedicated LLVM instructions, not available as intrinsics
...@@ -8979,7 +8963,7 @@ pub const FuncGen = struct {...@@ -8979,7 +8963,7 @@ pub const FuncGen = struct {
89798963
8980 fn airShlWithOverflow(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {8964 fn airShlWithOverflow(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
8981 const o = self.ng.object;8965 const o = self.ng.object;
8982 const pt = o.pt;8966 const pt = self.ng.pt;
8983 const zcu = pt.zcu;8967 const zcu = pt.zcu;
8984 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;8968 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
8985 const extra = self.air.extraData(Air.Bin, ty_pl.payload).data;8969 const extra = self.air.extraData(Air.Bin, ty_pl.payload).data;
...@@ -8993,9 +8977,9 @@ pub const FuncGen = struct {...@@ -8993,9 +8977,9 @@ pub const FuncGen = struct {
8993 const lhs_scalar_ty = lhs_ty.scalarType(zcu);8977 const lhs_scalar_ty = lhs_ty.scalarType(zcu);
89948978
8995 const dest_ty = self.typeOfIndex(inst);8979 const dest_ty = self.typeOfIndex(inst);
8996 const llvm_dest_ty = try o.lowerType(dest_ty);8980 const llvm_dest_ty = try o.lowerType(pt, dest_ty);
89978981
8998 const casted_rhs = try self.wip.conv(.unsigned, rhs, try o.lowerType(lhs_ty), "");8982 const casted_rhs = try self.wip.conv(.unsigned, rhs, try o.lowerType(pt, lhs_ty), "");
89998983
9000 const result = try self.wip.bin(.shl, lhs, casted_rhs, "");8984 const result = try self.wip.bin(.shl, lhs, casted_rhs, "");
9001 const reconstructed = try self.wip.bin(if (lhs_scalar_ty.isSignedInt(zcu))8985 const reconstructed = try self.wip.bin(if (lhs_scalar_ty.isSignedInt(zcu))
...@@ -9052,7 +9036,8 @@ pub const FuncGen = struct {...@@ -9052,7 +9036,8 @@ pub const FuncGen = struct {
90529036
9053 fn airShlExact(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9037 fn airShlExact(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9054 const o = self.ng.object;9038 const o = self.ng.object;
9055 const zcu = o.pt.zcu;9039 const pt = self.ng.pt;
9040 const zcu = pt.zcu;
9056 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;9041 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
90579042
9058 const lhs = try self.resolveInst(bin_op.lhs);9043 const lhs = try self.resolveInst(bin_op.lhs);
...@@ -9063,7 +9048,7 @@ pub const FuncGen = struct {...@@ -9063,7 +9048,7 @@ pub const FuncGen = struct {
9063 return self.ng.todo("implement vector shifts with scalar rhs", .{});9048 return self.ng.todo("implement vector shifts with scalar rhs", .{});
9064 const lhs_scalar_ty = lhs_ty.scalarType(zcu);9049 const lhs_scalar_ty = lhs_ty.scalarType(zcu);
90659050
9066 const casted_rhs = try self.wip.conv(.unsigned, rhs, try o.lowerType(lhs_ty), "");9051 const casted_rhs = try self.wip.conv(.unsigned, rhs, try o.lowerType(pt, lhs_ty), "");
9067 return self.wip.bin(if (lhs_scalar_ty.isSignedInt(zcu))9052 return self.wip.bin(if (lhs_scalar_ty.isSignedInt(zcu))
9068 .@"shl nsw"9053 .@"shl nsw"
9069 else9054 else
...@@ -9072,7 +9057,8 @@ pub const FuncGen = struct {...@@ -9072,7 +9057,8 @@ pub const FuncGen = struct {
90729057
9073 fn airShl(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9058 fn airShl(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9074 const o = self.ng.object;9059 const o = self.ng.object;
9075 const zcu = o.pt.zcu;9060 const pt = self.ng.pt;
9061 const zcu = pt.zcu;
9076 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;9062 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
90779063
9078 const lhs = try self.resolveInst(bin_op.lhs);9064 const lhs = try self.resolveInst(bin_op.lhs);
...@@ -9082,13 +9068,13 @@ pub const FuncGen = struct {...@@ -9082,13 +9068,13 @@ pub const FuncGen = struct {
9082 if (lhs_ty.isVector(zcu) and !self.typeOf(bin_op.rhs).isVector(zcu))9068 if (lhs_ty.isVector(zcu) and !self.typeOf(bin_op.rhs).isVector(zcu))
9083 return self.ng.todo("implement vector shifts with scalar rhs", .{});9069 return self.ng.todo("implement vector shifts with scalar rhs", .{});
90849070
9085 const casted_rhs = try self.wip.conv(.unsigned, rhs, try o.lowerType(lhs_ty), "");9071 const casted_rhs = try self.wip.conv(.unsigned, rhs, try o.lowerType(pt, lhs_ty), "");
9086 return self.wip.bin(.shl, lhs, casted_rhs, "");9072 return self.wip.bin(.shl, lhs, casted_rhs, "");
9087 }9073 }
90889074
9089 fn airShlSat(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9075 fn airShlSat(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9090 const o = self.ng.object;9076 const o = self.ng.object;
9091 const pt = o.pt;9077 const pt = self.ng.pt;
9092 const zcu = pt.zcu;9078 const zcu = pt.zcu;
9093 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;9079 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
90949080
...@@ -9097,7 +9083,7 @@ pub const FuncGen = struct {...@@ -9097,7 +9083,7 @@ pub const FuncGen = struct {
90979083
9098 const lhs_ty = self.typeOf(bin_op.lhs);9084 const lhs_ty = self.typeOf(bin_op.lhs);
9099 const lhs_info = lhs_ty.intInfo(zcu);9085 const lhs_info = lhs_ty.intInfo(zcu);
9100 const llvm_lhs_ty = try o.lowerType(lhs_ty);9086 const llvm_lhs_ty = try o.lowerType(pt, lhs_ty);
9101 const llvm_lhs_scalar_ty = llvm_lhs_ty.scalarType(&o.builder);9087 const llvm_lhs_scalar_ty = llvm_lhs_ty.scalarType(&o.builder);
91029088
9103 const rhs_ty = self.typeOf(bin_op.rhs);9089 const rhs_ty = self.typeOf(bin_op.rhs);
...@@ -9105,7 +9091,7 @@ pub const FuncGen = struct {...@@ -9105,7 +9091,7 @@ pub const FuncGen = struct {
9105 return self.ng.todo("implement vector shifts with scalar rhs", .{});9091 return self.ng.todo("implement vector shifts with scalar rhs", .{});
9106 const rhs_info = rhs_ty.intInfo(zcu);9092 const rhs_info = rhs_ty.intInfo(zcu);
9107 assert(rhs_info.signedness == .unsigned);9093 assert(rhs_info.signedness == .unsigned);
9108 const llvm_rhs_ty = try o.lowerType(rhs_ty);9094 const llvm_rhs_ty = try o.lowerType(pt, rhs_ty);
9109 const llvm_rhs_scalar_ty = llvm_rhs_ty.scalarType(&o.builder);9095 const llvm_rhs_scalar_ty = llvm_rhs_ty.scalarType(&o.builder);
91109096
9111 const result = try self.wip.callIntrinsic(9097 const result = try self.wip.callIntrinsic(
...@@ -9168,7 +9154,8 @@ pub const FuncGen = struct {...@@ -9168,7 +9154,8 @@ pub const FuncGen = struct {
91689154
9169 fn airShr(self: *FuncGen, inst: Air.Inst.Index, is_exact: bool) !Builder.Value {9155 fn airShr(self: *FuncGen, inst: Air.Inst.Index, is_exact: bool) !Builder.Value {
9170 const o = self.ng.object;9156 const o = self.ng.object;
9171 const zcu = o.pt.zcu;9157 const pt = self.ng.pt;
9158 const zcu = pt.zcu;
9172 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;9159 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
91739160
9174 const lhs = try self.resolveInst(bin_op.lhs);9161 const lhs = try self.resolveInst(bin_op.lhs);
...@@ -9179,7 +9166,7 @@ pub const FuncGen = struct {...@@ -9179,7 +9166,7 @@ pub const FuncGen = struct {
9179 return self.ng.todo("implement vector shifts with scalar rhs", .{});9166 return self.ng.todo("implement vector shifts with scalar rhs", .{});
9180 const lhs_scalar_ty = lhs_ty.scalarType(zcu);9167 const lhs_scalar_ty = lhs_ty.scalarType(zcu);
91819168
9182 const casted_rhs = try self.wip.conv(.unsigned, rhs, try o.lowerType(lhs_ty), "");9169 const casted_rhs = try self.wip.conv(.unsigned, rhs, try o.lowerType(pt, lhs_ty), "");
9183 const is_signed_int = lhs_scalar_ty.isSignedInt(zcu);9170 const is_signed_int = lhs_scalar_ty.isSignedInt(zcu);
91849171
9185 return self.wip.bin(if (is_exact)9172 return self.wip.bin(if (is_exact)
...@@ -9189,7 +9176,8 @@ pub const FuncGen = struct {...@@ -9189,7 +9176,8 @@ pub const FuncGen = struct {
91899176
9190 fn airAbs(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9177 fn airAbs(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9191 const o = self.ng.object;9178 const o = self.ng.object;
9192 const zcu = o.pt.zcu;9179 const pt = self.ng.pt;
9180 const zcu = pt.zcu;
9193 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;9181 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
9194 const operand = try self.resolveInst(ty_op.operand);9182 const operand = try self.resolveInst(ty_op.operand);
9195 const operand_ty = self.typeOf(ty_op.operand);9183 const operand_ty = self.typeOf(ty_op.operand);
...@@ -9200,7 +9188,7 @@ pub const FuncGen = struct {...@@ -9200,7 +9188,7 @@ pub const FuncGen = struct {
9200 .normal,9188 .normal,
9201 .none,9189 .none,
9202 .abs,9190 .abs,
9203 &.{try o.lowerType(operand_ty)},9191 &.{try o.lowerType(pt, operand_ty)},
9204 &.{ operand, try o.builder.intValue(.i1, 0) },9192 &.{ operand, try o.builder.intValue(.i1, 0) },
9205 "",9193 "",
9206 ),9194 ),
...@@ -9211,10 +9199,11 @@ pub const FuncGen = struct {...@@ -9211,10 +9199,11 @@ pub const FuncGen = struct {
92119199
9212 fn airIntCast(fg: *FuncGen, inst: Air.Inst.Index, safety: bool) !Builder.Value {9200 fn airIntCast(fg: *FuncGen, inst: Air.Inst.Index, safety: bool) !Builder.Value {
9213 const o = fg.ng.object;9201 const o = fg.ng.object;
9214 const zcu = o.pt.zcu;9202 const pt = fg.ng.pt;
9203 const zcu = pt.zcu;
9215 const ty_op = fg.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;9204 const ty_op = fg.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
9216 const dest_ty = fg.typeOfIndex(inst);9205 const dest_ty = fg.typeOfIndex(inst);
9217 const dest_llvm_ty = try o.lowerType(dest_ty);9206 const dest_llvm_ty = try o.lowerType(pt, dest_ty);
9218 const operand = try fg.resolveInst(ty_op.operand);9207 const operand = try fg.resolveInst(ty_op.operand);
9219 const operand_ty = fg.typeOf(ty_op.operand);9208 const operand_ty = fg.typeOf(ty_op.operand);
9220 const operand_info = operand_ty.intInfo(zcu);9209 const operand_info = operand_ty.intInfo(zcu);
...@@ -9243,8 +9232,8 @@ pub const FuncGen = struct {...@@ -9243,8 +9232,8 @@ pub const FuncGen = struct {
92439232
9244 if (!have_min_check and !have_max_check) break :safety;9233 if (!have_min_check and !have_max_check) break :safety;
92459234
9246 const operand_llvm_ty = try o.lowerType(operand_ty);9235 const operand_llvm_ty = try o.lowerType(pt, operand_ty);
9247 const operand_scalar_llvm_ty = try o.lowerType(operand_scalar);9236 const operand_scalar_llvm_ty = try o.lowerType(pt, operand_scalar);
92489237
9249 const is_vector = operand_ty.zigTypeTag(zcu) == .vector;9238 const is_vector = operand_ty.zigTypeTag(zcu) == .vector;
9250 assert(is_vector == (dest_ty.zigTypeTag(zcu) == .vector));9239 assert(is_vector == (dest_ty.zigTypeTag(zcu) == .vector));
...@@ -9313,15 +9302,17 @@ pub const FuncGen = struct {...@@ -9313,15 +9302,17 @@ pub const FuncGen = struct {
93139302
9314 fn airTrunc(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9303 fn airTrunc(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9315 const o = self.ng.object;9304 const o = self.ng.object;
9305 const pt = self.ng.pt;
9316 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;9306 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
9317 const operand = try self.resolveInst(ty_op.operand);9307 const operand = try self.resolveInst(ty_op.operand);
9318 const dest_llvm_ty = try o.lowerType(self.typeOfIndex(inst));9308 const dest_llvm_ty = try o.lowerType(pt, self.typeOfIndex(inst));
9319 return self.wip.cast(.trunc, operand, dest_llvm_ty, "");9309 return self.wip.cast(.trunc, operand, dest_llvm_ty, "");
9320 }9310 }
93219311
9322 fn airFptrunc(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9312 fn airFptrunc(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9323 const o = self.ng.object;9313 const o = self.ng.object;
9324 const zcu = o.pt.zcu;9314 const pt = self.ng.pt;
9315 const zcu = pt.zcu;
9325 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;9316 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
9326 const operand = try self.resolveInst(ty_op.operand);9317 const operand = try self.resolveInst(ty_op.operand);
9327 const operand_ty = self.typeOf(ty_op.operand);9318 const operand_ty = self.typeOf(ty_op.operand);
...@@ -9329,10 +9320,10 @@ pub const FuncGen = struct {...@@ -9329,10 +9320,10 @@ pub const FuncGen = struct {
9329 const target = zcu.getTarget();9320 const target = zcu.getTarget();
93309321
9331 if (intrinsicsAllowed(dest_ty, target) and intrinsicsAllowed(operand_ty, target)) {9322 if (intrinsicsAllowed(dest_ty, target) and intrinsicsAllowed(operand_ty, target)) {
9332 return self.wip.cast(.fptrunc, operand, try o.lowerType(dest_ty), "");9323 return self.wip.cast(.fptrunc, operand, try o.lowerType(pt, dest_ty), "");
9333 } else {9324 } else {
9334 const operand_llvm_ty = try o.lowerType(operand_ty);9325 const operand_llvm_ty = try o.lowerType(pt, operand_ty);
9335 const dest_llvm_ty = try o.lowerType(dest_ty);9326 const dest_llvm_ty = try o.lowerType(pt, dest_ty);
93369327
9337 const dest_bits = dest_ty.floatBits(target);9328 const dest_bits = dest_ty.floatBits(target);
9338 const src_bits = operand_ty.floatBits(target);9329 const src_bits = operand_ty.floatBits(target);
...@@ -9355,7 +9346,8 @@ pub const FuncGen = struct {...@@ -9355,7 +9346,8 @@ pub const FuncGen = struct {
93559346
9356 fn airFpext(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9347 fn airFpext(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9357 const o = self.ng.object;9348 const o = self.ng.object;
9358 const zcu = o.pt.zcu;9349 const pt = self.ng.pt;
9350 const zcu = pt.zcu;
9359 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;9351 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
9360 const operand = try self.resolveInst(ty_op.operand);9352 const operand = try self.resolveInst(ty_op.operand);
9361 const operand_ty = self.typeOf(ty_op.operand);9353 const operand_ty = self.typeOf(ty_op.operand);
...@@ -9363,10 +9355,10 @@ pub const FuncGen = struct {...@@ -9363,10 +9355,10 @@ pub const FuncGen = struct {
9363 const target = zcu.getTarget();9355 const target = zcu.getTarget();
93649356
9365 if (intrinsicsAllowed(dest_ty, target) and intrinsicsAllowed(operand_ty, target)) {9357 if (intrinsicsAllowed(dest_ty, target) and intrinsicsAllowed(operand_ty, target)) {
9366 return self.wip.cast(.fpext, operand, try o.lowerType(dest_ty), "");9358 return self.wip.cast(.fpext, operand, try o.lowerType(pt, dest_ty), "");
9367 } else {9359 } else {
9368 const operand_llvm_ty = try o.lowerType(operand_ty);9360 const operand_llvm_ty = try o.lowerType(pt, operand_ty);
9369 const dest_llvm_ty = try o.lowerType(dest_ty);9361 const dest_llvm_ty = try o.lowerType(pt, dest_ty);
93709362
9371 const dest_bits = dest_ty.scalarType(zcu).floatBits(target);9363 const dest_bits = dest_ty.scalarType(zcu).floatBits(target);
9372 const src_bits = operand_ty.scalarType(zcu).floatBits(target);9364 const src_bits = operand_ty.scalarType(zcu).floatBits(target);
...@@ -9403,11 +9395,11 @@ pub const FuncGen = struct {...@@ -9403,11 +9395,11 @@ pub const FuncGen = struct {
94039395
9404 fn bitCast(self: *FuncGen, operand: Builder.Value, operand_ty: Type, inst_ty: Type) !Builder.Value {9396 fn bitCast(self: *FuncGen, operand: Builder.Value, operand_ty: Type, inst_ty: Type) !Builder.Value {
9405 const o = self.ng.object;9397 const o = self.ng.object;
9406 const pt = o.pt;9398 const pt = self.ng.pt;
9407 const zcu = pt.zcu;9399 const zcu = pt.zcu;
9408 const operand_is_ref = isByRef(operand_ty, zcu);9400 const operand_is_ref = isByRef(operand_ty, zcu);
9409 const result_is_ref = isByRef(inst_ty, zcu);9401 const result_is_ref = isByRef(inst_ty, zcu);
9410 const llvm_dest_ty = try o.lowerType(inst_ty);9402 const llvm_dest_ty = try o.lowerType(pt, inst_ty);
94119403
9412 if (operand_is_ref and result_is_ref) {9404 if (operand_is_ref and result_is_ref) {
9413 // They are both pointers, so just return the same opaque pointer :)9405 // They are both pointers, so just return the same opaque pointer :)
...@@ -9442,7 +9434,7 @@ pub const FuncGen = struct {...@@ -9442,7 +9434,7 @@ pub const FuncGen = struct {
9442 } else {9434 } else {
9443 // If the ABI size of the element type is not evenly divisible by size in bits;9435 // If the ABI size of the element type is not evenly divisible by size in bits;
9444 // a simple bitcast will not work, and we fall back to extractelement.9436 // a simple bitcast will not work, and we fall back to extractelement.
9445 const llvm_usize = try o.lowerType(Type.usize);9437 const llvm_usize = try o.lowerType(pt, Type.usize);
9446 const usize_zero = try o.builder.intValue(llvm_usize, 0);9438 const usize_zero = try o.builder.intValue(llvm_usize, 0);
9447 const vector_len = operand_ty.arrayLen(zcu);9439 const vector_len = operand_ty.arrayLen(zcu);
9448 var i: u64 = 0;9440 var i: u64 = 0;
...@@ -9458,7 +9450,7 @@ pub const FuncGen = struct {...@@ -9458,7 +9450,7 @@ pub const FuncGen = struct {
9458 return array_ptr;9450 return array_ptr;
9459 } else if (operand_ty.zigTypeTag(zcu) == .array and inst_ty.zigTypeTag(zcu) == .vector) {9451 } else if (operand_ty.zigTypeTag(zcu) == .array and inst_ty.zigTypeTag(zcu) == .vector) {
9460 const elem_ty = operand_ty.childType(zcu);9452 const elem_ty = operand_ty.childType(zcu);
9461 const llvm_vector_ty = try o.lowerType(inst_ty);9453 const llvm_vector_ty = try o.lowerType(pt, inst_ty);
9462 if (!operand_is_ref) return self.ng.todo("implement bitcast non-ref array to vector", .{});9454 if (!operand_is_ref) return self.ng.todo("implement bitcast non-ref array to vector", .{});
94639455
9464 const bitcast_ok = elem_ty.bitSize(zcu) == elem_ty.abiSize(zcu) * 8;9456 const bitcast_ok = elem_ty.bitSize(zcu) == elem_ty.abiSize(zcu) * 8;
...@@ -9470,9 +9462,9 @@ pub const FuncGen = struct {...@@ -9470,9 +9462,9 @@ pub const FuncGen = struct {
9470 } else {9462 } else {
9471 // If the ABI size of the element type is not evenly divisible by size in bits;9463 // If the ABI size of the element type is not evenly divisible by size in bits;
9472 // a simple bitcast will not work, and we fall back to extractelement.9464 // a simple bitcast will not work, and we fall back to extractelement.
9473 const array_llvm_ty = try o.lowerType(operand_ty);9465 const array_llvm_ty = try o.lowerType(pt, operand_ty);
9474 const elem_llvm_ty = try o.lowerType(elem_ty);9466 const elem_llvm_ty = try o.lowerType(pt, elem_ty);
9475 const llvm_usize = try o.lowerType(Type.usize);9467 const llvm_usize = try o.lowerType(pt, Type.usize);
9476 const usize_zero = try o.builder.intValue(llvm_usize, 0);9468 const usize_zero = try o.builder.intValue(llvm_usize, 0);
9477 const vector_len = operand_ty.arrayLen(zcu);9469 const vector_len = operand_ty.arrayLen(zcu);
9478 var vector = try o.builder.poisonValue(llvm_vector_ty);9470 var vector = try o.builder.poisonValue(llvm_vector_ty);
...@@ -9519,7 +9511,7 @@ pub const FuncGen = struct {...@@ -9519,7 +9511,7 @@ pub const FuncGen = struct {
95199511
9520 fn airArg(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9512 fn airArg(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9521 const o = self.ng.object;9513 const o = self.ng.object;
9522 const pt = o.pt;9514 const pt = self.ng.pt;
9523 const zcu = pt.zcu;9515 const zcu = pt.zcu;
9524 const arg_val = self.args[self.arg_index];9516 const arg_val = self.args[self.arg_index];
9525 self.arg_index += 1;9517 self.arg_index += 1;
...@@ -9547,7 +9539,7 @@ pub const FuncGen = struct {...@@ -9547,7 +9539,7 @@ pub const FuncGen = struct {
9547 self.file,9539 self.file,
9548 self.scope,9540 self.scope,
9549 lbrace_line,9541 lbrace_line,
9550 try o.lowerDebugType(inst_ty),9542 try o.lowerDebugType(pt, inst_ty),
9551 self.arg_index,9543 self.arg_index,
9552 );9544 );
95539545
...@@ -9611,28 +9603,28 @@ pub const FuncGen = struct {...@@ -9611,28 +9603,28 @@ pub const FuncGen = struct {
96119603
9612 fn airAlloc(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9604 fn airAlloc(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9613 const o = self.ng.object;9605 const o = self.ng.object;
9614 const pt = o.pt;9606 const pt = self.ng.pt;
9615 const zcu = pt.zcu;9607 const zcu = pt.zcu;
9616 const ptr_ty = self.typeOfIndex(inst);9608 const ptr_ty = self.typeOfIndex(inst);
9617 const pointee_type = ptr_ty.childType(zcu);9609 const pointee_type = ptr_ty.childType(zcu);
9618 if (!pointee_type.isFnOrHasRuntimeBitsIgnoreComptime(zcu))9610 if (!pointee_type.isFnOrHasRuntimeBitsIgnoreComptime(zcu))
9619 return (try o.lowerPtrToVoid(ptr_ty)).toValue();9611 return (try o.lowerPtrToVoid(pt, ptr_ty)).toValue();
96209612
9621 const pointee_llvm_ty = try o.lowerType(pointee_type);9613 const pointee_llvm_ty = try o.lowerType(pt, pointee_type);
9622 const alignment = ptr_ty.ptrAlignment(zcu).toLlvm();9614 const alignment = ptr_ty.ptrAlignment(zcu).toLlvm();
9623 return self.buildAlloca(pointee_llvm_ty, alignment);9615 return self.buildAlloca(pointee_llvm_ty, alignment);
9624 }9616 }
96259617
9626 fn airRetPtr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9618 fn airRetPtr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9627 const o = self.ng.object;9619 const o = self.ng.object;
9628 const pt = o.pt;9620 const pt = self.ng.pt;
9629 const zcu = pt.zcu;9621 const zcu = pt.zcu;
9630 const ptr_ty = self.typeOfIndex(inst);9622 const ptr_ty = self.typeOfIndex(inst);
9631 const ret_ty = ptr_ty.childType(zcu);9623 const ret_ty = ptr_ty.childType(zcu);
9632 if (!ret_ty.isFnOrHasRuntimeBitsIgnoreComptime(zcu))9624 if (!ret_ty.isFnOrHasRuntimeBitsIgnoreComptime(zcu))
9633 return (try o.lowerPtrToVoid(ptr_ty)).toValue();9625 return (try o.lowerPtrToVoid(pt, ptr_ty)).toValue();
9634 if (self.ret_ptr != .none) return self.ret_ptr;9626 if (self.ret_ptr != .none) return self.ret_ptr;
9635 const ret_llvm_ty = try o.lowerType(ret_ty);9627 const ret_llvm_ty = try o.lowerType(pt, ret_ty);
9636 const alignment = ptr_ty.ptrAlignment(zcu).toLlvm();9628 const alignment = ptr_ty.ptrAlignment(zcu).toLlvm();
9637 return self.buildAlloca(ret_llvm_ty, alignment);9629 return self.buildAlloca(ret_llvm_ty, alignment);
9638 }9630 }
...@@ -9644,13 +9636,13 @@ pub const FuncGen = struct {...@@ -9644,13 +9636,13 @@ pub const FuncGen = struct {
9644 llvm_ty: Builder.Type,9636 llvm_ty: Builder.Type,
9645 alignment: Builder.Alignment,9637 alignment: Builder.Alignment,
9646 ) Allocator.Error!Builder.Value {9638 ) Allocator.Error!Builder.Value {
9647 const target = self.ng.object.pt.zcu.getTarget();9639 const target = self.ng.pt.zcu.getTarget();
9648 return buildAllocaInner(&self.wip, llvm_ty, alignment, target);9640 return buildAllocaInner(&self.wip, llvm_ty, alignment, target);
9649 }9641 }
96509642
9651 fn airStore(self: *FuncGen, inst: Air.Inst.Index, safety: bool) !Builder.Value {9643 fn airStore(self: *FuncGen, inst: Air.Inst.Index, safety: bool) !Builder.Value {
9652 const o = self.ng.object;9644 const o = self.ng.object;
9653 const pt = o.pt;9645 const pt = self.ng.pt;
9654 const zcu = pt.zcu;9646 const zcu = pt.zcu;
9655 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;9647 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
9656 const dest_ptr = try self.resolveInst(bin_op.lhs);9648 const dest_ptr = try self.resolveInst(bin_op.lhs);
...@@ -9685,7 +9677,7 @@ pub const FuncGen = struct {...@@ -9685,7 +9677,7 @@ pub const FuncGen = struct {
96859677
9686 self.maybeMarkAllowZeroAccess(ptr_info);9678 self.maybeMarkAllowZeroAccess(ptr_info);
96879679
9688 const len = try o.builder.intValue(try o.lowerType(Type.usize), operand_ty.abiSize(zcu));9680 const len = try o.builder.intValue(try o.lowerType(pt, Type.usize), operand_ty.abiSize(zcu));
9689 _ = try self.wip.callMemSet(9681 _ = try self.wip.callMemSet(
9690 dest_ptr,9682 dest_ptr,
9691 ptr_ty.ptrAlignment(zcu).toLlvm(),9683 ptr_ty.ptrAlignment(zcu).toLlvm(),
...@@ -9714,8 +9706,7 @@ pub const FuncGen = struct {...@@ -9714,8 +9706,7 @@ pub const FuncGen = struct {
9714 ///9706 ///
9715 /// The first instruction of `body_tail` is the one whose copy we want to elide.9707 /// The first instruction of `body_tail` is the one whose copy we want to elide.
9716 fn canElideLoad(fg: *FuncGen, body_tail: []const Air.Inst.Index) bool {9708 fn canElideLoad(fg: *FuncGen, body_tail: []const Air.Inst.Index) bool {
9717 const o = fg.ng.object;9709 const zcu = fg.ng.pt.zcu;
9718 const zcu = o.pt.zcu;
9719 const ip = &zcu.intern_pool;9710 const ip = &zcu.intern_pool;
9720 for (body_tail[1..]) |body_inst| {9711 for (body_tail[1..]) |body_inst| {
9721 switch (fg.liveness.categorizeOperand(fg.air, zcu, body_inst, body_tail[0], ip)) {9712 switch (fg.liveness.categorizeOperand(fg.air, zcu, body_inst, body_tail[0], ip)) {
...@@ -9730,8 +9721,7 @@ pub const FuncGen = struct {...@@ -9730,8 +9721,7 @@ pub const FuncGen = struct {
9730 }9721 }
97319722
9732 fn airLoad(fg: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {9723 fn airLoad(fg: *FuncGen, body_tail: []const Air.Inst.Index) !Builder.Value {
9733 const o = fg.ng.object;9724 const pt = fg.ng.pt;
9734 const pt = o.pt;
9735 const zcu = pt.zcu;9725 const zcu = pt.zcu;
9736 const inst = body_tail[0];9726 const inst = body_tail[0];
9737 const ty_op = fg.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;9727 const ty_op = fg.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
...@@ -9765,8 +9755,9 @@ pub const FuncGen = struct {...@@ -9765,8 +9755,9 @@ pub const FuncGen = struct {
9765 fn airRetAddr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9755 fn airRetAddr(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9766 _ = inst;9756 _ = inst;
9767 const o = self.ng.object;9757 const o = self.ng.object;
9768 const llvm_usize = try o.lowerType(Type.usize);9758 const pt = self.ng.pt;
9769 if (!target_util.supportsReturnAddress(o.pt.zcu.getTarget(), self.ng.ownerModule().optimize_mode)) {9759 const llvm_usize = try o.lowerType(pt, Type.usize);
9760 if (!target_util.supportsReturnAddress(self.ng.pt.zcu.getTarget(), self.ng.ownerModule().optimize_mode)) {
9770 // https://github.com/ziglang/zig/issues/119469761 // https://github.com/ziglang/zig/issues/11946
9771 return o.builder.intValue(llvm_usize, 0);9762 return o.builder.intValue(llvm_usize, 0);
9772 }9763 }
...@@ -9777,8 +9768,9 @@ pub const FuncGen = struct {...@@ -9777,8 +9768,9 @@ pub const FuncGen = struct {
9777 fn airFrameAddress(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9768 fn airFrameAddress(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9778 _ = inst;9769 _ = inst;
9779 const o = self.ng.object;9770 const o = self.ng.object;
9771 const pt = self.ng.pt;
9780 const result = try self.wip.callIntrinsic(.normal, .none, .frameaddress, &.{.ptr}, &.{.@"0"}, "");9772 const result = try self.wip.callIntrinsic(.normal, .none, .frameaddress, &.{.ptr}, &.{.@"0"}, "");
9781 return self.wip.cast(.ptrtoint, result, try o.lowerType(Type.usize), "");9773 return self.wip.cast(.ptrtoint, result, try o.lowerType(pt, Type.usize), "");
9782 }9774 }
97839775
9784 fn airCmpxchg(9776 fn airCmpxchg(
...@@ -9787,7 +9779,7 @@ pub const FuncGen = struct {...@@ -9787,7 +9779,7 @@ pub const FuncGen = struct {
9787 kind: Builder.Function.Instruction.CmpXchg.Kind,9779 kind: Builder.Function.Instruction.CmpXchg.Kind,
9788 ) !Builder.Value {9780 ) !Builder.Value {
9789 const o = self.ng.object;9781 const o = self.ng.object;
9790 const pt = o.pt;9782 const pt = self.ng.pt;
9791 const zcu = pt.zcu;9783 const zcu = pt.zcu;
9792 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;9784 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
9793 const extra = self.air.extraData(Air.Cmpxchg, ty_pl.payload).data;9785 const extra = self.air.extraData(Air.Cmpxchg, ty_pl.payload).data;
...@@ -9796,8 +9788,8 @@ pub const FuncGen = struct {...@@ -9796,8 +9788,8 @@ pub const FuncGen = struct {
9796 var expected_value = try self.resolveInst(extra.expected_value);9788 var expected_value = try self.resolveInst(extra.expected_value);
9797 var new_value = try self.resolveInst(extra.new_value);9789 var new_value = try self.resolveInst(extra.new_value);
9798 const operand_ty = ptr_ty.childType(zcu);9790 const operand_ty = ptr_ty.childType(zcu);
9799 const llvm_operand_ty = try o.lowerType(operand_ty);9791 const llvm_operand_ty = try o.lowerType(pt, operand_ty);
9800 const llvm_abi_ty = try o.getAtomicAbiType(operand_ty, false);9792 const llvm_abi_ty = try o.getAtomicAbiType(pt, operand_ty, false);
9801 if (llvm_abi_ty != .none) {9793 if (llvm_abi_ty != .none) {
9802 // operand needs widening and truncating9794 // operand needs widening and truncating
9803 const signedness: Builder.Function.Instruction.Cast.Signedness =9795 const signedness: Builder.Function.Instruction.Cast.Signedness =
...@@ -9840,7 +9832,7 @@ pub const FuncGen = struct {...@@ -9840,7 +9832,7 @@ pub const FuncGen = struct {
98409832
9841 fn airAtomicRmw(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9833 fn airAtomicRmw(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9842 const o = self.ng.object;9834 const o = self.ng.object;
9843 const pt = o.pt;9835 const pt = self.ng.pt;
9844 const zcu = pt.zcu;9836 const zcu = pt.zcu;
9845 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;9837 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
9846 const extra = self.air.extraData(Air.AtomicRmw, pl_op.payload).data;9838 const extra = self.air.extraData(Air.AtomicRmw, pl_op.payload).data;
...@@ -9852,8 +9844,8 @@ pub const FuncGen = struct {...@@ -9852,8 +9844,8 @@ pub const FuncGen = struct {
9852 const is_float = operand_ty.isRuntimeFloat();9844 const is_float = operand_ty.isRuntimeFloat();
9853 const op = toLlvmAtomicRmwBinOp(extra.op(), is_signed_int, is_float);9845 const op = toLlvmAtomicRmwBinOp(extra.op(), is_signed_int, is_float);
9854 const ordering = toLlvmAtomicOrdering(extra.ordering());9846 const ordering = toLlvmAtomicOrdering(extra.ordering());
9855 const llvm_abi_ty = try o.getAtomicAbiType(operand_ty, op == .xchg);9847 const llvm_abi_ty = try o.getAtomicAbiType(pt, operand_ty, op == .xchg);
9856 const llvm_operand_ty = try o.lowerType(operand_ty);9848 const llvm_operand_ty = try o.lowerType(pt, operand_ty);
98579849
9858 const access_kind: Builder.MemoryAccessKind =9850 const access_kind: Builder.MemoryAccessKind =
9859 if (ptr_ty.isVolatilePtr(zcu)) .@"volatile" else .normal;9851 if (ptr_ty.isVolatilePtr(zcu)) .@"volatile" else .normal;
...@@ -9896,7 +9888,7 @@ pub const FuncGen = struct {...@@ -9896,7 +9888,7 @@ pub const FuncGen = struct {
9896 access_kind,9888 access_kind,
9897 op,9889 op,
9898 ptr,9890 ptr,
9899 try self.wip.cast(.ptrtoint, operand, try o.lowerType(Type.usize), ""),9891 try self.wip.cast(.ptrtoint, operand, try o.lowerType(pt, Type.usize), ""),
9900 self.sync_scope,9892 self.sync_scope,
9901 ordering,9893 ordering,
9902 ptr_alignment,9894 ptr_alignment,
...@@ -9906,7 +9898,7 @@ pub const FuncGen = struct {...@@ -9906,7 +9898,7 @@ pub const FuncGen = struct {
99069898
9907 fn airAtomicLoad(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {9899 fn airAtomicLoad(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
9908 const o = self.ng.object;9900 const o = self.ng.object;
9909 const pt = o.pt;9901 const pt = self.ng.pt;
9910 const zcu = pt.zcu;9902 const zcu = pt.zcu;
9911 const atomic_load = self.air.instructions.items(.data)[@intFromEnum(inst)].atomic_load;9903 const atomic_load = self.air.instructions.items(.data)[@intFromEnum(inst)].atomic_load;
9912 const ptr = try self.resolveInst(atomic_load.ptr);9904 const ptr = try self.resolveInst(atomic_load.ptr);
...@@ -9915,14 +9907,14 @@ pub const FuncGen = struct {...@@ -9915,14 +9907,14 @@ pub const FuncGen = struct {
9915 const elem_ty = Type.fromInterned(info.child);9907 const elem_ty = Type.fromInterned(info.child);
9916 if (!elem_ty.hasRuntimeBitsIgnoreComptime(zcu)) return .none;9908 if (!elem_ty.hasRuntimeBitsIgnoreComptime(zcu)) return .none;
9917 const ordering = toLlvmAtomicOrdering(atomic_load.order);9909 const ordering = toLlvmAtomicOrdering(atomic_load.order);
9918 const llvm_abi_ty = try o.getAtomicAbiType(elem_ty, false);9910 const llvm_abi_ty = try o.getAtomicAbiType(pt, elem_ty, false);
9919 const ptr_alignment = (if (info.flags.alignment != .none)9911 const ptr_alignment = (if (info.flags.alignment != .none)
9920 @as(InternPool.Alignment, info.flags.alignment)9912 @as(InternPool.Alignment, info.flags.alignment)
9921 else9913 else
9922 Type.fromInterned(info.child).abiAlignment(zcu)).toLlvm();9914 Type.fromInterned(info.child).abiAlignment(zcu)).toLlvm();
9923 const access_kind: Builder.MemoryAccessKind =9915 const access_kind: Builder.MemoryAccessKind =
9924 if (info.flags.is_volatile) .@"volatile" else .normal;9916 if (info.flags.is_volatile) .@"volatile" else .normal;
9925 const elem_llvm_ty = try o.lowerType(elem_ty);9917 const elem_llvm_ty = try o.lowerType(pt, elem_ty);
99269918
9927 self.maybeMarkAllowZeroAccess(info);9919 self.maybeMarkAllowZeroAccess(info);
99289920
...@@ -9956,7 +9948,7 @@ pub const FuncGen = struct {...@@ -9956,7 +9948,7 @@ pub const FuncGen = struct {
9956 ordering: Builder.AtomicOrdering,9948 ordering: Builder.AtomicOrdering,
9957 ) !Builder.Value {9949 ) !Builder.Value {
9958 const o = self.ng.object;9950 const o = self.ng.object;
9959 const pt = o.pt;9951 const pt = self.ng.pt;
9960 const zcu = pt.zcu;9952 const zcu = pt.zcu;
9961 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;9953 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
9962 const ptr_ty = self.typeOf(bin_op.lhs);9954 const ptr_ty = self.typeOf(bin_op.lhs);
...@@ -9964,7 +9956,7 @@ pub const FuncGen = struct {...@@ -9964,7 +9956,7 @@ pub const FuncGen = struct {
9964 if (!operand_ty.isFnOrHasRuntimeBitsIgnoreComptime(zcu)) return .none;9956 if (!operand_ty.isFnOrHasRuntimeBitsIgnoreComptime(zcu)) return .none;
9965 const ptr = try self.resolveInst(bin_op.lhs);9957 const ptr = try self.resolveInst(bin_op.lhs);
9966 var element = try self.resolveInst(bin_op.rhs);9958 var element = try self.resolveInst(bin_op.rhs);
9967 const llvm_abi_ty = try o.getAtomicAbiType(operand_ty, false);9959 const llvm_abi_ty = try o.getAtomicAbiType(pt, operand_ty, false);
99689960
9969 if (llvm_abi_ty != .none) {9961 if (llvm_abi_ty != .none) {
9970 // operand needs widening9962 // operand needs widening
...@@ -9984,7 +9976,7 @@ pub const FuncGen = struct {...@@ -9984,7 +9976,7 @@ pub const FuncGen = struct {
99849976
9985 fn airMemset(self: *FuncGen, inst: Air.Inst.Index, safety: bool) !Builder.Value {9977 fn airMemset(self: *FuncGen, inst: Air.Inst.Index, safety: bool) !Builder.Value {
9986 const o = self.ng.object;9978 const o = self.ng.object;
9987 const pt = o.pt;9979 const pt = self.ng.pt;
9988 const zcu = pt.zcu;9980 const zcu = pt.zcu;
9989 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;9981 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
9990 const dest_slice = try self.resolveInst(bin_op.lhs);9982 const dest_slice = try self.resolveInst(bin_op.lhs);
...@@ -10081,13 +10073,13 @@ pub const FuncGen = struct {...@@ -10081,13 +10073,13 @@ pub const FuncGen = struct {
10081 const body_block = try self.wip.block(1, "InlineMemsetBody");10073 const body_block = try self.wip.block(1, "InlineMemsetBody");
10082 const end_block = try self.wip.block(1, "InlineMemsetEnd");10074 const end_block = try self.wip.block(1, "InlineMemsetEnd");
1008310075
10084 const llvm_usize_ty = try o.lowerType(Type.usize);10076 const llvm_usize_ty = try o.lowerType(pt, Type.usize);
10085 const len = switch (ptr_ty.ptrSize(zcu)) {10077 const len = switch (ptr_ty.ptrSize(zcu)) {
10086 .slice => try self.wip.extractValue(dest_slice, &.{1}, ""),10078 .slice => try self.wip.extractValue(dest_slice, &.{1}, ""),
10087 .one => try o.builder.intValue(llvm_usize_ty, ptr_ty.childType(zcu).arrayLen(zcu)),10079 .one => try o.builder.intValue(llvm_usize_ty, ptr_ty.childType(zcu).arrayLen(zcu)),
10088 .many, .c => unreachable,10080 .many, .c => unreachable,
10089 };10081 };
10090 const elem_llvm_ty = try o.lowerType(elem_ty);10082 const elem_llvm_ty = try o.lowerType(pt, elem_ty);
10091 const end_ptr = try self.wip.gep(.inbounds, elem_llvm_ty, dest_ptr, &.{len}, "");10083 const end_ptr = try self.wip.gep(.inbounds, elem_llvm_ty, dest_ptr, &.{len}, "");
10092 _ = try self.wip.br(loop_block);10084 _ = try self.wip.br(loop_block);
1009310085
...@@ -10121,8 +10113,7 @@ pub const FuncGen = struct {...@@ -10121,8 +10113,7 @@ pub const FuncGen = struct {
10121 }10113 }
1012210114
10123 fn airMemcpy(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10115 fn airMemcpy(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
10124 const o = self.ng.object;10116 const pt = self.ng.pt;
10125 const pt = o.pt;
10126 const zcu = pt.zcu;10117 const zcu = pt.zcu;
10127 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;10118 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
10128 const dest_slice = try self.resolveInst(bin_op.lhs);10119 const dest_slice = try self.resolveInst(bin_op.lhs);
...@@ -10151,8 +10142,7 @@ pub const FuncGen = struct {...@@ -10151,8 +10142,7 @@ pub const FuncGen = struct {
10151 }10142 }
1015210143
10153 fn airMemmove(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10144 fn airMemmove(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
10154 const o = self.ng.object;10145 const pt = self.ng.pt;
10155 const pt = o.pt;
10156 const zcu = pt.zcu;10146 const zcu = pt.zcu;
10157 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;10147 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
10158 const dest_slice = try self.resolveInst(bin_op.lhs);10148 const dest_slice = try self.resolveInst(bin_op.lhs);
...@@ -10178,7 +10168,7 @@ pub const FuncGen = struct {...@@ -10178,7 +10168,7 @@ pub const FuncGen = struct {
1017810168
10179 fn airSetUnionTag(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10169 fn airSetUnionTag(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
10180 const o = self.ng.object;10170 const o = self.ng.object;
10181 const pt = o.pt;10171 const pt = self.ng.pt;
10182 const zcu = pt.zcu;10172 const zcu = pt.zcu;
10183 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;10173 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
10184 const un_ptr_ty = self.typeOf(bin_op.lhs);10174 const un_ptr_ty = self.typeOf(bin_op.lhs);
...@@ -10199,7 +10189,7 @@ pub const FuncGen = struct {...@@ -10199,7 +10189,7 @@ pub const FuncGen = struct {
10199 return .none;10189 return .none;
10200 }10190 }
10201 const tag_index = @intFromBool(layout.tag_align.compare(.lt, layout.payload_align));10191 const tag_index = @intFromBool(layout.tag_align.compare(.lt, layout.payload_align));
10202 const tag_field_ptr = try self.wip.gepStruct(try o.lowerType(un_ty), union_ptr, tag_index, "");10192 const tag_field_ptr = try self.wip.gepStruct(try o.lowerType(pt, un_ty), union_ptr, tag_index, "");
10203 // TODO alignment on this store10193 // TODO alignment on this store
10204 _ = try self.wip.store(access_kind, new_tag, tag_field_ptr, .default);10194 _ = try self.wip.store(access_kind, new_tag, tag_field_ptr, .default);
10205 return .none;10195 return .none;
...@@ -10207,7 +10197,7 @@ pub const FuncGen = struct {...@@ -10207,7 +10197,7 @@ pub const FuncGen = struct {
1020710197
10208 fn airGetUnionTag(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10198 fn airGetUnionTag(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
10209 const o = self.ng.object;10199 const o = self.ng.object;
10210 const pt = o.pt;10200 const pt = self.ng.pt;
10211 const zcu = pt.zcu;10201 const zcu = pt.zcu;
10212 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;10202 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
10213 const un_ty = self.typeOf(ty_op.operand);10203 const un_ty = self.typeOf(ty_op.operand);
...@@ -10215,7 +10205,7 @@ pub const FuncGen = struct {...@@ -10215,7 +10205,7 @@ pub const FuncGen = struct {
10215 if (layout.tag_size == 0) return .none;10205 if (layout.tag_size == 0) return .none;
10216 const union_handle = try self.resolveInst(ty_op.operand);10206 const union_handle = try self.resolveInst(ty_op.operand);
10217 if (isByRef(un_ty, zcu)) {10207 if (isByRef(un_ty, zcu)) {
10218 const llvm_un_ty = try o.lowerType(un_ty);10208 const llvm_un_ty = try o.lowerType(pt, un_ty);
10219 if (layout.payload_size == 0)10209 if (layout.payload_size == 0)
10220 return self.wip.load(.normal, llvm_un_ty, union_handle, .default, "");10210 return self.wip.load(.normal, llvm_un_ty, union_handle, .default, "");
10221 const tag_index = @intFromBool(layout.tag_align.compare(.lt, layout.payload_align));10211 const tag_index = @intFromBool(layout.tag_align.compare(.lt, layout.payload_align));
...@@ -10247,6 +10237,7 @@ pub const FuncGen = struct {...@@ -10247,6 +10237,7 @@ pub const FuncGen = struct {
1024710237
10248 fn airClzCtz(self: *FuncGen, inst: Air.Inst.Index, intrinsic: Builder.Intrinsic) !Builder.Value {10238 fn airClzCtz(self: *FuncGen, inst: Air.Inst.Index, intrinsic: Builder.Intrinsic) !Builder.Value {
10249 const o = self.ng.object;10239 const o = self.ng.object;
10240 const pt = self.ng.pt;
10250 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;10241 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
10251 const inst_ty = self.typeOfIndex(inst);10242 const inst_ty = self.typeOfIndex(inst);
10252 const operand_ty = self.typeOf(ty_op.operand);10243 const operand_ty = self.typeOf(ty_op.operand);
...@@ -10256,15 +10247,16 @@ pub const FuncGen = struct {...@@ -10256,15 +10247,16 @@ pub const FuncGen = struct {
10256 .normal,10247 .normal,
10257 .none,10248 .none,
10258 intrinsic,10249 intrinsic,
10259 &.{try o.lowerType(operand_ty)},10250 &.{try o.lowerType(pt, operand_ty)},
10260 &.{ operand, .false },10251 &.{ operand, .false },
10261 "",10252 "",
10262 );10253 );
10263 return self.wip.conv(.unsigned, result, try o.lowerType(inst_ty), "");10254 return self.wip.conv(.unsigned, result, try o.lowerType(pt, inst_ty), "");
10264 }10255 }
1026510256
10266 fn airBitOp(self: *FuncGen, inst: Air.Inst.Index, intrinsic: Builder.Intrinsic) !Builder.Value {10257 fn airBitOp(self: *FuncGen, inst: Air.Inst.Index, intrinsic: Builder.Intrinsic) !Builder.Value {
10267 const o = self.ng.object;10258 const o = self.ng.object;
10259 const pt = self.ng.pt;
10268 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;10260 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
10269 const inst_ty = self.typeOfIndex(inst);10261 const inst_ty = self.typeOfIndex(inst);
10270 const operand_ty = self.typeOf(ty_op.operand);10262 const operand_ty = self.typeOf(ty_op.operand);
...@@ -10274,16 +10266,17 @@ pub const FuncGen = struct {...@@ -10274,16 +10266,17 @@ pub const FuncGen = struct {
10274 .normal,10266 .normal,
10275 .none,10267 .none,
10276 intrinsic,10268 intrinsic,
10277 &.{try o.lowerType(operand_ty)},10269 &.{try o.lowerType(pt, operand_ty)},
10278 &.{operand},10270 &.{operand},
10279 "",10271 "",
10280 );10272 );
10281 return self.wip.conv(.unsigned, result, try o.lowerType(inst_ty), "");10273 return self.wip.conv(.unsigned, result, try o.lowerType(pt, inst_ty), "");
10282 }10274 }
1028310275
10284 fn airByteSwap(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10276 fn airByteSwap(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
10285 const o = self.ng.object;10277 const o = self.ng.object;
10286 const zcu = o.pt.zcu;10278 const pt = self.ng.pt;
10279 const zcu = pt.zcu;
10287 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;10280 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
10288 const operand_ty = self.typeOf(ty_op.operand);10281 const operand_ty = self.typeOf(ty_op.operand);
10289 var bits = operand_ty.intInfo(zcu).bits;10282 var bits = operand_ty.intInfo(zcu).bits;
...@@ -10291,7 +10284,7 @@ pub const FuncGen = struct {...@@ -10291,7 +10284,7 @@ pub const FuncGen = struct {
1029110284
10292 const inst_ty = self.typeOfIndex(inst);10285 const inst_ty = self.typeOfIndex(inst);
10293 var operand = try self.resolveInst(ty_op.operand);10286 var operand = try self.resolveInst(ty_op.operand);
10294 var llvm_operand_ty = try o.lowerType(operand_ty);10287 var llvm_operand_ty = try o.lowerType(pt, operand_ty);
1029510288
10296 if (bits % 16 == 8) {10289 if (bits % 16 == 8) {
10297 // If not an even byte-multiple, we need zero-extend + shift-left 1 byte10290 // If not an even byte-multiple, we need zero-extend + shift-left 1 byte
...@@ -10312,12 +10305,13 @@ pub const FuncGen = struct {...@@ -10312,12 +10305,13 @@ pub const FuncGen = struct {
1031210305
10313 const result =10306 const result =
10314 try self.wip.callIntrinsic(.normal, .none, .bswap, &.{llvm_operand_ty}, &.{operand}, "");10307 try self.wip.callIntrinsic(.normal, .none, .bswap, &.{llvm_operand_ty}, &.{operand}, "");
10315 return self.wip.conv(.unsigned, result, try o.lowerType(inst_ty), "");10308 return self.wip.conv(.unsigned, result, try o.lowerType(pt, inst_ty), "");
10316 }10309 }
1031710310
10318 fn airErrorSetHasValue(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10311 fn airErrorSetHasValue(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
10319 const o = self.ng.object;10312 const o = self.ng.object;
10320 const zcu = o.pt.zcu;10313 const pt = self.ng.pt;
10314 const zcu = pt.zcu;
10321 const ip = &zcu.intern_pool;10315 const ip = &zcu.intern_pool;
10322 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;10316 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
10323 const operand = try self.resolveInst(ty_op.operand);10317 const operand = try self.resolveInst(ty_op.operand);
...@@ -10332,7 +10326,7 @@ pub const FuncGen = struct {...@@ -10332,7 +10326,7 @@ pub const FuncGen = struct {
1033210326
10333 for (0..names.len) |name_index| {10327 for (0..names.len) |name_index| {
10334 const err_int = ip.getErrorValueIfExists(names.get(ip)[name_index]).?;10328 const err_int = ip.getErrorValueIfExists(names.get(ip)[name_index]).?;
10335 const this_tag_int_value = try o.builder.intConst(try o.errorIntType(), err_int);10329 const this_tag_int_value = try o.builder.intConst(try o.errorIntType(pt), err_int);
10336 try wip_switch.addCase(this_tag_int_value, valid_block, &self.wip);10330 try wip_switch.addCase(this_tag_int_value, valid_block, &self.wip);
10337 }10331 }
10338 self.wip.cursor = .{ .block = valid_block };10332 self.wip.cursor = .{ .block = valid_block };
...@@ -10367,7 +10361,7 @@ pub const FuncGen = struct {...@@ -10367,7 +10361,7 @@ pub const FuncGen = struct {
1036710361
10368 fn getIsNamedEnumValueFunction(self: *FuncGen, enum_ty: Type) !Builder.Function.Index {10362 fn getIsNamedEnumValueFunction(self: *FuncGen, enum_ty: Type) !Builder.Function.Index {
10369 const o = self.ng.object;10363 const o = self.ng.object;
10370 const pt = o.pt;10364 const pt = self.ng.pt;
10371 const zcu = pt.zcu;10365 const zcu = pt.zcu;
10372 const ip = &zcu.intern_pool;10366 const ip = &zcu.intern_pool;
10373 const enum_type = ip.loadEnumType(enum_ty.toIntern());10367 const enum_type = ip.loadEnumType(enum_ty.toIntern());
...@@ -10379,7 +10373,7 @@ pub const FuncGen = struct {...@@ -10379,7 +10373,7 @@ pub const FuncGen = struct {
1037910373
10380 const target = &zcu.root_mod.resolved_target.result;10374 const target = &zcu.root_mod.resolved_target.result;
10381 const function_index = try o.builder.addFunction(10375 const function_index = try o.builder.addFunction(
10382 try o.builder.fnType(.i1, &.{try o.lowerType(Type.fromInterned(enum_type.tag_ty))}, .normal),10376 try o.builder.fnType(.i1, &.{try o.lowerType(pt, Type.fromInterned(enum_type.tag_ty))}, .normal),
10383 try o.builder.strtabStringFmt("__zig_is_named_enum_value_{f}", .{enum_type.name.fmt(ip)}),10377 try o.builder.strtabStringFmt("__zig_is_named_enum_value_{f}", .{enum_type.name.fmt(ip)}),
10384 toLlvmAddressSpace(.generic, target),10378 toLlvmAddressSpace(.generic, target),
10385 );10379 );
...@@ -10408,6 +10402,7 @@ pub const FuncGen = struct {...@@ -10408,6 +10402,7 @@ pub const FuncGen = struct {
1040810402
10409 for (0..enum_type.names.len) |field_index| {10403 for (0..enum_type.names.len) |field_index| {
10410 const this_tag_int_value = try o.lowerValue(10404 const this_tag_int_value = try o.lowerValue(
10405 pt,
10411 (try pt.enumValueFieldIndex(enum_ty, @intCast(field_index))).toIntern(),10406 (try pt.enumValueFieldIndex(enum_ty, @intCast(field_index))).toIntern(),
10412 );10407 );
10413 try wip_switch.addCase(this_tag_int_value, named_block, &wip);10408 try wip_switch.addCase(this_tag_int_value, named_block, &wip);
...@@ -10424,11 +10419,12 @@ pub const FuncGen = struct {...@@ -10424,11 +10419,12 @@ pub const FuncGen = struct {
1042410419
10425 fn airTagName(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10420 fn airTagName(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
10426 const o = self.ng.object;10421 const o = self.ng.object;
10422 const pt = self.ng.pt;
10427 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;10423 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;
10428 const operand = try self.resolveInst(un_op);10424 const operand = try self.resolveInst(un_op);
10429 const enum_ty = self.typeOf(un_op);10425 const enum_ty = self.typeOf(un_op);
1043010426
10431 const llvm_fn = try o.getEnumTagNameFunction(enum_ty);10427 const llvm_fn = try o.getEnumTagNameFunction(pt, enum_ty);
10432 return self.wip.call(10428 return self.wip.call(
10433 .normal,10429 .normal,
10434 .fastcc,10430 .fastcc,
...@@ -10442,10 +10438,11 @@ pub const FuncGen = struct {...@@ -10442,10 +10438,11 @@ pub const FuncGen = struct {
1044210438
10443 fn airErrorName(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10439 fn airErrorName(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
10444 const o = self.ng.object;10440 const o = self.ng.object;
10441 const pt = self.ng.pt;
10445 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;10442 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;
10446 const operand = try self.resolveInst(un_op);10443 const operand = try self.resolveInst(un_op);
10447 const slice_ty = self.typeOfIndex(inst);10444 const slice_ty = self.typeOfIndex(inst);
10448 const slice_llvm_ty = try o.lowerType(slice_ty);10445 const slice_llvm_ty = try o.lowerType(pt, slice_ty);
1044910446
10450 const error_name_table_ptr = try self.getErrorNameTable();10447 const error_name_table_ptr = try self.getErrorNameTable();
10451 const error_name_table =10448 const error_name_table =
...@@ -10457,10 +10454,11 @@ pub const FuncGen = struct {...@@ -10457,10 +10454,11 @@ pub const FuncGen = struct {
1045710454
10458 fn airSplat(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10455 fn airSplat(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
10459 const o = self.ng.object;10456 const o = self.ng.object;
10457 const pt = self.ng.pt;
10460 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;10458 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
10461 const scalar = try self.resolveInst(ty_op.operand);10459 const scalar = try self.resolveInst(ty_op.operand);
10462 const vector_ty = self.typeOfIndex(inst);10460 const vector_ty = self.typeOfIndex(inst);
10463 return self.wip.splatVector(try o.lowerType(vector_ty), scalar, "");10461 return self.wip.splatVector(try o.lowerType(pt, vector_ty), scalar, "");
10464 }10462 }
1046510463
10466 fn airSelect(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10464 fn airSelect(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
...@@ -10475,7 +10473,7 @@ pub const FuncGen = struct {...@@ -10475,7 +10473,7 @@ pub const FuncGen = struct {
1047510473
10476 fn airShuffleOne(fg: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10474 fn airShuffleOne(fg: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
10477 const o = fg.ng.object;10475 const o = fg.ng.object;
10478 const pt = o.pt;10476 const pt = fg.ng.pt;
10479 const zcu = pt.zcu;10477 const zcu = pt.zcu;
10480 const gpa = zcu.gpa;10478 const gpa = zcu.gpa;
1048110479
...@@ -10484,9 +10482,9 @@ pub const FuncGen = struct {...@@ -10484,9 +10482,9 @@ pub const FuncGen = struct {
10484 const operand = try fg.resolveInst(unwrapped.operand);10482 const operand = try fg.resolveInst(unwrapped.operand);
10485 const mask = unwrapped.mask;10483 const mask = unwrapped.mask;
10486 const operand_ty = fg.typeOf(unwrapped.operand);10484 const operand_ty = fg.typeOf(unwrapped.operand);
10487 const llvm_operand_ty = try o.lowerType(operand_ty);10485 const llvm_operand_ty = try o.lowerType(pt, operand_ty);
10488 const llvm_result_ty = try o.lowerType(unwrapped.result_ty);10486 const llvm_result_ty = try o.lowerType(pt, unwrapped.result_ty);
10489 const llvm_elem_ty = try o.lowerType(unwrapped.result_ty.childType(zcu));10487 const llvm_elem_ty = try o.lowerType(pt, unwrapped.result_ty.childType(zcu));
10490 const llvm_poison_elem = try o.builder.poisonConst(llvm_elem_ty);10488 const llvm_poison_elem = try o.builder.poisonConst(llvm_elem_ty);
10491 const llvm_poison_mask_elem = try o.builder.poisonConst(.i32);10489 const llvm_poison_mask_elem = try o.builder.poisonConst(.i32);
10492 const llvm_mask_ty = try o.builder.vectorType(.normal, @intCast(mask.len), .i32);10490 const llvm_mask_ty = try o.builder.vectorType(.normal, @intCast(mask.len), .i32);
...@@ -10516,7 +10514,7 @@ pub const FuncGen = struct {...@@ -10516,7 +10514,7 @@ pub const FuncGen = struct {
10516 .elem => llvm_poison_elem,10514 .elem => llvm_poison_elem,
10517 .value => |val| if (!Value.fromInterned(val).isUndef(zcu)) elem: {10515 .value => |val| if (!Value.fromInterned(val).isUndef(zcu)) elem: {
10518 any_defined_comptime_value = true;10516 any_defined_comptime_value = true;
10519 break :elem try o.lowerValue(val);10517 break :elem try o.lowerValue(pt, val);
10520 } else llvm_poison_elem,10518 } else llvm_poison_elem,
10521 };10519 };
10522 }10520 }
...@@ -10582,14 +10580,14 @@ pub const FuncGen = struct {...@@ -10582,14 +10580,14 @@ pub const FuncGen = struct {
1058210580
10583 fn airShuffleTwo(fg: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10581 fn airShuffleTwo(fg: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
10584 const o = fg.ng.object;10582 const o = fg.ng.object;
10585 const pt = o.pt;10583 const pt = fg.ng.pt;
10586 const zcu = pt.zcu;10584 const zcu = pt.zcu;
10587 const gpa = zcu.gpa;10585 const gpa = zcu.gpa;
1058810586
10589 const unwrapped = fg.air.unwrapShuffleTwo(zcu, inst);10587 const unwrapped = fg.air.unwrapShuffleTwo(zcu, inst);
1059010588
10591 const mask = unwrapped.mask;10589 const mask = unwrapped.mask;
10592 const llvm_elem_ty = try o.lowerType(unwrapped.result_ty.childType(zcu));10590 const llvm_elem_ty = try o.lowerType(pt, unwrapped.result_ty.childType(zcu));
10593 const llvm_mask_ty = try o.builder.vectorType(.normal, @intCast(mask.len), .i32);10591 const llvm_mask_ty = try o.builder.vectorType(.normal, @intCast(mask.len), .i32);
10594 const llvm_poison_mask_elem = try o.builder.poisonConst(.i32);10592 const llvm_poison_mask_elem = try o.builder.poisonConst(.i32);
1059510593
...@@ -10681,7 +10679,8 @@ pub const FuncGen = struct {...@@ -10681,7 +10679,8 @@ pub const FuncGen = struct {
10681 accum_init: Builder.Value,10679 accum_init: Builder.Value,
10682 ) !Builder.Value {10680 ) !Builder.Value {
10683 const o = self.ng.object;10681 const o = self.ng.object;
10684 const usize_ty = try o.lowerType(Type.usize);10682 const pt = self.ng.pt;
10683 const usize_ty = try o.lowerType(pt, Type.usize);
10685 const llvm_vector_len = try o.builder.intValue(usize_ty, vector_len);10684 const llvm_vector_len = try o.builder.intValue(usize_ty, vector_len);
10686 const llvm_result_ty = accum_init.typeOfWip(&self.wip);10685 const llvm_result_ty = accum_init.typeOfWip(&self.wip);
1068710686
...@@ -10735,15 +10734,16 @@ pub const FuncGen = struct {...@@ -10735,15 +10734,16 @@ pub const FuncGen = struct {
1073510734
10736 fn airReduce(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {10735 fn airReduce(self: *FuncGen, inst: Air.Inst.Index, fast: Builder.FastMathKind) !Builder.Value {
10737 const o = self.ng.object;10736 const o = self.ng.object;
10738 const zcu = o.pt.zcu;10737 const pt = self.ng.pt;
10738 const zcu = pt.zcu;
10739 const target = zcu.getTarget();10739 const target = zcu.getTarget();
1074010740
10741 const reduce = self.air.instructions.items(.data)[@intFromEnum(inst)].reduce;10741 const reduce = self.air.instructions.items(.data)[@intFromEnum(inst)].reduce;
10742 const operand = try self.resolveInst(reduce.operand);10742 const operand = try self.resolveInst(reduce.operand);
10743 const operand_ty = self.typeOf(reduce.operand);10743 const operand_ty = self.typeOf(reduce.operand);
10744 const llvm_operand_ty = try o.lowerType(operand_ty);10744 const llvm_operand_ty = try o.lowerType(pt, operand_ty);
10745 const scalar_ty = self.typeOfIndex(inst);10745 const scalar_ty = self.typeOfIndex(inst);
10746 const llvm_scalar_ty = try o.lowerType(scalar_ty);10746 const llvm_scalar_ty = try o.lowerType(pt, scalar_ty);
1074710747
10748 switch (reduce.operation) {10748 switch (reduce.operation) {
10749 .And, .Or, .Xor => return self.wip.callIntrinsic(.normal, .none, switch (reduce.operation) {10749 .And, .Or, .Xor => return self.wip.callIntrinsic(.normal, .none, switch (reduce.operation) {
...@@ -10845,14 +10845,14 @@ pub const FuncGen = struct {...@@ -10845,14 +10845,14 @@ pub const FuncGen = struct {
1084510845
10846 fn airAggregateInit(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10846 fn airAggregateInit(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
10847 const o = self.ng.object;10847 const o = self.ng.object;
10848 const pt = o.pt;10848 const pt = self.ng.pt;
10849 const zcu = pt.zcu;10849 const zcu = pt.zcu;
10850 const ip = &zcu.intern_pool;10850 const ip = &zcu.intern_pool;
10851 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;10851 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
10852 const result_ty = self.typeOfIndex(inst);10852 const result_ty = self.typeOfIndex(inst);
10853 const len: usize = @intCast(result_ty.arrayLen(zcu));10853 const len: usize = @intCast(result_ty.arrayLen(zcu));
10854 const elements: []const Air.Inst.Ref = @ptrCast(self.air.extra.items[ty_pl.payload..][0..len]);10854 const elements: []const Air.Inst.Ref = @ptrCast(self.air.extra.items[ty_pl.payload..][0..len]);
10855 const llvm_result_ty = try o.lowerType(result_ty);10855 const llvm_result_ty = try o.lowerType(pt, result_ty);
1085610856
10857 switch (result_ty.zigTypeTag(zcu)) {10857 switch (result_ty.zigTypeTag(zcu)) {
10858 .vector => {10858 .vector => {
...@@ -10933,7 +10933,7 @@ pub const FuncGen = struct {...@@ -10933,7 +10933,7 @@ pub const FuncGen = struct {
10933 .array => {10933 .array => {
10934 assert(isByRef(result_ty, zcu));10934 assert(isByRef(result_ty, zcu));
1093510935
10936 const llvm_usize = try o.lowerType(Type.usize);10936 const llvm_usize = try o.lowerType(pt, Type.usize);
10937 const usize_zero = try o.builder.intValue(llvm_usize, 0);10937 const usize_zero = try o.builder.intValue(llvm_usize, 0);
10938 const alignment = result_ty.abiAlignment(zcu).toLlvm();10938 const alignment = result_ty.abiAlignment(zcu).toLlvm();
10939 const alloca_inst = try self.buildAlloca(llvm_result_ty, alignment);10939 const alloca_inst = try self.buildAlloca(llvm_result_ty, alignment);
...@@ -10966,13 +10966,13 @@ pub const FuncGen = struct {...@@ -10966,13 +10966,13 @@ pub const FuncGen = struct {
1096610966
10967 fn airUnionInit(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {10967 fn airUnionInit(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
10968 const o = self.ng.object;10968 const o = self.ng.object;
10969 const pt = o.pt;10969 const pt = self.ng.pt;
10970 const zcu = pt.zcu;10970 const zcu = pt.zcu;
10971 const ip = &zcu.intern_pool;10971 const ip = &zcu.intern_pool;
10972 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;10972 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
10973 const extra = self.air.extraData(Air.UnionInit, ty_pl.payload).data;10973 const extra = self.air.extraData(Air.UnionInit, ty_pl.payload).data;
10974 const union_ty = self.typeOfIndex(inst);10974 const union_ty = self.typeOfIndex(inst);
10975 const union_llvm_ty = try o.lowerType(union_ty);10975 const union_llvm_ty = try o.lowerType(pt, union_ty);
10976 const layout = union_ty.unionGetLayout(zcu);10976 const layout = union_ty.unionGetLayout(zcu);
10977 const union_obj = zcu.typeToUnion(union_ty).?;10977 const union_obj = zcu.typeToUnion(union_ty).?;
1097810978
...@@ -11014,10 +11014,10 @@ pub const FuncGen = struct {...@@ -11014,10 +11014,10 @@ pub const FuncGen = struct {
11014 const result_ptr = try self.buildAlloca(union_llvm_ty, alignment);11014 const result_ptr = try self.buildAlloca(union_llvm_ty, alignment);
11015 const llvm_payload = try self.resolveInst(extra.init);11015 const llvm_payload = try self.resolveInst(extra.init);
11016 const field_ty = Type.fromInterned(union_obj.field_types.get(ip)[extra.field_index]);11016 const field_ty = Type.fromInterned(union_obj.field_types.get(ip)[extra.field_index]);
11017 const field_llvm_ty = try o.lowerType(field_ty);11017 const field_llvm_ty = try o.lowerType(pt, field_ty);
11018 const field_size = field_ty.abiSize(zcu);11018 const field_size = field_ty.abiSize(zcu);
11019 const field_align = union_ty.fieldAlignment(extra.field_index, zcu);11019 const field_align = union_ty.fieldAlignment(extra.field_index, zcu);
11020 const llvm_usize = try o.lowerType(Type.usize);11020 const llvm_usize = try o.lowerType(pt, Type.usize);
11021 const usize_zero = try o.builder.intValue(llvm_usize, 0);11021 const usize_zero = try o.builder.intValue(llvm_usize, 0);
1102211022
11023 const llvm_union_ty = t: {11023 const llvm_union_ty = t: {
...@@ -11035,7 +11035,7 @@ pub const FuncGen = struct {...@@ -11035,7 +11035,7 @@ pub const FuncGen = struct {
11035 });11035 });
11036 };11036 };
11037 if (layout.tag_size == 0) break :t try o.builder.structType(.normal, &.{payload_ty});11037 if (layout.tag_size == 0) break :t try o.builder.structType(.normal, &.{payload_ty});
11038 const tag_ty = try o.lowerType(Type.fromInterned(union_obj.enum_tag_ty));11038 const tag_ty = try o.lowerType(pt, Type.fromInterned(union_obj.enum_tag_ty));
11039 var fields: [3]Builder.Type = undefined;11039 var fields: [3]Builder.Type = undefined;
11040 var fields_len: usize = 2;11040 var fields_len: usize = 2;
11041 if (layout.tag_align.compare(.gte, layout.payload_align)) {11041 if (layout.tag_align.compare(.gte, layout.payload_align)) {
...@@ -11076,7 +11076,7 @@ pub const FuncGen = struct {...@@ -11076,7 +11076,7 @@ pub const FuncGen = struct {
11076 const tag_index = @intFromBool(layout.tag_align.compare(.lt, layout.payload_align));11076 const tag_index = @intFromBool(layout.tag_align.compare(.lt, layout.payload_align));
11077 const indices: [2]Builder.Value = .{ usize_zero, try o.builder.intValue(.i32, tag_index) };11077 const indices: [2]Builder.Value = .{ usize_zero, try o.builder.intValue(.i32, tag_index) };
11078 const field_ptr = try self.wip.gep(.inbounds, llvm_union_ty, result_ptr, &indices, "");11078 const field_ptr = try self.wip.gep(.inbounds, llvm_union_ty, result_ptr, &indices, "");
11079 const tag_ty = try o.lowerType(Type.fromInterned(union_obj.enum_tag_ty));11079 const tag_ty = try o.lowerType(pt, Type.fromInterned(union_obj.enum_tag_ty));
11080 var big_int_space: Value.BigIntSpace = undefined;11080 var big_int_space: Value.BigIntSpace = undefined;
11081 const tag_big_int = tag_int_val.toBigInt(&big_int_space, zcu);11081 const tag_big_int = tag_int_val.toBigInt(&big_int_space, zcu);
11082 const llvm_tag = try o.builder.bigIntValue(tag_ty, tag_big_int);11082 const llvm_tag = try o.builder.bigIntValue(tag_ty, tag_big_int);
...@@ -11106,7 +11106,7 @@ pub const FuncGen = struct {...@@ -11106,7 +11106,7 @@ pub const FuncGen = struct {
11106 // by the target.11106 // by the target.
11107 // To work around this, don't emit llvm.prefetch in this case.11107 // To work around this, don't emit llvm.prefetch in this case.
11108 // See https://bugs.llvm.org/show_bug.cgi?id=2103711108 // See https://bugs.llvm.org/show_bug.cgi?id=21037
11109 const zcu = o.pt.zcu;11109 const zcu = self.ng.pt.zcu;
11110 const target = zcu.getTarget();11110 const target = zcu.getTarget();
11111 switch (prefetch.cache) {11111 switch (prefetch.cache) {
11112 .instruction => switch (target.cpu.arch) {11112 .instruction => switch (target.cpu.arch) {
...@@ -11139,11 +11139,12 @@ pub const FuncGen = struct {...@@ -11139,11 +11139,12 @@ pub const FuncGen = struct {
1113911139
11140 fn airAddrSpaceCast(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {11140 fn airAddrSpaceCast(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
11141 const o = self.ng.object;11141 const o = self.ng.object;
11142 const pt = self.ng.pt;
11142 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;11143 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
11143 const inst_ty = self.typeOfIndex(inst);11144 const inst_ty = self.typeOfIndex(inst);
11144 const operand = try self.resolveInst(ty_op.operand);11145 const operand = try self.resolveInst(ty_op.operand);
1114511146
11146 return self.wip.cast(.addrspacecast, operand, try o.lowerType(inst_ty), "");11147 return self.wip.cast(.addrspacecast, operand, try o.lowerType(pt, inst_ty), "");
11147 }11148 }
1114811149
11149 fn workIntrinsic(11150 fn workIntrinsic(
...@@ -11161,8 +11162,7 @@ pub const FuncGen = struct {...@@ -11161,8 +11162,7 @@ pub const FuncGen = struct {
11161 }11162 }
1116211163
11163 fn airWorkItemId(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {11164 fn airWorkItemId(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
11164 const o = self.ng.object;11165 const target = self.ng.pt.zcu.getTarget();
11165 const target = o.pt.zcu.getTarget();
1116611166
11167 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;11167 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
11168 const dimension = pl_op.payload;11168 const dimension = pl_op.payload;
...@@ -11176,7 +11176,8 @@ pub const FuncGen = struct {...@@ -11176,7 +11176,8 @@ pub const FuncGen = struct {
1117611176
11177 fn airWorkGroupSize(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {11177 fn airWorkGroupSize(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
11178 const o = self.ng.object;11178 const o = self.ng.object;
11179 const target = o.pt.zcu.getTarget();11179 const pt = self.ng.pt;
11180 const target = pt.zcu.getTarget();
1118011181
11181 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;11182 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
11182 const dimension = pl_op.payload;11183 const dimension = pl_op.payload;
...@@ -11193,7 +11194,7 @@ pub const FuncGen = struct {...@@ -11193,7 +11194,7 @@ pub const FuncGen = struct {
11193 // Load the work_group_* member from the struct as u16.11194 // Load the work_group_* member from the struct as u16.
11194 // Just treat the dispatch pointer as an array of u16 to keep things simple.11195 // Just treat the dispatch pointer as an array of u16 to keep things simple.
11195 const workgroup_size_ptr = try self.wip.gep(.inbounds, .i16, dispatch_ptr, &.{11196 const workgroup_size_ptr = try self.wip.gep(.inbounds, .i16, dispatch_ptr, &.{
11196 try o.builder.intValue(try o.lowerType(Type.usize), 2 + dimension),11197 try o.builder.intValue(try o.lowerType(pt, Type.usize), 2 + dimension),
11197 }, "");11198 }, "");
11198 const workgroup_size_alignment = comptime Builder.Alignment.fromByteUnits(2);11199 const workgroup_size_alignment = comptime Builder.Alignment.fromByteUnits(2);
11199 return self.wip.load(.normal, .i16, workgroup_size_ptr, workgroup_size_alignment, "");11200 return self.wip.load(.normal, .i16, workgroup_size_ptr, workgroup_size_alignment, "");
...@@ -11206,8 +11207,7 @@ pub const FuncGen = struct {...@@ -11206,8 +11207,7 @@ pub const FuncGen = struct {
11206 }11207 }
1120711208
11208 fn airWorkGroupId(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {11209 fn airWorkGroupId(self: *FuncGen, inst: Air.Inst.Index) !Builder.Value {
11209 const o = self.ng.object;11210 const target = self.ng.pt.zcu.getTarget();
11210 const target = o.pt.zcu.getTarget();
1121111211
11212 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;11212 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
11213 const dimension = pl_op.payload;11213 const dimension = pl_op.payload;
...@@ -11221,7 +11221,7 @@ pub const FuncGen = struct {...@@ -11221,7 +11221,7 @@ pub const FuncGen = struct {
1122111221
11222 fn getErrorNameTable(self: *FuncGen) Allocator.Error!Builder.Variable.Index {11222 fn getErrorNameTable(self: *FuncGen) Allocator.Error!Builder.Variable.Index {
11223 const o = self.ng.object;11223 const o = self.ng.object;
11224 const pt = o.pt;11224 const pt = self.ng.pt;
1122511225
11226 const table = o.error_name_table;11226 const table = o.error_name_table;
11227 if (table != .none) return table;11227 if (table != .none) return table;
...@@ -11271,8 +11271,7 @@ pub const FuncGen = struct {...@@ -11271,8 +11271,7 @@ pub const FuncGen = struct {
11271 opt_ty: Type,11271 opt_ty: Type,
11272 can_elide_load: bool,11272 can_elide_load: bool,
11273 ) !Builder.Value {11273 ) !Builder.Value {
11274 const o = fg.ng.object;11274 const pt = fg.ng.pt;
11275 const pt = o.pt;
11276 const zcu = pt.zcu;11275 const zcu = pt.zcu;
11277 const payload_ty = opt_ty.optionalChild(zcu);11276 const payload_ty = opt_ty.optionalChild(zcu);
1127811277
...@@ -11301,9 +11300,9 @@ pub const FuncGen = struct {...@@ -11301,9 +11300,9 @@ pub const FuncGen = struct {
11301 non_null_bit: Builder.Value,11300 non_null_bit: Builder.Value,
11302 ) !Builder.Value {11301 ) !Builder.Value {
11303 const o = self.ng.object;11302 const o = self.ng.object;
11304 const pt = o.pt;11303 const pt = self.ng.pt;
11305 const zcu = pt.zcu;11304 const zcu = pt.zcu;
11306 const optional_llvm_ty = try o.lowerType(optional_ty);11305 const optional_llvm_ty = try o.lowerType(pt, optional_ty);
11307 const non_null_field = try self.wip.cast(.zext, non_null_bit, .i8, "");11306 const non_null_field = try self.wip.cast(.zext, non_null_bit, .i8, "");
1130811307
11309 if (isByRef(optional_ty, zcu)) {11308 if (isByRef(optional_ty, zcu)) {
...@@ -11334,7 +11333,7 @@ pub const FuncGen = struct {...@@ -11334,7 +11333,7 @@ pub const FuncGen = struct {
11334 field_index: u32,11333 field_index: u32,
11335 ) !Builder.Value {11334 ) !Builder.Value {
11336 const o = self.ng.object;11335 const o = self.ng.object;
11337 const pt = o.pt;11336 const pt = self.ng.pt;
11338 const zcu = pt.zcu;11337 const zcu = pt.zcu;
11339 const struct_ty = struct_ptr_ty.childType(zcu);11338 const struct_ty = struct_ptr_ty.childType(zcu);
11340 switch (struct_ty.zigTypeTag(zcu)) {11339 switch (struct_ty.zigTypeTag(zcu)) {
...@@ -11357,12 +11356,12 @@ pub const FuncGen = struct {...@@ -11357,12 +11356,12 @@ pub const FuncGen = struct {
11357 // Offset our operand pointer by the correct number of bytes.11356 // Offset our operand pointer by the correct number of bytes.
11358 const byte_offset = @divExact(pt.structPackedFieldBitOffset(struct_type, field_index) + struct_ptr_ty_info.packed_offset.bit_offset, 8);11357 const byte_offset = @divExact(pt.structPackedFieldBitOffset(struct_type, field_index) + struct_ptr_ty_info.packed_offset.bit_offset, 8);
11359 if (byte_offset == 0) return struct_ptr;11358 if (byte_offset == 0) return struct_ptr;
11360 const usize_ty = try o.lowerType(Type.usize);11359 const usize_ty = try o.lowerType(pt, Type.usize);
11361 const llvm_index = try o.builder.intValue(usize_ty, byte_offset);11360 const llvm_index = try o.builder.intValue(usize_ty, byte_offset);
11362 return self.wip.gep(.inbounds, .i8, struct_ptr, &.{llvm_index}, "");11361 return self.wip.gep(.inbounds, .i8, struct_ptr, &.{llvm_index}, "");
11363 },11362 },
11364 else => {11363 else => {
11365 const struct_llvm_ty = try o.lowerPtrElemTy(struct_ty);11364 const struct_llvm_ty = try o.lowerPtrElemTy(pt, struct_ty);
1136611365
11367 if (o.llvmFieldIndex(struct_ty, field_index)) |llvm_field_index| {11366 if (o.llvmFieldIndex(struct_ty, field_index)) |llvm_field_index| {
11368 return self.wip.gepStruct(struct_llvm_ty, struct_ptr, llvm_field_index, "");11367 return self.wip.gepStruct(struct_llvm_ty, struct_ptr, llvm_field_index, "");
...@@ -11372,7 +11371,7 @@ pub const FuncGen = struct {...@@ -11372,7 +11371,7 @@ pub const FuncGen = struct {
11372 // the index to the element at index `1` to get a pointer to the end of11371 // the index to the element at index `1` to get a pointer to the end of
11373 // the struct.11372 // the struct.
11374 const llvm_index = try o.builder.intValue(11373 const llvm_index = try o.builder.intValue(
11375 try o.lowerType(Type.usize),11374 try o.lowerType(pt, Type.usize),
11376 @intFromBool(struct_ty.hasRuntimeBitsIgnoreComptime(zcu)),11375 @intFromBool(struct_ty.hasRuntimeBitsIgnoreComptime(zcu)),
11377 );11376 );
11378 return self.wip.gep(.inbounds, struct_llvm_ty, struct_ptr, &.{llvm_index}, "");11377 return self.wip.gep(.inbounds, struct_llvm_ty, struct_ptr, &.{llvm_index}, "");
...@@ -11383,7 +11382,7 @@ pub const FuncGen = struct {...@@ -11383,7 +11382,7 @@ pub const FuncGen = struct {
11383 const layout = struct_ty.unionGetLayout(zcu);11382 const layout = struct_ty.unionGetLayout(zcu);
11384 if (layout.payload_size == 0 or struct_ty.containerLayout(zcu) == .@"packed") return struct_ptr;11383 if (layout.payload_size == 0 or struct_ty.containerLayout(zcu) == .@"packed") return struct_ptr;
11385 const payload_index = @intFromBool(layout.tag_align.compare(.gte, layout.payload_align));11384 const payload_index = @intFromBool(layout.tag_align.compare(.gte, layout.payload_align));
11386 const union_llvm_ty = try o.lowerType(struct_ty);11385 const union_llvm_ty = try o.lowerType(pt, struct_ty);
11387 return self.wip.gepStruct(union_llvm_ty, struct_ptr, payload_index, "");11386 return self.wip.gepStruct(union_llvm_ty, struct_ptr, payload_index, "");
11388 },11387 },
11389 else => unreachable,11388 else => unreachable,
...@@ -11403,9 +11402,9 @@ pub const FuncGen = struct {...@@ -11403,9 +11402,9 @@ pub const FuncGen = struct {
11403 // => so load the byte aligned value and trunc the unwanted bits.11402 // => so load the byte aligned value and trunc the unwanted bits.
1140411403
11405 const o = fg.ng.object;11404 const o = fg.ng.object;
11406 const pt = o.pt;11405 const pt = fg.ng.pt;
11407 const zcu = pt.zcu;11406 const zcu = pt.zcu;
11408 const payload_llvm_ty = try o.lowerType(payload_ty);11407 const payload_llvm_ty = try o.lowerType(pt, payload_ty);
11409 const abi_size = payload_ty.abiSize(zcu);11408 const abi_size = payload_ty.abiSize(zcu);
1141011409
11411 // llvm bug workarounds:11410 // llvm bug workarounds:
...@@ -11450,8 +11449,8 @@ pub const FuncGen = struct {...@@ -11450,8 +11449,8 @@ pub const FuncGen = struct {
11450 access_kind: Builder.MemoryAccessKind,11449 access_kind: Builder.MemoryAccessKind,
11451 ) !Builder.Value {11450 ) !Builder.Value {
11452 const o = fg.ng.object;11451 const o = fg.ng.object;
11453 const pt = o.pt;11452 const pt = fg.ng.pt;
11454 const pointee_llvm_ty = try o.lowerType(pointee_type);11453 const pointee_llvm_ty = try o.lowerType(pt, pointee_type);
11455 const result_align = InternPool.Alignment.fromLlvm(ptr_alignment)11454 const result_align = InternPool.Alignment.fromLlvm(ptr_alignment)
11456 .max(pointee_type.abiAlignment(pt.zcu)).toLlvm();11455 .max(pointee_type.abiAlignment(pt.zcu)).toLlvm();
11457 const result_ptr = try fg.buildAlloca(pointee_llvm_ty, result_align);11456 const result_ptr = try fg.buildAlloca(pointee_llvm_ty, result_align);
...@@ -11461,7 +11460,7 @@ pub const FuncGen = struct {...@@ -11461,7 +11460,7 @@ pub const FuncGen = struct {
11461 result_align,11460 result_align,
11462 ptr,11461 ptr,
11463 ptr_alignment,11462 ptr_alignment,
11464 try o.builder.intValue(try o.lowerType(Type.usize), size_bytes),11463 try o.builder.intValue(try o.lowerType(pt, Type.usize), size_bytes),
11465 access_kind,11464 access_kind,
11466 fg.disable_intrinsics,11465 fg.disable_intrinsics,
11467 );11466 );
...@@ -11473,7 +11472,7 @@ pub const FuncGen = struct {...@@ -11473,7 +11472,7 @@ pub const FuncGen = struct {
11473 /// For isByRef=false types, it creates a load instruction and returns it.11472 /// For isByRef=false types, it creates a load instruction and returns it.
11474 fn load(self: *FuncGen, ptr: Builder.Value, ptr_ty: Type) !Builder.Value {11473 fn load(self: *FuncGen, ptr: Builder.Value, ptr_ty: Type) !Builder.Value {
11475 const o = self.ng.object;11474 const o = self.ng.object;
11476 const pt = o.pt;11475 const pt = self.ng.pt;
11477 const zcu = pt.zcu;11476 const zcu = pt.zcu;
11478 const info = ptr_ty.ptrInfo(zcu);11477 const info = ptr_ty.ptrInfo(zcu);
11479 const elem_ty = Type.fromInterned(info.child);11478 const elem_ty = Type.fromInterned(info.child);
...@@ -11490,7 +11489,7 @@ pub const FuncGen = struct {...@@ -11490,7 +11489,7 @@ pub const FuncGen = struct {
11490 assert(info.flags.vector_index != .runtime);11489 assert(info.flags.vector_index != .runtime);
11491 if (info.flags.vector_index != .none) {11490 if (info.flags.vector_index != .none) {
11492 const index_u32 = try o.builder.intValue(.i32, info.flags.vector_index);11491 const index_u32 = try o.builder.intValue(.i32, info.flags.vector_index);
11493 const vec_elem_ty = try o.lowerType(elem_ty);11492 const vec_elem_ty = try o.lowerType(pt, elem_ty);
11494 const vec_ty = try o.builder.vectorType(.normal, info.packed_offset.host_size, vec_elem_ty);11493 const vec_ty = try o.builder.vectorType(.normal, info.packed_offset.host_size, vec_elem_ty);
1149511494
11496 const loaded_vector = try self.wip.load(access_kind, vec_ty, ptr, ptr_alignment, "");11495 const loaded_vector = try self.wip.load(access_kind, vec_ty, ptr, ptr_alignment, "");
...@@ -11511,7 +11510,7 @@ pub const FuncGen = struct {...@@ -11511,7 +11510,7 @@ pub const FuncGen = struct {
11511 const elem_bits = ptr_ty.childType(zcu).bitSize(zcu);11510 const elem_bits = ptr_ty.childType(zcu).bitSize(zcu);
11512 const shift_amt = try o.builder.intValue(containing_int_ty, info.packed_offset.bit_offset);11511 const shift_amt = try o.builder.intValue(containing_int_ty, info.packed_offset.bit_offset);
11513 const shifted_value = try self.wip.bin(.lshr, containing_int, shift_amt, "");11512 const shifted_value = try self.wip.bin(.lshr, containing_int, shift_amt, "");
11514 const elem_llvm_ty = try o.lowerType(elem_ty);11513 const elem_llvm_ty = try o.lowerType(pt, elem_ty);
1151511514
11516 if (isByRef(elem_ty, zcu)) {11515 if (isByRef(elem_ty, zcu)) {
11517 const result_align = elem_ty.abiAlignment(zcu).toLlvm();11516 const result_align = elem_ty.abiAlignment(zcu).toLlvm();
...@@ -11546,7 +11545,7 @@ pub const FuncGen = struct {...@@ -11546,7 +11545,7 @@ pub const FuncGen = struct {
11546 ordering: Builder.AtomicOrdering,11545 ordering: Builder.AtomicOrdering,
11547 ) !void {11546 ) !void {
11548 const o = self.ng.object;11547 const o = self.ng.object;
11549 const pt = o.pt;11548 const pt = self.ng.pt;
11550 const zcu = pt.zcu;11549 const zcu = pt.zcu;
11551 const info = ptr_ty.ptrInfo(zcu);11550 const info = ptr_ty.ptrInfo(zcu);
11552 const elem_ty = Type.fromInterned(info.child);11551 const elem_ty = Type.fromInterned(info.child);
...@@ -11560,7 +11559,7 @@ pub const FuncGen = struct {...@@ -11560,7 +11559,7 @@ pub const FuncGen = struct {
11560 assert(info.flags.vector_index != .runtime);11559 assert(info.flags.vector_index != .runtime);
11561 if (info.flags.vector_index != .none) {11560 if (info.flags.vector_index != .none) {
11562 const index_u32 = try o.builder.intValue(.i32, info.flags.vector_index);11561 const index_u32 = try o.builder.intValue(.i32, info.flags.vector_index);
11563 const vec_elem_ty = try o.lowerType(elem_ty);11562 const vec_elem_ty = try o.lowerType(pt, elem_ty);
11564 const vec_ty = try o.builder.vectorType(.normal, info.packed_offset.host_size, vec_elem_ty);11563 const vec_ty = try o.builder.vectorType(.normal, info.packed_offset.host_size, vec_elem_ty);
1156511564
11566 const loaded_vector = try self.wip.load(.normal, vec_ty, ptr, ptr_alignment, "");11565 const loaded_vector = try self.wip.load(.normal, vec_ty, ptr, ptr_alignment, "");
...@@ -11629,7 +11628,7 @@ pub const FuncGen = struct {...@@ -11629,7 +11628,7 @@ pub const FuncGen = struct {
11629 ptr_alignment,11628 ptr_alignment,
11630 elem,11629 elem,
11631 elem_ty.abiAlignment(zcu).toLlvm(),11630 elem_ty.abiAlignment(zcu).toLlvm(),
11632 try o.builder.intValue(try o.lowerType(Type.usize), elem_ty.abiSize(zcu)),11631 try o.builder.intValue(try o.lowerType(pt, Type.usize), elem_ty.abiSize(zcu)),
11633 access_kind,11632 access_kind,
11634 self.disable_intrinsics,11633 self.disable_intrinsics,
11635 );11634 );
...@@ -11638,7 +11637,8 @@ pub const FuncGen = struct {...@@ -11638,7 +11637,8 @@ pub const FuncGen = struct {
11638 fn valgrindMarkUndef(fg: *FuncGen, ptr: Builder.Value, len: Builder.Value) Allocator.Error!void {11637 fn valgrindMarkUndef(fg: *FuncGen, ptr: Builder.Value, len: Builder.Value) Allocator.Error!void {
11639 const VG_USERREQ__MAKE_MEM_UNDEFINED = 1296236545;11638 const VG_USERREQ__MAKE_MEM_UNDEFINED = 1296236545;
11640 const o = fg.ng.object;11639 const o = fg.ng.object;
11641 const usize_ty = try o.lowerType(Type.usize);11640 const pt = fg.ng.pt;
11641 const usize_ty = try o.lowerType(pt, Type.usize);
11642 const zero = try o.builder.intValue(usize_ty, 0);11642 const zero = try o.builder.intValue(usize_ty, 0);
11643 const req = try o.builder.intValue(usize_ty, VG_USERREQ__MAKE_MEM_UNDEFINED);11643 const req = try o.builder.intValue(usize_ty, VG_USERREQ__MAKE_MEM_UNDEFINED);
11644 const ptr_as_usize = try fg.wip.cast(.ptrtoint, ptr, usize_ty, "");11644 const ptr_as_usize = try fg.wip.cast(.ptrtoint, ptr, usize_ty, "");
...@@ -11656,12 +11656,12 @@ pub const FuncGen = struct {...@@ -11656,12 +11656,12 @@ pub const FuncGen = struct {
11656 a5: Builder.Value,11656 a5: Builder.Value,
11657 ) Allocator.Error!Builder.Value {11657 ) Allocator.Error!Builder.Value {
11658 const o = fg.ng.object;11658 const o = fg.ng.object;
11659 const pt = o.pt;11659 const pt = fg.ng.pt;
11660 const zcu = pt.zcu;11660 const zcu = pt.zcu;
11661 const target = zcu.getTarget();11661 const target = zcu.getTarget();
11662 if (!target_util.hasValgrindSupport(target, .stage2_llvm)) return default_value;11662 if (!target_util.hasValgrindSupport(target, .stage2_llvm)) return default_value;
1166311663
11664 const llvm_usize = try o.lowerType(Type.usize);11664 const llvm_usize = try o.lowerType(pt, Type.usize);
11665 const usize_alignment = Type.usize.abiAlignment(zcu).toLlvm();11665 const usize_alignment = Type.usize.abiAlignment(zcu).toLlvm();
1166611666
11667 const array_llvm_ty = try o.builder.arrayType(6, llvm_usize);11667 const array_llvm_ty = try o.builder.arrayType(6, llvm_usize);
...@@ -11787,14 +11787,12 @@ pub const FuncGen = struct {...@@ -11787,14 +11787,12 @@ pub const FuncGen = struct {
11787 }11787 }
1178811788
11789 fn typeOf(fg: *FuncGen, inst: Air.Inst.Ref) Type {11789 fn typeOf(fg: *FuncGen, inst: Air.Inst.Ref) Type {
11790 const o = fg.ng.object;11790 const zcu = fg.ng.pt.zcu;
11791 const zcu = o.pt.zcu;
11792 return fg.air.typeOf(inst, &zcu.intern_pool);11791 return fg.air.typeOf(inst, &zcu.intern_pool);
11793 }11792 }
1179411793
11795 fn typeOfIndex(fg: *FuncGen, inst: Air.Inst.Index) Type {11794 fn typeOfIndex(fg: *FuncGen, inst: Air.Inst.Index) Type {
11796 const o = fg.ng.object;11795 const zcu = fg.ng.pt.zcu;
11797 const zcu = o.pt.zcu;
11798 return fg.air.typeOfIndex(inst, &zcu.intern_pool);11796 return fg.air.typeOfIndex(inst, &zcu.intern_pool);
11799 }11797 }
11800};11798};
...@@ -12152,40 +12150,39 @@ fn firstParamSRetSystemV(ty: Type, zcu: *Zcu, target: *const std.Target) bool {...@@ -12152,40 +12150,39 @@ fn firstParamSRetSystemV(ty: Type, zcu: *Zcu, target: *const std.Target) bool {
12152/// In order to support the C calling convention, some return types need to be lowered12150/// In order to support the C calling convention, some return types need to be lowered
12153/// completely differently in the function prototype to honor the C ABI, and then12151/// completely differently in the function prototype to honor the C ABI, and then
12154/// be effectively bitcasted to the actual return type.12152/// be effectively bitcasted to the actual return type.
12155fn lowerFnRetTy(o: *Object, fn_info: InternPool.Key.FuncType) Allocator.Error!Builder.Type {12153fn lowerFnRetTy(o: *Object, pt: Zcu.PerThread, fn_info: InternPool.Key.FuncType) Allocator.Error!Builder.Type {
12156 const pt = o.pt;
12157 const zcu = pt.zcu;12154 const zcu = pt.zcu;
12158 const return_type = Type.fromInterned(fn_info.return_type);12155 const return_type = Type.fromInterned(fn_info.return_type);
12159 if (!return_type.hasRuntimeBitsIgnoreComptime(zcu)) {12156 if (!return_type.hasRuntimeBitsIgnoreComptime(zcu)) {
12160 // If the return type is an error set or an error union, then we make this12157 // If the return type is an error set or an error union, then we make this
12161 // anyerror return type instead, so that it can be coerced into a function12158 // anyerror return type instead, so that it can be coerced into a function
12162 // pointer type which has anyerror as the return type.12159 // pointer type which has anyerror as the return type.
12163 return if (return_type.isError(zcu)) try o.errorIntType() else .void;12160 return if (return_type.isError(zcu)) try o.errorIntType(pt) else .void;
12164 }12161 }
12165 const target = zcu.getTarget();12162 const target = zcu.getTarget();
12166 switch (fn_info.cc) {12163 switch (fn_info.cc) {
12167 .@"inline" => unreachable,12164 .@"inline" => unreachable,
12168 .auto => return if (returnTypeByRef(zcu, target, return_type)) .void else o.lowerType(return_type),12165 .auto => return if (returnTypeByRef(zcu, target, return_type)) .void else o.lowerType(pt, return_type),
1216912166
12170 .x86_64_sysv => return lowerSystemVFnRetTy(o, fn_info),12167 .x86_64_sysv => return lowerSystemVFnRetTy(o, pt, fn_info),
12171 .x86_64_win => return lowerWin64FnRetTy(o, fn_info),12168 .x86_64_win => return lowerWin64FnRetTy(o, pt, fn_info),
12172 .x86_stdcall => return if (isScalar(zcu, return_type)) o.lowerType(return_type) else .void,12169 .x86_stdcall => return if (isScalar(zcu, return_type)) o.lowerType(pt, return_type) else .void,
12173 .x86_sysv, .x86_win => return if (isByRef(return_type, zcu)) .void else o.lowerType(return_type),12170 .x86_sysv, .x86_win => return if (isByRef(return_type, zcu)) .void else o.lowerType(pt, return_type),
12174 .aarch64_aapcs, .aarch64_aapcs_darwin, .aarch64_aapcs_win => switch (aarch64_c_abi.classifyType(return_type, zcu)) {12171 .aarch64_aapcs, .aarch64_aapcs_darwin, .aarch64_aapcs_win => switch (aarch64_c_abi.classifyType(return_type, zcu)) {
12175 .memory => return .void,12172 .memory => return .void,
12176 .float_array => return o.lowerType(return_type),12173 .float_array => return o.lowerType(pt, return_type),
12177 .byval => return o.lowerType(return_type),12174 .byval => return o.lowerType(pt, return_type),
12178 .integer => return o.builder.intType(@intCast(return_type.bitSize(zcu))),12175 .integer => return o.builder.intType(@intCast(return_type.bitSize(zcu))),
12179 .double_integer => return o.builder.arrayType(2, .i64),12176 .double_integer => return o.builder.arrayType(2, .i64),
12180 },12177 },
12181 .arm_aapcs, .arm_aapcs_vfp => switch (arm_c_abi.classifyType(return_type, zcu, .ret)) {12178 .arm_aapcs, .arm_aapcs_vfp => switch (arm_c_abi.classifyType(return_type, zcu, .ret)) {
12182 .memory, .i64_array => return .void,12179 .memory, .i64_array => return .void,
12183 .i32_array => |len| return if (len == 1) .i32 else .void,12180 .i32_array => |len| return if (len == 1) .i32 else .void,
12184 .byval => return o.lowerType(return_type),12181 .byval => return o.lowerType(pt, return_type),
12185 },12182 },
12186 .mips_o32 => switch (mips_c_abi.classifyType(return_type, zcu, .ret)) {12183 .mips_o32 => switch (mips_c_abi.classifyType(return_type, zcu, .ret)) {
12187 .memory, .i32_array => return .void,12184 .memory, .i32_array => return .void,
12188 .byval => return o.lowerType(return_type),12185 .byval => return o.lowerType(pt, return_type),
12189 },12186 },
12190 .riscv64_lp64, .riscv32_ilp32 => switch (riscv_c_abi.classifyType(return_type, zcu)) {12187 .riscv64_lp64, .riscv32_ilp32 => switch (riscv_c_abi.classifyType(return_type, zcu)) {
12191 .memory => return .void,12188 .memory => return .void,
...@@ -12195,53 +12192,52 @@ fn lowerFnRetTy(o: *Object, fn_info: InternPool.Key.FuncType) Allocator.Error!Bu...@@ -12195,53 +12192,52 @@ fn lowerFnRetTy(o: *Object, fn_info: InternPool.Key.FuncType) Allocator.Error!Bu
12195 .double_integer => {12192 .double_integer => {
12196 return o.builder.structType(.normal, &.{ .i64, .i64 });12193 return o.builder.structType(.normal, &.{ .i64, .i64 });
12197 },12194 },
12198 .byval => return o.lowerType(return_type),12195 .byval => return o.lowerType(pt, return_type),
12199 .fields => {12196 .fields => {
12200 var types_len: usize = 0;12197 var types_len: usize = 0;
12201 var types: [8]Builder.Type = undefined;12198 var types: [8]Builder.Type = undefined;
12202 for (0..return_type.structFieldCount(zcu)) |field_index| {12199 for (0..return_type.structFieldCount(zcu)) |field_index| {
12203 const field_ty = return_type.fieldType(field_index, zcu);12200 const field_ty = return_type.fieldType(field_index, zcu);
12204 if (!field_ty.hasRuntimeBitsIgnoreComptime(zcu)) continue;12201 if (!field_ty.hasRuntimeBitsIgnoreComptime(zcu)) continue;
12205 types[types_len] = try o.lowerType(field_ty);12202 types[types_len] = try o.lowerType(pt, field_ty);
12206 types_len += 1;12203 types_len += 1;
12207 }12204 }
12208 return o.builder.structType(.normal, types[0..types_len]);12205 return o.builder.structType(.normal, types[0..types_len]);
12209 },12206 },
12210 },12207 },
12211 .wasm_mvp => switch (wasm_c_abi.classifyType(return_type, zcu)) {12208 .wasm_mvp => switch (wasm_c_abi.classifyType(return_type, zcu)) {
12212 .direct => |scalar_ty| return o.lowerType(scalar_ty),12209 .direct => |scalar_ty| return o.lowerType(pt, scalar_ty),
12213 .indirect => return .void,12210 .indirect => return .void,
12214 },12211 },
12215 // TODO investigate other callconvs12212 // TODO investigate other callconvs
12216 else => return o.lowerType(return_type),12213 else => return o.lowerType(pt, return_type),
12217 }12214 }
12218}12215}
1221912216
12220fn lowerWin64FnRetTy(o: *Object, fn_info: InternPool.Key.FuncType) Allocator.Error!Builder.Type {12217fn lowerWin64FnRetTy(o: *Object, pt: Zcu.PerThread, fn_info: InternPool.Key.FuncType) Allocator.Error!Builder.Type {
12221 const zcu = o.pt.zcu;12218 const zcu = pt.zcu;
12222 const return_type = Type.fromInterned(fn_info.return_type);12219 const return_type = Type.fromInterned(fn_info.return_type);
12223 switch (x86_64_abi.classifyWindows(return_type, zcu, zcu.getTarget())) {12220 switch (x86_64_abi.classifyWindows(return_type, zcu, zcu.getTarget())) {
12224 .integer => {12221 .integer => {
12225 if (isScalar(zcu, return_type)) {12222 if (isScalar(zcu, return_type)) {
12226 return o.lowerType(return_type);12223 return o.lowerType(pt, return_type);
12227 } else {12224 } else {
12228 return o.builder.intType(@intCast(return_type.abiSize(zcu) * 8));12225 return o.builder.intType(@intCast(return_type.abiSize(zcu) * 8));
12229 }12226 }
12230 },12227 },
12231 .win_i128 => return o.builder.vectorType(.normal, 2, .i64),12228 .win_i128 => return o.builder.vectorType(.normal, 2, .i64),
12232 .memory => return .void,12229 .memory => return .void,
12233 .sse => return o.lowerType(return_type),12230 .sse => return o.lowerType(pt, return_type),
12234 else => unreachable,12231 else => unreachable,
12235 }12232 }
12236}12233}
1223712234
12238fn lowerSystemVFnRetTy(o: *Object, fn_info: InternPool.Key.FuncType) Allocator.Error!Builder.Type {12235fn lowerSystemVFnRetTy(o: *Object, pt: Zcu.PerThread, fn_info: InternPool.Key.FuncType) Allocator.Error!Builder.Type {
12239 const pt = o.pt;
12240 const zcu = pt.zcu;12236 const zcu = pt.zcu;
12241 const ip = &zcu.intern_pool;12237 const ip = &zcu.intern_pool;
12242 const return_type = Type.fromInterned(fn_info.return_type);12238 const return_type = Type.fromInterned(fn_info.return_type);
12243 if (isScalar(zcu, return_type)) {12239 if (isScalar(zcu, return_type)) {
12244 return o.lowerType(return_type);12240 return o.lowerType(pt, return_type);
12245 }12241 }
12246 const classes = x86_64_abi.classifySystemV(return_type, zcu, zcu.getTarget(), .ret);12242 const classes = x86_64_abi.classifySystemV(return_type, zcu, zcu.getTarget(), .ret);
12247 var types_index: u32 = 0;12243 var types_index: u32 = 0;
...@@ -12305,6 +12301,7 @@ fn lowerSystemVFnRetTy(o: *Object, fn_info: InternPool.Key.FuncType) Allocator.E...@@ -12305,6 +12301,7 @@ fn lowerSystemVFnRetTy(o: *Object, fn_info: InternPool.Key.FuncType) Allocator.E
1230512301
12306const ParamTypeIterator = struct {12302const ParamTypeIterator = struct {
12307 object: *Object,12303 object: *Object,
12304 pt: Zcu.PerThread,
12308 fn_info: InternPool.Key.FuncType,12305 fn_info: InternPool.Key.FuncType,
12309 zig_index: u32,12306 zig_index: u32,
12310 llvm_index: u32,12307 llvm_index: u32,
...@@ -12327,7 +12324,7 @@ const ParamTypeIterator = struct {...@@ -12327,7 +12324,7 @@ const ParamTypeIterator = struct {
1232712324
12328 pub fn next(it: *ParamTypeIterator) Allocator.Error!?Lowering {12325 pub fn next(it: *ParamTypeIterator) Allocator.Error!?Lowering {
12329 if (it.zig_index >= it.fn_info.param_types.len) return null;12326 if (it.zig_index >= it.fn_info.param_types.len) return null;
12330 const ip = &it.object.pt.zcu.intern_pool;12327 const ip = &it.pt.zcu.intern_pool;
12331 const ty = it.fn_info.param_types.get(ip)[it.zig_index];12328 const ty = it.fn_info.param_types.get(ip)[it.zig_index];
12332 it.byval_attr = false;12329 it.byval_attr = false;
12333 return nextInner(it, Type.fromInterned(ty));12330 return nextInner(it, Type.fromInterned(ty));
...@@ -12335,7 +12332,8 @@ const ParamTypeIterator = struct {...@@ -12335,7 +12332,8 @@ const ParamTypeIterator = struct {
1233512332
12336 /// `airCall` uses this instead of `next` so that it can take into account variadic functions.12333 /// `airCall` uses this instead of `next` so that it can take into account variadic functions.
12337 pub fn nextCall(it: *ParamTypeIterator, fg: *FuncGen, args: []const Air.Inst.Ref) Allocator.Error!?Lowering {12334 pub fn nextCall(it: *ParamTypeIterator, fg: *FuncGen, args: []const Air.Inst.Ref) Allocator.Error!?Lowering {
12338 const ip = &it.object.pt.zcu.intern_pool;12335 assert(std.meta.eql(it.pt, fg.ng.pt));
12336 const ip = &it.pt.zcu.intern_pool;
12339 if (it.zig_index >= it.fn_info.param_types.len) {12337 if (it.zig_index >= it.fn_info.param_types.len) {
12340 if (it.zig_index >= args.len) {12338 if (it.zig_index >= args.len) {
12341 return null;12339 return null;
...@@ -12348,7 +12346,7 @@ const ParamTypeIterator = struct {...@@ -12348,7 +12346,7 @@ const ParamTypeIterator = struct {
12348 }12346 }
1234912347
12350 fn nextInner(it: *ParamTypeIterator, ty: Type) Allocator.Error!?Lowering {12348 fn nextInner(it: *ParamTypeIterator, ty: Type) Allocator.Error!?Lowering {
12351 const pt = it.object.pt;12349 const pt = it.pt;
12352 const zcu = pt.zcu;12350 const zcu = pt.zcu;
12353 const target = zcu.getTarget();12351 const target = zcu.getTarget();
1235412352
...@@ -12448,7 +12446,7 @@ const ParamTypeIterator = struct {...@@ -12448,7 +12446,7 @@ const ParamTypeIterator = struct {
12448 for (0..ty.structFieldCount(zcu)) |field_index| {12446 for (0..ty.structFieldCount(zcu)) |field_index| {
12449 const field_ty = ty.fieldType(field_index, zcu);12447 const field_ty = ty.fieldType(field_index, zcu);
12450 if (!field_ty.hasRuntimeBitsIgnoreComptime(zcu)) continue;12448 if (!field_ty.hasRuntimeBitsIgnoreComptime(zcu)) continue;
12451 it.types_buffer[it.types_len] = try it.object.lowerType(field_ty);12449 it.types_buffer[it.types_len] = try it.object.lowerType(pt, field_ty);
12452 it.types_len += 1;12450 it.types_len += 1;
12453 }12451 }
12454 it.llvm_index += it.types_len - 1;12452 it.llvm_index += it.types_len - 1;
...@@ -12464,7 +12462,7 @@ const ParamTypeIterator = struct {...@@ -12464,7 +12462,7 @@ const ParamTypeIterator = struct {
12464 return .byval;12462 return .byval;
12465 } else {12463 } else {
12466 var types_buffer: [8]Builder.Type = undefined;12464 var types_buffer: [8]Builder.Type = undefined;
12467 types_buffer[0] = try it.object.lowerType(scalar_ty);12465 types_buffer[0] = try it.object.lowerType(pt, scalar_ty);
12468 it.types_buffer = types_buffer;12466 it.types_buffer = types_buffer;
12469 it.types_len = 1;12467 it.types_len = 1;
12470 it.llvm_index += 1;12468 it.llvm_index += 1;
...@@ -12489,7 +12487,7 @@ const ParamTypeIterator = struct {...@@ -12489,7 +12487,7 @@ const ParamTypeIterator = struct {
12489 }12487 }
1249012488
12491 fn nextWin64(it: *ParamTypeIterator, ty: Type) ?Lowering {12489 fn nextWin64(it: *ParamTypeIterator, ty: Type) ?Lowering {
12492 const zcu = it.object.pt.zcu;12490 const zcu = it.pt.zcu;
12493 switch (x86_64_abi.classifyWindows(ty, zcu, zcu.getTarget())) {12491 switch (x86_64_abi.classifyWindows(ty, zcu, zcu.getTarget())) {
12494 .integer => {12492 .integer => {
12495 if (isScalar(zcu, ty)) {12493 if (isScalar(zcu, ty)) {
...@@ -12522,7 +12520,7 @@ const ParamTypeIterator = struct {...@@ -12522,7 +12520,7 @@ const ParamTypeIterator = struct {
12522 }12520 }
1252312521
12524 fn nextSystemV(it: *ParamTypeIterator, ty: Type) Allocator.Error!?Lowering {12522 fn nextSystemV(it: *ParamTypeIterator, ty: Type) Allocator.Error!?Lowering {
12525 const zcu = it.object.pt.zcu;12523 const zcu = it.pt.zcu;
12526 const ip = &zcu.intern_pool;12524 const ip = &zcu.intern_pool;
12527 const classes = x86_64_abi.classifySystemV(ty, zcu, zcu.getTarget(), .arg);12525 const classes = x86_64_abi.classifySystemV(ty, zcu, zcu.getTarget(), .arg);
12528 if (classes[0] == .memory) {12526 if (classes[0] == .memory) {
...@@ -12615,9 +12613,10 @@ const ParamTypeIterator = struct {...@@ -12615,9 +12613,10 @@ const ParamTypeIterator = struct {
12615 }12613 }
12616};12614};
1261712615
12618fn iterateParamTypes(object: *Object, fn_info: InternPool.Key.FuncType) ParamTypeIterator {12616fn iterateParamTypes(object: *Object, pt: Zcu.PerThread, fn_info: InternPool.Key.FuncType) ParamTypeIterator {
12619 return .{12617 return .{
12620 .object = object,12618 .object = object,
12619 .pt = pt,
12621 .fn_info = fn_info,12620 .fn_info = fn_info,
12622 .zig_index = 0,12621 .zig_index = 0,
12623 .llvm_index = 0,12622 .llvm_index = 0,
src/codegen/spirv.zig+258-292
...@@ -15,9 +15,7 @@ const InternPool = @import("../InternPool.zig");...@@ -15,9 +15,7 @@ const InternPool = @import("../InternPool.zig");
15const spec = @import("spirv/spec.zig");15const spec = @import("spirv/spec.zig");
16const Opcode = spec.Opcode;16const Opcode = spec.Opcode;
17const Word = spec.Word;17const Word = spec.Word;
18const IdRef = spec.IdRef;18const Id = spec.Id;
19const IdResult = spec.IdResult;
20const IdResultType = spec.IdResultType;
21const StorageClass = spec.StorageClass;19const StorageClass = spec.StorageClass;
2220
23const SpvModule = @import("spirv/Module.zig");21const SpvModule = @import("spirv/Module.zig");
...@@ -26,7 +24,7 @@ const IdRange = SpvModule.IdRange;...@@ -26,7 +24,7 @@ const IdRange = SpvModule.IdRange;
26const SpvSection = @import("spirv/Section.zig");24const SpvSection = @import("spirv/Section.zig");
27const SpvAssembler = @import("spirv/Assembler.zig");25const SpvAssembler = @import("spirv/Assembler.zig");
2826
29const InstMap = std.AutoHashMapUnmanaged(Air.Inst.Index, IdRef);27const InstMap = std.AutoHashMapUnmanaged(Air.Inst.Index, Id);
3028
31pub fn legalizeFeatures(_: *const std.Target) *const Air.Legalize.Features {29pub fn legalizeFeatures(_: *const std.Target) *const Air.Legalize.Features {
32 return comptime &.initMany(&.{30 return comptime &.initMany(&.{
...@@ -42,10 +40,10 @@ pub fn legalizeFeatures(_: *const std.Target) *const Air.Legalize.Features {...@@ -42,10 +40,10 @@ pub fn legalizeFeatures(_: *const std.Target) *const Air.Legalize.Features {
42pub const zig_call_abi_ver = 3;40pub const zig_call_abi_ver = 3;
43pub const big_int_bits = 32;41pub const big_int_bits = 32;
4442
45const InternMap = std.AutoHashMapUnmanaged(struct { InternPool.Index, NavGen.Repr }, IdResult);43const InternMap = std.AutoHashMapUnmanaged(struct { InternPool.Index, NavGen.Repr }, Id);
46const PtrTypeMap = std.AutoHashMapUnmanaged(44const PtrTypeMap = std.AutoHashMapUnmanaged(
47 struct { InternPool.Index, StorageClass, NavGen.Repr },45 struct { InternPool.Index, StorageClass, NavGen.Repr },
48 struct { ty_id: IdRef, fwd_emitted: bool },46 struct { ty_id: Id, fwd_emitted: bool },
49);47);
5048
51const ControlFlow = union(enum) {49const ControlFlow = union(enum) {
...@@ -55,10 +53,10 @@ const ControlFlow = union(enum) {...@@ -55,10 +53,10 @@ const ControlFlow = union(enum) {
55 /// inside the block must reach the outside.53 /// inside the block must reach the outside.
56 const Block = union(enum) {54 const Block = union(enum) {
57 const Incoming = struct {55 const Incoming = struct {
58 src_label: IdRef,56 src_label: Id,
59 /// Instruction that returns an u32 value of the57 /// Instruction that returns an u32 value of the
60 /// `Air.Inst.Index` that control flow should jump to.58 /// `Air.Inst.Index` that control flow should jump to.
61 next_block: IdRef,59 next_block: Id,
62 };60 };
6361
64 const SelectionMerge = struct {62 const SelectionMerge = struct {
...@@ -69,7 +67,7 @@ const ControlFlow = union(enum) {...@@ -69,7 +67,7 @@ const ControlFlow = union(enum) {
69 /// The label id of the cond_br's merge block.67 /// The label id of the cond_br's merge block.
70 /// For the top-most element in the stack, this68 /// For the top-most element in the stack, this
71 /// value is undefined.69 /// value is undefined.
72 merge_block: IdRef,70 merge_block: Id,
73 };71 };
7472
75 /// For a `selection` type block, we cannot use early exits, and we73 /// For a `selection` type block, we cannot use early exits, and we
...@@ -100,7 +98,7 @@ const ControlFlow = union(enum) {...@@ -100,7 +98,7 @@ const ControlFlow = union(enum) {
100 /// of conditions that jump to the loop exit.98 /// of conditions that jump to the loop exit.
101 merges: std.ArrayListUnmanaged(Incoming) = .empty,99 merges: std.ArrayListUnmanaged(Incoming) = .empty,
102 /// The label id of the loop's merge block.100 /// The label id of the loop's merge block.
103 merge_block: IdRef,101 merge_block: Id,
104 },102 },
105103
106 fn deinit(self: *Structured.Block, a: Allocator) void {104 fn deinit(self: *Structured.Block, a: Allocator) void {
...@@ -116,17 +114,17 @@ const ControlFlow = union(enum) {...@@ -116,17 +114,17 @@ const ControlFlow = union(enum) {
116 block_stack: std.ArrayListUnmanaged(*Structured.Block) = .empty,114 block_stack: std.ArrayListUnmanaged(*Structured.Block) = .empty,
117 /// Maps `block` inst indices to the variable that the block's result115 /// Maps `block` inst indices to the variable that the block's result
118 /// value must be written to.116 /// value must be written to.
119 block_results: std.AutoHashMapUnmanaged(Air.Inst.Index, IdRef) = .empty,117 block_results: std.AutoHashMapUnmanaged(Air.Inst.Index, Id) = .empty,
120 };118 };
121119
122 const Unstructured = struct {120 const Unstructured = struct {
123 const Incoming = struct {121 const Incoming = struct {
124 src_label: IdRef,122 src_label: Id,
125 break_value_id: IdRef,123 break_value_id: Id,
126 };124 };
127125
128 const Block = struct {126 const Block = struct {
129 label: ?IdRef = null,127 label: ?Id = null,
130 incoming_blocks: std.ArrayListUnmanaged(Incoming) = .empty,128 incoming_blocks: std.ArrayListUnmanaged(Incoming) = .empty,
131 };129 };
132130
...@@ -318,7 +316,7 @@ const NavGen = struct {...@@ -318,7 +316,7 @@ const NavGen = struct {
318316
319 /// An array of function argument result-ids. Each index corresponds with the317 /// An array of function argument result-ids. Each index corresponds with the
320 /// function argument of the same index.318 /// function argument of the same index.
321 args: std.ArrayListUnmanaged(IdRef) = .empty,319 args: std.ArrayListUnmanaged(Id) = .empty,
322320
323 /// A counter to keep track of how many `arg` instructions we've seen yet.321 /// A counter to keep track of how many `arg` instructions we've seen yet.
324 next_arg_index: u32 = 0,322 next_arg_index: u32 = 0,
...@@ -337,7 +335,7 @@ const NavGen = struct {...@@ -337,7 +335,7 @@ const NavGen = struct {
337 control_flow: ControlFlow,335 control_flow: ControlFlow,
338336
339 /// The label of the SPIR-V block we are currently generating.337 /// The label of the SPIR-V block we are currently generating.
340 current_block_label: IdRef,338 current_block_label: Id,
341339
342 /// The code (prologue and body) for the function we are currently generating code for.340 /// The code (prologue and body) for the function we are currently generating code for.
343 func: SpvModule.Fn = .{},341 func: SpvModule.Fn = .{},
...@@ -436,17 +434,17 @@ const NavGen = struct {...@@ -436,17 +434,17 @@ const NavGen = struct {
436434
437 /// This imports the "default" extended instruction set for the target435 /// This imports the "default" extended instruction set for the target
438 /// For OpenCL, OpenCL.std.100. For Vulkan and OpenGL, GLSL.std.450.436 /// For OpenCL, OpenCL.std.100. For Vulkan and OpenGL, GLSL.std.450.
439 fn importExtendedSet(self: *NavGen) !IdResult {437 fn importExtendedSet(self: *NavGen) !Id {
440 const target = self.spv.target;438 const target = self.spv.target;
441 return switch (target.os.tag) {439 return switch (target.os.tag) {
442 .opencl, .amdhsa => try self.spv.importInstructionSet(.@"OpenCL.std"),440 .opencl, .amdhsa => try self.spv.importInstructionSet(.open_cl_std),
443 .vulkan, .opengl => try self.spv.importInstructionSet(.@"GLSL.std.450"),441 .vulkan, .opengl => try self.spv.importInstructionSet(.glsl_std_450),
444 else => unreachable,442 else => unreachable,
445 };443 };
446 }444 }
447445
448 /// Fetch the result-id for a previously generated instruction or constant.446 /// Fetch the result-id for a previously generated instruction or constant.
449 fn resolve(self: *NavGen, inst: Air.Inst.Ref) !IdRef {447 fn resolve(self: *NavGen, inst: Air.Inst.Ref) !Id {
450 const pt = self.pt;448 const pt = self.pt;
451 const zcu = pt.zcu;449 const zcu = pt.zcu;
452 if (try self.air.value(inst, pt)) |val| {450 if (try self.air.value(inst, pt)) |val| {
...@@ -468,7 +466,7 @@ const NavGen = struct {...@@ -468,7 +466,7 @@ const NavGen = struct {
468 return self.inst_results.get(index).?; // Assertion means instruction does not dominate usage.466 return self.inst_results.get(index).?; // Assertion means instruction does not dominate usage.
469 }467 }
470468
471 fn resolveUav(self: *NavGen, val: InternPool.Index) !IdRef {469 fn resolveUav(self: *NavGen, val: InternPool.Index) !Id {
472 // TODO: This cannot be a function at this point, but it should probably be handled anyway.470 // TODO: This cannot be a function at this point, but it should probably be handled anyway.
473471
474 const zcu = self.pt.zcu;472 const zcu = self.pt.zcu;
...@@ -476,16 +474,16 @@ const NavGen = struct {...@@ -476,16 +474,16 @@ const NavGen = struct {
476 const decl_ptr_ty_id = try self.ptrType(ty, self.spvStorageClass(.generic), .indirect);474 const decl_ptr_ty_id = try self.ptrType(ty, self.spvStorageClass(.generic), .indirect);
477475
478 const spv_decl_index = blk: {476 const spv_decl_index = blk: {
479 const entry = try self.object.uav_link.getOrPut(self.object.gpa, .{ val, .Function });477 const entry = try self.object.uav_link.getOrPut(self.object.gpa, .{ val, .function });
480 if (entry.found_existing) {478 if (entry.found_existing) {
481 try self.addFunctionDep(entry.value_ptr.*, .Function);479 try self.addFunctionDep(entry.value_ptr.*, .function);
482480
483 const result_id = self.spv.declPtr(entry.value_ptr.*).result_id;481 const result_id = self.spv.declPtr(entry.value_ptr.*).result_id;
484 return try self.castToGeneric(decl_ptr_ty_id, result_id);482 return try self.castToGeneric(decl_ptr_ty_id, result_id);
485 }483 }
486484
487 const spv_decl_index = try self.spv.allocDecl(.invocation_global);485 const spv_decl_index = try self.spv.allocDecl(.invocation_global);
488 try self.addFunctionDep(spv_decl_index, .Function);486 try self.addFunctionDep(spv_decl_index, .function);
489 entry.value_ptr.* = spv_decl_index;487 entry.value_ptr.* = spv_decl_index;
490 break :blk spv_decl_index;488 break :blk spv_decl_index;
491 };489 };
...@@ -536,7 +534,7 @@ const NavGen = struct {...@@ -536,7 +534,7 @@ const NavGen = struct {
536534
537 try self.spv.debugNameFmt(initializer_id, "initializer of __anon_{d}", .{@intFromEnum(val)});535 try self.spv.debugNameFmt(initializer_id, "initializer of __anon_{d}", .{@intFromEnum(val)});
538536
539 const fn_decl_ptr_ty_id = try self.ptrType(ty, .Function, .indirect);537 const fn_decl_ptr_ty_id = try self.ptrType(ty, .function, .indirect);
540 try self.spv.sections.types_globals_constants.emit(self.spv.gpa, .OpExtInst, .{538 try self.spv.sections.types_globals_constants.emit(self.spv.gpa, .OpExtInst, .{
541 .id_result_type = fn_decl_ptr_ty_id,539 .id_result_type = fn_decl_ptr_ty_id,
542 .id_result = result_id,540 .id_result = result_id,
...@@ -552,7 +550,7 @@ const NavGen = struct {...@@ -552,7 +550,7 @@ const NavGen = struct {
552 fn addFunctionDep(self: *NavGen, decl_index: SpvModule.Decl.Index, storage_class: StorageClass) !void {550 fn addFunctionDep(self: *NavGen, decl_index: SpvModule.Decl.Index, storage_class: StorageClass) !void {
553 if (self.spv.version.minor < 4) {551 if (self.spv.version.minor < 4) {
554 // Before version 1.4, the interface’s storage classes are limited to the Input and Output552 // Before version 1.4, the interface’s storage classes are limited to the Input and Output
555 if (storage_class == .Input or storage_class == .Output) {553 if (storage_class == .input or storage_class == .output) {
556 try self.func.decl_deps.put(self.spv.gpa, decl_index, {});554 try self.func.decl_deps.put(self.spv.gpa, decl_index, {});
557 }555 }
558 } else {556 } else {
...@@ -560,7 +558,7 @@ const NavGen = struct {...@@ -560,7 +558,7 @@ const NavGen = struct {
560 }558 }
561 }559 }
562560
563 fn castToGeneric(self: *NavGen, type_id: IdRef, ptr_id: IdRef) !IdRef {561 fn castToGeneric(self: *NavGen, type_id: Id, ptr_id: Id) !Id {
564 if (self.spv.hasFeature(.generic_pointer)) {562 if (self.spv.hasFeature(.generic_pointer)) {
565 const result_id = self.spv.allocId();563 const result_id = self.spv.allocId();
566 try self.func.body.emit(self.spv.gpa, .OpPtrCastToGeneric, .{564 try self.func.body.emit(self.spv.gpa, .OpPtrCastToGeneric, .{
...@@ -578,7 +576,7 @@ const NavGen = struct {...@@ -578,7 +576,7 @@ const NavGen = struct {
578 /// block we are currently generating.576 /// block we are currently generating.
579 /// Note that there is no such thing as nested blocks like in ZIR or AIR, so we don't need to577 /// Note that there is no such thing as nested blocks like in ZIR or AIR, so we don't need to
580 /// keep track of the previous block.578 /// keep track of the previous block.
581 fn beginSpvBlock(self: *NavGen, label: IdResult) !void {579 fn beginSpvBlock(self: *NavGen, label: Id) !void {
582 try self.func.body.emit(self.spv.gpa, .OpLabel, .{ .id_result = label });580 try self.func.body.emit(self.spv.gpa, .OpLabel, .{ .id_result = label });
583 self.current_block_label = label;581 self.current_block_label = label;
584 }582 }
...@@ -705,7 +703,7 @@ const NavGen = struct {...@@ -705,7 +703,7 @@ const NavGen = struct {
705 }703 }
706704
707 /// Emits a bool constant in a particular representation.705 /// Emits a bool constant in a particular representation.
708 fn constBool(self: *NavGen, value: bool, repr: Repr) !IdRef {706 fn constBool(self: *NavGen, value: bool, repr: Repr) !Id {
709 return switch (repr) {707 return switch (repr) {
710 .indirect => self.constInt(Type.u1, @intFromBool(value)),708 .indirect => self.constInt(Type.u1, @intFromBool(value)),
711 .direct => self.spv.constBool(value),709 .direct => self.spv.constBool(value),
...@@ -715,7 +713,7 @@ const NavGen = struct {...@@ -715,7 +713,7 @@ const NavGen = struct {
715 /// Emits an integer constant.713 /// Emits an integer constant.
716 /// This function, unlike SpvModule.constInt, takes care to bitcast714 /// This function, unlike SpvModule.constInt, takes care to bitcast
717 /// the value to an unsigned int first for Kernels.715 /// the value to an unsigned int first for Kernels.
718 fn constInt(self: *NavGen, ty: Type, value: anytype) !IdRef {716 fn constInt(self: *NavGen, ty: Type, value: anytype) !Id {
719 const zcu = self.pt.zcu;717 const zcu = self.pt.zcu;
720 const scalar_ty = ty.scalarType(zcu);718 const scalar_ty = ty.scalarType(zcu);
721 const int_info = scalar_ty.intInfo(zcu);719 const int_info = scalar_ty.intInfo(zcu);
...@@ -773,7 +771,7 @@ const NavGen = struct {...@@ -773,7 +771,7 @@ const NavGen = struct {
773 return self.constructCompositeSplat(ty, result_id);771 return self.constructCompositeSplat(ty, result_id);
774 }772 }
775773
776 pub fn constructComposite(self: *NavGen, result_ty_id: IdRef, constituents: []const IdRef) !IdRef {774 pub fn constructComposite(self: *NavGen, result_ty_id: Id, constituents: []const Id) !Id {
777 const result_id = self.spv.allocId();775 const result_id = self.spv.allocId();
778 try self.func.body.emit(self.gpa, .OpCompositeConstruct, .{776 try self.func.body.emit(self.gpa, .OpCompositeConstruct, .{
779 .id_result_type = result_ty_id,777 .id_result_type = result_ty_id,
...@@ -785,11 +783,11 @@ const NavGen = struct {...@@ -785,11 +783,11 @@ const NavGen = struct {
785783
786 /// Construct a composite at runtime with all lanes set to the same value.784 /// Construct a composite at runtime with all lanes set to the same value.
787 /// ty must be an aggregate type.785 /// ty must be an aggregate type.
788 fn constructCompositeSplat(self: *NavGen, ty: Type, constituent: IdRef) !IdRef {786 fn constructCompositeSplat(self: *NavGen, ty: Type, constituent: Id) !Id {
789 const zcu = self.pt.zcu;787 const zcu = self.pt.zcu;
790 const n: usize = @intCast(ty.arrayLen(zcu));788 const n: usize = @intCast(ty.arrayLen(zcu));
791789
792 const constituents = try self.gpa.alloc(IdRef, n);790 const constituents = try self.gpa.alloc(Id, n);
793 defer self.gpa.free(constituents);791 defer self.gpa.free(constituents);
794 @memset(constituents, constituent);792 @memset(constituents, constituent);
795793
...@@ -803,7 +801,7 @@ const NavGen = struct {...@@ -803,7 +801,7 @@ const NavGen = struct {
803 /// is done by emitting a sequence of instructions that initialize the value.801 /// is done by emitting a sequence of instructions that initialize the value.
804 //802 //
805 /// This function should only be called during function code generation.803 /// This function should only be called during function code generation.
806 fn constant(self: *NavGen, ty: Type, val: Value, repr: Repr) !IdRef {804 fn constant(self: *NavGen, ty: Type, val: Value, repr: Repr) !Id {
807 // Note: Using intern_map can only be used with constants that DO NOT generate any runtime code!!805 // Note: Using intern_map can only be used with constants that DO NOT generate any runtime code!!
808 // Ideally that should be all constants in the future, or it should be cleaned up somehow. For806 // Ideally that should be all constants in the future, or it should be cleaned up somehow. For
809 // now, only use the intern_map on case-by-case basis by breaking to :cache.807 // now, only use the intern_map on case-by-case basis by breaking to :cache.
...@@ -909,7 +907,7 @@ const NavGen = struct {...@@ -909,7 +907,7 @@ const NavGen = struct {
909 .payload => |payload| payload,907 .payload => |payload| payload,
910 });908 });
911909
912 var constituents: [2]IdRef = undefined;910 var constituents: [2]Id = undefined;
913 var types: [2]Type = undefined;911 var types: [2]Type = undefined;
914 if (eu_layout.error_first) {912 if (eu_layout.error_first) {
915 constituents[0] = try self.constant(err_ty, err_val, .indirect);913 constituents[0] = try self.constant(err_ty, err_val, .indirect);
...@@ -967,7 +965,7 @@ const NavGen = struct {...@@ -967,7 +965,7 @@ const NavGen = struct {
967 inline .array_type, .vector_type => |array_type, tag| {965 inline .array_type, .vector_type => |array_type, tag| {
968 const elem_ty = Type.fromInterned(array_type.child);966 const elem_ty = Type.fromInterned(array_type.child);
969967
970 const constituents = try self.gpa.alloc(IdRef, @intCast(ty.arrayLenIncludingSentinel(zcu)));968 const constituents = try self.gpa.alloc(Id, @intCast(ty.arrayLenIncludingSentinel(zcu)));
971 defer self.gpa.free(constituents);969 defer self.gpa.free(constituents);
972970
973 const child_repr: Repr = switch (tag) {971 const child_repr: Repr = switch (tag) {
...@@ -1015,7 +1013,7 @@ const NavGen = struct {...@@ -1015,7 +1013,7 @@ const NavGen = struct {
1015 var types = std.ArrayList(Type).init(self.gpa);1013 var types = std.ArrayList(Type).init(self.gpa);
1016 defer types.deinit();1014 defer types.deinit();
10171015
1018 var constituents = std.ArrayList(IdRef).init(self.gpa);1016 var constituents = std.ArrayList(Id).init(self.gpa);
1019 defer constituents.deinit();1017 defer constituents.deinit();
10201018
1021 var it = struct_type.iterateRuntimeOrder(ip);1019 var it = struct_type.iterateRuntimeOrder(ip);
...@@ -1064,7 +1062,7 @@ const NavGen = struct {...@@ -1064,7 +1062,7 @@ const NavGen = struct {
1064 return cacheable_id;1062 return cacheable_id;
1065 }1063 }
10661064
1067 fn constantPtr(self: *NavGen, ptr_val: Value) Error!IdRef {1065 fn constantPtr(self: *NavGen, ptr_val: Value) Error!Id {
1068 const pt = self.pt;1066 const pt = self.pt;
10691067
1070 if (ptr_val.isUndef(pt.zcu)) {1068 if (ptr_val.isUndef(pt.zcu)) {
...@@ -1080,7 +1078,7 @@ const NavGen = struct {...@@ -1080,7 +1078,7 @@ const NavGen = struct {
1080 return self.derivePtr(derivation);1078 return self.derivePtr(derivation);
1081 }1079 }
10821080
1083 fn derivePtr(self: *NavGen, derivation: Value.PointerDeriveStep) Error!IdRef {1081 fn derivePtr(self: *NavGen, derivation: Value.PointerDeriveStep) Error!Id {
1084 const pt = self.pt;1082 const pt = self.pt;
1085 const zcu = pt.zcu;1083 const zcu = pt.zcu;
1086 switch (derivation) {1084 switch (derivation) {
...@@ -1159,7 +1157,7 @@ const NavGen = struct {...@@ -1159,7 +1157,7 @@ const NavGen = struct {
1159 self: *NavGen,1157 self: *NavGen,
1160 ty: Type,1158 ty: Type,
1161 uav: InternPool.Key.Ptr.BaseAddr.Uav,1159 uav: InternPool.Key.Ptr.BaseAddr.Uav,
1162 ) !IdRef {1160 ) !Id {
1163 // TODO: Merge this function with constantDeclRef.1161 // TODO: Merge this function with constantDeclRef.
11641162
1165 const pt = self.pt;1163 const pt = self.pt;
...@@ -1182,7 +1180,7 @@ const NavGen = struct {...@@ -1182,7 +1180,7 @@ const NavGen = struct {
11821180
1183 // Uav refs are always generic.1181 // Uav refs are always generic.
1184 assert(ty.ptrAddressSpace(zcu) == .generic);1182 assert(ty.ptrAddressSpace(zcu) == .generic);
1185 const decl_ptr_ty_id = try self.ptrType(uav_ty, .Generic, .indirect);1183 const decl_ptr_ty_id = try self.ptrType(uav_ty, .generic, .indirect);
1186 const ptr_id = try self.resolveUav(uav.val);1184 const ptr_id = try self.resolveUav(uav.val);
11871185
1188 if (decl_ptr_ty_id != ty_id) {1186 if (decl_ptr_ty_id != ty_id) {
...@@ -1199,7 +1197,7 @@ const NavGen = struct {...@@ -1199,7 +1197,7 @@ const NavGen = struct {
1199 }1197 }
1200 }1198 }
12011199
1202 fn constantNavRef(self: *NavGen, ty: Type, nav_index: InternPool.Nav.Index) !IdRef {1200 fn constantNavRef(self: *NavGen, ty: Type, nav_index: InternPool.Nav.Index) !Id {
1203 const pt = self.pt;1201 const pt = self.pt;
1204 const zcu = pt.zcu;1202 const zcu = pt.zcu;
1205 const ip = &zcu.intern_pool;1203 const ip = &zcu.intern_pool;
...@@ -1240,7 +1238,7 @@ const NavGen = struct {...@@ -1240,7 +1238,7 @@ const NavGen = struct {
1240 const decl_ptr_ty_id = try self.ptrType(nav_ty, storage_class, .indirect);1238 const decl_ptr_ty_id = try self.ptrType(nav_ty, storage_class, .indirect);
12411239
1242 const ptr_id = switch (storage_class) {1240 const ptr_id = switch (storage_class) {
1243 .Generic => try self.castToGeneric(decl_ptr_ty_id, decl_id),1241 .generic => try self.castToGeneric(decl_ptr_ty_id, decl_id),
1244 else => decl_id,1242 else => decl_id,
1245 };1243 };
12461244
...@@ -1272,7 +1270,7 @@ const NavGen = struct {...@@ -1272,7 +1270,7 @@ const NavGen = struct {
1272 /// The integer type that is returned by this function is the type that is used to perform1270 /// The integer type that is returned by this function is the type that is used to perform
1273 /// actual operations (as well as store) a Zig type of a particular number of bits. To create1271 /// actual operations (as well as store) a Zig type of a particular number of bits. To create
1274 /// a type with an exact size, use SpvModule.intType.1272 /// a type with an exact size, use SpvModule.intType.
1275 fn intType(self: *NavGen, signedness: std.builtin.Signedness, bits: u16) !IdRef {1273 fn intType(self: *NavGen, signedness: std.builtin.Signedness, bits: u16) !Id {
1276 const backing_bits, const big_int = self.backingIntBits(bits);1274 const backing_bits, const big_int = self.backingIntBits(bits);
1277 if (big_int) {1275 if (big_int) {
1278 if (backing_bits > 64) {1276 if (backing_bits > 64) {
...@@ -1289,12 +1287,12 @@ const NavGen = struct {...@@ -1289,12 +1287,12 @@ const NavGen = struct {
1289 };1287 };
1290 }1288 }
12911289
1292 fn arrayType(self: *NavGen, len: u32, child_ty: IdRef) !IdRef {1290 fn arrayType(self: *NavGen, len: u32, child_ty: Id) !Id {
1293 const len_id = try self.constInt(Type.u32, len);1291 const len_id = try self.constInt(Type.u32, len);
1294 return self.spv.arrayType(len_id, child_ty);1292 return self.spv.arrayType(len_id, child_ty);
1295 }1293 }
12961294
1297 fn ptrType(self: *NavGen, child_ty: Type, storage_class: StorageClass, child_repr: Repr) !IdRef {1295 fn ptrType(self: *NavGen, child_ty: Type, storage_class: StorageClass, child_repr: Repr) !Id {
1298 const zcu = self.pt.zcu;1296 const zcu = self.pt.zcu;
1299 const ip = &zcu.intern_pool;1297 const ip = &zcu.intern_pool;
1300 const key = .{ child_ty.toIntern(), storage_class, child_repr };1298 const key = .{ child_ty.toIntern(), storage_class, child_repr };
...@@ -1323,7 +1321,7 @@ const NavGen = struct {...@@ -1323,7 +1321,7 @@ const NavGen = struct {
1323 .vulkan, .opengl => {1321 .vulkan, .opengl => {
1324 if (child_ty.zigTypeTag(zcu) == .@"struct") {1322 if (child_ty.zigTypeTag(zcu) == .@"struct") {
1325 switch (storage_class) {1323 switch (storage_class) {
1326 .Uniform, .PushConstant => try self.spv.decorate(child_ty_id, .Block),1324 .uniform, .push_constant => try self.spv.decorate(child_ty_id, .block),
1327 else => {},1325 else => {},
1328 }1326 }
1329 }1327 }
...@@ -1331,7 +1329,7 @@ const NavGen = struct {...@@ -1331,7 +1329,7 @@ const NavGen = struct {
1331 switch (ip.indexToKey(child_ty.toIntern())) {1329 switch (ip.indexToKey(child_ty.toIntern())) {
1332 .func_type, .opaque_type => {},1330 .func_type, .opaque_type => {},
1333 else => {1331 else => {
1334 try self.spv.decorate(result_id, .{ .ArrayStride = .{ .array_stride = @intCast(child_ty.abiSize(zcu)) } });1332 try self.spv.decorate(result_id, .{ .array_stride = .{ .array_stride = @intCast(child_ty.abiSize(zcu)) } });
1335 },1333 },
1336 }1334 }
1337 },1335 },
...@@ -1349,9 +1347,9 @@ const NavGen = struct {...@@ -1349,9 +1347,9 @@ const NavGen = struct {
1349 return result_id;1347 return result_id;
1350 }1348 }
13511349
1352 fn functionType(self: *NavGen, return_ty: Type, param_types: []const Type) !IdRef {1350 fn functionType(self: *NavGen, return_ty: Type, param_types: []const Type) !Id {
1353 const return_ty_id = try self.resolveFnReturnType(return_ty);1351 const return_ty_id = try self.resolveFnReturnType(return_ty);
1354 const param_ids = try self.gpa.alloc(IdRef, param_types.len);1352 const param_ids = try self.gpa.alloc(Id, param_types.len);
1355 defer self.gpa.free(param_ids);1353 defer self.gpa.free(param_ids);
13561354
1357 for (param_types, param_ids) |param_ty, *param_id| {1355 for (param_types, param_ids) |param_ty, *param_id| {
...@@ -1379,7 +1377,7 @@ const NavGen = struct {...@@ -1379,7 +1377,7 @@ const NavGen = struct {
1379 /// padding: [padding_size]u8,1377 /// padding: [padding_size]u8,
1380 /// }1378 /// }
1381 /// If any of the fields' size is 0, it will be omitted.1379 /// If any of the fields' size is 0, it will be omitted.
1382 fn resolveUnionType(self: *NavGen, ty: Type) !IdRef {1380 fn resolveUnionType(self: *NavGen, ty: Type) !Id {
1383 const zcu = self.pt.zcu;1381 const zcu = self.pt.zcu;
1384 const ip = &zcu.intern_pool;1382 const ip = &zcu.intern_pool;
1385 const union_obj = zcu.typeToUnion(ty).?;1383 const union_obj = zcu.typeToUnion(ty).?;
...@@ -1394,7 +1392,7 @@ const NavGen = struct {...@@ -1394,7 +1392,7 @@ const NavGen = struct {
1394 return try self.resolveType(Type.fromInterned(union_obj.enum_tag_ty), .indirect);1392 return try self.resolveType(Type.fromInterned(union_obj.enum_tag_ty), .indirect);
1395 }1393 }
13961394
1397 var member_types: [4]IdRef = undefined;1395 var member_types: [4]Id = undefined;
1398 var member_names: [4][]const u8 = undefined;1396 var member_names: [4][]const u8 = undefined;
13991397
1400 const u8_ty_id = try self.resolveType(Type.u8, .direct);1398 const u8_ty_id = try self.resolveType(Type.u8, .direct);
...@@ -1433,7 +1431,7 @@ const NavGen = struct {...@@ -1433,7 +1431,7 @@ const NavGen = struct {
1433 return result_id;1431 return result_id;
1434 }1432 }
14351433
1436 fn resolveFnReturnType(self: *NavGen, ret_ty: Type) !IdRef {1434 fn resolveFnReturnType(self: *NavGen, ret_ty: Type) !Id {
1437 const zcu = self.pt.zcu;1435 const zcu = self.pt.zcu;
1438 if (!ret_ty.hasRuntimeBitsIgnoreComptime(zcu)) {1436 if (!ret_ty.hasRuntimeBitsIgnoreComptime(zcu)) {
1439 // If the return type is an error set or an error union, then we make this1437 // If the return type is an error set or an error union, then we make this
...@@ -1450,7 +1448,7 @@ const NavGen = struct {...@@ -1450,7 +1448,7 @@ const NavGen = struct {
1450 }1448 }
14511449
1452 /// Turn a Zig type into a SPIR-V Type, and return a reference to it.1450 /// Turn a Zig type into a SPIR-V Type, and return a reference to it.
1453 fn resolveType(self: *NavGen, ty: Type, repr: Repr) Error!IdRef {1451 fn resolveType(self: *NavGen, ty: Type, repr: Repr) Error!Id {
1454 if (self.intern_map.get(.{ ty.toIntern(), repr })) |id| {1452 if (self.intern_map.get(.{ ty.toIntern(), repr })) |id| {
1455 return id;1453 return id;
1456 }1454 }
...@@ -1460,7 +1458,7 @@ const NavGen = struct {...@@ -1460,7 +1458,7 @@ const NavGen = struct {
1460 return id;1458 return id;
1461 }1459 }
14621460
1463 fn resolveTypeInner(self: *NavGen, ty: Type, repr: Repr) Error!IdRef {1461 fn resolveTypeInner(self: *NavGen, ty: Type, repr: Repr) Error!Id {
1464 const pt = self.pt;1462 const pt = self.pt;
1465 const zcu = pt.zcu;1463 const zcu = pt.zcu;
1466 const ip = &zcu.intern_pool;1464 const ip = &zcu.intern_pool;
...@@ -1564,7 +1562,7 @@ const NavGen = struct {...@@ -1564,7 +1562,7 @@ const NavGen = struct {
1564 const result_id = try self.arrayType(total_len, elem_ty_id);1562 const result_id = try self.arrayType(total_len, elem_ty_id);
1565 switch (self.spv.target.os.tag) {1563 switch (self.spv.target.os.tag) {
1566 .vulkan, .opengl => {1564 .vulkan, .opengl => {
1567 try self.spv.decorate(result_id, .{ .ArrayStride = .{1565 try self.spv.decorate(result_id, .{ .array_stride = .{
1568 .array_stride = @intCast(elem_ty.abiSize(zcu)),1566 .array_stride = @intCast(elem_ty.abiSize(zcu)),
1569 } });1567 } });
1570 },1568 },
...@@ -1604,7 +1602,7 @@ const NavGen = struct {...@@ -1604,7 +1602,7 @@ const NavGen = struct {
1604 assert(!fn_info.is_var_args);1602 assert(!fn_info.is_var_args);
16051603
1606 // Note: Logic is different from functionType().1604 // Note: Logic is different from functionType().
1607 const param_ty_ids = try self.gpa.alloc(IdRef, fn_info.param_types.len);1605 const param_ty_ids = try self.gpa.alloc(Id, fn_info.param_types.len);
1608 defer self.gpa.free(param_ty_ids);1606 defer self.gpa.free(param_ty_ids);
1609 var param_index: usize = 0;1607 var param_index: usize = 0;
1610 for (fn_info.param_types.get(ip)) |param_ty_index| {1608 for (fn_info.param_types.get(ip)) |param_ty_index| {
...@@ -1655,7 +1653,7 @@ const NavGen = struct {...@@ -1655,7 +1653,7 @@ const NavGen = struct {
1655 .@"struct" => {1653 .@"struct" => {
1656 const struct_type = switch (ip.indexToKey(ty.toIntern())) {1654 const struct_type = switch (ip.indexToKey(ty.toIntern())) {
1657 .tuple_type => |tuple| {1655 .tuple_type => |tuple| {
1658 const member_types = try self.gpa.alloc(IdRef, tuple.values.len);1656 const member_types = try self.gpa.alloc(Id, tuple.values.len);
1659 defer self.gpa.free(member_types);1657 defer self.gpa.free(member_types);
16601658
1661 var member_index: usize = 0;1659 var member_index: usize = 0;
...@@ -1683,7 +1681,7 @@ const NavGen = struct {...@@ -1683,7 +1681,7 @@ const NavGen = struct {
1683 return try self.resolveType(Type.fromInterned(struct_type.backingIntTypeUnordered(ip)), .direct);1681 return try self.resolveType(Type.fromInterned(struct_type.backingIntTypeUnordered(ip)), .direct);
1684 }1682 }
16851683
1686 var member_types = std.ArrayList(IdRef).init(self.gpa);1684 var member_types = std.ArrayList(Id).init(self.gpa);
1687 defer member_types.deinit();1685 defer member_types.deinit();
16881686
1689 var member_names = std.ArrayList([]const u8).init(self.gpa);1687 var member_names = std.ArrayList([]const u8).init(self.gpa);
...@@ -1701,7 +1699,7 @@ const NavGen = struct {...@@ -1701,7 +1699,7 @@ const NavGen = struct {
17011699
1702 switch (self.spv.target.os.tag) {1700 switch (self.spv.target.os.tag) {
1703 .vulkan, .opengl => {1701 .vulkan, .opengl => {
1704 try self.spv.decorateMember(result_id, index, .{ .Offset = .{1702 try self.spv.decorateMember(result_id, index, .{ .offset = .{
1705 .byte_offset = @intCast(ty.structFieldOffset(field_index, zcu)),1703 .byte_offset = @intCast(ty.structFieldOffset(field_index, zcu)),
1706 } });1704 } });
1707 },1705 },
...@@ -1765,7 +1763,7 @@ const NavGen = struct {...@@ -1765,7 +1763,7 @@ const NavGen = struct {
17651763
1766 const payload_ty_id = try self.resolveType(payload_ty, .indirect);1764 const payload_ty_id = try self.resolveType(payload_ty, .indirect);
17671765
1768 var member_types: [2]IdRef = undefined;1766 var member_types: [2]Id = undefined;
1769 var member_names: [2][]const u8 = undefined;1767 var member_names: [2][]const u8 = undefined;
1770 if (eu_layout.error_first) {1768 if (eu_layout.error_first) {
1771 // Put the error first1769 // Put the error first
...@@ -1809,30 +1807,30 @@ const NavGen = struct {...@@ -1809,30 +1807,30 @@ const NavGen = struct {
18091807
1810 fn spvStorageClass(self: *NavGen, as: std.builtin.AddressSpace) StorageClass {1808 fn spvStorageClass(self: *NavGen, as: std.builtin.AddressSpace) StorageClass {
1811 return switch (as) {1809 return switch (as) {
1812 .generic => if (self.spv.hasFeature(.generic_pointer)) .Generic else .Function,1810 .generic => if (self.spv.hasFeature(.generic_pointer)) .generic else .function,
1813 .global => switch (self.spv.target.os.tag) {1811 .global => switch (self.spv.target.os.tag) {
1814 .opencl, .amdhsa => .CrossWorkgroup,1812 .opencl, .amdhsa => .cross_workgroup,
1815 else => .StorageBuffer,1813 else => .storage_buffer,
1816 },1814 },
1817 .push_constant => {1815 .push_constant => {
1818 return .PushConstant;1816 return .push_constant;
1819 },1817 },
1820 .output => {1818 .output => {
1821 return .Output;1819 return .output;
1822 },1820 },
1823 .uniform => {1821 .uniform => {
1824 return .Uniform;1822 return .uniform;
1825 },1823 },
1826 .storage_buffer => {1824 .storage_buffer => {
1827 return .StorageBuffer;1825 return .storage_buffer;
1828 },1826 },
1829 .physical_storage_buffer => {1827 .physical_storage_buffer => {
1830 return .PhysicalStorageBuffer;1828 return .physical_storage_buffer;
1831 },1829 },
1832 .constant => .UniformConstant,1830 .constant => .uniform_constant,
1833 .shared => .Workgroup,1831 .shared => .workgroup,
1834 .local => .Function,1832 .local => .function,
1835 .input => .Input,1833 .input => .input,
1836 .gs,1834 .gs,
1837 .fs,1835 .fs,
1838 .ss,1836 .ss,
...@@ -1980,22 +1978,22 @@ const NavGen = struct {...@@ -1980,22 +1978,22 @@ const NavGen = struct {
1980 value: Temporary.Value,1978 value: Temporary.Value,
19811979
1982 const Value = union(enum) {1980 const Value = union(enum) {
1983 singleton: IdResult,1981 singleton: Id,
1984 exploded_vector: IdRange,1982 exploded_vector: IdRange,
1985 };1983 };
19861984
1987 fn init(ty: Type, singleton: IdResult) Temporary {1985 fn init(ty: Type, singleton: Id) Temporary {
1988 return .{ .ty = ty, .value = .{ .singleton = singleton } };1986 return .{ .ty = ty, .value = .{ .singleton = singleton } };
1989 }1987 }
19901988
1991 fn materialize(self: Temporary, ng: *NavGen) !IdResult {1989 fn materialize(self: Temporary, ng: *NavGen) !Id {
1992 const zcu = ng.pt.zcu;1990 const zcu = ng.pt.zcu;
1993 switch (self.value) {1991 switch (self.value) {
1994 .singleton => |id| return id,1992 .singleton => |id| return id,
1995 .exploded_vector => |range| {1993 .exploded_vector => |range| {
1996 assert(self.ty.isVector(zcu));1994 assert(self.ty.isVector(zcu));
1997 assert(self.ty.vectorLen(zcu) == range.len);1995 assert(self.ty.vectorLen(zcu) == range.len);
1998 const constituents = try ng.gpa.alloc(IdRef, range.len);1996 const constituents = try ng.gpa.alloc(Id, range.len);
1999 defer ng.gpa.free(constituents);1997 defer ng.gpa.free(constituents);
2000 for (constituents, 0..range.len) |*id, i| {1998 for (constituents, 0..range.len) |*id, i| {
2001 id.* = range.at(i);1999 id.* = range.at(i);
...@@ -2170,16 +2168,16 @@ const NavGen = struct {...@@ -2170,16 +2168,16 @@ const NavGen = struct {
2170 /// on the operation and input value.2168 /// on the operation and input value.
2171 const Value = union(enum) {2169 const Value = union(enum) {
2172 /// A single scalar value that is used by a scalar operation.2170 /// A single scalar value that is used by a scalar operation.
2173 scalar: IdResult,2171 scalar: Id,
2174 /// A single scalar that is broadcasted in an unrolled operation.2172 /// A single scalar that is broadcasted in an unrolled operation.
2175 scalar_broadcast: IdResult,2173 scalar_broadcast: Id,
2176 /// A vector represented by a consecutive list of IDs that is used in an unrolled operation.2174 /// A vector represented by a consecutive list of IDs that is used in an unrolled operation.
2177 vector_exploded: IdRange,2175 vector_exploded: IdRange,
2178 };2176 };
21792177
2180 /// Query the value at a particular index of the operation. Note that2178 /// Query the value at a particular index of the operation. Note that
2181 /// the index is *not* the component/lane, but the index of the *operation*.2179 /// the index is *not* the component/lane, but the index of the *operation*.
2182 fn at(self: PreparedOperand, i: usize) IdResult {2180 fn at(self: PreparedOperand, i: usize) Id {
2183 switch (self.value) {2181 switch (self.value) {
2184 .scalar => |id| {2182 .scalar => |id| {
2185 assert(i == 0);2183 assert(i == 0);
...@@ -2253,9 +2251,9 @@ const NavGen = struct {...@@ -2253,9 +2251,9 @@ const NavGen = struct {
22532251
2254 for (0..ops) |i| {2252 for (0..ops) |i| {
2255 try self.func.body.emitRaw(self.spv.gpa, opcode, 3);2253 try self.func.body.emitRaw(self.spv.gpa, opcode, 3);
2256 self.func.body.writeOperand(spec.IdResultType, op_result_ty_id);2254 self.func.body.writeOperand(spec.Id, op_result_ty_id);
2257 self.func.body.writeOperand(IdResult, results.at(i));2255 self.func.body.writeOperand(Id, results.at(i));
2258 self.func.body.writeOperand(IdResult, op_src.at(i));2256 self.func.body.writeOperand(Id, op_src.at(i));
2259 }2257 }
22602258
2261 return v.finalize(result_ty, results);2259 return v.finalize(result_ty, results);
...@@ -2388,10 +2386,10 @@ const NavGen = struct {...@@ -2388,10 +2386,10 @@ const NavGen = struct {
23882386
2389 for (0..ops) |i| {2387 for (0..ops) |i| {
2390 try self.func.body.emitRaw(self.spv.gpa, opcode, 4);2388 try self.func.body.emitRaw(self.spv.gpa, opcode, 4);
2391 self.func.body.writeOperand(spec.IdResultType, op_result_ty_id);2389 self.func.body.writeOperand(spec.Id, op_result_ty_id);
2392 self.func.body.writeOperand(IdResult, results.at(i));2390 self.func.body.writeOperand(Id, results.at(i));
2393 self.func.body.writeOperand(IdResult, op_lhs.at(i));2391 self.func.body.writeOperand(Id, op_lhs.at(i));
2394 self.func.body.writeOperand(IdResult, op_rhs.at(i));2392 self.func.body.writeOperand(Id, op_rhs.at(i));
2395 }2393 }
23962394
2397 return v.finalize(result_ty, results);2395 return v.finalize(result_ty, results);
...@@ -2442,9 +2440,9 @@ const NavGen = struct {...@@ -2442,9 +2440,9 @@ const NavGen = struct {
2442 }) |opcode| {2440 }) |opcode| {
2443 for (0..ops) |i| {2441 for (0..ops) |i| {
2444 try self.func.body.emitRaw(self.spv.gpa, opcode, 3);2442 try self.func.body.emitRaw(self.spv.gpa, opcode, 3);
2445 self.func.body.writeOperand(spec.IdResultType, op_result_ty_id);2443 self.func.body.writeOperand(spec.Id, op_result_ty_id);
2446 self.func.body.writeOperand(IdResult, results.at(i));2444 self.func.body.writeOperand(Id, results.at(i));
2447 self.func.body.writeOperand(IdResult, op_operand.at(i));2445 self.func.body.writeOperand(Id, op_operand.at(i));
2448 }2446 }
2449 } else {2447 } else {
2450 const set = try self.importExtendedSet();2448 const set = try self.importExtendedSet();
...@@ -2583,10 +2581,10 @@ const NavGen = struct {...@@ -2583,10 +2581,10 @@ const NavGen = struct {
2583 }) |opcode| {2581 }) |opcode| {
2584 for (0..ops) |i| {2582 for (0..ops) |i| {
2585 try self.func.body.emitRaw(self.spv.gpa, opcode, 4);2583 try self.func.body.emitRaw(self.spv.gpa, opcode, 4);
2586 self.func.body.writeOperand(spec.IdResultType, op_result_ty_id);2584 self.func.body.writeOperand(spec.Id, op_result_ty_id);
2587 self.func.body.writeOperand(IdResult, results.at(i));2585 self.func.body.writeOperand(Id, results.at(i));
2588 self.func.body.writeOperand(IdResult, op_lhs.at(i));2586 self.func.body.writeOperand(Id, op_lhs.at(i));
2589 self.func.body.writeOperand(IdResult, op_rhs.at(i));2587 self.func.body.writeOperand(Id, op_rhs.at(i));
2590 }2588 }
2591 } else {2589 } else {
2592 const set = try self.importExtendedSet();2590 const set = try self.importExtendedSet();
...@@ -2702,10 +2700,10 @@ const NavGen = struct {...@@ -2702,10 +2700,10 @@ const NavGen = struct {
2702 const op_result = self.spv.allocId();2700 const op_result = self.spv.allocId();
27032701
2704 try self.func.body.emitRaw(self.spv.gpa, opcode, 4);2702 try self.func.body.emitRaw(self.spv.gpa, opcode, 4);
2705 self.func.body.writeOperand(spec.IdResultType, op_result_ty_id);2703 self.func.body.writeOperand(spec.Id, op_result_ty_id);
2706 self.func.body.writeOperand(IdResult, op_result);2704 self.func.body.writeOperand(Id, op_result);
2707 self.func.body.writeOperand(IdResult, lhs_op.at(i));2705 self.func.body.writeOperand(Id, lhs_op.at(i));
2708 self.func.body.writeOperand(IdResult, rhs_op.at(i));2706 self.func.body.writeOperand(Id, rhs_op.at(i));
27092707
2710 // The above operation returns a struct. We might want to expand2708 // The above operation returns a struct. We might want to expand
2711 // Temporary to deal with the fact that these are structs eventually,2709 // Temporary to deal with the fact that these are structs eventually,
...@@ -2804,8 +2802,8 @@ const NavGen = struct {...@@ -2804,8 +2802,8 @@ const NavGen = struct {
28042802
2805 const buffer_struct_ty_id = self.spv.allocId();2803 const buffer_struct_ty_id = self.spv.allocId();
2806 try self.spv.structType(buffer_struct_ty_id, &.{anyerror_ty_id}, &.{"error_out"});2804 try self.spv.structType(buffer_struct_ty_id, &.{anyerror_ty_id}, &.{"error_out"});
2807 try self.spv.decorate(buffer_struct_ty_id, .Block);2805 try self.spv.decorate(buffer_struct_ty_id, .block);
2808 try self.spv.decorateMember(buffer_struct_ty_id, 0, .{ .Offset = .{ .byte_offset = 0 } });2806 try self.spv.decorateMember(buffer_struct_ty_id, 0, .{ .offset = .{ .byte_offset = 0 } });
28092807
2810 const ptr_buffer_struct_ty_id = self.spv.allocId();2808 const ptr_buffer_struct_ty_id = self.spv.allocId();
2811 try self.spv.sections.types_globals_constants.emit(self.spv.gpa, .OpTypePointer, .{2809 try self.spv.sections.types_globals_constants.emit(self.spv.gpa, .OpTypePointer, .{
...@@ -2820,15 +2818,15 @@ const NavGen = struct {...@@ -2820,15 +2818,15 @@ const NavGen = struct {
2820 .id_result = buffer_struct_id,2818 .id_result = buffer_struct_id,
2821 .storage_class = self.spvStorageClass(.global),2819 .storage_class = self.spvStorageClass(.global),
2822 });2820 });
2823 try self.spv.decorate(buffer_struct_id, .{ .DescriptorSet = .{ .descriptor_set = 0 } });2821 try self.spv.decorate(buffer_struct_id, .{ .descriptor_set = .{ .descriptor_set = 0 } });
2824 try self.spv.decorate(buffer_struct_id, .{ .Binding = .{ .binding_point = 0 } });2822 try self.spv.decorate(buffer_struct_id, .{ .binding = .{ .binding_point = 0 } });
28252823
2826 self.object.error_buffer = spv_err_decl_index;2824 self.object.error_buffer = spv_err_decl_index;
2827 }2825 }
28282826
2829 try self.spv.sections.execution_modes.emit(self.spv.gpa, .OpExecutionMode, .{2827 try self.spv.sections.execution_modes.emit(self.spv.gpa, .OpExecutionMode, .{
2830 .entry_point = kernel_id,2828 .entry_point = kernel_id,
2831 .mode = .{ .LocalSize = .{2829 .mode = .{ .local_size = .{
2832 .x_size = 1,2830 .x_size = 1,
2833 .y_size = 1,2831 .y_size = 1,
2834 .z_size = 1,2832 .z_size = 1,
...@@ -2873,7 +2871,7 @@ const NavGen = struct {...@@ -2873,7 +2871,7 @@ const NavGen = struct {
2873 .pointer = p_error_id,2871 .pointer = p_error_id,
2874 .object = error_id,2872 .object = error_id,
2875 .memory_access = .{2873 .memory_access = .{
2876 .Aligned = .{ .literal_integer = @intCast(Type.abiAlignment(.anyerror, zcu).toByteUnits().?) },2874 .aligned = .{ .literal_integer = @intCast(Type.abiAlignment(.anyerror, zcu).toByteUnits().?) },
2877 },2875 },
2878 });2876 });
2879 try section.emit(self.spv.gpa, .OpReturn, {});2877 try section.emit(self.spv.gpa, .OpReturn, {});
...@@ -2885,8 +2883,8 @@ const NavGen = struct {...@@ -2885,8 +2883,8 @@ const NavGen = struct {
2885 defer self.gpa.free(test_name);2883 defer self.gpa.free(test_name);
28862884
2887 const execution_mode: spec.ExecutionModel = switch (target.os.tag) {2885 const execution_mode: spec.ExecutionModel = switch (target.os.tag) {
2888 .vulkan, .opengl => .GLCompute,2886 .vulkan, .opengl => .gl_compute,
2889 .opencl, .amdhsa => .Kernel,2887 .opencl, .amdhsa => .kernel,
2890 else => unreachable,2888 else => unreachable,
2891 };2889 };
28922890
...@@ -2983,7 +2981,7 @@ const NavGen = struct {...@@ -2983,7 +2981,7 @@ const NavGen = struct {
2983 assert(maybe_init_val == null); // TODO2981 assert(maybe_init_val == null); // TODO
29842982
2985 const storage_class = self.spvStorageClass(nav.getAddrspace());2983 const storage_class = self.spvStorageClass(nav.getAddrspace());
2986 assert(storage_class != .Generic); // These should be instance globals2984 assert(storage_class != .generic); // These should be instance globals
29872985
2988 const ptr_ty_id = try self.ptrType(ty, storage_class, .indirect);2986 const ptr_ty_id = try self.ptrType(ty, storage_class, .indirect);
29892987
...@@ -2993,38 +2991,8 @@ const NavGen = struct {...@@ -2993,38 +2991,8 @@ const NavGen = struct {
2993 .storage_class = storage_class,2991 .storage_class = storage_class,
2994 });2992 });
29952993
2996 if (nav.fqn.eqlSlice("position", ip)) {2994 if (std.meta.stringToEnum(spec.BuiltIn, nav.fqn.toSlice(ip))) |builtin| {
2997 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .Position } });2995 try self.spv.decorate(result_id, .{ .built_in = .{ .built_in = builtin } });
2998 } else if (nav.fqn.eqlSlice("point_size", ip)) {
2999 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .PointSize } });
3000 } else if (nav.fqn.eqlSlice("invocation_id", ip)) {
3001 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .InvocationId } });
3002 } else if (nav.fqn.eqlSlice("frag_coord", ip)) {
3003 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .FragCoord } });
3004 } else if (nav.fqn.eqlSlice("point_coord", ip)) {
3005 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .PointCoord } });
3006 } else if (nav.fqn.eqlSlice("front_facing", ip)) {
3007 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .FrontFacing } });
3008 } else if (nav.fqn.eqlSlice("sample_mask", ip)) {
3009 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .SampleMask } });
3010 } else if (nav.fqn.eqlSlice("frag_depth", ip)) {
3011 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .FragDepth } });
3012 } else if (nav.fqn.eqlSlice("num_workgroups", ip)) {
3013 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .NumWorkgroups } });
3014 } else if (nav.fqn.eqlSlice("workgroup_size", ip)) {
3015 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .WorkgroupSize } });
3016 } else if (nav.fqn.eqlSlice("workgroup_id", ip)) {
3017 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .WorkgroupId } });
3018 } else if (nav.fqn.eqlSlice("local_invocation_id", ip)) {
3019 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .LocalInvocationId } });
3020 } else if (nav.fqn.eqlSlice("global_invocation_id", ip)) {
3021 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .GlobalInvocationId } });
3022 } else if (nav.fqn.eqlSlice("local_invocation_index", ip)) {
3023 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .LocalInvocationIndex } });
3024 } else if (nav.fqn.eqlSlice("vertex_index", ip)) {
3025 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .VertexIndex } });
3026 } else if (nav.fqn.eqlSlice("instance_index", ip)) {
3027 try self.spv.decorate(result_id, .{ .BuiltIn = .{ .built_in = .InstanceIndex } });
3028 }2996 }
30292997
3030 try self.spv.debugName(result_id, nav.fqn.toSlice(ip));2998 try self.spv.debugName(result_id, nav.fqn.toSlice(ip));
...@@ -3040,7 +3008,7 @@ const NavGen = struct {...@@ -3040,7 +3008,7 @@ const NavGen = struct {
30403008
3041 try self.spv.declareDeclDeps(spv_decl_index, &.{});3009 try self.spv.declareDeclDeps(spv_decl_index, &.{});
30423010
3043 const ptr_ty_id = try self.ptrType(ty, .Function, .indirect);3011 const ptr_ty_id = try self.ptrType(ty, .function, .indirect);
30443012
3045 if (maybe_init_val) |init_val| {3013 if (maybe_init_val) |init_val| {
3046 // TODO: Combine with resolveAnonDecl?3014 // TODO: Combine with resolveAnonDecl?
...@@ -3109,7 +3077,7 @@ const NavGen = struct {...@@ -3109,7 +3077,7 @@ const NavGen = struct {
31093077
3110 /// Convert representation from indirect (in memory) to direct (in 'register')3078 /// Convert representation from indirect (in memory) to direct (in 'register')
3111 /// This converts the argument type from resolveType(ty, .indirect) to resolveType(ty, .direct).3079 /// This converts the argument type from resolveType(ty, .indirect) to resolveType(ty, .direct).
3112 fn convertToDirect(self: *NavGen, ty: Type, operand_id: IdRef) !IdRef {3080 fn convertToDirect(self: *NavGen, ty: Type, operand_id: Id) !Id {
3113 const pt = self.pt;3081 const pt = self.pt;
3114 const zcu = pt.zcu;3082 const zcu = pt.zcu;
3115 switch (ty.scalarType(zcu).zigTypeTag(zcu)) {3083 switch (ty.scalarType(zcu).zigTypeTag(zcu)) {
...@@ -3136,7 +3104,7 @@ const NavGen = struct {...@@ -3136,7 +3104,7 @@ const NavGen = struct {
31363104
3137 /// Convert representation from direct (in 'register) to direct (in memory)3105 /// Convert representation from direct (in 'register) to direct (in memory)
3138 /// This converts the argument type from resolveType(ty, .direct) to resolveType(ty, .indirect).3106 /// This converts the argument type from resolveType(ty, .direct) to resolveType(ty, .indirect).
3139 fn convertToIndirect(self: *NavGen, ty: Type, operand_id: IdRef) !IdRef {3107 fn convertToIndirect(self: *NavGen, ty: Type, operand_id: Id) !Id {
3140 const zcu = self.pt.zcu;3108 const zcu = self.pt.zcu;
3141 switch (ty.scalarType(zcu).zigTypeTag(zcu)) {3109 switch (ty.scalarType(zcu).zigTypeTag(zcu)) {
3142 .bool => {3110 .bool => {
...@@ -3147,7 +3115,7 @@ const NavGen = struct {...@@ -3147,7 +3115,7 @@ const NavGen = struct {
3147 }3115 }
3148 }3116 }
31493117
3150 fn extractField(self: *NavGen, result_ty: Type, object: IdRef, field: u32) !IdRef {3118 fn extractField(self: *NavGen, result_ty: Type, object: Id, field: u32) !Id {
3151 const result_ty_id = try self.resolveType(result_ty, .indirect);3119 const result_ty_id = try self.resolveType(result_ty, .indirect);
3152 const result_id = self.spv.allocId();3120 const result_id = self.spv.allocId();
3153 const indexes = [_]u32{field};3121 const indexes = [_]u32{field};
...@@ -3161,7 +3129,7 @@ const NavGen = struct {...@@ -3161,7 +3129,7 @@ const NavGen = struct {
3161 return try self.convertToDirect(result_ty, result_id);3129 return try self.convertToDirect(result_ty, result_id);
3162 }3130 }
31633131
3164 fn extractVectorComponent(self: *NavGen, result_ty: Type, vector_id: IdRef, field: u32) !IdRef {3132 fn extractVectorComponent(self: *NavGen, result_ty: Type, vector_id: Id, field: u32) !Id {
3165 const result_ty_id = try self.resolveType(result_ty, .direct);3133 const result_ty_id = try self.resolveType(result_ty, .direct);
3166 const result_id = self.spv.allocId();3134 const result_id = self.spv.allocId();
3167 const indexes = [_]u32{field};3135 const indexes = [_]u32{field};
...@@ -3179,14 +3147,14 @@ const NavGen = struct {...@@ -3179,14 +3147,14 @@ const NavGen = struct {
3179 is_volatile: bool = false,3147 is_volatile: bool = false,
3180 };3148 };
31813149
3182 fn load(self: *NavGen, value_ty: Type, ptr_id: IdRef, options: MemoryOptions) !IdRef {3150 fn load(self: *NavGen, value_ty: Type, ptr_id: Id, options: MemoryOptions) !Id {
3183 const zcu = self.pt.zcu;3151 const zcu = self.pt.zcu;
3184 const alignment: u32 = @intCast(value_ty.abiAlignment(zcu).toByteUnits().?);3152 const alignment: u32 = @intCast(value_ty.abiAlignment(zcu).toByteUnits().?);
3185 const indirect_value_ty_id = try self.resolveType(value_ty, .indirect);3153 const indirect_value_ty_id = try self.resolveType(value_ty, .indirect);
3186 const result_id = self.spv.allocId();3154 const result_id = self.spv.allocId();
3187 const access = spec.MemoryAccess.Extended{3155 const access: spec.MemoryAccess.Extended = .{
3188 .Volatile = options.is_volatile,3156 .@"volatile" = options.is_volatile,
3189 .Aligned = .{ .literal_integer = alignment },3157 .aligned = .{ .literal_integer = alignment },
3190 };3158 };
3191 try self.func.body.emit(self.spv.gpa, .OpLoad, .{3159 try self.func.body.emit(self.spv.gpa, .OpLoad, .{
3192 .id_result_type = indirect_value_ty_id,3160 .id_result_type = indirect_value_ty_id,
...@@ -3197,11 +3165,9 @@ const NavGen = struct {...@@ -3197,11 +3165,9 @@ const NavGen = struct {
3197 return try self.convertToDirect(value_ty, result_id);3165 return try self.convertToDirect(value_ty, result_id);
3198 }3166 }
31993167
3200 fn store(self: *NavGen, value_ty: Type, ptr_id: IdRef, value_id: IdRef, options: MemoryOptions) !void {3168 fn store(self: *NavGen, value_ty: Type, ptr_id: Id, value_id: Id, options: MemoryOptions) !void {
3201 const indirect_value_id = try self.convertToIndirect(value_ty, value_id);3169 const indirect_value_id = try self.convertToIndirect(value_ty, value_id);
3202 const access = spec.MemoryAccess.Extended{3170 const access: spec.MemoryAccess.Extended = .{ .@"volatile" = options.is_volatile };
3203 .Volatile = options.is_volatile,
3204 };
3205 try self.func.body.emit(self.spv.gpa, .OpStore, .{3171 try self.func.body.emit(self.spv.gpa, .OpStore, .{
3206 .pointer = ptr_id,3172 .pointer = ptr_id,
3207 .object = indirect_value_id,3173 .object = indirect_value_id,
...@@ -3222,7 +3188,7 @@ const NavGen = struct {...@@ -3222,7 +3188,7 @@ const NavGen = struct {
3222 return;3188 return;
32233189
3224 const air_tags = self.air.instructions.items(.tag);3190 const air_tags = self.air.instructions.items(.tag);
3225 const maybe_result_id: ?IdRef = switch (air_tags[@intFromEnum(inst)]) {3191 const maybe_result_id: ?Id = switch (air_tags[@intFromEnum(inst)]) {
3226 // zig fmt: off3192 // zig fmt: off
3227 .add, .add_wrap, .add_optimized => try self.airArithOp(inst, .f_add, .i_add, .i_add),3193 .add, .add_wrap, .add_optimized => try self.airArithOp(inst, .f_add, .i_add, .i_add),
3228 .sub, .sub_wrap, .sub_optimized => try self.airArithOp(inst, .f_sub, .i_sub, .i_sub),3194 .sub, .sub_wrap, .sub_optimized => try self.airArithOp(inst, .f_sub, .i_sub, .i_sub),
...@@ -3390,7 +3356,7 @@ const NavGen = struct {...@@ -3390,7 +3356,7 @@ const NavGen = struct {
3390 try self.inst_results.putNoClobber(self.gpa, inst, result_id);3356 try self.inst_results.putNoClobber(self.gpa, inst, result_id);
3391 }3357 }
33923358
3393 fn airBinOpSimple(self: *NavGen, inst: Air.Inst.Index, op: BinaryOp) !?IdRef {3359 fn airBinOpSimple(self: *NavGen, inst: Air.Inst.Index, op: BinaryOp) !?Id {
3394 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;3360 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
3395 const lhs = try self.temporary(bin_op.lhs);3361 const lhs = try self.temporary(bin_op.lhs);
3396 const rhs = try self.temporary(bin_op.rhs);3362 const rhs = try self.temporary(bin_op.rhs);
...@@ -3399,7 +3365,7 @@ const NavGen = struct {...@@ -3399,7 +3365,7 @@ const NavGen = struct {
3399 return try result.materialize(self);3365 return try result.materialize(self);
3400 }3366 }
34013367
3402 fn airShift(self: *NavGen, inst: Air.Inst.Index, unsigned: BinaryOp, signed: BinaryOp) !?IdRef {3368 fn airShift(self: *NavGen, inst: Air.Inst.Index, unsigned: BinaryOp, signed: BinaryOp) !?Id {
3403 const zcu = self.pt.zcu;3369 const zcu = self.pt.zcu;
3404 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;3370 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
34053371
...@@ -3438,7 +3404,7 @@ const NavGen = struct {...@@ -3438,7 +3404,7 @@ const NavGen = struct {
34383404
3439 const MinMax = enum { min, max };3405 const MinMax = enum { min, max };
34403406
3441 fn airMinMax(self: *NavGen, inst: Air.Inst.Index, op: MinMax) !?IdRef {3407 fn airMinMax(self: *NavGen, inst: Air.Inst.Index, op: MinMax) !?Id {
3442 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;3408 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
34433409
3444 const lhs = try self.temporary(bin_op.lhs);3410 const lhs = try self.temporary(bin_op.lhs);
...@@ -3503,7 +3469,7 @@ const NavGen = struct {...@@ -3503,7 +3469,7 @@ const NavGen = struct {
3503 }3469 }
3504 }3470 }
35053471
3506 fn airDivFloor(self: *NavGen, inst: Air.Inst.Index) !?IdRef {3472 fn airDivFloor(self: *NavGen, inst: Air.Inst.Index) !?Id {
3507 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;3473 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
35083474
3509 const lhs = try self.temporary(bin_op.lhs);3475 const lhs = try self.temporary(bin_op.lhs);
...@@ -3560,7 +3526,7 @@ const NavGen = struct {...@@ -3560,7 +3526,7 @@ const NavGen = struct {
3560 }3526 }
3561 }3527 }
35623528
3563 fn airDivTrunc(self: *NavGen, inst: Air.Inst.Index) !?IdRef {3529 fn airDivTrunc(self: *NavGen, inst: Air.Inst.Index) !?Id {
3564 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;3530 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
35653531
3566 const lhs = try self.temporary(bin_op.lhs);3532 const lhs = try self.temporary(bin_op.lhs);
...@@ -3588,7 +3554,7 @@ const NavGen = struct {...@@ -3588,7 +3554,7 @@ const NavGen = struct {
3588 }3554 }
3589 }3555 }
35903556
3591 fn airUnOpSimple(self: *NavGen, inst: Air.Inst.Index, op: UnaryOp) !?IdRef {3557 fn airUnOpSimple(self: *NavGen, inst: Air.Inst.Index, op: UnaryOp) !?Id {
3592 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;3558 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;
3593 const operand = try self.temporary(un_op);3559 const operand = try self.temporary(un_op);
3594 const result = try self.buildUnary(op, operand);3560 const result = try self.buildUnary(op, operand);
...@@ -3601,7 +3567,7 @@ const NavGen = struct {...@@ -3601,7 +3567,7 @@ const NavGen = struct {
3601 comptime fop: BinaryOp,3567 comptime fop: BinaryOp,
3602 comptime sop: BinaryOp,3568 comptime sop: BinaryOp,
3603 comptime uop: BinaryOp,3569 comptime uop: BinaryOp,
3604 ) !?IdRef {3570 ) !?Id {
3605 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;3571 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
36063572
3607 const lhs = try self.temporary(bin_op.lhs);3573 const lhs = try self.temporary(bin_op.lhs);
...@@ -3622,7 +3588,7 @@ const NavGen = struct {...@@ -3622,7 +3588,7 @@ const NavGen = struct {
3622 return try result.materialize(self);3588 return try result.materialize(self);
3623 }3589 }
36243590
3625 fn airAbs(self: *NavGen, inst: Air.Inst.Index) !?IdRef {3591 fn airAbs(self: *NavGen, inst: Air.Inst.Index) !?Id {
3626 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;3592 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
3627 const operand = try self.temporary(ty_op.operand);3593 const operand = try self.temporary(ty_op.operand);
3628 // Note: operand_ty may be signed, while ty is always unsigned!3594 // Note: operand_ty may be signed, while ty is always unsigned!
...@@ -3662,7 +3628,7 @@ const NavGen = struct {...@@ -3662,7 +3628,7 @@ const NavGen = struct {
3662 comptime add: BinaryOp,3628 comptime add: BinaryOp,
3663 comptime ucmp: CmpPredicate,3629 comptime ucmp: CmpPredicate,
3664 comptime scmp: CmpPredicate,3630 comptime scmp: CmpPredicate,
3665 ) !?IdRef {3631 ) !?Id {
3666 _ = scmp;3632 _ = scmp;
3667 // Note: OpIAddCarry and OpISubBorrow are not really useful here: For unsigned numbers,3633 // Note: OpIAddCarry and OpISubBorrow are not really useful here: For unsigned numbers,
3668 // there is in both cases only one extra operation required. For signed operations,3634 // there is in both cases only one extra operation required. For signed operations,
...@@ -3725,7 +3691,7 @@ const NavGen = struct {...@@ -3725,7 +3691,7 @@ const NavGen = struct {
3725 return try self.constructComposite(result_ty_id, &.{ try result.materialize(self), try ov.materialize(self) });3691 return try self.constructComposite(result_ty_id, &.{ try result.materialize(self), try ov.materialize(self) });
3726 }3692 }
37273693
3728 fn airMulOverflow(self: *NavGen, inst: Air.Inst.Index) !?IdRef {3694 fn airMulOverflow(self: *NavGen, inst: Air.Inst.Index) !?Id {
3729 const pt = self.pt;3695 const pt = self.pt;
37303696
3731 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;3697 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
...@@ -3897,7 +3863,7 @@ const NavGen = struct {...@@ -3897,7 +3863,7 @@ const NavGen = struct {
3897 return try self.constructComposite(result_ty_id, &.{ try result.materialize(self), try ov.materialize(self) });3863 return try self.constructComposite(result_ty_id, &.{ try result.materialize(self), try ov.materialize(self) });
3898 }3864 }
38993865
3900 fn airShlOverflow(self: *NavGen, inst: Air.Inst.Index) !?IdRef {3866 fn airShlOverflow(self: *NavGen, inst: Air.Inst.Index) !?Id {
3901 const zcu = self.pt.zcu;3867 const zcu = self.pt.zcu;
39023868
3903 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;3869 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
...@@ -3938,7 +3904,7 @@ const NavGen = struct {...@@ -3938,7 +3904,7 @@ const NavGen = struct {
3938 return try self.constructComposite(result_ty_id, &.{ try result.materialize(self), try ov.materialize(self) });3904 return try self.constructComposite(result_ty_id, &.{ try result.materialize(self), try ov.materialize(self) });
3939 }3905 }
39403906
3941 fn airMulAdd(self: *NavGen, inst: Air.Inst.Index) !?IdRef {3907 fn airMulAdd(self: *NavGen, inst: Air.Inst.Index) !?Id {
3942 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;3908 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
3943 const extra = self.air.extraData(Air.Bin, pl_op.payload).data;3909 const extra = self.air.extraData(Air.Bin, pl_op.payload).data;
39443910
...@@ -3954,7 +3920,7 @@ const NavGen = struct {...@@ -3954,7 +3920,7 @@ const NavGen = struct {
3954 return try result.materialize(self);3920 return try result.materialize(self);
3955 }3921 }
39563922
3957 fn airClzCtz(self: *NavGen, inst: Air.Inst.Index, op: UnaryOp) !?IdRef {3923 fn airClzCtz(self: *NavGen, inst: Air.Inst.Index, op: UnaryOp) !?Id {
3958 if (self.liveness.isUnused(inst)) return null;3924 if (self.liveness.isUnused(inst)) return null;
39593925
3960 const zcu = self.pt.zcu;3926 const zcu = self.pt.zcu;
...@@ -3979,7 +3945,7 @@ const NavGen = struct {...@@ -3979,7 +3945,7 @@ const NavGen = struct {
3979 return try result.materialize(self);3945 return try result.materialize(self);
3980 }3946 }
39813947
3982 fn airSelect(self: *NavGen, inst: Air.Inst.Index) !?IdRef {3948 fn airSelect(self: *NavGen, inst: Air.Inst.Index) !?Id {
3983 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;3949 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
3984 const extra = self.air.extraData(Air.Bin, pl_op.payload).data;3950 const extra = self.air.extraData(Air.Bin, pl_op.payload).data;
3985 const pred = try self.temporary(pl_op.operand);3951 const pred = try self.temporary(pl_op.operand);
...@@ -3990,7 +3956,7 @@ const NavGen = struct {...@@ -3990,7 +3956,7 @@ const NavGen = struct {
3990 return try result.materialize(self);3956 return try result.materialize(self);
3991 }3957 }
39923958
3993 fn airSplat(self: *NavGen, inst: Air.Inst.Index) !?IdRef {3959 fn airSplat(self: *NavGen, inst: Air.Inst.Index) !?Id {
3994 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;3960 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
39953961
3996 const operand_id = try self.resolve(ty_op.operand);3962 const operand_id = try self.resolve(ty_op.operand);
...@@ -3999,7 +3965,7 @@ const NavGen = struct {...@@ -3999,7 +3965,7 @@ const NavGen = struct {
3999 return try self.constructCompositeSplat(result_ty, operand_id);3965 return try self.constructCompositeSplat(result_ty, operand_id);
4000 }3966 }
40013967
4002 fn airReduce(self: *NavGen, inst: Air.Inst.Index) !?IdRef {3968 fn airReduce(self: *NavGen, inst: Air.Inst.Index) !?Id {
4003 const zcu = self.pt.zcu;3969 const zcu = self.pt.zcu;
4004 const reduce = self.air.instructions.items(.data)[@intFromEnum(inst)].reduce;3970 const reduce = self.air.instructions.items(.data)[@intFromEnum(inst)].reduce;
4005 const operand = try self.resolve(reduce.operand);3971 const operand = try self.resolve(reduce.operand);
...@@ -4062,16 +4028,16 @@ const NavGen = struct {...@@ -4062,16 +4028,16 @@ const NavGen = struct {
4062 result_id = self.spv.allocId();4028 result_id = self.spv.allocId();
40634029
4064 try self.func.body.emitRaw(self.spv.gpa, opcode, 4);4030 try self.func.body.emitRaw(self.spv.gpa, opcode, 4);
4065 self.func.body.writeOperand(spec.IdResultType, scalar_ty_id);4031 self.func.body.writeOperand(spec.Id, scalar_ty_id);
4066 self.func.body.writeOperand(spec.IdResult, result_id);4032 self.func.body.writeOperand(spec.Id, result_id);
4067 self.func.body.writeOperand(spec.IdResultType, lhs);4033 self.func.body.writeOperand(spec.Id, lhs);
4068 self.func.body.writeOperand(spec.IdResultType, rhs);4034 self.func.body.writeOperand(spec.Id, rhs);
4069 }4035 }
40704036
4071 return result_id;4037 return result_id;
4072 }4038 }
40734039
4074 fn airShuffleOne(ng: *NavGen, inst: Air.Inst.Index) !?IdRef {4040 fn airShuffleOne(ng: *NavGen, inst: Air.Inst.Index) !?Id {
4075 const pt = ng.pt;4041 const pt = ng.pt;
4076 const zcu = pt.zcu;4042 const zcu = pt.zcu;
4077 const gpa = zcu.gpa;4043 const gpa = zcu.gpa;
...@@ -4082,7 +4048,7 @@ const NavGen = struct {...@@ -4082,7 +4048,7 @@ const NavGen = struct {
4082 const elem_ty = result_ty.childType(zcu);4048 const elem_ty = result_ty.childType(zcu);
4083 const operand = try ng.resolve(unwrapped.operand);4049 const operand = try ng.resolve(unwrapped.operand);
40844050
4085 const constituents = try gpa.alloc(IdRef, mask.len);4051 const constituents = try gpa.alloc(Id, mask.len);
4086 defer gpa.free(constituents);4052 defer gpa.free(constituents);
40874053
4088 for (constituents, mask) |*id, mask_elem| {4054 for (constituents, mask) |*id, mask_elem| {
...@@ -4096,7 +4062,7 @@ const NavGen = struct {...@@ -4096,7 +4062,7 @@ const NavGen = struct {
4096 return try ng.constructComposite(result_ty_id, constituents);4062 return try ng.constructComposite(result_ty_id, constituents);
4097 }4063 }
40984064
4099 fn airShuffleTwo(ng: *NavGen, inst: Air.Inst.Index) !?IdRef {4065 fn airShuffleTwo(ng: *NavGen, inst: Air.Inst.Index) !?Id {
4100 const pt = ng.pt;4066 const pt = ng.pt;
4101 const zcu = pt.zcu;4067 const zcu = pt.zcu;
4102 const gpa = zcu.gpa;4068 const gpa = zcu.gpa;
...@@ -4109,7 +4075,7 @@ const NavGen = struct {...@@ -4109,7 +4075,7 @@ const NavGen = struct {
4109 const operand_a = try ng.resolve(unwrapped.operand_a);4075 const operand_a = try ng.resolve(unwrapped.operand_a);
4110 const operand_b = try ng.resolve(unwrapped.operand_b);4076 const operand_b = try ng.resolve(unwrapped.operand_b);
41114077
4112 const constituents = try gpa.alloc(IdRef, mask.len);4078 const constituents = try gpa.alloc(Id, mask.len);
4113 defer gpa.free(constituents);4079 defer gpa.free(constituents);
41144080
4115 for (constituents, mask) |*id, mask_elem| {4081 for (constituents, mask) |*id, mask_elem| {
...@@ -4124,8 +4090,8 @@ const NavGen = struct {...@@ -4124,8 +4090,8 @@ const NavGen = struct {
4124 return try ng.constructComposite(result_ty_id, constituents);4090 return try ng.constructComposite(result_ty_id, constituents);
4125 }4091 }
41264092
4127 fn indicesToIds(self: *NavGen, indices: []const u32) ![]IdRef {4093 fn indicesToIds(self: *NavGen, indices: []const u32) ![]Id {
4128 const ids = try self.gpa.alloc(IdRef, indices.len);4094 const ids = try self.gpa.alloc(Id, indices.len);
4129 errdefer self.gpa.free(ids);4095 errdefer self.gpa.free(ids);
4130 for (indices, ids) |index, *id| {4096 for (indices, ids) |index, *id| {
4131 id.* = try self.constInt(Type.u32, index);4097 id.* = try self.constInt(Type.u32, index);
...@@ -4136,10 +4102,10 @@ const NavGen = struct {...@@ -4136,10 +4102,10 @@ const NavGen = struct {
41364102
4137 fn accessChainId(4103 fn accessChainId(
4138 self: *NavGen,4104 self: *NavGen,
4139 result_ty_id: IdRef,4105 result_ty_id: Id,
4140 base: IdRef,4106 base: Id,
4141 indices: []const IdRef,4107 indices: []const Id,
4142 ) !IdRef {4108 ) !Id {
4143 const result_id = self.spv.allocId();4109 const result_id = self.spv.allocId();
4144 try self.func.body.emit(self.spv.gpa, .OpInBoundsAccessChain, .{4110 try self.func.body.emit(self.spv.gpa, .OpInBoundsAccessChain, .{
4145 .id_result_type = result_ty_id,4111 .id_result_type = result_ty_id,
...@@ -4156,10 +4122,10 @@ const NavGen = struct {...@@ -4156,10 +4122,10 @@ const NavGen = struct {
4156 /// is the latter and PtrAccessChain is the former.4122 /// is the latter and PtrAccessChain is the former.
4157 fn accessChain(4123 fn accessChain(
4158 self: *NavGen,4124 self: *NavGen,
4159 result_ty_id: IdRef,4125 result_ty_id: Id,
4160 base: IdRef,4126 base: Id,
4161 indices: []const u32,4127 indices: []const u32,
4162 ) !IdRef {4128 ) !Id {
4163 const ids = try self.indicesToIds(indices);4129 const ids = try self.indicesToIds(indices);
4164 defer self.gpa.free(ids);4130 defer self.gpa.free(ids);
4165 return try self.accessChainId(result_ty_id, base, ids);4131 return try self.accessChainId(result_ty_id, base, ids);
...@@ -4167,11 +4133,11 @@ const NavGen = struct {...@@ -4167,11 +4133,11 @@ const NavGen = struct {
41674133
4168 fn ptrAccessChain(4134 fn ptrAccessChain(
4169 self: *NavGen,4135 self: *NavGen,
4170 result_ty_id: IdRef,4136 result_ty_id: Id,
4171 base: IdRef,4137 base: Id,
4172 element: IdRef,4138 element: Id,
4173 indices: []const u32,4139 indices: []const u32,
4174 ) !IdRef {4140 ) !Id {
4175 const ids = try self.indicesToIds(indices);4141 const ids = try self.indicesToIds(indices);
4176 defer self.gpa.free(ids);4142 defer self.gpa.free(ids);
41774143
...@@ -4199,7 +4165,7 @@ const NavGen = struct {...@@ -4199,7 +4165,7 @@ const NavGen = struct {
4199 return result_id;4165 return result_id;
4200 }4166 }
42014167
4202 fn ptrAdd(self: *NavGen, result_ty: Type, ptr_ty: Type, ptr_id: IdRef, offset_id: IdRef) !IdRef {4168 fn ptrAdd(self: *NavGen, result_ty: Type, ptr_ty: Type, ptr_id: Id, offset_id: Id) !Id {
4203 const zcu = self.pt.zcu;4169 const zcu = self.pt.zcu;
4204 const result_ty_id = try self.resolveType(result_ty, .direct);4170 const result_ty_id = try self.resolveType(result_ty, .direct);
42054171
...@@ -4220,7 +4186,7 @@ const NavGen = struct {...@@ -4220,7 +4186,7 @@ const NavGen = struct {
4220 }4186 }
4221 }4187 }
42224188
4223 fn airPtrAdd(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4189 fn airPtrAdd(self: *NavGen, inst: Air.Inst.Index) !?Id {
4224 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;4190 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
4225 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;4191 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;
4226 const ptr_id = try self.resolve(bin_op.lhs);4192 const ptr_id = try self.resolve(bin_op.lhs);
...@@ -4231,7 +4197,7 @@ const NavGen = struct {...@@ -4231,7 +4197,7 @@ const NavGen = struct {
4231 return try self.ptrAdd(result_ty, ptr_ty, ptr_id, offset_id);4197 return try self.ptrAdd(result_ty, ptr_ty, ptr_id, offset_id);
4232 }4198 }
42334199
4234 fn airPtrSub(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4200 fn airPtrSub(self: *NavGen, inst: Air.Inst.Index) !?Id {
4235 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;4201 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
4236 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;4202 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;
4237 const ptr_id = try self.resolve(bin_op.lhs);4203 const ptr_id = try self.resolve(bin_op.lhs);
...@@ -4427,7 +4393,7 @@ const NavGen = struct {...@@ -4427,7 +4393,7 @@ const NavGen = struct {
4427 self: *NavGen,4393 self: *NavGen,
4428 inst: Air.Inst.Index,4394 inst: Air.Inst.Index,
4429 comptime op: std.math.CompareOperator,4395 comptime op: std.math.CompareOperator,
4430 ) !?IdRef {4396 ) !?Id {
4431 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;4397 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
4432 const lhs = try self.temporary(bin_op.lhs);4398 const lhs = try self.temporary(bin_op.lhs);
4433 const rhs = try self.temporary(bin_op.rhs);4399 const rhs = try self.temporary(bin_op.rhs);
...@@ -4436,7 +4402,7 @@ const NavGen = struct {...@@ -4436,7 +4402,7 @@ const NavGen = struct {
4436 return try result.materialize(self);4402 return try result.materialize(self);
4437 }4403 }
44384404
4439 fn airVectorCmp(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4405 fn airVectorCmp(self: *NavGen, inst: Air.Inst.Index) !?Id {
4440 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;4406 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
4441 const vec_cmp = self.air.extraData(Air.VectorCmp, ty_pl.payload).data;4407 const vec_cmp = self.air.extraData(Air.VectorCmp, ty_pl.payload).data;
4442 const lhs = try self.temporary(vec_cmp.lhs);4408 const lhs = try self.temporary(vec_cmp.lhs);
...@@ -4452,8 +4418,8 @@ const NavGen = struct {...@@ -4452,8 +4418,8 @@ const NavGen = struct {
4452 self: *NavGen,4418 self: *NavGen,
4453 dst_ty: Type,4419 dst_ty: Type,
4454 src_ty: Type,4420 src_ty: Type,
4455 src_id: IdRef,4421 src_id: Id,
4456 ) !IdRef {4422 ) !Id {
4457 const zcu = self.pt.zcu;4423 const zcu = self.pt.zcu;
4458 const src_ty_id = try self.resolveType(src_ty, .direct);4424 const src_ty_id = try self.resolveType(src_ty, .direct);
4459 const dst_ty_id = try self.resolveType(dst_ty, .direct);4425 const dst_ty_id = try self.resolveType(dst_ty, .direct);
...@@ -4489,9 +4455,9 @@ const NavGen = struct {...@@ -4489,9 +4455,9 @@ const NavGen = struct {
4489 break :blk result_id;4455 break :blk result_id;
4490 }4456 }
44914457
4492 const dst_ptr_ty_id = try self.ptrType(dst_ty, .Function, .indirect);4458 const dst_ptr_ty_id = try self.ptrType(dst_ty, .function, .indirect);
44934459
4494 const tmp_id = try self.alloc(src_ty, .{ .storage_class = .Function });4460 const tmp_id = try self.alloc(src_ty, .{ .storage_class = .function });
4495 try self.store(src_ty, tmp_id, src_id, .{});4461 try self.store(src_ty, tmp_id, src_id, .{});
4496 const casted_ptr_id = self.spv.allocId();4462 const casted_ptr_id = self.spv.allocId();
4497 try self.func.body.emit(self.spv.gpa, .OpBitcast, .{4463 try self.func.body.emit(self.spv.gpa, .OpBitcast, .{
...@@ -4515,7 +4481,7 @@ const NavGen = struct {...@@ -4515,7 +4481,7 @@ const NavGen = struct {
4515 return result_id;4481 return result_id;
4516 }4482 }
45174483
4518 fn airBitCast(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4484 fn airBitCast(self: *NavGen, inst: Air.Inst.Index) !?Id {
4519 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;4485 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
4520 const operand_ty = self.typeOf(ty_op.operand);4486 const operand_ty = self.typeOf(ty_op.operand);
4521 const result_ty = self.typeOfIndex(inst);4487 const result_ty = self.typeOfIndex(inst);
...@@ -4528,7 +4494,7 @@ const NavGen = struct {...@@ -4528,7 +4494,7 @@ const NavGen = struct {
4528 return try self.bitCast(result_ty, operand_ty, operand_id);4494 return try self.bitCast(result_ty, operand_ty, operand_id);
4529 }4495 }
45304496
4531 fn airIntCast(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4497 fn airIntCast(self: *NavGen, inst: Air.Inst.Index) !?Id {
4532 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;4498 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
4533 const src = try self.temporary(ty_op.operand);4499 const src = try self.temporary(ty_op.operand);
4534 const dst_ty = self.typeOfIndex(inst);4500 const dst_ty = self.typeOfIndex(inst);
...@@ -4554,7 +4520,7 @@ const NavGen = struct {...@@ -4554,7 +4520,7 @@ const NavGen = struct {
4554 return try result.materialize(self);4520 return try result.materialize(self);
4555 }4521 }
45564522
4557 fn intFromPtr(self: *NavGen, operand_id: IdRef) !IdRef {4523 fn intFromPtr(self: *NavGen, operand_id: Id) !Id {
4558 const result_type_id = try self.resolveType(Type.usize, .direct);4524 const result_type_id = try self.resolveType(Type.usize, .direct);
4559 const result_id = self.spv.allocId();4525 const result_id = self.spv.allocId();
4560 try self.func.body.emit(self.spv.gpa, .OpConvertPtrToU, .{4526 try self.func.body.emit(self.spv.gpa, .OpConvertPtrToU, .{
...@@ -4565,7 +4531,7 @@ const NavGen = struct {...@@ -4565,7 +4531,7 @@ const NavGen = struct {
4565 return result_id;4531 return result_id;
4566 }4532 }
45674533
4568 fn airFloatFromInt(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4534 fn airFloatFromInt(self: *NavGen, inst: Air.Inst.Index) !?Id {
4569 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;4535 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
4570 const operand_ty = self.typeOf(ty_op.operand);4536 const operand_ty = self.typeOf(ty_op.operand);
4571 const operand_id = try self.resolve(ty_op.operand);4537 const operand_id = try self.resolve(ty_op.operand);
...@@ -4573,7 +4539,7 @@ const NavGen = struct {...@@ -4573,7 +4539,7 @@ const NavGen = struct {
4573 return try self.floatFromInt(result_ty, operand_ty, operand_id);4539 return try self.floatFromInt(result_ty, operand_ty, operand_id);
4574 }4540 }
45754541
4576 fn floatFromInt(self: *NavGen, result_ty: Type, operand_ty: Type, operand_id: IdRef) !IdRef {4542 fn floatFromInt(self: *NavGen, result_ty: Type, operand_ty: Type, operand_id: Id) !Id {
4577 const operand_info = self.arithmeticTypeInfo(operand_ty);4543 const operand_info = self.arithmeticTypeInfo(operand_ty);
4578 const result_id = self.spv.allocId();4544 const result_id = self.spv.allocId();
4579 const result_ty_id = try self.resolveType(result_ty, .direct);4545 const result_ty_id = try self.resolveType(result_ty, .direct);
...@@ -4592,14 +4558,14 @@ const NavGen = struct {...@@ -4592,14 +4558,14 @@ const NavGen = struct {
4592 return result_id;4558 return result_id;
4593 }4559 }
45944560
4595 fn airIntFromFloat(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4561 fn airIntFromFloat(self: *NavGen, inst: Air.Inst.Index) !?Id {
4596 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;4562 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
4597 const operand_id = try self.resolve(ty_op.operand);4563 const operand_id = try self.resolve(ty_op.operand);
4598 const result_ty = self.typeOfIndex(inst);4564 const result_ty = self.typeOfIndex(inst);
4599 return try self.intFromFloat(result_ty, operand_id);4565 return try self.intFromFloat(result_ty, operand_id);
4600 }4566 }
46014567
4602 fn intFromFloat(self: *NavGen, result_ty: Type, operand_id: IdRef) !IdRef {4568 fn intFromFloat(self: *NavGen, result_ty: Type, operand_id: Id) !Id {
4603 const result_info = self.arithmeticTypeInfo(result_ty);4569 const result_info = self.arithmeticTypeInfo(result_ty);
4604 const result_ty_id = try self.resolveType(result_ty, .direct);4570 const result_ty_id = try self.resolveType(result_ty, .direct);
4605 const result_id = self.spv.allocId();4571 const result_id = self.spv.allocId();
...@@ -4618,7 +4584,7 @@ const NavGen = struct {...@@ -4618,7 +4584,7 @@ const NavGen = struct {
4618 return result_id;4584 return result_id;
4619 }4585 }
46204586
4621 fn airFloatCast(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4587 fn airFloatCast(self: *NavGen, inst: Air.Inst.Index) !?Id {
4622 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;4588 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
4623 const operand = try self.temporary(ty_op.operand);4589 const operand = try self.temporary(ty_op.operand);
4624 const dest_ty = self.typeOfIndex(inst);4590 const dest_ty = self.typeOfIndex(inst);
...@@ -4626,7 +4592,7 @@ const NavGen = struct {...@@ -4626,7 +4592,7 @@ const NavGen = struct {
4626 return try result.materialize(self);4592 return try result.materialize(self);
4627 }4593 }
46284594
4629 fn airNot(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4595 fn airNot(self: *NavGen, inst: Air.Inst.Index) !?Id {
4630 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;4596 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
4631 const operand = try self.temporary(ty_op.operand);4597 const operand = try self.temporary(ty_op.operand);
4632 const result_ty = self.typeOfIndex(inst);4598 const result_ty = self.typeOfIndex(inst);
...@@ -4645,7 +4611,7 @@ const NavGen = struct {...@@ -4645,7 +4611,7 @@ const NavGen = struct {
4645 return try result.materialize(self);4611 return try result.materialize(self);
4646 }4612 }
46474613
4648 fn airArrayToSlice(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4614 fn airArrayToSlice(self: *NavGen, inst: Air.Inst.Index) !?Id {
4649 const pt = self.pt;4615 const pt = self.pt;
4650 const zcu = pt.zcu;4616 const zcu = pt.zcu;
4651 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;4617 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
...@@ -4670,7 +4636,7 @@ const NavGen = struct {...@@ -4670,7 +4636,7 @@ const NavGen = struct {
4670 return try self.constructComposite(slice_ty_id, &.{ elem_ptr_id, len_id });4636 return try self.constructComposite(slice_ty_id, &.{ elem_ptr_id, len_id });
4671 }4637 }
46724638
4673 fn airSlice(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4639 fn airSlice(self: *NavGen, inst: Air.Inst.Index) !?Id {
4674 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;4640 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
4675 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;4641 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;
4676 const ptr_id = try self.resolve(bin_op.lhs);4642 const ptr_id = try self.resolve(bin_op.lhs);
...@@ -4680,7 +4646,7 @@ const NavGen = struct {...@@ -4680,7 +4646,7 @@ const NavGen = struct {
4680 return try self.constructComposite(slice_ty_id, &.{ ptr_id, len_id });4646 return try self.constructComposite(slice_ty_id, &.{ ptr_id, len_id });
4681 }4647 }
46824648
4683 fn airAggregateInit(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4649 fn airAggregateInit(self: *NavGen, inst: Air.Inst.Index) !?Id {
4684 const pt = self.pt;4650 const pt = self.pt;
4685 const zcu = pt.zcu;4651 const zcu = pt.zcu;
4686 const ip = &zcu.intern_pool;4652 const ip = &zcu.intern_pool;
...@@ -4732,7 +4698,7 @@ const NavGen = struct {...@@ -4732,7 +4698,7 @@ const NavGen = struct {
47324698
4733 const types = try self.gpa.alloc(Type, elements.len);4699 const types = try self.gpa.alloc(Type, elements.len);
4734 defer self.gpa.free(types);4700 defer self.gpa.free(types);
4735 const constituents = try self.gpa.alloc(IdRef, elements.len);4701 const constituents = try self.gpa.alloc(Id, elements.len);
4736 defer self.gpa.free(constituents);4702 defer self.gpa.free(constituents);
4737 var index: usize = 0;4703 var index: usize = 0;
47384704
...@@ -4771,7 +4737,7 @@ const NavGen = struct {...@@ -4771,7 +4737,7 @@ const NavGen = struct {
4771 },4737 },
4772 .vector => {4738 .vector => {
4773 const n_elems = result_ty.vectorLen(zcu);4739 const n_elems = result_ty.vectorLen(zcu);
4774 const elem_ids = try self.gpa.alloc(IdRef, n_elems);4740 const elem_ids = try self.gpa.alloc(Id, n_elems);
4775 defer self.gpa.free(elem_ids);4741 defer self.gpa.free(elem_ids);
47764742
4777 for (elements, 0..) |element, i| {4743 for (elements, 0..) |element, i| {
...@@ -4784,7 +4750,7 @@ const NavGen = struct {...@@ -4784,7 +4750,7 @@ const NavGen = struct {
4784 .array => {4750 .array => {
4785 const array_info = result_ty.arrayInfo(zcu);4751 const array_info = result_ty.arrayInfo(zcu);
4786 const n_elems: usize = @intCast(result_ty.arrayLenIncludingSentinel(zcu));4752 const n_elems: usize = @intCast(result_ty.arrayLenIncludingSentinel(zcu));
4787 const elem_ids = try self.gpa.alloc(IdRef, n_elems);4753 const elem_ids = try self.gpa.alloc(Id, n_elems);
4788 defer self.gpa.free(elem_ids);4754 defer self.gpa.free(elem_ids);
47894755
4790 for (elements, 0..) |element, i| {4756 for (elements, 0..) |element, i| {
...@@ -4803,7 +4769,7 @@ const NavGen = struct {...@@ -4803,7 +4769,7 @@ const NavGen = struct {
4803 }4769 }
4804 }4770 }
48054771
4806 fn sliceOrArrayLen(self: *NavGen, operand_id: IdRef, ty: Type) !IdRef {4772 fn sliceOrArrayLen(self: *NavGen, operand_id: Id, ty: Type) !Id {
4807 const pt = self.pt;4773 const pt = self.pt;
4808 const zcu = pt.zcu;4774 const zcu = pt.zcu;
4809 switch (ty.ptrSize(zcu)) {4775 switch (ty.ptrSize(zcu)) {
...@@ -4819,7 +4785,7 @@ const NavGen = struct {...@@ -4819,7 +4785,7 @@ const NavGen = struct {
4819 }4785 }
4820 }4786 }
48214787
4822 fn sliceOrArrayPtr(self: *NavGen, operand_id: IdRef, ty: Type) !IdRef {4788 fn sliceOrArrayPtr(self: *NavGen, operand_id: Id, ty: Type) !Id {
4823 const zcu = self.pt.zcu;4789 const zcu = self.pt.zcu;
4824 if (ty.isSlice(zcu)) {4790 if (ty.isSlice(zcu)) {
4825 const ptr_ty = ty.slicePtrFieldType(zcu);4791 const ptr_ty = ty.slicePtrFieldType(zcu);
...@@ -4849,14 +4815,14 @@ const NavGen = struct {...@@ -4849,14 +4815,14 @@ const NavGen = struct {
4849 return self.fail("TODO implement airMemcpy for spirv", .{});4815 return self.fail("TODO implement airMemcpy for spirv", .{});
4850 }4816 }
48514817
4852 fn airSliceField(self: *NavGen, inst: Air.Inst.Index, field: u32) !?IdRef {4818 fn airSliceField(self: *NavGen, inst: Air.Inst.Index, field: u32) !?Id {
4853 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;4819 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
4854 const field_ty = self.typeOfIndex(inst);4820 const field_ty = self.typeOfIndex(inst);
4855 const operand_id = try self.resolve(ty_op.operand);4821 const operand_id = try self.resolve(ty_op.operand);
4856 return try self.extractField(field_ty, operand_id, field);4822 return try self.extractField(field_ty, operand_id, field);
4857 }4823 }
48584824
4859 fn airSliceElemPtr(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4825 fn airSliceElemPtr(self: *NavGen, inst: Air.Inst.Index) !?Id {
4860 const zcu = self.pt.zcu;4826 const zcu = self.pt.zcu;
4861 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;4827 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
4862 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;4828 const bin_op = self.air.extraData(Air.Bin, ty_pl.payload).data;
...@@ -4873,7 +4839,7 @@ const NavGen = struct {...@@ -4873,7 +4839,7 @@ const NavGen = struct {
4873 return try self.ptrAccessChain(ptr_ty_id, slice_ptr, index_id, &.{});4839 return try self.ptrAccessChain(ptr_ty_id, slice_ptr, index_id, &.{});
4874 }4840 }
48754841
4876 fn airSliceElemVal(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4842 fn airSliceElemVal(self: *NavGen, inst: Air.Inst.Index) !?Id {
4877 const zcu = self.pt.zcu;4843 const zcu = self.pt.zcu;
4878 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;4844 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
4879 const slice_ty = self.typeOf(bin_op.lhs);4845 const slice_ty = self.typeOf(bin_op.lhs);
...@@ -4890,7 +4856,7 @@ const NavGen = struct {...@@ -4890,7 +4856,7 @@ const NavGen = struct {
4890 return try self.load(slice_ty.childType(zcu), elem_ptr, .{ .is_volatile = slice_ty.isVolatilePtr(zcu) });4856 return try self.load(slice_ty.childType(zcu), elem_ptr, .{ .is_volatile = slice_ty.isVolatilePtr(zcu) });
4891 }4857 }
48924858
4893 fn ptrElemPtr(self: *NavGen, ptr_ty: Type, ptr_id: IdRef, index_id: IdRef) !IdRef {4859 fn ptrElemPtr(self: *NavGen, ptr_ty: Type, ptr_id: Id, index_id: Id) !Id {
4894 const zcu = self.pt.zcu;4860 const zcu = self.pt.zcu;
4895 // Construct new pointer type for the resulting pointer4861 // Construct new pointer type for the resulting pointer
4896 const elem_ty = ptr_ty.elemType2(zcu); // use elemType() so that we get T for *[N]T.4862 const elem_ty = ptr_ty.elemType2(zcu); // use elemType() so that we get T for *[N]T.
...@@ -4905,7 +4871,7 @@ const NavGen = struct {...@@ -4905,7 +4871,7 @@ const NavGen = struct {
4905 }4871 }
4906 }4872 }
49074873
4908 fn airPtrElemPtr(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4874 fn airPtrElemPtr(self: *NavGen, inst: Air.Inst.Index) !?Id {
4909 const pt = self.pt;4875 const pt = self.pt;
4910 const zcu = pt.zcu;4876 const zcu = pt.zcu;
4911 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;4877 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
...@@ -4923,7 +4889,7 @@ const NavGen = struct {...@@ -4923,7 +4889,7 @@ const NavGen = struct {
4923 return try self.ptrElemPtr(src_ptr_ty, ptr_id, index_id);4889 return try self.ptrElemPtr(src_ptr_ty, ptr_id, index_id);
4924 }4890 }
49254891
4926 fn airArrayElemVal(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4892 fn airArrayElemVal(self: *NavGen, inst: Air.Inst.Index) !?Id {
4927 const zcu = self.pt.zcu;4893 const zcu = self.pt.zcu;
4928 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;4894 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
4929 const array_ty = self.typeOf(bin_op.lhs);4895 const array_ty = self.typeOf(bin_op.lhs);
...@@ -4938,14 +4904,14 @@ const NavGen = struct {...@@ -4938,14 +4904,14 @@ const NavGen = struct {
4938 const is_vector = array_ty.isVector(zcu);4904 const is_vector = array_ty.isVector(zcu);
49394905
4940 const elem_repr: Repr = if (is_vector) .direct else .indirect;4906 const elem_repr: Repr = if (is_vector) .direct else .indirect;
4941 const ptr_array_ty_id = try self.ptrType(array_ty, .Function, .direct);4907 const ptr_array_ty_id = try self.ptrType(array_ty, .function, .direct);
4942 const ptr_elem_ty_id = try self.ptrType(elem_ty, .Function, elem_repr);4908 const ptr_elem_ty_id = try self.ptrType(elem_ty, .function, elem_repr);
49434909
4944 const tmp_id = self.spv.allocId();4910 const tmp_id = self.spv.allocId();
4945 try self.func.prologue.emit(self.spv.gpa, .OpVariable, .{4911 try self.func.prologue.emit(self.spv.gpa, .OpVariable, .{
4946 .id_result_type = ptr_array_ty_id,4912 .id_result_type = ptr_array_ty_id,
4947 .id_result = tmp_id,4913 .id_result = tmp_id,
4948 .storage_class = .Function,4914 .storage_class = .function,
4949 });4915 });
49504916
4951 try self.func.body.emit(self.spv.gpa, .OpStore, .{4917 try self.func.body.emit(self.spv.gpa, .OpStore, .{
...@@ -4973,7 +4939,7 @@ const NavGen = struct {...@@ -4973,7 +4939,7 @@ const NavGen = struct {
4973 return try self.convertToDirect(elem_ty, result_id);4939 return try self.convertToDirect(elem_ty, result_id);
4974 }4940 }
49754941
4976 fn airPtrElemVal(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4942 fn airPtrElemVal(self: *NavGen, inst: Air.Inst.Index) !?Id {
4977 const zcu = self.pt.zcu;4943 const zcu = self.pt.zcu;
4978 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;4944 const bin_op = self.air.instructions.items(.data)[@intFromEnum(inst)].bin_op;
4979 const ptr_ty = self.typeOf(bin_op.lhs);4945 const ptr_ty = self.typeOf(bin_op.lhs);
...@@ -5029,7 +4995,7 @@ const NavGen = struct {...@@ -5029,7 +4995,7 @@ const NavGen = struct {
5029 }4995 }
5030 }4996 }
50314997
5032 fn airGetUnionTag(self: *NavGen, inst: Air.Inst.Index) !?IdRef {4998 fn airGetUnionTag(self: *NavGen, inst: Air.Inst.Index) !?Id {
5033 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;4999 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
5034 const un_ty = self.typeOf(ty_op.operand);5000 const un_ty = self.typeOf(ty_op.operand);
50355001
...@@ -5048,8 +5014,8 @@ const NavGen = struct {...@@ -5048,8 +5014,8 @@ const NavGen = struct {
5048 self: *NavGen,5014 self: *NavGen,
5049 ty: Type,5015 ty: Type,
5050 active_field: u32,5016 active_field: u32,
5051 payload: ?IdRef,5017 payload: ?Id,
5052 ) !IdRef {5018 ) !Id {
5053 // To initialize a union, generate a temporary variable with the5019 // To initialize a union, generate a temporary variable with the
5054 // union type, then get the field pointer and pointer-cast it to the5020 // union type, then get the field pointer and pointer-cast it to the
5055 // right type to store it. Finally load the entire union.5021 // right type to store it. Finally load the entire union.
...@@ -5100,20 +5066,20 @@ const NavGen = struct {...@@ -5100,20 +5066,20 @@ const NavGen = struct {
5100 return try self.constInt(tag_ty, tag_int);5066 return try self.constInt(tag_ty, tag_int);
5101 }5067 }
51025068
5103 const tmp_id = try self.alloc(ty, .{ .storage_class = .Function });5069 const tmp_id = try self.alloc(ty, .{ .storage_class = .function });
51045070
5105 if (layout.tag_size != 0) {5071 if (layout.tag_size != 0) {
5106 const tag_ptr_ty_id = try self.ptrType(tag_ty, .Function, .indirect);5072 const tag_ptr_ty_id = try self.ptrType(tag_ty, .function, .indirect);
5107 const ptr_id = try self.accessChain(tag_ptr_ty_id, tmp_id, &.{@as(u32, @intCast(layout.tag_index))});5073 const ptr_id = try self.accessChain(tag_ptr_ty_id, tmp_id, &.{@as(u32, @intCast(layout.tag_index))});
5108 const tag_id = try self.constInt(tag_ty, tag_int);5074 const tag_id = try self.constInt(tag_ty, tag_int);
5109 try self.store(tag_ty, ptr_id, tag_id, .{});5075 try self.store(tag_ty, ptr_id, tag_id, .{});
5110 }5076 }
51115077
5112 if (payload_ty.hasRuntimeBitsIgnoreComptime(zcu)) {5078 if (payload_ty.hasRuntimeBitsIgnoreComptime(zcu)) {
5113 const pl_ptr_ty_id = try self.ptrType(layout.payload_ty, .Function, .indirect);5079 const pl_ptr_ty_id = try self.ptrType(layout.payload_ty, .function, .indirect);
5114 const pl_ptr_id = try self.accessChain(pl_ptr_ty_id, tmp_id, &.{layout.payload_index});5080 const pl_ptr_id = try self.accessChain(pl_ptr_ty_id, tmp_id, &.{layout.payload_index});
5115 const active_pl_ptr_id = if (!layout.payload_ty.eql(payload_ty, zcu)) blk: {5081 const active_pl_ptr_id = if (!layout.payload_ty.eql(payload_ty, zcu)) blk: {
5116 const active_pl_ptr_ty_id = try self.ptrType(payload_ty, .Function, .indirect);5082 const active_pl_ptr_ty_id = try self.ptrType(payload_ty, .function, .indirect);
5117 const active_pl_ptr_id = self.spv.allocId();5083 const active_pl_ptr_id = self.spv.allocId();
5118 try self.func.body.emit(self.spv.gpa, .OpBitcast, .{5084 try self.func.body.emit(self.spv.gpa, .OpBitcast, .{
5119 .id_result_type = active_pl_ptr_ty_id,5085 .id_result_type = active_pl_ptr_ty_id,
...@@ -5134,7 +5100,7 @@ const NavGen = struct {...@@ -5134,7 +5100,7 @@ const NavGen = struct {
5134 return try self.load(ty, tmp_id, .{});5100 return try self.load(ty, tmp_id, .{});
5135 }5101 }
51365102
5137 fn airUnionInit(self: *NavGen, inst: Air.Inst.Index) !?IdRef {5103 fn airUnionInit(self: *NavGen, inst: Air.Inst.Index) !?Id {
5138 const pt = self.pt;5104 const pt = self.pt;
5139 const zcu = pt.zcu;5105 const zcu = pt.zcu;
5140 const ip = &zcu.intern_pool;5106 const ip = &zcu.intern_pool;
...@@ -5151,7 +5117,7 @@ const NavGen = struct {...@@ -5151,7 +5117,7 @@ const NavGen = struct {
5151 return try self.unionInit(ty, extra.field_index, payload);5117 return try self.unionInit(ty, extra.field_index, payload);
5152 }5118 }
51535119
5154 fn airStructFieldVal(self: *NavGen, inst: Air.Inst.Index) !?IdRef {5120 fn airStructFieldVal(self: *NavGen, inst: Air.Inst.Index) !?Id {
5155 const pt = self.pt;5121 const pt = self.pt;
5156 const zcu = pt.zcu;5122 const zcu = pt.zcu;
5157 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;5123 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
...@@ -5216,13 +5182,13 @@ const NavGen = struct {...@@ -5216,13 +5182,13 @@ const NavGen = struct {
5216 const layout = self.unionLayout(object_ty);5182 const layout = self.unionLayout(object_ty);
5217 assert(layout.has_payload);5183 assert(layout.has_payload);
52185184
5219 const tmp_id = try self.alloc(object_ty, .{ .storage_class = .Function });5185 const tmp_id = try self.alloc(object_ty, .{ .storage_class = .function });
5220 try self.store(object_ty, tmp_id, object_id, .{});5186 try self.store(object_ty, tmp_id, object_id, .{});
52215187
5222 const pl_ptr_ty_id = try self.ptrType(layout.payload_ty, .Function, .indirect);5188 const pl_ptr_ty_id = try self.ptrType(layout.payload_ty, .function, .indirect);
5223 const pl_ptr_id = try self.accessChain(pl_ptr_ty_id, tmp_id, &.{layout.payload_index});5189 const pl_ptr_id = try self.accessChain(pl_ptr_ty_id, tmp_id, &.{layout.payload_index});
52245190
5225 const active_pl_ptr_ty_id = try self.ptrType(field_ty, .Function, .indirect);5191 const active_pl_ptr_ty_id = try self.ptrType(field_ty, .function, .indirect);
5226 const active_pl_ptr_id = self.spv.allocId();5192 const active_pl_ptr_id = self.spv.allocId();
5227 try self.func.body.emit(self.spv.gpa, .OpBitcast, .{5193 try self.func.body.emit(self.spv.gpa, .OpBitcast, .{
5228 .id_result_type = active_pl_ptr_ty_id,5194 .id_result_type = active_pl_ptr_ty_id,
...@@ -5236,7 +5202,7 @@ const NavGen = struct {...@@ -5236,7 +5202,7 @@ const NavGen = struct {
5236 }5202 }
5237 }5203 }
52385204
5239 fn airFieldParentPtr(self: *NavGen, inst: Air.Inst.Index) !?IdRef {5205 fn airFieldParentPtr(self: *NavGen, inst: Air.Inst.Index) !?Id {
5240 const pt = self.pt;5206 const pt = self.pt;
5241 const zcu = pt.zcu;5207 const zcu = pt.zcu;
5242 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;5208 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
...@@ -5273,9 +5239,9 @@ const NavGen = struct {...@@ -5273,9 +5239,9 @@ const NavGen = struct {
5273 self: *NavGen,5239 self: *NavGen,
5274 result_ptr_ty: Type,5240 result_ptr_ty: Type,
5275 object_ptr_ty: Type,5241 object_ptr_ty: Type,
5276 object_ptr: IdRef,5242 object_ptr: Id,
5277 field_index: u32,5243 field_index: u32,
5278 ) !IdRef {5244 ) !Id {
5279 const result_ty_id = try self.resolveType(result_ptr_ty, .direct);5245 const result_ty_id = try self.resolveType(result_ptr_ty, .direct);
52805246
5281 const zcu = self.pt.zcu;5247 const zcu = self.pt.zcu;
...@@ -5318,7 +5284,7 @@ const NavGen = struct {...@@ -5318,7 +5284,7 @@ const NavGen = struct {
5318 }5284 }
5319 }5285 }
53205286
5321 fn airStructFieldPtrIndex(self: *NavGen, inst: Air.Inst.Index, field_index: u32) !?IdRef {5287 fn airStructFieldPtrIndex(self: *NavGen, inst: Air.Inst.Index, field_index: u32) !?Id {
5322 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;5288 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
5323 const struct_ptr = try self.resolve(ty_op.operand);5289 const struct_ptr = try self.resolve(ty_op.operand);
5324 const struct_ptr_ty = self.typeOf(ty_op.operand);5290 const struct_ptr_ty = self.typeOf(ty_op.operand);
...@@ -5327,7 +5293,7 @@ const NavGen = struct {...@@ -5327,7 +5293,7 @@ const NavGen = struct {
5327 }5293 }
53285294
5329 const AllocOptions = struct {5295 const AllocOptions = struct {
5330 initializer: ?IdRef = null,5296 initializer: ?Id = null,
5331 /// The final storage class of the pointer. This may be either `.Generic` or `.Function`.5297 /// The final storage class of the pointer. This may be either `.Generic` or `.Function`.
5332 /// In either case, the local is allocated in the `.Function` storage class, and optionally5298 /// In either case, the local is allocated in the `.Function` storage class, and optionally
5333 /// cast back to `.Generic`.5299 /// cast back to `.Generic`.
...@@ -5342,8 +5308,8 @@ const NavGen = struct {...@@ -5342,8 +5308,8 @@ const NavGen = struct {
5342 self: *NavGen,5308 self: *NavGen,
5343 ty: Type,5309 ty: Type,
5344 options: AllocOptions,5310 options: AllocOptions,
5345 ) !IdRef {5311 ) !Id {
5346 const ptr_fn_ty_id = try self.ptrType(ty, .Function, .indirect);5312 const ptr_fn_ty_id = try self.ptrType(ty, .function, .indirect);
53475313
5348 // SPIR-V requires that OpVariable declarations for locals go into the first block, so we are just going to5314 // SPIR-V requires that OpVariable declarations for locals go into the first block, so we are just going to
5349 // directly generate them into func.prologue instead of the body.5315 // directly generate them into func.prologue instead of the body.
...@@ -5351,7 +5317,7 @@ const NavGen = struct {...@@ -5351,7 +5317,7 @@ const NavGen = struct {
5351 try self.func.prologue.emit(self.spv.gpa, .OpVariable, .{5317 try self.func.prologue.emit(self.spv.gpa, .OpVariable, .{
5352 .id_result_type = ptr_fn_ty_id,5318 .id_result_type = ptr_fn_ty_id,
5353 .id_result = var_id,5319 .id_result = var_id,
5354 .storage_class = .Function,5320 .storage_class = .function,
5355 .initializer = options.initializer,5321 .initializer = options.initializer,
5356 });5322 });
53575323
...@@ -5361,17 +5327,17 @@ const NavGen = struct {...@@ -5361,17 +5327,17 @@ const NavGen = struct {
5361 }5327 }
53625328
5363 switch (options.storage_class) {5329 switch (options.storage_class) {
5364 .Generic => {5330 .generic => {
5365 const ptr_gn_ty_id = try self.ptrType(ty, .Generic, .indirect);5331 const ptr_gn_ty_id = try self.ptrType(ty, .generic, .indirect);
5366 // Convert to a generic pointer5332 // Convert to a generic pointer
5367 return self.castToGeneric(ptr_gn_ty_id, var_id);5333 return self.castToGeneric(ptr_gn_ty_id, var_id);
5368 },5334 },
5369 .Function => return var_id,5335 .function => return var_id,
5370 else => unreachable,5336 else => unreachable,
5371 }5337 }
5372 }5338 }
53735339
5374 fn airAlloc(self: *NavGen, inst: Air.Inst.Index) !?IdRef {5340 fn airAlloc(self: *NavGen, inst: Air.Inst.Index) !?Id {
5375 const zcu = self.pt.zcu;5341 const zcu = self.pt.zcu;
5376 const ptr_ty = self.typeOfIndex(inst);5342 const ptr_ty = self.typeOfIndex(inst);
5377 const child_ty = ptr_ty.childType(zcu);5343 const child_ty = ptr_ty.childType(zcu);
...@@ -5380,7 +5346,7 @@ const NavGen = struct {...@@ -5380,7 +5346,7 @@ const NavGen = struct {
5380 });5346 });
5381 }5347 }
53825348
5383 fn airArg(self: *NavGen) IdRef {5349 fn airArg(self: *NavGen) Id {
5384 defer self.next_arg_index += 1;5350 defer self.next_arg_index += 1;
5385 return self.args.items[self.next_arg_index];5351 return self.args.items[self.next_arg_index];
5386 }5352 }
...@@ -5389,14 +5355,14 @@ const NavGen = struct {...@@ -5389,14 +5355,14 @@ const NavGen = struct {
5389 /// block to jump to. This function emits instructions, so it should be emitted5355 /// block to jump to. This function emits instructions, so it should be emitted
5390 /// inside the merge block of the block.5356 /// inside the merge block of the block.
5391 /// This function should only be called with structured control flow generation.5357 /// This function should only be called with structured control flow generation.
5392 fn structuredNextBlock(self: *NavGen, incoming: []const ControlFlow.Structured.Block.Incoming) !IdRef {5358 fn structuredNextBlock(self: *NavGen, incoming: []const ControlFlow.Structured.Block.Incoming) !Id {
5393 assert(self.control_flow == .structured);5359 assert(self.control_flow == .structured);
53945360
5395 const result_id = self.spv.allocId();5361 const result_id = self.spv.allocId();
5396 const block_id_ty_id = try self.resolveType(Type.u32, .direct);5362 const block_id_ty_id = try self.resolveType(Type.u32, .direct);
5397 try self.func.body.emitRaw(self.spv.gpa, .OpPhi, @intCast(2 + incoming.len * 2)); // result type + result + variable/parent...5363 try self.func.body.emitRaw(self.spv.gpa, .OpPhi, @intCast(2 + incoming.len * 2)); // result type + result + variable/parent...
5398 self.func.body.writeOperand(spec.IdResultType, block_id_ty_id);5364 self.func.body.writeOperand(spec.Id, block_id_ty_id);
5399 self.func.body.writeOperand(spec.IdRef, result_id);5365 self.func.body.writeOperand(spec.Id, result_id);
54005366
5401 for (incoming) |incoming_block| {5367 for (incoming) |incoming_block| {
5402 self.func.body.writeOperand(spec.PairIdRefIdRef, .{ incoming_block.next_block, incoming_block.src_label });5368 self.func.body.writeOperand(spec.PairIdRefIdRef, .{ incoming_block.next_block, incoming_block.src_label });
...@@ -5408,7 +5374,7 @@ const NavGen = struct {...@@ -5408,7 +5374,7 @@ const NavGen = struct {
5408 /// Jumps to the block with the target block-id. This function must only be called when5374 /// Jumps to the block with the target block-id. This function must only be called when
5409 /// terminating a body, there should be no instructions after it.5375 /// terminating a body, there should be no instructions after it.
5410 /// This function should only be called with structured control flow generation.5376 /// This function should only be called with structured control flow generation.
5411 fn structuredBreak(self: *NavGen, target_block: IdRef) !void {5377 fn structuredBreak(self: *NavGen, target_block: Id) !void {
5412 assert(self.control_flow == .structured);5378 assert(self.control_flow == .structured);
54135379
5414 const sblock = self.control_flow.structured.block_stack.getLast();5380 const sblock = self.control_flow.structured.block_stack.getLast();
...@@ -5448,12 +5414,12 @@ const NavGen = struct {...@@ -5448,12 +5414,12 @@ const NavGen = struct {
5448 /// Using loops; loops can be early exited by jumping to the merge block at5414 /// Using loops; loops can be early exited by jumping to the merge block at
5449 /// any time.5415 /// any time.
5450 loop: struct {5416 loop: struct {
5451 merge_label: IdRef,5417 merge_label: Id,
5452 continue_label: IdRef,5418 continue_label: Id,
5453 },5419 },
5454 },5420 },
5455 body: []const Air.Inst.Index,5421 body: []const Air.Inst.Index,
5456 ) !IdRef {5422 ) !Id {
5457 assert(self.control_flow == .structured);5423 assert(self.control_flow == .structured);
54585424
5459 var sblock: ControlFlow.Structured.Block = switch (block_merge_type) {5425 var sblock: ControlFlow.Structured.Block = switch (block_merge_type) {
...@@ -5533,13 +5499,13 @@ const NavGen = struct {...@@ -5533,13 +5499,13 @@ const NavGen = struct {
5533 }5499 }
5534 }5500 }
55355501
5536 fn airBlock(self: *NavGen, inst: Air.Inst.Index) !?IdRef {5502 fn airBlock(self: *NavGen, inst: Air.Inst.Index) !?Id {
5537 const inst_datas = self.air.instructions.items(.data);5503 const inst_datas = self.air.instructions.items(.data);
5538 const extra = self.air.extraData(Air.Block, inst_datas[@intFromEnum(inst)].ty_pl.payload);5504 const extra = self.air.extraData(Air.Block, inst_datas[@intFromEnum(inst)].ty_pl.payload);
5539 return self.lowerBlock(inst, @ptrCast(self.air.extra.items[extra.end..][0..extra.data.body_len]));5505 return self.lowerBlock(inst, @ptrCast(self.air.extra.items[extra.end..][0..extra.data.body_len]));
5540 }5506 }
55415507
5542 fn lowerBlock(self: *NavGen, inst: Air.Inst.Index, body: []const Air.Inst.Index) !?IdRef {5508 fn lowerBlock(self: *NavGen, inst: Air.Inst.Index, body: []const Air.Inst.Index) !?Id {
5543 // In AIR, a block doesn't really define an entry point like a block, but5509 // In AIR, a block doesn't really define an entry point like a block, but
5544 // more like a scope that breaks can jump out of and "return" a value from.5510 // more like a scope that breaks can jump out of and "return" a value from.
5545 // This cannot be directly modelled in SPIR-V, so in a block instruction,5511 // This cannot be directly modelled in SPIR-V, so in a block instruction,
...@@ -5584,8 +5550,8 @@ const NavGen = struct {...@@ -5584,8 +5550,8 @@ const NavGen = struct {
5584 // result type + result + variable/parent...5550 // result type + result + variable/parent...
5585 2 + @as(u16, @intCast(block.incoming_blocks.items.len * 2)),5551 2 + @as(u16, @intCast(block.incoming_blocks.items.len * 2)),
5586 );5552 );
5587 self.func.body.writeOperand(spec.IdResultType, result_type_id);5553 self.func.body.writeOperand(spec.Id, result_type_id);
5588 self.func.body.writeOperand(spec.IdRef, result_id);5554 self.func.body.writeOperand(spec.Id, result_id);
55895555
5590 for (block.incoming_blocks.items) |incoming| {5556 for (block.incoming_blocks.items) |incoming| {
5591 self.func.body.writeOperand(5557 self.func.body.writeOperand(
...@@ -5599,7 +5565,7 @@ const NavGen = struct {...@@ -5599,7 +5565,7 @@ const NavGen = struct {
5599 };5565 };
56005566
5601 const maybe_block_result_var_id = if (have_block_result) blk: {5567 const maybe_block_result_var_id = if (have_block_result) blk: {
5602 const block_result_var_id = try self.alloc(ty, .{ .storage_class = .Function });5568 const block_result_var_id = try self.alloc(ty, .{ .storage_class = .function });
5603 try cf.block_results.putNoClobber(self.gpa, inst, block_result_var_id);5569 try cf.block_results.putNoClobber(self.gpa, inst, block_result_var_id);
5604 break :blk block_result_var_id;5570 break :blk block_result_var_id;
5605 } else null;5571 } else null;
...@@ -5823,7 +5789,7 @@ const NavGen = struct {...@@ -5823,7 +5789,7 @@ const NavGen = struct {
5823 }5789 }
5824 }5790 }
58255791
5826 fn airLoad(self: *NavGen, inst: Air.Inst.Index) !?IdRef {5792 fn airLoad(self: *NavGen, inst: Air.Inst.Index) !?Id {
5827 const zcu = self.pt.zcu;5793 const zcu = self.pt.zcu;
5828 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;5794 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
5829 const ptr_ty = self.typeOf(ty_op.operand);5795 const ptr_ty = self.typeOf(ty_op.operand);
...@@ -5894,7 +5860,7 @@ const NavGen = struct {...@@ -5894,7 +5860,7 @@ const NavGen = struct {
5894 });5860 });
5895 }5861 }
58965862
5897 fn airTry(self: *NavGen, inst: Air.Inst.Index) !?IdRef {5863 fn airTry(self: *NavGen, inst: Air.Inst.Index) !?Id {
5898 const zcu = self.pt.zcu;5864 const zcu = self.pt.zcu;
5899 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;5865 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
5900 const err_union_id = try self.resolve(pl_op.operand);5866 const err_union_id = try self.resolve(pl_op.operand);
...@@ -5964,7 +5930,7 @@ const NavGen = struct {...@@ -5964,7 +5930,7 @@ const NavGen = struct {
5964 return try self.extractField(payload_ty, err_union_id, eu_layout.payloadFieldIndex());5930 return try self.extractField(payload_ty, err_union_id, eu_layout.payloadFieldIndex());
5965 }5931 }
59665932
5967 fn airErrUnionErr(self: *NavGen, inst: Air.Inst.Index) !?IdRef {5933 fn airErrUnionErr(self: *NavGen, inst: Air.Inst.Index) !?Id {
5968 const zcu = self.pt.zcu;5934 const zcu = self.pt.zcu;
5969 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;5935 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
5970 const operand_id = try self.resolve(ty_op.operand);5936 const operand_id = try self.resolve(ty_op.operand);
...@@ -5987,7 +5953,7 @@ const NavGen = struct {...@@ -5987,7 +5953,7 @@ const NavGen = struct {
5987 return try self.extractField(Type.anyerror, operand_id, eu_layout.errorFieldIndex());5953 return try self.extractField(Type.anyerror, operand_id, eu_layout.errorFieldIndex());
5988 }5954 }
59895955
5990 fn airErrUnionPayload(self: *NavGen, inst: Air.Inst.Index) !?IdRef {5956 fn airErrUnionPayload(self: *NavGen, inst: Air.Inst.Index) !?Id {
5991 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;5957 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
5992 const operand_id = try self.resolve(ty_op.operand);5958 const operand_id = try self.resolve(ty_op.operand);
5993 const payload_ty = self.typeOfIndex(inst);5959 const payload_ty = self.typeOfIndex(inst);
...@@ -6000,7 +5966,7 @@ const NavGen = struct {...@@ -6000,7 +5966,7 @@ const NavGen = struct {
6000 return try self.extractField(payload_ty, operand_id, eu_layout.payloadFieldIndex());5966 return try self.extractField(payload_ty, operand_id, eu_layout.payloadFieldIndex());
6001 }5967 }
60025968
6003 fn airWrapErrUnionErr(self: *NavGen, inst: Air.Inst.Index) !?IdRef {5969 fn airWrapErrUnionErr(self: *NavGen, inst: Air.Inst.Index) !?Id {
6004 const zcu = self.pt.zcu;5970 const zcu = self.pt.zcu;
6005 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;5971 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
6006 const err_union_ty = self.typeOfIndex(inst);5972 const err_union_ty = self.typeOfIndex(inst);
...@@ -6014,7 +5980,7 @@ const NavGen = struct {...@@ -6014,7 +5980,7 @@ const NavGen = struct {
60145980
6015 const payload_ty_id = try self.resolveType(payload_ty, .indirect);5981 const payload_ty_id = try self.resolveType(payload_ty, .indirect);
60165982
6017 var members: [2]IdRef = undefined;5983 var members: [2]Id = undefined;
6018 members[eu_layout.errorFieldIndex()] = operand_id;5984 members[eu_layout.errorFieldIndex()] = operand_id;
6019 members[eu_layout.payloadFieldIndex()] = try self.spv.constUndef(payload_ty_id);5985 members[eu_layout.payloadFieldIndex()] = try self.spv.constUndef(payload_ty_id);
60205986
...@@ -6026,7 +5992,7 @@ const NavGen = struct {...@@ -6026,7 +5992,7 @@ const NavGen = struct {
6026 return try self.constructComposite(err_union_ty_id, &members);5992 return try self.constructComposite(err_union_ty_id, &members);
6027 }5993 }
60285994
6029 fn airWrapErrUnionPayload(self: *NavGen, inst: Air.Inst.Index) !?IdRef {5995 fn airWrapErrUnionPayload(self: *NavGen, inst: Air.Inst.Index) !?Id {
6030 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;5996 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
6031 const err_union_ty = self.typeOfIndex(inst);5997 const err_union_ty = self.typeOfIndex(inst);
6032 const operand_id = try self.resolve(ty_op.operand);5998 const operand_id = try self.resolve(ty_op.operand);
...@@ -6037,7 +6003,7 @@ const NavGen = struct {...@@ -6037,7 +6003,7 @@ const NavGen = struct {
6037 return try self.constInt(Type.anyerror, 0);6003 return try self.constInt(Type.anyerror, 0);
6038 }6004 }
60396005
6040 var members: [2]IdRef = undefined;6006 var members: [2]Id = undefined;
6041 members[eu_layout.errorFieldIndex()] = try self.constInt(Type.anyerror, 0);6007 members[eu_layout.errorFieldIndex()] = try self.constInt(Type.anyerror, 0);
6042 members[eu_layout.payloadFieldIndex()] = try self.convertToIndirect(payload_ty, operand_id);6008 members[eu_layout.payloadFieldIndex()] = try self.convertToIndirect(payload_ty, operand_id);
60436009
...@@ -6049,7 +6015,7 @@ const NavGen = struct {...@@ -6049,7 +6015,7 @@ const NavGen = struct {
6049 return try self.constructComposite(err_union_ty_id, &members);6015 return try self.constructComposite(err_union_ty_id, &members);
6050 }6016 }
60516017
6052 fn airIsNull(self: *NavGen, inst: Air.Inst.Index, is_pointer: bool, pred: enum { is_null, is_non_null }) !?IdRef {6018 fn airIsNull(self: *NavGen, inst: Air.Inst.Index, is_pointer: bool, pred: enum { is_null, is_non_null }) !?Id {
6053 const pt = self.pt;6019 const pt = self.pt;
6054 const zcu = pt.zcu;6020 const zcu = pt.zcu;
6055 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;6021 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;
...@@ -6126,7 +6092,7 @@ const NavGen = struct {...@@ -6126,7 +6092,7 @@ const NavGen = struct {
6126 };6092 };
6127 }6093 }
61286094
6129 fn airIsErr(self: *NavGen, inst: Air.Inst.Index, pred: enum { is_err, is_non_err }) !?IdRef {6095 fn airIsErr(self: *NavGen, inst: Air.Inst.Index, pred: enum { is_err, is_non_err }) !?Id {
6130 const zcu = self.pt.zcu;6096 const zcu = self.pt.zcu;
6131 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;6097 const un_op = self.air.instructions.items(.data)[@intFromEnum(inst)].un_op;
6132 const operand_id = try self.resolve(un_op);6098 const operand_id = try self.resolve(un_op);
...@@ -6164,7 +6130,7 @@ const NavGen = struct {...@@ -6164,7 +6130,7 @@ const NavGen = struct {
6164 return result_id;6130 return result_id;
6165 }6131 }
61666132
6167 fn airUnwrapOptional(self: *NavGen, inst: Air.Inst.Index) !?IdRef {6133 fn airUnwrapOptional(self: *NavGen, inst: Air.Inst.Index) !?Id {
6168 const pt = self.pt;6134 const pt = self.pt;
6169 const zcu = pt.zcu;6135 const zcu = pt.zcu;
6170 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;6136 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
...@@ -6181,7 +6147,7 @@ const NavGen = struct {...@@ -6181,7 +6147,7 @@ const NavGen = struct {
6181 return try self.extractField(payload_ty, operand_id, 0);6147 return try self.extractField(payload_ty, operand_id, 0);
6182 }6148 }
61836149
6184 fn airUnwrapOptionalPtr(self: *NavGen, inst: Air.Inst.Index) !?IdRef {6150 fn airUnwrapOptionalPtr(self: *NavGen, inst: Air.Inst.Index) !?Id {
6185 const pt = self.pt;6151 const pt = self.pt;
6186 const zcu = pt.zcu;6152 const zcu = pt.zcu;
6187 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;6153 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
...@@ -6206,7 +6172,7 @@ const NavGen = struct {...@@ -6206,7 +6172,7 @@ const NavGen = struct {
6206 return try self.accessChain(result_ty_id, operand_id, &.{0});6172 return try self.accessChain(result_ty_id, operand_id, &.{0});
6207 }6173 }
62086174
6209 fn airWrapOptional(self: *NavGen, inst: Air.Inst.Index) !?IdRef {6175 fn airWrapOptional(self: *NavGen, inst: Air.Inst.Index) !?Id {
6210 const pt = self.pt;6176 const pt = self.pt;
6211 const zcu = pt.zcu;6177 const zcu = pt.zcu;
6212 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;6178 const ty_op = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_op;
...@@ -6224,7 +6190,7 @@ const NavGen = struct {...@@ -6224,7 +6190,7 @@ const NavGen = struct {
6224 }6190 }
62256191
6226 const payload_id = try self.convertToIndirect(payload_ty, operand_id);6192 const payload_id = try self.convertToIndirect(payload_ty, operand_id);
6227 const members = [_]IdRef{ payload_id, try self.constBool(true, .indirect) };6193 const members = [_]Id{ payload_id, try self.constBool(true, .indirect) };
6228 const optional_ty_id = try self.resolveType(optional_ty, .direct);6194 const optional_ty_id = try self.resolveType(optional_ty, .direct);
6229 return try self.constructComposite(optional_ty_id, &members);6195 return try self.constructComposite(optional_ty_id, &members);
6230 }6196 }
...@@ -6294,8 +6260,8 @@ const NavGen = struct {...@@ -6294,8 +6260,8 @@ const NavGen = struct {
62946260
6295 // Emit the instruction before generating the blocks.6261 // Emit the instruction before generating the blocks.
6296 try self.func.body.emitRaw(self.spv.gpa, .OpSwitch, 2 + (cond_words + 1) * num_conditions);6262 try self.func.body.emitRaw(self.spv.gpa, .OpSwitch, 2 + (cond_words + 1) * num_conditions);
6297 self.func.body.writeOperand(IdRef, cond_indirect);6263 self.func.body.writeOperand(Id, cond_indirect);
6298 self.func.body.writeOperand(IdRef, default);6264 self.func.body.writeOperand(Id, default);
62996265
6300 // Emit each of the cases6266 // Emit each of the cases
6301 {6267 {
...@@ -6322,7 +6288,7 @@ const NavGen = struct {...@@ -6322,7 +6288,7 @@ const NavGen = struct {
6322 else => unreachable,6288 else => unreachable,
6323 };6289 };
6324 self.func.body.writeOperand(spec.LiteralContextDependentNumber, int_lit);6290 self.func.body.writeOperand(spec.LiteralContextDependentNumber, int_lit);
6325 self.func.body.writeOperand(IdRef, label);6291 self.func.body.writeOperand(Id, label);
6326 }6292 }
6327 }6293 }
6328 }6294 }
...@@ -6399,7 +6365,7 @@ const NavGen = struct {...@@ -6399,7 +6365,7 @@ const NavGen = struct {
6399 });6365 });
6400 }6366 }
64016367
6402 fn airDbgInlineBlock(self: *NavGen, inst: Air.Inst.Index) !?IdRef {6368 fn airDbgInlineBlock(self: *NavGen, inst: Air.Inst.Index) !?Id {
6403 const zcu = self.pt.zcu;6369 const zcu = self.pt.zcu;
6404 const inst_datas = self.air.instructions.items(.data);6370 const inst_datas = self.air.instructions.items(.data);
6405 const extra = self.air.extraData(Air.DbgInlineBlock, inst_datas[@intFromEnum(inst)].ty_pl.payload);6371 const extra = self.air.extraData(Air.DbgInlineBlock, inst_datas[@intFromEnum(inst)].ty_pl.payload);
...@@ -6416,7 +6382,7 @@ const NavGen = struct {...@@ -6416,7 +6382,7 @@ const NavGen = struct {
6416 try self.spv.debugName(target_id, name.toSlice(self.air));6382 try self.spv.debugName(target_id, name.toSlice(self.air));
6417 }6383 }
64186384
6419 fn airAssembly(self: *NavGen, inst: Air.Inst.Index) !?IdRef {6385 fn airAssembly(self: *NavGen, inst: Air.Inst.Index) !?Id {
6420 const zcu = self.pt.zcu;6386 const zcu = self.pt.zcu;
6421 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;6387 const ty_pl = self.air.instructions.items(.data)[@intFromEnum(inst)].ty_pl;
6422 const extra = self.air.extraData(Air.Asm, ty_pl.payload);6388 const extra = self.air.extraData(Air.Asm, ty_pl.payload);
...@@ -6586,7 +6552,7 @@ const NavGen = struct {...@@ -6586,7 +6552,7 @@ const NavGen = struct {
6586 return null;6552 return null;
6587 }6553 }
65886554
6589 fn airCall(self: *NavGen, inst: Air.Inst.Index, modifier: std.builtin.CallModifier) !?IdRef {6555 fn airCall(self: *NavGen, inst: Air.Inst.Index, modifier: std.builtin.CallModifier) !?Id {
6590 _ = modifier;6556 _ = modifier;
65916557
6592 const pt = self.pt;6558 const pt = self.pt;
...@@ -6608,7 +6574,7 @@ const NavGen = struct {...@@ -6608,7 +6574,7 @@ const NavGen = struct {
6608 const callee_id = try self.resolve(pl_op.operand);6574 const callee_id = try self.resolve(pl_op.operand);
66096575
6610 comptime assert(zig_call_abi_ver == 3);6576 comptime assert(zig_call_abi_ver == 3);
6611 const params = try self.gpa.alloc(spec.IdRef, args.len);6577 const params = try self.gpa.alloc(spec.Id, args.len);
6612 defer self.gpa.free(params);6578 defer self.gpa.free(params);
6613 var n_params: usize = 0;6579 var n_params: usize = 0;
6614 for (args) |arg| {6580 for (args) |arg| {
...@@ -6637,7 +6603,7 @@ const NavGen = struct {...@@ -6637,7 +6603,7 @@ const NavGen = struct {
6637 return result_id;6603 return result_id;
6638 }6604 }
66396605
6640 fn builtin3D(self: *NavGen, result_ty: Type, builtin: spec.BuiltIn, dimension: u32, out_of_range_value: anytype) !IdRef {6606 fn builtin3D(self: *NavGen, result_ty: Type, builtin: spec.BuiltIn, dimension: u32, out_of_range_value: anytype) !Id {
6641 if (dimension >= 3) {6607 if (dimension >= 3) {
6642 return try self.constInt(result_ty, out_of_range_value);6608 return try self.constInt(result_ty, out_of_range_value);
6643 }6609 }
...@@ -6645,7 +6611,7 @@ const NavGen = struct {...@@ -6645,7 +6611,7 @@ const NavGen = struct {
6645 .len = 3,6611 .len = 3,
6646 .child = result_ty.toIntern(),6612 .child = result_ty.toIntern(),
6647 });6613 });
6648 const ptr_ty_id = try self.ptrType(vec_ty, .Input, .indirect);6614 const ptr_ty_id = try self.ptrType(vec_ty, .input, .indirect);
6649 const spv_decl_index = try self.spv.builtin(ptr_ty_id, builtin);6615 const spv_decl_index = try self.spv.builtin(ptr_ty_id, builtin);
6650 try self.func.decl_deps.put(self.spv.gpa, spv_decl_index, {});6616 try self.func.decl_deps.put(self.spv.gpa, spv_decl_index, {});
6651 const ptr = self.spv.declPtr(spv_decl_index).result_id;6617 const ptr = self.spv.declPtr(spv_decl_index).result_id;
...@@ -6653,34 +6619,34 @@ const NavGen = struct {...@@ -6653,34 +6619,34 @@ const NavGen = struct {
6653 return try self.extractVectorComponent(result_ty, vec, dimension);6619 return try self.extractVectorComponent(result_ty, vec, dimension);
6654 }6620 }
66556621
6656 fn airWorkItemId(self: *NavGen, inst: Air.Inst.Index) !?IdRef {6622 fn airWorkItemId(self: *NavGen, inst: Air.Inst.Index) !?Id {
6657 if (self.liveness.isUnused(inst)) return null;6623 if (self.liveness.isUnused(inst)) return null;
6658 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;6624 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
6659 const dimension = pl_op.payload;6625 const dimension = pl_op.payload;
6660 // TODO: Should we make these builtins return usize?6626 // TODO: Should we make these builtins return usize?
6661 const result_id = try self.builtin3D(Type.u64, .LocalInvocationId, dimension, 0);6627 const result_id = try self.builtin3D(Type.u64, .local_invocation_id, dimension, 0);
6662 const tmp = Temporary.init(Type.u64, result_id);6628 const tmp = Temporary.init(Type.u64, result_id);
6663 const result = try self.buildConvert(Type.u32, tmp);6629 const result = try self.buildConvert(Type.u32, tmp);
6664 return try result.materialize(self);6630 return try result.materialize(self);
6665 }6631 }
66666632
6667 fn airWorkGroupSize(self: *NavGen, inst: Air.Inst.Index) !?IdRef {6633 fn airWorkGroupSize(self: *NavGen, inst: Air.Inst.Index) !?Id {
6668 if (self.liveness.isUnused(inst)) return null;6634 if (self.liveness.isUnused(inst)) return null;
6669 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;6635 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
6670 const dimension = pl_op.payload;6636 const dimension = pl_op.payload;
6671 // TODO: Should we make these builtins return usize?6637 // TODO: Should we make these builtins return usize?
6672 const result_id = try self.builtin3D(Type.u64, .WorkgroupSize, dimension, 0);6638 const result_id = try self.builtin3D(Type.u64, .workgroup_size, dimension, 0);
6673 const tmp = Temporary.init(Type.u64, result_id);6639 const tmp = Temporary.init(Type.u64, result_id);
6674 const result = try self.buildConvert(Type.u32, tmp);6640 const result = try self.buildConvert(Type.u32, tmp);
6675 return try result.materialize(self);6641 return try result.materialize(self);
6676 }6642 }
66776643
6678 fn airWorkGroupId(self: *NavGen, inst: Air.Inst.Index) !?IdRef {6644 fn airWorkGroupId(self: *NavGen, inst: Air.Inst.Index) !?Id {
6679 if (self.liveness.isUnused(inst)) return null;6645 if (self.liveness.isUnused(inst)) return null;
6680 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;6646 const pl_op = self.air.instructions.items(.data)[@intFromEnum(inst)].pl_op;
6681 const dimension = pl_op.payload;6647 const dimension = pl_op.payload;
6682 // TODO: Should we make these builtins return usize?6648 // TODO: Should we make these builtins return usize?
6683 const result_id = try self.builtin3D(Type.u64, .WorkgroupId, dimension, 0);6649 const result_id = try self.builtin3D(Type.u64, .workgroup_id, dimension, 0);
6684 const tmp = Temporary.init(Type.u64, result_id);6650 const tmp = Temporary.init(Type.u64, result_id);
6685 const result = try self.buildConvert(Type.u32, tmp);6651 const result = try self.buildConvert(Type.u32, tmp);
6686 return try result.materialize(self);6652 return try result.materialize(self);
src/codegen/spirv/Assembler.zig+23-24
...@@ -7,8 +7,7 @@ const assert = std.debug.assert;...@@ -7,8 +7,7 @@ const assert = std.debug.assert;
7const spec = @import("spec.zig");7const spec = @import("spec.zig");
8const Opcode = spec.Opcode;8const Opcode = spec.Opcode;
9const Word = spec.Word;9const Word = spec.Word;
10const IdRef = spec.IdRef;10const Id = spec.Id;
11const IdResult = spec.IdResult;
12const StorageClass = spec.StorageClass;11const StorageClass = spec.StorageClass;
1312
14const SpvModule = @import("Module.zig");13const SpvModule = @import("Module.zig");
...@@ -127,10 +126,10 @@ const AsmValue = union(enum) {...@@ -127,10 +126,10 @@ const AsmValue = union(enum) {
127 unresolved_forward_reference,126 unresolved_forward_reference,
128127
129 /// This result-value is a normal result produced by a different instruction.128 /// This result-value is a normal result produced by a different instruction.
130 value: IdRef,129 value: Id,
131130
132 /// This result-value represents a type registered into the module's type system.131 /// This result-value represents a type registered into the module's type system.
133 ty: IdRef,132 ty: Id,
134133
135 /// This is a pre-supplied constant integer value.134 /// This is a pre-supplied constant integer value.
136 constant: u32,135 constant: u32,
...@@ -141,7 +140,7 @@ const AsmValue = union(enum) {...@@ -141,7 +140,7 @@ const AsmValue = union(enum) {
141 /// Retrieve the result-id of this AsmValue. Asserts that this AsmValue140 /// Retrieve the result-id of this AsmValue. Asserts that this AsmValue
142 /// is of a variant that allows the result to be obtained (not an unresolved141 /// is of a variant that allows the result to be obtained (not an unresolved
143 /// forward declaration, not in the process of being declared, etc).142 /// forward declaration, not in the process of being declared, etc).
144 pub fn resultId(self: AsmValue) IdRef {143 pub fn resultId(self: AsmValue) Id {
145 return switch (self) {144 return switch (self) {
146 .just_declared,145 .just_declared,
147 .unresolved_forward_reference,146 .unresolved_forward_reference,
...@@ -314,7 +313,7 @@ fn processInstruction(self: *Assembler) !void {...@@ -314,7 +313,7 @@ fn processInstruction(self: *Assembler) !void {
314 return;313 return;
315 },314 },
316 else => switch (self.inst.opcode.class()) {315 else => switch (self.inst.opcode.class()) {
317 .TypeDeclaration => try self.processTypeInstruction(),316 .type_declaration => try self.processTypeInstruction(),
318 else => (try self.processGenericInstruction()) orelse return,317 else => (try self.processGenericInstruction()) orelse return,
319 },318 },
320 };319 };
...@@ -392,7 +391,7 @@ fn processTypeInstruction(self: *Assembler) !AsmValue {...@@ -392,7 +391,7 @@ fn processTypeInstruction(self: *Assembler) !AsmValue {
392 break :blk result_id;391 break :blk result_id;
393 },392 },
394 .OpTypeStruct => blk: {393 .OpTypeStruct => blk: {
395 const ids = try self.gpa.alloc(IdRef, operands[1..].len);394 const ids = try self.gpa.alloc(Id, operands[1..].len);
396 defer self.gpa.free(ids);395 defer self.gpa.free(ids);
397 for (operands[1..], ids) |op, *id| id.* = try self.resolveRefId(op.ref_id);396 for (operands[1..], ids) |op, *id| id.* = try self.resolveRefId(op.ref_id);
398 const result_id = self.spv.allocId();397 const result_id = self.spv.allocId();
...@@ -429,7 +428,7 @@ fn processTypeInstruction(self: *Assembler) !AsmValue {...@@ -429,7 +428,7 @@ fn processTypeInstruction(self: *Assembler) !AsmValue {
429 const param_operands = operands[2..];428 const param_operands = operands[2..];
430 const return_type = try self.resolveRefId(operands[1].ref_id);429 const return_type = try self.resolveRefId(operands[1].ref_id);
431430
432 const param_types = try self.spv.gpa.alloc(IdRef, param_operands.len);431 const param_types = try self.spv.gpa.alloc(Id, param_operands.len);
433 defer self.spv.gpa.free(param_types);432 defer self.spv.gpa.free(param_types);
434 for (param_types, param_operands) |*param, operand| {433 for (param_types, param_operands) |*param, operand| {
435 param.* = try self.resolveRefId(operand.ref_id);434 param.* = try self.resolveRefId(operand.ref_id);
...@@ -457,17 +456,17 @@ fn processGenericInstruction(self: *Assembler) !?AsmValue {...@@ -457,17 +456,17 @@ fn processGenericInstruction(self: *Assembler) !?AsmValue {
457 const operands = self.inst.operands.items;456 const operands = self.inst.operands.items;
458 var maybe_spv_decl_index: ?SpvModule.Decl.Index = null;457 var maybe_spv_decl_index: ?SpvModule.Decl.Index = null;
459 const section = switch (self.inst.opcode.class()) {458 const section = switch (self.inst.opcode.class()) {
460 .ConstantCreation => &self.spv.sections.types_globals_constants,459 .constant_creation => &self.spv.sections.types_globals_constants,
461 .Annotation => &self.spv.sections.annotations,460 .annotation => &self.spv.sections.annotations,
462 .TypeDeclaration => unreachable, // Handled elsewhere.461 .type_declaration => unreachable, // Handled elsewhere.
463 else => switch (self.inst.opcode) {462 else => switch (self.inst.opcode) {
464 .OpEntryPoint => unreachable,463 .OpEntryPoint => unreachable,
465 .OpExecutionMode, .OpExecutionModeId => &self.spv.sections.execution_modes,464 .OpExecutionMode, .OpExecutionModeId => &self.spv.sections.execution_modes,
466 .OpVariable => section: {465 .OpVariable => section: {
467 const storage_class: spec.StorageClass = @enumFromInt(operands[2].value);466 const storage_class: spec.StorageClass = @enumFromInt(operands[2].value);
468 if (storage_class == .Function) break :section &self.func.prologue;467 if (storage_class == .function) break :section &self.func.prologue;
469 maybe_spv_decl_index = try self.spv.allocDecl(.global);468 maybe_spv_decl_index = try self.spv.allocDecl(.global);
470 if (self.spv.version.minor < 4 and storage_class != .Input and storage_class != .Output) {469 if (self.spv.version.minor < 4 and storage_class != .input and storage_class != .output) {
471 // Before version 1.4, the interface’s storage classes are limited to the Input and Output470 // Before version 1.4, the interface’s storage classes are limited to the Input and Output
472 break :section &self.spv.sections.types_globals_constants;471 break :section &self.spv.sections.types_globals_constants;
473 }472 }
...@@ -481,7 +480,7 @@ fn processGenericInstruction(self: *Assembler) !?AsmValue {...@@ -481,7 +480,7 @@ fn processGenericInstruction(self: *Assembler) !?AsmValue {
481 },480 },
482 };481 };
483482
484 var maybe_result_id: ?IdResult = null;483 var maybe_result_id: ?Id = null;
485 const first_word = section.instructions.items.len;484 const first_word = section.instructions.items.len;
486 // At this point we're not quite sure how many operands this instruction is going to have,485 // At this point we're not quite sure how many operands this instruction is going to have,
487 // so insert 0 and patch up the actual opcode word later.486 // so insert 0 and patch up the actual opcode word later.
...@@ -504,12 +503,12 @@ fn processGenericInstruction(self: *Assembler) !?AsmValue {...@@ -504,12 +503,12 @@ fn processGenericInstruction(self: *Assembler) !?AsmValue {
504 else503 else
505 self.spv.allocId();504 self.spv.allocId();
506 try section.ensureUnusedCapacity(self.spv.gpa, 1);505 try section.ensureUnusedCapacity(self.spv.gpa, 1);
507 section.writeOperand(IdResult, maybe_result_id.?);506 section.writeOperand(Id, maybe_result_id.?);
508 },507 },
509 .ref_id => |index| {508 .ref_id => |index| {
510 const result = try self.resolveRef(index);509 const result = try self.resolveRef(index);
511 try section.ensureUnusedCapacity(self.spv.gpa, 1);510 try section.ensureUnusedCapacity(self.spv.gpa, 1);
512 section.writeOperand(spec.IdRef, result.resultId());511 section.writeOperand(spec.Id, result.resultId());
513 },512 },
514 .string => |offset| {513 .string => |offset| {
515 const text = std.mem.sliceTo(self.inst.string_bytes.items[offset..], 0);514 const text = std.mem.sliceTo(self.inst.string_bytes.items[offset..], 0);
...@@ -558,7 +557,7 @@ fn resolveRef(self: *Assembler, ref: AsmValue.Ref) !AsmValue {...@@ -558,7 +557,7 @@ fn resolveRef(self: *Assembler, ref: AsmValue.Ref) !AsmValue {
558 }557 }
559}558}
560559
561fn resolveRefId(self: *Assembler, ref: AsmValue.Ref) !IdRef {560fn resolveRefId(self: *Assembler, ref: AsmValue.Ref) !Id {
562 const value = try self.resolveRef(ref);561 const value = try self.resolveRef(ref);
563 return value.resultId();562 return value.resultId();
564}563}
...@@ -600,7 +599,7 @@ fn parseInstruction(self: *Assembler) !void {...@@ -600,7 +599,7 @@ fn parseInstruction(self: *Assembler) !void {
600 const expected_operands = inst.operands;599 const expected_operands = inst.operands;
601 // This is a loop because the result-id is not always the first operand.600 // This is a loop because the result-id is not always the first operand.
602 const requires_lhs_result = for (expected_operands) |op| {601 const requires_lhs_result = for (expected_operands) |op| {
603 if (op.kind == .IdResult) break true;602 if (op.kind == .id_result) break true;
604 } else false;603 } else false;
605604
606 if (requires_lhs_result and maybe_lhs_result == null) {605 if (requires_lhs_result and maybe_lhs_result == null) {
...@@ -614,7 +613,7 @@ fn parseInstruction(self: *Assembler) !void {...@@ -614,7 +613,7 @@ fn parseInstruction(self: *Assembler) !void {
614 }613 }
615614
616 for (expected_operands) |operand| {615 for (expected_operands) |operand| {
617 if (operand.kind == .IdResult) {616 if (operand.kind == .id_result) {
618 try self.inst.operands.append(self.gpa, .{ .result_id = maybe_lhs_result.? });617 try self.inst.operands.append(self.gpa, .{ .result_id = maybe_lhs_result.? });
619 continue;618 continue;
620 }619 }
...@@ -646,11 +645,11 @@ fn parseOperand(self: *Assembler, kind: spec.OperandKind) Error!void {...@@ -646,11 +645,11 @@ fn parseOperand(self: *Assembler, kind: spec.OperandKind) Error!void {
646 .value_enum => try self.parseValueEnum(kind),645 .value_enum => try self.parseValueEnum(kind),
647 .id => try self.parseRefId(),646 .id => try self.parseRefId(),
648 else => switch (kind) {647 else => switch (kind) {
649 .LiteralInteger => try self.parseLiteralInteger(),648 .literal_integer => try self.parseLiteralInteger(),
650 .LiteralString => try self.parseString(),649 .literal_string => try self.parseString(),
651 .LiteralContextDependentNumber => try self.parseContextDependentNumber(),650 .literal_context_dependent_number => try self.parseContextDependentNumber(),
652 .LiteralExtInstInteger => try self.parseLiteralExtInstInteger(),651 .literal_ext_inst_integer => try self.parseLiteralExtInstInteger(),
653 .PairIdRefIdRef => try self.parsePhiSource(),652 .pair_id_ref_id_ref => try self.parsePhiSource(),
654 else => return self.todo("parse operand of type {s}", .{@tagName(kind)}),653 else => return self.todo("parse operand of type {s}", .{@tagName(kind)}),
655 },654 },
656 }655 }
src/codegen/spirv/Module.zig+68-70
...@@ -15,9 +15,7 @@ const Wyhash = std.hash.Wyhash;...@@ -15,9 +15,7 @@ const Wyhash = std.hash.Wyhash;
1515
16const spec = @import("spec.zig");16const spec = @import("spec.zig");
17const Word = spec.Word;17const Word = spec.Word;
18const IdRef = spec.IdRef;18const Id = spec.Id;
19const IdResult = spec.IdResult;
20const IdResultType = spec.IdResultType;
2119
22const Section = @import("Section.zig");20const Section = @import("Section.zig");
2321
...@@ -82,7 +80,7 @@ pub const Decl = struct {...@@ -82,7 +80,7 @@ pub const Decl = struct {
82 /// - For `func`, this is the result-id of the associated OpFunction instruction.80 /// - For `func`, this is the result-id of the associated OpFunction instruction.
83 /// - For `global`, this is the result-id of the associated OpVariable instruction.81 /// - For `global`, this is the result-id of the associated OpVariable instruction.
84 /// - For `invocation_global`, this is the result-id of the associated InvocationGlobal instruction.82 /// - For `invocation_global`, this is the result-id of the associated InvocationGlobal instruction.
85 result_id: IdRef,83 result_id: Id,
86 /// The offset of the first dependency of this decl in the `decl_deps` array.84 /// The offset of the first dependency of this decl in the `decl_deps` array.
87 begin_dep: u32,85 begin_dep: u32,
88 /// The past-end offset of the dependencies of this decl in the `decl_deps` array.86 /// The past-end offset of the dependencies of this decl in the `decl_deps` array.
...@@ -150,7 +148,7 @@ sections: struct {...@@ -150,7 +148,7 @@ sections: struct {
150next_result_id: Word,148next_result_id: Word,
151149
152/// Cache for results of OpString instructions.150/// Cache for results of OpString instructions.
153strings: std.StringArrayHashMapUnmanaged(IdRef) = .empty,151strings: std.StringArrayHashMapUnmanaged(Id) = .empty,
154152
155/// Some types shouldn't be emitted more than one time, but cannot be caught by153/// Some types shouldn't be emitted more than one time, but cannot be caught by
156/// the `intern_map` during codegen. Sometimes, IDs are compared to check if154/// the `intern_map` during codegen. Sometimes, IDs are compared to check if
...@@ -161,20 +159,20 @@ strings: std.StringArrayHashMapUnmanaged(IdRef) = .empty,...@@ -161,20 +159,20 @@ strings: std.StringArrayHashMapUnmanaged(IdRef) = .empty,
161/// Additionally, this is used for other values which can be cached, for example,159/// Additionally, this is used for other values which can be cached, for example,
162/// built-in variables.160/// built-in variables.
163cache: struct {161cache: struct {
164 bool_type: ?IdRef = null,162 bool_type: ?Id = null,
165 void_type: ?IdRef = null,163 void_type: ?Id = null,
166 int_types: std.AutoHashMapUnmanaged(std.builtin.Type.Int, IdRef) = .empty,164 int_types: std.AutoHashMapUnmanaged(std.builtin.Type.Int, Id) = .empty,
167 float_types: std.AutoHashMapUnmanaged(std.builtin.Type.Float, IdRef) = .empty,165 float_types: std.AutoHashMapUnmanaged(std.builtin.Type.Float, Id) = .empty,
168 vector_types: std.AutoHashMapUnmanaged(struct { IdRef, u32 }, IdRef) = .empty,166 vector_types: std.AutoHashMapUnmanaged(struct { Id, u32 }, Id) = .empty,
169 array_types: std.AutoHashMapUnmanaged(struct { IdRef, IdRef }, IdRef) = .empty,167 array_types: std.AutoHashMapUnmanaged(struct { Id, Id }, Id) = .empty,
170168
171 capabilities: std.AutoHashMapUnmanaged(spec.Capability, void) = .empty,169 capabilities: std.AutoHashMapUnmanaged(spec.Capability, void) = .empty,
172 extensions: std.StringHashMapUnmanaged(void) = .empty,170 extensions: std.StringHashMapUnmanaged(void) = .empty,
173 extended_instruction_set: std.AutoHashMapUnmanaged(spec.InstructionSet, IdRef) = .empty,171 extended_instruction_set: std.AutoHashMapUnmanaged(spec.InstructionSet, Id) = .empty,
174 decorations: std.AutoHashMapUnmanaged(struct { IdRef, spec.Decoration }, void) = .empty,172 decorations: std.AutoHashMapUnmanaged(struct { Id, spec.Decoration }, void) = .empty,
175 builtins: std.AutoHashMapUnmanaged(struct { IdRef, spec.BuiltIn }, Decl.Index) = .empty,173 builtins: std.AutoHashMapUnmanaged(struct { Id, spec.BuiltIn }, Decl.Index) = .empty,
176174
177 bool_const: [2]?IdRef = .{ null, null },175 bool_const: [2]?Id = .{ null, null },
178} = .{},176} = .{},
179177
180/// Set of Decls, referred to by Decl.Index.178/// Set of Decls, referred to by Decl.Index.
...@@ -185,7 +183,7 @@ decls: std.ArrayListUnmanaged(Decl) = .empty,...@@ -185,7 +183,7 @@ decls: std.ArrayListUnmanaged(Decl) = .empty,
185decl_deps: std.ArrayListUnmanaged(Decl.Index) = .empty,183decl_deps: std.ArrayListUnmanaged(Decl.Index) = .empty,
186184
187/// The list of entry points that should be exported from this module.185/// The list of entry points that should be exported from this module.
188entry_points: std.AutoArrayHashMapUnmanaged(IdRef, EntryPoint) = .empty,186entry_points: std.AutoArrayHashMapUnmanaged(Id, EntryPoint) = .empty,
189187
190pub fn init(gpa: Allocator, target: *const std.Target) Module {188pub fn init(gpa: Allocator, target: *const std.Target) Module {
191 const version_minor: u8 = blk: {189 const version_minor: u8 = blk: {
...@@ -245,7 +243,7 @@ pub const IdRange = struct {...@@ -245,7 +243,7 @@ pub const IdRange = struct {
245 base: u32,243 base: u32,
246 len: u32,244 len: u32,
247245
248 pub fn at(range: IdRange, i: usize) IdResult {246 pub fn at(range: IdRange, i: usize) Id {
249 assert(i < range.len);247 assert(i < range.len);
250 return @enumFromInt(range.base + i);248 return @enumFromInt(range.base + i);
251 }249 }
...@@ -259,7 +257,7 @@ pub fn allocIds(self: *Module, n: u32) IdRange {...@@ -259,7 +257,7 @@ pub fn allocIds(self: *Module, n: u32) IdRange {
259 };257 };
260}258}
261259
262pub fn allocId(self: *Module) IdResult {260pub fn allocId(self: *Module) Id {
263 return self.allocIds(1).at(0);261 return self.allocIds(1).at(0);
264}262}
265263
...@@ -275,7 +273,7 @@ fn addEntryPointDeps(...@@ -275,7 +273,7 @@ fn addEntryPointDeps(
275 self: *Module,273 self: *Module,
276 decl_index: Decl.Index,274 decl_index: Decl.Index,
277 seen: *std.DynamicBitSetUnmanaged,275 seen: *std.DynamicBitSetUnmanaged,
278 interface: *std.ArrayList(IdRef),276 interface: *std.ArrayList(Id),
279) !void {277) !void {
280 const decl = self.declPtr(decl_index);278 const decl = self.declPtr(decl_index);
281 const deps = self.decl_deps.items[decl.begin_dep..decl.end_dep];279 const deps = self.decl_deps.items[decl.begin_dep..decl.end_dep];
...@@ -299,7 +297,7 @@ fn entryPoints(self: *Module) !Section {...@@ -299,7 +297,7 @@ fn entryPoints(self: *Module) !Section {
299 var entry_points = Section{};297 var entry_points = Section{};
300 errdefer entry_points.deinit(self.gpa);298 errdefer entry_points.deinit(self.gpa);
301299
302 var interface = std.ArrayList(IdRef).init(self.gpa);300 var interface = std.ArrayList(Id).init(self.gpa);
303 defer interface.deinit();301 defer interface.deinit();
304302
305 var seen = try std.DynamicBitSetUnmanaged.initEmpty(self.gpa, self.decls.items.len);303 var seen = try std.DynamicBitSetUnmanaged.initEmpty(self.gpa, self.decls.items.len);
...@@ -317,12 +315,12 @@ fn entryPoints(self: *Module) !Section {...@@ -317,12 +315,12 @@ fn entryPoints(self: *Module) !Section {
317 .interface = interface.items,315 .interface = interface.items,
318 });316 });
319317
320 if (entry_point.exec_mode == null and entry_point.exec_model == .Fragment) {318 if (entry_point.exec_mode == null and entry_point.exec_model == .fragment) {
321 switch (self.target.os.tag) {319 switch (self.target.os.tag) {
322 .vulkan, .opengl => |tag| {320 .vulkan, .opengl => |tag| {
323 try self.sections.execution_modes.emit(self.gpa, .OpExecutionMode, .{321 try self.sections.execution_modes.emit(self.gpa, .OpExecutionMode, .{
324 .entry_point = entry_point_id,322 .entry_point = entry_point_id,
325 .mode = if (tag == .vulkan) .OriginUpperLeft else .OriginLowerLeft,323 .mode = if (tag == .vulkan) .origin_upper_left else .origin_lower_left,
326 });324 });
327 },325 },
328 .opencl => {},326 .opencl => {},
...@@ -338,59 +336,59 @@ pub fn finalize(self: *Module, a: Allocator) ![]Word {...@@ -338,59 +336,59 @@ pub fn finalize(self: *Module, a: Allocator) ![]Word {
338 // Emit capabilities and extensions336 // Emit capabilities and extensions
339 switch (self.target.os.tag) {337 switch (self.target.os.tag) {
340 .opengl => {338 .opengl => {
341 try self.addCapability(.Shader);339 try self.addCapability(.shader);
342 try self.addCapability(.Matrix);340 try self.addCapability(.matrix);
343 },341 },
344 .vulkan => {342 .vulkan => {
345 try self.addCapability(.Shader);343 try self.addCapability(.shader);
346 try self.addCapability(.Matrix);344 try self.addCapability(.matrix);
347 if (self.target.cpu.arch == .spirv64) {345 if (self.target.cpu.arch == .spirv64) {
348 try self.addExtension("SPV_KHR_physical_storage_buffer");346 try self.addExtension("SPV_KHR_physical_storage_buffer");
349 try self.addCapability(.PhysicalStorageBufferAddresses);347 try self.addCapability(.physical_storage_buffer_addresses);
350 }348 }
351 },349 },
352 .opencl, .amdhsa => {350 .opencl, .amdhsa => {
353 try self.addCapability(.Kernel);351 try self.addCapability(.kernel);
354 try self.addCapability(.Addresses);352 try self.addCapability(.addresses);
355 },353 },
356 else => unreachable,354 else => unreachable,
357 }355 }
358 if (self.target.cpu.arch == .spirv64) try self.addCapability(.Int64);356 if (self.target.cpu.arch == .spirv64) try self.addCapability(.int64);
359 if (self.target.cpu.has(.spirv, .int64)) try self.addCapability(.Int64);357 if (self.target.cpu.has(.spirv, .int64)) try self.addCapability(.int64);
360 if (self.target.cpu.has(.spirv, .float16)) try self.addCapability(.Float16);358 if (self.target.cpu.has(.spirv, .float16)) try self.addCapability(.float16);
361 if (self.target.cpu.has(.spirv, .float64)) try self.addCapability(.Float64);359 if (self.target.cpu.has(.spirv, .float64)) try self.addCapability(.float64);
362 if (self.target.cpu.has(.spirv, .generic_pointer)) try self.addCapability(.GenericPointer);360 if (self.target.cpu.has(.spirv, .generic_pointer)) try self.addCapability(.generic_pointer);
363 if (self.target.cpu.has(.spirv, .vector16)) try self.addCapability(.Vector16);361 if (self.target.cpu.has(.spirv, .vector16)) try self.addCapability(.vector16);
364 if (self.target.cpu.has(.spirv, .storage_push_constant16)) {362 if (self.target.cpu.has(.spirv, .storage_push_constant16)) {
365 try self.addExtension("SPV_KHR_16bit_storage");363 try self.addExtension("SPV_KHR_16bit_storage");
366 try self.addCapability(.StoragePushConstant16);364 try self.addCapability(.storage_push_constant16);
367 }365 }
368 if (self.target.cpu.has(.spirv, .arbitrary_precision_integers)) {366 if (self.target.cpu.has(.spirv, .arbitrary_precision_integers)) {
369 try self.addExtension("SPV_INTEL_arbitrary_precision_integers");367 try self.addExtension("SPV_INTEL_arbitrary_precision_integers");
370 try self.addCapability(.ArbitraryPrecisionIntegersINTEL);368 try self.addCapability(.arbitrary_precision_integers_intel);
371 }369 }
372 if (self.target.cpu.has(.spirv, .variable_pointers)) {370 if (self.target.cpu.has(.spirv, .variable_pointers)) {
373 try self.addExtension("SPV_KHR_variable_pointers");371 try self.addExtension("SPV_KHR_variable_pointers");
374 try self.addCapability(.VariablePointersStorageBuffer);372 try self.addCapability(.variable_pointers_storage_buffer);
375 try self.addCapability(.VariablePointers);373 try self.addCapability(.variable_pointers);
376 }374 }
377 // These are well supported375 // These are well supported
378 try self.addCapability(.Int8);376 try self.addCapability(.int8);
379 try self.addCapability(.Int16);377 try self.addCapability(.int16);
380378
381 // Emit memory model379 // Emit memory model
382 const addressing_model: spec.AddressingModel = switch (self.target.os.tag) {380 const addressing_model: spec.AddressingModel = switch (self.target.os.tag) {
383 .opengl => .Logical,381 .opengl => .logical,
384 .vulkan => if (self.target.cpu.arch == .spirv32) .Logical else .PhysicalStorageBuffer64,382 .vulkan => if (self.target.cpu.arch == .spirv32) .logical else .physical_storage_buffer64,
385 .opencl => if (self.target.cpu.arch == .spirv32) .Physical32 else .Physical64,383 .opencl => if (self.target.cpu.arch == .spirv32) .physical32 else .physical64,
386 .amdhsa => .Physical64,384 .amdhsa => .physical64,
387 else => unreachable,385 else => unreachable,
388 };386 };
389 try self.sections.memory_model.emit(self.gpa, .OpMemoryModel, .{387 try self.sections.memory_model.emit(self.gpa, .OpMemoryModel, .{
390 .addressing_model = addressing_model,388 .addressing_model = addressing_model,
391 .memory_model = switch (self.target.os.tag) {389 .memory_model = switch (self.target.os.tag) {
392 .opencl => .OpenCL,390 .opencl => .open_cl,
393 .vulkan, .opengl => .GLSL450,391 .vulkan, .opengl => .glsl450,
394 else => unreachable,392 else => unreachable,
395 },393 },
396 });394 });
...@@ -411,7 +409,7 @@ pub fn finalize(self: *Module, a: Allocator) ![]Word {...@@ -411,7 +409,7 @@ pub fn finalize(self: *Module, a: Allocator) ![]Word {
411 var source = Section{};409 var source = Section{};
412 defer source.deinit(self.gpa);410 defer source.deinit(self.gpa);
413 try self.sections.debug_strings.emit(self.gpa, .OpSource, .{411 try self.sections.debug_strings.emit(self.gpa, .OpSource, .{
414 .source_language = .Zig,412 .source_language = .zig,
415 .version = 0,413 .version = 0,
416 // We cannot emit these because the Khronos translator does not parse this instruction414 // We cannot emit these because the Khronos translator does not parse this instruction
417 // correctly.415 // correctly.
...@@ -473,7 +471,7 @@ pub fn addExtension(self: *Module, ext: []const u8) !void {...@@ -473,7 +471,7 @@ pub fn addExtension(self: *Module, ext: []const u8) !void {
473}471}
474472
475/// Imports or returns the existing id of an extended instruction set473/// Imports or returns the existing id of an extended instruction set
476pub fn importInstructionSet(self: *Module, set: spec.InstructionSet) !IdRef {474pub fn importInstructionSet(self: *Module, set: spec.InstructionSet) !Id {
477 assert(set != .core);475 assert(set != .core);
478476
479 const gop = try self.cache.extended_instruction_set.getOrPut(self.gpa, set);477 const gop = try self.cache.extended_instruction_set.getOrPut(self.gpa, set);
...@@ -490,7 +488,7 @@ pub fn importInstructionSet(self: *Module, set: spec.InstructionSet) !IdRef {...@@ -490,7 +488,7 @@ pub fn importInstructionSet(self: *Module, set: spec.InstructionSet) !IdRef {
490}488}
491489
492/// Fetch the result-id of an instruction corresponding to a string.490/// Fetch the result-id of an instruction corresponding to a string.
493pub fn resolveString(self: *Module, string: []const u8) !IdRef {491pub fn resolveString(self: *Module, string: []const u8) !Id {
494 if (self.strings.get(string)) |id| {492 if (self.strings.get(string)) |id| {
495 return id;493 return id;
496 }494 }
...@@ -506,7 +504,7 @@ pub fn resolveString(self: *Module, string: []const u8) !IdRef {...@@ -506,7 +504,7 @@ pub fn resolveString(self: *Module, string: []const u8) !IdRef {
506 return id;504 return id;
507}505}
508506
509pub fn structType(self: *Module, result_id: IdResult, types: []const IdRef, maybe_names: ?[]const []const u8) !void {507pub fn structType(self: *Module, result_id: Id, types: []const Id, maybe_names: ?[]const []const u8) !void {
510 try self.sections.types_globals_constants.emit(self.gpa, .OpTypeStruct, .{508 try self.sections.types_globals_constants.emit(self.gpa, .OpTypeStruct, .{
511 .id_result = result_id,509 .id_result = result_id,
512 .id_ref = types,510 .id_ref = types,
...@@ -520,7 +518,7 @@ pub fn structType(self: *Module, result_id: IdResult, types: []const IdRef, mayb...@@ -520,7 +518,7 @@ pub fn structType(self: *Module, result_id: IdResult, types: []const IdRef, mayb
520 }518 }
521}519}
522520
523pub fn boolType(self: *Module) !IdRef {521pub fn boolType(self: *Module) !Id {
524 if (self.cache.bool_type) |id| return id;522 if (self.cache.bool_type) |id| return id;
525523
526 const result_id = self.allocId();524 const result_id = self.allocId();
...@@ -531,7 +529,7 @@ pub fn boolType(self: *Module) !IdRef {...@@ -531,7 +529,7 @@ pub fn boolType(self: *Module) !IdRef {
531 return result_id;529 return result_id;
532}530}
533531
534pub fn voidType(self: *Module) !IdRef {532pub fn voidType(self: *Module) !Id {
535 if (self.cache.void_type) |id| return id;533 if (self.cache.void_type) |id| return id;
536534
537 const result_id = self.allocId();535 const result_id = self.allocId();
...@@ -543,7 +541,7 @@ pub fn voidType(self: *Module) !IdRef {...@@ -543,7 +541,7 @@ pub fn voidType(self: *Module) !IdRef {
543 return result_id;541 return result_id;
544}542}
545543
546pub fn intType(self: *Module, signedness: std.builtin.Signedness, bits: u16) !IdRef {544pub fn intType(self: *Module, signedness: std.builtin.Signedness, bits: u16) !Id {
547 assert(bits > 0);545 assert(bits > 0);
548 const entry = try self.cache.int_types.getOrPut(self.gpa, .{ .signedness = signedness, .bits = bits });546 const entry = try self.cache.int_types.getOrPut(self.gpa, .{ .signedness = signedness, .bits = bits });
549 if (!entry.found_existing) {547 if (!entry.found_existing) {
...@@ -566,7 +564,7 @@ pub fn intType(self: *Module, signedness: std.builtin.Signedness, bits: u16) !Id...@@ -566,7 +564,7 @@ pub fn intType(self: *Module, signedness: std.builtin.Signedness, bits: u16) !Id
566 return entry.value_ptr.*;564 return entry.value_ptr.*;
567}565}
568566
569pub fn floatType(self: *Module, bits: u16) !IdRef {567pub fn floatType(self: *Module, bits: u16) !Id {
570 assert(bits > 0);568 assert(bits > 0);
571 const entry = try self.cache.float_types.getOrPut(self.gpa, .{ .bits = bits });569 const entry = try self.cache.float_types.getOrPut(self.gpa, .{ .bits = bits });
572 if (!entry.found_existing) {570 if (!entry.found_existing) {
...@@ -581,7 +579,7 @@ pub fn floatType(self: *Module, bits: u16) !IdRef {...@@ -581,7 +579,7 @@ pub fn floatType(self: *Module, bits: u16) !IdRef {
581 return entry.value_ptr.*;579 return entry.value_ptr.*;
582}580}
583581
584pub fn vectorType(self: *Module, len: u32, child_ty_id: IdRef) !IdRef {582pub fn vectorType(self: *Module, len: u32, child_ty_id: Id) !Id {
585 const entry = try self.cache.vector_types.getOrPut(self.gpa, .{ child_ty_id, len });583 const entry = try self.cache.vector_types.getOrPut(self.gpa, .{ child_ty_id, len });
586 if (!entry.found_existing) {584 if (!entry.found_existing) {
587 const result_id = self.allocId();585 const result_id = self.allocId();
...@@ -595,7 +593,7 @@ pub fn vectorType(self: *Module, len: u32, child_ty_id: IdRef) !IdRef {...@@ -595,7 +593,7 @@ pub fn vectorType(self: *Module, len: u32, child_ty_id: IdRef) !IdRef {
595 return entry.value_ptr.*;593 return entry.value_ptr.*;
596}594}
597595
598pub fn arrayType(self: *Module, len_id: IdRef, child_ty_id: IdRef) !IdRef {596pub fn arrayType(self: *Module, len_id: Id, child_ty_id: Id) !Id {
599 const entry = try self.cache.array_types.getOrPut(self.gpa, .{ child_ty_id, len_id });597 const entry = try self.cache.array_types.getOrPut(self.gpa, .{ child_ty_id, len_id });
600 if (!entry.found_existing) {598 if (!entry.found_existing) {
601 const result_id = self.allocId();599 const result_id = self.allocId();
...@@ -609,7 +607,7 @@ pub fn arrayType(self: *Module, len_id: IdRef, child_ty_id: IdRef) !IdRef {...@@ -609,7 +607,7 @@ pub fn arrayType(self: *Module, len_id: IdRef, child_ty_id: IdRef) !IdRef {
609 return entry.value_ptr.*;607 return entry.value_ptr.*;
610}608}
611609
612pub fn functionType(self: *Module, return_ty_id: IdRef, param_type_ids: []const IdRef) !IdRef {610pub fn functionType(self: *Module, return_ty_id: Id, param_type_ids: []const Id) !Id {
613 const result_id = self.allocId();611 const result_id = self.allocId();
614 try self.sections.types_globals_constants.emit(self.gpa, .OpTypeFunction, .{612 try self.sections.types_globals_constants.emit(self.gpa, .OpTypeFunction, .{
615 .id_result = result_id,613 .id_result = result_id,
...@@ -619,7 +617,7 @@ pub fn functionType(self: *Module, return_ty_id: IdRef, param_type_ids: []const...@@ -619,7 +617,7 @@ pub fn functionType(self: *Module, return_ty_id: IdRef, param_type_ids: []const
619 return result_id;617 return result_id;
620}618}
621619
622pub fn constant(self: *Module, result_ty_id: IdRef, value: spec.LiteralContextDependentNumber) !IdRef {620pub fn constant(self: *Module, result_ty_id: Id, value: spec.LiteralContextDependentNumber) !Id {
623 const result_id = self.allocId();621 const result_id = self.allocId();
624 const section = &self.sections.types_globals_constants;622 const section = &self.sections.types_globals_constants;
625 try section.emit(self.gpa, .OpConstant, .{623 try section.emit(self.gpa, .OpConstant, .{
...@@ -630,7 +628,7 @@ pub fn constant(self: *Module, result_ty_id: IdRef, value: spec.LiteralContextDe...@@ -630,7 +628,7 @@ pub fn constant(self: *Module, result_ty_id: IdRef, value: spec.LiteralContextDe
630 return result_id;628 return result_id;
631}629}
632630
633pub fn constBool(self: *Module, value: bool) !IdRef {631pub fn constBool(self: *Module, value: bool) !Id {
634 if (self.cache.bool_const[@intFromBool(value)]) |b| return b;632 if (self.cache.bool_const[@intFromBool(value)]) |b| return b;
635633
636 const result_ty_id = try self.boolType();634 const result_ty_id = try self.boolType();
...@@ -653,7 +651,7 @@ pub fn constBool(self: *Module, value: bool) !IdRef {...@@ -653,7 +651,7 @@ pub fn constBool(self: *Module, value: bool) !IdRef {
653651
654/// Return a pointer to a builtin variable. `result_ty_id` must be a **pointer**652/// Return a pointer to a builtin variable. `result_ty_id` must be a **pointer**
655/// with storage class `.Input`.653/// with storage class `.Input`.
656pub fn builtin(self: *Module, result_ty_id: IdRef, spirv_builtin: spec.BuiltIn) !Decl.Index {654pub fn builtin(self: *Module, result_ty_id: Id, spirv_builtin: spec.BuiltIn) !Decl.Index {
657 const entry = try self.cache.builtins.getOrPut(self.gpa, .{ result_ty_id, spirv_builtin });655 const entry = try self.cache.builtins.getOrPut(self.gpa, .{ result_ty_id, spirv_builtin });
658 if (!entry.found_existing) {656 if (!entry.found_existing) {
659 const decl_index = try self.allocDecl(.global);657 const decl_index = try self.allocDecl(.global);
...@@ -662,15 +660,15 @@ pub fn builtin(self: *Module, result_ty_id: IdRef, spirv_builtin: spec.BuiltIn)...@@ -662,15 +660,15 @@ pub fn builtin(self: *Module, result_ty_id: IdRef, spirv_builtin: spec.BuiltIn)
662 try self.sections.types_globals_constants.emit(self.gpa, .OpVariable, .{660 try self.sections.types_globals_constants.emit(self.gpa, .OpVariable, .{
663 .id_result_type = result_ty_id,661 .id_result_type = result_ty_id,
664 .id_result = result_id,662 .id_result = result_id,
665 .storage_class = .Input,663 .storage_class = .input,
666 });664 });
667 try self.decorate(result_id, .{ .BuiltIn = .{ .built_in = spirv_builtin } });665 try self.decorate(result_id, .{ .built_in = .{ .built_in = spirv_builtin } });
668 try self.declareDeclDeps(decl_index, &.{});666 try self.declareDeclDeps(decl_index, &.{});
669 }667 }
670 return entry.value_ptr.*;668 return entry.value_ptr.*;
671}669}
672670
673pub fn constUndef(self: *Module, ty_id: IdRef) !IdRef {671pub fn constUndef(self: *Module, ty_id: Id) !Id {
674 const result_id = self.allocId();672 const result_id = self.allocId();
675 try self.sections.types_globals_constants.emit(self.gpa, .OpUndef, .{673 try self.sections.types_globals_constants.emit(self.gpa, .OpUndef, .{
676 .id_result_type = ty_id,674 .id_result_type = ty_id,
...@@ -679,7 +677,7 @@ pub fn constUndef(self: *Module, ty_id: IdRef) !IdRef {...@@ -679,7 +677,7 @@ pub fn constUndef(self: *Module, ty_id: IdRef) !IdRef {
679 return result_id;677 return result_id;
680}678}
681679
682pub fn constNull(self: *Module, ty_id: IdRef) !IdRef {680pub fn constNull(self: *Module, ty_id: Id) !Id {
683 const result_id = self.allocId();681 const result_id = self.allocId();
684 try self.sections.types_globals_constants.emit(self.gpa, .OpConstantNull, .{682 try self.sections.types_globals_constants.emit(self.gpa, .OpConstantNull, .{
685 .id_result_type = ty_id,683 .id_result_type = ty_id,
...@@ -691,7 +689,7 @@ pub fn constNull(self: *Module, ty_id: IdRef) !IdRef {...@@ -691,7 +689,7 @@ pub fn constNull(self: *Module, ty_id: IdRef) !IdRef {
691/// Decorate a result-id.689/// Decorate a result-id.
692pub fn decorate(690pub fn decorate(
693 self: *Module,691 self: *Module,
694 target: IdRef,692 target: Id,
695 decoration: spec.Decoration.Extended,693 decoration: spec.Decoration.Extended,
696) !void {694) !void {
697 const entry = try self.cache.decorations.getOrPut(self.gpa, .{ target, decoration });695 const entry = try self.cache.decorations.getOrPut(self.gpa, .{ target, decoration });
...@@ -707,7 +705,7 @@ pub fn decorate(...@@ -707,7 +705,7 @@ pub fn decorate(
707/// We really don't have to and shouldn't need to cache this.705/// We really don't have to and shouldn't need to cache this.
708pub fn decorateMember(706pub fn decorateMember(
709 self: *Module,707 self: *Module,
710 structure_type: IdRef,708 structure_type: Id,
711 member: u32,709 member: u32,
712 decoration: spec.Decoration.Extended,710 decoration: spec.Decoration.Extended,
713) !void {711) !void {
...@@ -762,20 +760,20 @@ pub fn declareEntryPoint(...@@ -762,20 +760,20 @@ pub fn declareEntryPoint(
762 if (!gop.found_existing) gop.value_ptr.exec_mode = exec_mode;760 if (!gop.found_existing) gop.value_ptr.exec_mode = exec_mode;
763}761}
764762
765pub fn debugName(self: *Module, target: IdResult, name: []const u8) !void {763pub fn debugName(self: *Module, target: Id, name: []const u8) !void {
766 try self.sections.debug_names.emit(self.gpa, .OpName, .{764 try self.sections.debug_names.emit(self.gpa, .OpName, .{
767 .target = target,765 .target = target,
768 .name = name,766 .name = name,
769 });767 });
770}768}
771769
772pub fn debugNameFmt(self: *Module, target: IdResult, comptime fmt: []const u8, args: anytype) !void {770pub fn debugNameFmt(self: *Module, target: Id, comptime fmt: []const u8, args: anytype) !void {
773 const name = try std.fmt.allocPrint(self.gpa, fmt, args);771 const name = try std.fmt.allocPrint(self.gpa, fmt, args);
774 defer self.gpa.free(name);772 defer self.gpa.free(name);
775 try self.debugName(target, name);773 try self.debugName(target, name);
776}774}
777775
778pub fn memberDebugName(self: *Module, target: IdResult, member: u32, name: []const u8) !void {776pub fn memberDebugName(self: *Module, target: Id, member: u32, name: []const u8) !void {
779 try self.sections.debug_names.emit(self.gpa, .OpMemberName, .{777 try self.sections.debug_names.emit(self.gpa, .OpMemberName, .{
780 .type = target,778 .type = target,
781 .member = member,779 .member = member,
src/codegen/spirv/Section.zig+5-5
...@@ -79,7 +79,7 @@ pub fn emit(...@@ -79,7 +79,7 @@ pub fn emit(
79pub fn emitBranch(79pub fn emitBranch(
80 section: *Section,80 section: *Section,
81 allocator: Allocator,81 allocator: Allocator,
82 target_label: spec.IdRef,82 target_label: spec.Id,
83) !void {83) !void {
84 try section.emit(allocator, .OpBranch, .{84 try section.emit(allocator, .OpBranch, .{
85 .target_label = target_label,85 .target_label = target_label,
...@@ -94,8 +94,8 @@ pub fn emitSpecConstantOp(...@@ -94,8 +94,8 @@ pub fn emitSpecConstantOp(
94) !void {94) !void {
95 const word_count = operandsSize(opcode.Operands(), operands);95 const word_count = operandsSize(opcode.Operands(), operands);
96 try section.emitRaw(allocator, .OpSpecConstantOp, 1 + word_count);96 try section.emitRaw(allocator, .OpSpecConstantOp, 1 + word_count);
97 section.writeOperand(spec.IdRef, operands.id_result_type);97 section.writeOperand(spec.Id, operands.id_result_type);
98 section.writeOperand(spec.IdRef, operands.id_result);98 section.writeOperand(spec.Id, operands.id_result);
99 section.writeOperand(Opcode, opcode);99 section.writeOperand(Opcode, opcode);
100100
101 const fields = @typeInfo(opcode.Operands()).@"struct".fields;101 const fields = @typeInfo(opcode.Operands()).@"struct".fields;
...@@ -134,7 +134,7 @@ fn writeOperands(section: *Section, comptime Operands: type, operands: Operands)...@@ -134,7 +134,7 @@ fn writeOperands(section: *Section, comptime Operands: type, operands: Operands)
134134
135pub fn writeOperand(section: *Section, comptime Operand: type, operand: Operand) void {135pub fn writeOperand(section: *Section, comptime Operand: type, operand: Operand) void {
136 switch (Operand) {136 switch (Operand) {
137 spec.IdResult => section.writeWord(@intFromEnum(operand)),137 spec.Id => section.writeWord(@intFromEnum(operand)),
138138
139 spec.LiteralInteger => section.writeWord(operand),139 spec.LiteralInteger => section.writeWord(operand),
140140
...@@ -266,7 +266,7 @@ fn operandsSize(comptime Operands: type, operands: Operands) usize {...@@ -266,7 +266,7 @@ fn operandsSize(comptime Operands: type, operands: Operands) usize {
266266
267fn operandSize(comptime Operand: type, operand: Operand) usize {267fn operandSize(comptime Operand: type, operand: Operand) usize {
268 return switch (Operand) {268 return switch (Operand) {
269 spec.IdResult,269 spec.Id,
270 spec.LiteralInteger,270 spec.LiteralInteger,
271 spec.LiteralExtInstInteger,271 spec.LiteralExtInstInteger,
272 => 1,272 => 1,
src/codegen/spirv/extinst.zig.grammar.json+9-11
...@@ -1,13 +1,11 @@...@@ -1,13 +1,11 @@
1{1{
2 "version": 0,2 "version": 0,
3 "revision": 0,3 "revision": 0,
4 "instructions": [4 "instructions": [
5 {5 {
6 "opname": "InvocationGlobal",6 "opname": "InvocationGlobal",
7 "opcode": 0,7 "opcode": 0,
8 "operands": [8 "operands": [{ "kind": "IdRef", "name": "initializer function" }]
9 { "kind": "IdRef", "name": "initializer function" }9 }
10 ]10 ]
11 }
12 ]
13}11}
src/codegen/spirv/spec.zig+11928-10043
...@@ -1,7 +1,6 @@...@@ -1,7 +1,6 @@
1//! This file is auto-generated by tools/gen_spirv_spec.zig.1//! This file is auto-generated by tools/gen_spirv_spec.zig.
22
3const std = @import("std");3const std = @import("std");
4const assert = std.debug.assert;
54
6pub const Version = packed struct(Word) {5pub const Version = packed struct(Word) {
7 padding: u8 = 0,6 padding: u8 = 0,
...@@ -15,22 +14,17 @@ pub const Version = packed struct(Word) {...@@ -15,22 +14,17 @@ pub const Version = packed struct(Word) {
15};14};
1615
17pub const Word = u32;16pub const Word = u32;
18pub const IdResult = enum(Word) {17pub const Id = enum(Word) {
19 none,18 none,
20 _,19 _,
2120
22 pub fn format(self: IdResult, writer: *std.io.Writer) std.io.Writer.Error!void {21 pub fn format(self: Id, writer: *std.io.Writer) std.io.Writer.Error!void {
23 switch (self) {22 switch (self) {
24 .none => try writer.writeAll("(none)"),23 .none => try writer.writeAll("(none)"),
25 else => try writer.print("%{d}", .{@intFromEnum(self)}),24 else => try writer.print("%{d}", .{@intFromEnum(self)}),
26 }25 }
27 }26 }
28};27};
29pub const IdResultType = IdResult;
30pub const IdRef = IdResult;
31
32pub const IdMemorySemantics = IdRef;
33pub const IdScope = IdRef;
3428
35pub const LiteralInteger = Word;29pub const LiteralInteger = Word;
36pub const LiteralFloat = Word;30pub const LiteralFloat = Word;
...@@ -45,9 +39,9 @@ pub const LiteralContextDependentNumber = union(enum) {...@@ -45,9 +39,9 @@ pub const LiteralContextDependentNumber = union(enum) {
45};39};
46pub const LiteralExtInstInteger = struct { inst: Word };40pub const LiteralExtInstInteger = struct { inst: Word };
47pub const LiteralSpecConstantOpInteger = struct { opcode: Opcode };41pub const LiteralSpecConstantOpInteger = struct { opcode: Opcode };
48pub const PairLiteralIntegerIdRef = struct { value: LiteralInteger, label: IdRef };42pub const PairLiteralIntegerIdRef = struct { value: LiteralInteger, label: Id };
49pub const PairIdRefLiteralInteger = struct { target: IdRef, member: LiteralInteger };43pub const PairIdRefLiteralInteger = struct { target: Id, member: LiteralInteger };
50pub const PairIdRefIdRef = [2]IdRef;44pub const PairIdRefIdRef = [2]Id;
5145
52pub const Quantifier = enum {46pub const Quantifier = enum {
53 required,47 required,
...@@ -81,1499 +75,1564 @@ pub const Instruction = struct {...@@ -81,1499 +75,1564 @@ pub const Instruction = struct {
81};75};
8276
83pub const zig_generator_id: Word = 41;77pub const zig_generator_id: Word = 41;
84pub const version = Version{ .major = 1, .minor = 6, .patch = 1 };78pub const version: Version = .{ .major = 1, .minor = 6, .patch = 4 };
85pub const magic_number: Word = 0x07230203;79pub const magic_number: Word = 0x07230203;
8680
87pub const Class = enum {81pub const Class = enum {
88 Miscellaneous,82 miscellaneous,
89 Debug,83 debug,
90 Extension,84 extension,
91 ModeSetting,85 mode_setting,
92 TypeDeclaration,86 type_declaration,
93 ConstantCreation,87 constant_creation,
94 Function,88 function,
95 Memory,89 memory,
96 Annotation,90 annotation,
97 Composite,91 composite,
98 Image,92 image,
99 Conversion,93 conversion,
100 Arithmetic,94 arithmetic,
101 RelationalAndLogical,95 relational_and_logical,
102 Bit,96 bit,
103 Derivative,97 derivative,
104 Primitive,98 primitive,
105 Barrier,99 barrier,
106 Atomic,100 atomic,
107 ControlFlow,101 control_flow,
108 Group,102 group,
109 Pipe,103 pipe,
110 DeviceSideEnqueue,104 device_side_enqueue,
111 NonUniform,105 non_uniform,
112 Reserved,106 tensor,
107 graph,
108 reserved,
113};109};
114110
115pub const OperandKind = enum {111pub const OperandKind = enum {
116 Opcode,112 opcode,
117 ImageOperands,113 image_operands,
118 FPFastMathMode,114 fp_fast_math_mode,
119 SelectionControl,115 selection_control,
120 LoopControl,116 loop_control,
121 FunctionControl,117 function_control,
122 MemorySemantics,118 memory_semantics,
123 MemoryAccess,119 memory_access,
124 KernelProfilingInfo,120 kernel_profiling_info,
125 RayFlags,121 ray_flags,
126 FragmentShadingRate,122 fragment_shading_rate,
127 RawAccessChainOperands,123 raw_access_chain_operands,
128 SourceLanguage,124 source_language,
129 ExecutionModel,125 execution_model,
130 AddressingModel,126 addressing_model,
131 MemoryModel,127 memory_model,
132 ExecutionMode,128 execution_mode,
133 StorageClass,129 storage_class,
134 Dim,130 dim,
135 SamplerAddressingMode,131 sampler_addressing_mode,
136 SamplerFilterMode,132 sampler_filter_mode,
137 ImageFormat,133 image_format,
138 ImageChannelOrder,134 image_channel_order,
139 ImageChannelDataType,135 image_channel_data_type,
140 FPRoundingMode,136 fp_rounding_mode,
141 FPDenormMode,137 fp_denorm_mode,
142 QuantizationModes,138 quantization_modes,
143 FPOperationMode,139 fp_operation_mode,
144 OverflowModes,140 overflow_modes,
145 LinkageType,141 linkage_type,
146 AccessQualifier,142 access_qualifier,
147 HostAccessQualifier,143 host_access_qualifier,
148 FunctionParameterAttribute,144 function_parameter_attribute,
149 Decoration,145 decoration,
150 BuiltIn,146 built_in,
151 Scope,147 scope,
152 GroupOperation,148 group_operation,
153 KernelEnqueueFlags,149 kernel_enqueue_flags,
154 Capability,150 capability,
155 RayQueryIntersection,151 ray_query_intersection,
156 RayQueryCommittedIntersectionType,152 ray_query_committed_intersection_type,
157 RayQueryCandidateIntersectionType,153 ray_query_candidate_intersection_type,
158 PackedVectorFormat,154 packed_vector_format,
159 CooperativeMatrixOperands,155 cooperative_matrix_operands,
160 CooperativeMatrixLayout,156 cooperative_matrix_layout,
161 CooperativeMatrixUse,157 cooperative_matrix_use,
162 InitializationModeQualifier,158 cooperative_matrix_reduce,
163 LoadCacheControl,159 tensor_clamp_mode,
164 StoreCacheControl,160 tensor_addressing_operands,
165 NamedMaximumNumberOfRegisters,161 initialization_mode_qualifier,
166 IdResultType,162 load_cache_control,
167 IdResult,163 store_cache_control,
168 IdMemorySemantics,164 named_maximum_number_of_registers,
169 IdScope,165 matrix_multiply_accumulate_operands,
170 IdRef,166 fp_encoding,
171 LiteralInteger,167 cooperative_vector_matrix_layout,
172 LiteralString,168 component_type,
173 LiteralFloat,169 id_result_type,
174 LiteralContextDependentNumber,170 id_result,
175 LiteralExtInstInteger,171 id_memory_semantics,
176 LiteralSpecConstantOpInteger,172 id_scope,
177 PairLiteralIntegerIdRef,173 id_ref,
178 PairIdRefLiteralInteger,174 literal_integer,
179 PairIdRefIdRef,175 literal_string,
180 @"OpenCL.DebugInfo.100.DebugInfoFlags",176 literal_float,
181 @"OpenCL.DebugInfo.100.DebugBaseTypeAttributeEncoding",177 literal_context_dependent_number,
182 @"OpenCL.DebugInfo.100.DebugCompositeType",178 literal_ext_inst_integer,
183 @"OpenCL.DebugInfo.100.DebugTypeQualifier",179 literal_spec_constant_op_integer,
184 @"OpenCL.DebugInfo.100.DebugOperation",180 pair_literal_integer_id_ref,
185 @"OpenCL.DebugInfo.100.DebugImportedEntity",181 pair_id_ref_literal_integer,
186 @"NonSemantic.Shader.DebugInfo.100.DebugInfoFlags",182 pair_id_ref_id_ref,
187 @"NonSemantic.Shader.DebugInfo.100.BuildIdentifierFlags",183 tensor_operands,
188 @"NonSemantic.Shader.DebugInfo.100.DebugBaseTypeAttributeEncoding",184 debug_info_debug_info_flags,
189 @"NonSemantic.Shader.DebugInfo.100.DebugCompositeType",185 debug_info_debug_base_type_attribute_encoding,
190 @"NonSemantic.Shader.DebugInfo.100.DebugTypeQualifier",186 debug_info_debug_composite_type,
191 @"NonSemantic.Shader.DebugInfo.100.DebugOperation",187 debug_info_debug_type_qualifier,
192 @"NonSemantic.Shader.DebugInfo.100.DebugImportedEntity",188 debug_info_debug_operation,
193 @"NonSemantic.ClspvReflection.6.KernelPropertyFlags",189 open_cl_debug_info_100_debug_info_flags,
194 @"DebugInfo.DebugInfoFlags",190 open_cl_debug_info_100_debug_base_type_attribute_encoding,
195 @"DebugInfo.DebugBaseTypeAttributeEncoding",191 open_cl_debug_info_100_debug_composite_type,
196 @"DebugInfo.DebugCompositeType",192 open_cl_debug_info_100_debug_type_qualifier,
197 @"DebugInfo.DebugTypeQualifier",193 open_cl_debug_info_100_debug_operation,
198 @"DebugInfo.DebugOperation",194 open_cl_debug_info_100_debug_imported_entity,
195 non_semantic_clspv_reflection_6_kernel_property_flags,
196 non_semantic_shader_debug_info_100_debug_info_flags,
197 non_semantic_shader_debug_info_100_build_identifier_flags,
198 non_semantic_shader_debug_info_100_debug_base_type_attribute_encoding,
199 non_semantic_shader_debug_info_100_debug_composite_type,
200 non_semantic_shader_debug_info_100_debug_type_qualifier,
201 non_semantic_shader_debug_info_100_debug_operation,
202 non_semantic_shader_debug_info_100_debug_imported_entity,
199203
200 pub fn category(self: OperandKind) OperandCategory {204 pub fn category(self: OperandKind) OperandCategory {
201 return switch (self) {205 return switch (self) {
202 .Opcode => .literal,206 .opcode => .literal,
203 .ImageOperands => .bit_enum,207 .image_operands => .bit_enum,
204 .FPFastMathMode => .bit_enum,208 .fp_fast_math_mode => .bit_enum,
205 .SelectionControl => .bit_enum,209 .selection_control => .bit_enum,
206 .LoopControl => .bit_enum,210 .loop_control => .bit_enum,
207 .FunctionControl => .bit_enum,211 .function_control => .bit_enum,
208 .MemorySemantics => .bit_enum,212 .memory_semantics => .bit_enum,
209 .MemoryAccess => .bit_enum,213 .memory_access => .bit_enum,
210 .KernelProfilingInfo => .bit_enum,214 .kernel_profiling_info => .bit_enum,
211 .RayFlags => .bit_enum,215 .ray_flags => .bit_enum,
212 .FragmentShadingRate => .bit_enum,216 .fragment_shading_rate => .bit_enum,
213 .RawAccessChainOperands => .bit_enum,217 .raw_access_chain_operands => .bit_enum,
214 .SourceLanguage => .value_enum,218 .source_language => .value_enum,
215 .ExecutionModel => .value_enum,219 .execution_model => .value_enum,
216 .AddressingModel => .value_enum,220 .addressing_model => .value_enum,
217 .MemoryModel => .value_enum,221 .memory_model => .value_enum,
218 .ExecutionMode => .value_enum,222 .execution_mode => .value_enum,
219 .StorageClass => .value_enum,223 .storage_class => .value_enum,
220 .Dim => .value_enum,224 .dim => .value_enum,
221 .SamplerAddressingMode => .value_enum,225 .sampler_addressing_mode => .value_enum,
222 .SamplerFilterMode => .value_enum,226 .sampler_filter_mode => .value_enum,
223 .ImageFormat => .value_enum,227 .image_format => .value_enum,
224 .ImageChannelOrder => .value_enum,228 .image_channel_order => .value_enum,
225 .ImageChannelDataType => .value_enum,229 .image_channel_data_type => .value_enum,
226 .FPRoundingMode => .value_enum,230 .fp_rounding_mode => .value_enum,
227 .FPDenormMode => .value_enum,231 .fp_denorm_mode => .value_enum,
228 .QuantizationModes => .value_enum,232 .quantization_modes => .value_enum,
229 .FPOperationMode => .value_enum,233 .fp_operation_mode => .value_enum,
230 .OverflowModes => .value_enum,234 .overflow_modes => .value_enum,
231 .LinkageType => .value_enum,235 .linkage_type => .value_enum,
232 .AccessQualifier => .value_enum,236 .access_qualifier => .value_enum,
233 .HostAccessQualifier => .value_enum,237 .host_access_qualifier => .value_enum,
234 .FunctionParameterAttribute => .value_enum,238 .function_parameter_attribute => .value_enum,
235 .Decoration => .value_enum,239 .decoration => .value_enum,
236 .BuiltIn => .value_enum,240 .built_in => .value_enum,
237 .Scope => .value_enum,241 .scope => .value_enum,
238 .GroupOperation => .value_enum,242 .group_operation => .value_enum,
239 .KernelEnqueueFlags => .value_enum,243 .kernel_enqueue_flags => .value_enum,
240 .Capability => .value_enum,244 .capability => .value_enum,
241 .RayQueryIntersection => .value_enum,245 .ray_query_intersection => .value_enum,
242 .RayQueryCommittedIntersectionType => .value_enum,246 .ray_query_committed_intersection_type => .value_enum,
243 .RayQueryCandidateIntersectionType => .value_enum,247 .ray_query_candidate_intersection_type => .value_enum,
244 .PackedVectorFormat => .value_enum,248 .packed_vector_format => .value_enum,
245 .CooperativeMatrixOperands => .bit_enum,249 .cooperative_matrix_operands => .bit_enum,
246 .CooperativeMatrixLayout => .value_enum,250 .cooperative_matrix_layout => .value_enum,
247 .CooperativeMatrixUse => .value_enum,251 .cooperative_matrix_use => .value_enum,
248 .InitializationModeQualifier => .value_enum,252 .cooperative_matrix_reduce => .bit_enum,
249 .LoadCacheControl => .value_enum,253 .tensor_clamp_mode => .value_enum,
250 .StoreCacheControl => .value_enum,254 .tensor_addressing_operands => .bit_enum,
251 .NamedMaximumNumberOfRegisters => .value_enum,255 .initialization_mode_qualifier => .value_enum,
252 .IdResultType => .id,256 .load_cache_control => .value_enum,
253 .IdResult => .id,257 .store_cache_control => .value_enum,
254 .IdMemorySemantics => .id,258 .named_maximum_number_of_registers => .value_enum,
255 .IdScope => .id,259 .matrix_multiply_accumulate_operands => .bit_enum,
256 .IdRef => .id,260 .fp_encoding => .value_enum,
257 .LiteralInteger => .literal,261 .cooperative_vector_matrix_layout => .value_enum,
258 .LiteralString => .literal,262 .component_type => .value_enum,
259 .LiteralFloat => .literal,263 .id_result_type => .id,
260 .LiteralContextDependentNumber => .literal,264 .id_result => .id,
261 .LiteralExtInstInteger => .literal,265 .id_memory_semantics => .id,
262 .LiteralSpecConstantOpInteger => .literal,266 .id_scope => .id,
263 .PairLiteralIntegerIdRef => .composite,267 .id_ref => .id,
264 .PairIdRefLiteralInteger => .composite,268 .literal_integer => .literal,
265 .PairIdRefIdRef => .composite,269 .literal_string => .literal,
266 .@"OpenCL.DebugInfo.100.DebugInfoFlags" => .bit_enum,270 .literal_float => .literal,
267 .@"OpenCL.DebugInfo.100.DebugBaseTypeAttributeEncoding" => .value_enum,271 .literal_context_dependent_number => .literal,
268 .@"OpenCL.DebugInfo.100.DebugCompositeType" => .value_enum,272 .literal_ext_inst_integer => .literal,
269 .@"OpenCL.DebugInfo.100.DebugTypeQualifier" => .value_enum,273 .literal_spec_constant_op_integer => .literal,
270 .@"OpenCL.DebugInfo.100.DebugOperation" => .value_enum,274 .pair_literal_integer_id_ref => .composite,
271 .@"OpenCL.DebugInfo.100.DebugImportedEntity" => .value_enum,275 .pair_id_ref_literal_integer => .composite,
272 .@"NonSemantic.Shader.DebugInfo.100.DebugInfoFlags" => .bit_enum,276 .pair_id_ref_id_ref => .composite,
273 .@"NonSemantic.Shader.DebugInfo.100.BuildIdentifierFlags" => .bit_enum,277 .tensor_operands => .bit_enum,
274 .@"NonSemantic.Shader.DebugInfo.100.DebugBaseTypeAttributeEncoding" => .value_enum,278 .debug_info_debug_info_flags => .bit_enum,
275 .@"NonSemantic.Shader.DebugInfo.100.DebugCompositeType" => .value_enum,279 .debug_info_debug_base_type_attribute_encoding => .value_enum,
276 .@"NonSemantic.Shader.DebugInfo.100.DebugTypeQualifier" => .value_enum,280 .debug_info_debug_composite_type => .value_enum,
277 .@"NonSemantic.Shader.DebugInfo.100.DebugOperation" => .value_enum,281 .debug_info_debug_type_qualifier => .value_enum,
278 .@"NonSemantic.Shader.DebugInfo.100.DebugImportedEntity" => .value_enum,282 .debug_info_debug_operation => .value_enum,
279 .@"NonSemantic.ClspvReflection.6.KernelPropertyFlags" => .bit_enum,283 .open_cl_debug_info_100_debug_info_flags => .bit_enum,
280 .@"DebugInfo.DebugInfoFlags" => .bit_enum,284 .open_cl_debug_info_100_debug_base_type_attribute_encoding => .value_enum,
281 .@"DebugInfo.DebugBaseTypeAttributeEncoding" => .value_enum,285 .open_cl_debug_info_100_debug_composite_type => .value_enum,
282 .@"DebugInfo.DebugCompositeType" => .value_enum,286 .open_cl_debug_info_100_debug_type_qualifier => .value_enum,
283 .@"DebugInfo.DebugTypeQualifier" => .value_enum,287 .open_cl_debug_info_100_debug_operation => .value_enum,
284 .@"DebugInfo.DebugOperation" => .value_enum,288 .open_cl_debug_info_100_debug_imported_entity => .value_enum,
289 .non_semantic_clspv_reflection_6_kernel_property_flags => .bit_enum,
290 .non_semantic_shader_debug_info_100_debug_info_flags => .bit_enum,
291 .non_semantic_shader_debug_info_100_build_identifier_flags => .bit_enum,
292 .non_semantic_shader_debug_info_100_debug_base_type_attribute_encoding => .value_enum,
293 .non_semantic_shader_debug_info_100_debug_composite_type => .value_enum,
294 .non_semantic_shader_debug_info_100_debug_type_qualifier => .value_enum,
295 .non_semantic_shader_debug_info_100_debug_operation => .value_enum,
296 .non_semantic_shader_debug_info_100_debug_imported_entity => .value_enum,
285 };297 };
286 }298 }
287 pub fn enumerants(self: OperandKind) []const Enumerant {299 pub fn enumerants(self: OperandKind) []const Enumerant {
288 return switch (self) {300 return switch (self) {
289 .Opcode => unreachable,301 .opcode => unreachable,
290 .ImageOperands => &[_]Enumerant{302 .image_operands => &.{
291 .{ .name = "Bias", .value = 0x0001, .parameters = &[_]OperandKind{.IdRef} },303 .{ .name = "Bias", .value = 0x0001, .parameters = &.{.id_ref} },
292 .{ .name = "Lod", .value = 0x0002, .parameters = &[_]OperandKind{.IdRef} },304 .{ .name = "Lod", .value = 0x0002, .parameters = &.{.id_ref} },
293 .{ .name = "Grad", .value = 0x0004, .parameters = &[_]OperandKind{ .IdRef, .IdRef } },305 .{ .name = "Grad", .value = 0x0004, .parameters = &.{ .id_ref, .id_ref } },
294 .{ .name = "ConstOffset", .value = 0x0008, .parameters = &[_]OperandKind{.IdRef} },306 .{ .name = "ConstOffset", .value = 0x0008, .parameters = &.{.id_ref} },
295 .{ .name = "Offset", .value = 0x0010, .parameters = &[_]OperandKind{.IdRef} },307 .{ .name = "Offset", .value = 0x0010, .parameters = &.{.id_ref} },
296 .{ .name = "ConstOffsets", .value = 0x0020, .parameters = &[_]OperandKind{.IdRef} },308 .{ .name = "ConstOffsets", .value = 0x0020, .parameters = &.{.id_ref} },
297 .{ .name = "Sample", .value = 0x0040, .parameters = &[_]OperandKind{.IdRef} },309 .{ .name = "Sample", .value = 0x0040, .parameters = &.{.id_ref} },
298 .{ .name = "MinLod", .value = 0x0080, .parameters = &[_]OperandKind{.IdRef} },310 .{ .name = "MinLod", .value = 0x0080, .parameters = &.{.id_ref} },
299 .{ .name = "MakeTexelAvailable", .value = 0x0100, .parameters = &[_]OperandKind{.IdScope} },311 .{ .name = "MakeTexelAvailable", .value = 0x0100, .parameters = &.{.id_scope} },
300 .{ .name = "MakeTexelAvailableKHR", .value = 0x0100, .parameters = &[_]OperandKind{.IdScope} },312 .{ .name = "MakeTexelVisible", .value = 0x0200, .parameters = &.{.id_scope} },
301 .{ .name = "MakeTexelVisible", .value = 0x0200, .parameters = &[_]OperandKind{.IdScope} },313 .{ .name = "NonPrivateTexel", .value = 0x0400, .parameters = &.{} },
302 .{ .name = "MakeTexelVisibleKHR", .value = 0x0200, .parameters = &[_]OperandKind{.IdScope} },314 .{ .name = "VolatileTexel", .value = 0x0800, .parameters = &.{} },
303 .{ .name = "NonPrivateTexel", .value = 0x0400, .parameters = &[_]OperandKind{} },315 .{ .name = "SignExtend", .value = 0x1000, .parameters = &.{} },
304 .{ .name = "NonPrivateTexelKHR", .value = 0x0400, .parameters = &[_]OperandKind{} },316 .{ .name = "ZeroExtend", .value = 0x2000, .parameters = &.{} },
305 .{ .name = "VolatileTexel", .value = 0x0800, .parameters = &[_]OperandKind{} },317 .{ .name = "Nontemporal", .value = 0x4000, .parameters = &.{} },
306 .{ .name = "VolatileTexelKHR", .value = 0x0800, .parameters = &[_]OperandKind{} },318 .{ .name = "Offsets", .value = 0x10000, .parameters = &.{.id_ref} },
307 .{ .name = "SignExtend", .value = 0x1000, .parameters = &[_]OperandKind{} },319 },
308 .{ .name = "ZeroExtend", .value = 0x2000, .parameters = &[_]OperandKind{} },320 .fp_fast_math_mode => &.{
309 .{ .name = "Nontemporal", .value = 0x4000, .parameters = &[_]OperandKind{} },321 .{ .name = "NotNaN", .value = 0x0001, .parameters = &.{} },
310 .{ .name = "Offsets", .value = 0x10000, .parameters = &[_]OperandKind{.IdRef} },322 .{ .name = "NotInf", .value = 0x0002, .parameters = &.{} },
323 .{ .name = "NSZ", .value = 0x0004, .parameters = &.{} },
324 .{ .name = "AllowRecip", .value = 0x0008, .parameters = &.{} },
325 .{ .name = "Fast", .value = 0x0010, .parameters = &.{} },
326 .{ .name = "AllowContract", .value = 0x10000, .parameters = &.{} },
327 .{ .name = "AllowReassoc", .value = 0x20000, .parameters = &.{} },
328 .{ .name = "AllowTransform", .value = 0x40000, .parameters = &.{} },
329 },
330 .selection_control => &.{
331 .{ .name = "Flatten", .value = 0x0001, .parameters = &.{} },
332 .{ .name = "DontFlatten", .value = 0x0002, .parameters = &.{} },
333 },
334 .loop_control => &.{
335 .{ .name = "Unroll", .value = 0x0001, .parameters = &.{} },
336 .{ .name = "DontUnroll", .value = 0x0002, .parameters = &.{} },
337 .{ .name = "DependencyInfinite", .value = 0x0004, .parameters = &.{} },
338 .{ .name = "DependencyLength", .value = 0x0008, .parameters = &.{.literal_integer} },
339 .{ .name = "MinIterations", .value = 0x0010, .parameters = &.{.literal_integer} },
340 .{ .name = "MaxIterations", .value = 0x0020, .parameters = &.{.literal_integer} },
341 .{ .name = "IterationMultiple", .value = 0x0040, .parameters = &.{.literal_integer} },
342 .{ .name = "PeelCount", .value = 0x0080, .parameters = &.{.literal_integer} },
343 .{ .name = "PartialCount", .value = 0x0100, .parameters = &.{.literal_integer} },
344 .{ .name = "InitiationIntervalINTEL", .value = 0x10000, .parameters = &.{.literal_integer} },
345 .{ .name = "MaxConcurrencyINTEL", .value = 0x20000, .parameters = &.{.literal_integer} },
346 .{ .name = "DependencyArrayINTEL", .value = 0x40000, .parameters = &.{.literal_integer} },
347 .{ .name = "PipelineEnableINTEL", .value = 0x80000, .parameters = &.{.literal_integer} },
348 .{ .name = "LoopCoalesceINTEL", .value = 0x100000, .parameters = &.{.literal_integer} },
349 .{ .name = "MaxInterleavingINTEL", .value = 0x200000, .parameters = &.{.literal_integer} },
350 .{ .name = "SpeculatedIterationsINTEL", .value = 0x400000, .parameters = &.{.literal_integer} },
351 .{ .name = "NoFusionINTEL", .value = 0x800000, .parameters = &.{} },
352 .{ .name = "LoopCountINTEL", .value = 0x1000000, .parameters = &.{.literal_integer} },
353 .{ .name = "MaxReinvocationDelayINTEL", .value = 0x2000000, .parameters = &.{.literal_integer} },
354 },
355 .function_control => &.{
356 .{ .name = "Inline", .value = 0x0001, .parameters = &.{} },
357 .{ .name = "DontInline", .value = 0x0002, .parameters = &.{} },
358 .{ .name = "Pure", .value = 0x0004, .parameters = &.{} },
359 .{ .name = "Const", .value = 0x0008, .parameters = &.{} },
360 .{ .name = "OptNoneEXT", .value = 0x10000, .parameters = &.{} },
361 },
362 .memory_semantics => &.{
363 .{ .name = "Relaxed", .value = 0x0000, .parameters = &.{} },
364 .{ .name = "Acquire", .value = 0x0002, .parameters = &.{} },
365 .{ .name = "Release", .value = 0x0004, .parameters = &.{} },
366 .{ .name = "AcquireRelease", .value = 0x0008, .parameters = &.{} },
367 .{ .name = "SequentiallyConsistent", .value = 0x0010, .parameters = &.{} },
368 .{ .name = "UniformMemory", .value = 0x0040, .parameters = &.{} },
369 .{ .name = "SubgroupMemory", .value = 0x0080, .parameters = &.{} },
370 .{ .name = "WorkgroupMemory", .value = 0x0100, .parameters = &.{} },
371 .{ .name = "CrossWorkgroupMemory", .value = 0x0200, .parameters = &.{} },
372 .{ .name = "AtomicCounterMemory", .value = 0x0400, .parameters = &.{} },
373 .{ .name = "ImageMemory", .value = 0x0800, .parameters = &.{} },
374 .{ .name = "OutputMemory", .value = 0x1000, .parameters = &.{} },
375 .{ .name = "MakeAvailable", .value = 0x2000, .parameters = &.{} },
376 .{ .name = "MakeVisible", .value = 0x4000, .parameters = &.{} },
377 .{ .name = "Volatile", .value = 0x8000, .parameters = &.{} },
378 },
379 .memory_access => &.{
380 .{ .name = "Volatile", .value = 0x0001, .parameters = &.{} },
381 .{ .name = "Aligned", .value = 0x0002, .parameters = &.{.literal_integer} },
382 .{ .name = "Nontemporal", .value = 0x0004, .parameters = &.{} },
383 .{ .name = "MakePointerAvailable", .value = 0x0008, .parameters = &.{.id_scope} },
384 .{ .name = "MakePointerVisible", .value = 0x0010, .parameters = &.{.id_scope} },
385 .{ .name = "NonPrivatePointer", .value = 0x0020, .parameters = &.{} },
386 .{ .name = "AliasScopeINTELMask", .value = 0x10000, .parameters = &.{.id_ref} },
387 .{ .name = "NoAliasINTELMask", .value = 0x20000, .parameters = &.{.id_ref} },
311 },388 },
312 .FPFastMathMode => &[_]Enumerant{389 .kernel_profiling_info => &.{
313 .{ .name = "NotNaN", .value = 0x0001, .parameters = &[_]OperandKind{} },390 .{ .name = "CmdExecTime", .value = 0x0001, .parameters = &.{} },
314 .{ .name = "NotInf", .value = 0x0002, .parameters = &[_]OperandKind{} },
315 .{ .name = "NSZ", .value = 0x0004, .parameters = &[_]OperandKind{} },
316 .{ .name = "AllowRecip", .value = 0x0008, .parameters = &[_]OperandKind{} },
317 .{ .name = "Fast", .value = 0x0010, .parameters = &[_]OperandKind{} },
318 .{ .name = "AllowContract", .value = 0x10000, .parameters = &[_]OperandKind{} },
319 .{ .name = "AllowContractFastINTEL", .value = 0x10000, .parameters = &[_]OperandKind{} },
320 .{ .name = "AllowReassoc", .value = 0x20000, .parameters = &[_]OperandKind{} },
321 .{ .name = "AllowReassocINTEL", .value = 0x20000, .parameters = &[_]OperandKind{} },
322 .{ .name = "AllowTransform", .value = 0x40000, .parameters = &[_]OperandKind{} },
323 },391 },
324 .SelectionControl => &[_]Enumerant{392 .ray_flags => &.{
325 .{ .name = "Flatten", .value = 0x0001, .parameters = &[_]OperandKind{} },393 .{ .name = "NoneKHR", .value = 0x0000, .parameters = &.{} },
326 .{ .name = "DontFlatten", .value = 0x0002, .parameters = &[_]OperandKind{} },394 .{ .name = "OpaqueKHR", .value = 0x0001, .parameters = &.{} },
395 .{ .name = "NoOpaqueKHR", .value = 0x0002, .parameters = &.{} },
396 .{ .name = "TerminateOnFirstHitKHR", .value = 0x0004, .parameters = &.{} },
397 .{ .name = "SkipClosestHitShaderKHR", .value = 0x0008, .parameters = &.{} },
398 .{ .name = "CullBackFacingTrianglesKHR", .value = 0x0010, .parameters = &.{} },
399 .{ .name = "CullFrontFacingTrianglesKHR", .value = 0x0020, .parameters = &.{} },
400 .{ .name = "CullOpaqueKHR", .value = 0x0040, .parameters = &.{} },
401 .{ .name = "CullNoOpaqueKHR", .value = 0x0080, .parameters = &.{} },
402 .{ .name = "SkipTrianglesKHR", .value = 0x0100, .parameters = &.{} },
403 .{ .name = "SkipAABBsKHR", .value = 0x0200, .parameters = &.{} },
404 .{ .name = "ForceOpacityMicromap2StateEXT", .value = 0x0400, .parameters = &.{} },
327 },405 },
328 .LoopControl => &[_]Enumerant{406 .fragment_shading_rate => &.{
329 .{ .name = "Unroll", .value = 0x0001, .parameters = &[_]OperandKind{} },407 .{ .name = "Vertical2Pixels", .value = 0x0001, .parameters = &.{} },
330 .{ .name = "DontUnroll", .value = 0x0002, .parameters = &[_]OperandKind{} },408 .{ .name = "Vertical4Pixels", .value = 0x0002, .parameters = &.{} },
331 .{ .name = "DependencyInfinite", .value = 0x0004, .parameters = &[_]OperandKind{} },409 .{ .name = "Horizontal2Pixels", .value = 0x0004, .parameters = &.{} },
332 .{ .name = "DependencyLength", .value = 0x0008, .parameters = &[_]OperandKind{.LiteralInteger} },410 .{ .name = "Horizontal4Pixels", .value = 0x0008, .parameters = &.{} },
333 .{ .name = "MinIterations", .value = 0x0010, .parameters = &[_]OperandKind{.LiteralInteger} },
334 .{ .name = "MaxIterations", .value = 0x0020, .parameters = &[_]OperandKind{.LiteralInteger} },
335 .{ .name = "IterationMultiple", .value = 0x0040, .parameters = &[_]OperandKind{.LiteralInteger} },
336 .{ .name = "PeelCount", .value = 0x0080, .parameters = &[_]OperandKind{.LiteralInteger} },
337 .{ .name = "PartialCount", .value = 0x0100, .parameters = &[_]OperandKind{.LiteralInteger} },
338 .{ .name = "InitiationIntervalINTEL", .value = 0x10000, .parameters = &[_]OperandKind{.LiteralInteger} },
339 .{ .name = "MaxConcurrencyINTEL", .value = 0x20000, .parameters = &[_]OperandKind{.LiteralInteger} },
340 .{ .name = "DependencyArrayINTEL", .value = 0x40000, .parameters = &[_]OperandKind{.LiteralInteger} },
341 .{ .name = "PipelineEnableINTEL", .value = 0x80000, .parameters = &[_]OperandKind{.LiteralInteger} },
342 .{ .name = "LoopCoalesceINTEL", .value = 0x100000, .parameters = &[_]OperandKind{.LiteralInteger} },
343 .{ .name = "MaxInterleavingINTEL", .value = 0x200000, .parameters = &[_]OperandKind{.LiteralInteger} },
344 .{ .name = "SpeculatedIterationsINTEL", .value = 0x400000, .parameters = &[_]OperandKind{.LiteralInteger} },
345 .{ .name = "NoFusionINTEL", .value = 0x800000, .parameters = &[_]OperandKind{} },
346 .{ .name = "LoopCountINTEL", .value = 0x1000000, .parameters = &[_]OperandKind{.LiteralInteger} },
347 .{ .name = "MaxReinvocationDelayINTEL", .value = 0x2000000, .parameters = &[_]OperandKind{.LiteralInteger} },
348 },411 },
349 .FunctionControl => &[_]Enumerant{412 .raw_access_chain_operands => &.{
350 .{ .name = "Inline", .value = 0x0001, .parameters = &[_]OperandKind{} },413 .{ .name = "RobustnessPerComponentNV", .value = 0x0001, .parameters = &.{} },
351 .{ .name = "DontInline", .value = 0x0002, .parameters = &[_]OperandKind{} },414 .{ .name = "RobustnessPerElementNV", .value = 0x0002, .parameters = &.{} },
352 .{ .name = "Pure", .value = 0x0004, .parameters = &[_]OperandKind{} },
353 .{ .name = "Const", .value = 0x0008, .parameters = &[_]OperandKind{} },
354 .{ .name = "OptNoneINTEL", .value = 0x10000, .parameters = &[_]OperandKind{} },
355 },415 },
356 .MemorySemantics => &[_]Enumerant{416 .source_language => &.{
357 .{ .name = "Relaxed", .value = 0x0000, .parameters = &[_]OperandKind{} },417 .{ .name = "Unknown", .value = 0, .parameters = &.{} },
358 .{ .name = "Acquire", .value = 0x0002, .parameters = &[_]OperandKind{} },418 .{ .name = "ESSL", .value = 1, .parameters = &.{} },
359 .{ .name = "Release", .value = 0x0004, .parameters = &[_]OperandKind{} },419 .{ .name = "GLSL", .value = 2, .parameters = &.{} },
360 .{ .name = "AcquireRelease", .value = 0x0008, .parameters = &[_]OperandKind{} },420 .{ .name = "OpenCL_C", .value = 3, .parameters = &.{} },
361 .{ .name = "SequentiallyConsistent", .value = 0x0010, .parameters = &[_]OperandKind{} },421 .{ .name = "OpenCL_CPP", .value = 4, .parameters = &.{} },
362 .{ .name = "UniformMemory", .value = 0x0040, .parameters = &[_]OperandKind{} },422 .{ .name = "HLSL", .value = 5, .parameters = &.{} },
363 .{ .name = "SubgroupMemory", .value = 0x0080, .parameters = &[_]OperandKind{} },423 .{ .name = "CPP_for_OpenCL", .value = 6, .parameters = &.{} },
364 .{ .name = "WorkgroupMemory", .value = 0x0100, .parameters = &[_]OperandKind{} },424 .{ .name = "SYCL", .value = 7, .parameters = &.{} },
365 .{ .name = "CrossWorkgroupMemory", .value = 0x0200, .parameters = &[_]OperandKind{} },425 .{ .name = "HERO_C", .value = 8, .parameters = &.{} },
366 .{ .name = "AtomicCounterMemory", .value = 0x0400, .parameters = &[_]OperandKind{} },426 .{ .name = "NZSL", .value = 9, .parameters = &.{} },
367 .{ .name = "ImageMemory", .value = 0x0800, .parameters = &[_]OperandKind{} },427 .{ .name = "WGSL", .value = 10, .parameters = &.{} },
368 .{ .name = "OutputMemory", .value = 0x1000, .parameters = &[_]OperandKind{} },428 .{ .name = "Slang", .value = 11, .parameters = &.{} },
369 .{ .name = "OutputMemoryKHR", .value = 0x1000, .parameters = &[_]OperandKind{} },429 .{ .name = "Zig", .value = 12, .parameters = &.{} },
370 .{ .name = "MakeAvailable", .value = 0x2000, .parameters = &[_]OperandKind{} },430 .{ .name = "Rust", .value = 13, .parameters = &.{} },
371 .{ .name = "MakeAvailableKHR", .value = 0x2000, .parameters = &[_]OperandKind{} },
372 .{ .name = "MakeVisible", .value = 0x4000, .parameters = &[_]OperandKind{} },
373 .{ .name = "MakeVisibleKHR", .value = 0x4000, .parameters = &[_]OperandKind{} },
374 .{ .name = "Volatile", .value = 0x8000, .parameters = &[_]OperandKind{} },
375 },431 },
376 .MemoryAccess => &[_]Enumerant{432 .execution_model => &.{
377 .{ .name = "Volatile", .value = 0x0001, .parameters = &[_]OperandKind{} },433 .{ .name = "Vertex", .value = 0, .parameters = &.{} },
378 .{ .name = "Aligned", .value = 0x0002, .parameters = &[_]OperandKind{.LiteralInteger} },434 .{ .name = "TessellationControl", .value = 1, .parameters = &.{} },
379 .{ .name = "Nontemporal", .value = 0x0004, .parameters = &[_]OperandKind{} },435 .{ .name = "TessellationEvaluation", .value = 2, .parameters = &.{} },
380 .{ .name = "MakePointerAvailable", .value = 0x0008, .parameters = &[_]OperandKind{.IdScope} },436 .{ .name = "Geometry", .value = 3, .parameters = &.{} },
381 .{ .name = "MakePointerAvailableKHR", .value = 0x0008, .parameters = &[_]OperandKind{.IdScope} },437 .{ .name = "Fragment", .value = 4, .parameters = &.{} },
382 .{ .name = "MakePointerVisible", .value = 0x0010, .parameters = &[_]OperandKind{.IdScope} },438 .{ .name = "GLCompute", .value = 5, .parameters = &.{} },
383 .{ .name = "MakePointerVisibleKHR", .value = 0x0010, .parameters = &[_]OperandKind{.IdScope} },439 .{ .name = "Kernel", .value = 6, .parameters = &.{} },
384 .{ .name = "NonPrivatePointer", .value = 0x0020, .parameters = &[_]OperandKind{} },440 .{ .name = "TaskNV", .value = 5267, .parameters = &.{} },
385 .{ .name = "NonPrivatePointerKHR", .value = 0x0020, .parameters = &[_]OperandKind{} },441 .{ .name = "MeshNV", .value = 5268, .parameters = &.{} },
386 .{ .name = "AliasScopeINTELMask", .value = 0x10000, .parameters = &[_]OperandKind{.IdRef} },442 .{ .name = "RayGenerationKHR", .value = 5313, .parameters = &.{} },
387 .{ .name = "NoAliasINTELMask", .value = 0x20000, .parameters = &[_]OperandKind{.IdRef} },443 .{ .name = "IntersectionKHR", .value = 5314, .parameters = &.{} },
444 .{ .name = "AnyHitKHR", .value = 5315, .parameters = &.{} },
445 .{ .name = "ClosestHitKHR", .value = 5316, .parameters = &.{} },
446 .{ .name = "MissKHR", .value = 5317, .parameters = &.{} },
447 .{ .name = "CallableKHR", .value = 5318, .parameters = &.{} },
448 .{ .name = "TaskEXT", .value = 5364, .parameters = &.{} },
449 .{ .name = "MeshEXT", .value = 5365, .parameters = &.{} },
388 },450 },
389 .KernelProfilingInfo => &[_]Enumerant{451 .addressing_model => &.{
390 .{ .name = "CmdExecTime", .value = 0x0001, .parameters = &[_]OperandKind{} },452 .{ .name = "Logical", .value = 0, .parameters = &.{} },
453 .{ .name = "Physical32", .value = 1, .parameters = &.{} },
454 .{ .name = "Physical64", .value = 2, .parameters = &.{} },
455 .{ .name = "PhysicalStorageBuffer64", .value = 5348, .parameters = &.{} },
391 },456 },
392 .RayFlags => &[_]Enumerant{457 .memory_model => &.{
393 .{ .name = "NoneKHR", .value = 0x0000, .parameters = &[_]OperandKind{} },458 .{ .name = "Simple", .value = 0, .parameters = &.{} },
394 .{ .name = "OpaqueKHR", .value = 0x0001, .parameters = &[_]OperandKind{} },459 .{ .name = "GLSL450", .value = 1, .parameters = &.{} },
395 .{ .name = "NoOpaqueKHR", .value = 0x0002, .parameters = &[_]OperandKind{} },460 .{ .name = "OpenCL", .value = 2, .parameters = &.{} },
396 .{ .name = "TerminateOnFirstHitKHR", .value = 0x0004, .parameters = &[_]OperandKind{} },461 .{ .name = "Vulkan", .value = 3, .parameters = &.{} },
397 .{ .name = "SkipClosestHitShaderKHR", .value = 0x0008, .parameters = &[_]OperandKind{} },
398 .{ .name = "CullBackFacingTrianglesKHR", .value = 0x0010, .parameters = &[_]OperandKind{} },
399 .{ .name = "CullFrontFacingTrianglesKHR", .value = 0x0020, .parameters = &[_]OperandKind{} },
400 .{ .name = "CullOpaqueKHR", .value = 0x0040, .parameters = &[_]OperandKind{} },
401 .{ .name = "CullNoOpaqueKHR", .value = 0x0080, .parameters = &[_]OperandKind{} },
402 .{ .name = "SkipTrianglesKHR", .value = 0x0100, .parameters = &[_]OperandKind{} },
403 .{ .name = "SkipAABBsKHR", .value = 0x0200, .parameters = &[_]OperandKind{} },
404 .{ .name = "ForceOpacityMicromap2StateEXT", .value = 0x0400, .parameters = &[_]OperandKind{} },
405 },462 },
406 .FragmentShadingRate => &[_]Enumerant{463 .execution_mode => &.{
407 .{ .name = "Vertical2Pixels", .value = 0x0001, .parameters = &[_]OperandKind{} },464 .{ .name = "Invocations", .value = 0, .parameters = &.{.literal_integer} },
408 .{ .name = "Vertical4Pixels", .value = 0x0002, .parameters = &[_]OperandKind{} },465 .{ .name = "SpacingEqual", .value = 1, .parameters = &.{} },
409 .{ .name = "Horizontal2Pixels", .value = 0x0004, .parameters = &[_]OperandKind{} },466 .{ .name = "SpacingFractionalEven", .value = 2, .parameters = &.{} },
410 .{ .name = "Horizontal4Pixels", .value = 0x0008, .parameters = &[_]OperandKind{} },467 .{ .name = "SpacingFractionalOdd", .value = 3, .parameters = &.{} },
468 .{ .name = "VertexOrderCw", .value = 4, .parameters = &.{} },
469 .{ .name = "VertexOrderCcw", .value = 5, .parameters = &.{} },
470 .{ .name = "PixelCenterInteger", .value = 6, .parameters = &.{} },
471 .{ .name = "OriginUpperLeft", .value = 7, .parameters = &.{} },
472 .{ .name = "OriginLowerLeft", .value = 8, .parameters = &.{} },
473 .{ .name = "EarlyFragmentTests", .value = 9, .parameters = &.{} },
474 .{ .name = "PointMode", .value = 10, .parameters = &.{} },
475 .{ .name = "Xfb", .value = 11, .parameters = &.{} },
476 .{ .name = "DepthReplacing", .value = 12, .parameters = &.{} },
477 .{ .name = "DepthGreater", .value = 14, .parameters = &.{} },
478 .{ .name = "DepthLess", .value = 15, .parameters = &.{} },
479 .{ .name = "DepthUnchanged", .value = 16, .parameters = &.{} },
480 .{ .name = "LocalSize", .value = 17, .parameters = &.{ .literal_integer, .literal_integer, .literal_integer } },
481 .{ .name = "LocalSizeHint", .value = 18, .parameters = &.{ .literal_integer, .literal_integer, .literal_integer } },
482 .{ .name = "InputPoints", .value = 19, .parameters = &.{} },
483 .{ .name = "InputLines", .value = 20, .parameters = &.{} },
484 .{ .name = "InputLinesAdjacency", .value = 21, .parameters = &.{} },
485 .{ .name = "Triangles", .value = 22, .parameters = &.{} },
486 .{ .name = "InputTrianglesAdjacency", .value = 23, .parameters = &.{} },
487 .{ .name = "Quads", .value = 24, .parameters = &.{} },
488 .{ .name = "Isolines", .value = 25, .parameters = &.{} },
489 .{ .name = "OutputVertices", .value = 26, .parameters = &.{.literal_integer} },
490 .{ .name = "OutputPoints", .value = 27, .parameters = &.{} },
491 .{ .name = "OutputLineStrip", .value = 28, .parameters = &.{} },
492 .{ .name = "OutputTriangleStrip", .value = 29, .parameters = &.{} },
493 .{ .name = "VecTypeHint", .value = 30, .parameters = &.{.literal_integer} },
494 .{ .name = "ContractionOff", .value = 31, .parameters = &.{} },
495 .{ .name = "Initializer", .value = 33, .parameters = &.{} },
496 .{ .name = "Finalizer", .value = 34, .parameters = &.{} },
497 .{ .name = "SubgroupSize", .value = 35, .parameters = &.{.literal_integer} },
498 .{ .name = "SubgroupsPerWorkgroup", .value = 36, .parameters = &.{.literal_integer} },
499 .{ .name = "SubgroupsPerWorkgroupId", .value = 37, .parameters = &.{.id_ref} },
500 .{ .name = "LocalSizeId", .value = 38, .parameters = &.{ .id_ref, .id_ref, .id_ref } },
501 .{ .name = "LocalSizeHintId", .value = 39, .parameters = &.{ .id_ref, .id_ref, .id_ref } },
502 .{ .name = "NonCoherentColorAttachmentReadEXT", .value = 4169, .parameters = &.{} },
503 .{ .name = "NonCoherentDepthAttachmentReadEXT", .value = 4170, .parameters = &.{} },
504 .{ .name = "NonCoherentStencilAttachmentReadEXT", .value = 4171, .parameters = &.{} },
505 .{ .name = "SubgroupUniformControlFlowKHR", .value = 4421, .parameters = &.{} },
506 .{ .name = "PostDepthCoverage", .value = 4446, .parameters = &.{} },
507 .{ .name = "DenormPreserve", .value = 4459, .parameters = &.{.literal_integer} },
508 .{ .name = "DenormFlushToZero", .value = 4460, .parameters = &.{.literal_integer} },
509 .{ .name = "SignedZeroInfNanPreserve", .value = 4461, .parameters = &.{.literal_integer} },
510 .{ .name = "RoundingModeRTE", .value = 4462, .parameters = &.{.literal_integer} },
511 .{ .name = "RoundingModeRTZ", .value = 4463, .parameters = &.{.literal_integer} },
512 .{ .name = "NonCoherentTileAttachmentReadQCOM", .value = 4489, .parameters = &.{} },
513 .{ .name = "TileShadingRateQCOM", .value = 4490, .parameters = &.{ .literal_integer, .literal_integer, .literal_integer } },
514 .{ .name = "EarlyAndLateFragmentTestsAMD", .value = 5017, .parameters = &.{} },
515 .{ .name = "StencilRefReplacingEXT", .value = 5027, .parameters = &.{} },
516 .{ .name = "CoalescingAMDX", .value = 5069, .parameters = &.{} },
517 .{ .name = "IsApiEntryAMDX", .value = 5070, .parameters = &.{.id_ref} },
518 .{ .name = "MaxNodeRecursionAMDX", .value = 5071, .parameters = &.{.id_ref} },
519 .{ .name = "StaticNumWorkgroupsAMDX", .value = 5072, .parameters = &.{ .id_ref, .id_ref, .id_ref } },
520 .{ .name = "ShaderIndexAMDX", .value = 5073, .parameters = &.{.id_ref} },
521 .{ .name = "MaxNumWorkgroupsAMDX", .value = 5077, .parameters = &.{ .id_ref, .id_ref, .id_ref } },
522 .{ .name = "StencilRefUnchangedFrontAMD", .value = 5079, .parameters = &.{} },
523 .{ .name = "StencilRefGreaterFrontAMD", .value = 5080, .parameters = &.{} },
524 .{ .name = "StencilRefLessFrontAMD", .value = 5081, .parameters = &.{} },
525 .{ .name = "StencilRefUnchangedBackAMD", .value = 5082, .parameters = &.{} },
526 .{ .name = "StencilRefGreaterBackAMD", .value = 5083, .parameters = &.{} },
527 .{ .name = "StencilRefLessBackAMD", .value = 5084, .parameters = &.{} },
528 .{ .name = "QuadDerivativesKHR", .value = 5088, .parameters = &.{} },
529 .{ .name = "RequireFullQuadsKHR", .value = 5089, .parameters = &.{} },
530 .{ .name = "SharesInputWithAMDX", .value = 5102, .parameters = &.{ .id_ref, .id_ref } },
531 .{ .name = "OutputLinesEXT", .value = 5269, .parameters = &.{} },
532 .{ .name = "OutputPrimitivesEXT", .value = 5270, .parameters = &.{.literal_integer} },
533 .{ .name = "DerivativeGroupQuadsKHR", .value = 5289, .parameters = &.{} },
534 .{ .name = "DerivativeGroupLinearKHR", .value = 5290, .parameters = &.{} },
535 .{ .name = "OutputTrianglesEXT", .value = 5298, .parameters = &.{} },
536 .{ .name = "PixelInterlockOrderedEXT", .value = 5366, .parameters = &.{} },
537 .{ .name = "PixelInterlockUnorderedEXT", .value = 5367, .parameters = &.{} },
538 .{ .name = "SampleInterlockOrderedEXT", .value = 5368, .parameters = &.{} },
539 .{ .name = "SampleInterlockUnorderedEXT", .value = 5369, .parameters = &.{} },
540 .{ .name = "ShadingRateInterlockOrderedEXT", .value = 5370, .parameters = &.{} },
541 .{ .name = "ShadingRateInterlockUnorderedEXT", .value = 5371, .parameters = &.{} },
542 .{ .name = "SharedLocalMemorySizeINTEL", .value = 5618, .parameters = &.{.literal_integer} },
543 .{ .name = "RoundingModeRTPINTEL", .value = 5620, .parameters = &.{.literal_integer} },
544 .{ .name = "RoundingModeRTNINTEL", .value = 5621, .parameters = &.{.literal_integer} },
545 .{ .name = "FloatingPointModeALTINTEL", .value = 5622, .parameters = &.{.literal_integer} },
546 .{ .name = "FloatingPointModeIEEEINTEL", .value = 5623, .parameters = &.{.literal_integer} },
547 .{ .name = "MaxWorkgroupSizeINTEL", .value = 5893, .parameters = &.{ .literal_integer, .literal_integer, .literal_integer } },
548 .{ .name = "MaxWorkDimINTEL", .value = 5894, .parameters = &.{.literal_integer} },
549 .{ .name = "NoGlobalOffsetINTEL", .value = 5895, .parameters = &.{} },
550 .{ .name = "NumSIMDWorkitemsINTEL", .value = 5896, .parameters = &.{.literal_integer} },
551 .{ .name = "SchedulerTargetFmaxMhzINTEL", .value = 5903, .parameters = &.{.literal_integer} },
552 .{ .name = "MaximallyReconvergesKHR", .value = 6023, .parameters = &.{} },
553 .{ .name = "FPFastMathDefault", .value = 6028, .parameters = &.{ .id_ref, .id_ref } },
554 .{ .name = "StreamingInterfaceINTEL", .value = 6154, .parameters = &.{.literal_integer} },
555 .{ .name = "RegisterMapInterfaceINTEL", .value = 6160, .parameters = &.{.literal_integer} },
556 .{ .name = "NamedBarrierCountINTEL", .value = 6417, .parameters = &.{.literal_integer} },
557 .{ .name = "MaximumRegistersINTEL", .value = 6461, .parameters = &.{.literal_integer} },
558 .{ .name = "MaximumRegistersIdINTEL", .value = 6462, .parameters = &.{.id_ref} },
559 .{ .name = "NamedMaximumRegistersINTEL", .value = 6463, .parameters = &.{.named_maximum_number_of_registers} },
411 },560 },
412 .RawAccessChainOperands => &[_]Enumerant{561 .storage_class => &.{
413 .{ .name = "RobustnessPerComponentNV", .value = 0x0001, .parameters = &[_]OperandKind{} },562 .{ .name = "UniformConstant", .value = 0, .parameters = &.{} },
414 .{ .name = "RobustnessPerElementNV", .value = 0x0002, .parameters = &[_]OperandKind{} },563 .{ .name = "Input", .value = 1, .parameters = &.{} },
564 .{ .name = "Uniform", .value = 2, .parameters = &.{} },
565 .{ .name = "Output", .value = 3, .parameters = &.{} },
566 .{ .name = "Workgroup", .value = 4, .parameters = &.{} },
567 .{ .name = "CrossWorkgroup", .value = 5, .parameters = &.{} },
568 .{ .name = "Private", .value = 6, .parameters = &.{} },
569 .{ .name = "Function", .value = 7, .parameters = &.{} },
570 .{ .name = "Generic", .value = 8, .parameters = &.{} },
571 .{ .name = "PushConstant", .value = 9, .parameters = &.{} },
572 .{ .name = "AtomicCounter", .value = 10, .parameters = &.{} },
573 .{ .name = "Image", .value = 11, .parameters = &.{} },
574 .{ .name = "StorageBuffer", .value = 12, .parameters = &.{} },
575 .{ .name = "TileImageEXT", .value = 4172, .parameters = &.{} },
576 .{ .name = "TileAttachmentQCOM", .value = 4491, .parameters = &.{} },
577 .{ .name = "NodePayloadAMDX", .value = 5068, .parameters = &.{} },
578 .{ .name = "CallableDataKHR", .value = 5328, .parameters = &.{} },
579 .{ .name = "IncomingCallableDataKHR", .value = 5329, .parameters = &.{} },
580 .{ .name = "RayPayloadKHR", .value = 5338, .parameters = &.{} },
581 .{ .name = "HitAttributeKHR", .value = 5339, .parameters = &.{} },
582 .{ .name = "IncomingRayPayloadKHR", .value = 5342, .parameters = &.{} },
583 .{ .name = "ShaderRecordBufferKHR", .value = 5343, .parameters = &.{} },
584 .{ .name = "PhysicalStorageBuffer", .value = 5349, .parameters = &.{} },
585 .{ .name = "HitObjectAttributeNV", .value = 5385, .parameters = &.{} },
586 .{ .name = "TaskPayloadWorkgroupEXT", .value = 5402, .parameters = &.{} },
587 .{ .name = "CodeSectionINTEL", .value = 5605, .parameters = &.{} },
588 .{ .name = "DeviceOnlyINTEL", .value = 5936, .parameters = &.{} },
589 .{ .name = "HostOnlyINTEL", .value = 5937, .parameters = &.{} },
415 },590 },
416 .SourceLanguage => &[_]Enumerant{591 .dim => &.{
417 .{ .name = "Unknown", .value = 0, .parameters = &[_]OperandKind{} },592 .{ .name = "1D", .value = 0, .parameters = &.{} },
418 .{ .name = "ESSL", .value = 1, .parameters = &[_]OperandKind{} },593 .{ .name = "2D", .value = 1, .parameters = &.{} },
419 .{ .name = "GLSL", .value = 2, .parameters = &[_]OperandKind{} },594 .{ .name = "3D", .value = 2, .parameters = &.{} },
420 .{ .name = "OpenCL_C", .value = 3, .parameters = &[_]OperandKind{} },595 .{ .name = "Cube", .value = 3, .parameters = &.{} },
421 .{ .name = "OpenCL_CPP", .value = 4, .parameters = &[_]OperandKind{} },596 .{ .name = "Rect", .value = 4, .parameters = &.{} },
422 .{ .name = "HLSL", .value = 5, .parameters = &[_]OperandKind{} },597 .{ .name = "Buffer", .value = 5, .parameters = &.{} },
423 .{ .name = "CPP_for_OpenCL", .value = 6, .parameters = &[_]OperandKind{} },598 .{ .name = "SubpassData", .value = 6, .parameters = &.{} },
424 .{ .name = "SYCL", .value = 7, .parameters = &[_]OperandKind{} },599 .{ .name = "TileImageDataEXT", .value = 4173, .parameters = &.{} },
425 .{ .name = "HERO_C", .value = 8, .parameters = &[_]OperandKind{} },
426 .{ .name = "NZSL", .value = 9, .parameters = &[_]OperandKind{} },
427 .{ .name = "WGSL", .value = 10, .parameters = &[_]OperandKind{} },
428 .{ .name = "Slang", .value = 11, .parameters = &[_]OperandKind{} },
429 .{ .name = "Zig", .value = 12, .parameters = &[_]OperandKind{} },
430 },600 },
431 .ExecutionModel => &[_]Enumerant{601 .sampler_addressing_mode => &.{
432 .{ .name = "Vertex", .value = 0, .parameters = &[_]OperandKind{} },602 .{ .name = "None", .value = 0, .parameters = &.{} },
433 .{ .name = "TessellationControl", .value = 1, .parameters = &[_]OperandKind{} },603 .{ .name = "ClampToEdge", .value = 1, .parameters = &.{} },
434 .{ .name = "TessellationEvaluation", .value = 2, .parameters = &[_]OperandKind{} },604 .{ .name = "Clamp", .value = 2, .parameters = &.{} },
435 .{ .name = "Geometry", .value = 3, .parameters = &[_]OperandKind{} },605 .{ .name = "Repeat", .value = 3, .parameters = &.{} },
436 .{ .name = "Fragment", .value = 4, .parameters = &[_]OperandKind{} },606 .{ .name = "RepeatMirrored", .value = 4, .parameters = &.{} },
437 .{ .name = "GLCompute", .value = 5, .parameters = &[_]OperandKind{} },
438 .{ .name = "Kernel", .value = 6, .parameters = &[_]OperandKind{} },
439 .{ .name = "TaskNV", .value = 5267, .parameters = &[_]OperandKind{} },
440 .{ .name = "MeshNV", .value = 5268, .parameters = &[_]OperandKind{} },
441 .{ .name = "RayGenerationNV", .value = 5313, .parameters = &[_]OperandKind{} },
442 .{ .name = "RayGenerationKHR", .value = 5313, .parameters = &[_]OperandKind{} },
443 .{ .name = "IntersectionNV", .value = 5314, .parameters = &[_]OperandKind{} },
444 .{ .name = "IntersectionKHR", .value = 5314, .parameters = &[_]OperandKind{} },
445 .{ .name = "AnyHitNV", .value = 5315, .parameters = &[_]OperandKind{} },
446 .{ .name = "AnyHitKHR", .value = 5315, .parameters = &[_]OperandKind{} },
447 .{ .name = "ClosestHitNV", .value = 5316, .parameters = &[_]OperandKind{} },
448 .{ .name = "ClosestHitKHR", .value = 5316, .parameters = &[_]OperandKind{} },
449 .{ .name = "MissNV", .value = 5317, .parameters = &[_]OperandKind{} },
450 .{ .name = "MissKHR", .value = 5317, .parameters = &[_]OperandKind{} },
451 .{ .name = "CallableNV", .value = 5318, .parameters = &[_]OperandKind{} },
452 .{ .name = "CallableKHR", .value = 5318, .parameters = &[_]OperandKind{} },
453 .{ .name = "TaskEXT", .value = 5364, .parameters = &[_]OperandKind{} },
454 .{ .name = "MeshEXT", .value = 5365, .parameters = &[_]OperandKind{} },
455 },607 },
456 .AddressingModel => &[_]Enumerant{608 .sampler_filter_mode => &.{
457 .{ .name = "Logical", .value = 0, .parameters = &[_]OperandKind{} },609 .{ .name = "Nearest", .value = 0, .parameters = &.{} },
458 .{ .name = "Physical32", .value = 1, .parameters = &[_]OperandKind{} },610 .{ .name = "Linear", .value = 1, .parameters = &.{} },
459 .{ .name = "Physical64", .value = 2, .parameters = &[_]OperandKind{} },
460 .{ .name = "PhysicalStorageBuffer64", .value = 5348, .parameters = &[_]OperandKind{} },
461 .{ .name = "PhysicalStorageBuffer64EXT", .value = 5348, .parameters = &[_]OperandKind{} },
462 },611 },
463 .MemoryModel => &[_]Enumerant{612 .image_format => &.{
464 .{ .name = "Simple", .value = 0, .parameters = &[_]OperandKind{} },613 .{ .name = "Unknown", .value = 0, .parameters = &.{} },
465 .{ .name = "GLSL450", .value = 1, .parameters = &[_]OperandKind{} },614 .{ .name = "Rgba32f", .value = 1, .parameters = &.{} },
466 .{ .name = "OpenCL", .value = 2, .parameters = &[_]OperandKind{} },615 .{ .name = "Rgba16f", .value = 2, .parameters = &.{} },
467 .{ .name = "Vulkan", .value = 3, .parameters = &[_]OperandKind{} },616 .{ .name = "R32f", .value = 3, .parameters = &.{} },
468 .{ .name = "VulkanKHR", .value = 3, .parameters = &[_]OperandKind{} },617 .{ .name = "Rgba8", .value = 4, .parameters = &.{} },
618 .{ .name = "Rgba8Snorm", .value = 5, .parameters = &.{} },
619 .{ .name = "Rg32f", .value = 6, .parameters = &.{} },
620 .{ .name = "Rg16f", .value = 7, .parameters = &.{} },
621 .{ .name = "R11fG11fB10f", .value = 8, .parameters = &.{} },
622 .{ .name = "R16f", .value = 9, .parameters = &.{} },
623 .{ .name = "Rgba16", .value = 10, .parameters = &.{} },
624 .{ .name = "Rgb10A2", .value = 11, .parameters = &.{} },
625 .{ .name = "Rg16", .value = 12, .parameters = &.{} },
626 .{ .name = "Rg8", .value = 13, .parameters = &.{} },
627 .{ .name = "R16", .value = 14, .parameters = &.{} },
628 .{ .name = "R8", .value = 15, .parameters = &.{} },
629 .{ .name = "Rgba16Snorm", .value = 16, .parameters = &.{} },
630 .{ .name = "Rg16Snorm", .value = 17, .parameters = &.{} },
631 .{ .name = "Rg8Snorm", .value = 18, .parameters = &.{} },
632 .{ .name = "R16Snorm", .value = 19, .parameters = &.{} },
633 .{ .name = "R8Snorm", .value = 20, .parameters = &.{} },
634 .{ .name = "Rgba32i", .value = 21, .parameters = &.{} },
635 .{ .name = "Rgba16i", .value = 22, .parameters = &.{} },
636 .{ .name = "Rgba8i", .value = 23, .parameters = &.{} },
637 .{ .name = "R32i", .value = 24, .parameters = &.{} },
638 .{ .name = "Rg32i", .value = 25, .parameters = &.{} },
639 .{ .name = "Rg16i", .value = 26, .parameters = &.{} },
640 .{ .name = "Rg8i", .value = 27, .parameters = &.{} },
641 .{ .name = "R16i", .value = 28, .parameters = &.{} },
642 .{ .name = "R8i", .value = 29, .parameters = &.{} },
643 .{ .name = "Rgba32ui", .value = 30, .parameters = &.{} },
644 .{ .name = "Rgba16ui", .value = 31, .parameters = &.{} },
645 .{ .name = "Rgba8ui", .value = 32, .parameters = &.{} },
646 .{ .name = "R32ui", .value = 33, .parameters = &.{} },
647 .{ .name = "Rgb10a2ui", .value = 34, .parameters = &.{} },
648 .{ .name = "Rg32ui", .value = 35, .parameters = &.{} },
649 .{ .name = "Rg16ui", .value = 36, .parameters = &.{} },
650 .{ .name = "Rg8ui", .value = 37, .parameters = &.{} },
651 .{ .name = "R16ui", .value = 38, .parameters = &.{} },
652 .{ .name = "R8ui", .value = 39, .parameters = &.{} },
653 .{ .name = "R64ui", .value = 40, .parameters = &.{} },
654 .{ .name = "R64i", .value = 41, .parameters = &.{} },
469 },655 },
470 .ExecutionMode => &[_]Enumerant{656 .image_channel_order => &.{
471 .{ .name = "Invocations", .value = 0, .parameters = &[_]OperandKind{.LiteralInteger} },657 .{ .name = "R", .value = 0, .parameters = &.{} },
472 .{ .name = "SpacingEqual", .value = 1, .parameters = &[_]OperandKind{} },658 .{ .name = "A", .value = 1, .parameters = &.{} },
473 .{ .name = "SpacingFractionalEven", .value = 2, .parameters = &[_]OperandKind{} },659 .{ .name = "RG", .value = 2, .parameters = &.{} },
474 .{ .name = "SpacingFractionalOdd", .value = 3, .parameters = &[_]OperandKind{} },660 .{ .name = "RA", .value = 3, .parameters = &.{} },
475 .{ .name = "VertexOrderCw", .value = 4, .parameters = &[_]OperandKind{} },661 .{ .name = "RGB", .value = 4, .parameters = &.{} },
476 .{ .name = "VertexOrderCcw", .value = 5, .parameters = &[_]OperandKind{} },662 .{ .name = "RGBA", .value = 5, .parameters = &.{} },
477 .{ .name = "PixelCenterInteger", .value = 6, .parameters = &[_]OperandKind{} },663 .{ .name = "BGRA", .value = 6, .parameters = &.{} },
478 .{ .name = "OriginUpperLeft", .value = 7, .parameters = &[_]OperandKind{} },664 .{ .name = "ARGB", .value = 7, .parameters = &.{} },
479 .{ .name = "OriginLowerLeft", .value = 8, .parameters = &[_]OperandKind{} },665 .{ .name = "Intensity", .value = 8, .parameters = &.{} },
480 .{ .name = "EarlyFragmentTests", .value = 9, .parameters = &[_]OperandKind{} },666 .{ .name = "Luminance", .value = 9, .parameters = &.{} },
481 .{ .name = "PointMode", .value = 10, .parameters = &[_]OperandKind{} },667 .{ .name = "Rx", .value = 10, .parameters = &.{} },
482 .{ .name = "Xfb", .value = 11, .parameters = &[_]OperandKind{} },668 .{ .name = "RGx", .value = 11, .parameters = &.{} },
483 .{ .name = "DepthReplacing", .value = 12, .parameters = &[_]OperandKind{} },669 .{ .name = "RGBx", .value = 12, .parameters = &.{} },
484 .{ .name = "DepthGreater", .value = 14, .parameters = &[_]OperandKind{} },670 .{ .name = "Depth", .value = 13, .parameters = &.{} },
485 .{ .name = "DepthLess", .value = 15, .parameters = &[_]OperandKind{} },671 .{ .name = "DepthStencil", .value = 14, .parameters = &.{} },
486 .{ .name = "DepthUnchanged", .value = 16, .parameters = &[_]OperandKind{} },672 .{ .name = "sRGB", .value = 15, .parameters = &.{} },
487 .{ .name = "LocalSize", .value = 17, .parameters = &[_]OperandKind{ .LiteralInteger, .LiteralInteger, .LiteralInteger } },673 .{ .name = "sRGBx", .value = 16, .parameters = &.{} },
488 .{ .name = "LocalSizeHint", .value = 18, .parameters = &[_]OperandKind{ .LiteralInteger, .LiteralInteger, .LiteralInteger } },674 .{ .name = "sRGBA", .value = 17, .parameters = &.{} },
489 .{ .name = "InputPoints", .value = 19, .parameters = &[_]OperandKind{} },675 .{ .name = "sBGRA", .value = 18, .parameters = &.{} },
490 .{ .name = "InputLines", .value = 20, .parameters = &[_]OperandKind{} },676 .{ .name = "ABGR", .value = 19, .parameters = &.{} },
491 .{ .name = "InputLinesAdjacency", .value = 21, .parameters = &[_]OperandKind{} },
492 .{ .name = "Triangles", .value = 22, .parameters = &[_]OperandKind{} },
493 .{ .name = "InputTrianglesAdjacency", .value = 23, .parameters = &[_]OperandKind{} },
494 .{ .name = "Quads", .value = 24, .parameters = &[_]OperandKind{} },
495 .{ .name = "Isolines", .value = 25, .parameters = &[_]OperandKind{} },
496 .{ .name = "OutputVertices", .value = 26, .parameters = &[_]OperandKind{.LiteralInteger} },
497 .{ .name = "OutputPoints", .value = 27, .parameters = &[_]OperandKind{} },
498 .{ .name = "OutputLineStrip", .value = 28, .parameters = &[_]OperandKind{} },
499 .{ .name = "OutputTriangleStrip", .value = 29, .parameters = &[_]OperandKind{} },
500 .{ .name = "VecTypeHint", .value = 30, .parameters = &[_]OperandKind{.LiteralInteger} },
501 .{ .name = "ContractionOff", .value = 31, .parameters = &[_]OperandKind{} },
502 .{ .name = "Initializer", .value = 33, .parameters = &[_]OperandKind{} },
503 .{ .name = "Finalizer", .value = 34, .parameters = &[_]OperandKind{} },
504 .{ .name = "SubgroupSize", .value = 35, .parameters = &[_]OperandKind{.LiteralInteger} },
505 .{ .name = "SubgroupsPerWorkgroup", .value = 36, .parameters = &[_]OperandKind{.LiteralInteger} },
506 .{ .name = "SubgroupsPerWorkgroupId", .value = 37, .parameters = &[_]OperandKind{.IdRef} },
507 .{ .name = "LocalSizeId", .value = 38, .parameters = &[_]OperandKind{ .IdRef, .IdRef, .IdRef } },
508 .{ .name = "LocalSizeHintId", .value = 39, .parameters = &[_]OperandKind{ .IdRef, .IdRef, .IdRef } },
509 .{ .name = "NonCoherentColorAttachmentReadEXT", .value = 4169, .parameters = &[_]OperandKind{} },
510 .{ .name = "NonCoherentDepthAttachmentReadEXT", .value = 4170, .parameters = &[_]OperandKind{} },
511 .{ .name = "NonCoherentStencilAttachmentReadEXT", .value = 4171, .parameters = &[_]OperandKind{} },
512 .{ .name = "SubgroupUniformControlFlowKHR", .value = 4421, .parameters = &[_]OperandKind{} },
513 .{ .name = "PostDepthCoverage", .value = 4446, .parameters = &[_]OperandKind{} },
514 .{ .name = "DenormPreserve", .value = 4459, .parameters = &[_]OperandKind{.LiteralInteger} },
515 .{ .name = "DenormFlushToZero", .value = 4460, .parameters = &[_]OperandKind{.LiteralInteger} },
516 .{ .name = "SignedZeroInfNanPreserve", .value = 4461, .parameters = &[_]OperandKind{.LiteralInteger} },
517 .{ .name = "RoundingModeRTE", .value = 4462, .parameters = &[_]OperandKind{.LiteralInteger} },
518 .{ .name = "RoundingModeRTZ", .value = 4463, .parameters = &[_]OperandKind{.LiteralInteger} },
519 .{ .name = "EarlyAndLateFragmentTestsAMD", .value = 5017, .parameters = &[_]OperandKind{} },
520 .{ .name = "StencilRefReplacingEXT", .value = 5027, .parameters = &[_]OperandKind{} },
521 .{ .name = "CoalescingAMDX", .value = 5069, .parameters = &[_]OperandKind{} },
522 .{ .name = "MaxNodeRecursionAMDX", .value = 5071, .parameters = &[_]OperandKind{.IdRef} },
523 .{ .name = "StaticNumWorkgroupsAMDX", .value = 5072, .parameters = &[_]OperandKind{ .IdRef, .IdRef, .IdRef } },
524 .{ .name = "ShaderIndexAMDX", .value = 5073, .parameters = &[_]OperandKind{.IdRef} },
525 .{ .name = "MaxNumWorkgroupsAMDX", .value = 5077, .parameters = &[_]OperandKind{ .IdRef, .IdRef, .IdRef } },
526 .{ .name = "StencilRefUnchangedFrontAMD", .value = 5079, .parameters = &[_]OperandKind{} },
527 .{ .name = "StencilRefGreaterFrontAMD", .value = 5080, .parameters = &[_]OperandKind{} },
528 .{ .name = "StencilRefLessFrontAMD", .value = 5081, .parameters = &[_]OperandKind{} },
529 .{ .name = "StencilRefUnchangedBackAMD", .value = 5082, .parameters = &[_]OperandKind{} },
530 .{ .name = "StencilRefGreaterBackAMD", .value = 5083, .parameters = &[_]OperandKind{} },
531 .{ .name = "StencilRefLessBackAMD", .value = 5084, .parameters = &[_]OperandKind{} },
532 .{ .name = "QuadDerivativesKHR", .value = 5088, .parameters = &[_]OperandKind{} },
533 .{ .name = "RequireFullQuadsKHR", .value = 5089, .parameters = &[_]OperandKind{} },
534 .{ .name = "OutputLinesNV", .value = 5269, .parameters = &[_]OperandKind{} },
535 .{ .name = "OutputLinesEXT", .value = 5269, .parameters = &[_]OperandKind{} },
536 .{ .name = "OutputPrimitivesNV", .value = 5270, .parameters = &[_]OperandKind{.LiteralInteger} },
537 .{ .name = "OutputPrimitivesEXT", .value = 5270, .parameters = &[_]OperandKind{.LiteralInteger} },
538 .{ .name = "DerivativeGroupQuadsNV", .value = 5289, .parameters = &[_]OperandKind{} },
539 .{ .name = "DerivativeGroupLinearNV", .value = 5290, .parameters = &[_]OperandKind{} },
540 .{ .name = "OutputTrianglesNV", .value = 5298, .parameters = &[_]OperandKind{} },
541 .{ .name = "OutputTrianglesEXT", .value = 5298, .parameters = &[_]OperandKind{} },
542 .{ .name = "PixelInterlockOrderedEXT", .value = 5366, .parameters = &[_]OperandKind{} },
543 .{ .name = "PixelInterlockUnorderedEXT", .value = 5367, .parameters = &[_]OperandKind{} },
544 .{ .name = "SampleInterlockOrderedEXT", .value = 5368, .parameters = &[_]OperandKind{} },
545 .{ .name = "SampleInterlockUnorderedEXT", .value = 5369, .parameters = &[_]OperandKind{} },
546 .{ .name = "ShadingRateInterlockOrderedEXT", .value = 5370, .parameters = &[_]OperandKind{} },
547 .{ .name = "ShadingRateInterlockUnorderedEXT", .value = 5371, .parameters = &[_]OperandKind{} },
548 .{ .name = "SharedLocalMemorySizeINTEL", .value = 5618, .parameters = &[_]OperandKind{.LiteralInteger} },
549 .{ .name = "RoundingModeRTPINTEL", .value = 5620, .parameters = &[_]OperandKind{.LiteralInteger} },
550 .{ .name = "RoundingModeRTNINTEL", .value = 5621, .parameters = &[_]OperandKind{.LiteralInteger} },
551 .{ .name = "FloatingPointModeALTINTEL", .value = 5622, .parameters = &[_]OperandKind{.LiteralInteger} },
552 .{ .name = "FloatingPointModeIEEEINTEL", .value = 5623, .parameters = &[_]OperandKind{.LiteralInteger} },
553 .{ .name = "MaxWorkgroupSizeINTEL", .value = 5893, .parameters = &[_]OperandKind{ .LiteralInteger, .LiteralInteger, .LiteralInteger } },
554 .{ .name = "MaxWorkDimINTEL", .value = 5894, .parameters = &[_]OperandKind{.LiteralInteger} },
555 .{ .name = "NoGlobalOffsetINTEL", .value = 5895, .parameters = &[_]OperandKind{} },
556 .{ .name = "NumSIMDWorkitemsINTEL", .value = 5896, .parameters = &[_]OperandKind{.LiteralInteger} },
557 .{ .name = "SchedulerTargetFmaxMhzINTEL", .value = 5903, .parameters = &[_]OperandKind{.LiteralInteger} },
558 .{ .name = "MaximallyReconvergesKHR", .value = 6023, .parameters = &[_]OperandKind{} },
559 .{ .name = "FPFastMathDefault", .value = 6028, .parameters = &[_]OperandKind{ .IdRef, .IdRef } },
560 .{ .name = "StreamingInterfaceINTEL", .value = 6154, .parameters = &[_]OperandKind{.LiteralInteger} },
561 .{ .name = "RegisterMapInterfaceINTEL", .value = 6160, .parameters = &[_]OperandKind{.LiteralInteger} },
562 .{ .name = "NamedBarrierCountINTEL", .value = 6417, .parameters = &[_]OperandKind{.LiteralInteger} },
563 .{ .name = "MaximumRegistersINTEL", .value = 6461, .parameters = &[_]OperandKind{.LiteralInteger} },
564 .{ .name = "MaximumRegistersIdINTEL", .value = 6462, .parameters = &[_]OperandKind{.IdRef} },
565 .{ .name = "NamedMaximumRegistersINTEL", .value = 6463, .parameters = &[_]OperandKind{.NamedMaximumNumberOfRegisters} },
566 },677 },
567 .StorageClass => &[_]Enumerant{678 .image_channel_data_type => &.{
568 .{ .name = "UniformConstant", .value = 0, .parameters = &[_]OperandKind{} },679 .{ .name = "SnormInt8", .value = 0, .parameters = &.{} },
569 .{ .name = "Input", .value = 1, .parameters = &[_]OperandKind{} },680 .{ .name = "SnormInt16", .value = 1, .parameters = &.{} },
570 .{ .name = "Uniform", .value = 2, .parameters = &[_]OperandKind{} },681 .{ .name = "UnormInt8", .value = 2, .parameters = &.{} },
571 .{ .name = "Output", .value = 3, .parameters = &[_]OperandKind{} },682 .{ .name = "UnormInt16", .value = 3, .parameters = &.{} },
572 .{ .name = "Workgroup", .value = 4, .parameters = &[_]OperandKind{} },683 .{ .name = "UnormShort565", .value = 4, .parameters = &.{} },
573 .{ .name = "CrossWorkgroup", .value = 5, .parameters = &[_]OperandKind{} },684 .{ .name = "UnormShort555", .value = 5, .parameters = &.{} },
574 .{ .name = "Private", .value = 6, .parameters = &[_]OperandKind{} },685 .{ .name = "UnormInt101010", .value = 6, .parameters = &.{} },
575 .{ .name = "Function", .value = 7, .parameters = &[_]OperandKind{} },686 .{ .name = "SignedInt8", .value = 7, .parameters = &.{} },
576 .{ .name = "Generic", .value = 8, .parameters = &[_]OperandKind{} },687 .{ .name = "SignedInt16", .value = 8, .parameters = &.{} },
577 .{ .name = "PushConstant", .value = 9, .parameters = &[_]OperandKind{} },688 .{ .name = "SignedInt32", .value = 9, .parameters = &.{} },
578 .{ .name = "AtomicCounter", .value = 10, .parameters = &[_]OperandKind{} },689 .{ .name = "UnsignedInt8", .value = 10, .parameters = &.{} },
579 .{ .name = "Image", .value = 11, .parameters = &[_]OperandKind{} },690 .{ .name = "UnsignedInt16", .value = 11, .parameters = &.{} },
580 .{ .name = "StorageBuffer", .value = 12, .parameters = &[_]OperandKind{} },691 .{ .name = "UnsignedInt32", .value = 12, .parameters = &.{} },
581 .{ .name = "TileImageEXT", .value = 4172, .parameters = &[_]OperandKind{} },692 .{ .name = "HalfFloat", .value = 13, .parameters = &.{} },
582 .{ .name = "NodePayloadAMDX", .value = 5068, .parameters = &[_]OperandKind{} },693 .{ .name = "Float", .value = 14, .parameters = &.{} },
583 .{ .name = "NodeOutputPayloadAMDX", .value = 5076, .parameters = &[_]OperandKind{} },694 .{ .name = "UnormInt24", .value = 15, .parameters = &.{} },
584 .{ .name = "CallableDataNV", .value = 5328, .parameters = &[_]OperandKind{} },695 .{ .name = "UnormInt101010_2", .value = 16, .parameters = &.{} },
585 .{ .name = "CallableDataKHR", .value = 5328, .parameters = &[_]OperandKind{} },696 .{ .name = "UnormInt10X6EXT", .value = 17, .parameters = &.{} },
586 .{ .name = "IncomingCallableDataNV", .value = 5329, .parameters = &[_]OperandKind{} },697 .{ .name = "UnsignedIntRaw10EXT", .value = 19, .parameters = &.{} },
587 .{ .name = "IncomingCallableDataKHR", .value = 5329, .parameters = &[_]OperandKind{} },698 .{ .name = "UnsignedIntRaw12EXT", .value = 20, .parameters = &.{} },
588 .{ .name = "RayPayloadNV", .value = 5338, .parameters = &[_]OperandKind{} },699 .{ .name = "UnormInt2_101010EXT", .value = 21, .parameters = &.{} },
589 .{ .name = "RayPayloadKHR", .value = 5338, .parameters = &[_]OperandKind{} },700 .{ .name = "UnsignedInt10X6EXT", .value = 22, .parameters = &.{} },
590 .{ .name = "HitAttributeNV", .value = 5339, .parameters = &[_]OperandKind{} },701 .{ .name = "UnsignedInt12X4EXT", .value = 23, .parameters = &.{} },
591 .{ .name = "HitAttributeKHR", .value = 5339, .parameters = &[_]OperandKind{} },702 .{ .name = "UnsignedInt14X2EXT", .value = 24, .parameters = &.{} },
592 .{ .name = "IncomingRayPayloadNV", .value = 5342, .parameters = &[_]OperandKind{} },703 .{ .name = "UnormInt12X4EXT", .value = 25, .parameters = &.{} },
593 .{ .name = "IncomingRayPayloadKHR", .value = 5342, .parameters = &[_]OperandKind{} },704 .{ .name = "UnormInt14X2EXT", .value = 26, .parameters = &.{} },
594 .{ .name = "ShaderRecordBufferNV", .value = 5343, .parameters = &[_]OperandKind{} },
595 .{ .name = "ShaderRecordBufferKHR", .value = 5343, .parameters = &[_]OperandKind{} },
596 .{ .name = "PhysicalStorageBuffer", .value = 5349, .parameters = &[_]OperandKind{} },
597 .{ .name = "PhysicalStorageBufferEXT", .value = 5349, .parameters = &[_]OperandKind{} },
598 .{ .name = "HitObjectAttributeNV", .value = 5385, .parameters = &[_]OperandKind{} },
599 .{ .name = "TaskPayloadWorkgroupEXT", .value = 5402, .parameters = &[_]OperandKind{} },
600 .{ .name = "CodeSectionINTEL", .value = 5605, .parameters = &[_]OperandKind{} },
601 .{ .name = "DeviceOnlyINTEL", .value = 5936, .parameters = &[_]OperandKind{} },
602 .{ .name = "HostOnlyINTEL", .value = 5937, .parameters = &[_]OperandKind{} },
603 },705 },
604 .Dim => &[_]Enumerant{706 .fp_rounding_mode => &.{
605 .{ .name = "1D", .value = 0, .parameters = &[_]OperandKind{} },707 .{ .name = "RTE", .value = 0, .parameters = &.{} },
606 .{ .name = "2D", .value = 1, .parameters = &[_]OperandKind{} },708 .{ .name = "RTZ", .value = 1, .parameters = &.{} },
607 .{ .name = "3D", .value = 2, .parameters = &[_]OperandKind{} },709 .{ .name = "RTP", .value = 2, .parameters = &.{} },
608 .{ .name = "Cube", .value = 3, .parameters = &[_]OperandKind{} },710 .{ .name = "RTN", .value = 3, .parameters = &.{} },
609 .{ .name = "Rect", .value = 4, .parameters = &[_]OperandKind{} },
610 .{ .name = "Buffer", .value = 5, .parameters = &[_]OperandKind{} },
611 .{ .name = "SubpassData", .value = 6, .parameters = &[_]OperandKind{} },
612 .{ .name = "TileImageDataEXT", .value = 4173, .parameters = &[_]OperandKind{} },
613 },711 },
614 .SamplerAddressingMode => &[_]Enumerant{712 .fp_denorm_mode => &.{
615 .{ .name = "None", .value = 0, .parameters = &[_]OperandKind{} },713 .{ .name = "Preserve", .value = 0, .parameters = &.{} },
616 .{ .name = "ClampToEdge", .value = 1, .parameters = &[_]OperandKind{} },714 .{ .name = "FlushToZero", .value = 1, .parameters = &.{} },
617 .{ .name = "Clamp", .value = 2, .parameters = &[_]OperandKind{} },
618 .{ .name = "Repeat", .value = 3, .parameters = &[_]OperandKind{} },
619 .{ .name = "RepeatMirrored", .value = 4, .parameters = &[_]OperandKind{} },
620 },715 },
621 .SamplerFilterMode => &[_]Enumerant{716 .quantization_modes => &.{
622 .{ .name = "Nearest", .value = 0, .parameters = &[_]OperandKind{} },717 .{ .name = "TRN", .value = 0, .parameters = &.{} },
623 .{ .name = "Linear", .value = 1, .parameters = &[_]OperandKind{} },718 .{ .name = "TRN_ZERO", .value = 1, .parameters = &.{} },
719 .{ .name = "RND", .value = 2, .parameters = &.{} },
720 .{ .name = "RND_ZERO", .value = 3, .parameters = &.{} },
721 .{ .name = "RND_INF", .value = 4, .parameters = &.{} },
722 .{ .name = "RND_MIN_INF", .value = 5, .parameters = &.{} },
723 .{ .name = "RND_CONV", .value = 6, .parameters = &.{} },
724 .{ .name = "RND_CONV_ODD", .value = 7, .parameters = &.{} },
624 },725 },
625 .ImageFormat => &[_]Enumerant{726 .fp_operation_mode => &.{
626 .{ .name = "Unknown", .value = 0, .parameters = &[_]OperandKind{} },727 .{ .name = "IEEE", .value = 0, .parameters = &.{} },
627 .{ .name = "Rgba32f", .value = 1, .parameters = &[_]OperandKind{} },728 .{ .name = "ALT", .value = 1, .parameters = &.{} },
628 .{ .name = "Rgba16f", .value = 2, .parameters = &[_]OperandKind{} },
629 .{ .name = "R32f", .value = 3, .parameters = &[_]OperandKind{} },
630 .{ .name = "Rgba8", .value = 4, .parameters = &[_]OperandKind{} },
631 .{ .name = "Rgba8Snorm", .value = 5, .parameters = &[_]OperandKind{} },
632 .{ .name = "Rg32f", .value = 6, .parameters = &[_]OperandKind{} },
633 .{ .name = "Rg16f", .value = 7, .parameters = &[_]OperandKind{} },
634 .{ .name = "R11fG11fB10f", .value = 8, .parameters = &[_]OperandKind{} },
635 .{ .name = "R16f", .value = 9, .parameters = &[_]OperandKind{} },
636 .{ .name = "Rgba16", .value = 10, .parameters = &[_]OperandKind{} },
637 .{ .name = "Rgb10A2", .value = 11, .parameters = &[_]OperandKind{} },
638 .{ .name = "Rg16", .value = 12, .parameters = &[_]OperandKind{} },
639 .{ .name = "Rg8", .value = 13, .parameters = &[_]OperandKind{} },
640 .{ .name = "R16", .value = 14, .parameters = &[_]OperandKind{} },
641 .{ .name = "R8", .value = 15, .parameters = &[_]OperandKind{} },
642 .{ .name = "Rgba16Snorm", .value = 16, .parameters = &[_]OperandKind{} },
643 .{ .name = "Rg16Snorm", .value = 17, .parameters = &[_]OperandKind{} },
644 .{ .name = "Rg8Snorm", .value = 18, .parameters = &[_]OperandKind{} },
645 .{ .name = "R16Snorm", .value = 19, .parameters = &[_]OperandKind{} },
646 .{ .name = "R8Snorm", .value = 20, .parameters = &[_]OperandKind{} },
647 .{ .name = "Rgba32i", .value = 21, .parameters = &[_]OperandKind{} },
648 .{ .name = "Rgba16i", .value = 22, .parameters = &[_]OperandKind{} },
649 .{ .name = "Rgba8i", .value = 23, .parameters = &[_]OperandKind{} },
650 .{ .name = "R32i", .value = 24, .parameters = &[_]OperandKind{} },
651 .{ .name = "Rg32i", .value = 25, .parameters = &[_]OperandKind{} },
652 .{ .name = "Rg16i", .value = 26, .parameters = &[_]OperandKind{} },
653 .{ .name = "Rg8i", .value = 27, .parameters = &[_]OperandKind{} },
654 .{ .name = "R16i", .value = 28, .parameters = &[_]OperandKind{} },
655 .{ .name = "R8i", .value = 29, .parameters = &[_]OperandKind{} },
656 .{ .name = "Rgba32ui", .value = 30, .parameters = &[_]OperandKind{} },
657 .{ .name = "Rgba16ui", .value = 31, .parameters = &[_]OperandKind{} },
658 .{ .name = "Rgba8ui", .value = 32, .parameters = &[_]OperandKind{} },
659 .{ .name = "R32ui", .value = 33, .parameters = &[_]OperandKind{} },
660 .{ .name = "Rgb10a2ui", .value = 34, .parameters = &[_]OperandKind{} },
661 .{ .name = "Rg32ui", .value = 35, .parameters = &[_]OperandKind{} },
662 .{ .name = "Rg16ui", .value = 36, .parameters = &[_]OperandKind{} },
663 .{ .name = "Rg8ui", .value = 37, .parameters = &[_]OperandKind{} },
664 .{ .name = "R16ui", .value = 38, .parameters = &[_]OperandKind{} },
665 .{ .name = "R8ui", .value = 39, .parameters = &[_]OperandKind{} },
666 .{ .name = "R64ui", .value = 40, .parameters = &[_]OperandKind{} },
667 .{ .name = "R64i", .value = 41, .parameters = &[_]OperandKind{} },
668 },729 },
669 .ImageChannelOrder => &[_]Enumerant{730 .overflow_modes => &.{
670 .{ .name = "R", .value = 0, .parameters = &[_]OperandKind{} },731 .{ .name = "WRAP", .value = 0, .parameters = &.{} },
671 .{ .name = "A", .value = 1, .parameters = &[_]OperandKind{} },732 .{ .name = "SAT", .value = 1, .parameters = &.{} },
672 .{ .name = "RG", .value = 2, .parameters = &[_]OperandKind{} },733 .{ .name = "SAT_ZERO", .value = 2, .parameters = &.{} },
673 .{ .name = "RA", .value = 3, .parameters = &[_]OperandKind{} },734 .{ .name = "SAT_SYM", .value = 3, .parameters = &.{} },
674 .{ .name = "RGB", .value = 4, .parameters = &[_]OperandKind{} },
675 .{ .name = "RGBA", .value = 5, .parameters = &[_]OperandKind{} },
676 .{ .name = "BGRA", .value = 6, .parameters = &[_]OperandKind{} },
677 .{ .name = "ARGB", .value = 7, .parameters = &[_]OperandKind{} },
678 .{ .name = "Intensity", .value = 8, .parameters = &[_]OperandKind{} },
679 .{ .name = "Luminance", .value = 9, .parameters = &[_]OperandKind{} },
680 .{ .name = "Rx", .value = 10, .parameters = &[_]OperandKind{} },
681 .{ .name = "RGx", .value = 11, .parameters = &[_]OperandKind{} },
682 .{ .name = "RGBx", .value = 12, .parameters = &[_]OperandKind{} },
683 .{ .name = "Depth", .value = 13, .parameters = &[_]OperandKind{} },
684 .{ .name = "DepthStencil", .value = 14, .parameters = &[_]OperandKind{} },
685 .{ .name = "sRGB", .value = 15, .parameters = &[_]OperandKind{} },
686 .{ .name = "sRGBx", .value = 16, .parameters = &[_]OperandKind{} },
687 .{ .name = "sRGBA", .value = 17, .parameters = &[_]OperandKind{} },
688 .{ .name = "sBGRA", .value = 18, .parameters = &[_]OperandKind{} },
689 .{ .name = "ABGR", .value = 19, .parameters = &[_]OperandKind{} },
690 },735 },
691 .ImageChannelDataType => &[_]Enumerant{736 .linkage_type => &.{
692 .{ .name = "SnormInt8", .value = 0, .parameters = &[_]OperandKind{} },737 .{ .name = "Export", .value = 0, .parameters = &.{} },
693 .{ .name = "SnormInt16", .value = 1, .parameters = &[_]OperandKind{} },738 .{ .name = "Import", .value = 1, .parameters = &.{} },
694 .{ .name = "UnormInt8", .value = 2, .parameters = &[_]OperandKind{} },739 .{ .name = "LinkOnceODR", .value = 2, .parameters = &.{} },
695 .{ .name = "UnormInt16", .value = 3, .parameters = &[_]OperandKind{} },
696 .{ .name = "UnormShort565", .value = 4, .parameters = &[_]OperandKind{} },
697 .{ .name = "UnormShort555", .value = 5, .parameters = &[_]OperandKind{} },
698 .{ .name = "UnormInt101010", .value = 6, .parameters = &[_]OperandKind{} },
699 .{ .name = "SignedInt8", .value = 7, .parameters = &[_]OperandKind{} },
700 .{ .name = "SignedInt16", .value = 8, .parameters = &[_]OperandKind{} },
701 .{ .name = "SignedInt32", .value = 9, .parameters = &[_]OperandKind{} },
702 .{ .name = "UnsignedInt8", .value = 10, .parameters = &[_]OperandKind{} },
703 .{ .name = "UnsignedInt16", .value = 11, .parameters = &[_]OperandKind{} },
704 .{ .name = "UnsignedInt32", .value = 12, .parameters = &[_]OperandKind{} },
705 .{ .name = "HalfFloat", .value = 13, .parameters = &[_]OperandKind{} },
706 .{ .name = "Float", .value = 14, .parameters = &[_]OperandKind{} },
707 .{ .name = "UnormInt24", .value = 15, .parameters = &[_]OperandKind{} },
708 .{ .name = "UnormInt101010_2", .value = 16, .parameters = &[_]OperandKind{} },
709 .{ .name = "UnsignedIntRaw10EXT", .value = 19, .parameters = &[_]OperandKind{} },
710 .{ .name = "UnsignedIntRaw12EXT", .value = 20, .parameters = &[_]OperandKind{} },
711 },740 },
712 .FPRoundingMode => &[_]Enumerant{741 .access_qualifier => &.{
713 .{ .name = "RTE", .value = 0, .parameters = &[_]OperandKind{} },742 .{ .name = "ReadOnly", .value = 0, .parameters = &.{} },
714 .{ .name = "RTZ", .value = 1, .parameters = &[_]OperandKind{} },743 .{ .name = "WriteOnly", .value = 1, .parameters = &.{} },
715 .{ .name = "RTP", .value = 2, .parameters = &[_]OperandKind{} },744 .{ .name = "ReadWrite", .value = 2, .parameters = &.{} },
716 .{ .name = "RTN", .value = 3, .parameters = &[_]OperandKind{} },
717 },745 },
718 .FPDenormMode => &[_]Enumerant{746 .host_access_qualifier => &.{
719 .{ .name = "Preserve", .value = 0, .parameters = &[_]OperandKind{} },747 .{ .name = "NoneINTEL", .value = 0, .parameters = &.{} },
720 .{ .name = "FlushToZero", .value = 1, .parameters = &[_]OperandKind{} },748 .{ .name = "ReadINTEL", .value = 1, .parameters = &.{} },
749 .{ .name = "WriteINTEL", .value = 2, .parameters = &.{} },
750 .{ .name = "ReadWriteINTEL", .value = 3, .parameters = &.{} },
721 },751 },
722 .QuantizationModes => &[_]Enumerant{752 .function_parameter_attribute => &.{
723 .{ .name = "TRN", .value = 0, .parameters = &[_]OperandKind{} },753 .{ .name = "Zext", .value = 0, .parameters = &.{} },
724 .{ .name = "TRN_ZERO", .value = 1, .parameters = &[_]OperandKind{} },754 .{ .name = "Sext", .value = 1, .parameters = &.{} },
725 .{ .name = "RND", .value = 2, .parameters = &[_]OperandKind{} },755 .{ .name = "ByVal", .value = 2, .parameters = &.{} },
726 .{ .name = "RND_ZERO", .value = 3, .parameters = &[_]OperandKind{} },756 .{ .name = "Sret", .value = 3, .parameters = &.{} },
727 .{ .name = "RND_INF", .value = 4, .parameters = &[_]OperandKind{} },757 .{ .name = "NoAlias", .value = 4, .parameters = &.{} },
728 .{ .name = "RND_MIN_INF", .value = 5, .parameters = &[_]OperandKind{} },758 .{ .name = "NoCapture", .value = 5, .parameters = &.{} },
729 .{ .name = "RND_CONV", .value = 6, .parameters = &[_]OperandKind{} },759 .{ .name = "NoWrite", .value = 6, .parameters = &.{} },
730 .{ .name = "RND_CONV_ODD", .value = 7, .parameters = &[_]OperandKind{} },760 .{ .name = "NoReadWrite", .value = 7, .parameters = &.{} },
761 .{ .name = "RuntimeAlignedINTEL", .value = 5940, .parameters = &.{} },
731 },762 },
732 .FPOperationMode => &[_]Enumerant{763 .decoration => &.{
733 .{ .name = "IEEE", .value = 0, .parameters = &[_]OperandKind{} },764 .{ .name = "RelaxedPrecision", .value = 0, .parameters = &.{} },
734 .{ .name = "ALT", .value = 1, .parameters = &[_]OperandKind{} },765 .{ .name = "SpecId", .value = 1, .parameters = &.{.literal_integer} },
766 .{ .name = "Block", .value = 2, .parameters = &.{} },
767 .{ .name = "BufferBlock", .value = 3, .parameters = &.{} },
768 .{ .name = "RowMajor", .value = 4, .parameters = &.{} },
769 .{ .name = "ColMajor", .value = 5, .parameters = &.{} },
770 .{ .name = "ArrayStride", .value = 6, .parameters = &.{.literal_integer} },
771 .{ .name = "MatrixStride", .value = 7, .parameters = &.{.literal_integer} },
772 .{ .name = "GLSLShared", .value = 8, .parameters = &.{} },
773 .{ .name = "GLSLPacked", .value = 9, .parameters = &.{} },
774 .{ .name = "CPacked", .value = 10, .parameters = &.{} },
775 .{ .name = "BuiltIn", .value = 11, .parameters = &.{.built_in} },
776 .{ .name = "NoPerspective", .value = 13, .parameters = &.{} },
777 .{ .name = "Flat", .value = 14, .parameters = &.{} },
778 .{ .name = "Patch", .value = 15, .parameters = &.{} },
779 .{ .name = "Centroid", .value = 16, .parameters = &.{} },
780 .{ .name = "Sample", .value = 17, .parameters = &.{} },
781 .{ .name = "Invariant", .value = 18, .parameters = &.{} },
782 .{ .name = "Restrict", .value = 19, .parameters = &.{} },
783 .{ .name = "Aliased", .value = 20, .parameters = &.{} },
784 .{ .name = "Volatile", .value = 21, .parameters = &.{} },
785 .{ .name = "Constant", .value = 22, .parameters = &.{} },
786 .{ .name = "Coherent", .value = 23, .parameters = &.{} },
787 .{ .name = "NonWritable", .value = 24, .parameters = &.{} },
788 .{ .name = "NonReadable", .value = 25, .parameters = &.{} },
789 .{ .name = "Uniform", .value = 26, .parameters = &.{} },
790 .{ .name = "UniformId", .value = 27, .parameters = &.{.id_scope} },
791 .{ .name = "SaturatedConversion", .value = 28, .parameters = &.{} },
792 .{ .name = "Stream", .value = 29, .parameters = &.{.literal_integer} },
793 .{ .name = "Location", .value = 30, .parameters = &.{.literal_integer} },
794 .{ .name = "Component", .value = 31, .parameters = &.{.literal_integer} },
795 .{ .name = "Index", .value = 32, .parameters = &.{.literal_integer} },
796 .{ .name = "Binding", .value = 33, .parameters = &.{.literal_integer} },
797 .{ .name = "DescriptorSet", .value = 34, .parameters = &.{.literal_integer} },
798 .{ .name = "Offset", .value = 35, .parameters = &.{.literal_integer} },
799 .{ .name = "XfbBuffer", .value = 36, .parameters = &.{.literal_integer} },
800 .{ .name = "XfbStride", .value = 37, .parameters = &.{.literal_integer} },
801 .{ .name = "FuncParamAttr", .value = 38, .parameters = &.{.function_parameter_attribute} },
802 .{ .name = "FPRoundingMode", .value = 39, .parameters = &.{.fp_rounding_mode} },
803 .{ .name = "FPFastMathMode", .value = 40, .parameters = &.{.fp_fast_math_mode} },
804 .{ .name = "LinkageAttributes", .value = 41, .parameters = &.{ .literal_string, .linkage_type } },
805 .{ .name = "NoContraction", .value = 42, .parameters = &.{} },
806 .{ .name = "InputAttachmentIndex", .value = 43, .parameters = &.{.literal_integer} },
807 .{ .name = "Alignment", .value = 44, .parameters = &.{.literal_integer} },
808 .{ .name = "MaxByteOffset", .value = 45, .parameters = &.{.literal_integer} },
809 .{ .name = "AlignmentId", .value = 46, .parameters = &.{.id_ref} },
810 .{ .name = "MaxByteOffsetId", .value = 47, .parameters = &.{.id_ref} },
811 .{ .name = "SaturatedToLargestFloat8NormalConversionEXT", .value = 4216, .parameters = &.{} },
812 .{ .name = "NoSignedWrap", .value = 4469, .parameters = &.{} },
813 .{ .name = "NoUnsignedWrap", .value = 4470, .parameters = &.{} },
814 .{ .name = "WeightTextureQCOM", .value = 4487, .parameters = &.{} },
815 .{ .name = "BlockMatchTextureQCOM", .value = 4488, .parameters = &.{} },
816 .{ .name = "BlockMatchSamplerQCOM", .value = 4499, .parameters = &.{} },
817 .{ .name = "ExplicitInterpAMD", .value = 4999, .parameters = &.{} },
818 .{ .name = "NodeSharesPayloadLimitsWithAMDX", .value = 5019, .parameters = &.{.id_ref} },
819 .{ .name = "NodeMaxPayloadsAMDX", .value = 5020, .parameters = &.{.id_ref} },
820 .{ .name = "TrackFinishWritingAMDX", .value = 5078, .parameters = &.{} },
821 .{ .name = "PayloadNodeNameAMDX", .value = 5091, .parameters = &.{.id_ref} },
822 .{ .name = "PayloadNodeBaseIndexAMDX", .value = 5098, .parameters = &.{.id_ref} },
823 .{ .name = "PayloadNodeSparseArrayAMDX", .value = 5099, .parameters = &.{} },
824 .{ .name = "PayloadNodeArraySizeAMDX", .value = 5100, .parameters = &.{.id_ref} },
825 .{ .name = "PayloadDispatchIndirectAMDX", .value = 5105, .parameters = &.{} },
826 .{ .name = "OverrideCoverageNV", .value = 5248, .parameters = &.{} },
827 .{ .name = "PassthroughNV", .value = 5250, .parameters = &.{} },
828 .{ .name = "ViewportRelativeNV", .value = 5252, .parameters = &.{} },
829 .{ .name = "SecondaryViewportRelativeNV", .value = 5256, .parameters = &.{.literal_integer} },
830 .{ .name = "PerPrimitiveEXT", .value = 5271, .parameters = &.{} },
831 .{ .name = "PerViewNV", .value = 5272, .parameters = &.{} },
832 .{ .name = "PerTaskNV", .value = 5273, .parameters = &.{} },
833 .{ .name = "PerVertexKHR", .value = 5285, .parameters = &.{} },
834 .{ .name = "NonUniform", .value = 5300, .parameters = &.{} },
835 .{ .name = "RestrictPointer", .value = 5355, .parameters = &.{} },
836 .{ .name = "AliasedPointer", .value = 5356, .parameters = &.{} },
837 .{ .name = "HitObjectShaderRecordBufferNV", .value = 5386, .parameters = &.{} },
838 .{ .name = "BindlessSamplerNV", .value = 5398, .parameters = &.{} },
839 .{ .name = "BindlessImageNV", .value = 5399, .parameters = &.{} },
840 .{ .name = "BoundSamplerNV", .value = 5400, .parameters = &.{} },
841 .{ .name = "BoundImageNV", .value = 5401, .parameters = &.{} },
842 .{ .name = "SIMTCallINTEL", .value = 5599, .parameters = &.{.literal_integer} },
843 .{ .name = "ReferencedIndirectlyINTEL", .value = 5602, .parameters = &.{} },
844 .{ .name = "ClobberINTEL", .value = 5607, .parameters = &.{.literal_string} },
845 .{ .name = "SideEffectsINTEL", .value = 5608, .parameters = &.{} },
846 .{ .name = "VectorComputeVariableINTEL", .value = 5624, .parameters = &.{} },
847 .{ .name = "FuncParamIOKindINTEL", .value = 5625, .parameters = &.{.literal_integer} },
848 .{ .name = "VectorComputeFunctionINTEL", .value = 5626, .parameters = &.{} },
849 .{ .name = "StackCallINTEL", .value = 5627, .parameters = &.{} },
850 .{ .name = "GlobalVariableOffsetINTEL", .value = 5628, .parameters = &.{.literal_integer} },
851 .{ .name = "CounterBuffer", .value = 5634, .parameters = &.{.id_ref} },
852 .{ .name = "UserSemantic", .value = 5635, .parameters = &.{.literal_string} },
853 .{ .name = "UserTypeGOOGLE", .value = 5636, .parameters = &.{.literal_string} },
854 .{ .name = "FunctionRoundingModeINTEL", .value = 5822, .parameters = &.{ .literal_integer, .fp_rounding_mode } },
855 .{ .name = "FunctionDenormModeINTEL", .value = 5823, .parameters = &.{ .literal_integer, .fp_denorm_mode } },
856 .{ .name = "RegisterINTEL", .value = 5825, .parameters = &.{} },
857 .{ .name = "MemoryINTEL", .value = 5826, .parameters = &.{.literal_string} },
858 .{ .name = "NumbanksINTEL", .value = 5827, .parameters = &.{.literal_integer} },
859 .{ .name = "BankwidthINTEL", .value = 5828, .parameters = &.{.literal_integer} },
860 .{ .name = "MaxPrivateCopiesINTEL", .value = 5829, .parameters = &.{.literal_integer} },
861 .{ .name = "SinglepumpINTEL", .value = 5830, .parameters = &.{} },
862 .{ .name = "DoublepumpINTEL", .value = 5831, .parameters = &.{} },
863 .{ .name = "MaxReplicatesINTEL", .value = 5832, .parameters = &.{.literal_integer} },
864 .{ .name = "SimpleDualPortINTEL", .value = 5833, .parameters = &.{} },
865 .{ .name = "MergeINTEL", .value = 5834, .parameters = &.{ .literal_string, .literal_string } },
866 .{ .name = "BankBitsINTEL", .value = 5835, .parameters = &.{.literal_integer} },
867 .{ .name = "ForcePow2DepthINTEL", .value = 5836, .parameters = &.{.literal_integer} },
868 .{ .name = "StridesizeINTEL", .value = 5883, .parameters = &.{.literal_integer} },
869 .{ .name = "WordsizeINTEL", .value = 5884, .parameters = &.{.literal_integer} },
870 .{ .name = "TrueDualPortINTEL", .value = 5885, .parameters = &.{} },
871 .{ .name = "BurstCoalesceINTEL", .value = 5899, .parameters = &.{} },
872 .{ .name = "CacheSizeINTEL", .value = 5900, .parameters = &.{.literal_integer} },
873 .{ .name = "DontStaticallyCoalesceINTEL", .value = 5901, .parameters = &.{} },
874 .{ .name = "PrefetchINTEL", .value = 5902, .parameters = &.{.literal_integer} },
875 .{ .name = "StallEnableINTEL", .value = 5905, .parameters = &.{} },
876 .{ .name = "FuseLoopsInFunctionINTEL", .value = 5907, .parameters = &.{} },
877 .{ .name = "MathOpDSPModeINTEL", .value = 5909, .parameters = &.{ .literal_integer, .literal_integer } },
878 .{ .name = "AliasScopeINTEL", .value = 5914, .parameters = &.{.id_ref} },
879 .{ .name = "NoAliasINTEL", .value = 5915, .parameters = &.{.id_ref} },
880 .{ .name = "InitiationIntervalINTEL", .value = 5917, .parameters = &.{.literal_integer} },
881 .{ .name = "MaxConcurrencyINTEL", .value = 5918, .parameters = &.{.literal_integer} },
882 .{ .name = "PipelineEnableINTEL", .value = 5919, .parameters = &.{.literal_integer} },
883 .{ .name = "BufferLocationINTEL", .value = 5921, .parameters = &.{.literal_integer} },
884 .{ .name = "IOPipeStorageINTEL", .value = 5944, .parameters = &.{.literal_integer} },
885 .{ .name = "FunctionFloatingPointModeINTEL", .value = 6080, .parameters = &.{ .literal_integer, .fp_operation_mode } },
886 .{ .name = "SingleElementVectorINTEL", .value = 6085, .parameters = &.{} },
887 .{ .name = "VectorComputeCallableFunctionINTEL", .value = 6087, .parameters = &.{} },
888 .{ .name = "MediaBlockIOINTEL", .value = 6140, .parameters = &.{} },
889 .{ .name = "StallFreeINTEL", .value = 6151, .parameters = &.{} },
890 .{ .name = "FPMaxErrorDecorationINTEL", .value = 6170, .parameters = &.{.literal_float} },
891 .{ .name = "LatencyControlLabelINTEL", .value = 6172, .parameters = &.{.literal_integer} },
892 .{ .name = "LatencyControlConstraintINTEL", .value = 6173, .parameters = &.{ .literal_integer, .literal_integer, .literal_integer } },
893 .{ .name = "ConduitKernelArgumentINTEL", .value = 6175, .parameters = &.{} },
894 .{ .name = "RegisterMapKernelArgumentINTEL", .value = 6176, .parameters = &.{} },
895 .{ .name = "MMHostInterfaceAddressWidthINTEL", .value = 6177, .parameters = &.{.literal_integer} },
896 .{ .name = "MMHostInterfaceDataWidthINTEL", .value = 6178, .parameters = &.{.literal_integer} },
897 .{ .name = "MMHostInterfaceLatencyINTEL", .value = 6179, .parameters = &.{.literal_integer} },
898 .{ .name = "MMHostInterfaceReadWriteModeINTEL", .value = 6180, .parameters = &.{.access_qualifier} },
899 .{ .name = "MMHostInterfaceMaxBurstINTEL", .value = 6181, .parameters = &.{.literal_integer} },
900 .{ .name = "MMHostInterfaceWaitRequestINTEL", .value = 6182, .parameters = &.{.literal_integer} },
901 .{ .name = "StableKernelArgumentINTEL", .value = 6183, .parameters = &.{} },
902 .{ .name = "HostAccessINTEL", .value = 6188, .parameters = &.{ .host_access_qualifier, .literal_string } },
903 .{ .name = "InitModeINTEL", .value = 6190, .parameters = &.{.initialization_mode_qualifier} },
904 .{ .name = "ImplementInRegisterMapINTEL", .value = 6191, .parameters = &.{.literal_integer} },
905 .{ .name = "CacheControlLoadINTEL", .value = 6442, .parameters = &.{ .literal_integer, .load_cache_control } },
906 .{ .name = "CacheControlStoreINTEL", .value = 6443, .parameters = &.{ .literal_integer, .store_cache_control } },
735 },907 },
736 .OverflowModes => &[_]Enumerant{908 .built_in => &.{
737 .{ .name = "WRAP", .value = 0, .parameters = &[_]OperandKind{} },909 .{ .name = "Position", .value = 0, .parameters = &.{} },
738 .{ .name = "SAT", .value = 1, .parameters = &[_]OperandKind{} },910 .{ .name = "PointSize", .value = 1, .parameters = &.{} },
739 .{ .name = "SAT_ZERO", .value = 2, .parameters = &[_]OperandKind{} },911 .{ .name = "ClipDistance", .value = 3, .parameters = &.{} },
740 .{ .name = "SAT_SYM", .value = 3, .parameters = &[_]OperandKind{} },912 .{ .name = "CullDistance", .value = 4, .parameters = &.{} },
913 .{ .name = "VertexId", .value = 5, .parameters = &.{} },
914 .{ .name = "InstanceId", .value = 6, .parameters = &.{} },
915 .{ .name = "PrimitiveId", .value = 7, .parameters = &.{} },
916 .{ .name = "InvocationId", .value = 8, .parameters = &.{} },
917 .{ .name = "Layer", .value = 9, .parameters = &.{} },
918 .{ .name = "ViewportIndex", .value = 10, .parameters = &.{} },
919 .{ .name = "TessLevelOuter", .value = 11, .parameters = &.{} },
920 .{ .name = "TessLevelInner", .value = 12, .parameters = &.{} },
921 .{ .name = "TessCoord", .value = 13, .parameters = &.{} },
922 .{ .name = "PatchVertices", .value = 14, .parameters = &.{} },
923 .{ .name = "FragCoord", .value = 15, .parameters = &.{} },
924 .{ .name = "PointCoord", .value = 16, .parameters = &.{} },
925 .{ .name = "FrontFacing", .value = 17, .parameters = &.{} },
926 .{ .name = "SampleId", .value = 18, .parameters = &.{} },
927 .{ .name = "SamplePosition", .value = 19, .parameters = &.{} },
928 .{ .name = "SampleMask", .value = 20, .parameters = &.{} },
929 .{ .name = "FragDepth", .value = 22, .parameters = &.{} },
930 .{ .name = "HelperInvocation", .value = 23, .parameters = &.{} },
931 .{ .name = "NumWorkgroups", .value = 24, .parameters = &.{} },
932 .{ .name = "WorkgroupSize", .value = 25, .parameters = &.{} },
933 .{ .name = "WorkgroupId", .value = 26, .parameters = &.{} },
934 .{ .name = "LocalInvocationId", .value = 27, .parameters = &.{} },
935 .{ .name = "GlobalInvocationId", .value = 28, .parameters = &.{} },
936 .{ .name = "LocalInvocationIndex", .value = 29, .parameters = &.{} },
937 .{ .name = "WorkDim", .value = 30, .parameters = &.{} },
938 .{ .name = "GlobalSize", .value = 31, .parameters = &.{} },
939 .{ .name = "EnqueuedWorkgroupSize", .value = 32, .parameters = &.{} },
940 .{ .name = "GlobalOffset", .value = 33, .parameters = &.{} },
941 .{ .name = "GlobalLinearId", .value = 34, .parameters = &.{} },
942 .{ .name = "SubgroupSize", .value = 36, .parameters = &.{} },
943 .{ .name = "SubgroupMaxSize", .value = 37, .parameters = &.{} },
944 .{ .name = "NumSubgroups", .value = 38, .parameters = &.{} },
945 .{ .name = "NumEnqueuedSubgroups", .value = 39, .parameters = &.{} },
946 .{ .name = "SubgroupId", .value = 40, .parameters = &.{} },
947 .{ .name = "SubgroupLocalInvocationId", .value = 41, .parameters = &.{} },
948 .{ .name = "VertexIndex", .value = 42, .parameters = &.{} },
949 .{ .name = "InstanceIndex", .value = 43, .parameters = &.{} },
950 .{ .name = "CoreIDARM", .value = 4160, .parameters = &.{} },
951 .{ .name = "CoreCountARM", .value = 4161, .parameters = &.{} },
952 .{ .name = "CoreMaxIDARM", .value = 4162, .parameters = &.{} },
953 .{ .name = "WarpIDARM", .value = 4163, .parameters = &.{} },
954 .{ .name = "WarpMaxIDARM", .value = 4164, .parameters = &.{} },
955 .{ .name = "SubgroupEqMask", .value = 4416, .parameters = &.{} },
956 .{ .name = "SubgroupGeMask", .value = 4417, .parameters = &.{} },
957 .{ .name = "SubgroupGtMask", .value = 4418, .parameters = &.{} },
958 .{ .name = "SubgroupLeMask", .value = 4419, .parameters = &.{} },
959 .{ .name = "SubgroupLtMask", .value = 4420, .parameters = &.{} },
960 .{ .name = "BaseVertex", .value = 4424, .parameters = &.{} },
961 .{ .name = "BaseInstance", .value = 4425, .parameters = &.{} },
962 .{ .name = "DrawIndex", .value = 4426, .parameters = &.{} },
963 .{ .name = "PrimitiveShadingRateKHR", .value = 4432, .parameters = &.{} },
964 .{ .name = "DeviceIndex", .value = 4438, .parameters = &.{} },
965 .{ .name = "ViewIndex", .value = 4440, .parameters = &.{} },
966 .{ .name = "ShadingRateKHR", .value = 4444, .parameters = &.{} },
967 .{ .name = "TileOffsetQCOM", .value = 4492, .parameters = &.{} },
968 .{ .name = "TileDimensionQCOM", .value = 4493, .parameters = &.{} },
969 .{ .name = "TileApronSizeQCOM", .value = 4494, .parameters = &.{} },
970 .{ .name = "BaryCoordNoPerspAMD", .value = 4992, .parameters = &.{} },
971 .{ .name = "BaryCoordNoPerspCentroidAMD", .value = 4993, .parameters = &.{} },
972 .{ .name = "BaryCoordNoPerspSampleAMD", .value = 4994, .parameters = &.{} },
973 .{ .name = "BaryCoordSmoothAMD", .value = 4995, .parameters = &.{} },
974 .{ .name = "BaryCoordSmoothCentroidAMD", .value = 4996, .parameters = &.{} },
975 .{ .name = "BaryCoordSmoothSampleAMD", .value = 4997, .parameters = &.{} },
976 .{ .name = "BaryCoordPullModelAMD", .value = 4998, .parameters = &.{} },
977 .{ .name = "FragStencilRefEXT", .value = 5014, .parameters = &.{} },
978 .{ .name = "RemainingRecursionLevelsAMDX", .value = 5021, .parameters = &.{} },
979 .{ .name = "ShaderIndexAMDX", .value = 5073, .parameters = &.{} },
980 .{ .name = "ViewportMaskNV", .value = 5253, .parameters = &.{} },
981 .{ .name = "SecondaryPositionNV", .value = 5257, .parameters = &.{} },
982 .{ .name = "SecondaryViewportMaskNV", .value = 5258, .parameters = &.{} },
983 .{ .name = "PositionPerViewNV", .value = 5261, .parameters = &.{} },
984 .{ .name = "ViewportMaskPerViewNV", .value = 5262, .parameters = &.{} },
985 .{ .name = "FullyCoveredEXT", .value = 5264, .parameters = &.{} },
986 .{ .name = "TaskCountNV", .value = 5274, .parameters = &.{} },
987 .{ .name = "PrimitiveCountNV", .value = 5275, .parameters = &.{} },
988 .{ .name = "PrimitiveIndicesNV", .value = 5276, .parameters = &.{} },
989 .{ .name = "ClipDistancePerViewNV", .value = 5277, .parameters = &.{} },
990 .{ .name = "CullDistancePerViewNV", .value = 5278, .parameters = &.{} },
991 .{ .name = "LayerPerViewNV", .value = 5279, .parameters = &.{} },
992 .{ .name = "MeshViewCountNV", .value = 5280, .parameters = &.{} },
993 .{ .name = "MeshViewIndicesNV", .value = 5281, .parameters = &.{} },
994 .{ .name = "BaryCoordKHR", .value = 5286, .parameters = &.{} },
995 .{ .name = "BaryCoordNoPerspKHR", .value = 5287, .parameters = &.{} },
996 .{ .name = "FragSizeEXT", .value = 5292, .parameters = &.{} },
997 .{ .name = "FragInvocationCountEXT", .value = 5293, .parameters = &.{} },
998 .{ .name = "PrimitivePointIndicesEXT", .value = 5294, .parameters = &.{} },
999 .{ .name = "PrimitiveLineIndicesEXT", .value = 5295, .parameters = &.{} },
1000 .{ .name = "PrimitiveTriangleIndicesEXT", .value = 5296, .parameters = &.{} },
1001 .{ .name = "CullPrimitiveEXT", .value = 5299, .parameters = &.{} },
1002 .{ .name = "LaunchIdKHR", .value = 5319, .parameters = &.{} },
1003 .{ .name = "LaunchSizeKHR", .value = 5320, .parameters = &.{} },
1004 .{ .name = "WorldRayOriginKHR", .value = 5321, .parameters = &.{} },
1005 .{ .name = "WorldRayDirectionKHR", .value = 5322, .parameters = &.{} },
1006 .{ .name = "ObjectRayOriginKHR", .value = 5323, .parameters = &.{} },
1007 .{ .name = "ObjectRayDirectionKHR", .value = 5324, .parameters = &.{} },
1008 .{ .name = "RayTminKHR", .value = 5325, .parameters = &.{} },
1009 .{ .name = "RayTmaxKHR", .value = 5326, .parameters = &.{} },
1010 .{ .name = "InstanceCustomIndexKHR", .value = 5327, .parameters = &.{} },
1011 .{ .name = "ObjectToWorldKHR", .value = 5330, .parameters = &.{} },
1012 .{ .name = "WorldToObjectKHR", .value = 5331, .parameters = &.{} },
1013 .{ .name = "HitTNV", .value = 5332, .parameters = &.{} },
1014 .{ .name = "HitKindKHR", .value = 5333, .parameters = &.{} },
1015 .{ .name = "CurrentRayTimeNV", .value = 5334, .parameters = &.{} },
1016 .{ .name = "HitTriangleVertexPositionsKHR", .value = 5335, .parameters = &.{} },
1017 .{ .name = "HitMicroTriangleVertexPositionsNV", .value = 5337, .parameters = &.{} },
1018 .{ .name = "HitMicroTriangleVertexBarycentricsNV", .value = 5344, .parameters = &.{} },
1019 .{ .name = "IncomingRayFlagsKHR", .value = 5351, .parameters = &.{} },
1020 .{ .name = "RayGeometryIndexKHR", .value = 5352, .parameters = &.{} },
1021 .{ .name = "HitIsSphereNV", .value = 5359, .parameters = &.{} },
1022 .{ .name = "HitIsLSSNV", .value = 5360, .parameters = &.{} },
1023 .{ .name = "HitSpherePositionNV", .value = 5361, .parameters = &.{} },
1024 .{ .name = "WarpsPerSMNV", .value = 5374, .parameters = &.{} },
1025 .{ .name = "SMCountNV", .value = 5375, .parameters = &.{} },
1026 .{ .name = "WarpIDNV", .value = 5376, .parameters = &.{} },
1027 .{ .name = "SMIDNV", .value = 5377, .parameters = &.{} },
1028 .{ .name = "HitLSSPositionsNV", .value = 5396, .parameters = &.{} },
1029 .{ .name = "HitKindFrontFacingMicroTriangleNV", .value = 5405, .parameters = &.{} },
1030 .{ .name = "HitKindBackFacingMicroTriangleNV", .value = 5406, .parameters = &.{} },
1031 .{ .name = "HitSphereRadiusNV", .value = 5420, .parameters = &.{} },
1032 .{ .name = "HitLSSRadiiNV", .value = 5421, .parameters = &.{} },
1033 .{ .name = "ClusterIDNV", .value = 5436, .parameters = &.{} },
1034 .{ .name = "CullMaskKHR", .value = 6021, .parameters = &.{} },
741 },1035 },
742 .LinkageType => &[_]Enumerant{1036 .scope => &.{
743 .{ .name = "Export", .value = 0, .parameters = &[_]OperandKind{} },1037 .{ .name = "CrossDevice", .value = 0, .parameters = &.{} },
744 .{ .name = "Import", .value = 1, .parameters = &[_]OperandKind{} },1038 .{ .name = "Device", .value = 1, .parameters = &.{} },
745 .{ .name = "LinkOnceODR", .value = 2, .parameters = &[_]OperandKind{} },1039 .{ .name = "Workgroup", .value = 2, .parameters = &.{} },
1040 .{ .name = "Subgroup", .value = 3, .parameters = &.{} },
1041 .{ .name = "Invocation", .value = 4, .parameters = &.{} },
1042 .{ .name = "QueueFamily", .value = 5, .parameters = &.{} },
1043 .{ .name = "ShaderCallKHR", .value = 6, .parameters = &.{} },
746 },1044 },
747 .AccessQualifier => &[_]Enumerant{1045 .group_operation => &.{
748 .{ .name = "ReadOnly", .value = 0, .parameters = &[_]OperandKind{} },1046 .{ .name = "Reduce", .value = 0, .parameters = &.{} },
749 .{ .name = "WriteOnly", .value = 1, .parameters = &[_]OperandKind{} },1047 .{ .name = "InclusiveScan", .value = 1, .parameters = &.{} },
750 .{ .name = "ReadWrite", .value = 2, .parameters = &[_]OperandKind{} },1048 .{ .name = "ExclusiveScan", .value = 2, .parameters = &.{} },
1049 .{ .name = "ClusteredReduce", .value = 3, .parameters = &.{} },
1050 .{ .name = "PartitionedReduceNV", .value = 6, .parameters = &.{} },
1051 .{ .name = "PartitionedInclusiveScanNV", .value = 7, .parameters = &.{} },
1052 .{ .name = "PartitionedExclusiveScanNV", .value = 8, .parameters = &.{} },
751 },1053 },
752 .HostAccessQualifier => &[_]Enumerant{1054 .kernel_enqueue_flags => &.{
753 .{ .name = "NoneINTEL", .value = 0, .parameters = &[_]OperandKind{} },1055 .{ .name = "NoWait", .value = 0, .parameters = &.{} },
754 .{ .name = "ReadINTEL", .value = 1, .parameters = &[_]OperandKind{} },1056 .{ .name = "WaitKernel", .value = 1, .parameters = &.{} },
755 .{ .name = "WriteINTEL", .value = 2, .parameters = &[_]OperandKind{} },1057 .{ .name = "WaitWorkGroup", .value = 2, .parameters = &.{} },
756 .{ .name = "ReadWriteINTEL", .value = 3, .parameters = &[_]OperandKind{} },
757 },1058 },
758 .FunctionParameterAttribute => &[_]Enumerant{1059 .capability => &.{
759 .{ .name = "Zext", .value = 0, .parameters = &[_]OperandKind{} },1060 .{ .name = "Matrix", .value = 0, .parameters = &.{} },
760 .{ .name = "Sext", .value = 1, .parameters = &[_]OperandKind{} },1061 .{ .name = "Shader", .value = 1, .parameters = &.{} },
761 .{ .name = "ByVal", .value = 2, .parameters = &[_]OperandKind{} },1062 .{ .name = "Geometry", .value = 2, .parameters = &.{} },
762 .{ .name = "Sret", .value = 3, .parameters = &[_]OperandKind{} },1063 .{ .name = "Tessellation", .value = 3, .parameters = &.{} },
763 .{ .name = "NoAlias", .value = 4, .parameters = &[_]OperandKind{} },1064 .{ .name = "Addresses", .value = 4, .parameters = &.{} },
764 .{ .name = "NoCapture", .value = 5, .parameters = &[_]OperandKind{} },1065 .{ .name = "Linkage", .value = 5, .parameters = &.{} },
765 .{ .name = "NoWrite", .value = 6, .parameters = &[_]OperandKind{} },1066 .{ .name = "Kernel", .value = 6, .parameters = &.{} },
766 .{ .name = "NoReadWrite", .value = 7, .parameters = &[_]OperandKind{} },1067 .{ .name = "Vector16", .value = 7, .parameters = &.{} },
767 .{ .name = "RuntimeAlignedINTEL", .value = 5940, .parameters = &[_]OperandKind{} },1068 .{ .name = "Float16Buffer", .value = 8, .parameters = &.{} },
1069 .{ .name = "Float16", .value = 9, .parameters = &.{} },
1070 .{ .name = "Float64", .value = 10, .parameters = &.{} },
1071 .{ .name = "Int64", .value = 11, .parameters = &.{} },
1072 .{ .name = "Int64Atomics", .value = 12, .parameters = &.{} },
1073 .{ .name = "ImageBasic", .value = 13, .parameters = &.{} },
1074 .{ .name = "ImageReadWrite", .value = 14, .parameters = &.{} },
1075 .{ .name = "ImageMipmap", .value = 15, .parameters = &.{} },
1076 .{ .name = "Pipes", .value = 17, .parameters = &.{} },
1077 .{ .name = "Groups", .value = 18, .parameters = &.{} },
1078 .{ .name = "DeviceEnqueue", .value = 19, .parameters = &.{} },
1079 .{ .name = "LiteralSampler", .value = 20, .parameters = &.{} },
1080 .{ .name = "AtomicStorage", .value = 21, .parameters = &.{} },
1081 .{ .name = "Int16", .value = 22, .parameters = &.{} },
1082 .{ .name = "TessellationPointSize", .value = 23, .parameters = &.{} },
1083 .{ .name = "GeometryPointSize", .value = 24, .parameters = &.{} },
1084 .{ .name = "ImageGatherExtended", .value = 25, .parameters = &.{} },
1085 .{ .name = "StorageImageMultisample", .value = 27, .parameters = &.{} },
1086 .{ .name = "UniformBufferArrayDynamicIndexing", .value = 28, .parameters = &.{} },
1087 .{ .name = "SampledImageArrayDynamicIndexing", .value = 29, .parameters = &.{} },
1088 .{ .name = "StorageBufferArrayDynamicIndexing", .value = 30, .parameters = &.{} },
1089 .{ .name = "StorageImageArrayDynamicIndexing", .value = 31, .parameters = &.{} },
1090 .{ .name = "ClipDistance", .value = 32, .parameters = &.{} },
1091 .{ .name = "CullDistance", .value = 33, .parameters = &.{} },
1092 .{ .name = "ImageCubeArray", .value = 34, .parameters = &.{} },
1093 .{ .name = "SampleRateShading", .value = 35, .parameters = &.{} },
1094 .{ .name = "ImageRect", .value = 36, .parameters = &.{} },
1095 .{ .name = "SampledRect", .value = 37, .parameters = &.{} },
1096 .{ .name = "GenericPointer", .value = 38, .parameters = &.{} },
1097 .{ .name = "Int8", .value = 39, .parameters = &.{} },
1098 .{ .name = "InputAttachment", .value = 40, .parameters = &.{} },
1099 .{ .name = "SparseResidency", .value = 41, .parameters = &.{} },
1100 .{ .name = "MinLod", .value = 42, .parameters = &.{} },
1101 .{ .name = "Sampled1D", .value = 43, .parameters = &.{} },
1102 .{ .name = "Image1D", .value = 44, .parameters = &.{} },
1103 .{ .name = "SampledCubeArray", .value = 45, .parameters = &.{} },
1104 .{ .name = "SampledBuffer", .value = 46, .parameters = &.{} },
1105 .{ .name = "ImageBuffer", .value = 47, .parameters = &.{} },
1106 .{ .name = "ImageMSArray", .value = 48, .parameters = &.{} },
1107 .{ .name = "StorageImageExtendedFormats", .value = 49, .parameters = &.{} },
1108 .{ .name = "ImageQuery", .value = 50, .parameters = &.{} },
1109 .{ .name = "DerivativeControl", .value = 51, .parameters = &.{} },
1110 .{ .name = "InterpolationFunction", .value = 52, .parameters = &.{} },
1111 .{ .name = "TransformFeedback", .value = 53, .parameters = &.{} },
1112 .{ .name = "GeometryStreams", .value = 54, .parameters = &.{} },
1113 .{ .name = "StorageImageReadWithoutFormat", .value = 55, .parameters = &.{} },
1114 .{ .name = "StorageImageWriteWithoutFormat", .value = 56, .parameters = &.{} },
1115 .{ .name = "MultiViewport", .value = 57, .parameters = &.{} },
1116 .{ .name = "SubgroupDispatch", .value = 58, .parameters = &.{} },
1117 .{ .name = "NamedBarrier", .value = 59, .parameters = &.{} },
1118 .{ .name = "PipeStorage", .value = 60, .parameters = &.{} },
1119 .{ .name = "GroupNonUniform", .value = 61, .parameters = &.{} },
1120 .{ .name = "GroupNonUniformVote", .value = 62, .parameters = &.{} },
1121 .{ .name = "GroupNonUniformArithmetic", .value = 63, .parameters = &.{} },
1122 .{ .name = "GroupNonUniformBallot", .value = 64, .parameters = &.{} },
1123 .{ .name = "GroupNonUniformShuffle", .value = 65, .parameters = &.{} },
1124 .{ .name = "GroupNonUniformShuffleRelative", .value = 66, .parameters = &.{} },
1125 .{ .name = "GroupNonUniformClustered", .value = 67, .parameters = &.{} },
1126 .{ .name = "GroupNonUniformQuad", .value = 68, .parameters = &.{} },
1127 .{ .name = "ShaderLayer", .value = 69, .parameters = &.{} },
1128 .{ .name = "ShaderViewportIndex", .value = 70, .parameters = &.{} },
1129 .{ .name = "UniformDecoration", .value = 71, .parameters = &.{} },
1130 .{ .name = "CoreBuiltinsARM", .value = 4165, .parameters = &.{} },
1131 .{ .name = "TileImageColorReadAccessEXT", .value = 4166, .parameters = &.{} },
1132 .{ .name = "TileImageDepthReadAccessEXT", .value = 4167, .parameters = &.{} },
1133 .{ .name = "TileImageStencilReadAccessEXT", .value = 4168, .parameters = &.{} },
1134 .{ .name = "TensorsARM", .value = 4174, .parameters = &.{} },
1135 .{ .name = "StorageTensorArrayDynamicIndexingARM", .value = 4175, .parameters = &.{} },
1136 .{ .name = "StorageTensorArrayNonUniformIndexingARM", .value = 4176, .parameters = &.{} },
1137 .{ .name = "GraphARM", .value = 4191, .parameters = &.{} },
1138 .{ .name = "CooperativeMatrixLayoutsARM", .value = 4201, .parameters = &.{} },
1139 .{ .name = "Float8EXT", .value = 4212, .parameters = &.{} },
1140 .{ .name = "Float8CooperativeMatrixEXT", .value = 4213, .parameters = &.{} },
1141 .{ .name = "FragmentShadingRateKHR", .value = 4422, .parameters = &.{} },
1142 .{ .name = "SubgroupBallotKHR", .value = 4423, .parameters = &.{} },
1143 .{ .name = "DrawParameters", .value = 4427, .parameters = &.{} },
1144 .{ .name = "WorkgroupMemoryExplicitLayoutKHR", .value = 4428, .parameters = &.{} },
1145 .{ .name = "WorkgroupMemoryExplicitLayout8BitAccessKHR", .value = 4429, .parameters = &.{} },
1146 .{ .name = "WorkgroupMemoryExplicitLayout16BitAccessKHR", .value = 4430, .parameters = &.{} },
1147 .{ .name = "SubgroupVoteKHR", .value = 4431, .parameters = &.{} },
1148 .{ .name = "StorageBuffer16BitAccess", .value = 4433, .parameters = &.{} },
1149 .{ .name = "UniformAndStorageBuffer16BitAccess", .value = 4434, .parameters = &.{} },
1150 .{ .name = "StoragePushConstant16", .value = 4435, .parameters = &.{} },
1151 .{ .name = "StorageInputOutput16", .value = 4436, .parameters = &.{} },
1152 .{ .name = "DeviceGroup", .value = 4437, .parameters = &.{} },
1153 .{ .name = "MultiView", .value = 4439, .parameters = &.{} },
1154 .{ .name = "VariablePointersStorageBuffer", .value = 4441, .parameters = &.{} },
1155 .{ .name = "VariablePointers", .value = 4442, .parameters = &.{} },
1156 .{ .name = "AtomicStorageOps", .value = 4445, .parameters = &.{} },
1157 .{ .name = "SampleMaskPostDepthCoverage", .value = 4447, .parameters = &.{} },
1158 .{ .name = "StorageBuffer8BitAccess", .value = 4448, .parameters = &.{} },
1159 .{ .name = "UniformAndStorageBuffer8BitAccess", .value = 4449, .parameters = &.{} },
1160 .{ .name = "StoragePushConstant8", .value = 4450, .parameters = &.{} },
1161 .{ .name = "DenormPreserve", .value = 4464, .parameters = &.{} },
1162 .{ .name = "DenormFlushToZero", .value = 4465, .parameters = &.{} },
1163 .{ .name = "SignedZeroInfNanPreserve", .value = 4466, .parameters = &.{} },
1164 .{ .name = "RoundingModeRTE", .value = 4467, .parameters = &.{} },
1165 .{ .name = "RoundingModeRTZ", .value = 4468, .parameters = &.{} },
1166 .{ .name = "RayQueryProvisionalKHR", .value = 4471, .parameters = &.{} },
1167 .{ .name = "RayQueryKHR", .value = 4472, .parameters = &.{} },
1168 .{ .name = "UntypedPointersKHR", .value = 4473, .parameters = &.{} },
1169 .{ .name = "RayTraversalPrimitiveCullingKHR", .value = 4478, .parameters = &.{} },
1170 .{ .name = "RayTracingKHR", .value = 4479, .parameters = &.{} },
1171 .{ .name = "TextureSampleWeightedQCOM", .value = 4484, .parameters = &.{} },
1172 .{ .name = "TextureBoxFilterQCOM", .value = 4485, .parameters = &.{} },
1173 .{ .name = "TextureBlockMatchQCOM", .value = 4486, .parameters = &.{} },
1174 .{ .name = "TileShadingQCOM", .value = 4495, .parameters = &.{} },
1175 .{ .name = "TextureBlockMatch2QCOM", .value = 4498, .parameters = &.{} },
1176 .{ .name = "Float16ImageAMD", .value = 5008, .parameters = &.{} },
1177 .{ .name = "ImageGatherBiasLodAMD", .value = 5009, .parameters = &.{} },
1178 .{ .name = "FragmentMaskAMD", .value = 5010, .parameters = &.{} },
1179 .{ .name = "StencilExportEXT", .value = 5013, .parameters = &.{} },
1180 .{ .name = "ImageReadWriteLodAMD", .value = 5015, .parameters = &.{} },
1181 .{ .name = "Int64ImageEXT", .value = 5016, .parameters = &.{} },
1182 .{ .name = "ShaderClockKHR", .value = 5055, .parameters = &.{} },
1183 .{ .name = "ShaderEnqueueAMDX", .value = 5067, .parameters = &.{} },
1184 .{ .name = "QuadControlKHR", .value = 5087, .parameters = &.{} },
1185 .{ .name = "Int4TypeINTEL", .value = 5112, .parameters = &.{} },
1186 .{ .name = "Int4CooperativeMatrixINTEL", .value = 5114, .parameters = &.{} },
1187 .{ .name = "BFloat16TypeKHR", .value = 5116, .parameters = &.{} },
1188 .{ .name = "BFloat16DotProductKHR", .value = 5117, .parameters = &.{} },
1189 .{ .name = "BFloat16CooperativeMatrixKHR", .value = 5118, .parameters = &.{} },
1190 .{ .name = "SampleMaskOverrideCoverageNV", .value = 5249, .parameters = &.{} },
1191 .{ .name = "GeometryShaderPassthroughNV", .value = 5251, .parameters = &.{} },
1192 .{ .name = "ShaderViewportIndexLayerEXT", .value = 5254, .parameters = &.{} },
1193 .{ .name = "ShaderViewportMaskNV", .value = 5255, .parameters = &.{} },
1194 .{ .name = "ShaderStereoViewNV", .value = 5259, .parameters = &.{} },
1195 .{ .name = "PerViewAttributesNV", .value = 5260, .parameters = &.{} },
1196 .{ .name = "FragmentFullyCoveredEXT", .value = 5265, .parameters = &.{} },
1197 .{ .name = "MeshShadingNV", .value = 5266, .parameters = &.{} },
1198 .{ .name = "ImageFootprintNV", .value = 5282, .parameters = &.{} },
1199 .{ .name = "MeshShadingEXT", .value = 5283, .parameters = &.{} },
1200 .{ .name = "FragmentBarycentricKHR", .value = 5284, .parameters = &.{} },
1201 .{ .name = "ComputeDerivativeGroupQuadsKHR", .value = 5288, .parameters = &.{} },
1202 .{ .name = "FragmentDensityEXT", .value = 5291, .parameters = &.{} },
1203 .{ .name = "GroupNonUniformPartitionedNV", .value = 5297, .parameters = &.{} },
1204 .{ .name = "ShaderNonUniform", .value = 5301, .parameters = &.{} },
1205 .{ .name = "RuntimeDescriptorArray", .value = 5302, .parameters = &.{} },
1206 .{ .name = "InputAttachmentArrayDynamicIndexing", .value = 5303, .parameters = &.{} },
1207 .{ .name = "UniformTexelBufferArrayDynamicIndexing", .value = 5304, .parameters = &.{} },
1208 .{ .name = "StorageTexelBufferArrayDynamicIndexing", .value = 5305, .parameters = &.{} },
1209 .{ .name = "UniformBufferArrayNonUniformIndexing", .value = 5306, .parameters = &.{} },
1210 .{ .name = "SampledImageArrayNonUniformIndexing", .value = 5307, .parameters = &.{} },
1211 .{ .name = "StorageBufferArrayNonUniformIndexing", .value = 5308, .parameters = &.{} },
1212 .{ .name = "StorageImageArrayNonUniformIndexing", .value = 5309, .parameters = &.{} },
1213 .{ .name = "InputAttachmentArrayNonUniformIndexing", .value = 5310, .parameters = &.{} },
1214 .{ .name = "UniformTexelBufferArrayNonUniformIndexing", .value = 5311, .parameters = &.{} },
1215 .{ .name = "StorageTexelBufferArrayNonUniformIndexing", .value = 5312, .parameters = &.{} },
1216 .{ .name = "RayTracingPositionFetchKHR", .value = 5336, .parameters = &.{} },
1217 .{ .name = "RayTracingNV", .value = 5340, .parameters = &.{} },
1218 .{ .name = "RayTracingMotionBlurNV", .value = 5341, .parameters = &.{} },
1219 .{ .name = "VulkanMemoryModel", .value = 5345, .parameters = &.{} },
1220 .{ .name = "VulkanMemoryModelDeviceScope", .value = 5346, .parameters = &.{} },
1221 .{ .name = "PhysicalStorageBufferAddresses", .value = 5347, .parameters = &.{} },
1222 .{ .name = "ComputeDerivativeGroupLinearKHR", .value = 5350, .parameters = &.{} },
1223 .{ .name = "RayTracingProvisionalKHR", .value = 5353, .parameters = &.{} },
1224 .{ .name = "CooperativeMatrixNV", .value = 5357, .parameters = &.{} },
1225 .{ .name = "FragmentShaderSampleInterlockEXT", .value = 5363, .parameters = &.{} },
1226 .{ .name = "FragmentShaderShadingRateInterlockEXT", .value = 5372, .parameters = &.{} },
1227 .{ .name = "ShaderSMBuiltinsNV", .value = 5373, .parameters = &.{} },
1228 .{ .name = "FragmentShaderPixelInterlockEXT", .value = 5378, .parameters = &.{} },
1229 .{ .name = "DemoteToHelperInvocation", .value = 5379, .parameters = &.{} },
1230 .{ .name = "DisplacementMicromapNV", .value = 5380, .parameters = &.{} },
1231 .{ .name = "RayTracingOpacityMicromapEXT", .value = 5381, .parameters = &.{} },
1232 .{ .name = "ShaderInvocationReorderNV", .value = 5383, .parameters = &.{} },
1233 .{ .name = "BindlessTextureNV", .value = 5390, .parameters = &.{} },
1234 .{ .name = "RayQueryPositionFetchKHR", .value = 5391, .parameters = &.{} },
1235 .{ .name = "CooperativeVectorNV", .value = 5394, .parameters = &.{} },
1236 .{ .name = "AtomicFloat16VectorNV", .value = 5404, .parameters = &.{} },
1237 .{ .name = "RayTracingDisplacementMicromapNV", .value = 5409, .parameters = &.{} },
1238 .{ .name = "RawAccessChainsNV", .value = 5414, .parameters = &.{} },
1239 .{ .name = "RayTracingSpheresGeometryNV", .value = 5418, .parameters = &.{} },
1240 .{ .name = "RayTracingLinearSweptSpheresGeometryNV", .value = 5419, .parameters = &.{} },
1241 .{ .name = "CooperativeMatrixReductionsNV", .value = 5430, .parameters = &.{} },
1242 .{ .name = "CooperativeMatrixConversionsNV", .value = 5431, .parameters = &.{} },
1243 .{ .name = "CooperativeMatrixPerElementOperationsNV", .value = 5432, .parameters = &.{} },
1244 .{ .name = "CooperativeMatrixTensorAddressingNV", .value = 5433, .parameters = &.{} },
1245 .{ .name = "CooperativeMatrixBlockLoadsNV", .value = 5434, .parameters = &.{} },
1246 .{ .name = "CooperativeVectorTrainingNV", .value = 5435, .parameters = &.{} },
1247 .{ .name = "RayTracingClusterAccelerationStructureNV", .value = 5437, .parameters = &.{} },
1248 .{ .name = "TensorAddressingNV", .value = 5439, .parameters = &.{} },
1249 .{ .name = "SubgroupShuffleINTEL", .value = 5568, .parameters = &.{} },
1250 .{ .name = "SubgroupBufferBlockIOINTEL", .value = 5569, .parameters = &.{} },
1251 .{ .name = "SubgroupImageBlockIOINTEL", .value = 5570, .parameters = &.{} },
1252 .{ .name = "SubgroupImageMediaBlockIOINTEL", .value = 5579, .parameters = &.{} },
1253 .{ .name = "RoundToInfinityINTEL", .value = 5582, .parameters = &.{} },
1254 .{ .name = "FloatingPointModeINTEL", .value = 5583, .parameters = &.{} },
1255 .{ .name = "IntegerFunctions2INTEL", .value = 5584, .parameters = &.{} },
1256 .{ .name = "FunctionPointersINTEL", .value = 5603, .parameters = &.{} },
1257 .{ .name = "IndirectReferencesINTEL", .value = 5604, .parameters = &.{} },
1258 .{ .name = "AsmINTEL", .value = 5606, .parameters = &.{} },
1259 .{ .name = "AtomicFloat32MinMaxEXT", .value = 5612, .parameters = &.{} },
1260 .{ .name = "AtomicFloat64MinMaxEXT", .value = 5613, .parameters = &.{} },
1261 .{ .name = "AtomicFloat16MinMaxEXT", .value = 5616, .parameters = &.{} },
1262 .{ .name = "VectorComputeINTEL", .value = 5617, .parameters = &.{} },
1263 .{ .name = "VectorAnyINTEL", .value = 5619, .parameters = &.{} },
1264 .{ .name = "ExpectAssumeKHR", .value = 5629, .parameters = &.{} },
1265 .{ .name = "SubgroupAvcMotionEstimationINTEL", .value = 5696, .parameters = &.{} },
1266 .{ .name = "SubgroupAvcMotionEstimationIntraINTEL", .value = 5697, .parameters = &.{} },
1267 .{ .name = "SubgroupAvcMotionEstimationChromaINTEL", .value = 5698, .parameters = &.{} },
1268 .{ .name = "VariableLengthArrayINTEL", .value = 5817, .parameters = &.{} },
1269 .{ .name = "FunctionFloatControlINTEL", .value = 5821, .parameters = &.{} },
1270 .{ .name = "FPGAMemoryAttributesINTEL", .value = 5824, .parameters = &.{} },
1271 .{ .name = "FPFastMathModeINTEL", .value = 5837, .parameters = &.{} },
1272 .{ .name = "ArbitraryPrecisionIntegersINTEL", .value = 5844, .parameters = &.{} },
1273 .{ .name = "ArbitraryPrecisionFloatingPointINTEL", .value = 5845, .parameters = &.{} },
1274 .{ .name = "UnstructuredLoopControlsINTEL", .value = 5886, .parameters = &.{} },
1275 .{ .name = "FPGALoopControlsINTEL", .value = 5888, .parameters = &.{} },
1276 .{ .name = "KernelAttributesINTEL", .value = 5892, .parameters = &.{} },
1277 .{ .name = "FPGAKernelAttributesINTEL", .value = 5897, .parameters = &.{} },
1278 .{ .name = "FPGAMemoryAccessesINTEL", .value = 5898, .parameters = &.{} },
1279 .{ .name = "FPGAClusterAttributesINTEL", .value = 5904, .parameters = &.{} },
1280 .{ .name = "LoopFuseINTEL", .value = 5906, .parameters = &.{} },
1281 .{ .name = "FPGADSPControlINTEL", .value = 5908, .parameters = &.{} },
1282 .{ .name = "MemoryAccessAliasingINTEL", .value = 5910, .parameters = &.{} },
1283 .{ .name = "FPGAInvocationPipeliningAttributesINTEL", .value = 5916, .parameters = &.{} },
1284 .{ .name = "FPGABufferLocationINTEL", .value = 5920, .parameters = &.{} },
1285 .{ .name = "ArbitraryPrecisionFixedPointINTEL", .value = 5922, .parameters = &.{} },
1286 .{ .name = "USMStorageClassesINTEL", .value = 5935, .parameters = &.{} },
1287 .{ .name = "RuntimeAlignedAttributeINTEL", .value = 5939, .parameters = &.{} },
1288 .{ .name = "IOPipesINTEL", .value = 5943, .parameters = &.{} },
1289 .{ .name = "BlockingPipesINTEL", .value = 5945, .parameters = &.{} },
1290 .{ .name = "FPGARegINTEL", .value = 5948, .parameters = &.{} },
1291 .{ .name = "DotProductInputAll", .value = 6016, .parameters = &.{} },
1292 .{ .name = "DotProductInput4x8Bit", .value = 6017, .parameters = &.{} },
1293 .{ .name = "DotProductInput4x8BitPacked", .value = 6018, .parameters = &.{} },
1294 .{ .name = "DotProduct", .value = 6019, .parameters = &.{} },
1295 .{ .name = "RayCullMaskKHR", .value = 6020, .parameters = &.{} },
1296 .{ .name = "CooperativeMatrixKHR", .value = 6022, .parameters = &.{} },
1297 .{ .name = "ReplicatedCompositesEXT", .value = 6024, .parameters = &.{} },
1298 .{ .name = "BitInstructions", .value = 6025, .parameters = &.{} },
1299 .{ .name = "GroupNonUniformRotateKHR", .value = 6026, .parameters = &.{} },
1300 .{ .name = "FloatControls2", .value = 6029, .parameters = &.{} },
1301 .{ .name = "AtomicFloat32AddEXT", .value = 6033, .parameters = &.{} },
1302 .{ .name = "AtomicFloat64AddEXT", .value = 6034, .parameters = &.{} },
1303 .{ .name = "LongCompositesINTEL", .value = 6089, .parameters = &.{} },
1304 .{ .name = "OptNoneEXT", .value = 6094, .parameters = &.{} },
1305 .{ .name = "AtomicFloat16AddEXT", .value = 6095, .parameters = &.{} },
1306 .{ .name = "DebugInfoModuleINTEL", .value = 6114, .parameters = &.{} },
1307 .{ .name = "BFloat16ConversionINTEL", .value = 6115, .parameters = &.{} },
1308 .{ .name = "SplitBarrierINTEL", .value = 6141, .parameters = &.{} },
1309 .{ .name = "ArithmeticFenceEXT", .value = 6144, .parameters = &.{} },
1310 .{ .name = "FPGAClusterAttributesV2INTEL", .value = 6150, .parameters = &.{} },
1311 .{ .name = "FPGAKernelAttributesv2INTEL", .value = 6161, .parameters = &.{} },
1312 .{ .name = "TaskSequenceINTEL", .value = 6162, .parameters = &.{} },
1313 .{ .name = "FPMaxErrorINTEL", .value = 6169, .parameters = &.{} },
1314 .{ .name = "FPGALatencyControlINTEL", .value = 6171, .parameters = &.{} },
1315 .{ .name = "FPGAArgumentInterfacesINTEL", .value = 6174, .parameters = &.{} },
1316 .{ .name = "GlobalVariableHostAccessINTEL", .value = 6187, .parameters = &.{} },
1317 .{ .name = "GlobalVariableFPGADecorationsINTEL", .value = 6189, .parameters = &.{} },
1318 .{ .name = "SubgroupBufferPrefetchINTEL", .value = 6220, .parameters = &.{} },
1319 .{ .name = "Subgroup2DBlockIOINTEL", .value = 6228, .parameters = &.{} },
1320 .{ .name = "Subgroup2DBlockTransformINTEL", .value = 6229, .parameters = &.{} },
1321 .{ .name = "Subgroup2DBlockTransposeINTEL", .value = 6230, .parameters = &.{} },
1322 .{ .name = "SubgroupMatrixMultiplyAccumulateINTEL", .value = 6236, .parameters = &.{} },
1323 .{ .name = "TernaryBitwiseFunctionINTEL", .value = 6241, .parameters = &.{} },
1324 .{ .name = "GroupUniformArithmeticKHR", .value = 6400, .parameters = &.{} },
1325 .{ .name = "TensorFloat32RoundingINTEL", .value = 6425, .parameters = &.{} },
1326 .{ .name = "MaskedGatherScatterINTEL", .value = 6427, .parameters = &.{} },
1327 .{ .name = "CacheControlsINTEL", .value = 6441, .parameters = &.{} },
1328 .{ .name = "RegisterLimitsINTEL", .value = 6460, .parameters = &.{} },
1329 .{ .name = "BindlessImagesINTEL", .value = 6528, .parameters = &.{} },
768 },1330 },
769 .Decoration => &[_]Enumerant{1331 .ray_query_intersection => &.{
770 .{ .name = "RelaxedPrecision", .value = 0, .parameters = &[_]OperandKind{} },1332 .{ .name = "RayQueryCandidateIntersectionKHR", .value = 0, .parameters = &.{} },
771 .{ .name = "SpecId", .value = 1, .parameters = &[_]OperandKind{.LiteralInteger} },1333 .{ .name = "RayQueryCommittedIntersectionKHR", .value = 1, .parameters = &.{} },
772 .{ .name = "Block", .value = 2, .parameters = &[_]OperandKind{} },
773 .{ .name = "BufferBlock", .value = 3, .parameters = &[_]OperandKind{} },
774 .{ .name = "RowMajor", .value = 4, .parameters = &[_]OperandKind{} },
775 .{ .name = "ColMajor", .value = 5, .parameters = &[_]OperandKind{} },
776 .{ .name = "ArrayStride", .value = 6, .parameters = &[_]OperandKind{.LiteralInteger} },
777 .{ .name = "MatrixStride", .value = 7, .parameters = &[_]OperandKind{.LiteralInteger} },
778 .{ .name = "GLSLShared", .value = 8, .parameters = &[_]OperandKind{} },
779 .{ .name = "GLSLPacked", .value = 9, .parameters = &[_]OperandKind{} },
780 .{ .name = "CPacked", .value = 10, .parameters = &[_]OperandKind{} },
781 .{ .name = "BuiltIn", .value = 11, .parameters = &[_]OperandKind{.BuiltIn} },
782 .{ .name = "NoPerspective", .value = 13, .parameters = &[_]OperandKind{} },
783 .{ .name = "Flat", .value = 14, .parameters = &[_]OperandKind{} },
784 .{ .name = "Patch", .value = 15, .parameters = &[_]OperandKind{} },
785 .{ .name = "Centroid", .value = 16, .parameters = &[_]OperandKind{} },
786 .{ .name = "Sample", .value = 17, .parameters = &[_]OperandKind{} },
787 .{ .name = "Invariant", .value = 18, .parameters = &[_]OperandKind{} },
788 .{ .name = "Restrict", .value = 19, .parameters = &[_]OperandKind{} },
789 .{ .name = "Aliased", .value = 20, .parameters = &[_]OperandKind{} },
790 .{ .name = "Volatile", .value = 21, .parameters = &[_]OperandKind{} },
791 .{ .name = "Constant", .value = 22, .parameters = &[_]OperandKind{} },
792 .{ .name = "Coherent", .value = 23, .parameters = &[_]OperandKind{} },
793 .{ .name = "NonWritable", .value = 24, .parameters = &[_]OperandKind{} },
794 .{ .name = "NonReadable", .value = 25, .parameters = &[_]OperandKind{} },
795 .{ .name = "Uniform", .value = 26, .parameters = &[_]OperandKind{} },
796 .{ .name = "UniformId", .value = 27, .parameters = &[_]OperandKind{.IdScope} },
797 .{ .name = "SaturatedConversion", .value = 28, .parameters = &[_]OperandKind{} },
798 .{ .name = "Stream", .value = 29, .parameters = &[_]OperandKind{.LiteralInteger} },
799 .{ .name = "Location", .value = 30, .parameters = &[_]OperandKind{.LiteralInteger} },
800 .{ .name = "Component", .value = 31, .parameters = &[_]OperandKind{.LiteralInteger} },
801 .{ .name = "Index", .value = 32, .parameters = &[_]OperandKind{.LiteralInteger} },
802 .{ .name = "Binding", .value = 33, .parameters = &[_]OperandKind{.LiteralInteger} },
803 .{ .name = "DescriptorSet", .value = 34, .parameters = &[_]OperandKind{.LiteralInteger} },
804 .{ .name = "Offset", .value = 35, .parameters = &[_]OperandKind{.LiteralInteger} },
805 .{ .name = "XfbBuffer", .value = 36, .parameters = &[_]OperandKind{.LiteralInteger} },
806 .{ .name = "XfbStride", .value = 37, .parameters = &[_]OperandKind{.LiteralInteger} },
807 .{ .name = "FuncParamAttr", .value = 38, .parameters = &[_]OperandKind{.FunctionParameterAttribute} },
808 .{ .name = "FPRoundingMode", .value = 39, .parameters = &[_]OperandKind{.FPRoundingMode} },
809 .{ .name = "FPFastMathMode", .value = 40, .parameters = &[_]OperandKind{.FPFastMathMode} },
810 .{ .name = "LinkageAttributes", .value = 41, .parameters = &[_]OperandKind{ .LiteralString, .LinkageType } },
811 .{ .name = "NoContraction", .value = 42, .parameters = &[_]OperandKind{} },
812 .{ .name = "InputAttachmentIndex", .value = 43, .parameters = &[_]OperandKind{.LiteralInteger} },
813 .{ .name = "Alignment", .value = 44, .parameters = &[_]OperandKind{.LiteralInteger} },
814 .{ .name = "MaxByteOffset", .value = 45, .parameters = &[_]OperandKind{.LiteralInteger} },
815 .{ .name = "AlignmentId", .value = 46, .parameters = &[_]OperandKind{.IdRef} },
816 .{ .name = "MaxByteOffsetId", .value = 47, .parameters = &[_]OperandKind{.IdRef} },
817 .{ .name = "NoSignedWrap", .value = 4469, .parameters = &[_]OperandKind{} },
818 .{ .name = "NoUnsignedWrap", .value = 4470, .parameters = &[_]OperandKind{} },
819 .{ .name = "WeightTextureQCOM", .value = 4487, .parameters = &[_]OperandKind{} },
820 .{ .name = "BlockMatchTextureQCOM", .value = 4488, .parameters = &[_]OperandKind{} },
821 .{ .name = "BlockMatchSamplerQCOM", .value = 4499, .parameters = &[_]OperandKind{} },
822 .{ .name = "ExplicitInterpAMD", .value = 4999, .parameters = &[_]OperandKind{} },
823 .{ .name = "NodeSharesPayloadLimitsWithAMDX", .value = 5019, .parameters = &[_]OperandKind{.IdRef} },
824 .{ .name = "NodeMaxPayloadsAMDX", .value = 5020, .parameters = &[_]OperandKind{.IdRef} },
825 .{ .name = "TrackFinishWritingAMDX", .value = 5078, .parameters = &[_]OperandKind{} },
826 .{ .name = "PayloadNodeNameAMDX", .value = 5091, .parameters = &[_]OperandKind{.LiteralString} },
827 .{ .name = "OverrideCoverageNV", .value = 5248, .parameters = &[_]OperandKind{} },
828 .{ .name = "PassthroughNV", .value = 5250, .parameters = &[_]OperandKind{} },
829 .{ .name = "ViewportRelativeNV", .value = 5252, .parameters = &[_]OperandKind{} },
830 .{ .name = "SecondaryViewportRelativeNV", .value = 5256, .parameters = &[_]OperandKind{.LiteralInteger} },
831 .{ .name = "PerPrimitiveNV", .value = 5271, .parameters = &[_]OperandKind{} },
832 .{ .name = "PerPrimitiveEXT", .value = 5271, .parameters = &[_]OperandKind{} },
833 .{ .name = "PerViewNV", .value = 5272, .parameters = &[_]OperandKind{} },
834 .{ .name = "PerTaskNV", .value = 5273, .parameters = &[_]OperandKind{} },
835 .{ .name = "PerVertexKHR", .value = 5285, .parameters = &[_]OperandKind{} },
836 .{ .name = "PerVertexNV", .value = 5285, .parameters = &[_]OperandKind{} },
837 .{ .name = "NonUniform", .value = 5300, .parameters = &[_]OperandKind{} },
838 .{ .name = "NonUniformEXT", .value = 5300, .parameters = &[_]OperandKind{} },
839 .{ .name = "RestrictPointer", .value = 5355, .parameters = &[_]OperandKind{} },
840 .{ .name = "RestrictPointerEXT", .value = 5355, .parameters = &[_]OperandKind{} },
841 .{ .name = "AliasedPointer", .value = 5356, .parameters = &[_]OperandKind{} },
842 .{ .name = "AliasedPointerEXT", .value = 5356, .parameters = &[_]OperandKind{} },
843 .{ .name = "HitObjectShaderRecordBufferNV", .value = 5386, .parameters = &[_]OperandKind{} },
844 .{ .name = "BindlessSamplerNV", .value = 5398, .parameters = &[_]OperandKind{} },
845 .{ .name = "BindlessImageNV", .value = 5399, .parameters = &[_]OperandKind{} },
846 .{ .name = "BoundSamplerNV", .value = 5400, .parameters = &[_]OperandKind{} },
847 .{ .name = "BoundImageNV", .value = 5401, .parameters = &[_]OperandKind{} },
848 .{ .name = "SIMTCallINTEL", .value = 5599, .parameters = &[_]OperandKind{.LiteralInteger} },
849 .{ .name = "ReferencedIndirectlyINTEL", .value = 5602, .parameters = &[_]OperandKind{} },
850 .{ .name = "ClobberINTEL", .value = 5607, .parameters = &[_]OperandKind{.LiteralString} },
851 .{ .name = "SideEffectsINTEL", .value = 5608, .parameters = &[_]OperandKind{} },
852 .{ .name = "VectorComputeVariableINTEL", .value = 5624, .parameters = &[_]OperandKind{} },
853 .{ .name = "FuncParamIOKindINTEL", .value = 5625, .parameters = &[_]OperandKind{.LiteralInteger} },
854 .{ .name = "VectorComputeFunctionINTEL", .value = 5626, .parameters = &[_]OperandKind{} },
855 .{ .name = "StackCallINTEL", .value = 5627, .parameters = &[_]OperandKind{} },
856 .{ .name = "GlobalVariableOffsetINTEL", .value = 5628, .parameters = &[_]OperandKind{.LiteralInteger} },
857 .{ .name = "CounterBuffer", .value = 5634, .parameters = &[_]OperandKind{.IdRef} },
858 .{ .name = "HlslCounterBufferGOOGLE", .value = 5634, .parameters = &[_]OperandKind{.IdRef} },
859 .{ .name = "UserSemantic", .value = 5635, .parameters = &[_]OperandKind{.LiteralString} },
860 .{ .name = "HlslSemanticGOOGLE", .value = 5635, .parameters = &[_]OperandKind{.LiteralString} },
861 .{ .name = "UserTypeGOOGLE", .value = 5636, .parameters = &[_]OperandKind{.LiteralString} },
862 .{ .name = "FunctionRoundingModeINTEL", .value = 5822, .parameters = &[_]OperandKind{ .LiteralInteger, .FPRoundingMode } },
863 .{ .name = "FunctionDenormModeINTEL", .value = 5823, .parameters = &[_]OperandKind{ .LiteralInteger, .FPDenormMode } },
864 .{ .name = "RegisterINTEL", .value = 5825, .parameters = &[_]OperandKind{} },
865 .{ .name = "MemoryINTEL", .value = 5826, .parameters = &[_]OperandKind{.LiteralString} },
866 .{ .name = "NumbanksINTEL", .value = 5827, .parameters = &[_]OperandKind{.LiteralInteger} },
867 .{ .name = "BankwidthINTEL", .value = 5828, .parameters = &[_]OperandKind{.LiteralInteger} },
868 .{ .name = "MaxPrivateCopiesINTEL", .value = 5829, .parameters = &[_]OperandKind{.LiteralInteger} },
869 .{ .name = "SinglepumpINTEL", .value = 5830, .parameters = &[_]OperandKind{} },
870 .{ .name = "DoublepumpINTEL", .value = 5831, .parameters = &[_]OperandKind{} },
871 .{ .name = "MaxReplicatesINTEL", .value = 5832, .parameters = &[_]OperandKind{.LiteralInteger} },
872 .{ .name = "SimpleDualPortINTEL", .value = 5833, .parameters = &[_]OperandKind{} },
873 .{ .name = "MergeINTEL", .value = 5834, .parameters = &[_]OperandKind{ .LiteralString, .LiteralString } },
874 .{ .name = "BankBitsINTEL", .value = 5835, .parameters = &[_]OperandKind{.LiteralInteger} },
875 .{ .name = "ForcePow2DepthINTEL", .value = 5836, .parameters = &[_]OperandKind{.LiteralInteger} },
876 .{ .name = "StridesizeINTEL", .value = 5883, .parameters = &[_]OperandKind{.LiteralInteger} },
877 .{ .name = "WordsizeINTEL", .value = 5884, .parameters = &[_]OperandKind{.LiteralInteger} },
878 .{ .name = "TrueDualPortINTEL", .value = 5885, .parameters = &[_]OperandKind{} },
879 .{ .name = "BurstCoalesceINTEL", .value = 5899, .parameters = &[_]OperandKind{} },
880 .{ .name = "CacheSizeINTEL", .value = 5900, .parameters = &[_]OperandKind{.LiteralInteger} },
881 .{ .name = "DontStaticallyCoalesceINTEL", .value = 5901, .parameters = &[_]OperandKind{} },
882 .{ .name = "PrefetchINTEL", .value = 5902, .parameters = &[_]OperandKind{.LiteralInteger} },
883 .{ .name = "StallEnableINTEL", .value = 5905, .parameters = &[_]OperandKind{} },
884 .{ .name = "FuseLoopsInFunctionINTEL", .value = 5907, .parameters = &[_]OperandKind{} },
885 .{ .name = "MathOpDSPModeINTEL", .value = 5909, .parameters = &[_]OperandKind{ .LiteralInteger, .LiteralInteger } },
886 .{ .name = "AliasScopeINTEL", .value = 5914, .parameters = &[_]OperandKind{.IdRef} },
887 .{ .name = "NoAliasINTEL", .value = 5915, .parameters = &[_]OperandKind{.IdRef} },
888 .{ .name = "InitiationIntervalINTEL", .value = 5917, .parameters = &[_]OperandKind{.LiteralInteger} },
889 .{ .name = "MaxConcurrencyINTEL", .value = 5918, .parameters = &[_]OperandKind{.LiteralInteger} },
890 .{ .name = "PipelineEnableINTEL", .value = 5919, .parameters = &[_]OperandKind{.LiteralInteger} },
891 .{ .name = "BufferLocationINTEL", .value = 5921, .parameters = &[_]OperandKind{.LiteralInteger} },
892 .{ .name = "IOPipeStorageINTEL", .value = 5944, .parameters = &[_]OperandKind{.LiteralInteger} },
893 .{ .name = "FunctionFloatingPointModeINTEL", .value = 6080, .parameters = &[_]OperandKind{ .LiteralInteger, .FPOperationMode } },
894 .{ .name = "SingleElementVectorINTEL", .value = 6085, .parameters = &[_]OperandKind{} },
895 .{ .name = "VectorComputeCallableFunctionINTEL", .value = 6087, .parameters = &[_]OperandKind{} },
896 .{ .name = "MediaBlockIOINTEL", .value = 6140, .parameters = &[_]OperandKind{} },
897 .{ .name = "StallFreeINTEL", .value = 6151, .parameters = &[_]OperandKind{} },
898 .{ .name = "FPMaxErrorDecorationINTEL", .value = 6170, .parameters = &[_]OperandKind{.LiteralFloat} },
899 .{ .name = "LatencyControlLabelINTEL", .value = 6172, .parameters = &[_]OperandKind{.LiteralInteger} },
900 .{ .name = "LatencyControlConstraintINTEL", .value = 6173, .parameters = &[_]OperandKind{ .LiteralInteger, .LiteralInteger, .LiteralInteger } },
901 .{ .name = "ConduitKernelArgumentINTEL", .value = 6175, .parameters = &[_]OperandKind{} },
902 .{ .name = "RegisterMapKernelArgumentINTEL", .value = 6176, .parameters = &[_]OperandKind{} },
903 .{ .name = "MMHostInterfaceAddressWidthINTEL", .value = 6177, .parameters = &[_]OperandKind{.LiteralInteger} },
904 .{ .name = "MMHostInterfaceDataWidthINTEL", .value = 6178, .parameters = &[_]OperandKind{.LiteralInteger} },
905 .{ .name = "MMHostInterfaceLatencyINTEL", .value = 6179, .parameters = &[_]OperandKind{.LiteralInteger} },
906 .{ .name = "MMHostInterfaceReadWriteModeINTEL", .value = 6180, .parameters = &[_]OperandKind{.AccessQualifier} },
907 .{ .name = "MMHostInterfaceMaxBurstINTEL", .value = 6181, .parameters = &[_]OperandKind{.LiteralInteger} },
908 .{ .name = "MMHostInterfaceWaitRequestINTEL", .value = 6182, .parameters = &[_]OperandKind{.LiteralInteger} },
909 .{ .name = "StableKernelArgumentINTEL", .value = 6183, .parameters = &[_]OperandKind{} },
910 .{ .name = "HostAccessINTEL", .value = 6188, .parameters = &[_]OperandKind{ .HostAccessQualifier, .LiteralString } },
911 .{ .name = "InitModeINTEL", .value = 6190, .parameters = &[_]OperandKind{.InitializationModeQualifier} },
912 .{ .name = "ImplementInRegisterMapINTEL", .value = 6191, .parameters = &[_]OperandKind{.LiteralInteger} },
913 .{ .name = "CacheControlLoadINTEL", .value = 6442, .parameters = &[_]OperandKind{ .LiteralInteger, .LoadCacheControl } },
914 .{ .name = "CacheControlStoreINTEL", .value = 6443, .parameters = &[_]OperandKind{ .LiteralInteger, .StoreCacheControl } },
915 },1334 },
916 .BuiltIn => &[_]Enumerant{1335 .ray_query_committed_intersection_type => &.{
917 .{ .name = "Position", .value = 0, .parameters = &[_]OperandKind{} },1336 .{ .name = "RayQueryCommittedIntersectionNoneKHR", .value = 0, .parameters = &.{} },
918 .{ .name = "PointSize", .value = 1, .parameters = &[_]OperandKind{} },1337 .{ .name = "RayQueryCommittedIntersectionTriangleKHR", .value = 1, .parameters = &.{} },
919 .{ .name = "ClipDistance", .value = 3, .parameters = &[_]OperandKind{} },1338 .{ .name = "RayQueryCommittedIntersectionGeneratedKHR", .value = 2, .parameters = &.{} },
920 .{ .name = "CullDistance", .value = 4, .parameters = &[_]OperandKind{} },
921 .{ .name = "VertexId", .value = 5, .parameters = &[_]OperandKind{} },
922 .{ .name = "InstanceId", .value = 6, .parameters = &[_]OperandKind{} },
923 .{ .name = "PrimitiveId", .value = 7, .parameters = &[_]OperandKind{} },
924 .{ .name = "InvocationId", .value = 8, .parameters = &[_]OperandKind{} },
925 .{ .name = "Layer", .value = 9, .parameters = &[_]OperandKind{} },
926 .{ .name = "ViewportIndex", .value = 10, .parameters = &[_]OperandKind{} },
927 .{ .name = "TessLevelOuter", .value = 11, .parameters = &[_]OperandKind{} },
928 .{ .name = "TessLevelInner", .value = 12, .parameters = &[_]OperandKind{} },
929 .{ .name = "TessCoord", .value = 13, .parameters = &[_]OperandKind{} },
930 .{ .name = "PatchVertices", .value = 14, .parameters = &[_]OperandKind{} },
931 .{ .name = "FragCoord", .value = 15, .parameters = &[_]OperandKind{} },
932 .{ .name = "PointCoord", .value = 16, .parameters = &[_]OperandKind{} },
933 .{ .name = "FrontFacing", .value = 17, .parameters = &[_]OperandKind{} },
934 .{ .name = "SampleId", .value = 18, .parameters = &[_]OperandKind{} },
935 .{ .name = "SamplePosition", .value = 19, .parameters = &[_]OperandKind{} },
936 .{ .name = "SampleMask", .value = 20, .parameters = &[_]OperandKind{} },
937 .{ .name = "FragDepth", .value = 22, .parameters = &[_]OperandKind{} },
938 .{ .name = "HelperInvocation", .value = 23, .parameters = &[_]OperandKind{} },
939 .{ .name = "NumWorkgroups", .value = 24, .parameters = &[_]OperandKind{} },
940 .{ .name = "WorkgroupSize", .value = 25, .parameters = &[_]OperandKind{} },
941 .{ .name = "WorkgroupId", .value = 26, .parameters = &[_]OperandKind{} },
942 .{ .name = "LocalInvocationId", .value = 27, .parameters = &[_]OperandKind{} },
943 .{ .name = "GlobalInvocationId", .value = 28, .parameters = &[_]OperandKind{} },
944 .{ .name = "LocalInvocationIndex", .value = 29, .parameters = &[_]OperandKind{} },
945 .{ .name = "WorkDim", .value = 30, .parameters = &[_]OperandKind{} },
946 .{ .name = "GlobalSize", .value = 31, .parameters = &[_]OperandKind{} },
947 .{ .name = "EnqueuedWorkgroupSize", .value = 32, .parameters = &[_]OperandKind{} },
948 .{ .name = "GlobalOffset", .value = 33, .parameters = &[_]OperandKind{} },
949 .{ .name = "GlobalLinearId", .value = 34, .parameters = &[_]OperandKind{} },
950 .{ .name = "SubgroupSize", .value = 36, .parameters = &[_]OperandKind{} },
951 .{ .name = "SubgroupMaxSize", .value = 37, .parameters = &[_]OperandKind{} },
952 .{ .name = "NumSubgroups", .value = 38, .parameters = &[_]OperandKind{} },
953 .{ .name = "NumEnqueuedSubgroups", .value = 39, .parameters = &[_]OperandKind{} },
954 .{ .name = "SubgroupId", .value = 40, .parameters = &[_]OperandKind{} },
955 .{ .name = "SubgroupLocalInvocationId", .value = 41, .parameters = &[_]OperandKind{} },
956 .{ .name = "VertexIndex", .value = 42, .parameters = &[_]OperandKind{} },
957 .{ .name = "InstanceIndex", .value = 43, .parameters = &[_]OperandKind{} },
958 .{ .name = "CoreIDARM", .value = 4160, .parameters = &[_]OperandKind{} },
959 .{ .name = "CoreCountARM", .value = 4161, .parameters = &[_]OperandKind{} },
960 .{ .name = "CoreMaxIDARM", .value = 4162, .parameters = &[_]OperandKind{} },
961 .{ .name = "WarpIDARM", .value = 4163, .parameters = &[_]OperandKind{} },
962 .{ .name = "WarpMaxIDARM", .value = 4164, .parameters = &[_]OperandKind{} },
963 .{ .name = "SubgroupEqMask", .value = 4416, .parameters = &[_]OperandKind{} },
964 .{ .name = "SubgroupEqMaskKHR", .value = 4416, .parameters = &[_]OperandKind{} },
965 .{ .name = "SubgroupGeMask", .value = 4417, .parameters = &[_]OperandKind{} },
966 .{ .name = "SubgroupGeMaskKHR", .value = 4417, .parameters = &[_]OperandKind{} },
967 .{ .name = "SubgroupGtMask", .value = 4418, .parameters = &[_]OperandKind{} },
968 .{ .name = "SubgroupGtMaskKHR", .value = 4418, .parameters = &[_]OperandKind{} },
969 .{ .name = "SubgroupLeMask", .value = 4419, .parameters = &[_]OperandKind{} },
970 .{ .name = "SubgroupLeMaskKHR", .value = 4419, .parameters = &[_]OperandKind{} },
971 .{ .name = "SubgroupLtMask", .value = 4420, .parameters = &[_]OperandKind{} },
972 .{ .name = "SubgroupLtMaskKHR", .value = 4420, .parameters = &[_]OperandKind{} },
973 .{ .name = "BaseVertex", .value = 4424, .parameters = &[_]OperandKind{} },
974 .{ .name = "BaseInstance", .value = 4425, .parameters = &[_]OperandKind{} },
975 .{ .name = "DrawIndex", .value = 4426, .parameters = &[_]OperandKind{} },
976 .{ .name = "PrimitiveShadingRateKHR", .value = 4432, .parameters = &[_]OperandKind{} },
977 .{ .name = "DeviceIndex", .value = 4438, .parameters = &[_]OperandKind{} },
978 .{ .name = "ViewIndex", .value = 4440, .parameters = &[_]OperandKind{} },
979 .{ .name = "ShadingRateKHR", .value = 4444, .parameters = &[_]OperandKind{} },
980 .{ .name = "BaryCoordNoPerspAMD", .value = 4992, .parameters = &[_]OperandKind{} },
981 .{ .name = "BaryCoordNoPerspCentroidAMD", .value = 4993, .parameters = &[_]OperandKind{} },
982 .{ .name = "BaryCoordNoPerspSampleAMD", .value = 4994, .parameters = &[_]OperandKind{} },
983 .{ .name = "BaryCoordSmoothAMD", .value = 4995, .parameters = &[_]OperandKind{} },
984 .{ .name = "BaryCoordSmoothCentroidAMD", .value = 4996, .parameters = &[_]OperandKind{} },
985 .{ .name = "BaryCoordSmoothSampleAMD", .value = 4997, .parameters = &[_]OperandKind{} },
986 .{ .name = "BaryCoordPullModelAMD", .value = 4998, .parameters = &[_]OperandKind{} },
987 .{ .name = "FragStencilRefEXT", .value = 5014, .parameters = &[_]OperandKind{} },
988 .{ .name = "CoalescedInputCountAMDX", .value = 5021, .parameters = &[_]OperandKind{} },
989 .{ .name = "ShaderIndexAMDX", .value = 5073, .parameters = &[_]OperandKind{} },
990 .{ .name = "ViewportMaskNV", .value = 5253, .parameters = &[_]OperandKind{} },
991 .{ .name = "SecondaryPositionNV", .value = 5257, .parameters = &[_]OperandKind{} },
992 .{ .name = "SecondaryViewportMaskNV", .value = 5258, .parameters = &[_]OperandKind{} },
993 .{ .name = "PositionPerViewNV", .value = 5261, .parameters = &[_]OperandKind{} },
994 .{ .name = "ViewportMaskPerViewNV", .value = 5262, .parameters = &[_]OperandKind{} },
995 .{ .name = "FullyCoveredEXT", .value = 5264, .parameters = &[_]OperandKind{} },
996 .{ .name = "TaskCountNV", .value = 5274, .parameters = &[_]OperandKind{} },
997 .{ .name = "PrimitiveCountNV", .value = 5275, .parameters = &[_]OperandKind{} },
998 .{ .name = "PrimitiveIndicesNV", .value = 5276, .parameters = &[_]OperandKind{} },
999 .{ .name = "ClipDistancePerViewNV", .value = 5277, .parameters = &[_]OperandKind{} },
1000 .{ .name = "CullDistancePerViewNV", .value = 5278, .parameters = &[_]OperandKind{} },
1001 .{ .name = "LayerPerViewNV", .value = 5279, .parameters = &[_]OperandKind{} },
1002 .{ .name = "MeshViewCountNV", .value = 5280, .parameters = &[_]OperandKind{} },
1003 .{ .name = "MeshViewIndicesNV", .value = 5281, .parameters = &[_]OperandKind{} },
1004 .{ .name = "BaryCoordKHR", .value = 5286, .parameters = &[_]OperandKind{} },
1005 .{ .name = "BaryCoordNV", .value = 5286, .parameters = &[_]OperandKind{} },
1006 .{ .name = "BaryCoordNoPerspKHR", .value = 5287, .parameters = &[_]OperandKind{} },
1007 .{ .name = "BaryCoordNoPerspNV", .value = 5287, .parameters = &[_]OperandKind{} },
1008 .{ .name = "FragSizeEXT", .value = 5292, .parameters = &[_]OperandKind{} },
1009 .{ .name = "FragmentSizeNV", .value = 5292, .parameters = &[_]OperandKind{} },
1010 .{ .name = "FragInvocationCountEXT", .value = 5293, .parameters = &[_]OperandKind{} },
1011 .{ .name = "InvocationsPerPixelNV", .value = 5293, .parameters = &[_]OperandKind{} },
1012 .{ .name = "PrimitivePointIndicesEXT", .value = 5294, .parameters = &[_]OperandKind{} },
1013 .{ .name = "PrimitiveLineIndicesEXT", .value = 5295, .parameters = &[_]OperandKind{} },
1014 .{ .name = "PrimitiveTriangleIndicesEXT", .value = 5296, .parameters = &[_]OperandKind{} },
1015 .{ .name = "CullPrimitiveEXT", .value = 5299, .parameters = &[_]OperandKind{} },
1016 .{ .name = "LaunchIdNV", .value = 5319, .parameters = &[_]OperandKind{} },
1017 .{ .name = "LaunchIdKHR", .value = 5319, .parameters = &[_]OperandKind{} },
1018 .{ .name = "LaunchSizeNV", .value = 5320, .parameters = &[_]OperandKind{} },
1019 .{ .name = "LaunchSizeKHR", .value = 5320, .parameters = &[_]OperandKind{} },
1020 .{ .name = "WorldRayOriginNV", .value = 5321, .parameters = &[_]OperandKind{} },
1021 .{ .name = "WorldRayOriginKHR", .value = 5321, .parameters = &[_]OperandKind{} },
1022 .{ .name = "WorldRayDirectionNV", .value = 5322, .parameters = &[_]OperandKind{} },
1023 .{ .name = "WorldRayDirectionKHR", .value = 5322, .parameters = &[_]OperandKind{} },
1024 .{ .name = "ObjectRayOriginNV", .value = 5323, .parameters = &[_]OperandKind{} },
1025 .{ .name = "ObjectRayOriginKHR", .value = 5323, .parameters = &[_]OperandKind{} },
1026 .{ .name = "ObjectRayDirectionNV", .value = 5324, .parameters = &[_]OperandKind{} },
1027 .{ .name = "ObjectRayDirectionKHR", .value = 5324, .parameters = &[_]OperandKind{} },
1028 .{ .name = "RayTminNV", .value = 5325, .parameters = &[_]OperandKind{} },
1029 .{ .name = "RayTminKHR", .value = 5325, .parameters = &[_]OperandKind{} },
1030 .{ .name = "RayTmaxNV", .value = 5326, .parameters = &[_]OperandKind{} },
1031 .{ .name = "RayTmaxKHR", .value = 5326, .parameters = &[_]OperandKind{} },
1032 .{ .name = "InstanceCustomIndexNV", .value = 5327, .parameters = &[_]OperandKind{} },
1033 .{ .name = "InstanceCustomIndexKHR", .value = 5327, .parameters = &[_]OperandKind{} },
1034 .{ .name = "ObjectToWorldNV", .value = 5330, .parameters = &[_]OperandKind{} },
1035 .{ .name = "ObjectToWorldKHR", .value = 5330, .parameters = &[_]OperandKind{} },
1036 .{ .name = "WorldToObjectNV", .value = 5331, .parameters = &[_]OperandKind{} },
1037 .{ .name = "WorldToObjectKHR", .value = 5331, .parameters = &[_]OperandKind{} },
1038 .{ .name = "HitTNV", .value = 5332, .parameters = &[_]OperandKind{} },
1039 .{ .name = "HitKindNV", .value = 5333, .parameters = &[_]OperandKind{} },
1040 .{ .name = "HitKindKHR", .value = 5333, .parameters = &[_]OperandKind{} },
1041 .{ .name = "CurrentRayTimeNV", .value = 5334, .parameters = &[_]OperandKind{} },
1042 .{ .name = "HitTriangleVertexPositionsKHR", .value = 5335, .parameters = &[_]OperandKind{} },
1043 .{ .name = "HitMicroTriangleVertexPositionsNV", .value = 5337, .parameters = &[_]OperandKind{} },
1044 .{ .name = "HitMicroTriangleVertexBarycentricsNV", .value = 5344, .parameters = &[_]OperandKind{} },
1045 .{ .name = "IncomingRayFlagsNV", .value = 5351, .parameters = &[_]OperandKind{} },
1046 .{ .name = "IncomingRayFlagsKHR", .value = 5351, .parameters = &[_]OperandKind{} },
1047 .{ .name = "RayGeometryIndexKHR", .value = 5352, .parameters = &[_]OperandKind{} },
1048 .{ .name = "WarpsPerSMNV", .value = 5374, .parameters = &[_]OperandKind{} },
1049 .{ .name = "SMCountNV", .value = 5375, .parameters = &[_]OperandKind{} },
1050 .{ .name = "WarpIDNV", .value = 5376, .parameters = &[_]OperandKind{} },
1051 .{ .name = "SMIDNV", .value = 5377, .parameters = &[_]OperandKind{} },
1052 .{ .name = "HitKindFrontFacingMicroTriangleNV", .value = 5405, .parameters = &[_]OperandKind{} },
1053 .{ .name = "HitKindBackFacingMicroTriangleNV", .value = 5406, .parameters = &[_]OperandKind{} },
1054 .{ .name = "CullMaskKHR", .value = 6021, .parameters = &[_]OperandKind{} },
1055 },1339 },
1056 .Scope => &[_]Enumerant{1340 .ray_query_candidate_intersection_type => &.{
1057 .{ .name = "CrossDevice", .value = 0, .parameters = &[_]OperandKind{} },1341 .{ .name = "RayQueryCandidateIntersectionTriangleKHR", .value = 0, .parameters = &.{} },
1058 .{ .name = "Device", .value = 1, .parameters = &[_]OperandKind{} },1342 .{ .name = "RayQueryCandidateIntersectionAABBKHR", .value = 1, .parameters = &.{} },
1059 .{ .name = "Workgroup", .value = 2, .parameters = &[_]OperandKind{} },
1060 .{ .name = "Subgroup", .value = 3, .parameters = &[_]OperandKind{} },
1061 .{ .name = "Invocation", .value = 4, .parameters = &[_]OperandKind{} },
1062 .{ .name = "QueueFamily", .value = 5, .parameters = &[_]OperandKind{} },
1063 .{ .name = "QueueFamilyKHR", .value = 5, .parameters = &[_]OperandKind{} },
1064 .{ .name = "ShaderCallKHR", .value = 6, .parameters = &[_]OperandKind{} },
1065 },1343 },
1066 .GroupOperation => &[_]Enumerant{1344 .packed_vector_format => &.{
1067 .{ .name = "Reduce", .value = 0, .parameters = &[_]OperandKind{} },1345 .{ .name = "PackedVectorFormat4x8Bit", .value = 0, .parameters = &.{} },
1068 .{ .name = "InclusiveScan", .value = 1, .parameters = &[_]OperandKind{} },
1069 .{ .name = "ExclusiveScan", .value = 2, .parameters = &[_]OperandKind{} },
1070 .{ .name = "ClusteredReduce", .value = 3, .parameters = &[_]OperandKind{} },
1071 .{ .name = "PartitionedReduceNV", .value = 6, .parameters = &[_]OperandKind{} },
1072 .{ .name = "PartitionedInclusiveScanNV", .value = 7, .parameters = &[_]OperandKind{} },
1073 .{ .name = "PartitionedExclusiveScanNV", .value = 8, .parameters = &[_]OperandKind{} },
1074 },1346 },
1075 .KernelEnqueueFlags => &[_]Enumerant{1347 .cooperative_matrix_operands => &.{
1076 .{ .name = "NoWait", .value = 0, .parameters = &[_]OperandKind{} },1348 .{ .name = "NoneKHR", .value = 0x0000, .parameters = &.{} },
1077 .{ .name = "WaitKernel", .value = 1, .parameters = &[_]OperandKind{} },1349 .{ .name = "MatrixASignedComponentsKHR", .value = 0x0001, .parameters = &.{} },
1078 .{ .name = "WaitWorkGroup", .value = 2, .parameters = &[_]OperandKind{} },1350 .{ .name = "MatrixBSignedComponentsKHR", .value = 0x0002, .parameters = &.{} },
1351 .{ .name = "MatrixCSignedComponentsKHR", .value = 0x0004, .parameters = &.{} },
1352 .{ .name = "MatrixResultSignedComponentsKHR", .value = 0x0008, .parameters = &.{} },
1353 .{ .name = "SaturatingAccumulationKHR", .value = 0x0010, .parameters = &.{} },
1079 },1354 },
1080 .Capability => &[_]Enumerant{1355 .cooperative_matrix_layout => &.{
1081 .{ .name = "Matrix", .value = 0, .parameters = &[_]OperandKind{} },1356 .{ .name = "RowMajorKHR", .value = 0, .parameters = &.{} },
1082 .{ .name = "Shader", .value = 1, .parameters = &[_]OperandKind{} },1357 .{ .name = "ColumnMajorKHR", .value = 1, .parameters = &.{} },
1083 .{ .name = "Geometry", .value = 2, .parameters = &[_]OperandKind{} },1358 .{ .name = "RowBlockedInterleavedARM", .value = 4202, .parameters = &.{} },
1084 .{ .name = "Tessellation", .value = 3, .parameters = &[_]OperandKind{} },1359 .{ .name = "ColumnBlockedInterleavedARM", .value = 4203, .parameters = &.{} },
1085 .{ .name = "Addresses", .value = 4, .parameters = &[_]OperandKind{} },
1086 .{ .name = "Linkage", .value = 5, .parameters = &[_]OperandKind{} },
1087 .{ .name = "Kernel", .value = 6, .parameters = &[_]OperandKind{} },
1088 .{ .name = "Vector16", .value = 7, .parameters = &[_]OperandKind{} },
1089 .{ .name = "Float16Buffer", .value = 8, .parameters = &[_]OperandKind{} },
1090 .{ .name = "Float16", .value = 9, .parameters = &[_]OperandKind{} },
1091 .{ .name = "Float64", .value = 10, .parameters = &[_]OperandKind{} },
1092 .{ .name = "Int64", .value = 11, .parameters = &[_]OperandKind{} },
1093 .{ .name = "Int64Atomics", .value = 12, .parameters = &[_]OperandKind{} },
1094 .{ .name = "ImageBasic", .value = 13, .parameters = &[_]OperandKind{} },
1095 .{ .name = "ImageReadWrite", .value = 14, .parameters = &[_]OperandKind{} },
1096 .{ .name = "ImageMipmap", .value = 15, .parameters = &[_]OperandKind{} },
1097 .{ .name = "Pipes", .value = 17, .parameters = &[_]OperandKind{} },
1098 .{ .name = "Groups", .value = 18, .parameters = &[_]OperandKind{} },
1099 .{ .name = "DeviceEnqueue", .value = 19, .parameters = &[_]OperandKind{} },
1100 .{ .name = "LiteralSampler", .value = 20, .parameters = &[_]OperandKind{} },
1101 .{ .name = "AtomicStorage", .value = 21, .parameters = &[_]OperandKind{} },
1102 .{ .name = "Int16", .value = 22, .parameters = &[_]OperandKind{} },
1103 .{ .name = "TessellationPointSize", .value = 23, .parameters = &[_]OperandKind{} },
1104 .{ .name = "GeometryPointSize", .value = 24, .parameters = &[_]OperandKind{} },
1105 .{ .name = "ImageGatherExtended", .value = 25, .parameters = &[_]OperandKind{} },
1106 .{ .name = "StorageImageMultisample", .value = 27, .parameters = &[_]OperandKind{} },
1107 .{ .name = "UniformBufferArrayDynamicIndexing", .value = 28, .parameters = &[_]OperandKind{} },
1108 .{ .name = "SampledImageArrayDynamicIndexing", .value = 29, .parameters = &[_]OperandKind{} },
1109 .{ .name = "StorageBufferArrayDynamicIndexing", .value = 30, .parameters = &[_]OperandKind{} },
1110 .{ .name = "StorageImageArrayDynamicIndexing", .value = 31, .parameters = &[_]OperandKind{} },
1111 .{ .name = "ClipDistance", .value = 32, .parameters = &[_]OperandKind{} },
1112 .{ .name = "CullDistance", .value = 33, .parameters = &[_]OperandKind{} },
1113 .{ .name = "ImageCubeArray", .value = 34, .parameters = &[_]OperandKind{} },
1114 .{ .name = "SampleRateShading", .value = 35, .parameters = &[_]OperandKind{} },
1115 .{ .name = "ImageRect", .value = 36, .parameters = &[_]OperandKind{} },
1116 .{ .name = "SampledRect", .value = 37, .parameters = &[_]OperandKind{} },
1117 .{ .name = "GenericPointer", .value = 38, .parameters = &[_]OperandKind{} },
1118 .{ .name = "Int8", .value = 39, .parameters = &[_]OperandKind{} },
1119 .{ .name = "InputAttachment", .value = 40, .parameters = &[_]OperandKind{} },
1120 .{ .name = "SparseResidency", .value = 41, .parameters = &[_]OperandKind{} },
1121 .{ .name = "MinLod", .value = 42, .parameters = &[_]OperandKind{} },
1122 .{ .name = "Sampled1D", .value = 43, .parameters = &[_]OperandKind{} },
1123 .{ .name = "Image1D", .value = 44, .parameters = &[_]OperandKind{} },
1124 .{ .name = "SampledCubeArray", .value = 45, .parameters = &[_]OperandKind{} },
1125 .{ .name = "SampledBuffer", .value = 46, .parameters = &[_]OperandKind{} },
1126 .{ .name = "ImageBuffer", .value = 47, .parameters = &[_]OperandKind{} },
1127 .{ .name = "ImageMSArray", .value = 48, .parameters = &[_]OperandKind{} },
1128 .{ .name = "StorageImageExtendedFormats", .value = 49, .parameters = &[_]OperandKind{} },
1129 .{ .name = "ImageQuery", .value = 50, .parameters = &[_]OperandKind{} },
1130 .{ .name = "DerivativeControl", .value = 51, .parameters = &[_]OperandKind{} },
1131 .{ .name = "InterpolationFunction", .value = 52, .parameters = &[_]OperandKind{} },
1132 .{ .name = "TransformFeedback", .value = 53, .parameters = &[_]OperandKind{} },
1133 .{ .name = "GeometryStreams", .value = 54, .parameters = &[_]OperandKind{} },
1134 .{ .name = "StorageImageReadWithoutFormat", .value = 55, .parameters = &[_]OperandKind{} },
1135 .{ .name = "StorageImageWriteWithoutFormat", .value = 56, .parameters = &[_]OperandKind{} },
1136 .{ .name = "MultiViewport", .value = 57, .parameters = &[_]OperandKind{} },
1137 .{ .name = "SubgroupDispatch", .value = 58, .parameters = &[_]OperandKind{} },
1138 .{ .name = "NamedBarrier", .value = 59, .parameters = &[_]OperandKind{} },
1139 .{ .name = "PipeStorage", .value = 60, .parameters = &[_]OperandKind{} },
1140 .{ .name = "GroupNonUniform", .value = 61, .parameters = &[_]OperandKind{} },
1141 .{ .name = "GroupNonUniformVote", .value = 62, .parameters = &[_]OperandKind{} },
1142 .{ .name = "GroupNonUniformArithmetic", .value = 63, .parameters = &[_]OperandKind{} },
1143 .{ .name = "GroupNonUniformBallot", .value = 64, .parameters = &[_]OperandKind{} },
1144 .{ .name = "GroupNonUniformShuffle", .value = 65, .parameters = &[_]OperandKind{} },
1145 .{ .name = "GroupNonUniformShuffleRelative", .value = 66, .parameters = &[_]OperandKind{} },
1146 .{ .name = "GroupNonUniformClustered", .value = 67, .parameters = &[_]OperandKind{} },
1147 .{ .name = "GroupNonUniformQuad", .value = 68, .parameters = &[_]OperandKind{} },
1148 .{ .name = "ShaderLayer", .value = 69, .parameters = &[_]OperandKind{} },
1149 .{ .name = "ShaderViewportIndex", .value = 70, .parameters = &[_]OperandKind{} },
1150 .{ .name = "UniformDecoration", .value = 71, .parameters = &[_]OperandKind{} },
1151 .{ .name = "CoreBuiltinsARM", .value = 4165, .parameters = &[_]OperandKind{} },
1152 .{ .name = "TileImageColorReadAccessEXT", .value = 4166, .parameters = &[_]OperandKind{} },
1153 .{ .name = "TileImageDepthReadAccessEXT", .value = 4167, .parameters = &[_]OperandKind{} },
1154 .{ .name = "TileImageStencilReadAccessEXT", .value = 4168, .parameters = &[_]OperandKind{} },
1155 .{ .name = "FragmentShadingRateKHR", .value = 4422, .parameters = &[_]OperandKind{} },
1156 .{ .name = "SubgroupBallotKHR", .value = 4423, .parameters = &[_]OperandKind{} },
1157 .{ .name = "DrawParameters", .value = 4427, .parameters = &[_]OperandKind{} },
1158 .{ .name = "WorkgroupMemoryExplicitLayoutKHR", .value = 4428, .parameters = &[_]OperandKind{} },
1159 .{ .name = "WorkgroupMemoryExplicitLayout8BitAccessKHR", .value = 4429, .parameters = &[_]OperandKind{} },
1160 .{ .name = "WorkgroupMemoryExplicitLayout16BitAccessKHR", .value = 4430, .parameters = &[_]OperandKind{} },
1161 .{ .name = "SubgroupVoteKHR", .value = 4431, .parameters = &[_]OperandKind{} },
1162 .{ .name = "StorageBuffer16BitAccess", .value = 4433, .parameters = &[_]OperandKind{} },
1163 .{ .name = "StorageUniformBufferBlock16", .value = 4433, .parameters = &[_]OperandKind{} },
1164 .{ .name = "UniformAndStorageBuffer16BitAccess", .value = 4434, .parameters = &[_]OperandKind{} },
1165 .{ .name = "StorageUniform16", .value = 4434, .parameters = &[_]OperandKind{} },
1166 .{ .name = "StoragePushConstant16", .value = 4435, .parameters = &[_]OperandKind{} },
1167 .{ .name = "StorageInputOutput16", .value = 4436, .parameters = &[_]OperandKind{} },
1168 .{ .name = "DeviceGroup", .value = 4437, .parameters = &[_]OperandKind{} },
1169 .{ .name = "MultiView", .value = 4439, .parameters = &[_]OperandKind{} },
1170 .{ .name = "VariablePointersStorageBuffer", .value = 4441, .parameters = &[_]OperandKind{} },
1171 .{ .name = "VariablePointers", .value = 4442, .parameters = &[_]OperandKind{} },
1172 .{ .name = "AtomicStorageOps", .value = 4445, .parameters = &[_]OperandKind{} },
1173 .{ .name = "SampleMaskPostDepthCoverage", .value = 4447, .parameters = &[_]OperandKind{} },
1174 .{ .name = "StorageBuffer8BitAccess", .value = 4448, .parameters = &[_]OperandKind{} },
1175 .{ .name = "UniformAndStorageBuffer8BitAccess", .value = 4449, .parameters = &[_]OperandKind{} },
1176 .{ .name = "StoragePushConstant8", .value = 4450, .parameters = &[_]OperandKind{} },
1177 .{ .name = "DenormPreserve", .value = 4464, .parameters = &[_]OperandKind{} },
1178 .{ .name = "DenormFlushToZero", .value = 4465, .parameters = &[_]OperandKind{} },
1179 .{ .name = "SignedZeroInfNanPreserve", .value = 4466, .parameters = &[_]OperandKind{} },
1180 .{ .name = "RoundingModeRTE", .value = 4467, .parameters = &[_]OperandKind{} },
1181 .{ .name = "RoundingModeRTZ", .value = 4468, .parameters = &[_]OperandKind{} },
1182 .{ .name = "RayQueryProvisionalKHR", .value = 4471, .parameters = &[_]OperandKind{} },
1183 .{ .name = "RayQueryKHR", .value = 4472, .parameters = &[_]OperandKind{} },
1184 .{ .name = "RayTraversalPrimitiveCullingKHR", .value = 4478, .parameters = &[_]OperandKind{} },
1185 .{ .name = "RayTracingKHR", .value = 4479, .parameters = &[_]OperandKind{} },
1186 .{ .name = "TextureSampleWeightedQCOM", .value = 4484, .parameters = &[_]OperandKind{} },
1187 .{ .name = "TextureBoxFilterQCOM", .value = 4485, .parameters = &[_]OperandKind{} },
1188 .{ .name = "TextureBlockMatchQCOM", .value = 4486, .parameters = &[_]OperandKind{} },
1189 .{ .name = "TextureBlockMatch2QCOM", .value = 4498, .parameters = &[_]OperandKind{} },
1190 .{ .name = "Float16ImageAMD", .value = 5008, .parameters = &[_]OperandKind{} },
1191 .{ .name = "ImageGatherBiasLodAMD", .value = 5009, .parameters = &[_]OperandKind{} },
1192 .{ .name = "FragmentMaskAMD", .value = 5010, .parameters = &[_]OperandKind{} },
1193 .{ .name = "StencilExportEXT", .value = 5013, .parameters = &[_]OperandKind{} },
1194 .{ .name = "ImageReadWriteLodAMD", .value = 5015, .parameters = &[_]OperandKind{} },
1195 .{ .name = "Int64ImageEXT", .value = 5016, .parameters = &[_]OperandKind{} },
1196 .{ .name = "ShaderClockKHR", .value = 5055, .parameters = &[_]OperandKind{} },
1197 .{ .name = "ShaderEnqueueAMDX", .value = 5067, .parameters = &[_]OperandKind{} },
1198 .{ .name = "QuadControlKHR", .value = 5087, .parameters = &[_]OperandKind{} },
1199 .{ .name = "SampleMaskOverrideCoverageNV", .value = 5249, .parameters = &[_]OperandKind{} },
1200 .{ .name = "GeometryShaderPassthroughNV", .value = 5251, .parameters = &[_]OperandKind{} },
1201 .{ .name = "ShaderViewportIndexLayerEXT", .value = 5254, .parameters = &[_]OperandKind{} },
1202 .{ .name = "ShaderViewportIndexLayerNV", .value = 5254, .parameters = &[_]OperandKind{} },
1203 .{ .name = "ShaderViewportMaskNV", .value = 5255, .parameters = &[_]OperandKind{} },
1204 .{ .name = "ShaderStereoViewNV", .value = 5259, .parameters = &[_]OperandKind{} },
1205 .{ .name = "PerViewAttributesNV", .value = 5260, .parameters = &[_]OperandKind{} },
1206 .{ .name = "FragmentFullyCoveredEXT", .value = 5265, .parameters = &[_]OperandKind{} },
1207 .{ .name = "MeshShadingNV", .value = 5266, .parameters = &[_]OperandKind{} },
1208 .{ .name = "ImageFootprintNV", .value = 5282, .parameters = &[_]OperandKind{} },
1209 .{ .name = "MeshShadingEXT", .value = 5283, .parameters = &[_]OperandKind{} },
1210 .{ .name = "FragmentBarycentricKHR", .value = 5284, .parameters = &[_]OperandKind{} },
1211 .{ .name = "FragmentBarycentricNV", .value = 5284, .parameters = &[_]OperandKind{} },
1212 .{ .name = "ComputeDerivativeGroupQuadsNV", .value = 5288, .parameters = &[_]OperandKind{} },
1213 .{ .name = "FragmentDensityEXT", .value = 5291, .parameters = &[_]OperandKind{} },
1214 .{ .name = "ShadingRateNV", .value = 5291, .parameters = &[_]OperandKind{} },
1215 .{ .name = "GroupNonUniformPartitionedNV", .value = 5297, .parameters = &[_]OperandKind{} },
1216 .{ .name = "ShaderNonUniform", .value = 5301, .parameters = &[_]OperandKind{} },
1217 .{ .name = "ShaderNonUniformEXT", .value = 5301, .parameters = &[_]OperandKind{} },
1218 .{ .name = "RuntimeDescriptorArray", .value = 5302, .parameters = &[_]OperandKind{} },
1219 .{ .name = "RuntimeDescriptorArrayEXT", .value = 5302, .parameters = &[_]OperandKind{} },
1220 .{ .name = "InputAttachmentArrayDynamicIndexing", .value = 5303, .parameters = &[_]OperandKind{} },
1221 .{ .name = "InputAttachmentArrayDynamicIndexingEXT", .value = 5303, .parameters = &[_]OperandKind{} },
1222 .{ .name = "UniformTexelBufferArrayDynamicIndexing", .value = 5304, .parameters = &[_]OperandKind{} },
1223 .{ .name = "UniformTexelBufferArrayDynamicIndexingEXT", .value = 5304, .parameters = &[_]OperandKind{} },
1224 .{ .name = "StorageTexelBufferArrayDynamicIndexing", .value = 5305, .parameters = &[_]OperandKind{} },
1225 .{ .name = "StorageTexelBufferArrayDynamicIndexingEXT", .value = 5305, .parameters = &[_]OperandKind{} },
1226 .{ .name = "UniformBufferArrayNonUniformIndexing", .value = 5306, .parameters = &[_]OperandKind{} },
1227 .{ .name = "UniformBufferArrayNonUniformIndexingEXT", .value = 5306, .parameters = &[_]OperandKind{} },
1228 .{ .name = "SampledImageArrayNonUniformIndexing", .value = 5307, .parameters = &[_]OperandKind{} },
1229 .{ .name = "SampledImageArrayNonUniformIndexingEXT", .value = 5307, .parameters = &[_]OperandKind{} },
1230 .{ .name = "StorageBufferArrayNonUniformIndexing", .value = 5308, .parameters = &[_]OperandKind{} },
1231 .{ .name = "StorageBufferArrayNonUniformIndexingEXT", .value = 5308, .parameters = &[_]OperandKind{} },
1232 .{ .name = "StorageImageArrayNonUniformIndexing", .value = 5309, .parameters = &[_]OperandKind{} },
1233 .{ .name = "StorageImageArrayNonUniformIndexingEXT", .value = 5309, .parameters = &[_]OperandKind{} },
1234 .{ .name = "InputAttachmentArrayNonUniformIndexing", .value = 5310, .parameters = &[_]OperandKind{} },
1235 .{ .name = "InputAttachmentArrayNonUniformIndexingEXT", .value = 5310, .parameters = &[_]OperandKind{} },
1236 .{ .name = "UniformTexelBufferArrayNonUniformIndexing", .value = 5311, .parameters = &[_]OperandKind{} },
1237 .{ .name = "UniformTexelBufferArrayNonUniformIndexingEXT", .value = 5311, .parameters = &[_]OperandKind{} },
1238 .{ .name = "StorageTexelBufferArrayNonUniformIndexing", .value = 5312, .parameters = &[_]OperandKind{} },
1239 .{ .name = "StorageTexelBufferArrayNonUniformIndexingEXT", .value = 5312, .parameters = &[_]OperandKind{} },
1240 .{ .name = "RayTracingPositionFetchKHR", .value = 5336, .parameters = &[_]OperandKind{} },
1241 .{ .name = "RayTracingNV", .value = 5340, .parameters = &[_]OperandKind{} },
1242 .{ .name = "RayTracingMotionBlurNV", .value = 5341, .parameters = &[_]OperandKind{} },
1243 .{ .name = "VulkanMemoryModel", .value = 5345, .parameters = &[_]OperandKind{} },
1244 .{ .name = "VulkanMemoryModelKHR", .value = 5345, .parameters = &[_]OperandKind{} },
1245 .{ .name = "VulkanMemoryModelDeviceScope", .value = 5346, .parameters = &[_]OperandKind{} },
1246 .{ .name = "VulkanMemoryModelDeviceScopeKHR", .value = 5346, .parameters = &[_]OperandKind{} },
1247 .{ .name = "PhysicalStorageBufferAddresses", .value = 5347, .parameters = &[_]OperandKind{} },
1248 .{ .name = "PhysicalStorageBufferAddressesEXT", .value = 5347, .parameters = &[_]OperandKind{} },
1249 .{ .name = "ComputeDerivativeGroupLinearNV", .value = 5350, .parameters = &[_]OperandKind{} },
1250 .{ .name = "RayTracingProvisionalKHR", .value = 5353, .parameters = &[_]OperandKind{} },
1251 .{ .name = "CooperativeMatrixNV", .value = 5357, .parameters = &[_]OperandKind{} },
1252 .{ .name = "FragmentShaderSampleInterlockEXT", .value = 5363, .parameters = &[_]OperandKind{} },
1253 .{ .name = "FragmentShaderShadingRateInterlockEXT", .value = 5372, .parameters = &[_]OperandKind{} },
1254 .{ .name = "ShaderSMBuiltinsNV", .value = 5373, .parameters = &[_]OperandKind{} },
1255 .{ .name = "FragmentShaderPixelInterlockEXT", .value = 5378, .parameters = &[_]OperandKind{} },
1256 .{ .name = "DemoteToHelperInvocation", .value = 5379, .parameters = &[_]OperandKind{} },
1257 .{ .name = "DemoteToHelperInvocationEXT", .value = 5379, .parameters = &[_]OperandKind{} },
1258 .{ .name = "DisplacementMicromapNV", .value = 5380, .parameters = &[_]OperandKind{} },
1259 .{ .name = "RayTracingOpacityMicromapEXT", .value = 5381, .parameters = &[_]OperandKind{} },
1260 .{ .name = "ShaderInvocationReorderNV", .value = 5383, .parameters = &[_]OperandKind{} },
1261 .{ .name = "BindlessTextureNV", .value = 5390, .parameters = &[_]OperandKind{} },
1262 .{ .name = "RayQueryPositionFetchKHR", .value = 5391, .parameters = &[_]OperandKind{} },
1263 .{ .name = "AtomicFloat16VectorNV", .value = 5404, .parameters = &[_]OperandKind{} },
1264 .{ .name = "RayTracingDisplacementMicromapNV", .value = 5409, .parameters = &[_]OperandKind{} },
1265 .{ .name = "RawAccessChainsNV", .value = 5414, .parameters = &[_]OperandKind{} },
1266 .{ .name = "SubgroupShuffleINTEL", .value = 5568, .parameters = &[_]OperandKind{} },
1267 .{ .name = "SubgroupBufferBlockIOINTEL", .value = 5569, .parameters = &[_]OperandKind{} },
1268 .{ .name = "SubgroupImageBlockIOINTEL", .value = 5570, .parameters = &[_]OperandKind{} },
1269 .{ .name = "SubgroupImageMediaBlockIOINTEL", .value = 5579, .parameters = &[_]OperandKind{} },
1270 .{ .name = "RoundToInfinityINTEL", .value = 5582, .parameters = &[_]OperandKind{} },
1271 .{ .name = "FloatingPointModeINTEL", .value = 5583, .parameters = &[_]OperandKind{} },
1272 .{ .name = "IntegerFunctions2INTEL", .value = 5584, .parameters = &[_]OperandKind{} },
1273 .{ .name = "FunctionPointersINTEL", .value = 5603, .parameters = &[_]OperandKind{} },
1274 .{ .name = "IndirectReferencesINTEL", .value = 5604, .parameters = &[_]OperandKind{} },
1275 .{ .name = "AsmINTEL", .value = 5606, .parameters = &[_]OperandKind{} },
1276 .{ .name = "AtomicFloat32MinMaxEXT", .value = 5612, .parameters = &[_]OperandKind{} },
1277 .{ .name = "AtomicFloat64MinMaxEXT", .value = 5613, .parameters = &[_]OperandKind{} },
1278 .{ .name = "AtomicFloat16MinMaxEXT", .value = 5616, .parameters = &[_]OperandKind{} },
1279 .{ .name = "VectorComputeINTEL", .value = 5617, .parameters = &[_]OperandKind{} },
1280 .{ .name = "VectorAnyINTEL", .value = 5619, .parameters = &[_]OperandKind{} },
1281 .{ .name = "ExpectAssumeKHR", .value = 5629, .parameters = &[_]OperandKind{} },
1282 .{ .name = "SubgroupAvcMotionEstimationINTEL", .value = 5696, .parameters = &[_]OperandKind{} },
1283 .{ .name = "SubgroupAvcMotionEstimationIntraINTEL", .value = 5697, .parameters = &[_]OperandKind{} },
1284 .{ .name = "SubgroupAvcMotionEstimationChromaINTEL", .value = 5698, .parameters = &[_]OperandKind{} },
1285 .{ .name = "VariableLengthArrayINTEL", .value = 5817, .parameters = &[_]OperandKind{} },
1286 .{ .name = "FunctionFloatControlINTEL", .value = 5821, .parameters = &[_]OperandKind{} },
1287 .{ .name = "FPGAMemoryAttributesINTEL", .value = 5824, .parameters = &[_]OperandKind{} },
1288 .{ .name = "FPFastMathModeINTEL", .value = 5837, .parameters = &[_]OperandKind{} },
1289 .{ .name = "ArbitraryPrecisionIntegersINTEL", .value = 5844, .parameters = &[_]OperandKind{} },
1290 .{ .name = "ArbitraryPrecisionFloatingPointINTEL", .value = 5845, .parameters = &[_]OperandKind{} },
1291 .{ .name = "UnstructuredLoopControlsINTEL", .value = 5886, .parameters = &[_]OperandKind{} },
1292 .{ .name = "FPGALoopControlsINTEL", .value = 5888, .parameters = &[_]OperandKind{} },
1293 .{ .name = "KernelAttributesINTEL", .value = 5892, .parameters = &[_]OperandKind{} },
1294 .{ .name = "FPGAKernelAttributesINTEL", .value = 5897, .parameters = &[_]OperandKind{} },
1295 .{ .name = "FPGAMemoryAccessesINTEL", .value = 5898, .parameters = &[_]OperandKind{} },
1296 .{ .name = "FPGAClusterAttributesINTEL", .value = 5904, .parameters = &[_]OperandKind{} },
1297 .{ .name = "LoopFuseINTEL", .value = 5906, .parameters = &[_]OperandKind{} },
1298 .{ .name = "FPGADSPControlINTEL", .value = 5908, .parameters = &[_]OperandKind{} },
1299 .{ .name = "MemoryAccessAliasingINTEL", .value = 5910, .parameters = &[_]OperandKind{} },
1300 .{ .name = "FPGAInvocationPipeliningAttributesINTEL", .value = 5916, .parameters = &[_]OperandKind{} },
1301 .{ .name = "FPGABufferLocationINTEL", .value = 5920, .parameters = &[_]OperandKind{} },
1302 .{ .name = "ArbitraryPrecisionFixedPointINTEL", .value = 5922, .parameters = &[_]OperandKind{} },
1303 .{ .name = "USMStorageClassesINTEL", .value = 5935, .parameters = &[_]OperandKind{} },
1304 .{ .name = "RuntimeAlignedAttributeINTEL", .value = 5939, .parameters = &[_]OperandKind{} },
1305 .{ .name = "IOPipesINTEL", .value = 5943, .parameters = &[_]OperandKind{} },
1306 .{ .name = "BlockingPipesINTEL", .value = 5945, .parameters = &[_]OperandKind{} },
1307 .{ .name = "FPGARegINTEL", .value = 5948, .parameters = &[_]OperandKind{} },
1308 .{ .name = "DotProductInputAll", .value = 6016, .parameters = &[_]OperandKind{} },
1309 .{ .name = "DotProductInputAllKHR", .value = 6016, .parameters = &[_]OperandKind{} },
1310 .{ .name = "DotProductInput4x8Bit", .value = 6017, .parameters = &[_]OperandKind{} },
1311 .{ .name = "DotProductInput4x8BitKHR", .value = 6017, .parameters = &[_]OperandKind{} },
1312 .{ .name = "DotProductInput4x8BitPacked", .value = 6018, .parameters = &[_]OperandKind{} },
1313 .{ .name = "DotProductInput4x8BitPackedKHR", .value = 6018, .parameters = &[_]OperandKind{} },
1314 .{ .name = "DotProduct", .value = 6019, .parameters = &[_]OperandKind{} },
1315 .{ .name = "DotProductKHR", .value = 6019, .parameters = &[_]OperandKind{} },
1316 .{ .name = "RayCullMaskKHR", .value = 6020, .parameters = &[_]OperandKind{} },
1317 .{ .name = "CooperativeMatrixKHR", .value = 6022, .parameters = &[_]OperandKind{} },
1318 .{ .name = "BitInstructions", .value = 6025, .parameters = &[_]OperandKind{} },
1319 .{ .name = "GroupNonUniformRotateKHR", .value = 6026, .parameters = &[_]OperandKind{} },
1320 .{ .name = "FloatControls2", .value = 6029, .parameters = &[_]OperandKind{} },
1321 .{ .name = "AtomicFloat32AddEXT", .value = 6033, .parameters = &[_]OperandKind{} },
1322 .{ .name = "AtomicFloat64AddEXT", .value = 6034, .parameters = &[_]OperandKind{} },
1323 .{ .name = "LongCompositesINTEL", .value = 6089, .parameters = &[_]OperandKind{} },
1324 .{ .name = "OptNoneINTEL", .value = 6094, .parameters = &[_]OperandKind{} },
1325 .{ .name = "AtomicFloat16AddEXT", .value = 6095, .parameters = &[_]OperandKind{} },
1326 .{ .name = "DebugInfoModuleINTEL", .value = 6114, .parameters = &[_]OperandKind{} },
1327 .{ .name = "BFloat16ConversionINTEL", .value = 6115, .parameters = &[_]OperandKind{} },
1328 .{ .name = "SplitBarrierINTEL", .value = 6141, .parameters = &[_]OperandKind{} },
1329 .{ .name = "FPGAClusterAttributesV2INTEL", .value = 6150, .parameters = &[_]OperandKind{} },
1330 .{ .name = "FPGAKernelAttributesv2INTEL", .value = 6161, .parameters = &[_]OperandKind{} },
1331 .{ .name = "FPMaxErrorINTEL", .value = 6169, .parameters = &[_]OperandKind{} },
1332 .{ .name = "FPGALatencyControlINTEL", .value = 6171, .parameters = &[_]OperandKind{} },
1333 .{ .name = "FPGAArgumentInterfacesINTEL", .value = 6174, .parameters = &[_]OperandKind{} },
1334 .{ .name = "GlobalVariableHostAccessINTEL", .value = 6187, .parameters = &[_]OperandKind{} },
1335 .{ .name = "GlobalVariableFPGADecorationsINTEL", .value = 6189, .parameters = &[_]OperandKind{} },
1336 .{ .name = "GroupUniformArithmeticKHR", .value = 6400, .parameters = &[_]OperandKind{} },
1337 .{ .name = "MaskedGatherScatterINTEL", .value = 6427, .parameters = &[_]OperandKind{} },
1338 .{ .name = "CacheControlsINTEL", .value = 6441, .parameters = &[_]OperandKind{} },
1339 .{ .name = "RegisterLimitsINTEL", .value = 6460, .parameters = &[_]OperandKind{} },
1340 },1360 },
1341 .RayQueryIntersection => &[_]Enumerant{1361 .cooperative_matrix_use => &.{
1342 .{ .name = "RayQueryCandidateIntersectionKHR", .value = 0, .parameters = &[_]OperandKind{} },1362 .{ .name = "MatrixAKHR", .value = 0, .parameters = &.{} },
1343 .{ .name = "RayQueryCommittedIntersectionKHR", .value = 1, .parameters = &[_]OperandKind{} },1363 .{ .name = "MatrixBKHR", .value = 1, .parameters = &.{} },
1364 .{ .name = "MatrixAccumulatorKHR", .value = 2, .parameters = &.{} },
1344 },1365 },
1345 .RayQueryCommittedIntersectionType => &[_]Enumerant{1366 .cooperative_matrix_reduce => &.{
1346 .{ .name = "RayQueryCommittedIntersectionNoneKHR", .value = 0, .parameters = &[_]OperandKind{} },1367 .{ .name = "Row", .value = 0x0001, .parameters = &.{} },
1347 .{ .name = "RayQueryCommittedIntersectionTriangleKHR", .value = 1, .parameters = &[_]OperandKind{} },1368 .{ .name = "Column", .value = 0x0002, .parameters = &.{} },
1348 .{ .name = "RayQueryCommittedIntersectionGeneratedKHR", .value = 2, .parameters = &[_]OperandKind{} },1369 .{ .name = "2x2", .value = 0x0004, .parameters = &.{} },
1349 },1370 },
1350 .RayQueryCandidateIntersectionType => &[_]Enumerant{1371 .tensor_clamp_mode => &.{
1351 .{ .name = "RayQueryCandidateIntersectionTriangleKHR", .value = 0, .parameters = &[_]OperandKind{} },1372 .{ .name = "Undefined", .value = 0, .parameters = &.{} },
1352 .{ .name = "RayQueryCandidateIntersectionAABBKHR", .value = 1, .parameters = &[_]OperandKind{} },1373 .{ .name = "Constant", .value = 1, .parameters = &.{} },
1374 .{ .name = "ClampToEdge", .value = 2, .parameters = &.{} },
1375 .{ .name = "Repeat", .value = 3, .parameters = &.{} },
1376 .{ .name = "RepeatMirrored", .value = 4, .parameters = &.{} },
1353 },1377 },
1354 .PackedVectorFormat => &[_]Enumerant{1378 .tensor_addressing_operands => &.{
1355 .{ .name = "PackedVectorFormat4x8Bit", .value = 0, .parameters = &[_]OperandKind{} },1379 .{ .name = "TensorView", .value = 0x0001, .parameters = &.{.id_ref} },
1356 .{ .name = "PackedVectorFormat4x8BitKHR", .value = 0, .parameters = &[_]OperandKind{} },1380 .{ .name = "DecodeFunc", .value = 0x0002, .parameters = &.{.id_ref} },
1357 },1381 },
1358 .CooperativeMatrixOperands => &[_]Enumerant{1382 .initialization_mode_qualifier => &.{
1359 .{ .name = "NoneKHR", .value = 0x0000, .parameters = &[_]OperandKind{} },1383 .{ .name = "InitOnDeviceReprogramINTEL", .value = 0, .parameters = &.{} },
1360 .{ .name = "MatrixASignedComponentsKHR", .value = 0x0001, .parameters = &[_]OperandKind{} },1384 .{ .name = "InitOnDeviceResetINTEL", .value = 1, .parameters = &.{} },
1361 .{ .name = "MatrixBSignedComponentsKHR", .value = 0x0002, .parameters = &[_]OperandKind{} },
1362 .{ .name = "MatrixCSignedComponentsKHR", .value = 0x0004, .parameters = &[_]OperandKind{} },
1363 .{ .name = "MatrixResultSignedComponentsKHR", .value = 0x0008, .parameters = &[_]OperandKind{} },
1364 .{ .name = "SaturatingAccumulationKHR", .value = 0x0010, .parameters = &[_]OperandKind{} },
1365 },1385 },
1366 .CooperativeMatrixLayout => &[_]Enumerant{1386 .load_cache_control => &.{
1367 .{ .name = "RowMajorKHR", .value = 0, .parameters = &[_]OperandKind{} },1387 .{ .name = "UncachedINTEL", .value = 0, .parameters = &.{} },
1368 .{ .name = "ColumnMajorKHR", .value = 1, .parameters = &[_]OperandKind{} },1388 .{ .name = "CachedINTEL", .value = 1, .parameters = &.{} },
1389 .{ .name = "StreamingINTEL", .value = 2, .parameters = &.{} },
1390 .{ .name = "InvalidateAfterReadINTEL", .value = 3, .parameters = &.{} },
1391 .{ .name = "ConstCachedINTEL", .value = 4, .parameters = &.{} },
1369 },1392 },
1370 .CooperativeMatrixUse => &[_]Enumerant{1393 .store_cache_control => &.{
1371 .{ .name = "MatrixAKHR", .value = 0, .parameters = &[_]OperandKind{} },1394 .{ .name = "UncachedINTEL", .value = 0, .parameters = &.{} },
1372 .{ .name = "MatrixBKHR", .value = 1, .parameters = &[_]OperandKind{} },1395 .{ .name = "WriteThroughINTEL", .value = 1, .parameters = &.{} },
1373 .{ .name = "MatrixAccumulatorKHR", .value = 2, .parameters = &[_]OperandKind{} },1396 .{ .name = "WriteBackINTEL", .value = 2, .parameters = &.{} },
1397 .{ .name = "StreamingINTEL", .value = 3, .parameters = &.{} },
1374 },1398 },
1375 .InitializationModeQualifier => &[_]Enumerant{1399 .named_maximum_number_of_registers => &.{
1376 .{ .name = "InitOnDeviceReprogramINTEL", .value = 0, .parameters = &[_]OperandKind{} },1400 .{ .name = "AutoINTEL", .value = 0, .parameters = &.{} },
1377 .{ .name = "InitOnDeviceResetINTEL", .value = 1, .parameters = &[_]OperandKind{} },
1378 },1401 },
1379 .LoadCacheControl => &[_]Enumerant{1402 .matrix_multiply_accumulate_operands => &.{
1380 .{ .name = "UncachedINTEL", .value = 0, .parameters = &[_]OperandKind{} },1403 .{ .name = "MatrixASignedComponentsINTEL", .value = 0x1, .parameters = &.{} },
1381 .{ .name = "CachedINTEL", .value = 1, .parameters = &[_]OperandKind{} },1404 .{ .name = "MatrixBSignedComponentsINTEL", .value = 0x2, .parameters = &.{} },
1382 .{ .name = "StreamingINTEL", .value = 2, .parameters = &[_]OperandKind{} },1405 .{ .name = "MatrixCBFloat16INTEL", .value = 0x4, .parameters = &.{} },
1383 .{ .name = "InvalidateAfterReadINTEL", .value = 3, .parameters = &[_]OperandKind{} },1406 .{ .name = "MatrixResultBFloat16INTEL", .value = 0x8, .parameters = &.{} },
1384 .{ .name = "ConstCachedINTEL", .value = 4, .parameters = &[_]OperandKind{} },1407 .{ .name = "MatrixAPackedInt8INTEL", .value = 0x10, .parameters = &.{} },
1408 .{ .name = "MatrixBPackedInt8INTEL", .value = 0x20, .parameters = &.{} },
1409 .{ .name = "MatrixAPackedInt4INTEL", .value = 0x40, .parameters = &.{} },
1410 .{ .name = "MatrixBPackedInt4INTEL", .value = 0x80, .parameters = &.{} },
1411 .{ .name = "MatrixATF32INTEL", .value = 0x100, .parameters = &.{} },
1412 .{ .name = "MatrixBTF32INTEL", .value = 0x200, .parameters = &.{} },
1413 .{ .name = "MatrixAPackedFloat16INTEL", .value = 0x400, .parameters = &.{} },
1414 .{ .name = "MatrixBPackedFloat16INTEL", .value = 0x800, .parameters = &.{} },
1415 .{ .name = "MatrixAPackedBFloat16INTEL", .value = 0x1000, .parameters = &.{} },
1416 .{ .name = "MatrixBPackedBFloat16INTEL", .value = 0x2000, .parameters = &.{} },
1385 },1417 },
1386 .StoreCacheControl => &[_]Enumerant{1418 .fp_encoding => &.{
1387 .{ .name = "UncachedINTEL", .value = 0, .parameters = &[_]OperandKind{} },1419 .{ .name = "BFloat16KHR", .value = 0, .parameters = &.{} },
1388 .{ .name = "WriteThroughINTEL", .value = 1, .parameters = &[_]OperandKind{} },1420 .{ .name = "Float8E4M3EXT", .value = 4214, .parameters = &.{} },
1389 .{ .name = "WriteBackINTEL", .value = 2, .parameters = &[_]OperandKind{} },1421 .{ .name = "Float8E5M2EXT", .value = 4215, .parameters = &.{} },
1390 .{ .name = "StreamingINTEL", .value = 3, .parameters = &[_]OperandKind{} },
1391 },1422 },
1392 .NamedMaximumNumberOfRegisters => &[_]Enumerant{1423 .cooperative_vector_matrix_layout => &.{
1393 .{ .name = "AutoINTEL", .value = 0, .parameters = &[_]OperandKind{} },1424 .{ .name = "RowMajorNV", .value = 0, .parameters = &.{} },
1425 .{ .name = "ColumnMajorNV", .value = 1, .parameters = &.{} },
1426 .{ .name = "InferencingOptimalNV", .value = 2, .parameters = &.{} },
1427 .{ .name = "TrainingOptimalNV", .value = 3, .parameters = &.{} },
1394 },1428 },
1395 .IdResultType => unreachable,1429 .component_type => &.{
1396 .IdResult => unreachable,1430 .{ .name = "Float16NV", .value = 0, .parameters = &.{} },
1397 .IdMemorySemantics => unreachable,1431 .{ .name = "Float32NV", .value = 1, .parameters = &.{} },
1398 .IdScope => unreachable,1432 .{ .name = "Float64NV", .value = 2, .parameters = &.{} },
1399 .IdRef => unreachable,1433 .{ .name = "SignedInt8NV", .value = 3, .parameters = &.{} },
1400 .LiteralInteger => unreachable,1434 .{ .name = "SignedInt16NV", .value = 4, .parameters = &.{} },
1401 .LiteralString => unreachable,1435 .{ .name = "SignedInt32NV", .value = 5, .parameters = &.{} },
1402 .LiteralFloat => unreachable,1436 .{ .name = "SignedInt64NV", .value = 6, .parameters = &.{} },
1403 .LiteralContextDependentNumber => unreachable,1437 .{ .name = "UnsignedInt8NV", .value = 7, .parameters = &.{} },
1404 .LiteralExtInstInteger => unreachable,1438 .{ .name = "UnsignedInt16NV", .value = 8, .parameters = &.{} },
1405 .LiteralSpecConstantOpInteger => unreachable,1439 .{ .name = "UnsignedInt32NV", .value = 9, .parameters = &.{} },
1406 .PairLiteralIntegerIdRef => unreachable,1440 .{ .name = "UnsignedInt64NV", .value = 10, .parameters = &.{} },
1407 .PairIdRefLiteralInteger => unreachable,1441 .{ .name = "SignedInt8PackedNV", .value = 1000491000, .parameters = &.{} },
1408 .PairIdRefIdRef => unreachable,1442 .{ .name = "UnsignedInt8PackedNV", .value = 1000491001, .parameters = &.{} },
1409 .@"OpenCL.DebugInfo.100.DebugInfoFlags" => &[_]Enumerant{1443 .{ .name = "FloatE4M3NV", .value = 1000491002, .parameters = &.{} },
1410 .{ .name = "FlagIsProtected", .value = 0x01, .parameters = &[_]OperandKind{} },1444 .{ .name = "FloatE5M2NV", .value = 1000491003, .parameters = &.{} },
1411 .{ .name = "FlagIsPrivate", .value = 0x02, .parameters = &[_]OperandKind{} },
1412 .{ .name = "FlagIsPublic", .value = 0x03, .parameters = &[_]OperandKind{} },
1413 .{ .name = "FlagIsLocal", .value = 0x04, .parameters = &[_]OperandKind{} },
1414 .{ .name = "FlagIsDefinition", .value = 0x08, .parameters = &[_]OperandKind{} },
1415 .{ .name = "FlagFwdDecl", .value = 0x10, .parameters = &[_]OperandKind{} },
1416 .{ .name = "FlagArtificial", .value = 0x20, .parameters = &[_]OperandKind{} },
1417 .{ .name = "FlagExplicit", .value = 0x40, .parameters = &[_]OperandKind{} },
1418 .{ .name = "FlagPrototyped", .value = 0x80, .parameters = &[_]OperandKind{} },
1419 .{ .name = "FlagObjectPointer", .value = 0x100, .parameters = &[_]OperandKind{} },
1420 .{ .name = "FlagStaticMember", .value = 0x200, .parameters = &[_]OperandKind{} },
1421 .{ .name = "FlagIndirectVariable", .value = 0x400, .parameters = &[_]OperandKind{} },
1422 .{ .name = "FlagLValueReference", .value = 0x800, .parameters = &[_]OperandKind{} },
1423 .{ .name = "FlagRValueReference", .value = 0x1000, .parameters = &[_]OperandKind{} },
1424 .{ .name = "FlagIsOptimized", .value = 0x2000, .parameters = &[_]OperandKind{} },
1425 .{ .name = "FlagIsEnumClass", .value = 0x4000, .parameters = &[_]OperandKind{} },
1426 .{ .name = "FlagTypePassByValue", .value = 0x8000, .parameters = &[_]OperandKind{} },
1427 .{ .name = "FlagTypePassByReference", .value = 0x10000, .parameters = &[_]OperandKind{} },
1428 },1445 },
1429 .@"OpenCL.DebugInfo.100.DebugBaseTypeAttributeEncoding" => &[_]Enumerant{1446 .id_result_type => unreachable,
1430 .{ .name = "Unspecified", .value = 0, .parameters = &[_]OperandKind{} },1447 .id_result => unreachable,
1431 .{ .name = "Address", .value = 1, .parameters = &[_]OperandKind{} },1448 .id_memory_semantics => unreachable,
1432 .{ .name = "Boolean", .value = 2, .parameters = &[_]OperandKind{} },1449 .id_scope => unreachable,
1433 .{ .name = "Float", .value = 3, .parameters = &[_]OperandKind{} },1450 .id_ref => unreachable,
1434 .{ .name = "Signed", .value = 4, .parameters = &[_]OperandKind{} },1451 .literal_integer => unreachable,
1435 .{ .name = "SignedChar", .value = 5, .parameters = &[_]OperandKind{} },1452 .literal_string => unreachable,
1436 .{ .name = "Unsigned", .value = 6, .parameters = &[_]OperandKind{} },1453 .literal_float => unreachable,
1437 .{ .name = "UnsignedChar", .value = 7, .parameters = &[_]OperandKind{} },1454 .literal_context_dependent_number => unreachable,
1455 .literal_ext_inst_integer => unreachable,
1456 .literal_spec_constant_op_integer => unreachable,
1457 .pair_literal_integer_id_ref => unreachable,
1458 .pair_id_ref_literal_integer => unreachable,
1459 .pair_id_ref_id_ref => unreachable,
1460 .tensor_operands => &.{
1461 .{ .name = "NoneARM", .value = 0x0000, .parameters = &.{} },
1462 .{ .name = "NontemporalARM", .value = 0x0001, .parameters = &.{} },
1463 .{ .name = "OutOfBoundsValueARM", .value = 0x0002, .parameters = &.{.id_ref} },
1464 .{ .name = "MakeElementAvailableARM", .value = 0x0004, .parameters = &.{.id_ref} },
1465 .{ .name = "MakeElementVisibleARM", .value = 0x0008, .parameters = &.{.id_ref} },
1466 .{ .name = "NonPrivateElementARM", .value = 0x0010, .parameters = &.{} },
1438 },1467 },
1439 .@"OpenCL.DebugInfo.100.DebugCompositeType" => &[_]Enumerant{1468 .debug_info_debug_info_flags => &.{
1440 .{ .name = "Class", .value = 0, .parameters = &[_]OperandKind{} },1469 .{ .name = "FlagIsProtected", .value = 0x01, .parameters = &.{} },
1441 .{ .name = "Structure", .value = 1, .parameters = &[_]OperandKind{} },1470 .{ .name = "FlagIsPrivate", .value = 0x02, .parameters = &.{} },
1442 .{ .name = "Union", .value = 2, .parameters = &[_]OperandKind{} },1471 .{ .name = "FlagIsPublic", .value = 0x03, .parameters = &.{} },
1472 .{ .name = "FlagIsLocal", .value = 0x04, .parameters = &.{} },
1473 .{ .name = "FlagIsDefinition", .value = 0x08, .parameters = &.{} },
1474 .{ .name = "FlagFwdDecl", .value = 0x10, .parameters = &.{} },
1475 .{ .name = "FlagArtificial", .value = 0x20, .parameters = &.{} },
1476 .{ .name = "FlagExplicit", .value = 0x40, .parameters = &.{} },
1477 .{ .name = "FlagPrototyped", .value = 0x80, .parameters = &.{} },
1478 .{ .name = "FlagObjectPointer", .value = 0x100, .parameters = &.{} },
1479 .{ .name = "FlagStaticMember", .value = 0x200, .parameters = &.{} },
1480 .{ .name = "FlagIndirectVariable", .value = 0x400, .parameters = &.{} },
1481 .{ .name = "FlagLValueReference", .value = 0x800, .parameters = &.{} },
1482 .{ .name = "FlagRValueReference", .value = 0x1000, .parameters = &.{} },
1483 .{ .name = "FlagIsOptimized", .value = 0x2000, .parameters = &.{} },
1443 },1484 },
1444 .@"OpenCL.DebugInfo.100.DebugTypeQualifier" => &[_]Enumerant{1485 .debug_info_debug_base_type_attribute_encoding => &.{
1445 .{ .name = "ConstType", .value = 0, .parameters = &[_]OperandKind{} },1486 .{ .name = "Unspecified", .value = 0, .parameters = &.{} },
1446 .{ .name = "VolatileType", .value = 1, .parameters = &[_]OperandKind{} },1487 .{ .name = "Address", .value = 1, .parameters = &.{} },
1447 .{ .name = "RestrictType", .value = 2, .parameters = &[_]OperandKind{} },1488 .{ .name = "Boolean", .value = 2, .parameters = &.{} },
1448 .{ .name = "AtomicType", .value = 3, .parameters = &[_]OperandKind{} },1489 .{ .name = "Float", .value = 4, .parameters = &.{} },
1490 .{ .name = "Signed", .value = 5, .parameters = &.{} },
1491 .{ .name = "SignedChar", .value = 6, .parameters = &.{} },
1492 .{ .name = "Unsigned", .value = 7, .parameters = &.{} },
1493 .{ .name = "UnsignedChar", .value = 8, .parameters = &.{} },
1449 },1494 },
1450 .@"OpenCL.DebugInfo.100.DebugOperation" => &[_]Enumerant{1495 .debug_info_debug_composite_type => &.{
1451 .{ .name = "Deref", .value = 0, .parameters = &[_]OperandKind{} },1496 .{ .name = "Class", .value = 0, .parameters = &.{} },
1452 .{ .name = "Plus", .value = 1, .parameters = &[_]OperandKind{} },1497 .{ .name = "Structure", .value = 1, .parameters = &.{} },
1453 .{ .name = "Minus", .value = 2, .parameters = &[_]OperandKind{} },1498 .{ .name = "Union", .value = 2, .parameters = &.{} },
1454 .{ .name = "PlusUconst", .value = 3, .parameters = &[_]OperandKind{.LiteralInteger} },
1455 .{ .name = "BitPiece", .value = 4, .parameters = &[_]OperandKind{ .LiteralInteger, .LiteralInteger } },
1456 .{ .name = "Swap", .value = 5, .parameters = &[_]OperandKind{} },
1457 .{ .name = "Xderef", .value = 6, .parameters = &[_]OperandKind{} },
1458 .{ .name = "StackValue", .value = 7, .parameters = &[_]OperandKind{} },
1459 .{ .name = "Constu", .value = 8, .parameters = &[_]OperandKind{.LiteralInteger} },
1460 .{ .name = "Fragment", .value = 9, .parameters = &[_]OperandKind{ .LiteralInteger, .LiteralInteger } },
1461 },1499 },
1462 .@"OpenCL.DebugInfo.100.DebugImportedEntity" => &[_]Enumerant{1500 .debug_info_debug_type_qualifier => &.{
1463 .{ .name = "ImportedModule", .value = 0, .parameters = &[_]OperandKind{} },1501 .{ .name = "ConstType", .value = 0, .parameters = &.{} },
1464 .{ .name = "ImportedDeclaration", .value = 1, .parameters = &[_]OperandKind{} },1502 .{ .name = "VolatileType", .value = 1, .parameters = &.{} },
1503 .{ .name = "RestrictType", .value = 2, .parameters = &.{} },
1465 },1504 },
1466 .@"NonSemantic.Shader.DebugInfo.100.DebugInfoFlags" => &[_]Enumerant{1505 .debug_info_debug_operation => &.{
1467 .{ .name = "FlagIsProtected", .value = 0x01, .parameters = &[_]OperandKind{} },1506 .{ .name = "Deref", .value = 0, .parameters = &.{} },
1468 .{ .name = "FlagIsPrivate", .value = 0x02, .parameters = &[_]OperandKind{} },1507 .{ .name = "Plus", .value = 1, .parameters = &.{} },
1469 .{ .name = "FlagIsPublic", .value = 0x03, .parameters = &[_]OperandKind{} },1508 .{ .name = "Minus", .value = 2, .parameters = &.{} },
1470 .{ .name = "FlagIsLocal", .value = 0x04, .parameters = &[_]OperandKind{} },1509 .{ .name = "PlusUconst", .value = 3, .parameters = &.{.literal_integer} },
1471 .{ .name = "FlagIsDefinition", .value = 0x08, .parameters = &[_]OperandKind{} },1510 .{ .name = "BitPiece", .value = 4, .parameters = &.{ .literal_integer, .literal_integer } },
1472 .{ .name = "FlagFwdDecl", .value = 0x10, .parameters = &[_]OperandKind{} },1511 .{ .name = "Swap", .value = 5, .parameters = &.{} },
1473 .{ .name = "FlagArtificial", .value = 0x20, .parameters = &[_]OperandKind{} },1512 .{ .name = "Xderef", .value = 6, .parameters = &.{} },
1474 .{ .name = "FlagExplicit", .value = 0x40, .parameters = &[_]OperandKind{} },1513 .{ .name = "StackValue", .value = 7, .parameters = &.{} },
1475 .{ .name = "FlagPrototyped", .value = 0x80, .parameters = &[_]OperandKind{} },1514 .{ .name = "Constu", .value = 8, .parameters = &.{.literal_integer} },
1476 .{ .name = "FlagObjectPointer", .value = 0x100, .parameters = &[_]OperandKind{} },
1477 .{ .name = "FlagStaticMember", .value = 0x200, .parameters = &[_]OperandKind{} },
1478 .{ .name = "FlagIndirectVariable", .value = 0x400, .parameters = &[_]OperandKind{} },
1479 .{ .name = "FlagLValueReference", .value = 0x800, .parameters = &[_]OperandKind{} },
1480 .{ .name = "FlagRValueReference", .value = 0x1000, .parameters = &[_]OperandKind{} },
1481 .{ .name = "FlagIsOptimized", .value = 0x2000, .parameters = &[_]OperandKind{} },
1482 .{ .name = "FlagIsEnumClass", .value = 0x4000, .parameters = &[_]OperandKind{} },
1483 .{ .name = "FlagTypePassByValue", .value = 0x8000, .parameters = &[_]OperandKind{} },
1484 .{ .name = "FlagTypePassByReference", .value = 0x10000, .parameters = &[_]OperandKind{} },
1485 .{ .name = "FlagUnknownPhysicalLayout", .value = 0x20000, .parameters = &[_]OperandKind{} },
1486 },1515 },
1487 .@"NonSemantic.Shader.DebugInfo.100.BuildIdentifierFlags" => &[_]Enumerant{1516 .open_cl_debug_info_100_debug_info_flags => &.{
1488 .{ .name = "IdentifierPossibleDuplicates", .value = 0x01, .parameters = &[_]OperandKind{} },1517 .{ .name = "FlagIsProtected", .value = 0x01, .parameters = &.{} },
1518 .{ .name = "FlagIsPrivate", .value = 0x02, .parameters = &.{} },
1519 .{ .name = "FlagIsPublic", .value = 0x03, .parameters = &.{} },
1520 .{ .name = "FlagIsLocal", .value = 0x04, .parameters = &.{} },
1521 .{ .name = "FlagIsDefinition", .value = 0x08, .parameters = &.{} },
1522 .{ .name = "FlagFwdDecl", .value = 0x10, .parameters = &.{} },
1523 .{ .name = "FlagArtificial", .value = 0x20, .parameters = &.{} },
1524 .{ .name = "FlagExplicit", .value = 0x40, .parameters = &.{} },
1525 .{ .name = "FlagPrototyped", .value = 0x80, .parameters = &.{} },
1526 .{ .name = "FlagObjectPointer", .value = 0x100, .parameters = &.{} },
1527 .{ .name = "FlagStaticMember", .value = 0x200, .parameters = &.{} },
1528 .{ .name = "FlagIndirectVariable", .value = 0x400, .parameters = &.{} },
1529 .{ .name = "FlagLValueReference", .value = 0x800, .parameters = &.{} },
1530 .{ .name = "FlagRValueReference", .value = 0x1000, .parameters = &.{} },
1531 .{ .name = "FlagIsOptimized", .value = 0x2000, .parameters = &.{} },
1532 .{ .name = "FlagIsEnumClass", .value = 0x4000, .parameters = &.{} },
1533 .{ .name = "FlagTypePassByValue", .value = 0x8000, .parameters = &.{} },
1534 .{ .name = "FlagTypePassByReference", .value = 0x10000, .parameters = &.{} },
1489 },1535 },
1490 .@"NonSemantic.Shader.DebugInfo.100.DebugBaseTypeAttributeEncoding" => &[_]Enumerant{1536 .open_cl_debug_info_100_debug_base_type_attribute_encoding => &.{
1491 .{ .name = "Unspecified", .value = 0, .parameters = &[_]OperandKind{} },1537 .{ .name = "Unspecified", .value = 0, .parameters = &.{} },
1492 .{ .name = "Address", .value = 1, .parameters = &[_]OperandKind{} },1538 .{ .name = "Address", .value = 1, .parameters = &.{} },
1493 .{ .name = "Boolean", .value = 2, .parameters = &[_]OperandKind{} },1539 .{ .name = "Boolean", .value = 2, .parameters = &.{} },
1494 .{ .name = "Float", .value = 3, .parameters = &[_]OperandKind{} },1540 .{ .name = "Float", .value = 3, .parameters = &.{} },
1495 .{ .name = "Signed", .value = 4, .parameters = &[_]OperandKind{} },1541 .{ .name = "Signed", .value = 4, .parameters = &.{} },
1496 .{ .name = "SignedChar", .value = 5, .parameters = &[_]OperandKind{} },1542 .{ .name = "SignedChar", .value = 5, .parameters = &.{} },
1497 .{ .name = "Unsigned", .value = 6, .parameters = &[_]OperandKind{} },1543 .{ .name = "Unsigned", .value = 6, .parameters = &.{} },
1498 .{ .name = "UnsignedChar", .value = 7, .parameters = &[_]OperandKind{} },1544 .{ .name = "UnsignedChar", .value = 7, .parameters = &.{} },
1499 },1545 },
1500 .@"NonSemantic.Shader.DebugInfo.100.DebugCompositeType" => &[_]Enumerant{1546 .open_cl_debug_info_100_debug_composite_type => &.{
1501 .{ .name = "Class", .value = 0, .parameters = &[_]OperandKind{} },1547 .{ .name = "Class", .value = 0, .parameters = &.{} },
1502 .{ .name = "Structure", .value = 1, .parameters = &[_]OperandKind{} },1548 .{ .name = "Structure", .value = 1, .parameters = &.{} },
1503 .{ .name = "Union", .value = 2, .parameters = &[_]OperandKind{} },1549 .{ .name = "Union", .value = 2, .parameters = &.{} },
1504 },1550 },
1505 .@"NonSemantic.Shader.DebugInfo.100.DebugTypeQualifier" => &[_]Enumerant{1551 .open_cl_debug_info_100_debug_type_qualifier => &.{
1506 .{ .name = "ConstType", .value = 0, .parameters = &[_]OperandKind{} },1552 .{ .name = "ConstType", .value = 0, .parameters = &.{} },
1507 .{ .name = "VolatileType", .value = 1, .parameters = &[_]OperandKind{} },1553 .{ .name = "VolatileType", .value = 1, .parameters = &.{} },
1508 .{ .name = "RestrictType", .value = 2, .parameters = &[_]OperandKind{} },1554 .{ .name = "RestrictType", .value = 2, .parameters = &.{} },
1509 .{ .name = "AtomicType", .value = 3, .parameters = &[_]OperandKind{} },1555 .{ .name = "AtomicType", .value = 3, .parameters = &.{} },
1510 },1556 },
1511 .@"NonSemantic.Shader.DebugInfo.100.DebugOperation" => &[_]Enumerant{1557 .open_cl_debug_info_100_debug_operation => &.{
1512 .{ .name = "Deref", .value = 0, .parameters = &[_]OperandKind{} },1558 .{ .name = "Deref", .value = 0, .parameters = &.{} },
1513 .{ .name = "Plus", .value = 1, .parameters = &[_]OperandKind{} },1559 .{ .name = "Plus", .value = 1, .parameters = &.{} },
1514 .{ .name = "Minus", .value = 2, .parameters = &[_]OperandKind{} },1560 .{ .name = "Minus", .value = 2, .parameters = &.{} },
1515 .{ .name = "PlusUconst", .value = 3, .parameters = &[_]OperandKind{.IdRef} },1561 .{ .name = "PlusUconst", .value = 3, .parameters = &.{.literal_integer} },
1516 .{ .name = "BitPiece", .value = 4, .parameters = &[_]OperandKind{ .IdRef, .IdRef } },1562 .{ .name = "BitPiece", .value = 4, .parameters = &.{ .literal_integer, .literal_integer } },
1517 .{ .name = "Swap", .value = 5, .parameters = &[_]OperandKind{} },1563 .{ .name = "Swap", .value = 5, .parameters = &.{} },
1518 .{ .name = "Xderef", .value = 6, .parameters = &[_]OperandKind{} },1564 .{ .name = "Xderef", .value = 6, .parameters = &.{} },
1519 .{ .name = "StackValue", .value = 7, .parameters = &[_]OperandKind{} },1565 .{ .name = "StackValue", .value = 7, .parameters = &.{} },
1520 .{ .name = "Constu", .value = 8, .parameters = &[_]OperandKind{.IdRef} },1566 .{ .name = "Constu", .value = 8, .parameters = &.{.literal_integer} },
1521 .{ .name = "Fragment", .value = 9, .parameters = &[_]OperandKind{ .IdRef, .IdRef } },1567 .{ .name = "Fragment", .value = 9, .parameters = &.{ .literal_integer, .literal_integer } },
1522 },1568 },
1523 .@"NonSemantic.Shader.DebugInfo.100.DebugImportedEntity" => &[_]Enumerant{1569 .open_cl_debug_info_100_debug_imported_entity => &.{
1524 .{ .name = "ImportedModule", .value = 0, .parameters = &[_]OperandKind{} },1570 .{ .name = "ImportedModule", .value = 0, .parameters = &.{} },
1525 .{ .name = "ImportedDeclaration", .value = 1, .parameters = &[_]OperandKind{} },1571 .{ .name = "ImportedDeclaration", .value = 1, .parameters = &.{} },
1526 },1572 },
1527 .@"NonSemantic.ClspvReflection.6.KernelPropertyFlags" => &[_]Enumerant{1573 .non_semantic_clspv_reflection_6_kernel_property_flags => &.{
1528 .{ .name = "MayUsePrintf", .value = 0x1, .parameters = &[_]OperandKind{} },1574 .{ .name = "MayUsePrintf", .value = 0x1, .parameters = &.{} },
1529 },1575 },
1530 .@"DebugInfo.DebugInfoFlags" => &[_]Enumerant{1576 .non_semantic_shader_debug_info_100_debug_info_flags => &.{
1531 .{ .name = "FlagIsProtected", .value = 0x01, .parameters = &[_]OperandKind{} },1577 .{ .name = "FlagIsProtected", .value = 0x01, .parameters = &.{} },
1532 .{ .name = "FlagIsPrivate", .value = 0x02, .parameters = &[_]OperandKind{} },1578 .{ .name = "FlagIsPrivate", .value = 0x02, .parameters = &.{} },
1533 .{ .name = "FlagIsPublic", .value = 0x03, .parameters = &[_]OperandKind{} },1579 .{ .name = "FlagIsPublic", .value = 0x03, .parameters = &.{} },
1534 .{ .name = "FlagIsLocal", .value = 0x04, .parameters = &[_]OperandKind{} },1580 .{ .name = "FlagIsLocal", .value = 0x04, .parameters = &.{} },
1535 .{ .name = "FlagIsDefinition", .value = 0x08, .parameters = &[_]OperandKind{} },1581 .{ .name = "FlagIsDefinition", .value = 0x08, .parameters = &.{} },
1536 .{ .name = "FlagFwdDecl", .value = 0x10, .parameters = &[_]OperandKind{} },1582 .{ .name = "FlagFwdDecl", .value = 0x10, .parameters = &.{} },
1537 .{ .name = "FlagArtificial", .value = 0x20, .parameters = &[_]OperandKind{} },1583 .{ .name = "FlagArtificial", .value = 0x20, .parameters = &.{} },
1538 .{ .name = "FlagExplicit", .value = 0x40, .parameters = &[_]OperandKind{} },1584 .{ .name = "FlagExplicit", .value = 0x40, .parameters = &.{} },
1539 .{ .name = "FlagPrototyped", .value = 0x80, .parameters = &[_]OperandKind{} },1585 .{ .name = "FlagPrototyped", .value = 0x80, .parameters = &.{} },
1540 .{ .name = "FlagObjectPointer", .value = 0x100, .parameters = &[_]OperandKind{} },1586 .{ .name = "FlagObjectPointer", .value = 0x100, .parameters = &.{} },
1541 .{ .name = "FlagStaticMember", .value = 0x200, .parameters = &[_]OperandKind{} },1587 .{ .name = "FlagStaticMember", .value = 0x200, .parameters = &.{} },
1542 .{ .name = "FlagIndirectVariable", .value = 0x400, .parameters = &[_]OperandKind{} },1588 .{ .name = "FlagIndirectVariable", .value = 0x400, .parameters = &.{} },
1543 .{ .name = "FlagLValueReference", .value = 0x800, .parameters = &[_]OperandKind{} },1589 .{ .name = "FlagLValueReference", .value = 0x800, .parameters = &.{} },
1544 .{ .name = "FlagRValueReference", .value = 0x1000, .parameters = &[_]OperandKind{} },1590 .{ .name = "FlagRValueReference", .value = 0x1000, .parameters = &.{} },
1545 .{ .name = "FlagIsOptimized", .value = 0x2000, .parameters = &[_]OperandKind{} },1591 .{ .name = "FlagIsOptimized", .value = 0x2000, .parameters = &.{} },
1592 .{ .name = "FlagIsEnumClass", .value = 0x4000, .parameters = &.{} },
1593 .{ .name = "FlagTypePassByValue", .value = 0x8000, .parameters = &.{} },
1594 .{ .name = "FlagTypePassByReference", .value = 0x10000, .parameters = &.{} },
1595 .{ .name = "FlagUnknownPhysicalLayout", .value = 0x20000, .parameters = &.{} },
1546 },1596 },
1547 .@"DebugInfo.DebugBaseTypeAttributeEncoding" => &[_]Enumerant{1597 .non_semantic_shader_debug_info_100_build_identifier_flags => &.{
1548 .{ .name = "Unspecified", .value = 0, .parameters = &[_]OperandKind{} },1598 .{ .name = "IdentifierPossibleDuplicates", .value = 0x01, .parameters = &.{} },
1549 .{ .name = "Address", .value = 1, .parameters = &[_]OperandKind{} },
1550 .{ .name = "Boolean", .value = 2, .parameters = &[_]OperandKind{} },
1551 .{ .name = "Float", .value = 4, .parameters = &[_]OperandKind{} },
1552 .{ .name = "Signed", .value = 5, .parameters = &[_]OperandKind{} },
1553 .{ .name = "SignedChar", .value = 6, .parameters = &[_]OperandKind{} },
1554 .{ .name = "Unsigned", .value = 7, .parameters = &[_]OperandKind{} },
1555 .{ .name = "UnsignedChar", .value = 8, .parameters = &[_]OperandKind{} },
1556 },1599 },
1557 .@"DebugInfo.DebugCompositeType" => &[_]Enumerant{1600 .non_semantic_shader_debug_info_100_debug_base_type_attribute_encoding => &.{
1558 .{ .name = "Class", .value = 0, .parameters = &[_]OperandKind{} },1601 .{ .name = "Unspecified", .value = 0, .parameters = &.{} },
1559 .{ .name = "Structure", .value = 1, .parameters = &[_]OperandKind{} },1602 .{ .name = "Address", .value = 1, .parameters = &.{} },
1560 .{ .name = "Union", .value = 2, .parameters = &[_]OperandKind{} },1603 .{ .name = "Boolean", .value = 2, .parameters = &.{} },
1604 .{ .name = "Float", .value = 3, .parameters = &.{} },
1605 .{ .name = "Signed", .value = 4, .parameters = &.{} },
1606 .{ .name = "SignedChar", .value = 5, .parameters = &.{} },
1607 .{ .name = "Unsigned", .value = 6, .parameters = &.{} },
1608 .{ .name = "UnsignedChar", .value = 7, .parameters = &.{} },
1561 },1609 },
1562 .@"DebugInfo.DebugTypeQualifier" => &[_]Enumerant{1610 .non_semantic_shader_debug_info_100_debug_composite_type => &.{
1563 .{ .name = "ConstType", .value = 0, .parameters = &[_]OperandKind{} },1611 .{ .name = "Class", .value = 0, .parameters = &.{} },
1564 .{ .name = "VolatileType", .value = 1, .parameters = &[_]OperandKind{} },1612 .{ .name = "Structure", .value = 1, .parameters = &.{} },
1565 .{ .name = "RestrictType", .value = 2, .parameters = &[_]OperandKind{} },1613 .{ .name = "Union", .value = 2, .parameters = &.{} },
1566 },1614 },
1567 .@"DebugInfo.DebugOperation" => &[_]Enumerant{1615 .non_semantic_shader_debug_info_100_debug_type_qualifier => &.{
1568 .{ .name = "Deref", .value = 0, .parameters = &[_]OperandKind{} },1616 .{ .name = "ConstType", .value = 0, .parameters = &.{} },
1569 .{ .name = "Plus", .value = 1, .parameters = &[_]OperandKind{} },1617 .{ .name = "VolatileType", .value = 1, .parameters = &.{} },
1570 .{ .name = "Minus", .value = 2, .parameters = &[_]OperandKind{} },1618 .{ .name = "RestrictType", .value = 2, .parameters = &.{} },
1571 .{ .name = "PlusUconst", .value = 3, .parameters = &[_]OperandKind{.LiteralInteger} },1619 .{ .name = "AtomicType", .value = 3, .parameters = &.{} },
1572 .{ .name = "BitPiece", .value = 4, .parameters = &[_]OperandKind{ .LiteralInteger, .LiteralInteger } },1620 },
1573 .{ .name = "Swap", .value = 5, .parameters = &[_]OperandKind{} },1621 .non_semantic_shader_debug_info_100_debug_operation => &.{
1574 .{ .name = "Xderef", .value = 6, .parameters = &[_]OperandKind{} },1622 .{ .name = "Deref", .value = 0, .parameters = &.{} },
1575 .{ .name = "StackValue", .value = 7, .parameters = &[_]OperandKind{} },1623 .{ .name = "Plus", .value = 1, .parameters = &.{} },
1576 .{ .name = "Constu", .value = 8, .parameters = &[_]OperandKind{.LiteralInteger} },1624 .{ .name = "Minus", .value = 2, .parameters = &.{} },
1625 .{ .name = "PlusUconst", .value = 3, .parameters = &.{.id_ref} },
1626 .{ .name = "BitPiece", .value = 4, .parameters = &.{ .id_ref, .id_ref } },
1627 .{ .name = "Swap", .value = 5, .parameters = &.{} },
1628 .{ .name = "Xderef", .value = 6, .parameters = &.{} },
1629 .{ .name = "StackValue", .value = 7, .parameters = &.{} },
1630 .{ .name = "Constu", .value = 8, .parameters = &.{.id_ref} },
1631 .{ .name = "Fragment", .value = 9, .parameters = &.{ .id_ref, .id_ref } },
1632 },
1633 .non_semantic_shader_debug_info_100_debug_imported_entity => &.{
1634 .{ .name = "ImportedModule", .value = 0, .parameters = &.{} },
1635 .{ .name = "ImportedDeclaration", .value = 1, .parameters = &.{} },
1577 },1636 },
1578 };1637 };
1579 }1638 }
...@@ -1926,14 +1985,34 @@ pub const Opcode = enum(u16) {...@@ -1926,14 +1985,34 @@ pub const Opcode = enum(u16) {
1926 OpColorAttachmentReadEXT = 4160,1985 OpColorAttachmentReadEXT = 4160,
1927 OpDepthAttachmentReadEXT = 4161,1986 OpDepthAttachmentReadEXT = 4161,
1928 OpStencilAttachmentReadEXT = 4162,1987 OpStencilAttachmentReadEXT = 4162,
1988 OpTypeTensorARM = 4163,
1989 OpTensorReadARM = 4164,
1990 OpTensorWriteARM = 4165,
1991 OpTensorQuerySizeARM = 4166,
1992 OpGraphConstantARM = 4181,
1993 OpGraphEntryPointARM = 4182,
1994 OpGraphARM = 4183,
1995 OpGraphInputARM = 4184,
1996 OpGraphSetOutputARM = 4185,
1997 OpGraphEndARM = 4186,
1998 OpTypeGraphARM = 4190,
1929 OpTerminateInvocation = 4416,1999 OpTerminateInvocation = 4416,
2000 OpTypeUntypedPointerKHR = 4417,
2001 OpUntypedVariableKHR = 4418,
2002 OpUntypedAccessChainKHR = 4419,
2003 OpUntypedInBoundsAccessChainKHR = 4420,
1930 OpSubgroupBallotKHR = 4421,2004 OpSubgroupBallotKHR = 4421,
1931 OpSubgroupFirstInvocationKHR = 4422,2005 OpSubgroupFirstInvocationKHR = 4422,
2006 OpUntypedPtrAccessChainKHR = 4423,
2007 OpUntypedInBoundsPtrAccessChainKHR = 4424,
2008 OpUntypedArrayLengthKHR = 4425,
2009 OpUntypedPrefetchKHR = 4426,
1932 OpSubgroupAllKHR = 4428,2010 OpSubgroupAllKHR = 4428,
1933 OpSubgroupAnyKHR = 4429,2011 OpSubgroupAnyKHR = 4429,
1934 OpSubgroupAllEqualKHR = 4430,2012 OpSubgroupAllEqualKHR = 4430,
1935 OpGroupNonUniformRotateKHR = 4431,2013 OpGroupNonUniformRotateKHR = 4431,
1936 OpSubgroupReadInvocationKHR = 4432,2014 OpSubgroupReadInvocationKHR = 4432,
2015 OpExtInstWithForwardRefsKHR = 4433,
1937 OpTraceRayKHR = 4445,2016 OpTraceRayKHR = 4445,
1938 OpExecuteCallableKHR = 4446,2017 OpExecuteCallableKHR = 4446,
1939 OpConvertUToAccelerationStructureKHR = 4447,2018 OpConvertUToAccelerationStructureKHR = 4447,
...@@ -1950,6 +2029,9 @@ pub const Opcode = enum(u16) {...@@ -1950,6 +2029,9 @@ pub const Opcode = enum(u16) {
1950 OpCooperativeMatrixStoreKHR = 4458,2029 OpCooperativeMatrixStoreKHR = 4458,
1951 OpCooperativeMatrixMulAddKHR = 4459,2030 OpCooperativeMatrixMulAddKHR = 4459,
1952 OpCooperativeMatrixLengthKHR = 4460,2031 OpCooperativeMatrixLengthKHR = 4460,
2032 OpConstantCompositeReplicateEXT = 4461,
2033 OpSpecConstantCompositeReplicateEXT = 4462,
2034 OpCompositeConstructReplicateEXT = 4463,
1953 OpTypeRayQueryKHR = 4472,2035 OpTypeRayQueryKHR = 4472,
1954 OpRayQueryInitializeKHR = 4473,2036 OpRayQueryInitializeKHR = 4473,
1955 OpRayQueryTerminateKHR = 4474,2037 OpRayQueryTerminateKHR = 4474,
...@@ -1976,9 +2058,14 @@ pub const Opcode = enum(u16) {...@@ -1976,9 +2058,14 @@ pub const Opcode = enum(u16) {
1976 OpFragmentMaskFetchAMD = 5011,2058 OpFragmentMaskFetchAMD = 5011,
1977 OpFragmentFetchAMD = 5012,2059 OpFragmentFetchAMD = 5012,
1978 OpReadClockKHR = 5056,2060 OpReadClockKHR = 5056,
1979 OpFinalizeNodePayloadsAMDX = 5075,2061 OpAllocateNodePayloadsAMDX = 5074,
2062 OpEnqueueNodePayloadsAMDX = 5075,
2063 OpTypeNodePayloadArrayAMDX = 5076,
1980 OpFinishWritingNodePayloadAMDX = 5078,2064 OpFinishWritingNodePayloadAMDX = 5078,
1981 OpInitializeNodePayloadsAMDX = 5090,2065 OpNodePayloadArrayLengthAMDX = 5090,
2066 OpIsNodePayloadValidAMDX = 5101,
2067 OpConstantStringAMDX = 5103,
2068 OpSpecConstantStringAMDX = 5104,
1982 OpGroupNonUniformQuadAllKHR = 5110,2069 OpGroupNonUniformQuadAllKHR = 5110,
1983 OpGroupNonUniformQuadAnyKHR = 5111,2070 OpGroupNonUniformQuadAnyKHR = 5111,
1984 OpHitObjectRecordHitMotionNV = 5249,2071 OpHitObjectRecordHitMotionNV = 5249,
...@@ -2015,12 +2102,20 @@ pub const Opcode = enum(u16) {...@@ -2015,12 +2102,20 @@ pub const Opcode = enum(u16) {
2015 OpReorderThreadWithHintNV = 5280,2102 OpReorderThreadWithHintNV = 5280,
2016 OpTypeHitObjectNV = 5281,2103 OpTypeHitObjectNV = 5281,
2017 OpImageSampleFootprintNV = 5283,2104 OpImageSampleFootprintNV = 5283,
2105 OpTypeCooperativeVectorNV = 5288,
2106 OpCooperativeVectorMatrixMulNV = 5289,
2107 OpCooperativeVectorOuterProductAccumulateNV = 5290,
2108 OpCooperativeVectorReduceSumAccumulateNV = 5291,
2109 OpCooperativeVectorMatrixMulAddNV = 5292,
2110 OpCooperativeMatrixConvertNV = 5293,
2018 OpEmitMeshTasksEXT = 5294,2111 OpEmitMeshTasksEXT = 5294,
2019 OpSetMeshOutputsEXT = 5295,2112 OpSetMeshOutputsEXT = 5295,
2020 OpGroupNonUniformPartitionNV = 5296,2113 OpGroupNonUniformPartitionNV = 5296,
2021 OpWritePackedPrimitiveIndices4x8NV = 5299,2114 OpWritePackedPrimitiveIndices4x8NV = 5299,
2022 OpFetchMicroTriangleVertexPositionNV = 5300,2115 OpFetchMicroTriangleVertexPositionNV = 5300,
2023 OpFetchMicroTriangleVertexBarycentricNV = 5301,2116 OpFetchMicroTriangleVertexBarycentricNV = 5301,
2117 OpCooperativeVectorLoadNV = 5302,
2118 OpCooperativeVectorStoreNV = 5303,
2024 OpReportIntersectionKHR = 5334,2119 OpReportIntersectionKHR = 5334,
2025 OpIgnoreIntersectionNV = 5335,2120 OpIgnoreIntersectionNV = 5335,
2026 OpTerminateRayNV = 5336,2121 OpTerminateRayNV = 5336,
...@@ -2030,6 +2125,8 @@ pub const Opcode = enum(u16) {...@@ -2030,6 +2125,8 @@ pub const Opcode = enum(u16) {
2030 OpRayQueryGetIntersectionTriangleVertexPositionsKHR = 5340,2125 OpRayQueryGetIntersectionTriangleVertexPositionsKHR = 5340,
2031 OpTypeAccelerationStructureKHR = 5341,2126 OpTypeAccelerationStructureKHR = 5341,
2032 OpExecuteCallableNV = 5344,2127 OpExecuteCallableNV = 5344,
2128 OpRayQueryGetClusterIdNV = 5345,
2129 OpHitObjectGetClusterIdNV = 5346,
2033 OpTypeCooperativeMatrixNV = 5358,2130 OpTypeCooperativeMatrixNV = 5358,
2034 OpCooperativeMatrixLoadNV = 5359,2131 OpCooperativeMatrixLoadNV = 5359,
2035 OpCooperativeMatrixStoreNV = 5360,2132 OpCooperativeMatrixStoreNV = 5360,
...@@ -2037,8 +2134,25 @@ pub const Opcode = enum(u16) {...@@ -2037,8 +2134,25 @@ pub const Opcode = enum(u16) {
2037 OpCooperativeMatrixLengthNV = 5362,2134 OpCooperativeMatrixLengthNV = 5362,
2038 OpBeginInvocationInterlockEXT = 5364,2135 OpBeginInvocationInterlockEXT = 5364,
2039 OpEndInvocationInterlockEXT = 5365,2136 OpEndInvocationInterlockEXT = 5365,
2137 OpCooperativeMatrixReduceNV = 5366,
2138 OpCooperativeMatrixLoadTensorNV = 5367,
2139 OpCooperativeMatrixStoreTensorNV = 5368,
2140 OpCooperativeMatrixPerElementOpNV = 5369,
2141 OpTypeTensorLayoutNV = 5370,
2142 OpTypeTensorViewNV = 5371,
2143 OpCreateTensorLayoutNV = 5372,
2144 OpTensorLayoutSetDimensionNV = 5373,
2145 OpTensorLayoutSetStrideNV = 5374,
2146 OpTensorLayoutSliceNV = 5375,
2147 OpTensorLayoutSetClampValueNV = 5376,
2148 OpCreateTensorViewNV = 5377,
2149 OpTensorViewSetDimensionNV = 5378,
2150 OpTensorViewSetStrideNV = 5379,
2040 OpDemoteToHelperInvocation = 5380,2151 OpDemoteToHelperInvocation = 5380,
2041 OpIsHelperInvocationEXT = 5381,2152 OpIsHelperInvocationEXT = 5381,
2153 OpTensorViewSetClipNV = 5382,
2154 OpTensorLayoutSetBlockSizeNV = 5384,
2155 OpCooperativeMatrixTransposeNV = 5390,
2042 OpConvertUToImageNV = 5391,2156 OpConvertUToImageNV = 5391,
2043 OpConvertUToSamplerNV = 5392,2157 OpConvertUToSamplerNV = 5392,
2044 OpConvertImageToUNV = 5393,2158 OpConvertImageToUNV = 5393,
...@@ -2047,6 +2161,19 @@ pub const Opcode = enum(u16) {...@@ -2047,6 +2161,19 @@ pub const Opcode = enum(u16) {
2047 OpConvertSampledImageToUNV = 5396,2161 OpConvertSampledImageToUNV = 5396,
2048 OpSamplerImageAddressingModeNV = 5397,2162 OpSamplerImageAddressingModeNV = 5397,
2049 OpRawAccessChainNV = 5398,2163 OpRawAccessChainNV = 5398,
2164 OpRayQueryGetIntersectionSpherePositionNV = 5427,
2165 OpRayQueryGetIntersectionSphereRadiusNV = 5428,
2166 OpRayQueryGetIntersectionLSSPositionsNV = 5429,
2167 OpRayQueryGetIntersectionLSSRadiiNV = 5430,
2168 OpRayQueryGetIntersectionLSSHitValueNV = 5431,
2169 OpHitObjectGetSpherePositionNV = 5432,
2170 OpHitObjectGetSphereRadiusNV = 5433,
2171 OpHitObjectGetLSSPositionsNV = 5434,
2172 OpHitObjectGetLSSRadiiNV = 5435,
2173 OpHitObjectIsSphereHitNV = 5436,
2174 OpHitObjectIsLSSHitNV = 5437,
2175 OpRayQueryIsSphereHitNV = 5438,
2176 OpRayQueryIsLSSHitNV = 5439,
2050 OpSubgroupShuffleINTEL = 5571,2177 OpSubgroupShuffleINTEL = 5571,
2051 OpSubgroupShuffleDownINTEL = 5572,2178 OpSubgroupShuffleDownINTEL = 5572,
2052 OpSubgroupShuffleUpINTEL = 5573,2179 OpSubgroupShuffleUpINTEL = 5573,
...@@ -2108,6 +2235,20 @@ pub const Opcode = enum(u16) {...@@ -2108,6 +2235,20 @@ pub const Opcode = enum(u16) {
2108 OpConvertBF16ToFINTEL = 6117,2235 OpConvertBF16ToFINTEL = 6117,
2109 OpControlBarrierArriveINTEL = 6142,2236 OpControlBarrierArriveINTEL = 6142,
2110 OpControlBarrierWaitINTEL = 6143,2237 OpControlBarrierWaitINTEL = 6143,
2238 OpArithmeticFenceEXT = 6145,
2239 OpTaskSequenceCreateINTEL = 6163,
2240 OpTaskSequenceAsyncINTEL = 6164,
2241 OpTaskSequenceGetINTEL = 6165,
2242 OpTaskSequenceReleaseINTEL = 6166,
2243 OpTypeTaskSequenceINTEL = 6199,
2244 OpSubgroupBlockPrefetchINTEL = 6221,
2245 OpSubgroup2DBlockLoadINTEL = 6231,
2246 OpSubgroup2DBlockLoadTransformINTEL = 6232,
2247 OpSubgroup2DBlockLoadTransposeINTEL = 6233,
2248 OpSubgroup2DBlockPrefetchINTEL = 6234,
2249 OpSubgroup2DBlockStoreINTEL = 6235,
2250 OpSubgroupMatrixMultiplyAccumulateINTEL = 6237,
2251 OpBitwiseFunctionINTEL = 6242,
2111 OpGroupIMulKHR = 6401,2252 OpGroupIMulKHR = 6401,
2112 OpGroupFMulKHR = 6402,2253 OpGroupFMulKHR = 6402,
2113 OpGroupBitwiseAndKHR = 6403,2254 OpGroupBitwiseAndKHR = 6403,
...@@ -2116,1125 +2257,1290 @@ pub const Opcode = enum(u16) {...@@ -2116,1125 +2257,1290 @@ pub const Opcode = enum(u16) {
2116 OpGroupLogicalAndKHR = 6406,2257 OpGroupLogicalAndKHR = 6406,
2117 OpGroupLogicalOrKHR = 6407,2258 OpGroupLogicalOrKHR = 6407,
2118 OpGroupLogicalXorKHR = 6408,2259 OpGroupLogicalXorKHR = 6408,
2260 OpRoundFToTF32INTEL = 6426,
2119 OpMaskedGatherINTEL = 6428,2261 OpMaskedGatherINTEL = 6428,
2120 OpMaskedScatterINTEL = 6429,2262 OpMaskedScatterINTEL = 6429,
2121 pub const OpSDotKHR = Opcode.OpSDot;2263 OpConvertHandleToImageINTEL = 6529,
2122 pub const OpUDotKHR = Opcode.OpUDot;2264 OpConvertHandleToSamplerINTEL = 6530,
2123 pub const OpSUDotKHR = Opcode.OpSUDot;2265 OpConvertHandleToSampledImageINTEL = 6531,
2124 pub const OpSDotAccSatKHR = Opcode.OpSDotAccSat;
2125 pub const OpUDotAccSatKHR = Opcode.OpUDotAccSat;
2126 pub const OpSUDotAccSatKHR = Opcode.OpSUDotAccSat;
2127 pub const OpReportIntersectionNV = Opcode.OpReportIntersectionKHR;
2128 pub const OpTypeAccelerationStructureNV = Opcode.OpTypeAccelerationStructureKHR;
2129 pub const OpDemoteToHelperInvocationEXT = Opcode.OpDemoteToHelperInvocation;
2130 pub const OpDecorateStringGOOGLE = Opcode.OpDecorateString;
2131 pub const OpMemberDecorateStringGOOGLE = Opcode.OpMemberDecorateString;
21322266
2133 pub fn Operands(comptime self: Opcode) type {2267 pub fn Operands(comptime self: Opcode) type {
2134 return switch (self) {2268 return switch (self) {
2135 .OpNop => void,2269 .OpNop => void,
2136 .OpUndef => struct { id_result_type: IdResultType, id_result: IdResult },2270 .OpUndef => struct { id_result_type: Id, id_result: Id },
2137 .OpSourceContinued => struct { continued_source: LiteralString },2271 .OpSourceContinued => struct { continued_source: LiteralString },
2138 .OpSource => struct { source_language: SourceLanguage, version: LiteralInteger, file: ?IdRef = null, source: ?LiteralString = null },2272 .OpSource => struct { source_language: SourceLanguage, version: LiteralInteger, file: ?Id = null, source: ?LiteralString = null },
2139 .OpSourceExtension => struct { extension: LiteralString },2273 .OpSourceExtension => struct { extension: LiteralString },
2140 .OpName => struct { target: IdRef, name: LiteralString },2274 .OpName => struct { target: Id, name: LiteralString },
2141 .OpMemberName => struct { type: IdRef, member: LiteralInteger, name: LiteralString },2275 .OpMemberName => struct { type: Id, member: LiteralInteger, name: LiteralString },
2142 .OpString => struct { id_result: IdResult, string: LiteralString },2276 .OpString => struct { id_result: Id, string: LiteralString },
2143 .OpLine => struct { file: IdRef, line: LiteralInteger, column: LiteralInteger },2277 .OpLine => struct { file: Id, line: LiteralInteger, column: LiteralInteger },
2144 .OpExtension => struct { name: LiteralString },2278 .OpExtension => struct { name: LiteralString },
2145 .OpExtInstImport => struct { id_result: IdResult, name: LiteralString },2279 .OpExtInstImport => struct { id_result: Id, name: LiteralString },
2146 .OpExtInst => struct { id_result_type: IdResultType, id_result: IdResult, set: IdRef, instruction: LiteralExtInstInteger, id_ref_4: []const IdRef = &.{} },2280 .OpExtInst => struct { id_result_type: Id, id_result: Id, set: Id, instruction: LiteralExtInstInteger, id_ref_4: []const Id = &.{} },
2147 .OpMemoryModel => struct { addressing_model: AddressingModel, memory_model: MemoryModel },2281 .OpMemoryModel => struct { addressing_model: AddressingModel, memory_model: MemoryModel },
2148 .OpEntryPoint => struct { execution_model: ExecutionModel, entry_point: IdRef, name: LiteralString, interface: []const IdRef = &.{} },2282 .OpEntryPoint => struct { execution_model: ExecutionModel, entry_point: Id, name: LiteralString, interface: []const Id = &.{} },
2149 .OpExecutionMode => struct { entry_point: IdRef, mode: ExecutionMode.Extended },2283 .OpExecutionMode => struct { entry_point: Id, mode: ExecutionMode.Extended },
2150 .OpCapability => struct { capability: Capability },2284 .OpCapability => struct { capability: Capability },
2151 .OpTypeVoid => struct { id_result: IdResult },2285 .OpTypeVoid => struct { id_result: Id },
2152 .OpTypeBool => struct { id_result: IdResult },2286 .OpTypeBool => struct { id_result: Id },
2153 .OpTypeInt => struct { id_result: IdResult, width: LiteralInteger, signedness: LiteralInteger },2287 .OpTypeInt => struct { id_result: Id, width: LiteralInteger, signedness: LiteralInteger },
2154 .OpTypeFloat => struct { id_result: IdResult, width: LiteralInteger },2288 .OpTypeFloat => struct { id_result: Id, width: LiteralInteger, floating_point_encoding: ?FPEncoding = null },
2155 .OpTypeVector => struct { id_result: IdResult, component_type: IdRef, component_count: LiteralInteger },2289 .OpTypeVector => struct { id_result: Id, component_type: Id, component_count: LiteralInteger },
2156 .OpTypeMatrix => struct { id_result: IdResult, column_type: IdRef, column_count: LiteralInteger },2290 .OpTypeMatrix => struct { id_result: Id, column_type: Id, column_count: LiteralInteger },
2157 .OpTypeImage => struct { id_result: IdResult, sampled_type: IdRef, dim: Dim, depth: LiteralInteger, arrayed: LiteralInteger, ms: LiteralInteger, sampled: LiteralInteger, image_format: ImageFormat, access_qualifier: ?AccessQualifier = null },2291 .OpTypeImage => struct { id_result: Id, sampled_type: Id, dim: Dim, depth: LiteralInteger, arrayed: LiteralInteger, ms: LiteralInteger, sampled: LiteralInteger, image_format: ImageFormat, access_qualifier: ?AccessQualifier = null },
2158 .OpTypeSampler => struct { id_result: IdResult },2292 .OpTypeSampler => struct { id_result: Id },
2159 .OpTypeSampledImage => struct { id_result: IdResult, image_type: IdRef },2293 .OpTypeSampledImage => struct { id_result: Id, image_type: Id },
2160 .OpTypeArray => struct { id_result: IdResult, element_type: IdRef, length: IdRef },2294 .OpTypeArray => struct { id_result: Id, element_type: Id, length: Id },
2161 .OpTypeRuntimeArray => struct { id_result: IdResult, element_type: IdRef },2295 .OpTypeRuntimeArray => struct { id_result: Id, element_type: Id },
2162 .OpTypeStruct => struct { id_result: IdResult, id_ref: []const IdRef = &.{} },2296 .OpTypeStruct => struct { id_result: Id, id_ref: []const Id = &.{} },
2163 .OpTypeOpaque => struct { id_result: IdResult, literal_string: LiteralString },2297 .OpTypeOpaque => struct { id_result: Id, literal_string: LiteralString },
2164 .OpTypePointer => struct { id_result: IdResult, storage_class: StorageClass, type: IdRef },2298 .OpTypePointer => struct { id_result: Id, storage_class: StorageClass, type: Id },
2165 .OpTypeFunction => struct { id_result: IdResult, return_type: IdRef, id_ref_2: []const IdRef = &.{} },2299 .OpTypeFunction => struct { id_result: Id, return_type: Id, id_ref_2: []const Id = &.{} },
2166 .OpTypeEvent => struct { id_result: IdResult },2300 .OpTypeEvent => struct { id_result: Id },
2167 .OpTypeDeviceEvent => struct { id_result: IdResult },2301 .OpTypeDeviceEvent => struct { id_result: Id },
2168 .OpTypeReserveId => struct { id_result: IdResult },2302 .OpTypeReserveId => struct { id_result: Id },
2169 .OpTypeQueue => struct { id_result: IdResult },2303 .OpTypeQueue => struct { id_result: Id },
2170 .OpTypePipe => struct { id_result: IdResult, qualifier: AccessQualifier },2304 .OpTypePipe => struct { id_result: Id, qualifier: AccessQualifier },
2171 .OpTypeForwardPointer => struct { pointer_type: IdRef, storage_class: StorageClass },2305 .OpTypeForwardPointer => struct { pointer_type: Id, storage_class: StorageClass },
2172 .OpConstantTrue => struct { id_result_type: IdResultType, id_result: IdResult },2306 .OpConstantTrue => struct { id_result_type: Id, id_result: Id },
2173 .OpConstantFalse => struct { id_result_type: IdResultType, id_result: IdResult },2307 .OpConstantFalse => struct { id_result_type: Id, id_result: Id },
2174 .OpConstant => struct { id_result_type: IdResultType, id_result: IdResult, value: LiteralContextDependentNumber },2308 .OpConstant => struct { id_result_type: Id, id_result: Id, value: LiteralContextDependentNumber },
2175 .OpConstantComposite => struct { id_result_type: IdResultType, id_result: IdResult, constituents: []const IdRef = &.{} },2309 .OpConstantComposite => struct { id_result_type: Id, id_result: Id, constituents: []const Id = &.{} },
2176 .OpConstantSampler => struct { id_result_type: IdResultType, id_result: IdResult, sampler_addressing_mode: SamplerAddressingMode, param: LiteralInteger, sampler_filter_mode: SamplerFilterMode },2310 .OpConstantSampler => struct { id_result_type: Id, id_result: Id, sampler_addressing_mode: SamplerAddressingMode, param: LiteralInteger, sampler_filter_mode: SamplerFilterMode },
2177 .OpConstantNull => struct { id_result_type: IdResultType, id_result: IdResult },2311 .OpConstantNull => struct { id_result_type: Id, id_result: Id },
2178 .OpSpecConstantTrue => struct { id_result_type: IdResultType, id_result: IdResult },2312 .OpSpecConstantTrue => struct { id_result_type: Id, id_result: Id },
2179 .OpSpecConstantFalse => struct { id_result_type: IdResultType, id_result: IdResult },2313 .OpSpecConstantFalse => struct { id_result_type: Id, id_result: Id },
2180 .OpSpecConstant => struct { id_result_type: IdResultType, id_result: IdResult, value: LiteralContextDependentNumber },2314 .OpSpecConstant => struct { id_result_type: Id, id_result: Id, value: LiteralContextDependentNumber },
2181 .OpSpecConstantComposite => struct { id_result_type: IdResultType, id_result: IdResult, constituents: []const IdRef = &.{} },2315 .OpSpecConstantComposite => struct { id_result_type: Id, id_result: Id, constituents: []const Id = &.{} },
2182 .OpSpecConstantOp => struct { id_result_type: IdResultType, id_result: IdResult, opcode: LiteralSpecConstantOpInteger },2316 .OpSpecConstantOp => struct { id_result_type: Id, id_result: Id, opcode: LiteralSpecConstantOpInteger },
2183 .OpFunction => struct { id_result_type: IdResultType, id_result: IdResult, function_control: FunctionControl, function_type: IdRef },2317 .OpFunction => struct { id_result_type: Id, id_result: Id, function_control: FunctionControl, function_type: Id },
2184 .OpFunctionParameter => struct { id_result_type: IdResultType, id_result: IdResult },2318 .OpFunctionParameter => struct { id_result_type: Id, id_result: Id },
2185 .OpFunctionEnd => void,2319 .OpFunctionEnd => void,
2186 .OpFunctionCall => struct { id_result_type: IdResultType, id_result: IdResult, function: IdRef, id_ref_3: []const IdRef = &.{} },2320 .OpFunctionCall => struct { id_result_type: Id, id_result: Id, function: Id, id_ref_3: []const Id = &.{} },
2187 .OpVariable => struct { id_result_type: IdResultType, id_result: IdResult, storage_class: StorageClass, initializer: ?IdRef = null },2321 .OpVariable => struct { id_result_type: Id, id_result: Id, storage_class: StorageClass, initializer: ?Id = null },
2188 .OpImageTexelPointer => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef, coordinate: IdRef, sample: IdRef },2322 .OpImageTexelPointer => struct { id_result_type: Id, id_result: Id, image: Id, coordinate: Id, sample: Id },
2189 .OpLoad => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory_access: ?MemoryAccess.Extended = null },2323 .OpLoad => struct { id_result_type: Id, id_result: Id, pointer: Id, memory_access: ?MemoryAccess.Extended = null },
2190 .OpStore => struct { pointer: IdRef, object: IdRef, memory_access: ?MemoryAccess.Extended = null },2324 .OpStore => struct { pointer: Id, object: Id, memory_access: ?MemoryAccess.Extended = null },
2191 .OpCopyMemory => struct { target: IdRef, source: IdRef, memory_access_2: ?MemoryAccess.Extended = null, memory_access_3: ?MemoryAccess.Extended = null },2325 .OpCopyMemory => struct { target: Id, source: Id, memory_access_2: ?MemoryAccess.Extended = null, memory_access_3: ?MemoryAccess.Extended = null },
2192 .OpCopyMemorySized => struct { target: IdRef, source: IdRef, size: IdRef, memory_access_3: ?MemoryAccess.Extended = null, memory_access_4: ?MemoryAccess.Extended = null },2326 .OpCopyMemorySized => struct { target: Id, source: Id, size: Id, memory_access_3: ?MemoryAccess.Extended = null, memory_access_4: ?MemoryAccess.Extended = null },
2193 .OpAccessChain => struct { id_result_type: IdResultType, id_result: IdResult, base: IdRef, indexes: []const IdRef = &.{} },2327 .OpAccessChain => struct { id_result_type: Id, id_result: Id, base: Id, indexes: []const Id = &.{} },
2194 .OpInBoundsAccessChain => struct { id_result_type: IdResultType, id_result: IdResult, base: IdRef, indexes: []const IdRef = &.{} },2328 .OpInBoundsAccessChain => struct { id_result_type: Id, id_result: Id, base: Id, indexes: []const Id = &.{} },
2195 .OpPtrAccessChain => struct { id_result_type: IdResultType, id_result: IdResult, base: IdRef, element: IdRef, indexes: []const IdRef = &.{} },2329 .OpPtrAccessChain => struct { id_result_type: Id, id_result: Id, base: Id, element: Id, indexes: []const Id = &.{} },
2196 .OpArrayLength => struct { id_result_type: IdResultType, id_result: IdResult, structure: IdRef, array_member: LiteralInteger },2330 .OpArrayLength => struct { id_result_type: Id, id_result: Id, structure: Id, array_member: LiteralInteger },
2197 .OpGenericPtrMemSemantics => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef },2331 .OpGenericPtrMemSemantics => struct { id_result_type: Id, id_result: Id, pointer: Id },
2198 .OpInBoundsPtrAccessChain => struct { id_result_type: IdResultType, id_result: IdResult, base: IdRef, element: IdRef, indexes: []const IdRef = &.{} },2332 .OpInBoundsPtrAccessChain => struct { id_result_type: Id, id_result: Id, base: Id, element: Id, indexes: []const Id = &.{} },
2199 .OpDecorate => struct { target: IdRef, decoration: Decoration.Extended },2333 .OpDecorate => struct { target: Id, decoration: Decoration.Extended },
2200 .OpMemberDecorate => struct { structure_type: IdRef, member: LiteralInteger, decoration: Decoration.Extended },2334 .OpMemberDecorate => struct { structure_type: Id, member: LiteralInteger, decoration: Decoration.Extended },
2201 .OpDecorationGroup => struct { id_result: IdResult },2335 .OpDecorationGroup => struct { id_result: Id },
2202 .OpGroupDecorate => struct { decoration_group: IdRef, targets: []const IdRef = &.{} },2336 .OpGroupDecorate => struct { decoration_group: Id, targets: []const Id = &.{} },
2203 .OpGroupMemberDecorate => struct { decoration_group: IdRef, targets: []const PairIdRefLiteralInteger = &.{} },2337 .OpGroupMemberDecorate => struct { decoration_group: Id, targets: []const PairIdRefLiteralInteger = &.{} },
2204 .OpVectorExtractDynamic => struct { id_result_type: IdResultType, id_result: IdResult, vector: IdRef, index: IdRef },2338 .OpVectorExtractDynamic => struct { id_result_type: Id, id_result: Id, vector: Id, index: Id },
2205 .OpVectorInsertDynamic => struct { id_result_type: IdResultType, id_result: IdResult, vector: IdRef, component: IdRef, index: IdRef },2339 .OpVectorInsertDynamic => struct { id_result_type: Id, id_result: Id, vector: Id, component: Id, index: Id },
2206 .OpVectorShuffle => struct { id_result_type: IdResultType, id_result: IdResult, vector_1: IdRef, vector_2: IdRef, components: []const LiteralInteger = &.{} },2340 .OpVectorShuffle => struct { id_result_type: Id, id_result: Id, vector_1: Id, vector_2: Id, components: []const LiteralInteger = &.{} },
2207 .OpCompositeConstruct => struct { id_result_type: IdResultType, id_result: IdResult, constituents: []const IdRef = &.{} },2341 .OpCompositeConstruct => struct { id_result_type: Id, id_result: Id, constituents: []const Id = &.{} },
2208 .OpCompositeExtract => struct { id_result_type: IdResultType, id_result: IdResult, composite: IdRef, indexes: []const LiteralInteger = &.{} },2342 .OpCompositeExtract => struct { id_result_type: Id, id_result: Id, composite: Id, indexes: []const LiteralInteger = &.{} },
2209 .OpCompositeInsert => struct { id_result_type: IdResultType, id_result: IdResult, object: IdRef, composite: IdRef, indexes: []const LiteralInteger = &.{} },2343 .OpCompositeInsert => struct { id_result_type: Id, id_result: Id, object: Id, composite: Id, indexes: []const LiteralInteger = &.{} },
2210 .OpCopyObject => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2344 .OpCopyObject => struct { id_result_type: Id, id_result: Id, operand: Id },
2211 .OpTranspose => struct { id_result_type: IdResultType, id_result: IdResult, matrix: IdRef },2345 .OpTranspose => struct { id_result_type: Id, id_result: Id, matrix: Id },
2212 .OpSampledImage => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef, sampler: IdRef },2346 .OpSampledImage => struct { id_result_type: Id, id_result: Id, image: Id, sampler: Id },
2213 .OpImageSampleImplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, image_operands: ?ImageOperands.Extended = null },2347 .OpImageSampleImplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, image_operands: ?ImageOperands.Extended = null },
2214 .OpImageSampleExplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, image_operands: ImageOperands.Extended },2348 .OpImageSampleExplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, image_operands: ImageOperands.Extended },
2215 .OpImageSampleDrefImplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, d_ref: IdRef, image_operands: ?ImageOperands.Extended = null },2349 .OpImageSampleDrefImplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, d_ref: Id, image_operands: ?ImageOperands.Extended = null },
2216 .OpImageSampleDrefExplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, d_ref: IdRef, image_operands: ImageOperands.Extended },2350 .OpImageSampleDrefExplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, d_ref: Id, image_operands: ImageOperands.Extended },
2217 .OpImageSampleProjImplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, image_operands: ?ImageOperands.Extended = null },2351 .OpImageSampleProjImplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, image_operands: ?ImageOperands.Extended = null },
2218 .OpImageSampleProjExplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, image_operands: ImageOperands.Extended },2352 .OpImageSampleProjExplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, image_operands: ImageOperands.Extended },
2219 .OpImageSampleProjDrefImplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, d_ref: IdRef, image_operands: ?ImageOperands.Extended = null },2353 .OpImageSampleProjDrefImplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, d_ref: Id, image_operands: ?ImageOperands.Extended = null },
2220 .OpImageSampleProjDrefExplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, d_ref: IdRef, image_operands: ImageOperands.Extended },2354 .OpImageSampleProjDrefExplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, d_ref: Id, image_operands: ImageOperands.Extended },
2221 .OpImageFetch => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef, coordinate: IdRef, image_operands: ?ImageOperands.Extended = null },2355 .OpImageFetch => struct { id_result_type: Id, id_result: Id, image: Id, coordinate: Id, image_operands: ?ImageOperands.Extended = null },
2222 .OpImageGather => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, component: IdRef, image_operands: ?ImageOperands.Extended = null },2356 .OpImageGather => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, component: Id, image_operands: ?ImageOperands.Extended = null },
2223 .OpImageDrefGather => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, d_ref: IdRef, image_operands: ?ImageOperands.Extended = null },2357 .OpImageDrefGather => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, d_ref: Id, image_operands: ?ImageOperands.Extended = null },
2224 .OpImageRead => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef, coordinate: IdRef, image_operands: ?ImageOperands.Extended = null },2358 .OpImageRead => struct { id_result_type: Id, id_result: Id, image: Id, coordinate: Id, image_operands: ?ImageOperands.Extended = null },
2225 .OpImageWrite => struct { image: IdRef, coordinate: IdRef, texel: IdRef, image_operands: ?ImageOperands.Extended = null },2359 .OpImageWrite => struct { image: Id, coordinate: Id, texel: Id, image_operands: ?ImageOperands.Extended = null },
2226 .OpImage => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef },2360 .OpImage => struct { id_result_type: Id, id_result: Id, sampled_image: Id },
2227 .OpImageQueryFormat => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef },2361 .OpImageQueryFormat => struct { id_result_type: Id, id_result: Id, image: Id },
2228 .OpImageQueryOrder => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef },2362 .OpImageQueryOrder => struct { id_result_type: Id, id_result: Id, image: Id },
2229 .OpImageQuerySizeLod => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef, level_of_detail: IdRef },2363 .OpImageQuerySizeLod => struct { id_result_type: Id, id_result: Id, image: Id, level_of_detail: Id },
2230 .OpImageQuerySize => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef },2364 .OpImageQuerySize => struct { id_result_type: Id, id_result: Id, image: Id },
2231 .OpImageQueryLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef },2365 .OpImageQueryLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id },
2232 .OpImageQueryLevels => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef },2366 .OpImageQueryLevels => struct { id_result_type: Id, id_result: Id, image: Id },
2233 .OpImageQuerySamples => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef },2367 .OpImageQuerySamples => struct { id_result_type: Id, id_result: Id, image: Id },
2234 .OpConvertFToU => struct { id_result_type: IdResultType, id_result: IdResult, float_value: IdRef },2368 .OpConvertFToU => struct { id_result_type: Id, id_result: Id, float_value: Id },
2235 .OpConvertFToS => struct { id_result_type: IdResultType, id_result: IdResult, float_value: IdRef },2369 .OpConvertFToS => struct { id_result_type: Id, id_result: Id, float_value: Id },
2236 .OpConvertSToF => struct { id_result_type: IdResultType, id_result: IdResult, signed_value: IdRef },2370 .OpConvertSToF => struct { id_result_type: Id, id_result: Id, signed_value: Id },
2237 .OpConvertUToF => struct { id_result_type: IdResultType, id_result: IdResult, unsigned_value: IdRef },2371 .OpConvertUToF => struct { id_result_type: Id, id_result: Id, unsigned_value: Id },
2238 .OpUConvert => struct { id_result_type: IdResultType, id_result: IdResult, unsigned_value: IdRef },2372 .OpUConvert => struct { id_result_type: Id, id_result: Id, unsigned_value: Id },
2239 .OpSConvert => struct { id_result_type: IdResultType, id_result: IdResult, signed_value: IdRef },2373 .OpSConvert => struct { id_result_type: Id, id_result: Id, signed_value: Id },
2240 .OpFConvert => struct { id_result_type: IdResultType, id_result: IdResult, float_value: IdRef },2374 .OpFConvert => struct { id_result_type: Id, id_result: Id, float_value: Id },
2241 .OpQuantizeToF16 => struct { id_result_type: IdResultType, id_result: IdResult, value: IdRef },2375 .OpQuantizeToF16 => struct { id_result_type: Id, id_result: Id, value: Id },
2242 .OpConvertPtrToU => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef },2376 .OpConvertPtrToU => struct { id_result_type: Id, id_result: Id, pointer: Id },
2243 .OpSatConvertSToU => struct { id_result_type: IdResultType, id_result: IdResult, signed_value: IdRef },2377 .OpSatConvertSToU => struct { id_result_type: Id, id_result: Id, signed_value: Id },
2244 .OpSatConvertUToS => struct { id_result_type: IdResultType, id_result: IdResult, unsigned_value: IdRef },2378 .OpSatConvertUToS => struct { id_result_type: Id, id_result: Id, unsigned_value: Id },
2245 .OpConvertUToPtr => struct { id_result_type: IdResultType, id_result: IdResult, integer_value: IdRef },2379 .OpConvertUToPtr => struct { id_result_type: Id, id_result: Id, integer_value: Id },
2246 .OpPtrCastToGeneric => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef },2380 .OpPtrCastToGeneric => struct { id_result_type: Id, id_result: Id, pointer: Id },
2247 .OpGenericCastToPtr => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef },2381 .OpGenericCastToPtr => struct { id_result_type: Id, id_result: Id, pointer: Id },
2248 .OpGenericCastToPtrExplicit => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, storage: StorageClass },2382 .OpGenericCastToPtrExplicit => struct { id_result_type: Id, id_result: Id, pointer: Id, storage: StorageClass },
2249 .OpBitcast => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2383 .OpBitcast => struct { id_result_type: Id, id_result: Id, operand: Id },
2250 .OpSNegate => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2384 .OpSNegate => struct { id_result_type: Id, id_result: Id, operand: Id },
2251 .OpFNegate => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2385 .OpFNegate => struct { id_result_type: Id, id_result: Id, operand: Id },
2252 .OpIAdd => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2386 .OpIAdd => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2253 .OpFAdd => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2387 .OpFAdd => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2254 .OpISub => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2388 .OpISub => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2255 .OpFSub => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2389 .OpFSub => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2256 .OpIMul => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2390 .OpIMul => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2257 .OpFMul => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2391 .OpFMul => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2258 .OpUDiv => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2392 .OpUDiv => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2259 .OpSDiv => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2393 .OpSDiv => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2260 .OpFDiv => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2394 .OpFDiv => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2261 .OpUMod => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2395 .OpUMod => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2262 .OpSRem => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2396 .OpSRem => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2263 .OpSMod => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2397 .OpSMod => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2264 .OpFRem => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2398 .OpFRem => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2265 .OpFMod => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2399 .OpFMod => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2266 .OpVectorTimesScalar => struct { id_result_type: IdResultType, id_result: IdResult, vector: IdRef, scalar: IdRef },2400 .OpVectorTimesScalar => struct { id_result_type: Id, id_result: Id, vector: Id, scalar: Id },
2267 .OpMatrixTimesScalar => struct { id_result_type: IdResultType, id_result: IdResult, matrix: IdRef, scalar: IdRef },2401 .OpMatrixTimesScalar => struct { id_result_type: Id, id_result: Id, matrix: Id, scalar: Id },
2268 .OpVectorTimesMatrix => struct { id_result_type: IdResultType, id_result: IdResult, vector: IdRef, matrix: IdRef },2402 .OpVectorTimesMatrix => struct { id_result_type: Id, id_result: Id, vector: Id, matrix: Id },
2269 .OpMatrixTimesVector => struct { id_result_type: IdResultType, id_result: IdResult, matrix: IdRef, vector: IdRef },2403 .OpMatrixTimesVector => struct { id_result_type: Id, id_result: Id, matrix: Id, vector: Id },
2270 .OpMatrixTimesMatrix => struct { id_result_type: IdResultType, id_result: IdResult, leftmatrix: IdRef, rightmatrix: IdRef },2404 .OpMatrixTimesMatrix => struct { id_result_type: Id, id_result: Id, left_matrix: Id, right_matrix: Id },
2271 .OpOuterProduct => struct { id_result_type: IdResultType, id_result: IdResult, vector_1: IdRef, vector_2: IdRef },2405 .OpOuterProduct => struct { id_result_type: Id, id_result: Id, vector_1: Id, vector_2: Id },
2272 .OpDot => struct { id_result_type: IdResultType, id_result: IdResult, vector_1: IdRef, vector_2: IdRef },2406 .OpDot => struct { id_result_type: Id, id_result: Id, vector_1: Id, vector_2: Id },
2273 .OpIAddCarry => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2407 .OpIAddCarry => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2274 .OpISubBorrow => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2408 .OpISubBorrow => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2275 .OpUMulExtended => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2409 .OpUMulExtended => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2276 .OpSMulExtended => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2410 .OpSMulExtended => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2277 .OpAny => struct { id_result_type: IdResultType, id_result: IdResult, vector: IdRef },2411 .OpAny => struct { id_result_type: Id, id_result: Id, vector: Id },
2278 .OpAll => struct { id_result_type: IdResultType, id_result: IdResult, vector: IdRef },2412 .OpAll => struct { id_result_type: Id, id_result: Id, vector: Id },
2279 .OpIsNan => struct { id_result_type: IdResultType, id_result: IdResult, x: IdRef },2413 .OpIsNan => struct { id_result_type: Id, id_result: Id, x: Id },
2280 .OpIsInf => struct { id_result_type: IdResultType, id_result: IdResult, x: IdRef },2414 .OpIsInf => struct { id_result_type: Id, id_result: Id, x: Id },
2281 .OpIsFinite => struct { id_result_type: IdResultType, id_result: IdResult, x: IdRef },2415 .OpIsFinite => struct { id_result_type: Id, id_result: Id, x: Id },
2282 .OpIsNormal => struct { id_result_type: IdResultType, id_result: IdResult, x: IdRef },2416 .OpIsNormal => struct { id_result_type: Id, id_result: Id, x: Id },
2283 .OpSignBitSet => struct { id_result_type: IdResultType, id_result: IdResult, x: IdRef },2417 .OpSignBitSet => struct { id_result_type: Id, id_result: Id, x: Id },
2284 .OpLessOrGreater => struct { id_result_type: IdResultType, id_result: IdResult, x: IdRef, y: IdRef },2418 .OpLessOrGreater => struct { id_result_type: Id, id_result: Id, x: Id, y: Id },
2285 .OpOrdered => struct { id_result_type: IdResultType, id_result: IdResult, x: IdRef, y: IdRef },2419 .OpOrdered => struct { id_result_type: Id, id_result: Id, x: Id, y: Id },
2286 .OpUnordered => struct { id_result_type: IdResultType, id_result: IdResult, x: IdRef, y: IdRef },2420 .OpUnordered => struct { id_result_type: Id, id_result: Id, x: Id, y: Id },
2287 .OpLogicalEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2421 .OpLogicalEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2288 .OpLogicalNotEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2422 .OpLogicalNotEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2289 .OpLogicalOr => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2423 .OpLogicalOr => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2290 .OpLogicalAnd => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2424 .OpLogicalAnd => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2291 .OpLogicalNot => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2425 .OpLogicalNot => struct { id_result_type: Id, id_result: Id, operand: Id },
2292 .OpSelect => struct { id_result_type: IdResultType, id_result: IdResult, condition: IdRef, object_1: IdRef, object_2: IdRef },2426 .OpSelect => struct { id_result_type: Id, id_result: Id, condition: Id, object_1: Id, object_2: Id },
2293 .OpIEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2427 .OpIEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2294 .OpINotEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2428 .OpINotEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2295 .OpUGreaterThan => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2429 .OpUGreaterThan => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2296 .OpSGreaterThan => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2430 .OpSGreaterThan => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2297 .OpUGreaterThanEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2431 .OpUGreaterThanEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2298 .OpSGreaterThanEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2432 .OpSGreaterThanEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2299 .OpULessThan => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2433 .OpULessThan => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2300 .OpSLessThan => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2434 .OpSLessThan => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2301 .OpULessThanEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2435 .OpULessThanEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2302 .OpSLessThanEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2436 .OpSLessThanEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2303 .OpFOrdEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2437 .OpFOrdEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2304 .OpFUnordEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2438 .OpFUnordEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2305 .OpFOrdNotEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2439 .OpFOrdNotEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2306 .OpFUnordNotEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2440 .OpFUnordNotEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2307 .OpFOrdLessThan => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2441 .OpFOrdLessThan => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2308 .OpFUnordLessThan => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2442 .OpFUnordLessThan => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2309 .OpFOrdGreaterThan => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2443 .OpFOrdGreaterThan => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2310 .OpFUnordGreaterThan => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2444 .OpFUnordGreaterThan => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2311 .OpFOrdLessThanEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2445 .OpFOrdLessThanEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2312 .OpFUnordLessThanEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2446 .OpFUnordLessThanEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2313 .OpFOrdGreaterThanEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2447 .OpFOrdGreaterThanEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2314 .OpFUnordGreaterThanEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2448 .OpFUnordGreaterThanEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2315 .OpShiftRightLogical => struct { id_result_type: IdResultType, id_result: IdResult, base: IdRef, shift: IdRef },2449 .OpShiftRightLogical => struct { id_result_type: Id, id_result: Id, base: Id, shift: Id },
2316 .OpShiftRightArithmetic => struct { id_result_type: IdResultType, id_result: IdResult, base: IdRef, shift: IdRef },2450 .OpShiftRightArithmetic => struct { id_result_type: Id, id_result: Id, base: Id, shift: Id },
2317 .OpShiftLeftLogical => struct { id_result_type: IdResultType, id_result: IdResult, base: IdRef, shift: IdRef },2451 .OpShiftLeftLogical => struct { id_result_type: Id, id_result: Id, base: Id, shift: Id },
2318 .OpBitwiseOr => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2452 .OpBitwiseOr => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2319 .OpBitwiseXor => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2453 .OpBitwiseXor => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2320 .OpBitwiseAnd => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2454 .OpBitwiseAnd => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2321 .OpNot => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2455 .OpNot => struct { id_result_type: Id, id_result: Id, operand: Id },
2322 .OpBitFieldInsert => struct { id_result_type: IdResultType, id_result: IdResult, base: IdRef, insert: IdRef, offset: IdRef, count: IdRef },2456 .OpBitFieldInsert => struct { id_result_type: Id, id_result: Id, base: Id, insert: Id, offset: Id, count: Id },
2323 .OpBitFieldSExtract => struct { id_result_type: IdResultType, id_result: IdResult, base: IdRef, offset: IdRef, count: IdRef },2457 .OpBitFieldSExtract => struct { id_result_type: Id, id_result: Id, base: Id, offset: Id, count: Id },
2324 .OpBitFieldUExtract => struct { id_result_type: IdResultType, id_result: IdResult, base: IdRef, offset: IdRef, count: IdRef },2458 .OpBitFieldUExtract => struct { id_result_type: Id, id_result: Id, base: Id, offset: Id, count: Id },
2325 .OpBitReverse => struct { id_result_type: IdResultType, id_result: IdResult, base: IdRef },2459 .OpBitReverse => struct { id_result_type: Id, id_result: Id, base: Id },
2326 .OpBitCount => struct { id_result_type: IdResultType, id_result: IdResult, base: IdRef },2460 .OpBitCount => struct { id_result_type: Id, id_result: Id, base: Id },
2327 .OpDPdx => struct { id_result_type: IdResultType, id_result: IdResult, p: IdRef },2461 .OpDPdx => struct { id_result_type: Id, id_result: Id, p: Id },
2328 .OpDPdy => struct { id_result_type: IdResultType, id_result: IdResult, p: IdRef },2462 .OpDPdy => struct { id_result_type: Id, id_result: Id, p: Id },
2329 .OpFwidth => struct { id_result_type: IdResultType, id_result: IdResult, p: IdRef },2463 .OpFwidth => struct { id_result_type: Id, id_result: Id, p: Id },
2330 .OpDPdxFine => struct { id_result_type: IdResultType, id_result: IdResult, p: IdRef },2464 .OpDPdxFine => struct { id_result_type: Id, id_result: Id, p: Id },
2331 .OpDPdyFine => struct { id_result_type: IdResultType, id_result: IdResult, p: IdRef },2465 .OpDPdyFine => struct { id_result_type: Id, id_result: Id, p: Id },
2332 .OpFwidthFine => struct { id_result_type: IdResultType, id_result: IdResult, p: IdRef },2466 .OpFwidthFine => struct { id_result_type: Id, id_result: Id, p: Id },
2333 .OpDPdxCoarse => struct { id_result_type: IdResultType, id_result: IdResult, p: IdRef },2467 .OpDPdxCoarse => struct { id_result_type: Id, id_result: Id, p: Id },
2334 .OpDPdyCoarse => struct { id_result_type: IdResultType, id_result: IdResult, p: IdRef },2468 .OpDPdyCoarse => struct { id_result_type: Id, id_result: Id, p: Id },
2335 .OpFwidthCoarse => struct { id_result_type: IdResultType, id_result: IdResult, p: IdRef },2469 .OpFwidthCoarse => struct { id_result_type: Id, id_result: Id, p: Id },
2336 .OpEmitVertex => void,2470 .OpEmitVertex => void,
2337 .OpEndPrimitive => void,2471 .OpEndPrimitive => void,
2338 .OpEmitStreamVertex => struct { stream: IdRef },2472 .OpEmitStreamVertex => struct { stream: Id },
2339 .OpEndStreamPrimitive => struct { stream: IdRef },2473 .OpEndStreamPrimitive => struct { stream: Id },
2340 .OpControlBarrier => struct { execution: IdScope, memory: IdScope, semantics: IdMemorySemantics },2474 .OpControlBarrier => struct { execution: Id, memory: Id, semantics: Id },
2341 .OpMemoryBarrier => struct { memory: IdScope, semantics: IdMemorySemantics },2475 .OpMemoryBarrier => struct { memory: Id, semantics: Id },
2342 .OpAtomicLoad => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics },2476 .OpAtomicLoad => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id },
2343 .OpAtomicStore => struct { pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2477 .OpAtomicStore => struct { pointer: Id, memory: Id, semantics: Id, value: Id },
2344 .OpAtomicExchange => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2478 .OpAtomicExchange => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id, value: Id },
2345 .OpAtomicCompareExchange => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, equal: IdMemorySemantics, unequal: IdMemorySemantics, value: IdRef, comparator: IdRef },2479 .OpAtomicCompareExchange => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, equal: Id, unequal: Id, value: Id, comparator: Id },
2346 .OpAtomicCompareExchangeWeak => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, equal: IdMemorySemantics, unequal: IdMemorySemantics, value: IdRef, comparator: IdRef },2480 .OpAtomicCompareExchangeWeak => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, equal: Id, unequal: Id, value: Id, comparator: Id },
2347 .OpAtomicIIncrement => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics },2481 .OpAtomicIIncrement => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id },
2348 .OpAtomicIDecrement => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics },2482 .OpAtomicIDecrement => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id },
2349 .OpAtomicIAdd => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2483 .OpAtomicIAdd => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id, value: Id },
2350 .OpAtomicISub => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2484 .OpAtomicISub => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id, value: Id },
2351 .OpAtomicSMin => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2485 .OpAtomicSMin => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id, value: Id },
2352 .OpAtomicUMin => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2486 .OpAtomicUMin => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id, value: Id },
2353 .OpAtomicSMax => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2487 .OpAtomicSMax => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id, value: Id },
2354 .OpAtomicUMax => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2488 .OpAtomicUMax => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id, value: Id },
2355 .OpAtomicAnd => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2489 .OpAtomicAnd => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id, value: Id },
2356 .OpAtomicOr => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2490 .OpAtomicOr => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id, value: Id },
2357 .OpAtomicXor => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2491 .OpAtomicXor => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id, value: Id },
2358 .OpPhi => struct { id_result_type: IdResultType, id_result: IdResult, pair_id_ref_id_ref: []const PairIdRefIdRef = &.{} },2492 .OpPhi => struct { id_result_type: Id, id_result: Id, pair_id_ref_id_ref: []const PairIdRefIdRef = &.{} },
2359 .OpLoopMerge => struct { merge_block: IdRef, continue_target: IdRef, loop_control: LoopControl.Extended },2493 .OpLoopMerge => struct { merge_block: Id, continue_target: Id, loop_control: LoopControl.Extended },
2360 .OpSelectionMerge => struct { merge_block: IdRef, selection_control: SelectionControl },2494 .OpSelectionMerge => struct { merge_block: Id, selection_control: SelectionControl },
2361 .OpLabel => struct { id_result: IdResult },2495 .OpLabel => struct { id_result: Id },
2362 .OpBranch => struct { target_label: IdRef },2496 .OpBranch => struct { target_label: Id },
2363 .OpBranchConditional => struct { condition: IdRef, true_label: IdRef, false_label: IdRef, branch_weights: []const LiteralInteger = &.{} },2497 .OpBranchConditional => struct { condition: Id, true_label: Id, false_label: Id, branch_weights: []const LiteralInteger = &.{} },
2364 .OpSwitch => struct { selector: IdRef, default: IdRef, target: []const PairLiteralIntegerIdRef = &.{} },2498 .OpSwitch => struct { selector: Id, default: Id, target: []const PairLiteralIntegerIdRef = &.{} },
2365 .OpKill => void,2499 .OpKill => void,
2366 .OpReturn => void,2500 .OpReturn => void,
2367 .OpReturnValue => struct { value: IdRef },2501 .OpReturnValue => struct { value: Id },
2368 .OpUnreachable => void,2502 .OpUnreachable => void,
2369 .OpLifetimeStart => struct { pointer: IdRef, size: LiteralInteger },2503 .OpLifetimeStart => struct { pointer: Id, size: LiteralInteger },
2370 .OpLifetimeStop => struct { pointer: IdRef, size: LiteralInteger },2504 .OpLifetimeStop => struct { pointer: Id, size: LiteralInteger },
2371 .OpGroupAsyncCopy => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, destination: IdRef, source: IdRef, num_elements: IdRef, stride: IdRef, event: IdRef },2505 .OpGroupAsyncCopy => struct { id_result_type: Id, id_result: Id, execution: Id, destination: Id, source: Id, num_elements: Id, stride: Id, event: Id },
2372 .OpGroupWaitEvents => struct { execution: IdScope, num_events: IdRef, events_list: IdRef },2506 .OpGroupWaitEvents => struct { execution: Id, num_events: Id, events_list: Id },
2373 .OpGroupAll => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, predicate: IdRef },2507 .OpGroupAll => struct { id_result_type: Id, id_result: Id, execution: Id, predicate: Id },
2374 .OpGroupAny => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, predicate: IdRef },2508 .OpGroupAny => struct { id_result_type: Id, id_result: Id, execution: Id, predicate: Id },
2375 .OpGroupBroadcast => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef, localid: IdRef },2509 .OpGroupBroadcast => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id, local_id: Id },
2376 .OpGroupIAdd => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2510 .OpGroupIAdd => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2377 .OpGroupFAdd => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2511 .OpGroupFAdd => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2378 .OpGroupFMin => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2512 .OpGroupFMin => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2379 .OpGroupUMin => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2513 .OpGroupUMin => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2380 .OpGroupSMin => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2514 .OpGroupSMin => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2381 .OpGroupFMax => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2515 .OpGroupFMax => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2382 .OpGroupUMax => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2516 .OpGroupUMax => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2383 .OpGroupSMax => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2517 .OpGroupSMax => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2384 .OpReadPipe => struct { id_result_type: IdResultType, id_result: IdResult, pipe: IdRef, pointer: IdRef, packet_size: IdRef, packet_alignment: IdRef },2518 .OpReadPipe => struct { id_result_type: Id, id_result: Id, pipe: Id, pointer: Id, packet_size: Id, packet_alignment: Id },
2385 .OpWritePipe => struct { id_result_type: IdResultType, id_result: IdResult, pipe: IdRef, pointer: IdRef, packet_size: IdRef, packet_alignment: IdRef },2519 .OpWritePipe => struct { id_result_type: Id, id_result: Id, pipe: Id, pointer: Id, packet_size: Id, packet_alignment: Id },
2386 .OpReservedReadPipe => struct { id_result_type: IdResultType, id_result: IdResult, pipe: IdRef, reserve_id: IdRef, index: IdRef, pointer: IdRef, packet_size: IdRef, packet_alignment: IdRef },2520 .OpReservedReadPipe => struct { id_result_type: Id, id_result: Id, pipe: Id, reserve_id: Id, index: Id, pointer: Id, packet_size: Id, packet_alignment: Id },
2387 .OpReservedWritePipe => struct { id_result_type: IdResultType, id_result: IdResult, pipe: IdRef, reserve_id: IdRef, index: IdRef, pointer: IdRef, packet_size: IdRef, packet_alignment: IdRef },2521 .OpReservedWritePipe => struct { id_result_type: Id, id_result: Id, pipe: Id, reserve_id: Id, index: Id, pointer: Id, packet_size: Id, packet_alignment: Id },
2388 .OpReserveReadPipePackets => struct { id_result_type: IdResultType, id_result: IdResult, pipe: IdRef, num_packets: IdRef, packet_size: IdRef, packet_alignment: IdRef },2522 .OpReserveReadPipePackets => struct { id_result_type: Id, id_result: Id, pipe: Id, num_packets: Id, packet_size: Id, packet_alignment: Id },
2389 .OpReserveWritePipePackets => struct { id_result_type: IdResultType, id_result: IdResult, pipe: IdRef, num_packets: IdRef, packet_size: IdRef, packet_alignment: IdRef },2523 .OpReserveWritePipePackets => struct { id_result_type: Id, id_result: Id, pipe: Id, num_packets: Id, packet_size: Id, packet_alignment: Id },
2390 .OpCommitReadPipe => struct { pipe: IdRef, reserve_id: IdRef, packet_size: IdRef, packet_alignment: IdRef },2524 .OpCommitReadPipe => struct { pipe: Id, reserve_id: Id, packet_size: Id, packet_alignment: Id },
2391 .OpCommitWritePipe => struct { pipe: IdRef, reserve_id: IdRef, packet_size: IdRef, packet_alignment: IdRef },2525 .OpCommitWritePipe => struct { pipe: Id, reserve_id: Id, packet_size: Id, packet_alignment: Id },
2392 .OpIsValidReserveId => struct { id_result_type: IdResultType, id_result: IdResult, reserve_id: IdRef },2526 .OpIsValidReserveId => struct { id_result_type: Id, id_result: Id, reserve_id: Id },
2393 .OpGetNumPipePackets => struct { id_result_type: IdResultType, id_result: IdResult, pipe: IdRef, packet_size: IdRef, packet_alignment: IdRef },2527 .OpGetNumPipePackets => struct { id_result_type: Id, id_result: Id, pipe: Id, packet_size: Id, packet_alignment: Id },
2394 .OpGetMaxPipePackets => struct { id_result_type: IdResultType, id_result: IdResult, pipe: IdRef, packet_size: IdRef, packet_alignment: IdRef },2528 .OpGetMaxPipePackets => struct { id_result_type: Id, id_result: Id, pipe: Id, packet_size: Id, packet_alignment: Id },
2395 .OpGroupReserveReadPipePackets => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, pipe: IdRef, num_packets: IdRef, packet_size: IdRef, packet_alignment: IdRef },2529 .OpGroupReserveReadPipePackets => struct { id_result_type: Id, id_result: Id, execution: Id, pipe: Id, num_packets: Id, packet_size: Id, packet_alignment: Id },
2396 .OpGroupReserveWritePipePackets => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, pipe: IdRef, num_packets: IdRef, packet_size: IdRef, packet_alignment: IdRef },2530 .OpGroupReserveWritePipePackets => struct { id_result_type: Id, id_result: Id, execution: Id, pipe: Id, num_packets: Id, packet_size: Id, packet_alignment: Id },
2397 .OpGroupCommitReadPipe => struct { execution: IdScope, pipe: IdRef, reserve_id: IdRef, packet_size: IdRef, packet_alignment: IdRef },2531 .OpGroupCommitReadPipe => struct { execution: Id, pipe: Id, reserve_id: Id, packet_size: Id, packet_alignment: Id },
2398 .OpGroupCommitWritePipe => struct { execution: IdScope, pipe: IdRef, reserve_id: IdRef, packet_size: IdRef, packet_alignment: IdRef },2532 .OpGroupCommitWritePipe => struct { execution: Id, pipe: Id, reserve_id: Id, packet_size: Id, packet_alignment: Id },
2399 .OpEnqueueMarker => struct { id_result_type: IdResultType, id_result: IdResult, queue: IdRef, num_events: IdRef, wait_events: IdRef, ret_event: IdRef },2533 .OpEnqueueMarker => struct { id_result_type: Id, id_result: Id, queue: Id, num_events: Id, wait_events: Id, ret_event: Id },
2400 .OpEnqueueKernel => struct { id_result_type: IdResultType, id_result: IdResult, queue: IdRef, flags: IdRef, nd_range: IdRef, num_events: IdRef, wait_events: IdRef, ret_event: IdRef, invoke: IdRef, param: IdRef, param_size: IdRef, param_align: IdRef, local_size: []const IdRef = &.{} },2534 .OpEnqueueKernel => struct { id_result_type: Id, id_result: Id, queue: Id, flags: Id, nd_range: Id, num_events: Id, wait_events: Id, ret_event: Id, invoke: Id, param: Id, param_size: Id, param_align: Id, local_size: []const Id = &.{} },
2401 .OpGetKernelNDrangeSubGroupCount => struct { id_result_type: IdResultType, id_result: IdResult, nd_range: IdRef, invoke: IdRef, param: IdRef, param_size: IdRef, param_align: IdRef },2535 .OpGetKernelNDrangeSubGroupCount => struct { id_result_type: Id, id_result: Id, nd_range: Id, invoke: Id, param: Id, param_size: Id, param_align: Id },
2402 .OpGetKernelNDrangeMaxSubGroupSize => struct { id_result_type: IdResultType, id_result: IdResult, nd_range: IdRef, invoke: IdRef, param: IdRef, param_size: IdRef, param_align: IdRef },2536 .OpGetKernelNDrangeMaxSubGroupSize => struct { id_result_type: Id, id_result: Id, nd_range: Id, invoke: Id, param: Id, param_size: Id, param_align: Id },
2403 .OpGetKernelWorkGroupSize => struct { id_result_type: IdResultType, id_result: IdResult, invoke: IdRef, param: IdRef, param_size: IdRef, param_align: IdRef },2537 .OpGetKernelWorkGroupSize => struct { id_result_type: Id, id_result: Id, invoke: Id, param: Id, param_size: Id, param_align: Id },
2404 .OpGetKernelPreferredWorkGroupSizeMultiple => struct { id_result_type: IdResultType, id_result: IdResult, invoke: IdRef, param: IdRef, param_size: IdRef, param_align: IdRef },2538 .OpGetKernelPreferredWorkGroupSizeMultiple => struct { id_result_type: Id, id_result: Id, invoke: Id, param: Id, param_size: Id, param_align: Id },
2405 .OpRetainEvent => struct { event: IdRef },2539 .OpRetainEvent => struct { event: Id },
2406 .OpReleaseEvent => struct { event: IdRef },2540 .OpReleaseEvent => struct { event: Id },
2407 .OpCreateUserEvent => struct { id_result_type: IdResultType, id_result: IdResult },2541 .OpCreateUserEvent => struct { id_result_type: Id, id_result: Id },
2408 .OpIsValidEvent => struct { id_result_type: IdResultType, id_result: IdResult, event: IdRef },2542 .OpIsValidEvent => struct { id_result_type: Id, id_result: Id, event: Id },
2409 .OpSetUserEventStatus => struct { event: IdRef, status: IdRef },2543 .OpSetUserEventStatus => struct { event: Id, status: Id },
2410 .OpCaptureEventProfilingInfo => struct { event: IdRef, profiling_info: IdRef, value: IdRef },2544 .OpCaptureEventProfilingInfo => struct { event: Id, profiling_info: Id, value: Id },
2411 .OpGetDefaultQueue => struct { id_result_type: IdResultType, id_result: IdResult },2545 .OpGetDefaultQueue => struct { id_result_type: Id, id_result: Id },
2412 .OpBuildNDRange => struct { id_result_type: IdResultType, id_result: IdResult, globalworksize: IdRef, localworksize: IdRef, globalworkoffset: IdRef },2546 .OpBuildNDRange => struct { id_result_type: Id, id_result: Id, global_work_size: Id, local_work_size: Id, global_work_offset: Id },
2413 .OpImageSparseSampleImplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, image_operands: ?ImageOperands.Extended = null },2547 .OpImageSparseSampleImplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, image_operands: ?ImageOperands.Extended = null },
2414 .OpImageSparseSampleExplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, image_operands: ImageOperands.Extended },2548 .OpImageSparseSampleExplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, image_operands: ImageOperands.Extended },
2415 .OpImageSparseSampleDrefImplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, d_ref: IdRef, image_operands: ?ImageOperands.Extended = null },2549 .OpImageSparseSampleDrefImplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, d_ref: Id, image_operands: ?ImageOperands.Extended = null },
2416 .OpImageSparseSampleDrefExplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, d_ref: IdRef, image_operands: ImageOperands.Extended },2550 .OpImageSparseSampleDrefExplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, d_ref: Id, image_operands: ImageOperands.Extended },
2417 .OpImageSparseSampleProjImplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, image_operands: ?ImageOperands.Extended = null },2551 .OpImageSparseSampleProjImplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, image_operands: ?ImageOperands.Extended = null },
2418 .OpImageSparseSampleProjExplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, image_operands: ImageOperands.Extended },2552 .OpImageSparseSampleProjExplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, image_operands: ImageOperands.Extended },
2419 .OpImageSparseSampleProjDrefImplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, d_ref: IdRef, image_operands: ?ImageOperands.Extended = null },2553 .OpImageSparseSampleProjDrefImplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, d_ref: Id, image_operands: ?ImageOperands.Extended = null },
2420 .OpImageSparseSampleProjDrefExplicitLod => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, d_ref: IdRef, image_operands: ImageOperands.Extended },2554 .OpImageSparseSampleProjDrefExplicitLod => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, d_ref: Id, image_operands: ImageOperands.Extended },
2421 .OpImageSparseFetch => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef, coordinate: IdRef, image_operands: ?ImageOperands.Extended = null },2555 .OpImageSparseFetch => struct { id_result_type: Id, id_result: Id, image: Id, coordinate: Id, image_operands: ?ImageOperands.Extended = null },
2422 .OpImageSparseGather => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, component: IdRef, image_operands: ?ImageOperands.Extended = null },2556 .OpImageSparseGather => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, component: Id, image_operands: ?ImageOperands.Extended = null },
2423 .OpImageSparseDrefGather => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, d_ref: IdRef, image_operands: ?ImageOperands.Extended = null },2557 .OpImageSparseDrefGather => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, d_ref: Id, image_operands: ?ImageOperands.Extended = null },
2424 .OpImageSparseTexelsResident => struct { id_result_type: IdResultType, id_result: IdResult, resident_code: IdRef },2558 .OpImageSparseTexelsResident => struct { id_result_type: Id, id_result: Id, resident_code: Id },
2425 .OpNoLine => void,2559 .OpNoLine => void,
2426 .OpAtomicFlagTestAndSet => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics },2560 .OpAtomicFlagTestAndSet => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id },
2427 .OpAtomicFlagClear => struct { pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics },2561 .OpAtomicFlagClear => struct { pointer: Id, memory: Id, semantics: Id },
2428 .OpImageSparseRead => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef, coordinate: IdRef, image_operands: ?ImageOperands.Extended = null },2562 .OpImageSparseRead => struct { id_result_type: Id, id_result: Id, image: Id, coordinate: Id, image_operands: ?ImageOperands.Extended = null },
2429 .OpSizeOf => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef },2563 .OpSizeOf => struct { id_result_type: Id, id_result: Id, pointer: Id },
2430 .OpTypePipeStorage => struct { id_result: IdResult },2564 .OpTypePipeStorage => struct { id_result: Id },
2431 .OpConstantPipeStorage => struct { id_result_type: IdResultType, id_result: IdResult, packet_size: LiteralInteger, packet_alignment: LiteralInteger, capacity: LiteralInteger },2565 .OpConstantPipeStorage => struct { id_result_type: Id, id_result: Id, packet_size: LiteralInteger, packet_alignment: LiteralInteger, capacity: LiteralInteger },
2432 .OpCreatePipeFromPipeStorage => struct { id_result_type: IdResultType, id_result: IdResult, pipe_storage: IdRef },2566 .OpCreatePipeFromPipeStorage => struct { id_result_type: Id, id_result: Id, pipe_storage: Id },
2433 .OpGetKernelLocalSizeForSubgroupCount => struct { id_result_type: IdResultType, id_result: IdResult, subgroup_count: IdRef, invoke: IdRef, param: IdRef, param_size: IdRef, param_align: IdRef },2567 .OpGetKernelLocalSizeForSubgroupCount => struct { id_result_type: Id, id_result: Id, subgroup_count: Id, invoke: Id, param: Id, param_size: Id, param_align: Id },
2434 .OpGetKernelMaxNumSubgroups => struct { id_result_type: IdResultType, id_result: IdResult, invoke: IdRef, param: IdRef, param_size: IdRef, param_align: IdRef },2568 .OpGetKernelMaxNumSubgroups => struct { id_result_type: Id, id_result: Id, invoke: Id, param: Id, param_size: Id, param_align: Id },
2435 .OpTypeNamedBarrier => struct { id_result: IdResult },2569 .OpTypeNamedBarrier => struct { id_result: Id },
2436 .OpNamedBarrierInitialize => struct { id_result_type: IdResultType, id_result: IdResult, subgroup_count: IdRef },2570 .OpNamedBarrierInitialize => struct { id_result_type: Id, id_result: Id, subgroup_count: Id },
2437 .OpMemoryNamedBarrier => struct { named_barrier: IdRef, memory: IdScope, semantics: IdMemorySemantics },2571 .OpMemoryNamedBarrier => struct { named_barrier: Id, memory: Id, semantics: Id },
2438 .OpModuleProcessed => struct { process: LiteralString },2572 .OpModuleProcessed => struct { process: LiteralString },
2439 .OpExecutionModeId => struct { entry_point: IdRef, mode: ExecutionMode.Extended },2573 .OpExecutionModeId => struct { entry_point: Id, mode: ExecutionMode.Extended },
2440 .OpDecorateId => struct { target: IdRef, decoration: Decoration.Extended },2574 .OpDecorateId => struct { target: Id, decoration: Decoration.Extended },
2441 .OpGroupNonUniformElect => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope },2575 .OpGroupNonUniformElect => struct { id_result_type: Id, id_result: Id, execution: Id },
2442 .OpGroupNonUniformAll => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, predicate: IdRef },2576 .OpGroupNonUniformAll => struct { id_result_type: Id, id_result: Id, execution: Id, predicate: Id },
2443 .OpGroupNonUniformAny => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, predicate: IdRef },2577 .OpGroupNonUniformAny => struct { id_result_type: Id, id_result: Id, execution: Id, predicate: Id },
2444 .OpGroupNonUniformAllEqual => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef },2578 .OpGroupNonUniformAllEqual => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id },
2445 .OpGroupNonUniformBroadcast => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef, id: IdRef },2579 .OpGroupNonUniformBroadcast => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id, id: Id },
2446 .OpGroupNonUniformBroadcastFirst => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef },2580 .OpGroupNonUniformBroadcastFirst => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id },
2447 .OpGroupNonUniformBallot => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, predicate: IdRef },2581 .OpGroupNonUniformBallot => struct { id_result_type: Id, id_result: Id, execution: Id, predicate: Id },
2448 .OpGroupNonUniformInverseBallot => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef },2582 .OpGroupNonUniformInverseBallot => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id },
2449 .OpGroupNonUniformBallotBitExtract => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef, index: IdRef },2583 .OpGroupNonUniformBallotBitExtract => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id, index: Id },
2450 .OpGroupNonUniformBallotBitCount => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef },2584 .OpGroupNonUniformBallotBitCount => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id },
2451 .OpGroupNonUniformBallotFindLSB => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef },2585 .OpGroupNonUniformBallotFindLSB => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id },
2452 .OpGroupNonUniformBallotFindMSB => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef },2586 .OpGroupNonUniformBallotFindMSB => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id },
2453 .OpGroupNonUniformShuffle => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef, id: IdRef },2587 .OpGroupNonUniformShuffle => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id, id: Id },
2454 .OpGroupNonUniformShuffleXor => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef, mask: IdRef },2588 .OpGroupNonUniformShuffleXor => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id, mask: Id },
2455 .OpGroupNonUniformShuffleUp => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef, delta: IdRef },2589 .OpGroupNonUniformShuffleUp => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id, delta: Id },
2456 .OpGroupNonUniformShuffleDown => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef, delta: IdRef },2590 .OpGroupNonUniformShuffleDown => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id, delta: Id },
2457 .OpGroupNonUniformIAdd => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2591 .OpGroupNonUniformIAdd => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2458 .OpGroupNonUniformFAdd => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2592 .OpGroupNonUniformFAdd => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2459 .OpGroupNonUniformIMul => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2593 .OpGroupNonUniformIMul => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2460 .OpGroupNonUniformFMul => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2594 .OpGroupNonUniformFMul => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2461 .OpGroupNonUniformSMin => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2595 .OpGroupNonUniformSMin => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2462 .OpGroupNonUniformUMin => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2596 .OpGroupNonUniformUMin => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2463 .OpGroupNonUniformFMin => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2597 .OpGroupNonUniformFMin => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2464 .OpGroupNonUniformSMax => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2598 .OpGroupNonUniformSMax => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2465 .OpGroupNonUniformUMax => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2599 .OpGroupNonUniformUMax => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2466 .OpGroupNonUniformFMax => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2600 .OpGroupNonUniformFMax => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2467 .OpGroupNonUniformBitwiseAnd => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2601 .OpGroupNonUniformBitwiseAnd => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2468 .OpGroupNonUniformBitwiseOr => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2602 .OpGroupNonUniformBitwiseOr => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2469 .OpGroupNonUniformBitwiseXor => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2603 .OpGroupNonUniformBitwiseXor => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2470 .OpGroupNonUniformLogicalAnd => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2604 .OpGroupNonUniformLogicalAnd => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2471 .OpGroupNonUniformLogicalOr => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2605 .OpGroupNonUniformLogicalOr => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2472 .OpGroupNonUniformLogicalXor => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, value: IdRef, clustersize: ?IdRef = null },2606 .OpGroupNonUniformLogicalXor => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, value: Id, cluster_size: ?Id = null },
2473 .OpGroupNonUniformQuadBroadcast => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef, index: IdRef },2607 .OpGroupNonUniformQuadBroadcast => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id, index: Id },
2474 .OpGroupNonUniformQuadSwap => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef, direction: IdRef },2608 .OpGroupNonUniformQuadSwap => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id, direction: Id },
2475 .OpCopyLogical => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2609 .OpCopyLogical => struct { id_result_type: Id, id_result: Id, operand: Id },
2476 .OpPtrEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2610 .OpPtrEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2477 .OpPtrNotEqual => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2611 .OpPtrNotEqual => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2478 .OpPtrDiff => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2612 .OpPtrDiff => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2479 .OpColorAttachmentReadEXT => struct { id_result_type: IdResultType, id_result: IdResult, attachment: IdRef, sample: ?IdRef = null },2613 .OpColorAttachmentReadEXT => struct { id_result_type: Id, id_result: Id, attachment: Id, sample: ?Id = null },
2480 .OpDepthAttachmentReadEXT => struct { id_result_type: IdResultType, id_result: IdResult, sample: ?IdRef = null },2614 .OpDepthAttachmentReadEXT => struct { id_result_type: Id, id_result: Id, sample: ?Id = null },
2481 .OpStencilAttachmentReadEXT => struct { id_result_type: IdResultType, id_result: IdResult, sample: ?IdRef = null },2615 .OpStencilAttachmentReadEXT => struct { id_result_type: Id, id_result: Id, sample: ?Id = null },
2616 .OpTypeTensorARM => struct { id_result: Id, element_type: Id, rank: ?Id = null, shape: ?Id = null },
2617 .OpTensorReadARM => struct { id_result_type: Id, id_result: Id, tensor: Id, coordinates: Id, tensor_operands: ?TensorOperands.Extended = null },
2618 .OpTensorWriteARM => struct { tensor: Id, coordinates: Id, object: Id, tensor_operands: ?TensorOperands.Extended = null },
2619 .OpTensorQuerySizeARM => struct { id_result_type: Id, id_result: Id, tensor: Id, dimension: Id },
2620 .OpGraphConstantARM => struct { id_result_type: Id, id_result: Id, graph_constant_id: LiteralInteger },
2621 .OpGraphEntryPointARM => struct { graph: Id, name: LiteralString, interface: []const Id = &.{} },
2622 .OpGraphARM => struct { id_result_type: Id, id_result: Id },
2623 .OpGraphInputARM => struct { id_result_type: Id, id_result: Id, input_index: Id, element_index: []const Id = &.{} },
2624 .OpGraphSetOutputARM => struct { value: Id, output_index: Id, element_index: []const Id = &.{} },
2625 .OpGraphEndARM => void,
2626 .OpTypeGraphARM => struct { id_result: Id, num_inputs: LiteralInteger, in_out_types: []const Id = &.{} },
2482 .OpTerminateInvocation => void,2627 .OpTerminateInvocation => void,
2483 .OpSubgroupBallotKHR => struct { id_result_type: IdResultType, id_result: IdResult, predicate: IdRef },2628 .OpTypeUntypedPointerKHR => struct { id_result: Id, storage_class: StorageClass },
2484 .OpSubgroupFirstInvocationKHR => struct { id_result_type: IdResultType, id_result: IdResult, value: IdRef },2629 .OpUntypedVariableKHR => struct { id_result_type: Id, id_result: Id, storage_class: StorageClass, data_type: ?Id = null, initializer: ?Id = null },
2485 .OpSubgroupAllKHR => struct { id_result_type: IdResultType, id_result: IdResult, predicate: IdRef },2630 .OpUntypedAccessChainKHR => struct { id_result_type: Id, id_result: Id, base_type: Id, base: Id, indexes: []const Id = &.{} },
2486 .OpSubgroupAnyKHR => struct { id_result_type: IdResultType, id_result: IdResult, predicate: IdRef },2631 .OpUntypedInBoundsAccessChainKHR => struct { id_result_type: Id, id_result: Id, base_type: Id, base: Id, indexes: []const Id = &.{} },
2487 .OpSubgroupAllEqualKHR => struct { id_result_type: IdResultType, id_result: IdResult, predicate: IdRef },2632 .OpSubgroupBallotKHR => struct { id_result_type: Id, id_result: Id, predicate: Id },
2488 .OpGroupNonUniformRotateKHR => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, value: IdRef, delta: IdRef, clustersize: ?IdRef = null },2633 .OpSubgroupFirstInvocationKHR => struct { id_result_type: Id, id_result: Id, value: Id },
2489 .OpSubgroupReadInvocationKHR => struct { id_result_type: IdResultType, id_result: IdResult, value: IdRef, index: IdRef },2634 .OpUntypedPtrAccessChainKHR => struct { id_result_type: Id, id_result: Id, base_type: Id, base: Id, element: Id, indexes: []const Id = &.{} },
2490 .OpTraceRayKHR => struct { accel: IdRef, ray_flags: IdRef, cull_mask: IdRef, sbt_offset: IdRef, sbt_stride: IdRef, miss_index: IdRef, ray_origin: IdRef, ray_tmin: IdRef, ray_direction: IdRef, ray_tmax: IdRef, payload: IdRef },2635 .OpUntypedInBoundsPtrAccessChainKHR => struct { id_result_type: Id, id_result: Id, base_type: Id, base: Id, element: Id, indexes: []const Id = &.{} },
2491 .OpExecuteCallableKHR => struct { sbt_index: IdRef, callable_data: IdRef },2636 .OpUntypedArrayLengthKHR => struct { id_result_type: Id, id_result: Id, structure: Id, pointer: Id, array_member: LiteralInteger },
2492 .OpConvertUToAccelerationStructureKHR => struct { id_result_type: IdResultType, id_result: IdResult, accel: IdRef },2637 .OpUntypedPrefetchKHR => struct { pointer_type: Id, num_bytes: Id, rw: ?Id = null, locality: ?Id = null, cache_type: ?Id = null },
2638 .OpSubgroupAllKHR => struct { id_result_type: Id, id_result: Id, predicate: Id },
2639 .OpSubgroupAnyKHR => struct { id_result_type: Id, id_result: Id, predicate: Id },
2640 .OpSubgroupAllEqualKHR => struct { id_result_type: Id, id_result: Id, predicate: Id },
2641 .OpGroupNonUniformRotateKHR => struct { id_result_type: Id, id_result: Id, execution: Id, value: Id, delta: Id, cluster_size: ?Id = null },
2642 .OpSubgroupReadInvocationKHR => struct { id_result_type: Id, id_result: Id, value: Id, index: Id },
2643 .OpExtInstWithForwardRefsKHR => struct { id_result_type: Id, id_result: Id, set: Id, instruction: LiteralExtInstInteger, id_ref_4: []const Id = &.{} },
2644 .OpTraceRayKHR => struct { accel: Id, ray_flags: Id, cull_mask: Id, sbt_offset: Id, sbt_stride: Id, miss_index: Id, ray_origin: Id, ray_tmin: Id, ray_direction: Id, ray_tmax: Id, payload: Id },
2645 .OpExecuteCallableKHR => struct { sbt_index: Id, callable_data: Id },
2646 .OpConvertUToAccelerationStructureKHR => struct { id_result_type: Id, id_result: Id, accel: Id },
2493 .OpIgnoreIntersectionKHR => void,2647 .OpIgnoreIntersectionKHR => void,
2494 .OpTerminateRayKHR => void,2648 .OpTerminateRayKHR => void,
2495 .OpSDot => struct { id_result_type: IdResultType, id_result: IdResult, vector_1: IdRef, vector_2: IdRef, packed_vector_format: ?PackedVectorFormat = null },2649 .OpSDot => struct { id_result_type: Id, id_result: Id, vector_1: Id, vector_2: Id, packed_vector_format: ?PackedVectorFormat = null },
2496 .OpUDot => struct { id_result_type: IdResultType, id_result: IdResult, vector_1: IdRef, vector_2: IdRef, packed_vector_format: ?PackedVectorFormat = null },2650 .OpUDot => struct { id_result_type: Id, id_result: Id, vector_1: Id, vector_2: Id, packed_vector_format: ?PackedVectorFormat = null },
2497 .OpSUDot => struct { id_result_type: IdResultType, id_result: IdResult, vector_1: IdRef, vector_2: IdRef, packed_vector_format: ?PackedVectorFormat = null },2651 .OpSUDot => struct { id_result_type: Id, id_result: Id, vector_1: Id, vector_2: Id, packed_vector_format: ?PackedVectorFormat = null },
2498 .OpSDotAccSat => struct { id_result_type: IdResultType, id_result: IdResult, vector_1: IdRef, vector_2: IdRef, accumulator: IdRef, packed_vector_format: ?PackedVectorFormat = null },2652 .OpSDotAccSat => struct { id_result_type: Id, id_result: Id, vector_1: Id, vector_2: Id, accumulator: Id, packed_vector_format: ?PackedVectorFormat = null },
2499 .OpUDotAccSat => struct { id_result_type: IdResultType, id_result: IdResult, vector_1: IdRef, vector_2: IdRef, accumulator: IdRef, packed_vector_format: ?PackedVectorFormat = null },2653 .OpUDotAccSat => struct { id_result_type: Id, id_result: Id, vector_1: Id, vector_2: Id, accumulator: Id, packed_vector_format: ?PackedVectorFormat = null },
2500 .OpSUDotAccSat => struct { id_result_type: IdResultType, id_result: IdResult, vector_1: IdRef, vector_2: IdRef, accumulator: IdRef, packed_vector_format: ?PackedVectorFormat = null },2654 .OpSUDotAccSat => struct { id_result_type: Id, id_result: Id, vector_1: Id, vector_2: Id, accumulator: Id, packed_vector_format: ?PackedVectorFormat = null },
2501 .OpTypeCooperativeMatrixKHR => struct { id_result: IdResult, component_type: IdRef, scope: IdScope, rows: IdRef, columns: IdRef, use: IdRef },2655 .OpTypeCooperativeMatrixKHR => struct { id_result: Id, component_type: Id, scope: Id, rows: Id, columns: Id, use: Id },
2502 .OpCooperativeMatrixLoadKHR => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memorylayout: IdRef, stride: ?IdRef = null, memory_operand: ?MemoryAccess.Extended = null },2656 .OpCooperativeMatrixLoadKHR => struct { id_result_type: Id, id_result: Id, pointer: Id, memory_layout: Id, stride: ?Id = null, memory_operand: ?MemoryAccess.Extended = null },
2503 .OpCooperativeMatrixStoreKHR => struct { pointer: IdRef, object: IdRef, memorylayout: IdRef, stride: ?IdRef = null, memory_operand: ?MemoryAccess.Extended = null },2657 .OpCooperativeMatrixStoreKHR => struct { pointer: Id, object: Id, memory_layout: Id, stride: ?Id = null, memory_operand: ?MemoryAccess.Extended = null },
2504 .OpCooperativeMatrixMulAddKHR => struct { id_result_type: IdResultType, id_result: IdResult, a: IdRef, b: IdRef, c: IdRef, cooperative_matrix_operands: ?CooperativeMatrixOperands = null },2658 .OpCooperativeMatrixMulAddKHR => struct { id_result_type: Id, id_result: Id, a: Id, b: Id, c: Id, cooperative_matrix_operands: ?CooperativeMatrixOperands = null },
2505 .OpCooperativeMatrixLengthKHR => struct { id_result_type: IdResultType, id_result: IdResult, type: IdRef },2659 .OpCooperativeMatrixLengthKHR => struct { id_result_type: Id, id_result: Id, type: Id },
2506 .OpTypeRayQueryKHR => struct { id_result: IdResult },2660 .OpConstantCompositeReplicateEXT => struct { id_result_type: Id, id_result: Id, value: Id },
2507 .OpRayQueryInitializeKHR => struct { rayquery: IdRef, accel: IdRef, rayflags: IdRef, cullmask: IdRef, rayorigin: IdRef, raytmin: IdRef, raydirection: IdRef, raytmax: IdRef },2661 .OpSpecConstantCompositeReplicateEXT => struct { id_result_type: Id, id_result: Id, value: Id },
2508 .OpRayQueryTerminateKHR => struct { rayquery: IdRef },2662 .OpCompositeConstructReplicateEXT => struct { id_result_type: Id, id_result: Id, value: Id },
2509 .OpRayQueryGenerateIntersectionKHR => struct { rayquery: IdRef, hitt: IdRef },2663 .OpTypeRayQueryKHR => struct { id_result: Id },
2510 .OpRayQueryConfirmIntersectionKHR => struct { rayquery: IdRef },2664 .OpRayQueryInitializeKHR => struct { ray_query: Id, accel: Id, ray_flags: Id, cull_mask: Id, ray_origin: Id, ray_t_min: Id, ray_direction: Id, ray_t_max: Id },
2511 .OpRayQueryProceedKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef },2665 .OpRayQueryTerminateKHR => struct { ray_query: Id },
2512 .OpRayQueryGetIntersectionTypeKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2666 .OpRayQueryGenerateIntersectionKHR => struct { ray_query: Id, hit_t: Id },
2513 .OpImageSampleWeightedQCOM => struct { id_result_type: IdResultType, id_result: IdResult, texture: IdRef, coordinates: IdRef, weights: IdRef },2667 .OpRayQueryConfirmIntersectionKHR => struct { ray_query: Id },
2514 .OpImageBoxFilterQCOM => struct { id_result_type: IdResultType, id_result: IdResult, texture: IdRef, coordinates: IdRef, box_size: IdRef },2668 .OpRayQueryProceedKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id },
2515 .OpImageBlockMatchSSDQCOM => struct { id_result_type: IdResultType, id_result: IdResult, target: IdRef, target_coordinates: IdRef, reference: IdRef, reference_coordinates: IdRef, block_size: IdRef },2669 .OpRayQueryGetIntersectionTypeKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2516 .OpImageBlockMatchSADQCOM => struct { id_result_type: IdResultType, id_result: IdResult, target: IdRef, target_coordinates: IdRef, reference: IdRef, reference_coordinates: IdRef, block_size: IdRef },2670 .OpImageSampleWeightedQCOM => struct { id_result_type: Id, id_result: Id, texture: Id, coordinates: Id, weights: Id },
2517 .OpImageBlockMatchWindowSSDQCOM => struct { id_result_type: IdResultType, id_result: IdResult, target_sampled_image: IdRef, target_coordinates: IdRef, reference_sampled_image: IdRef, reference_coordinates: IdRef, block_size: IdRef },2671 .OpImageBoxFilterQCOM => struct { id_result_type: Id, id_result: Id, texture: Id, coordinates: Id, box_size: Id },
2518 .OpImageBlockMatchWindowSADQCOM => struct { id_result_type: IdResultType, id_result: IdResult, target_sampled_image: IdRef, target_coordinates: IdRef, reference_sampled_image: IdRef, reference_coordinates: IdRef, block_size: IdRef },2672 .OpImageBlockMatchSSDQCOM => struct { id_result_type: Id, id_result: Id, target: Id, target_coordinates: Id, reference: Id, reference_coordinates: Id, block_size: Id },
2519 .OpImageBlockMatchGatherSSDQCOM => struct { id_result_type: IdResultType, id_result: IdResult, target_sampled_image: IdRef, target_coordinates: IdRef, reference_sampled_image: IdRef, reference_coordinates: IdRef, block_size: IdRef },2673 .OpImageBlockMatchSADQCOM => struct { id_result_type: Id, id_result: Id, target: Id, target_coordinates: Id, reference: Id, reference_coordinates: Id, block_size: Id },
2520 .OpImageBlockMatchGatherSADQCOM => struct { id_result_type: IdResultType, id_result: IdResult, target_sampled_image: IdRef, target_coordinates: IdRef, reference_sampled_image: IdRef, reference_coordinates: IdRef, block_size: IdRef },2674 .OpImageBlockMatchWindowSSDQCOM => struct { id_result_type: Id, id_result: Id, target_sampled_image: Id, target_coordinates: Id, reference_sampled_image: Id, reference_coordinates: Id, block_size: Id },
2521 .OpGroupIAddNonUniformAMD => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2675 .OpImageBlockMatchWindowSADQCOM => struct { id_result_type: Id, id_result: Id, target_sampled_image: Id, target_coordinates: Id, reference_sampled_image: Id, reference_coordinates: Id, block_size: Id },
2522 .OpGroupFAddNonUniformAMD => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2676 .OpImageBlockMatchGatherSSDQCOM => struct { id_result_type: Id, id_result: Id, target_sampled_image: Id, target_coordinates: Id, reference_sampled_image: Id, reference_coordinates: Id, block_size: Id },
2523 .OpGroupFMinNonUniformAMD => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2677 .OpImageBlockMatchGatherSADQCOM => struct { id_result_type: Id, id_result: Id, target_sampled_image: Id, target_coordinates: Id, reference_sampled_image: Id, reference_coordinates: Id, block_size: Id },
2524 .OpGroupUMinNonUniformAMD => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2678 .OpGroupIAddNonUniformAMD => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2525 .OpGroupSMinNonUniformAMD => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2679 .OpGroupFAddNonUniformAMD => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2526 .OpGroupFMaxNonUniformAMD => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2680 .OpGroupFMinNonUniformAMD => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2527 .OpGroupUMaxNonUniformAMD => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2681 .OpGroupUMinNonUniformAMD => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2528 .OpGroupSMaxNonUniformAMD => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2682 .OpGroupSMinNonUniformAMD => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2529 .OpFragmentMaskFetchAMD => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef, coordinate: IdRef },2683 .OpGroupFMaxNonUniformAMD => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2530 .OpFragmentFetchAMD => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef, coordinate: IdRef, fragment_index: IdRef },2684 .OpGroupUMaxNonUniformAMD => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2531 .OpReadClockKHR => struct { id_result_type: IdResultType, id_result: IdResult, scope: IdScope },2685 .OpGroupSMaxNonUniformAMD => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2532 .OpFinalizeNodePayloadsAMDX => struct { payload_array: IdRef },2686 .OpFragmentMaskFetchAMD => struct { id_result_type: Id, id_result: Id, image: Id, coordinate: Id },
2533 .OpFinishWritingNodePayloadAMDX => struct { id_result_type: IdResultType, id_result: IdResult, payload: IdRef },2687 .OpFragmentFetchAMD => struct { id_result_type: Id, id_result: Id, image: Id, coordinate: Id, fragment_index: Id },
2534 .OpInitializeNodePayloadsAMDX => struct { payload_array: IdRef, visibility: IdScope, payload_count: IdRef, node_index: IdRef },2688 .OpReadClockKHR => struct { id_result_type: Id, id_result: Id, scope: Id },
2535 .OpGroupNonUniformQuadAllKHR => struct { id_result_type: IdResultType, id_result: IdResult, predicate: IdRef },2689 .OpAllocateNodePayloadsAMDX => struct { id_result_type: Id, id_result: Id, visibility: Id, payload_count: Id, node_index: Id },
2536 .OpGroupNonUniformQuadAnyKHR => struct { id_result_type: IdResultType, id_result: IdResult, predicate: IdRef },2690 .OpEnqueueNodePayloadsAMDX => struct { payload_array: Id },
2537 .OpHitObjectRecordHitMotionNV => struct { hit_object: IdRef, acceleration_structure: IdRef, instanceid: IdRef, primitiveid: IdRef, geometryindex: IdRef, hit_kind: IdRef, sbt_record_offset: IdRef, sbt_record_stride: IdRef, origin: IdRef, tmin: IdRef, direction: IdRef, tmax: IdRef, current_time: IdRef, hitobject_attributes: IdRef },2691 .OpTypeNodePayloadArrayAMDX => struct { id_result: Id, payload_type: Id },
2538 .OpHitObjectRecordHitWithIndexMotionNV => struct { hit_object: IdRef, acceleration_structure: IdRef, instanceid: IdRef, primitiveid: IdRef, geometryindex: IdRef, hit_kind: IdRef, sbt_record_index: IdRef, origin: IdRef, tmin: IdRef, direction: IdRef, tmax: IdRef, current_time: IdRef, hitobject_attributes: IdRef },2692 .OpFinishWritingNodePayloadAMDX => struct { id_result_type: Id, id_result: Id, payload: Id },
2539 .OpHitObjectRecordMissMotionNV => struct { hit_object: IdRef, sbt_index: IdRef, origin: IdRef, tmin: IdRef, direction: IdRef, tmax: IdRef, current_time: IdRef },2693 .OpNodePayloadArrayLengthAMDX => struct { id_result_type: Id, id_result: Id, payload_array: Id },
2540 .OpHitObjectGetWorldToObjectNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2694 .OpIsNodePayloadValidAMDX => struct { id_result_type: Id, id_result: Id, payload_type: Id, node_index: Id },
2541 .OpHitObjectGetObjectToWorldNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2695 .OpConstantStringAMDX => struct { id_result: Id, literal_string: LiteralString },
2542 .OpHitObjectGetObjectRayDirectionNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2696 .OpSpecConstantStringAMDX => struct { id_result: Id, literal_string: LiteralString },
2543 .OpHitObjectGetObjectRayOriginNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2697 .OpGroupNonUniformQuadAllKHR => struct { id_result_type: Id, id_result: Id, predicate: Id },
2544 .OpHitObjectTraceRayMotionNV => struct { hit_object: IdRef, acceleration_structure: IdRef, rayflags: IdRef, cullmask: IdRef, sbt_record_offset: IdRef, sbt_record_stride: IdRef, miss_index: IdRef, origin: IdRef, tmin: IdRef, direction: IdRef, tmax: IdRef, time: IdRef, payload: IdRef },2698 .OpGroupNonUniformQuadAnyKHR => struct { id_result_type: Id, id_result: Id, predicate: Id },
2545 .OpHitObjectGetShaderRecordBufferHandleNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2699 .OpHitObjectRecordHitMotionNV => struct { hit_object: Id, acceleration_structure: Id, instance_id: Id, primitive_id: Id, geometry_index: Id, hit_kind: Id, sbt_record_offset: Id, sbt_record_stride: Id, origin: Id, t_min: Id, direction: Id, t_max: Id, current_time: Id, hit_object_attributes: Id },
2546 .OpHitObjectGetShaderBindingTableRecordIndexNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2700 .OpHitObjectRecordHitWithIndexMotionNV => struct { hit_object: Id, acceleration_structure: Id, instance_id: Id, primitive_id: Id, geometry_index: Id, hit_kind: Id, sbt_record_index: Id, origin: Id, t_min: Id, direction: Id, t_max: Id, current_time: Id, hit_object_attributes: Id },
2547 .OpHitObjectRecordEmptyNV => struct { hit_object: IdRef },2701 .OpHitObjectRecordMissMotionNV => struct { hit_object: Id, sbt_index: Id, origin: Id, t_min: Id, direction: Id, t_max: Id, current_time: Id },
2548 .OpHitObjectTraceRayNV => struct { hit_object: IdRef, acceleration_structure: IdRef, rayflags: IdRef, cullmask: IdRef, sbt_record_offset: IdRef, sbt_record_stride: IdRef, miss_index: IdRef, origin: IdRef, tmin: IdRef, direction: IdRef, tmax: IdRef, payload: IdRef },2702 .OpHitObjectGetWorldToObjectNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2549 .OpHitObjectRecordHitNV => struct { hit_object: IdRef, acceleration_structure: IdRef, instanceid: IdRef, primitiveid: IdRef, geometryindex: IdRef, hit_kind: IdRef, sbt_record_offset: IdRef, sbt_record_stride: IdRef, origin: IdRef, tmin: IdRef, direction: IdRef, tmax: IdRef, hitobject_attributes: IdRef },2703 .OpHitObjectGetObjectToWorldNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2550 .OpHitObjectRecordHitWithIndexNV => struct { hit_object: IdRef, acceleration_structure: IdRef, instanceid: IdRef, primitiveid: IdRef, geometryindex: IdRef, hit_kind: IdRef, sbt_record_index: IdRef, origin: IdRef, tmin: IdRef, direction: IdRef, tmax: IdRef, hitobject_attributes: IdRef },2704 .OpHitObjectGetObjectRayDirectionNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2551 .OpHitObjectRecordMissNV => struct { hit_object: IdRef, sbt_index: IdRef, origin: IdRef, tmin: IdRef, direction: IdRef, tmax: IdRef },2705 .OpHitObjectGetObjectRayOriginNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2552 .OpHitObjectExecuteShaderNV => struct { hit_object: IdRef, payload: IdRef },2706 .OpHitObjectTraceRayMotionNV => struct { hit_object: Id, acceleration_structure: Id, ray_flags: Id, cullmask: Id, sbt_record_offset: Id, sbt_record_stride: Id, miss_index: Id, origin: Id, t_min: Id, direction: Id, t_max: Id, time: Id, payload: Id },
2553 .OpHitObjectGetCurrentTimeNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2707 .OpHitObjectGetShaderRecordBufferHandleNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2554 .OpHitObjectGetAttributesNV => struct { hit_object: IdRef, hit_object_attribute: IdRef },2708 .OpHitObjectGetShaderBindingTableRecordIndexNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2555 .OpHitObjectGetHitKindNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2709 .OpHitObjectRecordEmptyNV => struct { hit_object: Id },
2556 .OpHitObjectGetPrimitiveIndexNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2710 .OpHitObjectTraceRayNV => struct { hit_object: Id, acceleration_structure: Id, ray_flags: Id, cullmask: Id, sbt_record_offset: Id, sbt_record_stride: Id, miss_index: Id, origin: Id, t_min: Id, direction: Id, t_max: Id, payload: Id },
2557 .OpHitObjectGetGeometryIndexNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2711 .OpHitObjectRecordHitNV => struct { hit_object: Id, acceleration_structure: Id, instance_id: Id, primitive_id: Id, geometry_index: Id, hit_kind: Id, sbt_record_offset: Id, sbt_record_stride: Id, origin: Id, t_min: Id, direction: Id, t_max: Id, hit_object_attributes: Id },
2558 .OpHitObjectGetInstanceIdNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2712 .OpHitObjectRecordHitWithIndexNV => struct { hit_object: Id, acceleration_structure: Id, instance_id: Id, primitive_id: Id, geometry_index: Id, hit_kind: Id, sbt_record_index: Id, origin: Id, t_min: Id, direction: Id, t_max: Id, hit_object_attributes: Id },
2559 .OpHitObjectGetInstanceCustomIndexNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2713 .OpHitObjectRecordMissNV => struct { hit_object: Id, sbt_index: Id, origin: Id, t_min: Id, direction: Id, t_max: Id },
2560 .OpHitObjectGetWorldRayDirectionNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2714 .OpHitObjectExecuteShaderNV => struct { hit_object: Id, payload: Id },
2561 .OpHitObjectGetWorldRayOriginNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2715 .OpHitObjectGetCurrentTimeNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2562 .OpHitObjectGetRayTMaxNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2716 .OpHitObjectGetAttributesNV => struct { hit_object: Id, hit_object_attribute: Id },
2563 .OpHitObjectGetRayTMinNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2717 .OpHitObjectGetHitKindNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2564 .OpHitObjectIsEmptyNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2718 .OpHitObjectGetPrimitiveIndexNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2565 .OpHitObjectIsHitNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2719 .OpHitObjectGetGeometryIndexNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2566 .OpHitObjectIsMissNV => struct { id_result_type: IdResultType, id_result: IdResult, hit_object: IdRef },2720 .OpHitObjectGetInstanceIdNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2567 .OpReorderThreadWithHitObjectNV => struct { hit_object: IdRef, hint: ?IdRef = null, bits: ?IdRef = null },2721 .OpHitObjectGetInstanceCustomIndexNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2568 .OpReorderThreadWithHintNV => struct { hint: IdRef, bits: IdRef },2722 .OpHitObjectGetWorldRayDirectionNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2569 .OpTypeHitObjectNV => struct { id_result: IdResult },2723 .OpHitObjectGetWorldRayOriginNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2570 .OpImageSampleFootprintNV => struct { id_result_type: IdResultType, id_result: IdResult, sampled_image: IdRef, coordinate: IdRef, granularity: IdRef, coarse: IdRef, image_operands: ?ImageOperands.Extended = null },2724 .OpHitObjectGetRayTMaxNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2571 .OpEmitMeshTasksEXT => struct { group_count_x: IdRef, group_count_y: IdRef, group_count_z: IdRef, payload: ?IdRef = null },2725 .OpHitObjectGetRayTMinNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2572 .OpSetMeshOutputsEXT => struct { vertex_count: IdRef, primitive_count: IdRef },2726 .OpHitObjectIsEmptyNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2573 .OpGroupNonUniformPartitionNV => struct { id_result_type: IdResultType, id_result: IdResult, value: IdRef },2727 .OpHitObjectIsHitNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2574 .OpWritePackedPrimitiveIndices4x8NV => struct { index_offset: IdRef, packed_indices: IdRef },2728 .OpHitObjectIsMissNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2575 .OpFetchMicroTriangleVertexPositionNV => struct { id_result_type: IdResultType, id_result: IdResult, accel: IdRef, instance_id: IdRef, geometry_index: IdRef, primitive_index: IdRef, barycentric: IdRef },2729 .OpReorderThreadWithHitObjectNV => struct { hit_object: Id, hint: ?Id = null, bits: ?Id = null },
2576 .OpFetchMicroTriangleVertexBarycentricNV => struct { id_result_type: IdResultType, id_result: IdResult, accel: IdRef, instance_id: IdRef, geometry_index: IdRef, primitive_index: IdRef, barycentric: IdRef },2730 .OpReorderThreadWithHintNV => struct { hint: Id, bits: Id },
2577 .OpReportIntersectionKHR => struct { id_result_type: IdResultType, id_result: IdResult, hit: IdRef, hitkind: IdRef },2731 .OpTypeHitObjectNV => struct { id_result: Id },
2732 .OpImageSampleFootprintNV => struct { id_result_type: Id, id_result: Id, sampled_image: Id, coordinate: Id, granularity: Id, coarse: Id, image_operands: ?ImageOperands.Extended = null },
2733 .OpTypeCooperativeVectorNV => struct { id_result: Id, component_type: Id, component_count: Id },
2734 .OpCooperativeVectorMatrixMulNV => struct { id_result_type: Id, id_result: Id, input: Id, input_interpretation: Id, matrix: Id, matrix_offset: Id, matrix_interpretation: Id, m: Id, k: Id, memory_layout: Id, transpose: Id, matrix_stride: ?Id = null, cooperative_matrix_operands: ?CooperativeMatrixOperands = null },
2735 .OpCooperativeVectorOuterProductAccumulateNV => struct { pointer: Id, offset: Id, a: Id, b: Id, memory_layout: Id, matrix_interpretation: Id, matrix_stride: ?Id = null },
2736 .OpCooperativeVectorReduceSumAccumulateNV => struct { pointer: Id, offset: Id, v: Id },
2737 .OpCooperativeVectorMatrixMulAddNV => struct { id_result_type: Id, id_result: Id, input: Id, input_interpretation: Id, matrix: Id, matrix_offset: Id, matrix_interpretation: Id, bias: Id, bias_offset: Id, bias_interpretation: Id, m: Id, k: Id, memory_layout: Id, transpose: Id, matrix_stride: ?Id = null, cooperative_matrix_operands: ?CooperativeMatrixOperands = null },
2738 .OpCooperativeMatrixConvertNV => struct { id_result_type: Id, id_result: Id, matrix: Id },
2739 .OpEmitMeshTasksEXT => struct { group_count_x: Id, group_count_y: Id, group_count_z: Id, payload: ?Id = null },
2740 .OpSetMeshOutputsEXT => struct { vertex_count: Id, primitive_count: Id },
2741 .OpGroupNonUniformPartitionNV => struct { id_result_type: Id, id_result: Id, value: Id },
2742 .OpWritePackedPrimitiveIndices4x8NV => struct { index_offset: Id, packed_indices: Id },
2743 .OpFetchMicroTriangleVertexPositionNV => struct { id_result_type: Id, id_result: Id, accel: Id, instance_id: Id, geometry_index: Id, primitive_index: Id, barycentric: Id },
2744 .OpFetchMicroTriangleVertexBarycentricNV => struct { id_result_type: Id, id_result: Id, accel: Id, instance_id: Id, geometry_index: Id, primitive_index: Id, barycentric: Id },
2745 .OpCooperativeVectorLoadNV => struct { id_result_type: Id, id_result: Id, pointer: Id, offset: Id, memory_access: ?MemoryAccess.Extended = null },
2746 .OpCooperativeVectorStoreNV => struct { pointer: Id, offset: Id, object: Id, memory_access: ?MemoryAccess.Extended = null },
2747 .OpReportIntersectionKHR => struct { id_result_type: Id, id_result: Id, hit: Id, hit_kind: Id },
2578 .OpIgnoreIntersectionNV => void,2748 .OpIgnoreIntersectionNV => void,
2579 .OpTerminateRayNV => void,2749 .OpTerminateRayNV => void,
2580 .OpTraceNV => struct { accel: IdRef, ray_flags: IdRef, cull_mask: IdRef, sbt_offset: IdRef, sbt_stride: IdRef, miss_index: IdRef, ray_origin: IdRef, ray_tmin: IdRef, ray_direction: IdRef, ray_tmax: IdRef, payloadid: IdRef },2750 .OpTraceNV => struct { accel: Id, ray_flags: Id, cull_mask: Id, sbt_offset: Id, sbt_stride: Id, miss_index: Id, ray_origin: Id, ray_tmin: Id, ray_direction: Id, ray_tmax: Id, payload_id: Id },
2581 .OpTraceMotionNV => struct { accel: IdRef, ray_flags: IdRef, cull_mask: IdRef, sbt_offset: IdRef, sbt_stride: IdRef, miss_index: IdRef, ray_origin: IdRef, ray_tmin: IdRef, ray_direction: IdRef, ray_tmax: IdRef, time: IdRef, payloadid: IdRef },2751 .OpTraceMotionNV => struct { accel: Id, ray_flags: Id, cull_mask: Id, sbt_offset: Id, sbt_stride: Id, miss_index: Id, ray_origin: Id, ray_tmin: Id, ray_direction: Id, ray_tmax: Id, time: Id, payload_id: Id },
2582 .OpTraceRayMotionNV => struct { accel: IdRef, ray_flags: IdRef, cull_mask: IdRef, sbt_offset: IdRef, sbt_stride: IdRef, miss_index: IdRef, ray_origin: IdRef, ray_tmin: IdRef, ray_direction: IdRef, ray_tmax: IdRef, time: IdRef, payload: IdRef },2752 .OpTraceRayMotionNV => struct { accel: Id, ray_flags: Id, cull_mask: Id, sbt_offset: Id, sbt_stride: Id, miss_index: Id, ray_origin: Id, ray_tmin: Id, ray_direction: Id, ray_tmax: Id, time: Id, payload: Id },
2583 .OpRayQueryGetIntersectionTriangleVertexPositionsKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2753 .OpRayQueryGetIntersectionTriangleVertexPositionsKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2584 .OpTypeAccelerationStructureKHR => struct { id_result: IdResult },2754 .OpTypeAccelerationStructureKHR => struct { id_result: Id },
2585 .OpExecuteCallableNV => struct { sbt_index: IdRef, callable_dataid: IdRef },2755 .OpExecuteCallableNV => struct { sbt_index: Id, callable_data_id: Id },
2586 .OpTypeCooperativeMatrixNV => struct { id_result: IdResult, component_type: IdRef, execution: IdScope, rows: IdRef, columns: IdRef },2756 .OpRayQueryGetClusterIdNV => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2587 .OpCooperativeMatrixLoadNV => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, stride: IdRef, column_major: IdRef, memory_access: ?MemoryAccess.Extended = null },2757 .OpHitObjectGetClusterIdNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2588 .OpCooperativeMatrixStoreNV => struct { pointer: IdRef, object: IdRef, stride: IdRef, column_major: IdRef, memory_access: ?MemoryAccess.Extended = null },2758 .OpTypeCooperativeMatrixNV => struct { id_result: Id, component_type: Id, execution: Id, rows: Id, columns: Id },
2589 .OpCooperativeMatrixMulAddNV => struct { id_result_type: IdResultType, id_result: IdResult, a: IdRef, b: IdRef, c: IdRef },2759 .OpCooperativeMatrixLoadNV => struct { id_result_type: Id, id_result: Id, pointer: Id, stride: Id, column_major: Id, memory_access: ?MemoryAccess.Extended = null },
2590 .OpCooperativeMatrixLengthNV => struct { id_result_type: IdResultType, id_result: IdResult, type: IdRef },2760 .OpCooperativeMatrixStoreNV => struct { pointer: Id, object: Id, stride: Id, column_major: Id, memory_access: ?MemoryAccess.Extended = null },
2761 .OpCooperativeMatrixMulAddNV => struct { id_result_type: Id, id_result: Id, a: Id, b: Id, c: Id },
2762 .OpCooperativeMatrixLengthNV => struct { id_result_type: Id, id_result: Id, type: Id },
2591 .OpBeginInvocationInterlockEXT => void,2763 .OpBeginInvocationInterlockEXT => void,
2592 .OpEndInvocationInterlockEXT => void,2764 .OpEndInvocationInterlockEXT => void,
2765 .OpCooperativeMatrixReduceNV => struct { id_result_type: Id, id_result: Id, matrix: Id, reduce: CooperativeMatrixReduce, combine_func: Id },
2766 .OpCooperativeMatrixLoadTensorNV => struct { id_result_type: Id, id_result: Id, pointer: Id, object: Id, tensor_layout: Id, memory_operand: MemoryAccess.Extended, tensor_addressing_operands: TensorAddressingOperands.Extended },
2767 .OpCooperativeMatrixStoreTensorNV => struct { pointer: Id, object: Id, tensor_layout: Id, memory_operand: MemoryAccess.Extended, tensor_addressing_operands: TensorAddressingOperands.Extended },
2768 .OpCooperativeMatrixPerElementOpNV => struct { id_result_type: Id, id_result: Id, matrix: Id, func: Id, operands: []const Id = &.{} },
2769 .OpTypeTensorLayoutNV => struct { id_result: Id, dim: Id, clamp_mode: Id },
2770 .OpTypeTensorViewNV => struct { id_result: Id, dim: Id, has_dimensions: Id, p: []const Id = &.{} },
2771 .OpCreateTensorLayoutNV => struct { id_result_type: Id, id_result: Id },
2772 .OpTensorLayoutSetDimensionNV => struct { id_result_type: Id, id_result: Id, tensor_layout: Id, dim: []const Id = &.{} },
2773 .OpTensorLayoutSetStrideNV => struct { id_result_type: Id, id_result: Id, tensor_layout: Id, stride: []const Id = &.{} },
2774 .OpTensorLayoutSliceNV => struct { id_result_type: Id, id_result: Id, tensor_layout: Id, operands: []const Id = &.{} },
2775 .OpTensorLayoutSetClampValueNV => struct { id_result_type: Id, id_result: Id, tensor_layout: Id, value: Id },
2776 .OpCreateTensorViewNV => struct { id_result_type: Id, id_result: Id },
2777 .OpTensorViewSetDimensionNV => struct { id_result_type: Id, id_result: Id, tensor_view: Id, dim: []const Id = &.{} },
2778 .OpTensorViewSetStrideNV => struct { id_result_type: Id, id_result: Id, tensor_view: Id, stride: []const Id = &.{} },
2593 .OpDemoteToHelperInvocation => void,2779 .OpDemoteToHelperInvocation => void,
2594 .OpIsHelperInvocationEXT => struct { id_result_type: IdResultType, id_result: IdResult },2780 .OpIsHelperInvocationEXT => struct { id_result_type: Id, id_result: Id },
2595 .OpConvertUToImageNV => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2781 .OpTensorViewSetClipNV => struct { id_result_type: Id, id_result: Id, tensor_view: Id, clip_row_offset: Id, clip_row_span: Id, clip_col_offset: Id, clip_col_span: Id },
2596 .OpConvertUToSamplerNV => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2782 .OpTensorLayoutSetBlockSizeNV => struct { id_result_type: Id, id_result: Id, tensor_layout: Id, block_size: []const Id = &.{} },
2597 .OpConvertImageToUNV => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2783 .OpCooperativeMatrixTransposeNV => struct { id_result_type: Id, id_result: Id, matrix: Id },
2598 .OpConvertSamplerToUNV => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2784 .OpConvertUToImageNV => struct { id_result_type: Id, id_result: Id, operand: Id },
2599 .OpConvertUToSampledImageNV => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2785 .OpConvertUToSamplerNV => struct { id_result_type: Id, id_result: Id, operand: Id },
2600 .OpConvertSampledImageToUNV => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2786 .OpConvertImageToUNV => struct { id_result_type: Id, id_result: Id, operand: Id },
2787 .OpConvertSamplerToUNV => struct { id_result_type: Id, id_result: Id, operand: Id },
2788 .OpConvertUToSampledImageNV => struct { id_result_type: Id, id_result: Id, operand: Id },
2789 .OpConvertSampledImageToUNV => struct { id_result_type: Id, id_result: Id, operand: Id },
2601 .OpSamplerImageAddressingModeNV => struct { bit_width: LiteralInteger },2790 .OpSamplerImageAddressingModeNV => struct { bit_width: LiteralInteger },
2602 .OpRawAccessChainNV => struct { id_result_type: IdResultType, id_result: IdResult, base: IdRef, byte_stride: IdRef, element_index: IdRef, byte_offset: IdRef, raw_access_chain_operands: ?RawAccessChainOperands = null },2791 .OpRawAccessChainNV => struct { id_result_type: Id, id_result: Id, base: Id, byte_stride: Id, element_index: Id, byte_offset: Id, raw_access_chain_operands: ?RawAccessChainOperands = null },
2603 .OpSubgroupShuffleINTEL => struct { id_result_type: IdResultType, id_result: IdResult, data: IdRef, invocationid: IdRef },2792 .OpRayQueryGetIntersectionSpherePositionNV => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2604 .OpSubgroupShuffleDownINTEL => struct { id_result_type: IdResultType, id_result: IdResult, current: IdRef, next: IdRef, delta: IdRef },2793 .OpRayQueryGetIntersectionSphereRadiusNV => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2605 .OpSubgroupShuffleUpINTEL => struct { id_result_type: IdResultType, id_result: IdResult, previous: IdRef, current: IdRef, delta: IdRef },2794 .OpRayQueryGetIntersectionLSSPositionsNV => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2606 .OpSubgroupShuffleXorINTEL => struct { id_result_type: IdResultType, id_result: IdResult, data: IdRef, value: IdRef },2795 .OpRayQueryGetIntersectionLSSRadiiNV => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2607 .OpSubgroupBlockReadINTEL => struct { id_result_type: IdResultType, id_result: IdResult, ptr: IdRef },2796 .OpRayQueryGetIntersectionLSSHitValueNV => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2608 .OpSubgroupBlockWriteINTEL => struct { ptr: IdRef, data: IdRef },2797 .OpHitObjectGetSpherePositionNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2609 .OpSubgroupImageBlockReadINTEL => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef, coordinate: IdRef },2798 .OpHitObjectGetSphereRadiusNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2610 .OpSubgroupImageBlockWriteINTEL => struct { image: IdRef, coordinate: IdRef, data: IdRef },2799 .OpHitObjectGetLSSPositionsNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2611 .OpSubgroupImageMediaBlockReadINTEL => struct { id_result_type: IdResultType, id_result: IdResult, image: IdRef, coordinate: IdRef, width: IdRef, height: IdRef },2800 .OpHitObjectGetLSSRadiiNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2612 .OpSubgroupImageMediaBlockWriteINTEL => struct { image: IdRef, coordinate: IdRef, width: IdRef, height: IdRef, data: IdRef },2801 .OpHitObjectIsSphereHitNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2613 .OpUCountLeadingZerosINTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2802 .OpHitObjectIsLSSHitNV => struct { id_result_type: Id, id_result: Id, hit_object: Id },
2614 .OpUCountTrailingZerosINTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand: IdRef },2803 .OpRayQueryIsSphereHitNV => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2615 .OpAbsISubINTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2804 .OpRayQueryIsLSSHitNV => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2616 .OpAbsUSubINTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2805 .OpSubgroupShuffleINTEL => struct { id_result_type: Id, id_result: Id, data: Id, invocation_id: Id },
2617 .OpIAddSatINTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2806 .OpSubgroupShuffleDownINTEL => struct { id_result_type: Id, id_result: Id, current: Id, next: Id, delta: Id },
2618 .OpUAddSatINTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2807 .OpSubgroupShuffleUpINTEL => struct { id_result_type: Id, id_result: Id, previous: Id, current: Id, delta: Id },
2619 .OpIAverageINTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2808 .OpSubgroupShuffleXorINTEL => struct { id_result_type: Id, id_result: Id, data: Id, value: Id },
2620 .OpUAverageINTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2809 .OpSubgroupBlockReadINTEL => struct { id_result_type: Id, id_result: Id, ptr: Id },
2621 .OpIAverageRoundedINTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2810 .OpSubgroupBlockWriteINTEL => struct { ptr: Id, data: Id },
2622 .OpUAverageRoundedINTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2811 .OpSubgroupImageBlockReadINTEL => struct { id_result_type: Id, id_result: Id, image: Id, coordinate: Id },
2623 .OpISubSatINTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2812 .OpSubgroupImageBlockWriteINTEL => struct { image: Id, coordinate: Id, data: Id },
2624 .OpUSubSatINTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2813 .OpSubgroupImageMediaBlockReadINTEL => struct { id_result_type: Id, id_result: Id, image: Id, coordinate: Id, width: Id, height: Id },
2625 .OpIMul32x16INTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2814 .OpSubgroupImageMediaBlockWriteINTEL => struct { image: Id, coordinate: Id, width: Id, height: Id, data: Id },
2626 .OpUMul32x16INTEL => struct { id_result_type: IdResultType, id_result: IdResult, operand_1: IdRef, operand_2: IdRef },2815 .OpUCountLeadingZerosINTEL => struct { id_result_type: Id, id_result: Id, operand: Id },
2627 .OpAtomicFMinEXT => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2816 .OpUCountTrailingZerosINTEL => struct { id_result_type: Id, id_result: Id, operand: Id },
2628 .OpAtomicFMaxEXT => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2817 .OpAbsISubINTEL => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2629 .OpAssumeTrueKHR => struct { condition: IdRef },2818 .OpAbsUSubINTEL => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2630 .OpExpectKHR => struct { id_result_type: IdResultType, id_result: IdResult, value: IdRef, expectedvalue: IdRef },2819 .OpIAddSatINTEL => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2631 .OpDecorateString => struct { target: IdRef, decoration: Decoration.Extended },2820 .OpUAddSatINTEL => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2632 .OpMemberDecorateString => struct { struct_type: IdRef, member: LiteralInteger, decoration: Decoration.Extended },2821 .OpIAverageINTEL => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2822 .OpUAverageINTEL => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2823 .OpIAverageRoundedINTEL => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2824 .OpUAverageRoundedINTEL => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2825 .OpISubSatINTEL => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2826 .OpUSubSatINTEL => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2827 .OpIMul32x16INTEL => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2828 .OpUMul32x16INTEL => struct { id_result_type: Id, id_result: Id, operand_1: Id, operand_2: Id },
2829 .OpAtomicFMinEXT => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id, value: Id },
2830 .OpAtomicFMaxEXT => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id, value: Id },
2831 .OpAssumeTrueKHR => struct { condition: Id },
2832 .OpExpectKHR => struct { id_result_type: Id, id_result: Id, value: Id, expected_value: Id },
2833 .OpDecorateString => struct { target: Id, decoration: Decoration.Extended },
2834 .OpMemberDecorateString => struct { struct_type: Id, member: LiteralInteger, decoration: Decoration.Extended },
2633 .OpLoopControlINTEL => struct { loop_control_parameters: []const LiteralInteger = &.{} },2835 .OpLoopControlINTEL => struct { loop_control_parameters: []const LiteralInteger = &.{} },
2634 .OpReadPipeBlockingINTEL => struct { id_result_type: IdResultType, id_result: IdResult, packet_size: IdRef, packet_alignment: IdRef },2836 .OpReadPipeBlockingINTEL => struct { id_result_type: Id, id_result: Id, packet_size: Id, packet_alignment: Id },
2635 .OpWritePipeBlockingINTEL => struct { id_result_type: IdResultType, id_result: IdResult, packet_size: IdRef, packet_alignment: IdRef },2837 .OpWritePipeBlockingINTEL => struct { id_result_type: Id, id_result: Id, packet_size: Id, packet_alignment: Id },
2636 .OpFPGARegINTEL => struct { id_result_type: IdResultType, id_result: IdResult, result: IdRef, input: IdRef },2838 .OpFPGARegINTEL => struct { id_result_type: Id, id_result: Id, input: Id },
2637 .OpRayQueryGetRayTMinKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef },2839 .OpRayQueryGetRayTMinKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id },
2638 .OpRayQueryGetRayFlagsKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef },2840 .OpRayQueryGetRayFlagsKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id },
2639 .OpRayQueryGetIntersectionTKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2841 .OpRayQueryGetIntersectionTKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2640 .OpRayQueryGetIntersectionInstanceCustomIndexKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2842 .OpRayQueryGetIntersectionInstanceCustomIndexKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2641 .OpRayQueryGetIntersectionInstanceIdKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2843 .OpRayQueryGetIntersectionInstanceIdKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2642 .OpRayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2844 .OpRayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2643 .OpRayQueryGetIntersectionGeometryIndexKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2845 .OpRayQueryGetIntersectionGeometryIndexKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2644 .OpRayQueryGetIntersectionPrimitiveIndexKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2846 .OpRayQueryGetIntersectionPrimitiveIndexKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2645 .OpRayQueryGetIntersectionBarycentricsKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2847 .OpRayQueryGetIntersectionBarycentricsKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2646 .OpRayQueryGetIntersectionFrontFaceKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2848 .OpRayQueryGetIntersectionFrontFaceKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2647 .OpRayQueryGetIntersectionCandidateAABBOpaqueKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef },2849 .OpRayQueryGetIntersectionCandidateAABBOpaqueKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id },
2648 .OpRayQueryGetIntersectionObjectRayDirectionKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2850 .OpRayQueryGetIntersectionObjectRayDirectionKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2649 .OpRayQueryGetIntersectionObjectRayOriginKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2851 .OpRayQueryGetIntersectionObjectRayOriginKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2650 .OpRayQueryGetWorldRayDirectionKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef },2852 .OpRayQueryGetWorldRayDirectionKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id },
2651 .OpRayQueryGetWorldRayOriginKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef },2853 .OpRayQueryGetWorldRayOriginKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id },
2652 .OpRayQueryGetIntersectionObjectToWorldKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2854 .OpRayQueryGetIntersectionObjectToWorldKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2653 .OpRayQueryGetIntersectionWorldToObjectKHR => struct { id_result_type: IdResultType, id_result: IdResult, rayquery: IdRef, intersection: IdRef },2855 .OpRayQueryGetIntersectionWorldToObjectKHR => struct { id_result_type: Id, id_result: Id, ray_query: Id, intersection: Id },
2654 .OpAtomicFAddEXT => struct { id_result_type: IdResultType, id_result: IdResult, pointer: IdRef, memory: IdScope, semantics: IdMemorySemantics, value: IdRef },2856 .OpAtomicFAddEXT => struct { id_result_type: Id, id_result: Id, pointer: Id, memory: Id, semantics: Id, value: Id },
2655 .OpTypeBufferSurfaceINTEL => struct { id_result: IdResult, accessqualifier: AccessQualifier },2857 .OpTypeBufferSurfaceINTEL => struct { id_result: Id, access_qualifier: AccessQualifier },
2656 .OpTypeStructContinuedINTEL => struct { id_ref: []const IdRef = &.{} },2858 .OpTypeStructContinuedINTEL => struct { id_ref: []const Id = &.{} },
2657 .OpConstantCompositeContinuedINTEL => struct { constituents: []const IdRef = &.{} },2859 .OpConstantCompositeContinuedINTEL => struct { constituents: []const Id = &.{} },
2658 .OpSpecConstantCompositeContinuedINTEL => struct { constituents: []const IdRef = &.{} },2860 .OpSpecConstantCompositeContinuedINTEL => struct { constituents: []const Id = &.{} },
2659 .OpCompositeConstructContinuedINTEL => struct { id_result_type: IdResultType, id_result: IdResult, constituents: []const IdRef = &.{} },2861 .OpCompositeConstructContinuedINTEL => struct { id_result_type: Id, id_result: Id, constituents: []const Id = &.{} },
2660 .OpConvertFToBF16INTEL => struct { id_result_type: IdResultType, id_result: IdResult, float_value: IdRef },2862 .OpConvertFToBF16INTEL => struct { id_result_type: Id, id_result: Id, float_value: Id },
2661 .OpConvertBF16ToFINTEL => struct { id_result_type: IdResultType, id_result: IdResult, bfloat16_value: IdRef },2863 .OpConvertBF16ToFINTEL => struct { id_result_type: Id, id_result: Id, b_float16_value: Id },
2662 .OpControlBarrierArriveINTEL => struct { execution: IdScope, memory: IdScope, semantics: IdMemorySemantics },2864 .OpControlBarrierArriveINTEL => struct { execution: Id, memory: Id, semantics: Id },
2663 .OpControlBarrierWaitINTEL => struct { execution: IdScope, memory: IdScope, semantics: IdMemorySemantics },2865 .OpControlBarrierWaitINTEL => struct { execution: Id, memory: Id, semantics: Id },
2664 .OpGroupIMulKHR => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2866 .OpArithmeticFenceEXT => struct { id_result_type: Id, id_result: Id, target: Id },
2665 .OpGroupFMulKHR => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2867 .OpTaskSequenceCreateINTEL => struct { id_result_type: Id, id_result: Id, function: Id, pipelined: LiteralInteger, use_stall_enable_clusters: LiteralInteger, get_capacity: LiteralInteger, async_capacity: LiteralInteger },
2666 .OpGroupBitwiseAndKHR => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2868 .OpTaskSequenceAsyncINTEL => struct { sequence: Id, arguments: []const Id = &.{} },
2667 .OpGroupBitwiseOrKHR => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2869 .OpTaskSequenceGetINTEL => struct { id_result_type: Id, id_result: Id, sequence: Id },
2668 .OpGroupBitwiseXorKHR => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2870 .OpTaskSequenceReleaseINTEL => struct { sequence: Id },
2669 .OpGroupLogicalAndKHR => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2871 .OpTypeTaskSequenceINTEL => struct { id_result: Id },
2670 .OpGroupLogicalOrKHR => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2872 .OpSubgroupBlockPrefetchINTEL => struct { ptr: Id, num_bytes: Id, memory_access: ?MemoryAccess.Extended = null },
2671 .OpGroupLogicalXorKHR => struct { id_result_type: IdResultType, id_result: IdResult, execution: IdScope, operation: GroupOperation, x: IdRef },2873 .OpSubgroup2DBlockLoadINTEL => struct { element_size: Id, block_width: Id, block_height: Id, block_count: Id, src_base_pointer: Id, memory_width: Id, memory_height: Id, memory_pitch: Id, coordinate: Id, dst_pointer: Id },
2672 .OpMaskedGatherINTEL => struct { id_result_type: IdResultType, id_result: IdResult, ptrvector: IdRef, alignment: LiteralInteger, mask: IdRef, fillempty: IdRef },2874 .OpSubgroup2DBlockLoadTransformINTEL => struct { element_size: Id, block_width: Id, block_height: Id, block_count: Id, src_base_pointer: Id, memory_width: Id, memory_height: Id, memory_pitch: Id, coordinate: Id, dst_pointer: Id },
2673 .OpMaskedScatterINTEL => struct { inputvector: IdRef, ptrvector: IdRef, alignment: LiteralInteger, mask: IdRef },2875 .OpSubgroup2DBlockLoadTransposeINTEL => struct { element_size: Id, block_width: Id, block_height: Id, block_count: Id, src_base_pointer: Id, memory_width: Id, memory_height: Id, memory_pitch: Id, coordinate: Id, dst_pointer: Id },
2876 .OpSubgroup2DBlockPrefetchINTEL => struct { element_size: Id, block_width: Id, block_height: Id, block_count: Id, src_base_pointer: Id, memory_width: Id, memory_height: Id, memory_pitch: Id, coordinate: Id },
2877 .OpSubgroup2DBlockStoreINTEL => struct { element_size: Id, block_width: Id, block_height: Id, block_count: Id, src_pointer: Id, dst_base_pointer: Id, memory_width: Id, memory_height: Id, memory_pitch: Id, coordinate: Id },
2878 .OpSubgroupMatrixMultiplyAccumulateINTEL => struct { id_result_type: Id, id_result: Id, k_dim: Id, matrix_a: Id, matrix_b: Id, matrix_c: Id, matrix_multiply_accumulate_operands: ?MatrixMultiplyAccumulateOperands = null },
2879 .OpBitwiseFunctionINTEL => struct { id_result_type: Id, id_result: Id, a: Id, b: Id, c: Id, lut_index: Id },
2880 .OpGroupIMulKHR => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2881 .OpGroupFMulKHR => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2882 .OpGroupBitwiseAndKHR => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2883 .OpGroupBitwiseOrKHR => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2884 .OpGroupBitwiseXorKHR => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2885 .OpGroupLogicalAndKHR => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2886 .OpGroupLogicalOrKHR => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2887 .OpGroupLogicalXorKHR => struct { id_result_type: Id, id_result: Id, execution: Id, operation: GroupOperation, x: Id },
2888 .OpRoundFToTF32INTEL => struct { id_result_type: Id, id_result: Id, float_value: Id },
2889 .OpMaskedGatherINTEL => struct { id_result_type: Id, id_result: Id, ptr_vector: Id, alignment: LiteralInteger, mask: Id, fill_empty: Id },
2890 .OpMaskedScatterINTEL => struct { input_vector: Id, ptr_vector: Id, alignment: LiteralInteger, mask: Id },
2891 .OpConvertHandleToImageINTEL => struct { id_result_type: Id, id_result: Id, operand: Id },
2892 .OpConvertHandleToSamplerINTEL => struct { id_result_type: Id, id_result: Id, operand: Id },
2893 .OpConvertHandleToSampledImageINTEL => struct { id_result_type: Id, id_result: Id, operand: Id },
2674 };2894 };
2675 }2895 }
2676 pub fn class(self: Opcode) Class {2896 pub fn class(self: Opcode) Class {
2677 return switch (self) {2897 return switch (self) {
2678 .OpNop => .Miscellaneous,2898 .OpNop => .miscellaneous,
2679 .OpUndef => .Miscellaneous,2899 .OpUndef => .miscellaneous,
2680 .OpSourceContinued => .Debug,2900 .OpSourceContinued => .debug,
2681 .OpSource => .Debug,2901 .OpSource => .debug,
2682 .OpSourceExtension => .Debug,2902 .OpSourceExtension => .debug,
2683 .OpName => .Debug,2903 .OpName => .debug,
2684 .OpMemberName => .Debug,2904 .OpMemberName => .debug,
2685 .OpString => .Debug,2905 .OpString => .debug,
2686 .OpLine => .Debug,2906 .OpLine => .debug,
2687 .OpExtension => .Extension,2907 .OpExtension => .extension,
2688 .OpExtInstImport => .Extension,2908 .OpExtInstImport => .extension,
2689 .OpExtInst => .Extension,2909 .OpExtInst => .extension,
2690 .OpMemoryModel => .ModeSetting,2910 .OpMemoryModel => .mode_setting,
2691 .OpEntryPoint => .ModeSetting,2911 .OpEntryPoint => .mode_setting,
2692 .OpExecutionMode => .ModeSetting,2912 .OpExecutionMode => .mode_setting,
2693 .OpCapability => .ModeSetting,2913 .OpCapability => .mode_setting,
2694 .OpTypeVoid => .TypeDeclaration,2914 .OpTypeVoid => .type_declaration,
2695 .OpTypeBool => .TypeDeclaration,2915 .OpTypeBool => .type_declaration,
2696 .OpTypeInt => .TypeDeclaration,2916 .OpTypeInt => .type_declaration,
2697 .OpTypeFloat => .TypeDeclaration,2917 .OpTypeFloat => .type_declaration,
2698 .OpTypeVector => .TypeDeclaration,2918 .OpTypeVector => .type_declaration,
2699 .OpTypeMatrix => .TypeDeclaration,2919 .OpTypeMatrix => .type_declaration,
2700 .OpTypeImage => .TypeDeclaration,2920 .OpTypeImage => .type_declaration,
2701 .OpTypeSampler => .TypeDeclaration,2921 .OpTypeSampler => .type_declaration,
2702 .OpTypeSampledImage => .TypeDeclaration,2922 .OpTypeSampledImage => .type_declaration,
2703 .OpTypeArray => .TypeDeclaration,2923 .OpTypeArray => .type_declaration,
2704 .OpTypeRuntimeArray => .TypeDeclaration,2924 .OpTypeRuntimeArray => .type_declaration,
2705 .OpTypeStruct => .TypeDeclaration,2925 .OpTypeStruct => .type_declaration,
2706 .OpTypeOpaque => .TypeDeclaration,2926 .OpTypeOpaque => .type_declaration,
2707 .OpTypePointer => .TypeDeclaration,2927 .OpTypePointer => .type_declaration,
2708 .OpTypeFunction => .TypeDeclaration,2928 .OpTypeFunction => .type_declaration,
2709 .OpTypeEvent => .TypeDeclaration,2929 .OpTypeEvent => .type_declaration,
2710 .OpTypeDeviceEvent => .TypeDeclaration,2930 .OpTypeDeviceEvent => .type_declaration,
2711 .OpTypeReserveId => .TypeDeclaration,2931 .OpTypeReserveId => .type_declaration,
2712 .OpTypeQueue => .TypeDeclaration,2932 .OpTypeQueue => .type_declaration,
2713 .OpTypePipe => .TypeDeclaration,2933 .OpTypePipe => .type_declaration,
2714 .OpTypeForwardPointer => .TypeDeclaration,2934 .OpTypeForwardPointer => .type_declaration,
2715 .OpConstantTrue => .ConstantCreation,2935 .OpConstantTrue => .constant_creation,
2716 .OpConstantFalse => .ConstantCreation,2936 .OpConstantFalse => .constant_creation,
2717 .OpConstant => .ConstantCreation,2937 .OpConstant => .constant_creation,
2718 .OpConstantComposite => .ConstantCreation,2938 .OpConstantComposite => .constant_creation,
2719 .OpConstantSampler => .ConstantCreation,2939 .OpConstantSampler => .constant_creation,
2720 .OpConstantNull => .ConstantCreation,2940 .OpConstantNull => .constant_creation,
2721 .OpSpecConstantTrue => .ConstantCreation,2941 .OpSpecConstantTrue => .constant_creation,
2722 .OpSpecConstantFalse => .ConstantCreation,2942 .OpSpecConstantFalse => .constant_creation,
2723 .OpSpecConstant => .ConstantCreation,2943 .OpSpecConstant => .constant_creation,
2724 .OpSpecConstantComposite => .ConstantCreation,2944 .OpSpecConstantComposite => .constant_creation,
2725 .OpSpecConstantOp => .ConstantCreation,2945 .OpSpecConstantOp => .constant_creation,
2726 .OpFunction => .Function,2946 .OpFunction => .function,
2727 .OpFunctionParameter => .Function,2947 .OpFunctionParameter => .function,
2728 .OpFunctionEnd => .Function,2948 .OpFunctionEnd => .function,
2729 .OpFunctionCall => .Function,2949 .OpFunctionCall => .function,
2730 .OpVariable => .Memory,2950 .OpVariable => .memory,
2731 .OpImageTexelPointer => .Memory,2951 .OpImageTexelPointer => .memory,
2732 .OpLoad => .Memory,2952 .OpLoad => .memory,
2733 .OpStore => .Memory,2953 .OpStore => .memory,
2734 .OpCopyMemory => .Memory,2954 .OpCopyMemory => .memory,
2735 .OpCopyMemorySized => .Memory,2955 .OpCopyMemorySized => .memory,
2736 .OpAccessChain => .Memory,2956 .OpAccessChain => .memory,
2737 .OpInBoundsAccessChain => .Memory,2957 .OpInBoundsAccessChain => .memory,
2738 .OpPtrAccessChain => .Memory,2958 .OpPtrAccessChain => .memory,
2739 .OpArrayLength => .Memory,2959 .OpArrayLength => .memory,
2740 .OpGenericPtrMemSemantics => .Memory,2960 .OpGenericPtrMemSemantics => .memory,
2741 .OpInBoundsPtrAccessChain => .Memory,2961 .OpInBoundsPtrAccessChain => .memory,
2742 .OpDecorate => .Annotation,2962 .OpDecorate => .annotation,
2743 .OpMemberDecorate => .Annotation,2963 .OpMemberDecorate => .annotation,
2744 .OpDecorationGroup => .Annotation,2964 .OpDecorationGroup => .annotation,
2745 .OpGroupDecorate => .Annotation,2965 .OpGroupDecorate => .annotation,
2746 .OpGroupMemberDecorate => .Annotation,2966 .OpGroupMemberDecorate => .annotation,
2747 .OpVectorExtractDynamic => .Composite,2967 .OpVectorExtractDynamic => .composite,
2748 .OpVectorInsertDynamic => .Composite,2968 .OpVectorInsertDynamic => .composite,
2749 .OpVectorShuffle => .Composite,2969 .OpVectorShuffle => .composite,
2750 .OpCompositeConstruct => .Composite,2970 .OpCompositeConstruct => .composite,
2751 .OpCompositeExtract => .Composite,2971 .OpCompositeExtract => .composite,
2752 .OpCompositeInsert => .Composite,2972 .OpCompositeInsert => .composite,
2753 .OpCopyObject => .Composite,2973 .OpCopyObject => .composite,
2754 .OpTranspose => .Composite,2974 .OpTranspose => .composite,
2755 .OpSampledImage => .Image,2975 .OpSampledImage => .image,
2756 .OpImageSampleImplicitLod => .Image,2976 .OpImageSampleImplicitLod => .image,
2757 .OpImageSampleExplicitLod => .Image,2977 .OpImageSampleExplicitLod => .image,
2758 .OpImageSampleDrefImplicitLod => .Image,2978 .OpImageSampleDrefImplicitLod => .image,
2759 .OpImageSampleDrefExplicitLod => .Image,2979 .OpImageSampleDrefExplicitLod => .image,
2760 .OpImageSampleProjImplicitLod => .Image,2980 .OpImageSampleProjImplicitLod => .image,
2761 .OpImageSampleProjExplicitLod => .Image,2981 .OpImageSampleProjExplicitLod => .image,
2762 .OpImageSampleProjDrefImplicitLod => .Image,2982 .OpImageSampleProjDrefImplicitLod => .image,
2763 .OpImageSampleProjDrefExplicitLod => .Image,2983 .OpImageSampleProjDrefExplicitLod => .image,
2764 .OpImageFetch => .Image,2984 .OpImageFetch => .image,
2765 .OpImageGather => .Image,2985 .OpImageGather => .image,
2766 .OpImageDrefGather => .Image,2986 .OpImageDrefGather => .image,
2767 .OpImageRead => .Image,2987 .OpImageRead => .image,
2768 .OpImageWrite => .Image,2988 .OpImageWrite => .image,
2769 .OpImage => .Image,2989 .OpImage => .image,
2770 .OpImageQueryFormat => .Image,2990 .OpImageQueryFormat => .image,
2771 .OpImageQueryOrder => .Image,2991 .OpImageQueryOrder => .image,
2772 .OpImageQuerySizeLod => .Image,2992 .OpImageQuerySizeLod => .image,
2773 .OpImageQuerySize => .Image,2993 .OpImageQuerySize => .image,
2774 .OpImageQueryLod => .Image,2994 .OpImageQueryLod => .image,
2775 .OpImageQueryLevels => .Image,2995 .OpImageQueryLevels => .image,
2776 .OpImageQuerySamples => .Image,2996 .OpImageQuerySamples => .image,
2777 .OpConvertFToU => .Conversion,2997 .OpConvertFToU => .conversion,
2778 .OpConvertFToS => .Conversion,2998 .OpConvertFToS => .conversion,
2779 .OpConvertSToF => .Conversion,2999 .OpConvertSToF => .conversion,
2780 .OpConvertUToF => .Conversion,3000 .OpConvertUToF => .conversion,
2781 .OpUConvert => .Conversion,3001 .OpUConvert => .conversion,
2782 .OpSConvert => .Conversion,3002 .OpSConvert => .conversion,
2783 .OpFConvert => .Conversion,3003 .OpFConvert => .conversion,
2784 .OpQuantizeToF16 => .Conversion,3004 .OpQuantizeToF16 => .conversion,
2785 .OpConvertPtrToU => .Conversion,3005 .OpConvertPtrToU => .conversion,
2786 .OpSatConvertSToU => .Conversion,3006 .OpSatConvertSToU => .conversion,
2787 .OpSatConvertUToS => .Conversion,3007 .OpSatConvertUToS => .conversion,
2788 .OpConvertUToPtr => .Conversion,3008 .OpConvertUToPtr => .conversion,
2789 .OpPtrCastToGeneric => .Conversion,3009 .OpPtrCastToGeneric => .conversion,
2790 .OpGenericCastToPtr => .Conversion,3010 .OpGenericCastToPtr => .conversion,
2791 .OpGenericCastToPtrExplicit => .Conversion,3011 .OpGenericCastToPtrExplicit => .conversion,
2792 .OpBitcast => .Conversion,3012 .OpBitcast => .conversion,
2793 .OpSNegate => .Arithmetic,3013 .OpSNegate => .arithmetic,
2794 .OpFNegate => .Arithmetic,3014 .OpFNegate => .arithmetic,
2795 .OpIAdd => .Arithmetic,3015 .OpIAdd => .arithmetic,
2796 .OpFAdd => .Arithmetic,3016 .OpFAdd => .arithmetic,
2797 .OpISub => .Arithmetic,3017 .OpISub => .arithmetic,
2798 .OpFSub => .Arithmetic,3018 .OpFSub => .arithmetic,
2799 .OpIMul => .Arithmetic,3019 .OpIMul => .arithmetic,
2800 .OpFMul => .Arithmetic,3020 .OpFMul => .arithmetic,
2801 .OpUDiv => .Arithmetic,3021 .OpUDiv => .arithmetic,
2802 .OpSDiv => .Arithmetic,3022 .OpSDiv => .arithmetic,
2803 .OpFDiv => .Arithmetic,3023 .OpFDiv => .arithmetic,
2804 .OpUMod => .Arithmetic,3024 .OpUMod => .arithmetic,
2805 .OpSRem => .Arithmetic,3025 .OpSRem => .arithmetic,
2806 .OpSMod => .Arithmetic,3026 .OpSMod => .arithmetic,
2807 .OpFRem => .Arithmetic,3027 .OpFRem => .arithmetic,
2808 .OpFMod => .Arithmetic,3028 .OpFMod => .arithmetic,
2809 .OpVectorTimesScalar => .Arithmetic,3029 .OpVectorTimesScalar => .arithmetic,
2810 .OpMatrixTimesScalar => .Arithmetic,3030 .OpMatrixTimesScalar => .arithmetic,
2811 .OpVectorTimesMatrix => .Arithmetic,3031 .OpVectorTimesMatrix => .arithmetic,
2812 .OpMatrixTimesVector => .Arithmetic,3032 .OpMatrixTimesVector => .arithmetic,
2813 .OpMatrixTimesMatrix => .Arithmetic,3033 .OpMatrixTimesMatrix => .arithmetic,
2814 .OpOuterProduct => .Arithmetic,3034 .OpOuterProduct => .arithmetic,
2815 .OpDot => .Arithmetic,3035 .OpDot => .arithmetic,
2816 .OpIAddCarry => .Arithmetic,3036 .OpIAddCarry => .arithmetic,
2817 .OpISubBorrow => .Arithmetic,3037 .OpISubBorrow => .arithmetic,
2818 .OpUMulExtended => .Arithmetic,3038 .OpUMulExtended => .arithmetic,
2819 .OpSMulExtended => .Arithmetic,3039 .OpSMulExtended => .arithmetic,
2820 .OpAny => .RelationalAndLogical,3040 .OpAny => .relational_and_logical,
2821 .OpAll => .RelationalAndLogical,3041 .OpAll => .relational_and_logical,
2822 .OpIsNan => .RelationalAndLogical,3042 .OpIsNan => .relational_and_logical,
2823 .OpIsInf => .RelationalAndLogical,3043 .OpIsInf => .relational_and_logical,
2824 .OpIsFinite => .RelationalAndLogical,3044 .OpIsFinite => .relational_and_logical,
2825 .OpIsNormal => .RelationalAndLogical,3045 .OpIsNormal => .relational_and_logical,
2826 .OpSignBitSet => .RelationalAndLogical,3046 .OpSignBitSet => .relational_and_logical,
2827 .OpLessOrGreater => .RelationalAndLogical,3047 .OpLessOrGreater => .relational_and_logical,
2828 .OpOrdered => .RelationalAndLogical,3048 .OpOrdered => .relational_and_logical,
2829 .OpUnordered => .RelationalAndLogical,3049 .OpUnordered => .relational_and_logical,
2830 .OpLogicalEqual => .RelationalAndLogical,3050 .OpLogicalEqual => .relational_and_logical,
2831 .OpLogicalNotEqual => .RelationalAndLogical,3051 .OpLogicalNotEqual => .relational_and_logical,
2832 .OpLogicalOr => .RelationalAndLogical,3052 .OpLogicalOr => .relational_and_logical,
2833 .OpLogicalAnd => .RelationalAndLogical,3053 .OpLogicalAnd => .relational_and_logical,
2834 .OpLogicalNot => .RelationalAndLogical,3054 .OpLogicalNot => .relational_and_logical,
2835 .OpSelect => .RelationalAndLogical,3055 .OpSelect => .relational_and_logical,
2836 .OpIEqual => .RelationalAndLogical,3056 .OpIEqual => .relational_and_logical,
2837 .OpINotEqual => .RelationalAndLogical,3057 .OpINotEqual => .relational_and_logical,
2838 .OpUGreaterThan => .RelationalAndLogical,3058 .OpUGreaterThan => .relational_and_logical,
2839 .OpSGreaterThan => .RelationalAndLogical,3059 .OpSGreaterThan => .relational_and_logical,
2840 .OpUGreaterThanEqual => .RelationalAndLogical,3060 .OpUGreaterThanEqual => .relational_and_logical,
2841 .OpSGreaterThanEqual => .RelationalAndLogical,3061 .OpSGreaterThanEqual => .relational_and_logical,
2842 .OpULessThan => .RelationalAndLogical,3062 .OpULessThan => .relational_and_logical,
2843 .OpSLessThan => .RelationalAndLogical,3063 .OpSLessThan => .relational_and_logical,
2844 .OpULessThanEqual => .RelationalAndLogical,3064 .OpULessThanEqual => .relational_and_logical,
2845 .OpSLessThanEqual => .RelationalAndLogical,3065 .OpSLessThanEqual => .relational_and_logical,
2846 .OpFOrdEqual => .RelationalAndLogical,3066 .OpFOrdEqual => .relational_and_logical,
2847 .OpFUnordEqual => .RelationalAndLogical,3067 .OpFUnordEqual => .relational_and_logical,
2848 .OpFOrdNotEqual => .RelationalAndLogical,3068 .OpFOrdNotEqual => .relational_and_logical,
2849 .OpFUnordNotEqual => .RelationalAndLogical,3069 .OpFUnordNotEqual => .relational_and_logical,
2850 .OpFOrdLessThan => .RelationalAndLogical,3070 .OpFOrdLessThan => .relational_and_logical,
2851 .OpFUnordLessThan => .RelationalAndLogical,3071 .OpFUnordLessThan => .relational_and_logical,
2852 .OpFOrdGreaterThan => .RelationalAndLogical,3072 .OpFOrdGreaterThan => .relational_and_logical,
2853 .OpFUnordGreaterThan => .RelationalAndLogical,3073 .OpFUnordGreaterThan => .relational_and_logical,
2854 .OpFOrdLessThanEqual => .RelationalAndLogical,3074 .OpFOrdLessThanEqual => .relational_and_logical,
2855 .OpFUnordLessThanEqual => .RelationalAndLogical,3075 .OpFUnordLessThanEqual => .relational_and_logical,
2856 .OpFOrdGreaterThanEqual => .RelationalAndLogical,3076 .OpFOrdGreaterThanEqual => .relational_and_logical,
2857 .OpFUnordGreaterThanEqual => .RelationalAndLogical,3077 .OpFUnordGreaterThanEqual => .relational_and_logical,
2858 .OpShiftRightLogical => .Bit,3078 .OpShiftRightLogical => .bit,
2859 .OpShiftRightArithmetic => .Bit,3079 .OpShiftRightArithmetic => .bit,
2860 .OpShiftLeftLogical => .Bit,3080 .OpShiftLeftLogical => .bit,
2861 .OpBitwiseOr => .Bit,3081 .OpBitwiseOr => .bit,
2862 .OpBitwiseXor => .Bit,3082 .OpBitwiseXor => .bit,
2863 .OpBitwiseAnd => .Bit,3083 .OpBitwiseAnd => .bit,
2864 .OpNot => .Bit,3084 .OpNot => .bit,
2865 .OpBitFieldInsert => .Bit,3085 .OpBitFieldInsert => .bit,
2866 .OpBitFieldSExtract => .Bit,3086 .OpBitFieldSExtract => .bit,
2867 .OpBitFieldUExtract => .Bit,3087 .OpBitFieldUExtract => .bit,
2868 .OpBitReverse => .Bit,3088 .OpBitReverse => .bit,
2869 .OpBitCount => .Bit,3089 .OpBitCount => .bit,
2870 .OpDPdx => .Derivative,3090 .OpDPdx => .derivative,
2871 .OpDPdy => .Derivative,3091 .OpDPdy => .derivative,
2872 .OpFwidth => .Derivative,3092 .OpFwidth => .derivative,
2873 .OpDPdxFine => .Derivative,3093 .OpDPdxFine => .derivative,
2874 .OpDPdyFine => .Derivative,3094 .OpDPdyFine => .derivative,
2875 .OpFwidthFine => .Derivative,3095 .OpFwidthFine => .derivative,
2876 .OpDPdxCoarse => .Derivative,3096 .OpDPdxCoarse => .derivative,
2877 .OpDPdyCoarse => .Derivative,3097 .OpDPdyCoarse => .derivative,
2878 .OpFwidthCoarse => .Derivative,3098 .OpFwidthCoarse => .derivative,
2879 .OpEmitVertex => .Primitive,3099 .OpEmitVertex => .primitive,
2880 .OpEndPrimitive => .Primitive,3100 .OpEndPrimitive => .primitive,
2881 .OpEmitStreamVertex => .Primitive,3101 .OpEmitStreamVertex => .primitive,
2882 .OpEndStreamPrimitive => .Primitive,3102 .OpEndStreamPrimitive => .primitive,
2883 .OpControlBarrier => .Barrier,3103 .OpControlBarrier => .barrier,
2884 .OpMemoryBarrier => .Barrier,3104 .OpMemoryBarrier => .barrier,
2885 .OpAtomicLoad => .Atomic,3105 .OpAtomicLoad => .atomic,
2886 .OpAtomicStore => .Atomic,3106 .OpAtomicStore => .atomic,
2887 .OpAtomicExchange => .Atomic,3107 .OpAtomicExchange => .atomic,
2888 .OpAtomicCompareExchange => .Atomic,3108 .OpAtomicCompareExchange => .atomic,
2889 .OpAtomicCompareExchangeWeak => .Atomic,3109 .OpAtomicCompareExchangeWeak => .atomic,
2890 .OpAtomicIIncrement => .Atomic,3110 .OpAtomicIIncrement => .atomic,
2891 .OpAtomicIDecrement => .Atomic,3111 .OpAtomicIDecrement => .atomic,
2892 .OpAtomicIAdd => .Atomic,3112 .OpAtomicIAdd => .atomic,
2893 .OpAtomicISub => .Atomic,3113 .OpAtomicISub => .atomic,
2894 .OpAtomicSMin => .Atomic,3114 .OpAtomicSMin => .atomic,
2895 .OpAtomicUMin => .Atomic,3115 .OpAtomicUMin => .atomic,
2896 .OpAtomicSMax => .Atomic,3116 .OpAtomicSMax => .atomic,
2897 .OpAtomicUMax => .Atomic,3117 .OpAtomicUMax => .atomic,
2898 .OpAtomicAnd => .Atomic,3118 .OpAtomicAnd => .atomic,
2899 .OpAtomicOr => .Atomic,3119 .OpAtomicOr => .atomic,
2900 .OpAtomicXor => .Atomic,3120 .OpAtomicXor => .atomic,
2901 .OpPhi => .ControlFlow,3121 .OpPhi => .control_flow,
2902 .OpLoopMerge => .ControlFlow,3122 .OpLoopMerge => .control_flow,
2903 .OpSelectionMerge => .ControlFlow,3123 .OpSelectionMerge => .control_flow,
2904 .OpLabel => .ControlFlow,3124 .OpLabel => .control_flow,
2905 .OpBranch => .ControlFlow,3125 .OpBranch => .control_flow,
2906 .OpBranchConditional => .ControlFlow,3126 .OpBranchConditional => .control_flow,
2907 .OpSwitch => .ControlFlow,3127 .OpSwitch => .control_flow,
2908 .OpKill => .ControlFlow,3128 .OpKill => .control_flow,
2909 .OpReturn => .ControlFlow,3129 .OpReturn => .control_flow,
2910 .OpReturnValue => .ControlFlow,3130 .OpReturnValue => .control_flow,
2911 .OpUnreachable => .ControlFlow,3131 .OpUnreachable => .control_flow,
2912 .OpLifetimeStart => .ControlFlow,3132 .OpLifetimeStart => .control_flow,
2913 .OpLifetimeStop => .ControlFlow,3133 .OpLifetimeStop => .control_flow,
2914 .OpGroupAsyncCopy => .Group,3134 .OpGroupAsyncCopy => .group,
2915 .OpGroupWaitEvents => .Group,3135 .OpGroupWaitEvents => .group,
2916 .OpGroupAll => .Group,3136 .OpGroupAll => .group,
2917 .OpGroupAny => .Group,3137 .OpGroupAny => .group,
2918 .OpGroupBroadcast => .Group,3138 .OpGroupBroadcast => .group,
2919 .OpGroupIAdd => .Group,3139 .OpGroupIAdd => .group,
2920 .OpGroupFAdd => .Group,3140 .OpGroupFAdd => .group,
2921 .OpGroupFMin => .Group,3141 .OpGroupFMin => .group,
2922 .OpGroupUMin => .Group,3142 .OpGroupUMin => .group,
2923 .OpGroupSMin => .Group,3143 .OpGroupSMin => .group,
2924 .OpGroupFMax => .Group,3144 .OpGroupFMax => .group,
2925 .OpGroupUMax => .Group,3145 .OpGroupUMax => .group,
2926 .OpGroupSMax => .Group,3146 .OpGroupSMax => .group,
2927 .OpReadPipe => .Pipe,3147 .OpReadPipe => .pipe,
2928 .OpWritePipe => .Pipe,3148 .OpWritePipe => .pipe,
2929 .OpReservedReadPipe => .Pipe,3149 .OpReservedReadPipe => .pipe,
2930 .OpReservedWritePipe => .Pipe,3150 .OpReservedWritePipe => .pipe,
2931 .OpReserveReadPipePackets => .Pipe,3151 .OpReserveReadPipePackets => .pipe,
2932 .OpReserveWritePipePackets => .Pipe,3152 .OpReserveWritePipePackets => .pipe,
2933 .OpCommitReadPipe => .Pipe,3153 .OpCommitReadPipe => .pipe,
2934 .OpCommitWritePipe => .Pipe,3154 .OpCommitWritePipe => .pipe,
2935 .OpIsValidReserveId => .Pipe,3155 .OpIsValidReserveId => .pipe,
2936 .OpGetNumPipePackets => .Pipe,3156 .OpGetNumPipePackets => .pipe,
2937 .OpGetMaxPipePackets => .Pipe,3157 .OpGetMaxPipePackets => .pipe,
2938 .OpGroupReserveReadPipePackets => .Pipe,3158 .OpGroupReserveReadPipePackets => .pipe,
2939 .OpGroupReserveWritePipePackets => .Pipe,3159 .OpGroupReserveWritePipePackets => .pipe,
2940 .OpGroupCommitReadPipe => .Pipe,3160 .OpGroupCommitReadPipe => .pipe,
2941 .OpGroupCommitWritePipe => .Pipe,3161 .OpGroupCommitWritePipe => .pipe,
2942 .OpEnqueueMarker => .DeviceSideEnqueue,3162 .OpEnqueueMarker => .device_side_enqueue,
2943 .OpEnqueueKernel => .DeviceSideEnqueue,3163 .OpEnqueueKernel => .device_side_enqueue,
2944 .OpGetKernelNDrangeSubGroupCount => .DeviceSideEnqueue,3164 .OpGetKernelNDrangeSubGroupCount => .device_side_enqueue,
2945 .OpGetKernelNDrangeMaxSubGroupSize => .DeviceSideEnqueue,3165 .OpGetKernelNDrangeMaxSubGroupSize => .device_side_enqueue,
2946 .OpGetKernelWorkGroupSize => .DeviceSideEnqueue,3166 .OpGetKernelWorkGroupSize => .device_side_enqueue,
2947 .OpGetKernelPreferredWorkGroupSizeMultiple => .DeviceSideEnqueue,3167 .OpGetKernelPreferredWorkGroupSizeMultiple => .device_side_enqueue,
2948 .OpRetainEvent => .DeviceSideEnqueue,3168 .OpRetainEvent => .device_side_enqueue,
2949 .OpReleaseEvent => .DeviceSideEnqueue,3169 .OpReleaseEvent => .device_side_enqueue,
2950 .OpCreateUserEvent => .DeviceSideEnqueue,3170 .OpCreateUserEvent => .device_side_enqueue,
2951 .OpIsValidEvent => .DeviceSideEnqueue,3171 .OpIsValidEvent => .device_side_enqueue,
2952 .OpSetUserEventStatus => .DeviceSideEnqueue,3172 .OpSetUserEventStatus => .device_side_enqueue,
2953 .OpCaptureEventProfilingInfo => .DeviceSideEnqueue,3173 .OpCaptureEventProfilingInfo => .device_side_enqueue,
2954 .OpGetDefaultQueue => .DeviceSideEnqueue,3174 .OpGetDefaultQueue => .device_side_enqueue,
2955 .OpBuildNDRange => .DeviceSideEnqueue,3175 .OpBuildNDRange => .device_side_enqueue,
2956 .OpImageSparseSampleImplicitLod => .Image,3176 .OpImageSparseSampleImplicitLod => .image,
2957 .OpImageSparseSampleExplicitLod => .Image,3177 .OpImageSparseSampleExplicitLod => .image,
2958 .OpImageSparseSampleDrefImplicitLod => .Image,3178 .OpImageSparseSampleDrefImplicitLod => .image,
2959 .OpImageSparseSampleDrefExplicitLod => .Image,3179 .OpImageSparseSampleDrefExplicitLod => .image,
2960 .OpImageSparseSampleProjImplicitLod => .Image,3180 .OpImageSparseSampleProjImplicitLod => .image,
2961 .OpImageSparseSampleProjExplicitLod => .Image,3181 .OpImageSparseSampleProjExplicitLod => .image,
2962 .OpImageSparseSampleProjDrefImplicitLod => .Image,3182 .OpImageSparseSampleProjDrefImplicitLod => .image,
2963 .OpImageSparseSampleProjDrefExplicitLod => .Image,3183 .OpImageSparseSampleProjDrefExplicitLod => .image,
2964 .OpImageSparseFetch => .Image,3184 .OpImageSparseFetch => .image,
2965 .OpImageSparseGather => .Image,3185 .OpImageSparseGather => .image,
2966 .OpImageSparseDrefGather => .Image,3186 .OpImageSparseDrefGather => .image,
2967 .OpImageSparseTexelsResident => .Image,3187 .OpImageSparseTexelsResident => .image,
2968 .OpNoLine => .Debug,3188 .OpNoLine => .debug,
2969 .OpAtomicFlagTestAndSet => .Atomic,3189 .OpAtomicFlagTestAndSet => .atomic,
2970 .OpAtomicFlagClear => .Atomic,3190 .OpAtomicFlagClear => .atomic,
2971 .OpImageSparseRead => .Image,3191 .OpImageSparseRead => .image,
2972 .OpSizeOf => .Miscellaneous,3192 .OpSizeOf => .miscellaneous,
2973 .OpTypePipeStorage => .TypeDeclaration,3193 .OpTypePipeStorage => .type_declaration,
2974 .OpConstantPipeStorage => .Pipe,3194 .OpConstantPipeStorage => .pipe,
2975 .OpCreatePipeFromPipeStorage => .Pipe,3195 .OpCreatePipeFromPipeStorage => .pipe,
2976 .OpGetKernelLocalSizeForSubgroupCount => .DeviceSideEnqueue,3196 .OpGetKernelLocalSizeForSubgroupCount => .device_side_enqueue,
2977 .OpGetKernelMaxNumSubgroups => .DeviceSideEnqueue,3197 .OpGetKernelMaxNumSubgroups => .device_side_enqueue,
2978 .OpTypeNamedBarrier => .TypeDeclaration,3198 .OpTypeNamedBarrier => .type_declaration,
2979 .OpNamedBarrierInitialize => .Barrier,3199 .OpNamedBarrierInitialize => .barrier,
2980 .OpMemoryNamedBarrier => .Barrier,3200 .OpMemoryNamedBarrier => .barrier,
2981 .OpModuleProcessed => .Debug,3201 .OpModuleProcessed => .debug,
2982 .OpExecutionModeId => .ModeSetting,3202 .OpExecutionModeId => .mode_setting,
2983 .OpDecorateId => .Annotation,3203 .OpDecorateId => .annotation,
2984 .OpGroupNonUniformElect => .NonUniform,3204 .OpGroupNonUniformElect => .non_uniform,
2985 .OpGroupNonUniformAll => .NonUniform,3205 .OpGroupNonUniformAll => .non_uniform,
2986 .OpGroupNonUniformAny => .NonUniform,3206 .OpGroupNonUniformAny => .non_uniform,
2987 .OpGroupNonUniformAllEqual => .NonUniform,3207 .OpGroupNonUniformAllEqual => .non_uniform,
2988 .OpGroupNonUniformBroadcast => .NonUniform,3208 .OpGroupNonUniformBroadcast => .non_uniform,
2989 .OpGroupNonUniformBroadcastFirst => .NonUniform,3209 .OpGroupNonUniformBroadcastFirst => .non_uniform,
2990 .OpGroupNonUniformBallot => .NonUniform,3210 .OpGroupNonUniformBallot => .non_uniform,
2991 .OpGroupNonUniformInverseBallot => .NonUniform,3211 .OpGroupNonUniformInverseBallot => .non_uniform,
2992 .OpGroupNonUniformBallotBitExtract => .NonUniform,3212 .OpGroupNonUniformBallotBitExtract => .non_uniform,
2993 .OpGroupNonUniformBallotBitCount => .NonUniform,3213 .OpGroupNonUniformBallotBitCount => .non_uniform,
2994 .OpGroupNonUniformBallotFindLSB => .NonUniform,3214 .OpGroupNonUniformBallotFindLSB => .non_uniform,
2995 .OpGroupNonUniformBallotFindMSB => .NonUniform,3215 .OpGroupNonUniformBallotFindMSB => .non_uniform,
2996 .OpGroupNonUniformShuffle => .NonUniform,3216 .OpGroupNonUniformShuffle => .non_uniform,
2997 .OpGroupNonUniformShuffleXor => .NonUniform,3217 .OpGroupNonUniformShuffleXor => .non_uniform,
2998 .OpGroupNonUniformShuffleUp => .NonUniform,3218 .OpGroupNonUniformShuffleUp => .non_uniform,
2999 .OpGroupNonUniformShuffleDown => .NonUniform,3219 .OpGroupNonUniformShuffleDown => .non_uniform,
3000 .OpGroupNonUniformIAdd => .NonUniform,3220 .OpGroupNonUniformIAdd => .non_uniform,
3001 .OpGroupNonUniformFAdd => .NonUniform,3221 .OpGroupNonUniformFAdd => .non_uniform,
3002 .OpGroupNonUniformIMul => .NonUniform,3222 .OpGroupNonUniformIMul => .non_uniform,
3003 .OpGroupNonUniformFMul => .NonUniform,3223 .OpGroupNonUniformFMul => .non_uniform,
3004 .OpGroupNonUniformSMin => .NonUniform,3224 .OpGroupNonUniformSMin => .non_uniform,
3005 .OpGroupNonUniformUMin => .NonUniform,3225 .OpGroupNonUniformUMin => .non_uniform,
3006 .OpGroupNonUniformFMin => .NonUniform,3226 .OpGroupNonUniformFMin => .non_uniform,
3007 .OpGroupNonUniformSMax => .NonUniform,3227 .OpGroupNonUniformSMax => .non_uniform,
3008 .OpGroupNonUniformUMax => .NonUniform,3228 .OpGroupNonUniformUMax => .non_uniform,
3009 .OpGroupNonUniformFMax => .NonUniform,3229 .OpGroupNonUniformFMax => .non_uniform,
3010 .OpGroupNonUniformBitwiseAnd => .NonUniform,3230 .OpGroupNonUniformBitwiseAnd => .non_uniform,
3011 .OpGroupNonUniformBitwiseOr => .NonUniform,3231 .OpGroupNonUniformBitwiseOr => .non_uniform,
3012 .OpGroupNonUniformBitwiseXor => .NonUniform,3232 .OpGroupNonUniformBitwiseXor => .non_uniform,
3013 .OpGroupNonUniformLogicalAnd => .NonUniform,3233 .OpGroupNonUniformLogicalAnd => .non_uniform,
3014 .OpGroupNonUniformLogicalOr => .NonUniform,3234 .OpGroupNonUniformLogicalOr => .non_uniform,
3015 .OpGroupNonUniformLogicalXor => .NonUniform,3235 .OpGroupNonUniformLogicalXor => .non_uniform,
3016 .OpGroupNonUniformQuadBroadcast => .NonUniform,3236 .OpGroupNonUniformQuadBroadcast => .non_uniform,
3017 .OpGroupNonUniformQuadSwap => .NonUniform,3237 .OpGroupNonUniformQuadSwap => .non_uniform,
3018 .OpCopyLogical => .Composite,3238 .OpCopyLogical => .composite,
3019 .OpPtrEqual => .Memory,3239 .OpPtrEqual => .memory,
3020 .OpPtrNotEqual => .Memory,3240 .OpPtrNotEqual => .memory,
3021 .OpPtrDiff => .Memory,3241 .OpPtrDiff => .memory,
3022 .OpColorAttachmentReadEXT => .Image,3242 .OpColorAttachmentReadEXT => .image,
3023 .OpDepthAttachmentReadEXT => .Image,3243 .OpDepthAttachmentReadEXT => .image,
3024 .OpStencilAttachmentReadEXT => .Image,3244 .OpStencilAttachmentReadEXT => .image,
3025 .OpTerminateInvocation => .ControlFlow,3245 .OpTypeTensorARM => .type_declaration,
3026 .OpSubgroupBallotKHR => .Group,3246 .OpTensorReadARM => .tensor,
3027 .OpSubgroupFirstInvocationKHR => .Group,3247 .OpTensorWriteARM => .tensor,
3028 .OpSubgroupAllKHR => .Group,3248 .OpTensorQuerySizeARM => .tensor,
3029 .OpSubgroupAnyKHR => .Group,3249 .OpGraphConstantARM => .graph,
3030 .OpSubgroupAllEqualKHR => .Group,3250 .OpGraphEntryPointARM => .graph,
3031 .OpGroupNonUniformRotateKHR => .Group,3251 .OpGraphARM => .graph,
3032 .OpSubgroupReadInvocationKHR => .Group,3252 .OpGraphInputARM => .graph,
3033 .OpTraceRayKHR => .Reserved,3253 .OpGraphSetOutputARM => .graph,
3034 .OpExecuteCallableKHR => .Reserved,3254 .OpGraphEndARM => .graph,
3035 .OpConvertUToAccelerationStructureKHR => .Reserved,3255 .OpTypeGraphARM => .type_declaration,
3036 .OpIgnoreIntersectionKHR => .Reserved,3256 .OpTerminateInvocation => .control_flow,
3037 .OpTerminateRayKHR => .Reserved,3257 .OpTypeUntypedPointerKHR => .type_declaration,
3038 .OpSDot => .Arithmetic,3258 .OpUntypedVariableKHR => .memory,
3039 .OpUDot => .Arithmetic,3259 .OpUntypedAccessChainKHR => .memory,
3040 .OpSUDot => .Arithmetic,3260 .OpUntypedInBoundsAccessChainKHR => .memory,
3041 .OpSDotAccSat => .Arithmetic,3261 .OpSubgroupBallotKHR => .group,
3042 .OpUDotAccSat => .Arithmetic,3262 .OpSubgroupFirstInvocationKHR => .group,
3043 .OpSUDotAccSat => .Arithmetic,3263 .OpUntypedPtrAccessChainKHR => .memory,
3044 .OpTypeCooperativeMatrixKHR => .TypeDeclaration,3264 .OpUntypedInBoundsPtrAccessChainKHR => .memory,
3045 .OpCooperativeMatrixLoadKHR => .Memory,3265 .OpUntypedArrayLengthKHR => .memory,
3046 .OpCooperativeMatrixStoreKHR => .Memory,3266 .OpUntypedPrefetchKHR => .memory,
3047 .OpCooperativeMatrixMulAddKHR => .Arithmetic,3267 .OpSubgroupAllKHR => .group,
3048 .OpCooperativeMatrixLengthKHR => .Miscellaneous,3268 .OpSubgroupAnyKHR => .group,
3049 .OpTypeRayQueryKHR => .TypeDeclaration,3269 .OpSubgroupAllEqualKHR => .group,
3050 .OpRayQueryInitializeKHR => .Reserved,3270 .OpGroupNonUniformRotateKHR => .group,
3051 .OpRayQueryTerminateKHR => .Reserved,3271 .OpSubgroupReadInvocationKHR => .group,
3052 .OpRayQueryGenerateIntersectionKHR => .Reserved,3272 .OpExtInstWithForwardRefsKHR => .extension,
3053 .OpRayQueryConfirmIntersectionKHR => .Reserved,3273 .OpTraceRayKHR => .reserved,
3054 .OpRayQueryProceedKHR => .Reserved,3274 .OpExecuteCallableKHR => .reserved,
3055 .OpRayQueryGetIntersectionTypeKHR => .Reserved,3275 .OpConvertUToAccelerationStructureKHR => .reserved,
3056 .OpImageSampleWeightedQCOM => .Image,3276 .OpIgnoreIntersectionKHR => .reserved,
3057 .OpImageBoxFilterQCOM => .Image,3277 .OpTerminateRayKHR => .reserved,
3058 .OpImageBlockMatchSSDQCOM => .Image,3278 .OpSDot => .arithmetic,
3059 .OpImageBlockMatchSADQCOM => .Image,3279 .OpUDot => .arithmetic,
3060 .OpImageBlockMatchWindowSSDQCOM => .Image,3280 .OpSUDot => .arithmetic,
3061 .OpImageBlockMatchWindowSADQCOM => .Image,3281 .OpSDotAccSat => .arithmetic,
3062 .OpImageBlockMatchGatherSSDQCOM => .Image,3282 .OpUDotAccSat => .arithmetic,
3063 .OpImageBlockMatchGatherSADQCOM => .Image,3283 .OpSUDotAccSat => .arithmetic,
3064 .OpGroupIAddNonUniformAMD => .Group,3284 .OpTypeCooperativeMatrixKHR => .type_declaration,
3065 .OpGroupFAddNonUniformAMD => .Group,3285 .OpCooperativeMatrixLoadKHR => .memory,
3066 .OpGroupFMinNonUniformAMD => .Group,3286 .OpCooperativeMatrixStoreKHR => .memory,
3067 .OpGroupUMinNonUniformAMD => .Group,3287 .OpCooperativeMatrixMulAddKHR => .arithmetic,
3068 .OpGroupSMinNonUniformAMD => .Group,3288 .OpCooperativeMatrixLengthKHR => .miscellaneous,
3069 .OpGroupFMaxNonUniformAMD => .Group,3289 .OpConstantCompositeReplicateEXT => .constant_creation,
3070 .OpGroupUMaxNonUniformAMD => .Group,3290 .OpSpecConstantCompositeReplicateEXT => .constant_creation,
3071 .OpGroupSMaxNonUniformAMD => .Group,3291 .OpCompositeConstructReplicateEXT => .composite,
3072 .OpFragmentMaskFetchAMD => .Reserved,3292 .OpTypeRayQueryKHR => .type_declaration,
3073 .OpFragmentFetchAMD => .Reserved,3293 .OpRayQueryInitializeKHR => .reserved,
3074 .OpReadClockKHR => .Reserved,3294 .OpRayQueryTerminateKHR => .reserved,
3075 .OpFinalizeNodePayloadsAMDX => .Reserved,3295 .OpRayQueryGenerateIntersectionKHR => .reserved,
3076 .OpFinishWritingNodePayloadAMDX => .Reserved,3296 .OpRayQueryConfirmIntersectionKHR => .reserved,
3077 .OpInitializeNodePayloadsAMDX => .Reserved,3297 .OpRayQueryProceedKHR => .reserved,
3078 .OpGroupNonUniformQuadAllKHR => .NonUniform,3298 .OpRayQueryGetIntersectionTypeKHR => .reserved,
3079 .OpGroupNonUniformQuadAnyKHR => .NonUniform,3299 .OpImageSampleWeightedQCOM => .image,
3080 .OpHitObjectRecordHitMotionNV => .Reserved,3300 .OpImageBoxFilterQCOM => .image,
3081 .OpHitObjectRecordHitWithIndexMotionNV => .Reserved,3301 .OpImageBlockMatchSSDQCOM => .image,
3082 .OpHitObjectRecordMissMotionNV => .Reserved,3302 .OpImageBlockMatchSADQCOM => .image,
3083 .OpHitObjectGetWorldToObjectNV => .Reserved,3303 .OpImageBlockMatchWindowSSDQCOM => .image,
3084 .OpHitObjectGetObjectToWorldNV => .Reserved,3304 .OpImageBlockMatchWindowSADQCOM => .image,
3085 .OpHitObjectGetObjectRayDirectionNV => .Reserved,3305 .OpImageBlockMatchGatherSSDQCOM => .image,
3086 .OpHitObjectGetObjectRayOriginNV => .Reserved,3306 .OpImageBlockMatchGatherSADQCOM => .image,
3087 .OpHitObjectTraceRayMotionNV => .Reserved,3307 .OpGroupIAddNonUniformAMD => .group,
3088 .OpHitObjectGetShaderRecordBufferHandleNV => .Reserved,3308 .OpGroupFAddNonUniformAMD => .group,
3089 .OpHitObjectGetShaderBindingTableRecordIndexNV => .Reserved,3309 .OpGroupFMinNonUniformAMD => .group,
3090 .OpHitObjectRecordEmptyNV => .Reserved,3310 .OpGroupUMinNonUniformAMD => .group,
3091 .OpHitObjectTraceRayNV => .Reserved,3311 .OpGroupSMinNonUniformAMD => .group,
3092 .OpHitObjectRecordHitNV => .Reserved,3312 .OpGroupFMaxNonUniformAMD => .group,
3093 .OpHitObjectRecordHitWithIndexNV => .Reserved,3313 .OpGroupUMaxNonUniformAMD => .group,
3094 .OpHitObjectRecordMissNV => .Reserved,3314 .OpGroupSMaxNonUniformAMD => .group,
3095 .OpHitObjectExecuteShaderNV => .Reserved,3315 .OpFragmentMaskFetchAMD => .reserved,
3096 .OpHitObjectGetCurrentTimeNV => .Reserved,3316 .OpFragmentFetchAMD => .reserved,
3097 .OpHitObjectGetAttributesNV => .Reserved,3317 .OpReadClockKHR => .reserved,
3098 .OpHitObjectGetHitKindNV => .Reserved,3318 .OpAllocateNodePayloadsAMDX => .reserved,
3099 .OpHitObjectGetPrimitiveIndexNV => .Reserved,3319 .OpEnqueueNodePayloadsAMDX => .reserved,
3100 .OpHitObjectGetGeometryIndexNV => .Reserved,3320 .OpTypeNodePayloadArrayAMDX => .reserved,
3101 .OpHitObjectGetInstanceIdNV => .Reserved,3321 .OpFinishWritingNodePayloadAMDX => .reserved,
3102 .OpHitObjectGetInstanceCustomIndexNV => .Reserved,3322 .OpNodePayloadArrayLengthAMDX => .reserved,
3103 .OpHitObjectGetWorldRayDirectionNV => .Reserved,3323 .OpIsNodePayloadValidAMDX => .reserved,
3104 .OpHitObjectGetWorldRayOriginNV => .Reserved,3324 .OpConstantStringAMDX => .reserved,
3105 .OpHitObjectGetRayTMaxNV => .Reserved,3325 .OpSpecConstantStringAMDX => .reserved,
3106 .OpHitObjectGetRayTMinNV => .Reserved,3326 .OpGroupNonUniformQuadAllKHR => .non_uniform,
3107 .OpHitObjectIsEmptyNV => .Reserved,3327 .OpGroupNonUniformQuadAnyKHR => .non_uniform,
3108 .OpHitObjectIsHitNV => .Reserved,3328 .OpHitObjectRecordHitMotionNV => .reserved,
3109 .OpHitObjectIsMissNV => .Reserved,3329 .OpHitObjectRecordHitWithIndexMotionNV => .reserved,
3110 .OpReorderThreadWithHitObjectNV => .Reserved,3330 .OpHitObjectRecordMissMotionNV => .reserved,
3111 .OpReorderThreadWithHintNV => .Reserved,3331 .OpHitObjectGetWorldToObjectNV => .reserved,
3112 .OpTypeHitObjectNV => .TypeDeclaration,3332 .OpHitObjectGetObjectToWorldNV => .reserved,
3113 .OpImageSampleFootprintNV => .Image,3333 .OpHitObjectGetObjectRayDirectionNV => .reserved,
3114 .OpEmitMeshTasksEXT => .Reserved,3334 .OpHitObjectGetObjectRayOriginNV => .reserved,
3115 .OpSetMeshOutputsEXT => .Reserved,3335 .OpHitObjectTraceRayMotionNV => .reserved,
3116 .OpGroupNonUniformPartitionNV => .NonUniform,3336 .OpHitObjectGetShaderRecordBufferHandleNV => .reserved,
3117 .OpWritePackedPrimitiveIndices4x8NV => .Reserved,3337 .OpHitObjectGetShaderBindingTableRecordIndexNV => .reserved,
3118 .OpFetchMicroTriangleVertexPositionNV => .Reserved,3338 .OpHitObjectRecordEmptyNV => .reserved,
3119 .OpFetchMicroTriangleVertexBarycentricNV => .Reserved,3339 .OpHitObjectTraceRayNV => .reserved,
3120 .OpReportIntersectionKHR => .Reserved,3340 .OpHitObjectRecordHitNV => .reserved,
3121 .OpIgnoreIntersectionNV => .Reserved,3341 .OpHitObjectRecordHitWithIndexNV => .reserved,
3122 .OpTerminateRayNV => .Reserved,3342 .OpHitObjectRecordMissNV => .reserved,
3123 .OpTraceNV => .Reserved,3343 .OpHitObjectExecuteShaderNV => .reserved,
3124 .OpTraceMotionNV => .Reserved,3344 .OpHitObjectGetCurrentTimeNV => .reserved,
3125 .OpTraceRayMotionNV => .Reserved,3345 .OpHitObjectGetAttributesNV => .reserved,
3126 .OpRayQueryGetIntersectionTriangleVertexPositionsKHR => .Reserved,3346 .OpHitObjectGetHitKindNV => .reserved,
3127 .OpTypeAccelerationStructureKHR => .TypeDeclaration,3347 .OpHitObjectGetPrimitiveIndexNV => .reserved,
3128 .OpExecuteCallableNV => .Reserved,3348 .OpHitObjectGetGeometryIndexNV => .reserved,
3129 .OpTypeCooperativeMatrixNV => .TypeDeclaration,3349 .OpHitObjectGetInstanceIdNV => .reserved,
3130 .OpCooperativeMatrixLoadNV => .Reserved,3350 .OpHitObjectGetInstanceCustomIndexNV => .reserved,
3131 .OpCooperativeMatrixStoreNV => .Reserved,3351 .OpHitObjectGetWorldRayDirectionNV => .reserved,
3132 .OpCooperativeMatrixMulAddNV => .Reserved,3352 .OpHitObjectGetWorldRayOriginNV => .reserved,
3133 .OpCooperativeMatrixLengthNV => .Reserved,3353 .OpHitObjectGetRayTMaxNV => .reserved,
3134 .OpBeginInvocationInterlockEXT => .Reserved,3354 .OpHitObjectGetRayTMinNV => .reserved,
3135 .OpEndInvocationInterlockEXT => .Reserved,3355 .OpHitObjectIsEmptyNV => .reserved,
3136 .OpDemoteToHelperInvocation => .ControlFlow,3356 .OpHitObjectIsHitNV => .reserved,
3137 .OpIsHelperInvocationEXT => .Reserved,3357 .OpHitObjectIsMissNV => .reserved,
3138 .OpConvertUToImageNV => .Reserved,3358 .OpReorderThreadWithHitObjectNV => .reserved,
3139 .OpConvertUToSamplerNV => .Reserved,3359 .OpReorderThreadWithHintNV => .reserved,
3140 .OpConvertImageToUNV => .Reserved,3360 .OpTypeHitObjectNV => .type_declaration,
3141 .OpConvertSamplerToUNV => .Reserved,3361 .OpImageSampleFootprintNV => .image,
3142 .OpConvertUToSampledImageNV => .Reserved,3362 .OpTypeCooperativeVectorNV => .type_declaration,
3143 .OpConvertSampledImageToUNV => .Reserved,3363 .OpCooperativeVectorMatrixMulNV => .reserved,
3144 .OpSamplerImageAddressingModeNV => .Reserved,3364 .OpCooperativeVectorOuterProductAccumulateNV => .reserved,
3145 .OpRawAccessChainNV => .Memory,3365 .OpCooperativeVectorReduceSumAccumulateNV => .reserved,
3146 .OpSubgroupShuffleINTEL => .Group,3366 .OpCooperativeVectorMatrixMulAddNV => .reserved,
3147 .OpSubgroupShuffleDownINTEL => .Group,3367 .OpCooperativeMatrixConvertNV => .conversion,
3148 .OpSubgroupShuffleUpINTEL => .Group,3368 .OpEmitMeshTasksEXT => .reserved,
3149 .OpSubgroupShuffleXorINTEL => .Group,3369 .OpSetMeshOutputsEXT => .reserved,
3150 .OpSubgroupBlockReadINTEL => .Group,3370 .OpGroupNonUniformPartitionNV => .non_uniform,
3151 .OpSubgroupBlockWriteINTEL => .Group,3371 .OpWritePackedPrimitiveIndices4x8NV => .reserved,
3152 .OpSubgroupImageBlockReadINTEL => .Group,3372 .OpFetchMicroTriangleVertexPositionNV => .reserved,
3153 .OpSubgroupImageBlockWriteINTEL => .Group,3373 .OpFetchMicroTriangleVertexBarycentricNV => .reserved,
3154 .OpSubgroupImageMediaBlockReadINTEL => .Group,3374 .OpCooperativeVectorLoadNV => .memory,
3155 .OpSubgroupImageMediaBlockWriteINTEL => .Group,3375 .OpCooperativeVectorStoreNV => .memory,
3156 .OpUCountLeadingZerosINTEL => .Reserved,3376 .OpReportIntersectionKHR => .reserved,
3157 .OpUCountTrailingZerosINTEL => .Reserved,3377 .OpIgnoreIntersectionNV => .reserved,
3158 .OpAbsISubINTEL => .Reserved,3378 .OpTerminateRayNV => .reserved,
3159 .OpAbsUSubINTEL => .Reserved,3379 .OpTraceNV => .reserved,
3160 .OpIAddSatINTEL => .Reserved,3380 .OpTraceMotionNV => .reserved,
3161 .OpUAddSatINTEL => .Reserved,3381 .OpTraceRayMotionNV => .reserved,
3162 .OpIAverageINTEL => .Reserved,3382 .OpRayQueryGetIntersectionTriangleVertexPositionsKHR => .reserved,
3163 .OpUAverageINTEL => .Reserved,3383 .OpTypeAccelerationStructureKHR => .type_declaration,
3164 .OpIAverageRoundedINTEL => .Reserved,3384 .OpExecuteCallableNV => .reserved,
3165 .OpUAverageRoundedINTEL => .Reserved,3385 .OpRayQueryGetClusterIdNV => .reserved,
3166 .OpISubSatINTEL => .Reserved,3386 .OpHitObjectGetClusterIdNV => .reserved,
3167 .OpUSubSatINTEL => .Reserved,3387 .OpTypeCooperativeMatrixNV => .type_declaration,
3168 .OpIMul32x16INTEL => .Reserved,3388 .OpCooperativeMatrixLoadNV => .reserved,
3169 .OpUMul32x16INTEL => .Reserved,3389 .OpCooperativeMatrixStoreNV => .reserved,
3170 .OpAtomicFMinEXT => .Atomic,3390 .OpCooperativeMatrixMulAddNV => .reserved,
3171 .OpAtomicFMaxEXT => .Atomic,3391 .OpCooperativeMatrixLengthNV => .reserved,
3172 .OpAssumeTrueKHR => .Miscellaneous,3392 .OpBeginInvocationInterlockEXT => .reserved,
3173 .OpExpectKHR => .Miscellaneous,3393 .OpEndInvocationInterlockEXT => .reserved,
3174 .OpDecorateString => .Annotation,3394 .OpCooperativeMatrixReduceNV => .arithmetic,
3175 .OpMemberDecorateString => .Annotation,3395 .OpCooperativeMatrixLoadTensorNV => .memory,
3176 .OpLoopControlINTEL => .Reserved,3396 .OpCooperativeMatrixStoreTensorNV => .memory,
3177 .OpReadPipeBlockingINTEL => .Pipe,3397 .OpCooperativeMatrixPerElementOpNV => .function,
3178 .OpWritePipeBlockingINTEL => .Pipe,3398 .OpTypeTensorLayoutNV => .type_declaration,
3179 .OpFPGARegINTEL => .Reserved,3399 .OpTypeTensorViewNV => .type_declaration,
3180 .OpRayQueryGetRayTMinKHR => .Reserved,3400 .OpCreateTensorLayoutNV => .reserved,
3181 .OpRayQueryGetRayFlagsKHR => .Reserved,3401 .OpTensorLayoutSetDimensionNV => .reserved,
3182 .OpRayQueryGetIntersectionTKHR => .Reserved,3402 .OpTensorLayoutSetStrideNV => .reserved,
3183 .OpRayQueryGetIntersectionInstanceCustomIndexKHR => .Reserved,3403 .OpTensorLayoutSliceNV => .reserved,
3184 .OpRayQueryGetIntersectionInstanceIdKHR => .Reserved,3404 .OpTensorLayoutSetClampValueNV => .reserved,
3185 .OpRayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetKHR => .Reserved,3405 .OpCreateTensorViewNV => .reserved,
3186 .OpRayQueryGetIntersectionGeometryIndexKHR => .Reserved,3406 .OpTensorViewSetDimensionNV => .reserved,
3187 .OpRayQueryGetIntersectionPrimitiveIndexKHR => .Reserved,3407 .OpTensorViewSetStrideNV => .reserved,
3188 .OpRayQueryGetIntersectionBarycentricsKHR => .Reserved,3408 .OpDemoteToHelperInvocation => .control_flow,
3189 .OpRayQueryGetIntersectionFrontFaceKHR => .Reserved,3409 .OpIsHelperInvocationEXT => .reserved,
3190 .OpRayQueryGetIntersectionCandidateAABBOpaqueKHR => .Reserved,3410 .OpTensorViewSetClipNV => .reserved,
3191 .OpRayQueryGetIntersectionObjectRayDirectionKHR => .Reserved,3411 .OpTensorLayoutSetBlockSizeNV => .reserved,
3192 .OpRayQueryGetIntersectionObjectRayOriginKHR => .Reserved,3412 .OpCooperativeMatrixTransposeNV => .conversion,
3193 .OpRayQueryGetWorldRayDirectionKHR => .Reserved,3413 .OpConvertUToImageNV => .reserved,
3194 .OpRayQueryGetWorldRayOriginKHR => .Reserved,3414 .OpConvertUToSamplerNV => .reserved,
3195 .OpRayQueryGetIntersectionObjectToWorldKHR => .Reserved,3415 .OpConvertImageToUNV => .reserved,
3196 .OpRayQueryGetIntersectionWorldToObjectKHR => .Reserved,3416 .OpConvertSamplerToUNV => .reserved,
3197 .OpAtomicFAddEXT => .Atomic,3417 .OpConvertUToSampledImageNV => .reserved,
3198 .OpTypeBufferSurfaceINTEL => .TypeDeclaration,3418 .OpConvertSampledImageToUNV => .reserved,
3199 .OpTypeStructContinuedINTEL => .TypeDeclaration,3419 .OpSamplerImageAddressingModeNV => .reserved,
3200 .OpConstantCompositeContinuedINTEL => .ConstantCreation,3420 .OpRawAccessChainNV => .memory,
3201 .OpSpecConstantCompositeContinuedINTEL => .ConstantCreation,3421 .OpRayQueryGetIntersectionSpherePositionNV => .reserved,
3202 .OpCompositeConstructContinuedINTEL => .Composite,3422 .OpRayQueryGetIntersectionSphereRadiusNV => .reserved,
3203 .OpConvertFToBF16INTEL => .Conversion,3423 .OpRayQueryGetIntersectionLSSPositionsNV => .reserved,
3204 .OpConvertBF16ToFINTEL => .Conversion,3424 .OpRayQueryGetIntersectionLSSRadiiNV => .reserved,
3205 .OpControlBarrierArriveINTEL => .Barrier,3425 .OpRayQueryGetIntersectionLSSHitValueNV => .reserved,
3206 .OpControlBarrierWaitINTEL => .Barrier,3426 .OpHitObjectGetSpherePositionNV => .reserved,
3207 .OpGroupIMulKHR => .Group,3427 .OpHitObjectGetSphereRadiusNV => .reserved,
3208 .OpGroupFMulKHR => .Group,3428 .OpHitObjectGetLSSPositionsNV => .reserved,
3209 .OpGroupBitwiseAndKHR => .Group,3429 .OpHitObjectGetLSSRadiiNV => .reserved,
3210 .OpGroupBitwiseOrKHR => .Group,3430 .OpHitObjectIsSphereHitNV => .reserved,
3211 .OpGroupBitwiseXorKHR => .Group,3431 .OpHitObjectIsLSSHitNV => .reserved,
3212 .OpGroupLogicalAndKHR => .Group,3432 .OpRayQueryIsSphereHitNV => .reserved,
3213 .OpGroupLogicalOrKHR => .Group,3433 .OpRayQueryIsLSSHitNV => .reserved,
3214 .OpGroupLogicalXorKHR => .Group,3434 .OpSubgroupShuffleINTEL => .group,
3215 .OpMaskedGatherINTEL => .Memory,3435 .OpSubgroupShuffleDownINTEL => .group,
3216 .OpMaskedScatterINTEL => .Memory,3436 .OpSubgroupShuffleUpINTEL => .group,
3437 .OpSubgroupShuffleXorINTEL => .group,
3438 .OpSubgroupBlockReadINTEL => .group,
3439 .OpSubgroupBlockWriteINTEL => .group,
3440 .OpSubgroupImageBlockReadINTEL => .group,
3441 .OpSubgroupImageBlockWriteINTEL => .group,
3442 .OpSubgroupImageMediaBlockReadINTEL => .group,
3443 .OpSubgroupImageMediaBlockWriteINTEL => .group,
3444 .OpUCountLeadingZerosINTEL => .reserved,
3445 .OpUCountTrailingZerosINTEL => .reserved,
3446 .OpAbsISubINTEL => .reserved,
3447 .OpAbsUSubINTEL => .reserved,
3448 .OpIAddSatINTEL => .reserved,
3449 .OpUAddSatINTEL => .reserved,
3450 .OpIAverageINTEL => .reserved,
3451 .OpUAverageINTEL => .reserved,
3452 .OpIAverageRoundedINTEL => .reserved,
3453 .OpUAverageRoundedINTEL => .reserved,
3454 .OpISubSatINTEL => .reserved,
3455 .OpUSubSatINTEL => .reserved,
3456 .OpIMul32x16INTEL => .reserved,
3457 .OpUMul32x16INTEL => .reserved,
3458 .OpAtomicFMinEXT => .atomic,
3459 .OpAtomicFMaxEXT => .atomic,
3460 .OpAssumeTrueKHR => .miscellaneous,
3461 .OpExpectKHR => .miscellaneous,
3462 .OpDecorateString => .annotation,
3463 .OpMemberDecorateString => .annotation,
3464 .OpLoopControlINTEL => .reserved,
3465 .OpReadPipeBlockingINTEL => .pipe,
3466 .OpWritePipeBlockingINTEL => .pipe,
3467 .OpFPGARegINTEL => .reserved,
3468 .OpRayQueryGetRayTMinKHR => .reserved,
3469 .OpRayQueryGetRayFlagsKHR => .reserved,
3470 .OpRayQueryGetIntersectionTKHR => .reserved,
3471 .OpRayQueryGetIntersectionInstanceCustomIndexKHR => .reserved,
3472 .OpRayQueryGetIntersectionInstanceIdKHR => .reserved,
3473 .OpRayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetKHR => .reserved,
3474 .OpRayQueryGetIntersectionGeometryIndexKHR => .reserved,
3475 .OpRayQueryGetIntersectionPrimitiveIndexKHR => .reserved,
3476 .OpRayQueryGetIntersectionBarycentricsKHR => .reserved,
3477 .OpRayQueryGetIntersectionFrontFaceKHR => .reserved,
3478 .OpRayQueryGetIntersectionCandidateAABBOpaqueKHR => .reserved,
3479 .OpRayQueryGetIntersectionObjectRayDirectionKHR => .reserved,
3480 .OpRayQueryGetIntersectionObjectRayOriginKHR => .reserved,
3481 .OpRayQueryGetWorldRayDirectionKHR => .reserved,
3482 .OpRayQueryGetWorldRayOriginKHR => .reserved,
3483 .OpRayQueryGetIntersectionObjectToWorldKHR => .reserved,
3484 .OpRayQueryGetIntersectionWorldToObjectKHR => .reserved,
3485 .OpAtomicFAddEXT => .atomic,
3486 .OpTypeBufferSurfaceINTEL => .type_declaration,
3487 .OpTypeStructContinuedINTEL => .type_declaration,
3488 .OpConstantCompositeContinuedINTEL => .constant_creation,
3489 .OpSpecConstantCompositeContinuedINTEL => .constant_creation,
3490 .OpCompositeConstructContinuedINTEL => .composite,
3491 .OpConvertFToBF16INTEL => .conversion,
3492 .OpConvertBF16ToFINTEL => .conversion,
3493 .OpControlBarrierArriveINTEL => .barrier,
3494 .OpControlBarrierWaitINTEL => .barrier,
3495 .OpArithmeticFenceEXT => .miscellaneous,
3496 .OpTaskSequenceCreateINTEL => .reserved,
3497 .OpTaskSequenceAsyncINTEL => .reserved,
3498 .OpTaskSequenceGetINTEL => .reserved,
3499 .OpTaskSequenceReleaseINTEL => .reserved,
3500 .OpTypeTaskSequenceINTEL => .type_declaration,
3501 .OpSubgroupBlockPrefetchINTEL => .group,
3502 .OpSubgroup2DBlockLoadINTEL => .group,
3503 .OpSubgroup2DBlockLoadTransformINTEL => .group,
3504 .OpSubgroup2DBlockLoadTransposeINTEL => .group,
3505 .OpSubgroup2DBlockPrefetchINTEL => .group,
3506 .OpSubgroup2DBlockStoreINTEL => .group,
3507 .OpSubgroupMatrixMultiplyAccumulateINTEL => .group,
3508 .OpBitwiseFunctionINTEL => .bit,
3509 .OpGroupIMulKHR => .group,
3510 .OpGroupFMulKHR => .group,
3511 .OpGroupBitwiseAndKHR => .group,
3512 .OpGroupBitwiseOrKHR => .group,
3513 .OpGroupBitwiseXorKHR => .group,
3514 .OpGroupLogicalAndKHR => .group,
3515 .OpGroupLogicalOrKHR => .group,
3516 .OpGroupLogicalXorKHR => .group,
3517 .OpRoundFToTF32INTEL => .conversion,
3518 .OpMaskedGatherINTEL => .memory,
3519 .OpMaskedScatterINTEL => .memory,
3520 .OpConvertHandleToImageINTEL => .image,
3521 .OpConvertHandleToSamplerINTEL => .image,
3522 .OpConvertHandleToSampledImageINTEL => .image,
3217 };3523 };
3218 }3524 }
3219};3525};
3220pub const ImageOperands = packed struct {3526pub const ImageOperands = packed struct {
3221 Bias: bool = false,3527 bias: bool = false,
3222 Lod: bool = false,3528 lod: bool = false,
3223 Grad: bool = false,3529 grad: bool = false,
3224 ConstOffset: bool = false,3530 const_offset: bool = false,
3225 Offset: bool = false,3531 offset: bool = false,
3226 ConstOffsets: bool = false,3532 const_offsets: bool = false,
3227 Sample: bool = false,3533 sample: bool = false,
3228 MinLod: bool = false,3534 min_lod: bool = false,
3229 MakeTexelAvailable: bool = false,3535 make_texel_available: bool = false,
3230 MakeTexelVisible: bool = false,3536 make_texel_visible: bool = false,
3231 NonPrivateTexel: bool = false,3537 non_private_texel: bool = false,
3232 VolatileTexel: bool = false,3538 volatile_texel: bool = false,
3233 SignExtend: bool = false,3539 sign_extend: bool = false,
3234 ZeroExtend: bool = false,3540 zero_extend: bool = false,
3235 Nontemporal: bool = false,3541 nontemporal: bool = false,
3236 _reserved_bit_15: bool = false,3542 _reserved_bit_15: bool = false,
3237 Offsets: bool = false,3543 offsets: bool = false,
3238 _reserved_bit_17: bool = false,3544 _reserved_bit_17: bool = false,
3239 _reserved_bit_18: bool = false,3545 _reserved_bit_18: bool = false,
3240 _reserved_bit_19: bool = false,3546 _reserved_bit_19: bool = false,
...@@ -3251,29 +3557,24 @@ pub const ImageOperands = packed struct {...@@ -3251,29 +3557,24 @@ pub const ImageOperands = packed struct {
3251 _reserved_bit_30: bool = false,3557 _reserved_bit_30: bool = false,
3252 _reserved_bit_31: bool = false,3558 _reserved_bit_31: bool = false,
32533559
3254 pub const MakeTexelAvailableKHR: ImageOperands = .{ .MakeTexelAvailable = true };
3255 pub const MakeTexelVisibleKHR: ImageOperands = .{ .MakeTexelVisible = true };
3256 pub const NonPrivateTexelKHR: ImageOperands = .{ .NonPrivateTexel = true };
3257 pub const VolatileTexelKHR: ImageOperands = .{ .VolatileTexel = true };
3258
3259 pub const Extended = struct {3560 pub const Extended = struct {
3260 Bias: ?struct { id_ref: IdRef } = null,3561 bias: ?struct { id_ref: Id } = null,
3261 Lod: ?struct { id_ref: IdRef } = null,3562 lod: ?struct { id_ref: Id } = null,
3262 Grad: ?struct { id_ref_0: IdRef, id_ref_1: IdRef } = null,3563 grad: ?struct { id_ref_0: Id, id_ref_1: Id } = null,
3263 ConstOffset: ?struct { id_ref: IdRef } = null,3564 const_offset: ?struct { id_ref: Id } = null,
3264 Offset: ?struct { id_ref: IdRef } = null,3565 offset: ?struct { id_ref: Id } = null,
3265 ConstOffsets: ?struct { id_ref: IdRef } = null,3566 const_offsets: ?struct { id_ref: Id } = null,
3266 Sample: ?struct { id_ref: IdRef } = null,3567 sample: ?struct { id_ref: Id } = null,
3267 MinLod: ?struct { id_ref: IdRef } = null,3568 min_lod: ?struct { id_ref: Id } = null,
3268 MakeTexelAvailable: ?struct { id_scope: IdScope } = null,3569 make_texel_available: ?struct { id_scope: Id } = null,
3269 MakeTexelVisible: ?struct { id_scope: IdScope } = null,3570 make_texel_visible: ?struct { id_scope: Id } = null,
3270 NonPrivateTexel: bool = false,3571 non_private_texel: bool = false,
3271 VolatileTexel: bool = false,3572 volatile_texel: bool = false,
3272 SignExtend: bool = false,3573 sign_extend: bool = false,
3273 ZeroExtend: bool = false,3574 zero_extend: bool = false,
3274 Nontemporal: bool = false,3575 nontemporal: bool = false,
3275 _reserved_bit_15: bool = false,3576 _reserved_bit_15: bool = false,
3276 Offsets: ?struct { id_ref: IdRef } = null,3577 offsets: ?struct { id_ref: Id } = null,
3277 _reserved_bit_17: bool = false,3578 _reserved_bit_17: bool = false,
3278 _reserved_bit_18: bool = false,3579 _reserved_bit_18: bool = false,
3279 _reserved_bit_19: bool = false,3580 _reserved_bit_19: bool = false,
...@@ -3292,11 +3593,11 @@ pub const ImageOperands = packed struct {...@@ -3292,11 +3593,11 @@ pub const ImageOperands = packed struct {
3292 };3593 };
3293};3594};
3294pub const FPFastMathMode = packed struct {3595pub const FPFastMathMode = packed struct {
3295 NotNaN: bool = false,3596 not_na_n: bool = false,
3296 NotInf: bool = false,3597 not_inf: bool = false,
3297 NSZ: bool = false,3598 nsz: bool = false,
3298 AllowRecip: bool = false,3599 allow_recip: bool = false,
3299 Fast: bool = false,3600 fast: bool = false,
3300 _reserved_bit_5: bool = false,3601 _reserved_bit_5: bool = false,
3301 _reserved_bit_6: bool = false,3602 _reserved_bit_6: bool = false,
3302 _reserved_bit_7: bool = false,3603 _reserved_bit_7: bool = false,
...@@ -3308,9 +3609,9 @@ pub const FPFastMathMode = packed struct {...@@ -3308,9 +3609,9 @@ pub const FPFastMathMode = packed struct {
3308 _reserved_bit_13: bool = false,3609 _reserved_bit_13: bool = false,
3309 _reserved_bit_14: bool = false,3610 _reserved_bit_14: bool = false,
3310 _reserved_bit_15: bool = false,3611 _reserved_bit_15: bool = false,
3311 AllowContract: bool = false,3612 allow_contract: bool = false,
3312 AllowReassoc: bool = false,3613 allow_reassoc: bool = false,
3313 AllowTransform: bool = false,3614 allow_transform: bool = false,
3314 _reserved_bit_19: bool = false,3615 _reserved_bit_19: bool = false,
3315 _reserved_bit_20: bool = false,3616 _reserved_bit_20: bool = false,
3316 _reserved_bit_21: bool = false,3617 _reserved_bit_21: bool = false,
...@@ -3324,13 +3625,10 @@ pub const FPFastMathMode = packed struct {...@@ -3324,13 +3625,10 @@ pub const FPFastMathMode = packed struct {
3324 _reserved_bit_29: bool = false,3625 _reserved_bit_29: bool = false,
3325 _reserved_bit_30: bool = false,3626 _reserved_bit_30: bool = false,
3326 _reserved_bit_31: bool = false,3627 _reserved_bit_31: bool = false,
3327
3328 pub const AllowContractFastINTEL: FPFastMathMode = .{ .AllowContract = true };
3329 pub const AllowReassocINTEL: FPFastMathMode = .{ .AllowReassoc = true };
3330};3628};
3331pub const SelectionControl = packed struct {3629pub const SelectionControl = packed struct {
3332 Flatten: bool = false,3630 flatten: bool = false,
3333 DontFlatten: bool = false,3631 dont_flatten: bool = false,
3334 _reserved_bit_2: bool = false,3632 _reserved_bit_2: bool = false,
3335 _reserved_bit_3: bool = false,3633 _reserved_bit_3: bool = false,
3336 _reserved_bit_4: bool = false,3634 _reserved_bit_4: bool = false,
...@@ -3363,15 +3661,15 @@ pub const SelectionControl = packed struct {...@@ -3363,15 +3661,15 @@ pub const SelectionControl = packed struct {
3363 _reserved_bit_31: bool = false,3661 _reserved_bit_31: bool = false,
3364};3662};
3365pub const LoopControl = packed struct {3663pub const LoopControl = packed struct {
3366 Unroll: bool = false,3664 unroll: bool = false,
3367 DontUnroll: bool = false,3665 dont_unroll: bool = false,
3368 DependencyInfinite: bool = false,3666 dependency_infinite: bool = false,
3369 DependencyLength: bool = false,3667 dependency_length: bool = false,
3370 MinIterations: bool = false,3668 min_iterations: bool = false,
3371 MaxIterations: bool = false,3669 max_iterations: bool = false,
3372 IterationMultiple: bool = false,3670 iteration_multiple: bool = false,
3373 PeelCount: bool = false,3671 peel_count: bool = false,
3374 PartialCount: bool = false,3672 partial_count: bool = false,
3375 _reserved_bit_9: bool = false,3673 _reserved_bit_9: bool = false,
3376 _reserved_bit_10: bool = false,3674 _reserved_bit_10: bool = false,
3377 _reserved_bit_11: bool = false,3675 _reserved_bit_11: bool = false,
...@@ -3379,16 +3677,16 @@ pub const LoopControl = packed struct {...@@ -3379,16 +3677,16 @@ pub const LoopControl = packed struct {
3379 _reserved_bit_13: bool = false,3677 _reserved_bit_13: bool = false,
3380 _reserved_bit_14: bool = false,3678 _reserved_bit_14: bool = false,
3381 _reserved_bit_15: bool = false,3679 _reserved_bit_15: bool = false,
3382 InitiationIntervalINTEL: bool = false,3680 initiation_interval_intel: bool = false,
3383 MaxConcurrencyINTEL: bool = false,3681 max_concurrency_intel: bool = false,
3384 DependencyArrayINTEL: bool = false,3682 dependency_array_intel: bool = false,
3385 PipelineEnableINTEL: bool = false,3683 pipeline_enable_intel: bool = false,
3386 LoopCoalesceINTEL: bool = false,3684 loop_coalesce_intel: bool = false,
3387 MaxInterleavingINTEL: bool = false,3685 max_interleaving_intel: bool = false,
3388 SpeculatedIterationsINTEL: bool = false,3686 speculated_iterations_intel: bool = false,
3389 NoFusionINTEL: bool = false,3687 no_fusion_intel: bool = false,
3390 LoopCountINTEL: bool = false,3688 loop_count_intel: bool = false,
3391 MaxReinvocationDelayINTEL: bool = false,3689 max_reinvocation_delay_intel: bool = false,
3392 _reserved_bit_26: bool = false,3690 _reserved_bit_26: bool = false,
3393 _reserved_bit_27: bool = false,3691 _reserved_bit_27: bool = false,
3394 _reserved_bit_28: bool = false,3692 _reserved_bit_28: bool = false,
...@@ -3397,15 +3695,15 @@ pub const LoopControl = packed struct {...@@ -3397,15 +3695,15 @@ pub const LoopControl = packed struct {
3397 _reserved_bit_31: bool = false,3695 _reserved_bit_31: bool = false,
33983696
3399 pub const Extended = struct {3697 pub const Extended = struct {
3400 Unroll: bool = false,3698 unroll: bool = false,
3401 DontUnroll: bool = false,3699 dont_unroll: bool = false,
3402 DependencyInfinite: bool = false,3700 dependency_infinite: bool = false,
3403 DependencyLength: ?struct { literal_integer: LiteralInteger } = null,3701 dependency_length: ?struct { literal_integer: LiteralInteger } = null,
3404 MinIterations: ?struct { literal_integer: LiteralInteger } = null,3702 min_iterations: ?struct { literal_integer: LiteralInteger } = null,
3405 MaxIterations: ?struct { literal_integer: LiteralInteger } = null,3703 max_iterations: ?struct { literal_integer: LiteralInteger } = null,
3406 IterationMultiple: ?struct { literal_integer: LiteralInteger } = null,3704 iteration_multiple: ?struct { literal_integer: LiteralInteger } = null,
3407 PeelCount: ?struct { literal_integer: LiteralInteger } = null,3705 peel_count: ?struct { literal_integer: LiteralInteger } = null,
3408 PartialCount: ?struct { literal_integer: LiteralInteger } = null,3706 partial_count: ?struct { literal_integer: LiteralInteger } = null,
3409 _reserved_bit_9: bool = false,3707 _reserved_bit_9: bool = false,
3410 _reserved_bit_10: bool = false,3708 _reserved_bit_10: bool = false,
3411 _reserved_bit_11: bool = false,3709 _reserved_bit_11: bool = false,
...@@ -3413,16 +3711,16 @@ pub const LoopControl = packed struct {...@@ -3413,16 +3711,16 @@ pub const LoopControl = packed struct {
3413 _reserved_bit_13: bool = false,3711 _reserved_bit_13: bool = false,
3414 _reserved_bit_14: bool = false,3712 _reserved_bit_14: bool = false,
3415 _reserved_bit_15: bool = false,3713 _reserved_bit_15: bool = false,
3416 InitiationIntervalINTEL: ?struct { literal_integer: LiteralInteger } = null,3714 initiation_interval_intel: ?struct { literal_integer: LiteralInteger } = null,
3417 MaxConcurrencyINTEL: ?struct { literal_integer: LiteralInteger } = null,3715 max_concurrency_intel: ?struct { literal_integer: LiteralInteger } = null,
3418 DependencyArrayINTEL: ?struct { literal_integer: LiteralInteger } = null,3716 dependency_array_intel: ?struct { literal_integer: LiteralInteger } = null,
3419 PipelineEnableINTEL: ?struct { literal_integer: LiteralInteger } = null,3717 pipeline_enable_intel: ?struct { literal_integer: LiteralInteger } = null,
3420 LoopCoalesceINTEL: ?struct { literal_integer: LiteralInteger } = null,3718 loop_coalesce_intel: ?struct { literal_integer: LiteralInteger } = null,
3421 MaxInterleavingINTEL: ?struct { literal_integer: LiteralInteger } = null,3719 max_interleaving_intel: ?struct { literal_integer: LiteralInteger } = null,
3422 SpeculatedIterationsINTEL: ?struct { literal_integer: LiteralInteger } = null,3720 speculated_iterations_intel: ?struct { literal_integer: LiteralInteger } = null,
3423 NoFusionINTEL: bool = false,3721 no_fusion_intel: bool = false,
3424 LoopCountINTEL: ?struct { literal_integer: LiteralInteger } = null,3722 loop_count_intel: ?struct { literal_integer: LiteralInteger } = null,
3425 MaxReinvocationDelayINTEL: ?struct { literal_integer: LiteralInteger } = null,3723 max_reinvocation_delay_intel: ?struct { literal_integer: LiteralInteger } = null,
3426 _reserved_bit_26: bool = false,3724 _reserved_bit_26: bool = false,
3427 _reserved_bit_27: bool = false,3725 _reserved_bit_27: bool = false,
3428 _reserved_bit_28: bool = false,3726 _reserved_bit_28: bool = false,
...@@ -3432,10 +3730,10 @@ pub const LoopControl = packed struct {...@@ -3432,10 +3730,10 @@ pub const LoopControl = packed struct {
3432 };3730 };
3433};3731};
3434pub const FunctionControl = packed struct {3732pub const FunctionControl = packed struct {
3435 Inline: bool = false,3733 @"inline": bool = false,
3436 DontInline: bool = false,3734 dont_inline: bool = false,
3437 Pure: bool = false,3735 pure: bool = false,
3438 Const: bool = false,3736 @"const": bool = false,
3439 _reserved_bit_4: bool = false,3737 _reserved_bit_4: bool = false,
3440 _reserved_bit_5: bool = false,3738 _reserved_bit_5: bool = false,
3441 _reserved_bit_6: bool = false,3739 _reserved_bit_6: bool = false,
...@@ -3448,7 +3746,7 @@ pub const FunctionControl = packed struct {...@@ -3448,7 +3746,7 @@ pub const FunctionControl = packed struct {
3448 _reserved_bit_13: bool = false,3746 _reserved_bit_13: bool = false,
3449 _reserved_bit_14: bool = false,3747 _reserved_bit_14: bool = false,
3450 _reserved_bit_15: bool = false,3748 _reserved_bit_15: bool = false,
3451 OptNoneINTEL: bool = false,3749 opt_none_ext: bool = false,
3452 _reserved_bit_17: bool = false,3750 _reserved_bit_17: bool = false,
3453 _reserved_bit_18: bool = false,3751 _reserved_bit_18: bool = false,
3454 _reserved_bit_19: bool = false,3752 _reserved_bit_19: bool = false,
...@@ -3467,21 +3765,21 @@ pub const FunctionControl = packed struct {...@@ -3467,21 +3765,21 @@ pub const FunctionControl = packed struct {
3467};3765};
3468pub const MemorySemantics = packed struct {3766pub const MemorySemantics = packed struct {
3469 _reserved_bit_0: bool = false,3767 _reserved_bit_0: bool = false,
3470 Acquire: bool = false,3768 acquire: bool = false,
3471 Release: bool = false,3769 release: bool = false,
3472 AcquireRelease: bool = false,3770 acquire_release: bool = false,
3473 SequentiallyConsistent: bool = false,3771 sequentially_consistent: bool = false,
3474 _reserved_bit_5: bool = false,3772 _reserved_bit_5: bool = false,
3475 UniformMemory: bool = false,3773 uniform_memory: bool = false,
3476 SubgroupMemory: bool = false,3774 subgroup_memory: bool = false,
3477 WorkgroupMemory: bool = false,3775 workgroup_memory: bool = false,
3478 CrossWorkgroupMemory: bool = false,3776 cross_workgroup_memory: bool = false,
3479 AtomicCounterMemory: bool = false,3777 atomic_counter_memory: bool = false,
3480 ImageMemory: bool = false,3778 image_memory: bool = false,
3481 OutputMemory: bool = false,3779 output_memory: bool = false,
3482 MakeAvailable: bool = false,3780 make_available: bool = false,
3483 MakeVisible: bool = false,3781 make_visible: bool = false,
3484 Volatile: bool = false,3782 @"volatile": bool = false,
3485 _reserved_bit_16: bool = false,3783 _reserved_bit_16: bool = false,
3486 _reserved_bit_17: bool = false,3784 _reserved_bit_17: bool = false,
3487 _reserved_bit_18: bool = false,3785 _reserved_bit_18: bool = false,
...@@ -3498,18 +3796,14 @@ pub const MemorySemantics = packed struct {...@@ -3498,18 +3796,14 @@ pub const MemorySemantics = packed struct {
3498 _reserved_bit_29: bool = false,3796 _reserved_bit_29: bool = false,
3499 _reserved_bit_30: bool = false,3797 _reserved_bit_30: bool = false,
3500 _reserved_bit_31: bool = false,3798 _reserved_bit_31: bool = false,
3501
3502 pub const OutputMemoryKHR: MemorySemantics = .{ .OutputMemory = true };
3503 pub const MakeAvailableKHR: MemorySemantics = .{ .MakeAvailable = true };
3504 pub const MakeVisibleKHR: MemorySemantics = .{ .MakeVisible = true };
3505};3799};
3506pub const MemoryAccess = packed struct {3800pub const MemoryAccess = packed struct {
3507 Volatile: bool = false,3801 @"volatile": bool = false,
3508 Aligned: bool = false,3802 aligned: bool = false,
3509 Nontemporal: bool = false,3803 nontemporal: bool = false,
3510 MakePointerAvailable: bool = false,3804 make_pointer_available: bool = false,
3511 MakePointerVisible: bool = false,3805 make_pointer_visible: bool = false,
3512 NonPrivatePointer: bool = false,3806 non_private_pointer: bool = false,
3513 _reserved_bit_6: bool = false,3807 _reserved_bit_6: bool = false,
3514 _reserved_bit_7: bool = false,3808 _reserved_bit_7: bool = false,
3515 _reserved_bit_8: bool = false,3809 _reserved_bit_8: bool = false,
...@@ -3520,8 +3814,8 @@ pub const MemoryAccess = packed struct {...@@ -3520,8 +3814,8 @@ pub const MemoryAccess = packed struct {
3520 _reserved_bit_13: bool = false,3814 _reserved_bit_13: bool = false,
3521 _reserved_bit_14: bool = false,3815 _reserved_bit_14: bool = false,
3522 _reserved_bit_15: bool = false,3816 _reserved_bit_15: bool = false,
3523 AliasScopeINTELMask: bool = false,3817 alias_scope_intel_mask: bool = false,
3524 NoAliasINTELMask: bool = false,3818 no_alias_intel_mask: bool = false,
3525 _reserved_bit_18: bool = false,3819 _reserved_bit_18: bool = false,
3526 _reserved_bit_19: bool = false,3820 _reserved_bit_19: bool = false,
3527 _reserved_bit_20: bool = false,3821 _reserved_bit_20: bool = false,
...@@ -3537,17 +3831,13 @@ pub const MemoryAccess = packed struct {...@@ -3537,17 +3831,13 @@ pub const MemoryAccess = packed struct {
3537 _reserved_bit_30: bool = false,3831 _reserved_bit_30: bool = false,
3538 _reserved_bit_31: bool = false,3832 _reserved_bit_31: bool = false,
35393833
3540 pub const MakePointerAvailableKHR: MemoryAccess = .{ .MakePointerAvailable = true };
3541 pub const MakePointerVisibleKHR: MemoryAccess = .{ .MakePointerVisible = true };
3542 pub const NonPrivatePointerKHR: MemoryAccess = .{ .NonPrivatePointer = true };
3543
3544 pub const Extended = struct {3834 pub const Extended = struct {
3545 Volatile: bool = false,3835 @"volatile": bool = false,
3546 Aligned: ?struct { literal_integer: LiteralInteger } = null,3836 aligned: ?struct { literal_integer: LiteralInteger } = null,
3547 Nontemporal: bool = false,3837 nontemporal: bool = false,
3548 MakePointerAvailable: ?struct { id_scope: IdScope } = null,3838 make_pointer_available: ?struct { id_scope: Id } = null,
3549 MakePointerVisible: ?struct { id_scope: IdScope } = null,3839 make_pointer_visible: ?struct { id_scope: Id } = null,
3550 NonPrivatePointer: bool = false,3840 non_private_pointer: bool = false,
3551 _reserved_bit_6: bool = false,3841 _reserved_bit_6: bool = false,
3552 _reserved_bit_7: bool = false,3842 _reserved_bit_7: bool = false,
3553 _reserved_bit_8: bool = false,3843 _reserved_bit_8: bool = false,
...@@ -3558,8 +3848,8 @@ pub const MemoryAccess = packed struct {...@@ -3558,8 +3848,8 @@ pub const MemoryAccess = packed struct {
3558 _reserved_bit_13: bool = false,3848 _reserved_bit_13: bool = false,
3559 _reserved_bit_14: bool = false,3849 _reserved_bit_14: bool = false,
3560 _reserved_bit_15: bool = false,3850 _reserved_bit_15: bool = false,
3561 AliasScopeINTELMask: ?struct { id_ref: IdRef } = null,3851 alias_scope_intel_mask: ?struct { id_ref: Id } = null,
3562 NoAliasINTELMask: ?struct { id_ref: IdRef } = null,3852 no_alias_intel_mask: ?struct { id_ref: Id } = null,
3563 _reserved_bit_18: bool = false,3853 _reserved_bit_18: bool = false,
3564 _reserved_bit_19: bool = false,3854 _reserved_bit_19: bool = false,
3565 _reserved_bit_20: bool = false,3855 _reserved_bit_20: bool = false,
...@@ -3577,7 +3867,7 @@ pub const MemoryAccess = packed struct {...@@ -3577,7 +3867,7 @@ pub const MemoryAccess = packed struct {
3577 };3867 };
3578};3868};
3579pub const KernelProfilingInfo = packed struct {3869pub const KernelProfilingInfo = packed struct {
3580 CmdExecTime: bool = false,3870 cmd_exec_time: bool = false,
3581 _reserved_bit_1: bool = false,3871 _reserved_bit_1: bool = false,
3582 _reserved_bit_2: bool = false,3872 _reserved_bit_2: bool = false,
3583 _reserved_bit_3: bool = false,3873 _reserved_bit_3: bool = false,
...@@ -3611,17 +3901,17 @@ pub const KernelProfilingInfo = packed struct {...@@ -3611,17 +3901,17 @@ pub const KernelProfilingInfo = packed struct {
3611 _reserved_bit_31: bool = false,3901 _reserved_bit_31: bool = false,
3612};3902};
3613pub const RayFlags = packed struct {3903pub const RayFlags = packed struct {
3614 OpaqueKHR: bool = false,3904 opaque_khr: bool = false,
3615 NoOpaqueKHR: bool = false,3905 no_opaque_khr: bool = false,
3616 TerminateOnFirstHitKHR: bool = false,3906 terminate_on_first_hit_khr: bool = false,
3617 SkipClosestHitShaderKHR: bool = false,3907 skip_closest_hit_shader_khr: bool = false,
3618 CullBackFacingTrianglesKHR: bool = false,3908 cull_back_facing_triangles_khr: bool = false,
3619 CullFrontFacingTrianglesKHR: bool = false,3909 cull_front_facing_triangles_khr: bool = false,
3620 CullOpaqueKHR: bool = false,3910 cull_opaque_khr: bool = false,
3621 CullNoOpaqueKHR: bool = false,3911 cull_no_opaque_khr: bool = false,
3622 SkipTrianglesKHR: bool = false,3912 skip_triangles_khr: bool = false,
3623 SkipAABBsKHR: bool = false,3913 skip_aab_bs_khr: bool = false,
3624 ForceOpacityMicromap2StateEXT: bool = false,3914 force_opacity_micromap2state_ext: bool = false,
3625 _reserved_bit_11: bool = false,3915 _reserved_bit_11: bool = false,
3626 _reserved_bit_12: bool = false,3916 _reserved_bit_12: bool = false,
3627 _reserved_bit_13: bool = false,3917 _reserved_bit_13: bool = false,
...@@ -3645,10 +3935,10 @@ pub const RayFlags = packed struct {...@@ -3645,10 +3935,10 @@ pub const RayFlags = packed struct {
3645 _reserved_bit_31: bool = false,3935 _reserved_bit_31: bool = false,
3646};3936};
3647pub const FragmentShadingRate = packed struct {3937pub const FragmentShadingRate = packed struct {
3648 Vertical2Pixels: bool = false,3938 vertical2pixels: bool = false,
3649 Vertical4Pixels: bool = false,3939 vertical4pixels: bool = false,
3650 Horizontal2Pixels: bool = false,3940 horizontal2pixels: bool = false,
3651 Horizontal4Pixels: bool = false,3941 horizontal4pixels: bool = false,
3652 _reserved_bit_4: bool = false,3942 _reserved_bit_4: bool = false,
3653 _reserved_bit_5: bool = false,3943 _reserved_bit_5: bool = false,
3654 _reserved_bit_6: bool = false,3944 _reserved_bit_6: bool = false,
...@@ -3679,8 +3969,8 @@ pub const FragmentShadingRate = packed struct {...@@ -3679,8 +3969,8 @@ pub const FragmentShadingRate = packed struct {
3679 _reserved_bit_31: bool = false,3969 _reserved_bit_31: bool = false,
3680};3970};
3681pub const RawAccessChainOperands = packed struct {3971pub const RawAccessChainOperands = packed struct {
3682 RobustnessPerComponentNV: bool = false,3972 robustness_per_component_nv: bool = false,
3683 RobustnessPerElementNV: bool = false,3973 robustness_per_element_nv: bool = false,
3684 _reserved_bit_2: bool = false,3974 _reserved_bit_2: bool = false,
3685 _reserved_bit_3: bool = false,3975 _reserved_bit_3: bool = false,
3686 _reserved_bit_4: bool = false,3976 _reserved_bit_4: bool = false,
...@@ -3713,1199 +4003,1187 @@ pub const RawAccessChainOperands = packed struct {...@@ -3713,1199 +4003,1187 @@ pub const RawAccessChainOperands = packed struct {
3713 _reserved_bit_31: bool = false,4003 _reserved_bit_31: bool = false,
3714};4004};
3715pub const SourceLanguage = enum(u32) {4005pub const SourceLanguage = enum(u32) {
3716 Unknown = 0,4006 unknown = 0,
3717 ESSL = 1,4007 essl = 1,
3718 GLSL = 2,4008 glsl = 2,
3719 OpenCL_C = 3,4009 open_cl_c = 3,
3720 OpenCL_CPP = 4,4010 open_cl_cpp = 4,
3721 HLSL = 5,4011 hlsl = 5,
3722 CPP_for_OpenCL = 6,4012 cpp_for_open_cl = 6,
3723 SYCL = 7,4013 sycl = 7,
3724 HERO_C = 8,4014 hero_c = 8,
3725 NZSL = 9,4015 nzsl = 9,
3726 WGSL = 10,4016 wgsl = 10,
3727 Slang = 11,4017 slang = 11,
3728 Zig = 12,4018 zig = 12,
4019 rust = 13,
3729};4020};
3730pub const ExecutionModel = enum(u32) {4021pub const ExecutionModel = enum(u32) {
3731 Vertex = 0,4022 vertex = 0,
3732 TessellationControl = 1,4023 tessellation_control = 1,
3733 TessellationEvaluation = 2,4024 tessellation_evaluation = 2,
3734 Geometry = 3,4025 geometry = 3,
3735 Fragment = 4,4026 fragment = 4,
3736 GLCompute = 5,4027 gl_compute = 5,
3737 Kernel = 6,4028 kernel = 6,
3738 TaskNV = 5267,4029 task_nv = 5267,
3739 MeshNV = 5268,4030 mesh_nv = 5268,
3740 RayGenerationKHR = 5313,4031 ray_generation_khr = 5313,
3741 IntersectionKHR = 5314,4032 intersection_khr = 5314,
3742 AnyHitKHR = 5315,4033 any_hit_khr = 5315,
3743 ClosestHitKHR = 5316,4034 closest_hit_khr = 5316,
3744 MissKHR = 5317,4035 miss_khr = 5317,
3745 CallableKHR = 5318,4036 callable_khr = 5318,
3746 TaskEXT = 5364,4037 task_ext = 5364,
3747 MeshEXT = 5365,4038 mesh_ext = 5365,
3748
3749 pub const RayGenerationNV = ExecutionModel.RayGenerationKHR;
3750 pub const IntersectionNV = ExecutionModel.IntersectionKHR;
3751 pub const AnyHitNV = ExecutionModel.AnyHitKHR;
3752 pub const ClosestHitNV = ExecutionModel.ClosestHitKHR;
3753 pub const MissNV = ExecutionModel.MissKHR;
3754 pub const CallableNV = ExecutionModel.CallableKHR;
3755};4039};
3756pub const AddressingModel = enum(u32) {4040pub const AddressingModel = enum(u32) {
3757 Logical = 0,4041 logical = 0,
3758 Physical32 = 1,4042 physical32 = 1,
3759 Physical64 = 2,4043 physical64 = 2,
3760 PhysicalStorageBuffer64 = 5348,4044 physical_storage_buffer64 = 5348,
3761
3762 pub const PhysicalStorageBuffer64EXT = AddressingModel.PhysicalStorageBuffer64;
3763};4045};
3764pub const MemoryModel = enum(u32) {4046pub const MemoryModel = enum(u32) {
3765 Simple = 0,4047 simple = 0,
3766 GLSL450 = 1,4048 glsl450 = 1,
3767 OpenCL = 2,4049 open_cl = 2,
3768 Vulkan = 3,4050 vulkan = 3,
3769
3770 pub const VulkanKHR = MemoryModel.Vulkan;
3771};4051};
3772pub const ExecutionMode = enum(u32) {4052pub const ExecutionMode = enum(u32) {
3773 Invocations = 0,4053 invocations = 0,
3774 SpacingEqual = 1,4054 spacing_equal = 1,
3775 SpacingFractionalEven = 2,4055 spacing_fractional_even = 2,
3776 SpacingFractionalOdd = 3,4056 spacing_fractional_odd = 3,
3777 VertexOrderCw = 4,4057 vertex_order_cw = 4,
3778 VertexOrderCcw = 5,4058 vertex_order_ccw = 5,
3779 PixelCenterInteger = 6,4059 pixel_center_integer = 6,
3780 OriginUpperLeft = 7,4060 origin_upper_left = 7,
3781 OriginLowerLeft = 8,4061 origin_lower_left = 8,
3782 EarlyFragmentTests = 9,4062 early_fragment_tests = 9,
3783 PointMode = 10,4063 point_mode = 10,
3784 Xfb = 11,4064 xfb = 11,
3785 DepthReplacing = 12,4065 depth_replacing = 12,
3786 DepthGreater = 14,4066 depth_greater = 14,
3787 DepthLess = 15,4067 depth_less = 15,
3788 DepthUnchanged = 16,4068 depth_unchanged = 16,
3789 LocalSize = 17,4069 local_size = 17,
3790 LocalSizeHint = 18,4070 local_size_hint = 18,
3791 InputPoints = 19,4071 input_points = 19,
3792 InputLines = 20,4072 input_lines = 20,
3793 InputLinesAdjacency = 21,4073 input_lines_adjacency = 21,
3794 Triangles = 22,4074 triangles = 22,
3795 InputTrianglesAdjacency = 23,4075 input_triangles_adjacency = 23,
3796 Quads = 24,4076 quads = 24,
3797 Isolines = 25,4077 isolines = 25,
3798 OutputVertices = 26,4078 output_vertices = 26,
3799 OutputPoints = 27,4079 output_points = 27,
3800 OutputLineStrip = 28,4080 output_line_strip = 28,
3801 OutputTriangleStrip = 29,4081 output_triangle_strip = 29,
3802 VecTypeHint = 30,4082 vec_type_hint = 30,
3803 ContractionOff = 31,4083 contraction_off = 31,
3804 Initializer = 33,4084 initializer = 33,
3805 Finalizer = 34,4085 finalizer = 34,
3806 SubgroupSize = 35,4086 subgroup_size = 35,
3807 SubgroupsPerWorkgroup = 36,4087 subgroups_per_workgroup = 36,
3808 SubgroupsPerWorkgroupId = 37,4088 subgroups_per_workgroup_id = 37,
3809 LocalSizeId = 38,4089 local_size_id = 38,
3810 LocalSizeHintId = 39,4090 local_size_hint_id = 39,
3811 NonCoherentColorAttachmentReadEXT = 4169,4091 non_coherent_color_attachment_read_ext = 4169,
3812 NonCoherentDepthAttachmentReadEXT = 4170,4092 non_coherent_depth_attachment_read_ext = 4170,
3813 NonCoherentStencilAttachmentReadEXT = 4171,4093 non_coherent_stencil_attachment_read_ext = 4171,
3814 SubgroupUniformControlFlowKHR = 4421,4094 subgroup_uniform_control_flow_khr = 4421,
3815 PostDepthCoverage = 4446,4095 post_depth_coverage = 4446,
3816 DenormPreserve = 4459,4096 denorm_preserve = 4459,
3817 DenormFlushToZero = 4460,4097 denorm_flush_to_zero = 4460,
3818 SignedZeroInfNanPreserve = 4461,4098 signed_zero_inf_nan_preserve = 4461,
3819 RoundingModeRTE = 4462,4099 rounding_mode_rte = 4462,
3820 RoundingModeRTZ = 4463,4100 rounding_mode_rtz = 4463,
3821 EarlyAndLateFragmentTestsAMD = 5017,4101 non_coherent_tile_attachment_read_qcom = 4489,
3822 StencilRefReplacingEXT = 5027,4102 tile_shading_rate_qcom = 4490,
3823 CoalescingAMDX = 5069,4103 early_and_late_fragment_tests_amd = 5017,
3824 MaxNodeRecursionAMDX = 5071,4104 stencil_ref_replacing_ext = 5027,
3825 StaticNumWorkgroupsAMDX = 5072,4105 coalescing_amdx = 5069,
3826 ShaderIndexAMDX = 5073,4106 is_api_entry_amdx = 5070,
3827 MaxNumWorkgroupsAMDX = 5077,4107 max_node_recursion_amdx = 5071,
3828 StencilRefUnchangedFrontAMD = 5079,4108 static_num_workgroups_amdx = 5072,
3829 StencilRefGreaterFrontAMD = 5080,4109 shader_index_amdx = 5073,
3830 StencilRefLessFrontAMD = 5081,4110 max_num_workgroups_amdx = 5077,
3831 StencilRefUnchangedBackAMD = 5082,4111 stencil_ref_unchanged_front_amd = 5079,
3832 StencilRefGreaterBackAMD = 5083,4112 stencil_ref_greater_front_amd = 5080,
3833 StencilRefLessBackAMD = 5084,4113 stencil_ref_less_front_amd = 5081,
3834 QuadDerivativesKHR = 5088,4114 stencil_ref_unchanged_back_amd = 5082,
3835 RequireFullQuadsKHR = 5089,4115 stencil_ref_greater_back_amd = 5083,
3836 OutputLinesEXT = 5269,4116 stencil_ref_less_back_amd = 5084,
3837 OutputPrimitivesEXT = 5270,4117 quad_derivatives_khr = 5088,
3838 DerivativeGroupQuadsNV = 5289,4118 require_full_quads_khr = 5089,
3839 DerivativeGroupLinearNV = 5290,4119 shares_input_with_amdx = 5102,
3840 OutputTrianglesEXT = 5298,4120 output_lines_ext = 5269,
3841 PixelInterlockOrderedEXT = 5366,4121 output_primitives_ext = 5270,
3842 PixelInterlockUnorderedEXT = 5367,4122 derivative_group_quads_khr = 5289,
3843 SampleInterlockOrderedEXT = 5368,4123 derivative_group_linear_khr = 5290,
3844 SampleInterlockUnorderedEXT = 5369,4124 output_triangles_ext = 5298,
3845 ShadingRateInterlockOrderedEXT = 5370,4125 pixel_interlock_ordered_ext = 5366,
3846 ShadingRateInterlockUnorderedEXT = 5371,4126 pixel_interlock_unordered_ext = 5367,
3847 SharedLocalMemorySizeINTEL = 5618,4127 sample_interlock_ordered_ext = 5368,
3848 RoundingModeRTPINTEL = 5620,4128 sample_interlock_unordered_ext = 5369,
3849 RoundingModeRTNINTEL = 5621,4129 shading_rate_interlock_ordered_ext = 5370,
3850 FloatingPointModeALTINTEL = 5622,4130 shading_rate_interlock_unordered_ext = 5371,
3851 FloatingPointModeIEEEINTEL = 5623,4131 shared_local_memory_size_intel = 5618,
3852 MaxWorkgroupSizeINTEL = 5893,4132 rounding_mode_rtpintel = 5620,
3853 MaxWorkDimINTEL = 5894,4133 rounding_mode_rtnintel = 5621,
3854 NoGlobalOffsetINTEL = 5895,4134 floating_point_mode_altintel = 5622,
3855 NumSIMDWorkitemsINTEL = 5896,4135 floating_point_mode_ieeeintel = 5623,
3856 SchedulerTargetFmaxMhzINTEL = 5903,4136 max_workgroup_size_intel = 5893,
3857 MaximallyReconvergesKHR = 6023,4137 max_work_dim_intel = 5894,
3858 FPFastMathDefault = 6028,4138 no_global_offset_intel = 5895,
3859 StreamingInterfaceINTEL = 6154,4139 num_simd_workitems_intel = 5896,
3860 RegisterMapInterfaceINTEL = 6160,4140 scheduler_target_fmax_mhz_intel = 5903,
3861 NamedBarrierCountINTEL = 6417,4141 maximally_reconverges_khr = 6023,
3862 MaximumRegistersINTEL = 6461,4142 fp_fast_math_default = 6028,
3863 MaximumRegistersIdINTEL = 6462,4143 streaming_interface_intel = 6154,
3864 NamedMaximumRegistersINTEL = 6463,4144 register_map_interface_intel = 6160,
38654145 named_barrier_count_intel = 6417,
3866 pub const OutputLinesNV = ExecutionMode.OutputLinesEXT;4146 maximum_registers_intel = 6461,
3867 pub const OutputPrimitivesNV = ExecutionMode.OutputPrimitivesEXT;4147 maximum_registers_id_intel = 6462,
3868 pub const OutputTrianglesNV = ExecutionMode.OutputTrianglesEXT;4148 named_maximum_registers_intel = 6463,
38694149
3870 pub const Extended = union(ExecutionMode) {4150 pub const Extended = union(ExecutionMode) {
3871 Invocations: struct { literal_integer: LiteralInteger },4151 invocations: struct { literal_integer: LiteralInteger },
3872 SpacingEqual,4152 spacing_equal,
3873 SpacingFractionalEven,4153 spacing_fractional_even,
3874 SpacingFractionalOdd,4154 spacing_fractional_odd,
3875 VertexOrderCw,4155 vertex_order_cw,
3876 VertexOrderCcw,4156 vertex_order_ccw,
3877 PixelCenterInteger,4157 pixel_center_integer,
3878 OriginUpperLeft,4158 origin_upper_left,
3879 OriginLowerLeft,4159 origin_lower_left,
3880 EarlyFragmentTests,4160 early_fragment_tests,
3881 PointMode,4161 point_mode,
3882 Xfb,4162 xfb,
3883 DepthReplacing,4163 depth_replacing,
3884 DepthGreater,4164 depth_greater,
3885 DepthLess,4165 depth_less,
3886 DepthUnchanged,4166 depth_unchanged,
3887 LocalSize: struct { x_size: LiteralInteger, y_size: LiteralInteger, z_size: LiteralInteger },4167 local_size: struct { x_size: LiteralInteger, y_size: LiteralInteger, z_size: LiteralInteger },
3888 LocalSizeHint: struct { x_size: LiteralInteger, y_size: LiteralInteger, z_size: LiteralInteger },4168 local_size_hint: struct { x_size: LiteralInteger, y_size: LiteralInteger, z_size: LiteralInteger },
3889 InputPoints,4169 input_points,
3890 InputLines,4170 input_lines,
3891 InputLinesAdjacency,4171 input_lines_adjacency,
3892 Triangles,4172 triangles,
3893 InputTrianglesAdjacency,4173 input_triangles_adjacency,
3894 Quads,4174 quads,
3895 Isolines,4175 isolines,
3896 OutputVertices: struct { vertex_count: LiteralInteger },4176 output_vertices: struct { vertex_count: LiteralInteger },
3897 OutputPoints,4177 output_points,
3898 OutputLineStrip,4178 output_line_strip,
3899 OutputTriangleStrip,4179 output_triangle_strip,
3900 VecTypeHint: struct { vector_type: LiteralInteger },4180 vec_type_hint: struct { vector_type: LiteralInteger },
3901 ContractionOff,4181 contraction_off,
3902 Initializer,4182 initializer,
3903 Finalizer,4183 finalizer,
3904 SubgroupSize: struct { subgroup_size: LiteralInteger },4184 subgroup_size: struct { subgroup_size: LiteralInteger },
3905 SubgroupsPerWorkgroup: struct { subgroups_per_workgroup: LiteralInteger },4185 subgroups_per_workgroup: struct { subgroups_per_workgroup: LiteralInteger },
3906 SubgroupsPerWorkgroupId: struct { subgroups_per_workgroup: IdRef },4186 subgroups_per_workgroup_id: struct { subgroups_per_workgroup: Id },
3907 LocalSizeId: struct { x_size: IdRef, y_size: IdRef, z_size: IdRef },4187 local_size_id: struct { x_size: Id, y_size: Id, z_size: Id },
3908 LocalSizeHintId: struct { x_size_hint: IdRef, y_size_hint: IdRef, z_size_hint: IdRef },4188 local_size_hint_id: struct { x_size_hint: Id, y_size_hint: Id, z_size_hint: Id },
3909 NonCoherentColorAttachmentReadEXT,4189 non_coherent_color_attachment_read_ext,
3910 NonCoherentDepthAttachmentReadEXT,4190 non_coherent_depth_attachment_read_ext,
3911 NonCoherentStencilAttachmentReadEXT,4191 non_coherent_stencil_attachment_read_ext,
3912 SubgroupUniformControlFlowKHR,4192 subgroup_uniform_control_flow_khr,
3913 PostDepthCoverage,4193 post_depth_coverage,
3914 DenormPreserve: struct { target_width: LiteralInteger },4194 denorm_preserve: struct { target_width: LiteralInteger },
3915 DenormFlushToZero: struct { target_width: LiteralInteger },4195 denorm_flush_to_zero: struct { target_width: LiteralInteger },
3916 SignedZeroInfNanPreserve: struct { target_width: LiteralInteger },4196 signed_zero_inf_nan_preserve: struct { target_width: LiteralInteger },
3917 RoundingModeRTE: struct { target_width: LiteralInteger },4197 rounding_mode_rte: struct { target_width: LiteralInteger },
3918 RoundingModeRTZ: struct { target_width: LiteralInteger },4198 rounding_mode_rtz: struct { target_width: LiteralInteger },
3919 EarlyAndLateFragmentTestsAMD,4199 non_coherent_tile_attachment_read_qcom,
3920 StencilRefReplacingEXT,4200 tile_shading_rate_qcom: struct { x_rate: LiteralInteger, y_rate: LiteralInteger, z_rate: LiteralInteger },
3921 CoalescingAMDX,4201 early_and_late_fragment_tests_amd,
3922 MaxNodeRecursionAMDX: struct { number_of_recursions: IdRef },4202 stencil_ref_replacing_ext,
3923 StaticNumWorkgroupsAMDX: struct { x_size: IdRef, y_size: IdRef, z_size: IdRef },4203 coalescing_amdx,
3924 ShaderIndexAMDX: struct { shader_index: IdRef },4204 is_api_entry_amdx: struct { is_entry: Id },
3925 MaxNumWorkgroupsAMDX: struct { x_size: IdRef, y_size: IdRef, z_size: IdRef },4205 max_node_recursion_amdx: struct { number_of_recursions: Id },
3926 StencilRefUnchangedFrontAMD,4206 static_num_workgroups_amdx: struct { x_size: Id, y_size: Id, z_size: Id },
3927 StencilRefGreaterFrontAMD,4207 shader_index_amdx: struct { shader_index: Id },
3928 StencilRefLessFrontAMD,4208 max_num_workgroups_amdx: struct { x_size: Id, y_size: Id, z_size: Id },
3929 StencilRefUnchangedBackAMD,4209 stencil_ref_unchanged_front_amd,
3930 StencilRefGreaterBackAMD,4210 stencil_ref_greater_front_amd,
3931 StencilRefLessBackAMD,4211 stencil_ref_less_front_amd,
3932 QuadDerivativesKHR,4212 stencil_ref_unchanged_back_amd,
3933 RequireFullQuadsKHR,4213 stencil_ref_greater_back_amd,
3934 OutputLinesEXT,4214 stencil_ref_less_back_amd,
3935 OutputPrimitivesEXT: struct { primitive_count: LiteralInteger },4215 quad_derivatives_khr,
3936 DerivativeGroupQuadsNV,4216 require_full_quads_khr,
3937 DerivativeGroupLinearNV,4217 shares_input_with_amdx: struct { node_name: Id, shader_index: Id },
3938 OutputTrianglesEXT,4218 output_lines_ext,
3939 PixelInterlockOrderedEXT,4219 output_primitives_ext: struct { primitive_count: LiteralInteger },
3940 PixelInterlockUnorderedEXT,4220 derivative_group_quads_khr,
3941 SampleInterlockOrderedEXT,4221 derivative_group_linear_khr,
3942 SampleInterlockUnorderedEXT,4222 output_triangles_ext,
3943 ShadingRateInterlockOrderedEXT,4223 pixel_interlock_ordered_ext,
3944 ShadingRateInterlockUnorderedEXT,4224 pixel_interlock_unordered_ext,
3945 SharedLocalMemorySizeINTEL: struct { size: LiteralInteger },4225 sample_interlock_ordered_ext,
3946 RoundingModeRTPINTEL: struct { target_width: LiteralInteger },4226 sample_interlock_unordered_ext,
3947 RoundingModeRTNINTEL: struct { target_width: LiteralInteger },4227 shading_rate_interlock_ordered_ext,
3948 FloatingPointModeALTINTEL: struct { target_width: LiteralInteger },4228 shading_rate_interlock_unordered_ext,
3949 FloatingPointModeIEEEINTEL: struct { target_width: LiteralInteger },4229 shared_local_memory_size_intel: struct { size: LiteralInteger },
3950 MaxWorkgroupSizeINTEL: struct { literal_integer_0: LiteralInteger, literal_integer_1: LiteralInteger, literal_integer_2: LiteralInteger },4230 rounding_mode_rtpintel: struct { target_width: LiteralInteger },
3951 MaxWorkDimINTEL: struct { literal_integer: LiteralInteger },4231 rounding_mode_rtnintel: struct { target_width: LiteralInteger },
3952 NoGlobalOffsetINTEL,4232 floating_point_mode_altintel: struct { target_width: LiteralInteger },
3953 NumSIMDWorkitemsINTEL: struct { literal_integer: LiteralInteger },4233 floating_point_mode_ieeeintel: struct { target_width: LiteralInteger },
3954 SchedulerTargetFmaxMhzINTEL: struct { literal_integer: LiteralInteger },4234 max_workgroup_size_intel: struct { literal_integer_0: LiteralInteger, literal_integer_1: LiteralInteger, literal_integer_2: LiteralInteger },
3955 MaximallyReconvergesKHR,4235 max_work_dim_intel: struct { literal_integer: LiteralInteger },
3956 FPFastMathDefault: struct { target_type: IdRef, id_ref_1: IdRef },4236 no_global_offset_intel,
3957 StreamingInterfaceINTEL: struct { stallfreereturn: LiteralInteger },4237 num_simd_workitems_intel: struct { literal_integer: LiteralInteger },
3958 RegisterMapInterfaceINTEL: struct { waitfordonewrite: LiteralInteger },4238 scheduler_target_fmax_mhz_intel: struct { literal_integer: LiteralInteger },
3959 NamedBarrierCountINTEL: struct { barrier_count: LiteralInteger },4239 maximally_reconverges_khr,
3960 MaximumRegistersINTEL: struct { number_of_registers: LiteralInteger },4240 fp_fast_math_default: struct { target_type: Id, id_ref_1: Id },
3961 MaximumRegistersIdINTEL: struct { number_of_registers: IdRef },4241 streaming_interface_intel: struct { stall_free_return: LiteralInteger },
3962 NamedMaximumRegistersINTEL: struct { named_maximum_number_of_registers: NamedMaximumNumberOfRegisters },4242 register_map_interface_intel: struct { wait_for_done_write: LiteralInteger },
4243 named_barrier_count_intel: struct { barrier_count: LiteralInteger },
4244 maximum_registers_intel: struct { number_of_registers: LiteralInteger },
4245 maximum_registers_id_intel: struct { number_of_registers: Id },
4246 named_maximum_registers_intel: struct { named_maximum_number_of_registers: NamedMaximumNumberOfRegisters },
3963 };4247 };
3964};4248};
3965pub const StorageClass = enum(u32) {4249pub const StorageClass = enum(u32) {
3966 UniformConstant = 0,4250 uniform_constant = 0,
3967 Input = 1,4251 input = 1,
3968 Uniform = 2,4252 uniform = 2,
3969 Output = 3,4253 output = 3,
3970 Workgroup = 4,4254 workgroup = 4,
3971 CrossWorkgroup = 5,4255 cross_workgroup = 5,
3972 Private = 6,4256 private = 6,
3973 Function = 7,4257 function = 7,
3974 Generic = 8,4258 generic = 8,
3975 PushConstant = 9,4259 push_constant = 9,
3976 AtomicCounter = 10,4260 atomic_counter = 10,
3977 Image = 11,4261 image = 11,
3978 StorageBuffer = 12,4262 storage_buffer = 12,
3979 TileImageEXT = 4172,4263 tile_image_ext = 4172,
3980 NodePayloadAMDX = 5068,4264 tile_attachment_qcom = 4491,
3981 NodeOutputPayloadAMDX = 5076,4265 node_payload_amdx = 5068,
3982 CallableDataKHR = 5328,4266 callable_data_khr = 5328,
3983 IncomingCallableDataKHR = 5329,4267 incoming_callable_data_khr = 5329,
3984 RayPayloadKHR = 5338,4268 ray_payload_khr = 5338,
3985 HitAttributeKHR = 5339,4269 hit_attribute_khr = 5339,
3986 IncomingRayPayloadKHR = 5342,4270 incoming_ray_payload_khr = 5342,
3987 ShaderRecordBufferKHR = 5343,4271 shader_record_buffer_khr = 5343,
3988 PhysicalStorageBuffer = 5349,4272 physical_storage_buffer = 5349,
3989 HitObjectAttributeNV = 5385,4273 hit_object_attribute_nv = 5385,
3990 TaskPayloadWorkgroupEXT = 5402,4274 task_payload_workgroup_ext = 5402,
3991 CodeSectionINTEL = 5605,4275 code_section_intel = 5605,
3992 DeviceOnlyINTEL = 5936,4276 device_only_intel = 5936,
3993 HostOnlyINTEL = 5937,4277 host_only_intel = 5937,
3994
3995 pub const CallableDataNV = StorageClass.CallableDataKHR;
3996 pub const IncomingCallableDataNV = StorageClass.IncomingCallableDataKHR;
3997 pub const RayPayloadNV = StorageClass.RayPayloadKHR;
3998 pub const HitAttributeNV = StorageClass.HitAttributeKHR;
3999 pub const IncomingRayPayloadNV = StorageClass.IncomingRayPayloadKHR;
4000 pub const ShaderRecordBufferNV = StorageClass.ShaderRecordBufferKHR;
4001 pub const PhysicalStorageBufferEXT = StorageClass.PhysicalStorageBuffer;
4002};4278};
4003pub const Dim = enum(u32) {4279pub const Dim = enum(u32) {
4004 @"1D" = 0,4280 @"1d" = 0,
4005 @"2D" = 1,4281 @"2d" = 1,
4006 @"3D" = 2,4282 @"3d" = 2,
4007 Cube = 3,4283 cube = 3,
4008 Rect = 4,4284 rect = 4,
4009 Buffer = 5,4285 buffer = 5,
4010 SubpassData = 6,4286 subpass_data = 6,
4011 TileImageDataEXT = 4173,4287 tile_image_data_ext = 4173,
4012};4288};
4013pub const SamplerAddressingMode = enum(u32) {4289pub const SamplerAddressingMode = enum(u32) {
4014 None = 0,4290 none = 0,
4015 ClampToEdge = 1,4291 clamp_to_edge = 1,
4016 Clamp = 2,4292 clamp = 2,
4017 Repeat = 3,4293 repeat = 3,
4018 RepeatMirrored = 4,4294 repeat_mirrored = 4,
4019};4295};
4020pub const SamplerFilterMode = enum(u32) {4296pub const SamplerFilterMode = enum(u32) {
4021 Nearest = 0,4297 nearest = 0,
4022 Linear = 1,4298 linear = 1,
4023};4299};
4024pub const ImageFormat = enum(u32) {4300pub const ImageFormat = enum(u32) {
4025 Unknown = 0,4301 unknown = 0,
4026 Rgba32f = 1,4302 rgba32f = 1,
4027 Rgba16f = 2,4303 rgba16f = 2,
4028 R32f = 3,4304 r32f = 3,
4029 Rgba8 = 4,4305 rgba8 = 4,
4030 Rgba8Snorm = 5,4306 rgba8snorm = 5,
4031 Rg32f = 6,4307 rg32f = 6,
4032 Rg16f = 7,4308 rg16f = 7,
4033 R11fG11fB10f = 8,4309 r11f_g11f_b10f = 8,
4034 R16f = 9,4310 r16f = 9,
4035 Rgba16 = 10,4311 rgba16 = 10,
4036 Rgb10A2 = 11,4312 rgb10a2 = 11,
4037 Rg16 = 12,4313 rg16 = 12,
4038 Rg8 = 13,4314 rg8 = 13,
4039 R16 = 14,4315 r16 = 14,
4040 R8 = 15,4316 r8 = 15,
4041 Rgba16Snorm = 16,4317 rgba16snorm = 16,
4042 Rg16Snorm = 17,4318 rg16snorm = 17,
4043 Rg8Snorm = 18,4319 rg8snorm = 18,
4044 R16Snorm = 19,4320 r16snorm = 19,
4045 R8Snorm = 20,4321 r8snorm = 20,
4046 Rgba32i = 21,4322 rgba32i = 21,
4047 Rgba16i = 22,4323 rgba16i = 22,
4048 Rgba8i = 23,4324 rgba8i = 23,
4049 R32i = 24,4325 r32i = 24,
4050 Rg32i = 25,4326 rg32i = 25,
4051 Rg16i = 26,4327 rg16i = 26,
4052 Rg8i = 27,4328 rg8i = 27,
4053 R16i = 28,4329 r16i = 28,
4054 R8i = 29,4330 r8i = 29,
4055 Rgba32ui = 30,4331 rgba32ui = 30,
4056 Rgba16ui = 31,4332 rgba16ui = 31,
4057 Rgba8ui = 32,4333 rgba8ui = 32,
4058 R32ui = 33,4334 r32ui = 33,
4059 Rgb10a2ui = 34,4335 rgb10a2ui = 34,
4060 Rg32ui = 35,4336 rg32ui = 35,
4061 Rg16ui = 36,4337 rg16ui = 36,
4062 Rg8ui = 37,4338 rg8ui = 37,
4063 R16ui = 38,4339 r16ui = 38,
4064 R8ui = 39,4340 r8ui = 39,
4065 R64ui = 40,4341 r64ui = 40,
4066 R64i = 41,4342 r64i = 41,
4067};4343};
4068pub const ImageChannelOrder = enum(u32) {4344pub const ImageChannelOrder = enum(u32) {
4069 R = 0,4345 r = 0,
4070 A = 1,4346 a = 1,
4071 RG = 2,4347 rg = 2,
4072 RA = 3,4348 ra = 3,
4073 RGB = 4,4349 rgb = 4,
4074 RGBA = 5,4350 rgba = 5,
4075 BGRA = 6,4351 bgra = 6,
4076 ARGB = 7,4352 argb = 7,
4077 Intensity = 8,4353 intensity = 8,
4078 Luminance = 9,4354 luminance = 9,
4079 Rx = 10,4355 rx = 10,
4080 RGx = 11,4356 r_gx = 11,
4081 RGBx = 12,4357 rg_bx = 12,
4082 Depth = 13,4358 depth = 13,
4083 DepthStencil = 14,4359 depth_stencil = 14,
4084 sRGB = 15,4360 s_rgb = 15,
4085 sRGBx = 16,4361 s_rg_bx = 16,
4086 sRGBA = 17,4362 s_rgba = 17,
4087 sBGRA = 18,4363 s_bgra = 18,
4088 ABGR = 19,4364 abgr = 19,
4089};4365};
4090pub const ImageChannelDataType = enum(u32) {4366pub const ImageChannelDataType = enum(u32) {
4091 SnormInt8 = 0,4367 snorm_int8 = 0,
4092 SnormInt16 = 1,4368 snorm_int16 = 1,
4093 UnormInt8 = 2,4369 unorm_int8 = 2,
4094 UnormInt16 = 3,4370 unorm_int16 = 3,
4095 UnormShort565 = 4,4371 unorm_short565 = 4,
4096 UnormShort555 = 5,4372 unorm_short555 = 5,
4097 UnormInt101010 = 6,4373 unorm_int101010 = 6,
4098 SignedInt8 = 7,4374 signed_int8 = 7,
4099 SignedInt16 = 8,4375 signed_int16 = 8,
4100 SignedInt32 = 9,4376 signed_int32 = 9,
4101 UnsignedInt8 = 10,4377 unsigned_int8 = 10,
4102 UnsignedInt16 = 11,4378 unsigned_int16 = 11,
4103 UnsignedInt32 = 12,4379 unsigned_int32 = 12,
4104 HalfFloat = 13,4380 half_float = 13,
4105 Float = 14,4381 float = 14,
4106 UnormInt24 = 15,4382 unorm_int24 = 15,
4107 UnormInt101010_2 = 16,4383 unorm_int101010_2 = 16,
4108 UnsignedIntRaw10EXT = 19,4384 unorm_int10x6ext = 17,
4109 UnsignedIntRaw12EXT = 20,4385 unsigned_int_raw10ext = 19,
4386 unsigned_int_raw12ext = 20,
4387 unorm_int2_101010ext = 21,
4388 unsigned_int10x6ext = 22,
4389 unsigned_int12x4ext = 23,
4390 unsigned_int14x2ext = 24,
4391 unorm_int12x4ext = 25,
4392 unorm_int14x2ext = 26,
4110};4393};
4111pub const FPRoundingMode = enum(u32) {4394pub const FPRoundingMode = enum(u32) {
4112 RTE = 0,4395 rte = 0,
4113 RTZ = 1,4396 rtz = 1,
4114 RTP = 2,4397 rtp = 2,
4115 RTN = 3,4398 rtn = 3,
4116};4399};
4117pub const FPDenormMode = enum(u32) {4400pub const FPDenormMode = enum(u32) {
4118 Preserve = 0,4401 preserve = 0,
4119 FlushToZero = 1,4402 flush_to_zero = 1,
4120};4403};
4121pub const QuantizationModes = enum(u32) {4404pub const QuantizationModes = enum(u32) {
4122 TRN = 0,4405 trn = 0,
4123 TRN_ZERO = 1,4406 trn_zero = 1,
4124 RND = 2,4407 rnd = 2,
4125 RND_ZERO = 3,4408 rnd_zero = 3,
4126 RND_INF = 4,4409 rnd_inf = 4,
4127 RND_MIN_INF = 5,4410 rnd_min_inf = 5,
4128 RND_CONV = 6,4411 rnd_conv = 6,
4129 RND_CONV_ODD = 7,4412 rnd_conv_odd = 7,
4130};4413};
4131pub const FPOperationMode = enum(u32) {4414pub const FPOperationMode = enum(u32) {
4132 IEEE = 0,4415 ieee = 0,
4133 ALT = 1,4416 alt = 1,
4134};4417};
4135pub const OverflowModes = enum(u32) {4418pub const OverflowModes = enum(u32) {
4136 WRAP = 0,4419 wrap = 0,
4137 SAT = 1,4420 sat = 1,
4138 SAT_ZERO = 2,4421 sat_zero = 2,
4139 SAT_SYM = 3,4422 sat_sym = 3,
4140};4423};
4141pub const LinkageType = enum(u32) {4424pub const LinkageType = enum(u32) {
4142 Export = 0,4425 @"export" = 0,
4143 Import = 1,4426 import = 1,
4144 LinkOnceODR = 2,4427 link_once_odr = 2,
4145};4428};
4146pub const AccessQualifier = enum(u32) {4429pub const AccessQualifier = enum(u32) {
4147 ReadOnly = 0,4430 read_only = 0,
4148 WriteOnly = 1,4431 write_only = 1,
4149 ReadWrite = 2,4432 read_write = 2,
4150};4433};
4151pub const HostAccessQualifier = enum(u32) {4434pub const HostAccessQualifier = enum(u32) {
4152 NoneINTEL = 0,4435 none_intel = 0,
4153 ReadINTEL = 1,4436 read_intel = 1,
4154 WriteINTEL = 2,4437 write_intel = 2,
4155 ReadWriteINTEL = 3,4438 read_write_intel = 3,
4156};4439};
4157pub const FunctionParameterAttribute = enum(u32) {4440pub const FunctionParameterAttribute = enum(u32) {
4158 Zext = 0,4441 zext = 0,
4159 Sext = 1,4442 sext = 1,
4160 ByVal = 2,4443 by_val = 2,
4161 Sret = 3,4444 sret = 3,
4162 NoAlias = 4,4445 no_alias = 4,
4163 NoCapture = 5,4446 no_capture = 5,
4164 NoWrite = 6,4447 no_write = 6,
4165 NoReadWrite = 7,4448 no_read_write = 7,
4166 RuntimeAlignedINTEL = 5940,4449 runtime_aligned_intel = 5940,
4167};4450};
4168pub const Decoration = enum(u32) {4451pub const Decoration = enum(u32) {
4169 RelaxedPrecision = 0,4452 relaxed_precision = 0,
4170 SpecId = 1,4453 spec_id = 1,
4171 Block = 2,4454 block = 2,
4172 BufferBlock = 3,4455 buffer_block = 3,
4173 RowMajor = 4,4456 row_major = 4,
4174 ColMajor = 5,4457 col_major = 5,
4175 ArrayStride = 6,4458 array_stride = 6,
4176 MatrixStride = 7,4459 matrix_stride = 7,
4177 GLSLShared = 8,4460 glsl_shared = 8,
4178 GLSLPacked = 9,4461 glsl_packed = 9,
4179 CPacked = 10,4462 c_packed = 10,
4180 BuiltIn = 11,4463 built_in = 11,
4181 NoPerspective = 13,4464 no_perspective = 13,
4182 Flat = 14,4465 flat = 14,
4183 Patch = 15,4466 patch = 15,
4184 Centroid = 16,4467 centroid = 16,
4185 Sample = 17,4468 sample = 17,
4186 Invariant = 18,4469 invariant = 18,
4187 Restrict = 19,4470 restrict = 19,
4188 Aliased = 20,4471 aliased = 20,
4189 Volatile = 21,4472 @"volatile" = 21,
4190 Constant = 22,4473 constant = 22,
4191 Coherent = 23,4474 coherent = 23,
4192 NonWritable = 24,4475 non_writable = 24,
4193 NonReadable = 25,4476 non_readable = 25,
4194 Uniform = 26,4477 uniform = 26,
4195 UniformId = 27,4478 uniform_id = 27,
4196 SaturatedConversion = 28,4479 saturated_conversion = 28,
4197 Stream = 29,4480 stream = 29,
4198 Location = 30,4481 location = 30,
4199 Component = 31,4482 component = 31,
4200 Index = 32,4483 index = 32,
4201 Binding = 33,4484 binding = 33,
4202 DescriptorSet = 34,4485 descriptor_set = 34,
4203 Offset = 35,4486 offset = 35,
4204 XfbBuffer = 36,4487 xfb_buffer = 36,
4205 XfbStride = 37,4488 xfb_stride = 37,
4206 FuncParamAttr = 38,4489 func_param_attr = 38,
4207 FPRoundingMode = 39,4490 fp_rounding_mode = 39,
4208 FPFastMathMode = 40,4491 fp_fast_math_mode = 40,
4209 LinkageAttributes = 41,4492 linkage_attributes = 41,
4210 NoContraction = 42,4493 no_contraction = 42,
4211 InputAttachmentIndex = 43,4494 input_attachment_index = 43,
4212 Alignment = 44,4495 alignment = 44,
4213 MaxByteOffset = 45,4496 max_byte_offset = 45,
4214 AlignmentId = 46,4497 alignment_id = 46,
4215 MaxByteOffsetId = 47,4498 max_byte_offset_id = 47,
4216 NoSignedWrap = 4469,4499 saturated_to_largest_float8normal_conversion_ext = 4216,
4217 NoUnsignedWrap = 4470,4500 no_signed_wrap = 4469,
4218 WeightTextureQCOM = 4487,4501 no_unsigned_wrap = 4470,
4219 BlockMatchTextureQCOM = 4488,4502 weight_texture_qcom = 4487,
4220 BlockMatchSamplerQCOM = 4499,4503 block_match_texture_qcom = 4488,
4221 ExplicitInterpAMD = 4999,4504 block_match_sampler_qcom = 4499,
4222 NodeSharesPayloadLimitsWithAMDX = 5019,4505 explicit_interp_amd = 4999,
4223 NodeMaxPayloadsAMDX = 5020,4506 node_shares_payload_limits_with_amdx = 5019,
4224 TrackFinishWritingAMDX = 5078,4507 node_max_payloads_amdx = 5020,
4225 PayloadNodeNameAMDX = 5091,4508 track_finish_writing_amdx = 5078,
4226 OverrideCoverageNV = 5248,4509 payload_node_name_amdx = 5091,
4227 PassthroughNV = 5250,4510 payload_node_base_index_amdx = 5098,
4228 ViewportRelativeNV = 5252,4511 payload_node_sparse_array_amdx = 5099,
4229 SecondaryViewportRelativeNV = 5256,4512 payload_node_array_size_amdx = 5100,
4230 PerPrimitiveEXT = 5271,4513 payload_dispatch_indirect_amdx = 5105,
4231 PerViewNV = 5272,4514 override_coverage_nv = 5248,
4232 PerTaskNV = 5273,4515 passthrough_nv = 5250,
4233 PerVertexKHR = 5285,4516 viewport_relative_nv = 5252,
4234 NonUniform = 5300,4517 secondary_viewport_relative_nv = 5256,
4235 RestrictPointer = 5355,4518 per_primitive_ext = 5271,
4236 AliasedPointer = 5356,4519 per_view_nv = 5272,
4237 HitObjectShaderRecordBufferNV = 5386,4520 per_task_nv = 5273,
4238 BindlessSamplerNV = 5398,4521 per_vertex_khr = 5285,
4239 BindlessImageNV = 5399,4522 non_uniform = 5300,
4240 BoundSamplerNV = 5400,4523 restrict_pointer = 5355,
4241 BoundImageNV = 5401,4524 aliased_pointer = 5356,
4242 SIMTCallINTEL = 5599,4525 hit_object_shader_record_buffer_nv = 5386,
4243 ReferencedIndirectlyINTEL = 5602,4526 bindless_sampler_nv = 5398,
4244 ClobberINTEL = 5607,4527 bindless_image_nv = 5399,
4245 SideEffectsINTEL = 5608,4528 bound_sampler_nv = 5400,
4246 VectorComputeVariableINTEL = 5624,4529 bound_image_nv = 5401,
4247 FuncParamIOKindINTEL = 5625,4530 simt_call_intel = 5599,
4248 VectorComputeFunctionINTEL = 5626,4531 referenced_indirectly_intel = 5602,
4249 StackCallINTEL = 5627,4532 clobber_intel = 5607,
4250 GlobalVariableOffsetINTEL = 5628,4533 side_effects_intel = 5608,
4251 CounterBuffer = 5634,4534 vector_compute_variable_intel = 5624,
4252 UserSemantic = 5635,4535 func_param_io_kind_intel = 5625,
4253 UserTypeGOOGLE = 5636,4536 vector_compute_function_intel = 5626,
4254 FunctionRoundingModeINTEL = 5822,4537 stack_call_intel = 5627,
4255 FunctionDenormModeINTEL = 5823,4538 global_variable_offset_intel = 5628,
4256 RegisterINTEL = 5825,4539 counter_buffer = 5634,
4257 MemoryINTEL = 5826,4540 user_semantic = 5635,
4258 NumbanksINTEL = 5827,4541 user_type_google = 5636,
4259 BankwidthINTEL = 5828,4542 function_rounding_mode_intel = 5822,
4260 MaxPrivateCopiesINTEL = 5829,4543 function_denorm_mode_intel = 5823,
4261 SinglepumpINTEL = 5830,4544 register_intel = 5825,
4262 DoublepumpINTEL = 5831,4545 memory_intel = 5826,
4263 MaxReplicatesINTEL = 5832,4546 numbanks_intel = 5827,
4264 SimpleDualPortINTEL = 5833,4547 bankwidth_intel = 5828,
4265 MergeINTEL = 5834,4548 max_private_copies_intel = 5829,
4266 BankBitsINTEL = 5835,4549 singlepump_intel = 5830,
4267 ForcePow2DepthINTEL = 5836,4550 doublepump_intel = 5831,
4268 StridesizeINTEL = 5883,4551 max_replicates_intel = 5832,
4269 WordsizeINTEL = 5884,4552 simple_dual_port_intel = 5833,
4270 TrueDualPortINTEL = 5885,4553 merge_intel = 5834,
4271 BurstCoalesceINTEL = 5899,4554 bank_bits_intel = 5835,
4272 CacheSizeINTEL = 5900,4555 force_pow2depth_intel = 5836,
4273 DontStaticallyCoalesceINTEL = 5901,4556 stridesize_intel = 5883,
4274 PrefetchINTEL = 5902,4557 wordsize_intel = 5884,
4275 StallEnableINTEL = 5905,4558 true_dual_port_intel = 5885,
4276 FuseLoopsInFunctionINTEL = 5907,4559 burst_coalesce_intel = 5899,
4277 MathOpDSPModeINTEL = 5909,4560 cache_size_intel = 5900,
4278 AliasScopeINTEL = 5914,4561 dont_statically_coalesce_intel = 5901,
4279 NoAliasINTEL = 5915,4562 prefetch_intel = 5902,
4280 InitiationIntervalINTEL = 5917,4563 stall_enable_intel = 5905,
4281 MaxConcurrencyINTEL = 5918,4564 fuse_loops_in_function_intel = 5907,
4282 PipelineEnableINTEL = 5919,4565 math_op_dsp_mode_intel = 5909,
4283 BufferLocationINTEL = 5921,4566 alias_scope_intel = 5914,
4284 IOPipeStorageINTEL = 5944,4567 no_alias_intel = 5915,
4285 FunctionFloatingPointModeINTEL = 6080,4568 initiation_interval_intel = 5917,
4286 SingleElementVectorINTEL = 6085,4569 max_concurrency_intel = 5918,
4287 VectorComputeCallableFunctionINTEL = 6087,4570 pipeline_enable_intel = 5919,
4288 MediaBlockIOINTEL = 6140,4571 buffer_location_intel = 5921,
4289 StallFreeINTEL = 6151,4572 io_pipe_storage_intel = 5944,
4290 FPMaxErrorDecorationINTEL = 6170,4573 function_floating_point_mode_intel = 6080,
4291 LatencyControlLabelINTEL = 6172,4574 single_element_vector_intel = 6085,
4292 LatencyControlConstraintINTEL = 6173,4575 vector_compute_callable_function_intel = 6087,
4293 ConduitKernelArgumentINTEL = 6175,4576 media_block_iointel = 6140,
4294 RegisterMapKernelArgumentINTEL = 6176,4577 stall_free_intel = 6151,
4295 MMHostInterfaceAddressWidthINTEL = 6177,4578 fp_max_error_decoration_intel = 6170,
4296 MMHostInterfaceDataWidthINTEL = 6178,4579 latency_control_label_intel = 6172,
4297 MMHostInterfaceLatencyINTEL = 6179,4580 latency_control_constraint_intel = 6173,
4298 MMHostInterfaceReadWriteModeINTEL = 6180,4581 conduit_kernel_argument_intel = 6175,
4299 MMHostInterfaceMaxBurstINTEL = 6181,4582 register_map_kernel_argument_intel = 6176,
4300 MMHostInterfaceWaitRequestINTEL = 6182,4583 mm_host_interface_address_width_intel = 6177,
4301 StableKernelArgumentINTEL = 6183,4584 mm_host_interface_data_width_intel = 6178,
4302 HostAccessINTEL = 6188,4585 mm_host_interface_latency_intel = 6179,
4303 InitModeINTEL = 6190,4586 mm_host_interface_read_write_mode_intel = 6180,
4304 ImplementInRegisterMapINTEL = 6191,4587 mm_host_interface_max_burst_intel = 6181,
4305 CacheControlLoadINTEL = 6442,4588 mm_host_interface_wait_request_intel = 6182,
4306 CacheControlStoreINTEL = 6443,4589 stable_kernel_argument_intel = 6183,
43074590 host_access_intel = 6188,
4308 pub const PerPrimitiveNV = Decoration.PerPrimitiveEXT;4591 init_mode_intel = 6190,
4309 pub const PerVertexNV = Decoration.PerVertexKHR;4592 implement_in_register_map_intel = 6191,
4310 pub const NonUniformEXT = Decoration.NonUniform;4593 cache_control_load_intel = 6442,
4311 pub const RestrictPointerEXT = Decoration.RestrictPointer;4594 cache_control_store_intel = 6443,
4312 pub const AliasedPointerEXT = Decoration.AliasedPointer;
4313 pub const HlslCounterBufferGOOGLE = Decoration.CounterBuffer;
4314 pub const HlslSemanticGOOGLE = Decoration.UserSemantic;
43154595
4316 pub const Extended = union(Decoration) {4596 pub const Extended = union(Decoration) {
4317 RelaxedPrecision,4597 relaxed_precision,
4318 SpecId: struct { specialization_constant_id: LiteralInteger },4598 spec_id: struct { specialization_constant_id: LiteralInteger },
4319 Block,4599 block,
4320 BufferBlock,4600 buffer_block,
4321 RowMajor,4601 row_major,
4322 ColMajor,4602 col_major,
4323 ArrayStride: struct { array_stride: LiteralInteger },4603 array_stride: struct { array_stride: LiteralInteger },
4324 MatrixStride: struct { matrix_stride: LiteralInteger },4604 matrix_stride: struct { matrix_stride: LiteralInteger },
4325 GLSLShared,4605 glsl_shared,
4326 GLSLPacked,4606 glsl_packed,
4327 CPacked,4607 c_packed,
4328 BuiltIn: struct { built_in: BuiltIn },4608 built_in: struct { built_in: BuiltIn },
4329 NoPerspective,4609 no_perspective,
4330 Flat,4610 flat,
4331 Patch,4611 patch,
4332 Centroid,4612 centroid,
4333 Sample,4613 sample,
4334 Invariant,4614 invariant,
4335 Restrict,4615 restrict,
4336 Aliased,4616 aliased,
4337 Volatile,4617 @"volatile",
4338 Constant,4618 constant,
4339 Coherent,4619 coherent,
4340 NonWritable,4620 non_writable,
4341 NonReadable,4621 non_readable,
4342 Uniform,4622 uniform,
4343 UniformId: struct { execution: IdScope },4623 uniform_id: struct { execution: Id },
4344 SaturatedConversion,4624 saturated_conversion,
4345 Stream: struct { stream_number: LiteralInteger },4625 stream: struct { stream_number: LiteralInteger },
4346 Location: struct { location: LiteralInteger },4626 location: struct { location: LiteralInteger },
4347 Component: struct { component: LiteralInteger },4627 component: struct { component: LiteralInteger },
4348 Index: struct { index: LiteralInteger },4628 index: struct { index: LiteralInteger },
4349 Binding: struct { binding_point: LiteralInteger },4629 binding: struct { binding_point: LiteralInteger },
4350 DescriptorSet: struct { descriptor_set: LiteralInteger },4630 descriptor_set: struct { descriptor_set: LiteralInteger },
4351 Offset: struct { byte_offset: LiteralInteger },4631 offset: struct { byte_offset: LiteralInteger },
4352 XfbBuffer: struct { xfb_buffer_number: LiteralInteger },4632 xfb_buffer: struct { xfb_buffer_number: LiteralInteger },
4353 XfbStride: struct { xfb_stride: LiteralInteger },4633 xfb_stride: struct { xfb_stride: LiteralInteger },
4354 FuncParamAttr: struct { function_parameter_attribute: FunctionParameterAttribute },4634 func_param_attr: struct { function_parameter_attribute: FunctionParameterAttribute },
4355 FPRoundingMode: struct { fprounding_mode: FPRoundingMode },4635 fp_rounding_mode: struct { fp_rounding_mode: FPRoundingMode },
4356 FPFastMathMode: struct { fpfast_math_mode: FPFastMathMode },4636 fp_fast_math_mode: struct { fp_fast_math_mode: FPFastMathMode },
4357 LinkageAttributes: struct { name: LiteralString, linkage_type: LinkageType },4637 linkage_attributes: struct { name: LiteralString, linkage_type: LinkageType },
4358 NoContraction,4638 no_contraction,
4359 InputAttachmentIndex: struct { attachment_index: LiteralInteger },4639 input_attachment_index: struct { attachment_index: LiteralInteger },
4360 Alignment: struct { alignment: LiteralInteger },4640 alignment: struct { alignment: LiteralInteger },
4361 MaxByteOffset: struct { max_byte_offset: LiteralInteger },4641 max_byte_offset: struct { max_byte_offset: LiteralInteger },
4362 AlignmentId: struct { alignment: IdRef },4642 alignment_id: struct { alignment: Id },
4363 MaxByteOffsetId: struct { max_byte_offset: IdRef },4643 max_byte_offset_id: struct { max_byte_offset: Id },
4364 NoSignedWrap,4644 saturated_to_largest_float8normal_conversion_ext,
4365 NoUnsignedWrap,4645 no_signed_wrap,
4366 WeightTextureQCOM,4646 no_unsigned_wrap,
4367 BlockMatchTextureQCOM,4647 weight_texture_qcom,
4368 BlockMatchSamplerQCOM,4648 block_match_texture_qcom,
4369 ExplicitInterpAMD,4649 block_match_sampler_qcom,
4370 NodeSharesPayloadLimitsWithAMDX: struct { payload_array: IdRef },4650 explicit_interp_amd,
4371 NodeMaxPayloadsAMDX: struct { max_number_of_payloads: IdRef },4651 node_shares_payload_limits_with_amdx: struct { payload_type: Id },
4372 TrackFinishWritingAMDX,4652 node_max_payloads_amdx: struct { max_number_of_payloads: Id },
4373 PayloadNodeNameAMDX: struct { node_name: LiteralString },4653 track_finish_writing_amdx,
4374 OverrideCoverageNV,4654 payload_node_name_amdx: struct { node_name: Id },
4375 PassthroughNV,4655 payload_node_base_index_amdx: struct { base_index: Id },
4376 ViewportRelativeNV,4656 payload_node_sparse_array_amdx,
4377 SecondaryViewportRelativeNV: struct { offset: LiteralInteger },4657 payload_node_array_size_amdx: struct { array_size: Id },
4378 PerPrimitiveEXT,4658 payload_dispatch_indirect_amdx,
4379 PerViewNV,4659 override_coverage_nv,
4380 PerTaskNV,4660 passthrough_nv,
4381 PerVertexKHR,4661 viewport_relative_nv,
4382 NonUniform,4662 secondary_viewport_relative_nv: struct { offset: LiteralInteger },
4383 RestrictPointer,4663 per_primitive_ext,
4384 AliasedPointer,4664 per_view_nv,
4385 HitObjectShaderRecordBufferNV,4665 per_task_nv,
4386 BindlessSamplerNV,4666 per_vertex_khr,
4387 BindlessImageNV,4667 non_uniform,
4388 BoundSamplerNV,4668 restrict_pointer,
4389 BoundImageNV,4669 aliased_pointer,
4390 SIMTCallINTEL: struct { n: LiteralInteger },4670 hit_object_shader_record_buffer_nv,
4391 ReferencedIndirectlyINTEL,4671 bindless_sampler_nv,
4392 ClobberINTEL: struct { register: LiteralString },4672 bindless_image_nv,
4393 SideEffectsINTEL,4673 bound_sampler_nv,
4394 VectorComputeVariableINTEL,4674 bound_image_nv,
4395 FuncParamIOKindINTEL: struct { kind: LiteralInteger },4675 simt_call_intel: struct { n: LiteralInteger },
4396 VectorComputeFunctionINTEL,4676 referenced_indirectly_intel,
4397 StackCallINTEL,4677 clobber_intel: struct { register: LiteralString },
4398 GlobalVariableOffsetINTEL: struct { offset: LiteralInteger },4678 side_effects_intel,
4399 CounterBuffer: struct { counter_buffer: IdRef },4679 vector_compute_variable_intel,
4400 UserSemantic: struct { semantic: LiteralString },4680 func_param_io_kind_intel: struct { kind: LiteralInteger },
4401 UserTypeGOOGLE: struct { user_type: LiteralString },4681 vector_compute_function_intel,
4402 FunctionRoundingModeINTEL: struct { target_width: LiteralInteger, fp_rounding_mode: FPRoundingMode },4682 stack_call_intel,
4403 FunctionDenormModeINTEL: struct { target_width: LiteralInteger, fp_denorm_mode: FPDenormMode },4683 global_variable_offset_intel: struct { offset: LiteralInteger },
4404 RegisterINTEL,4684 counter_buffer: struct { counter_buffer: Id },
4405 MemoryINTEL: struct { memory_type: LiteralString },4685 user_semantic: struct { semantic: LiteralString },
4406 NumbanksINTEL: struct { banks: LiteralInteger },4686 user_type_google: struct { user_type: LiteralString },
4407 BankwidthINTEL: struct { bank_width: LiteralInteger },4687 function_rounding_mode_intel: struct { target_width: LiteralInteger, fp_rounding_mode: FPRoundingMode },
4408 MaxPrivateCopiesINTEL: struct { maximum_copies: LiteralInteger },4688 function_denorm_mode_intel: struct { target_width: LiteralInteger, fp_denorm_mode: FPDenormMode },
4409 SinglepumpINTEL,4689 register_intel,
4410 DoublepumpINTEL,4690 memory_intel: struct { memory_type: LiteralString },
4411 MaxReplicatesINTEL: struct { maximum_replicates: LiteralInteger },4691 numbanks_intel: struct { banks: LiteralInteger },
4412 SimpleDualPortINTEL,4692 bankwidth_intel: struct { bank_width: LiteralInteger },
4413 MergeINTEL: struct { merge_key: LiteralString, merge_type: LiteralString },4693 max_private_copies_intel: struct { maximum_copies: LiteralInteger },
4414 BankBitsINTEL: struct { bank_bits: []const LiteralInteger = &.{} },4694 singlepump_intel,
4415 ForcePow2DepthINTEL: struct { force_key: LiteralInteger },4695 doublepump_intel,
4416 StridesizeINTEL: struct { stride_size: LiteralInteger },4696 max_replicates_intel: struct { maximum_replicates: LiteralInteger },
4417 WordsizeINTEL: struct { word_size: LiteralInteger },4697 simple_dual_port_intel,
4418 TrueDualPortINTEL,4698 merge_intel: struct { merge_key: LiteralString, merge_type: LiteralString },
4419 BurstCoalesceINTEL,4699 bank_bits_intel: struct { bank_bits: []const LiteralInteger = &.{} },
4420 CacheSizeINTEL: struct { cache_size_in_bytes: LiteralInteger },4700 force_pow2depth_intel: struct { force_key: LiteralInteger },
4421 DontStaticallyCoalesceINTEL,4701 stridesize_intel: struct { stride_size: LiteralInteger },
4422 PrefetchINTEL: struct { prefetcher_size_in_bytes: LiteralInteger },4702 wordsize_intel: struct { word_size: LiteralInteger },
4423 StallEnableINTEL,4703 true_dual_port_intel,
4424 FuseLoopsInFunctionINTEL,4704 burst_coalesce_intel,
4425 MathOpDSPModeINTEL: struct { mode: LiteralInteger, propagate: LiteralInteger },4705 cache_size_intel: struct { cache_size_in_bytes: LiteralInteger },
4426 AliasScopeINTEL: struct { aliasing_scopes_list: IdRef },4706 dont_statically_coalesce_intel,
4427 NoAliasINTEL: struct { aliasing_scopes_list: IdRef },4707 prefetch_intel: struct { prefetcher_size_in_bytes: LiteralInteger },
4428 InitiationIntervalINTEL: struct { cycles: LiteralInteger },4708 stall_enable_intel,
4429 MaxConcurrencyINTEL: struct { invocations: LiteralInteger },4709 fuse_loops_in_function_intel,
4430 PipelineEnableINTEL: struct { enable: LiteralInteger },4710 math_op_dsp_mode_intel: struct { mode: LiteralInteger, propagate: LiteralInteger },
4431 BufferLocationINTEL: struct { buffer_location_id: LiteralInteger },4711 alias_scope_intel: struct { aliasing_scopes_list: Id },
4432 IOPipeStorageINTEL: struct { io_pipe_id: LiteralInteger },4712 no_alias_intel: struct { aliasing_scopes_list: Id },
4433 FunctionFloatingPointModeINTEL: struct { target_width: LiteralInteger, fp_operation_mode: FPOperationMode },4713 initiation_interval_intel: struct { cycles: LiteralInteger },
4434 SingleElementVectorINTEL,4714 max_concurrency_intel: struct { invocations: LiteralInteger },
4435 VectorComputeCallableFunctionINTEL,4715 pipeline_enable_intel: struct { enable: LiteralInteger },
4436 MediaBlockIOINTEL,4716 buffer_location_intel: struct { buffer_location_id: LiteralInteger },
4437 StallFreeINTEL,4717 io_pipe_storage_intel: struct { io_pipe_id: LiteralInteger },
4438 FPMaxErrorDecorationINTEL: struct { max_error: LiteralFloat },4718 function_floating_point_mode_intel: struct { target_width: LiteralInteger, fp_operation_mode: FPOperationMode },
4439 LatencyControlLabelINTEL: struct { latency_label: LiteralInteger },4719 single_element_vector_intel,
4440 LatencyControlConstraintINTEL: struct { relative_to: LiteralInteger, control_type: LiteralInteger, relative_cycle: LiteralInteger },4720 vector_compute_callable_function_intel,
4441 ConduitKernelArgumentINTEL,4721 media_block_iointel,
4442 RegisterMapKernelArgumentINTEL,4722 stall_free_intel,
4443 MMHostInterfaceAddressWidthINTEL: struct { addresswidth: LiteralInteger },4723 fp_max_error_decoration_intel: struct { max_error: LiteralFloat },
4444 MMHostInterfaceDataWidthINTEL: struct { datawidth: LiteralInteger },4724 latency_control_label_intel: struct { latency_label: LiteralInteger },
4445 MMHostInterfaceLatencyINTEL: struct { latency: LiteralInteger },4725 latency_control_constraint_intel: struct { relative_to: LiteralInteger, control_type: LiteralInteger, relative_cycle: LiteralInteger },
4446 MMHostInterfaceReadWriteModeINTEL: struct { readwritemode: AccessQualifier },4726 conduit_kernel_argument_intel,
4447 MMHostInterfaceMaxBurstINTEL: struct { maxburstcount: LiteralInteger },4727 register_map_kernel_argument_intel,
4448 MMHostInterfaceWaitRequestINTEL: struct { waitrequest: LiteralInteger },4728 mm_host_interface_address_width_intel: struct { address_width: LiteralInteger },
4449 StableKernelArgumentINTEL,4729 mm_host_interface_data_width_intel: struct { data_width: LiteralInteger },
4450 HostAccessINTEL: struct { access: HostAccessQualifier, name: LiteralString },4730 mm_host_interface_latency_intel: struct { latency: LiteralInteger },
4451 InitModeINTEL: struct { trigger: InitializationModeQualifier },4731 mm_host_interface_read_write_mode_intel: struct { read_write_mode: AccessQualifier },
4452 ImplementInRegisterMapINTEL: struct { value: LiteralInteger },4732 mm_host_interface_max_burst_intel: struct { max_burst_count: LiteralInteger },
4453 CacheControlLoadINTEL: struct { cache_level: LiteralInteger, cache_control: LoadCacheControl },4733 mm_host_interface_wait_request_intel: struct { waitrequest: LiteralInteger },
4454 CacheControlStoreINTEL: struct { cache_level: LiteralInteger, cache_control: StoreCacheControl },4734 stable_kernel_argument_intel,
4735 host_access_intel: struct { access: HostAccessQualifier, name: LiteralString },
4736 init_mode_intel: struct { trigger: InitializationModeQualifier },
4737 implement_in_register_map_intel: struct { value: LiteralInteger },
4738 cache_control_load_intel: struct { cache_level: LiteralInteger, cache_control: LoadCacheControl },
4739 cache_control_store_intel: struct { cache_level: LiteralInteger, cache_control: StoreCacheControl },
4455 };4740 };
4456};4741};
4457pub const BuiltIn = enum(u32) {4742pub const BuiltIn = enum(u32) {
4458 Position = 0,4743 position = 0,
4459 PointSize = 1,4744 point_size = 1,
4460 ClipDistance = 3,4745 clip_distance = 3,
4461 CullDistance = 4,4746 cull_distance = 4,
4462 VertexId = 5,4747 vertex_id = 5,
4463 InstanceId = 6,4748 instance_id = 6,
4464 PrimitiveId = 7,4749 primitive_id = 7,
4465 InvocationId = 8,4750 invocation_id = 8,
4466 Layer = 9,4751 layer = 9,
4467 ViewportIndex = 10,4752 viewport_index = 10,
4468 TessLevelOuter = 11,4753 tess_level_outer = 11,
4469 TessLevelInner = 12,4754 tess_level_inner = 12,
4470 TessCoord = 13,4755 tess_coord = 13,
4471 PatchVertices = 14,4756 patch_vertices = 14,
4472 FragCoord = 15,4757 frag_coord = 15,
4473 PointCoord = 16,4758 point_coord = 16,
4474 FrontFacing = 17,4759 front_facing = 17,
4475 SampleId = 18,4760 sample_id = 18,
4476 SamplePosition = 19,4761 sample_position = 19,
4477 SampleMask = 20,4762 sample_mask = 20,
4478 FragDepth = 22,4763 frag_depth = 22,
4479 HelperInvocation = 23,4764 helper_invocation = 23,
4480 NumWorkgroups = 24,4765 num_workgroups = 24,
4481 WorkgroupSize = 25,4766 workgroup_size = 25,
4482 WorkgroupId = 26,4767 workgroup_id = 26,
4483 LocalInvocationId = 27,4768 local_invocation_id = 27,
4484 GlobalInvocationId = 28,4769 global_invocation_id = 28,
4485 LocalInvocationIndex = 29,4770 local_invocation_index = 29,
4486 WorkDim = 30,4771 work_dim = 30,
4487 GlobalSize = 31,4772 global_size = 31,
4488 EnqueuedWorkgroupSize = 32,4773 enqueued_workgroup_size = 32,
4489 GlobalOffset = 33,4774 global_offset = 33,
4490 GlobalLinearId = 34,4775 global_linear_id = 34,
4491 SubgroupSize = 36,4776 subgroup_size = 36,
4492 SubgroupMaxSize = 37,4777 subgroup_max_size = 37,
4493 NumSubgroups = 38,4778 num_subgroups = 38,
4494 NumEnqueuedSubgroups = 39,4779 num_enqueued_subgroups = 39,
4495 SubgroupId = 40,4780 subgroup_id = 40,
4496 SubgroupLocalInvocationId = 41,4781 subgroup_local_invocation_id = 41,
4497 VertexIndex = 42,4782 vertex_index = 42,
4498 InstanceIndex = 43,4783 instance_index = 43,
4499 CoreIDARM = 4160,4784 core_idarm = 4160,
4500 CoreCountARM = 4161,4785 core_count_arm = 4161,
4501 CoreMaxIDARM = 4162,4786 core_max_idarm = 4162,
4502 WarpIDARM = 4163,4787 warp_idarm = 4163,
4503 WarpMaxIDARM = 4164,4788 warp_max_idarm = 4164,
4504 SubgroupEqMask = 4416,4789 subgroup_eq_mask = 4416,
4505 SubgroupGeMask = 4417,4790 subgroup_ge_mask = 4417,
4506 SubgroupGtMask = 4418,4791 subgroup_gt_mask = 4418,
4507 SubgroupLeMask = 4419,4792 subgroup_le_mask = 4419,
4508 SubgroupLtMask = 4420,4793 subgroup_lt_mask = 4420,
4509 BaseVertex = 4424,4794 base_vertex = 4424,
4510 BaseInstance = 4425,4795 base_instance = 4425,
4511 DrawIndex = 4426,4796 draw_index = 4426,
4512 PrimitiveShadingRateKHR = 4432,4797 primitive_shading_rate_khr = 4432,
4513 DeviceIndex = 4438,4798 device_index = 4438,
4514 ViewIndex = 4440,4799 view_index = 4440,
4515 ShadingRateKHR = 4444,4800 shading_rate_khr = 4444,
4516 BaryCoordNoPerspAMD = 4992,4801 tile_offset_qcom = 4492,
4517 BaryCoordNoPerspCentroidAMD = 4993,4802 tile_dimension_qcom = 4493,
4518 BaryCoordNoPerspSampleAMD = 4994,4803 tile_apron_size_qcom = 4494,
4519 BaryCoordSmoothAMD = 4995,4804 bary_coord_no_persp_amd = 4992,
4520 BaryCoordSmoothCentroidAMD = 4996,4805 bary_coord_no_persp_centroid_amd = 4993,
4521 BaryCoordSmoothSampleAMD = 4997,4806 bary_coord_no_persp_sample_amd = 4994,
4522 BaryCoordPullModelAMD = 4998,4807 bary_coord_smooth_amd = 4995,
4523 FragStencilRefEXT = 5014,4808 bary_coord_smooth_centroid_amd = 4996,
4524 CoalescedInputCountAMDX = 5021,4809 bary_coord_smooth_sample_amd = 4997,
4525 ShaderIndexAMDX = 5073,4810 bary_coord_pull_model_amd = 4998,
4526 ViewportMaskNV = 5253,4811 frag_stencil_ref_ext = 5014,
4527 SecondaryPositionNV = 5257,4812 remaining_recursion_levels_amdx = 5021,
4528 SecondaryViewportMaskNV = 5258,4813 shader_index_amdx = 5073,
4529 PositionPerViewNV = 5261,4814 viewport_mask_nv = 5253,
4530 ViewportMaskPerViewNV = 5262,4815 secondary_position_nv = 5257,
4531 FullyCoveredEXT = 5264,4816 secondary_viewport_mask_nv = 5258,
4532 TaskCountNV = 5274,4817 position_per_view_nv = 5261,
4533 PrimitiveCountNV = 5275,4818 viewport_mask_per_view_nv = 5262,
4534 PrimitiveIndicesNV = 5276,4819 fully_covered_ext = 5264,
4535 ClipDistancePerViewNV = 5277,4820 task_count_nv = 5274,
4536 CullDistancePerViewNV = 5278,4821 primitive_count_nv = 5275,
4537 LayerPerViewNV = 5279,4822 primitive_indices_nv = 5276,
4538 MeshViewCountNV = 5280,4823 clip_distance_per_view_nv = 5277,
4539 MeshViewIndicesNV = 5281,4824 cull_distance_per_view_nv = 5278,
4540 BaryCoordKHR = 5286,4825 layer_per_view_nv = 5279,
4541 BaryCoordNoPerspKHR = 5287,4826 mesh_view_count_nv = 5280,
4542 FragSizeEXT = 5292,4827 mesh_view_indices_nv = 5281,
4543 FragInvocationCountEXT = 5293,4828 bary_coord_khr = 5286,
4544 PrimitivePointIndicesEXT = 5294,4829 bary_coord_no_persp_khr = 5287,
4545 PrimitiveLineIndicesEXT = 5295,4830 frag_size_ext = 5292,
4546 PrimitiveTriangleIndicesEXT = 5296,4831 frag_invocation_count_ext = 5293,
4547 CullPrimitiveEXT = 5299,4832 primitive_point_indices_ext = 5294,
4548 LaunchIdKHR = 5319,4833 primitive_line_indices_ext = 5295,
4549 LaunchSizeKHR = 5320,4834 primitive_triangle_indices_ext = 5296,
4550 WorldRayOriginKHR = 5321,4835 cull_primitive_ext = 5299,
4551 WorldRayDirectionKHR = 5322,4836 launch_id_khr = 5319,
4552 ObjectRayOriginKHR = 5323,4837 launch_size_khr = 5320,
4553 ObjectRayDirectionKHR = 5324,4838 world_ray_origin_khr = 5321,
4554 RayTminKHR = 5325,4839 world_ray_direction_khr = 5322,
4555 RayTmaxKHR = 5326,4840 object_ray_origin_khr = 5323,
4556 InstanceCustomIndexKHR = 5327,4841 object_ray_direction_khr = 5324,
4557 ObjectToWorldKHR = 5330,4842 ray_tmin_khr = 5325,
4558 WorldToObjectKHR = 5331,4843 ray_tmax_khr = 5326,
4559 HitTNV = 5332,4844 instance_custom_index_khr = 5327,
4560 HitKindKHR = 5333,4845 object_to_world_khr = 5330,
4561 CurrentRayTimeNV = 5334,4846 world_to_object_khr = 5331,
4562 HitTriangleVertexPositionsKHR = 5335,4847 hit_tnv = 5332,
4563 HitMicroTriangleVertexPositionsNV = 5337,4848 hit_kind_khr = 5333,
4564 HitMicroTriangleVertexBarycentricsNV = 5344,4849 current_ray_time_nv = 5334,
4565 IncomingRayFlagsKHR = 5351,4850 hit_triangle_vertex_positions_khr = 5335,
4566 RayGeometryIndexKHR = 5352,4851 hit_micro_triangle_vertex_positions_nv = 5337,
4567 WarpsPerSMNV = 5374,4852 hit_micro_triangle_vertex_barycentrics_nv = 5344,
4568 SMCountNV = 5375,4853 incoming_ray_flags_khr = 5351,
4569 WarpIDNV = 5376,4854 ray_geometry_index_khr = 5352,
4570 SMIDNV = 5377,4855 hit_is_sphere_nv = 5359,
4571 HitKindFrontFacingMicroTriangleNV = 5405,4856 hit_is_lssnv = 5360,
4572 HitKindBackFacingMicroTriangleNV = 5406,4857 hit_sphere_position_nv = 5361,
4573 CullMaskKHR = 6021,4858 warps_per_smnv = 5374,
45744859 sm_count_nv = 5375,
4575 pub const SubgroupEqMaskKHR = BuiltIn.SubgroupEqMask;4860 warp_idnv = 5376,
4576 pub const SubgroupGeMaskKHR = BuiltIn.SubgroupGeMask;4861 smidnv = 5377,
4577 pub const SubgroupGtMaskKHR = BuiltIn.SubgroupGtMask;4862 hit_lss_positions_nv = 5396,
4578 pub const SubgroupLeMaskKHR = BuiltIn.SubgroupLeMask;4863 hit_kind_front_facing_micro_triangle_nv = 5405,
4579 pub const SubgroupLtMaskKHR = BuiltIn.SubgroupLtMask;4864 hit_kind_back_facing_micro_triangle_nv = 5406,
4580 pub const BaryCoordNV = BuiltIn.BaryCoordKHR;4865 hit_sphere_radius_nv = 5420,
4581 pub const BaryCoordNoPerspNV = BuiltIn.BaryCoordNoPerspKHR;4866 hit_lss_radii_nv = 5421,
4582 pub const FragmentSizeNV = BuiltIn.FragSizeEXT;4867 cluster_idnv = 5436,
4583 pub const InvocationsPerPixelNV = BuiltIn.FragInvocationCountEXT;4868 cull_mask_khr = 6021,
4584 pub const LaunchIdNV = BuiltIn.LaunchIdKHR;
4585 pub const LaunchSizeNV = BuiltIn.LaunchSizeKHR;
4586 pub const WorldRayOriginNV = BuiltIn.WorldRayOriginKHR;
4587 pub const WorldRayDirectionNV = BuiltIn.WorldRayDirectionKHR;
4588 pub const ObjectRayOriginNV = BuiltIn.ObjectRayOriginKHR;
4589 pub const ObjectRayDirectionNV = BuiltIn.ObjectRayDirectionKHR;
4590 pub const RayTminNV = BuiltIn.RayTminKHR;
4591 pub const RayTmaxNV = BuiltIn.RayTmaxKHR;
4592 pub const InstanceCustomIndexNV = BuiltIn.InstanceCustomIndexKHR;
4593 pub const ObjectToWorldNV = BuiltIn.ObjectToWorldKHR;
4594 pub const WorldToObjectNV = BuiltIn.WorldToObjectKHR;
4595 pub const HitKindNV = BuiltIn.HitKindKHR;
4596 pub const IncomingRayFlagsNV = BuiltIn.IncomingRayFlagsKHR;
4597};4869};
4598pub const Scope = enum(u32) {4870pub const Scope = enum(u32) {
4599 CrossDevice = 0,4871 cross_device = 0,
4600 Device = 1,4872 device = 1,
4601 Workgroup = 2,4873 workgroup = 2,
4602 Subgroup = 3,4874 subgroup = 3,
4603 Invocation = 4,4875 invocation = 4,
4604 QueueFamily = 5,4876 queue_family = 5,
4605 ShaderCallKHR = 6,4877 shader_call_khr = 6,
4606
4607 pub const QueueFamilyKHR = Scope.QueueFamily;
4608};4878};
4609pub const GroupOperation = enum(u32) {4879pub const GroupOperation = enum(u32) {
4610 Reduce = 0,4880 reduce = 0,
4611 InclusiveScan = 1,4881 inclusive_scan = 1,
4612 ExclusiveScan = 2,4882 exclusive_scan = 2,
4613 ClusteredReduce = 3,4883 clustered_reduce = 3,
4614 PartitionedReduceNV = 6,4884 partitioned_reduce_nv = 6,
4615 PartitionedInclusiveScanNV = 7,4885 partitioned_inclusive_scan_nv = 7,
4616 PartitionedExclusiveScanNV = 8,4886 partitioned_exclusive_scan_nv = 8,
4617};4887};
4618pub const KernelEnqueueFlags = enum(u32) {4888pub const KernelEnqueueFlags = enum(u32) {
4619 NoWait = 0,4889 no_wait = 0,
4620 WaitKernel = 1,4890 wait_kernel = 1,
4621 WaitWorkGroup = 2,4891 wait_work_group = 2,
4622};4892};
4623pub const Capability = enum(u32) {4893pub const Capability = enum(u32) {
4624 Matrix = 0,4894 matrix = 0,
4625 Shader = 1,4895 shader = 1,
4626 Geometry = 2,4896 geometry = 2,
4627 Tessellation = 3,4897 tessellation = 3,
4628 Addresses = 4,4898 addresses = 4,
4629 Linkage = 5,4899 linkage = 5,
4630 Kernel = 6,4900 kernel = 6,
4631 Vector16 = 7,4901 vector16 = 7,
4632 Float16Buffer = 8,4902 float16buffer = 8,
4633 Float16 = 9,4903 float16 = 9,
4634 Float64 = 10,4904 float64 = 10,
4635 Int64 = 11,4905 int64 = 11,
4636 Int64Atomics = 12,4906 int64atomics = 12,
4637 ImageBasic = 13,4907 image_basic = 13,
4638 ImageReadWrite = 14,4908 image_read_write = 14,
4639 ImageMipmap = 15,4909 image_mipmap = 15,
4640 Pipes = 17,4910 pipes = 17,
4641 Groups = 18,4911 groups = 18,
4642 DeviceEnqueue = 19,4912 device_enqueue = 19,
4643 LiteralSampler = 20,4913 literal_sampler = 20,
4644 AtomicStorage = 21,4914 atomic_storage = 21,
4645 Int16 = 22,4915 int16 = 22,
4646 TessellationPointSize = 23,4916 tessellation_point_size = 23,
4647 GeometryPointSize = 24,4917 geometry_point_size = 24,
4648 ImageGatherExtended = 25,4918 image_gather_extended = 25,
4649 StorageImageMultisample = 27,4919 storage_image_multisample = 27,
4650 UniformBufferArrayDynamicIndexing = 28,4920 uniform_buffer_array_dynamic_indexing = 28,
4651 SampledImageArrayDynamicIndexing = 29,4921 sampled_image_array_dynamic_indexing = 29,
4652 StorageBufferArrayDynamicIndexing = 30,4922 storage_buffer_array_dynamic_indexing = 30,
4653 StorageImageArrayDynamicIndexing = 31,4923 storage_image_array_dynamic_indexing = 31,
4654 ClipDistance = 32,4924 clip_distance = 32,
4655 CullDistance = 33,4925 cull_distance = 33,
4656 ImageCubeArray = 34,4926 image_cube_array = 34,
4657 SampleRateShading = 35,4927 sample_rate_shading = 35,
4658 ImageRect = 36,4928 image_rect = 36,
4659 SampledRect = 37,4929 sampled_rect = 37,
4660 GenericPointer = 38,4930 generic_pointer = 38,
4661 Int8 = 39,4931 int8 = 39,
4662 InputAttachment = 40,4932 input_attachment = 40,
4663 SparseResidency = 41,4933 sparse_residency = 41,
4664 MinLod = 42,4934 min_lod = 42,
4665 Sampled1D = 43,4935 sampled1d = 43,
4666 Image1D = 44,4936 image1d = 44,
4667 SampledCubeArray = 45,4937 sampled_cube_array = 45,
4668 SampledBuffer = 46,4938 sampled_buffer = 46,
4669 ImageBuffer = 47,4939 image_buffer = 47,
4670 ImageMSArray = 48,4940 image_ms_array = 48,
4671 StorageImageExtendedFormats = 49,4941 storage_image_extended_formats = 49,
4672 ImageQuery = 50,4942 image_query = 50,
4673 DerivativeControl = 51,4943 derivative_control = 51,
4674 InterpolationFunction = 52,4944 interpolation_function = 52,
4675 TransformFeedback = 53,4945 transform_feedback = 53,
4676 GeometryStreams = 54,4946 geometry_streams = 54,
4677 StorageImageReadWithoutFormat = 55,4947 storage_image_read_without_format = 55,
4678 StorageImageWriteWithoutFormat = 56,4948 storage_image_write_without_format = 56,
4679 MultiViewport = 57,4949 multi_viewport = 57,
4680 SubgroupDispatch = 58,4950 subgroup_dispatch = 58,
4681 NamedBarrier = 59,4951 named_barrier = 59,
4682 PipeStorage = 60,4952 pipe_storage = 60,
4683 GroupNonUniform = 61,4953 group_non_uniform = 61,
4684 GroupNonUniformVote = 62,4954 group_non_uniform_vote = 62,
4685 GroupNonUniformArithmetic = 63,4955 group_non_uniform_arithmetic = 63,
4686 GroupNonUniformBallot = 64,4956 group_non_uniform_ballot = 64,
4687 GroupNonUniformShuffle = 65,4957 group_non_uniform_shuffle = 65,
4688 GroupNonUniformShuffleRelative = 66,4958 group_non_uniform_shuffle_relative = 66,
4689 GroupNonUniformClustered = 67,4959 group_non_uniform_clustered = 67,
4690 GroupNonUniformQuad = 68,4960 group_non_uniform_quad = 68,
4691 ShaderLayer = 69,4961 shader_layer = 69,
4692 ShaderViewportIndex = 70,4962 shader_viewport_index = 70,
4693 UniformDecoration = 71,4963 uniform_decoration = 71,
4694 CoreBuiltinsARM = 4165,4964 core_builtins_arm = 4165,
4695 TileImageColorReadAccessEXT = 4166,4965 tile_image_color_read_access_ext = 4166,
4696 TileImageDepthReadAccessEXT = 4167,4966 tile_image_depth_read_access_ext = 4167,
4697 TileImageStencilReadAccessEXT = 4168,4967 tile_image_stencil_read_access_ext = 4168,
4698 FragmentShadingRateKHR = 4422,4968 tensors_arm = 4174,
4699 SubgroupBallotKHR = 4423,4969 storage_tensor_array_dynamic_indexing_arm = 4175,
4700 DrawParameters = 4427,4970 storage_tensor_array_non_uniform_indexing_arm = 4176,
4701 WorkgroupMemoryExplicitLayoutKHR = 4428,4971 graph_arm = 4191,
4702 WorkgroupMemoryExplicitLayout8BitAccessKHR = 4429,4972 cooperative_matrix_layouts_arm = 4201,
4703 WorkgroupMemoryExplicitLayout16BitAccessKHR = 4430,4973 float8ext = 4212,
4704 SubgroupVoteKHR = 4431,4974 float8cooperative_matrix_ext = 4213,
4705 StorageBuffer16BitAccess = 4433,4975 fragment_shading_rate_khr = 4422,
4706 UniformAndStorageBuffer16BitAccess = 4434,4976 subgroup_ballot_khr = 4423,
4707 StoragePushConstant16 = 4435,4977 draw_parameters = 4427,
4708 StorageInputOutput16 = 4436,4978 workgroup_memory_explicit_layout_khr = 4428,
4709 DeviceGroup = 4437,4979 workgroup_memory_explicit_layout8bit_access_khr = 4429,
4710 MultiView = 4439,4980 workgroup_memory_explicit_layout16bit_access_khr = 4430,
4711 VariablePointersStorageBuffer = 4441,4981 subgroup_vote_khr = 4431,
4712 VariablePointers = 4442,4982 storage_buffer16bit_access = 4433,
4713 AtomicStorageOps = 4445,4983 uniform_and_storage_buffer16bit_access = 4434,
4714 SampleMaskPostDepthCoverage = 4447,4984 storage_push_constant16 = 4435,
4715 StorageBuffer8BitAccess = 4448,4985 storage_input_output16 = 4436,
4716 UniformAndStorageBuffer8BitAccess = 4449,4986 device_group = 4437,
4717 StoragePushConstant8 = 4450,4987 multi_view = 4439,
4718 DenormPreserve = 4464,4988 variable_pointers_storage_buffer = 4441,
4719 DenormFlushToZero = 4465,4989 variable_pointers = 4442,
4720 SignedZeroInfNanPreserve = 4466,4990 atomic_storage_ops = 4445,
4721 RoundingModeRTE = 4467,4991 sample_mask_post_depth_coverage = 4447,
4722 RoundingModeRTZ = 4468,4992 storage_buffer8bit_access = 4448,
4723 RayQueryProvisionalKHR = 4471,4993 uniform_and_storage_buffer8bit_access = 4449,
4724 RayQueryKHR = 4472,4994 storage_push_constant8 = 4450,
4725 RayTraversalPrimitiveCullingKHR = 4478,4995 denorm_preserve = 4464,
4726 RayTracingKHR = 4479,4996 denorm_flush_to_zero = 4465,
4727 TextureSampleWeightedQCOM = 4484,4997 signed_zero_inf_nan_preserve = 4466,
4728 TextureBoxFilterQCOM = 4485,4998 rounding_mode_rte = 4467,
4729 TextureBlockMatchQCOM = 4486,4999 rounding_mode_rtz = 4468,
4730 TextureBlockMatch2QCOM = 4498,5000 ray_query_provisional_khr = 4471,
4731 Float16ImageAMD = 5008,5001 ray_query_khr = 4472,
4732 ImageGatherBiasLodAMD = 5009,5002 untyped_pointers_khr = 4473,
4733 FragmentMaskAMD = 5010,5003 ray_traversal_primitive_culling_khr = 4478,
4734 StencilExportEXT = 5013,5004 ray_tracing_khr = 4479,
4735 ImageReadWriteLodAMD = 5015,5005 texture_sample_weighted_qcom = 4484,
4736 Int64ImageEXT = 5016,5006 texture_box_filter_qcom = 4485,
4737 ShaderClockKHR = 5055,5007 texture_block_match_qcom = 4486,
4738 ShaderEnqueueAMDX = 5067,5008 tile_shading_qcom = 4495,
4739 QuadControlKHR = 5087,5009 texture_block_match2qcom = 4498,
4740 SampleMaskOverrideCoverageNV = 5249,5010 float16image_amd = 5008,
4741 GeometryShaderPassthroughNV = 5251,5011 image_gather_bias_lod_amd = 5009,
4742 ShaderViewportIndexLayerEXT = 5254,5012 fragment_mask_amd = 5010,
4743 ShaderViewportMaskNV = 5255,5013 stencil_export_ext = 5013,
4744 ShaderStereoViewNV = 5259,5014 image_read_write_lod_amd = 5015,
4745 PerViewAttributesNV = 5260,5015 int64image_ext = 5016,
4746 FragmentFullyCoveredEXT = 5265,5016 shader_clock_khr = 5055,
4747 MeshShadingNV = 5266,5017 shader_enqueue_amdx = 5067,
4748 ImageFootprintNV = 5282,5018 quad_control_khr = 5087,
4749 MeshShadingEXT = 5283,5019 int4type_intel = 5112,
4750 FragmentBarycentricKHR = 5284,5020 int4cooperative_matrix_intel = 5114,
4751 ComputeDerivativeGroupQuadsNV = 5288,5021 b_float16type_khr = 5116,
4752 FragmentDensityEXT = 5291,5022 b_float16dot_product_khr = 5117,
4753 GroupNonUniformPartitionedNV = 5297,5023 b_float16cooperative_matrix_khr = 5118,
4754 ShaderNonUniform = 5301,5024 sample_mask_override_coverage_nv = 5249,
4755 RuntimeDescriptorArray = 5302,5025 geometry_shader_passthrough_nv = 5251,
4756 InputAttachmentArrayDynamicIndexing = 5303,5026 shader_viewport_index_layer_ext = 5254,
4757 UniformTexelBufferArrayDynamicIndexing = 5304,5027 shader_viewport_mask_nv = 5255,
4758 StorageTexelBufferArrayDynamicIndexing = 5305,5028 shader_stereo_view_nv = 5259,
4759 UniformBufferArrayNonUniformIndexing = 5306,5029 per_view_attributes_nv = 5260,
4760 SampledImageArrayNonUniformIndexing = 5307,5030 fragment_fully_covered_ext = 5265,
4761 StorageBufferArrayNonUniformIndexing = 5308,5031 mesh_shading_nv = 5266,
4762 StorageImageArrayNonUniformIndexing = 5309,5032 image_footprint_nv = 5282,
4763 InputAttachmentArrayNonUniformIndexing = 5310,5033 mesh_shading_ext = 5283,
4764 UniformTexelBufferArrayNonUniformIndexing = 5311,5034 fragment_barycentric_khr = 5284,
4765 StorageTexelBufferArrayNonUniformIndexing = 5312,5035 compute_derivative_group_quads_khr = 5288,
4766 RayTracingPositionFetchKHR = 5336,5036 fragment_density_ext = 5291,
4767 RayTracingNV = 5340,5037 group_non_uniform_partitioned_nv = 5297,
4768 RayTracingMotionBlurNV = 5341,5038 shader_non_uniform = 5301,
4769 VulkanMemoryModel = 5345,5039 runtime_descriptor_array = 5302,
4770 VulkanMemoryModelDeviceScope = 5346,5040 input_attachment_array_dynamic_indexing = 5303,
4771 PhysicalStorageBufferAddresses = 5347,5041 uniform_texel_buffer_array_dynamic_indexing = 5304,
4772 ComputeDerivativeGroupLinearNV = 5350,5042 storage_texel_buffer_array_dynamic_indexing = 5305,
4773 RayTracingProvisionalKHR = 5353,5043 uniform_buffer_array_non_uniform_indexing = 5306,
4774 CooperativeMatrixNV = 5357,5044 sampled_image_array_non_uniform_indexing = 5307,
4775 FragmentShaderSampleInterlockEXT = 5363,5045 storage_buffer_array_non_uniform_indexing = 5308,
4776 FragmentShaderShadingRateInterlockEXT = 5372,5046 storage_image_array_non_uniform_indexing = 5309,
4777 ShaderSMBuiltinsNV = 5373,5047 input_attachment_array_non_uniform_indexing = 5310,
4778 FragmentShaderPixelInterlockEXT = 5378,5048 uniform_texel_buffer_array_non_uniform_indexing = 5311,
4779 DemoteToHelperInvocation = 5379,5049 storage_texel_buffer_array_non_uniform_indexing = 5312,
4780 DisplacementMicromapNV = 5380,5050 ray_tracing_position_fetch_khr = 5336,
4781 RayTracingOpacityMicromapEXT = 5381,5051 ray_tracing_nv = 5340,
4782 ShaderInvocationReorderNV = 5383,5052 ray_tracing_motion_blur_nv = 5341,
4783 BindlessTextureNV = 5390,5053 vulkan_memory_model = 5345,
4784 RayQueryPositionFetchKHR = 5391,5054 vulkan_memory_model_device_scope = 5346,
4785 AtomicFloat16VectorNV = 5404,5055 physical_storage_buffer_addresses = 5347,
4786 RayTracingDisplacementMicromapNV = 5409,5056 compute_derivative_group_linear_khr = 5350,
4787 RawAccessChainsNV = 5414,5057 ray_tracing_provisional_khr = 5353,
4788 SubgroupShuffleINTEL = 5568,5058 cooperative_matrix_nv = 5357,
4789 SubgroupBufferBlockIOINTEL = 5569,5059 fragment_shader_sample_interlock_ext = 5363,
4790 SubgroupImageBlockIOINTEL = 5570,5060 fragment_shader_shading_rate_interlock_ext = 5372,
4791 SubgroupImageMediaBlockIOINTEL = 5579,5061 shader_sm_builtins_nv = 5373,
4792 RoundToInfinityINTEL = 5582,5062 fragment_shader_pixel_interlock_ext = 5378,
4793 FloatingPointModeINTEL = 5583,5063 demote_to_helper_invocation = 5379,
4794 IntegerFunctions2INTEL = 5584,5064 displacement_micromap_nv = 5380,
4795 FunctionPointersINTEL = 5603,5065 ray_tracing_opacity_micromap_ext = 5381,
4796 IndirectReferencesINTEL = 5604,5066 shader_invocation_reorder_nv = 5383,
4797 AsmINTEL = 5606,5067 bindless_texture_nv = 5390,
4798 AtomicFloat32MinMaxEXT = 5612,5068 ray_query_position_fetch_khr = 5391,
4799 AtomicFloat64MinMaxEXT = 5613,5069 cooperative_vector_nv = 5394,
4800 AtomicFloat16MinMaxEXT = 5616,5070 atomic_float16vector_nv = 5404,
4801 VectorComputeINTEL = 5617,5071 ray_tracing_displacement_micromap_nv = 5409,
4802 VectorAnyINTEL = 5619,5072 raw_access_chains_nv = 5414,
4803 ExpectAssumeKHR = 5629,5073 ray_tracing_spheres_geometry_nv = 5418,
4804 SubgroupAvcMotionEstimationINTEL = 5696,5074 ray_tracing_linear_swept_spheres_geometry_nv = 5419,
4805 SubgroupAvcMotionEstimationIntraINTEL = 5697,5075 cooperative_matrix_reductions_nv = 5430,
4806 SubgroupAvcMotionEstimationChromaINTEL = 5698,5076 cooperative_matrix_conversions_nv = 5431,
4807 VariableLengthArrayINTEL = 5817,5077 cooperative_matrix_per_element_operations_nv = 5432,
4808 FunctionFloatControlINTEL = 5821,5078 cooperative_matrix_tensor_addressing_nv = 5433,
4809 FPGAMemoryAttributesINTEL = 5824,5079 cooperative_matrix_block_loads_nv = 5434,
4810 FPFastMathModeINTEL = 5837,5080 cooperative_vector_training_nv = 5435,
4811 ArbitraryPrecisionIntegersINTEL = 5844,5081 ray_tracing_cluster_acceleration_structure_nv = 5437,
4812 ArbitraryPrecisionFloatingPointINTEL = 5845,5082 tensor_addressing_nv = 5439,
4813 UnstructuredLoopControlsINTEL = 5886,5083 subgroup_shuffle_intel = 5568,
4814 FPGALoopControlsINTEL = 5888,5084 subgroup_buffer_block_iointel = 5569,
4815 KernelAttributesINTEL = 5892,5085 subgroup_image_block_iointel = 5570,
4816 FPGAKernelAttributesINTEL = 5897,5086 subgroup_image_media_block_iointel = 5579,
4817 FPGAMemoryAccessesINTEL = 5898,5087 round_to_infinity_intel = 5582,
4818 FPGAClusterAttributesINTEL = 5904,5088 floating_point_mode_intel = 5583,
4819 LoopFuseINTEL = 5906,5089 integer_functions2intel = 5584,
4820 FPGADSPControlINTEL = 5908,5090 function_pointers_intel = 5603,
4821 MemoryAccessAliasingINTEL = 5910,5091 indirect_references_intel = 5604,
4822 FPGAInvocationPipeliningAttributesINTEL = 5916,5092 asm_intel = 5606,
4823 FPGABufferLocationINTEL = 5920,5093 atomic_float32min_max_ext = 5612,
4824 ArbitraryPrecisionFixedPointINTEL = 5922,5094 atomic_float64min_max_ext = 5613,
4825 USMStorageClassesINTEL = 5935,5095 atomic_float16min_max_ext = 5616,
4826 RuntimeAlignedAttributeINTEL = 5939,5096 vector_compute_intel = 5617,
4827 IOPipesINTEL = 5943,5097 vector_any_intel = 5619,
4828 BlockingPipesINTEL = 5945,5098 expect_assume_khr = 5629,
4829 FPGARegINTEL = 5948,5099 subgroup_avc_motion_estimation_intel = 5696,
4830 DotProductInputAll = 6016,5100 subgroup_avc_motion_estimation_intra_intel = 5697,
4831 DotProductInput4x8Bit = 6017,5101 subgroup_avc_motion_estimation_chroma_intel = 5698,
4832 DotProductInput4x8BitPacked = 6018,5102 variable_length_array_intel = 5817,
4833 DotProduct = 6019,5103 function_float_control_intel = 5821,
4834 RayCullMaskKHR = 6020,5104 fpga_memory_attributes_intel = 5824,
4835 CooperativeMatrixKHR = 6022,5105 fp_fast_math_mode_intel = 5837,
4836 BitInstructions = 6025,5106 arbitrary_precision_integers_intel = 5844,
4837 GroupNonUniformRotateKHR = 6026,5107 arbitrary_precision_floating_point_intel = 5845,
4838 FloatControls2 = 6029,5108 unstructured_loop_controls_intel = 5886,
4839 AtomicFloat32AddEXT = 6033,5109 fpga_loop_controls_intel = 5888,
4840 AtomicFloat64AddEXT = 6034,5110 kernel_attributes_intel = 5892,
4841 LongCompositesINTEL = 6089,5111 fpga_kernel_attributes_intel = 5897,
4842 OptNoneINTEL = 6094,5112 fpga_memory_accesses_intel = 5898,
4843 AtomicFloat16AddEXT = 6095,5113 fpga_cluster_attributes_intel = 5904,
4844 DebugInfoModuleINTEL = 6114,5114 loop_fuse_intel = 5906,
4845 BFloat16ConversionINTEL = 6115,5115 fpgadsp_control_intel = 5908,
4846 SplitBarrierINTEL = 6141,5116 memory_access_aliasing_intel = 5910,
4847 FPGAClusterAttributesV2INTEL = 6150,5117 fpga_invocation_pipelining_attributes_intel = 5916,
4848 FPGAKernelAttributesv2INTEL = 6161,5118 fpga_buffer_location_intel = 5920,
4849 FPMaxErrorINTEL = 6169,5119 arbitrary_precision_fixed_point_intel = 5922,
4850 FPGALatencyControlINTEL = 6171,5120 usm_storage_classes_intel = 5935,
4851 FPGAArgumentInterfacesINTEL = 6174,5121 runtime_aligned_attribute_intel = 5939,
4852 GlobalVariableHostAccessINTEL = 6187,5122 io_pipes_intel = 5943,
4853 GlobalVariableFPGADecorationsINTEL = 6189,5123 blocking_pipes_intel = 5945,
4854 GroupUniformArithmeticKHR = 6400,5124 fpga_reg_intel = 5948,
4855 MaskedGatherScatterINTEL = 6427,5125 dot_product_input_all = 6016,
4856 CacheControlsINTEL = 6441,5126 dot_product_input4x8bit = 6017,
4857 RegisterLimitsINTEL = 6460,5127 dot_product_input4x8bit_packed = 6018,
48585128 dot_product = 6019,
4859 pub const StorageUniformBufferBlock16 = Capability.StorageBuffer16BitAccess;5129 ray_cull_mask_khr = 6020,
4860 pub const StorageUniform16 = Capability.UniformAndStorageBuffer16BitAccess;5130 cooperative_matrix_khr = 6022,
4861 pub const ShaderViewportIndexLayerNV = Capability.ShaderViewportIndexLayerEXT;5131 replicated_composites_ext = 6024,
4862 pub const FragmentBarycentricNV = Capability.FragmentBarycentricKHR;5132 bit_instructions = 6025,
4863 pub const ShadingRateNV = Capability.FragmentDensityEXT;5133 group_non_uniform_rotate_khr = 6026,
4864 pub const ShaderNonUniformEXT = Capability.ShaderNonUniform;5134 float_controls2 = 6029,
4865 pub const RuntimeDescriptorArrayEXT = Capability.RuntimeDescriptorArray;5135 atomic_float32add_ext = 6033,
4866 pub const InputAttachmentArrayDynamicIndexingEXT = Capability.InputAttachmentArrayDynamicIndexing;5136 atomic_float64add_ext = 6034,
4867 pub const UniformTexelBufferArrayDynamicIndexingEXT = Capability.UniformTexelBufferArrayDynamicIndexing;5137 long_composites_intel = 6089,
4868 pub const StorageTexelBufferArrayDynamicIndexingEXT = Capability.StorageTexelBufferArrayDynamicIndexing;5138 opt_none_ext = 6094,
4869 pub const UniformBufferArrayNonUniformIndexingEXT = Capability.UniformBufferArrayNonUniformIndexing;5139 atomic_float16add_ext = 6095,
4870 pub const SampledImageArrayNonUniformIndexingEXT = Capability.SampledImageArrayNonUniformIndexing;5140 debug_info_module_intel = 6114,
4871 pub const StorageBufferArrayNonUniformIndexingEXT = Capability.StorageBufferArrayNonUniformIndexing;5141 b_float16conversion_intel = 6115,
4872 pub const StorageImageArrayNonUniformIndexingEXT = Capability.StorageImageArrayNonUniformIndexing;5142 split_barrier_intel = 6141,
4873 pub const InputAttachmentArrayNonUniformIndexingEXT = Capability.InputAttachmentArrayNonUniformIndexing;5143 arithmetic_fence_ext = 6144,
4874 pub const UniformTexelBufferArrayNonUniformIndexingEXT = Capability.UniformTexelBufferArrayNonUniformIndexing;5144 fpga_cluster_attributes_v2intel = 6150,
4875 pub const StorageTexelBufferArrayNonUniformIndexingEXT = Capability.StorageTexelBufferArrayNonUniformIndexing;5145 fpga_kernel_attributesv2intel = 6161,
4876 pub const VulkanMemoryModelKHR = Capability.VulkanMemoryModel;5146 task_sequence_intel = 6162,
4877 pub const VulkanMemoryModelDeviceScopeKHR = Capability.VulkanMemoryModelDeviceScope;5147 fp_max_error_intel = 6169,
4878 pub const PhysicalStorageBufferAddressesEXT = Capability.PhysicalStorageBufferAddresses;5148 fpga_latency_control_intel = 6171,
4879 pub const DemoteToHelperInvocationEXT = Capability.DemoteToHelperInvocation;5149 fpga_argument_interfaces_intel = 6174,
4880 pub const DotProductInputAllKHR = Capability.DotProductInputAll;5150 global_variable_host_access_intel = 6187,
4881 pub const DotProductInput4x8BitKHR = Capability.DotProductInput4x8Bit;5151 global_variable_fpga_decorations_intel = 6189,
4882 pub const DotProductInput4x8BitPackedKHR = Capability.DotProductInput4x8BitPacked;5152 subgroup_buffer_prefetch_intel = 6220,
4883 pub const DotProductKHR = Capability.DotProduct;5153 subgroup2d_block_iointel = 6228,
5154 subgroup2d_block_transform_intel = 6229,
5155 subgroup2d_block_transpose_intel = 6230,
5156 subgroup_matrix_multiply_accumulate_intel = 6236,
5157 ternary_bitwise_function_intel = 6241,
5158 group_uniform_arithmetic_khr = 6400,
5159 tensor_float32rounding_intel = 6425,
5160 masked_gather_scatter_intel = 6427,
5161 cache_controls_intel = 6441,
5162 register_limits_intel = 6460,
5163 bindless_images_intel = 6528,
4884};5164};
4885pub const RayQueryIntersection = enum(u32) {5165pub const RayQueryIntersection = enum(u32) {
4886 RayQueryCandidateIntersectionKHR = 0,5166 ray_query_candidate_intersection_khr = 0,
4887 RayQueryCommittedIntersectionKHR = 1,5167 ray_query_committed_intersection_khr = 1,
4888};5168};
4889pub const RayQueryCommittedIntersectionType = enum(u32) {5169pub const RayQueryCommittedIntersectionType = enum(u32) {
4890 RayQueryCommittedIntersectionNoneKHR = 0,5170 ray_query_committed_intersection_none_khr = 0,
4891 RayQueryCommittedIntersectionTriangleKHR = 1,5171 ray_query_committed_intersection_triangle_khr = 1,
4892 RayQueryCommittedIntersectionGeneratedKHR = 2,5172 ray_query_committed_intersection_generated_khr = 2,
4893};5173};
4894pub const RayQueryCandidateIntersectionType = enum(u32) {5174pub const RayQueryCandidateIntersectionType = enum(u32) {
4895 RayQueryCandidateIntersectionTriangleKHR = 0,5175 ray_query_candidate_intersection_triangle_khr = 0,
4896 RayQueryCandidateIntersectionAABBKHR = 1,5176 ray_query_candidate_intersection_aabbkhr = 1,
4897};5177};
4898pub const PackedVectorFormat = enum(u32) {5178pub const PackedVectorFormat = enum(u32) {
4899 PackedVectorFormat4x8Bit = 0,5179 packed_vector_format4x8bit = 0,
4900
4901 pub const PackedVectorFormat4x8BitKHR = PackedVectorFormat.PackedVectorFormat4x8Bit;
4902};5180};
4903pub const CooperativeMatrixOperands = packed struct {5181pub const CooperativeMatrixOperands = packed struct {
4904 MatrixASignedComponentsKHR: bool = false,5182 matrix_a_signed_components_khr: bool = false,
4905 MatrixBSignedComponentsKHR: bool = false,5183 matrix_b_signed_components_khr: bool = false,
4906 MatrixCSignedComponentsKHR: bool = false,5184 matrix_c_signed_components_khr: bool = false,
4907 MatrixResultSignedComponentsKHR: bool = false,5185 matrix_result_signed_components_khr: bool = false,
4908 SaturatingAccumulationKHR: bool = false,5186 saturating_accumulation_khr: bool = false,
4909 _reserved_bit_5: bool = false,5187 _reserved_bit_5: bool = false,
4910 _reserved_bit_6: bool = false,5188 _reserved_bit_6: bool = false,
4911 _reserved_bit_7: bool = false,5189 _reserved_bit_7: bool = false,
...@@ -4935,52 +5213,75 @@ pub const CooperativeMatrixOperands = packed struct {...@@ -4935,52 +5213,75 @@ pub const CooperativeMatrixOperands = packed struct {
4935 _reserved_bit_31: bool = false,5213 _reserved_bit_31: bool = false,
4936};5214};
4937pub const CooperativeMatrixLayout = enum(u32) {5215pub const CooperativeMatrixLayout = enum(u32) {
4938 RowMajorKHR = 0,5216 row_major_khr = 0,
4939 ColumnMajorKHR = 1,5217 column_major_khr = 1,
5218 row_blocked_interleaved_arm = 4202,
5219 column_blocked_interleaved_arm = 4203,
4940};5220};
4941pub const CooperativeMatrixUse = enum(u32) {5221pub const CooperativeMatrixUse = enum(u32) {
4942 MatrixAKHR = 0,5222 matrix_akhr = 0,
4943 MatrixBKHR = 1,5223 matrix_bkhr = 1,
4944 MatrixAccumulatorKHR = 2,5224 matrix_accumulator_khr = 2,
4945};5225};
4946pub const InitializationModeQualifier = enum(u32) {5226pub const CooperativeMatrixReduce = packed struct {
4947 InitOnDeviceReprogramINTEL = 0,5227 row: bool = false,
4948 InitOnDeviceResetINTEL = 1,5228 column: bool = false,
4949};5229 @"2x2": bool = false,
4950pub const LoadCacheControl = enum(u32) {5230 _reserved_bit_3: bool = false,
4951 UncachedINTEL = 0,5231 _reserved_bit_4: bool = false,
4952 CachedINTEL = 1,5232 _reserved_bit_5: bool = false,
4953 StreamingINTEL = 2,5233 _reserved_bit_6: bool = false,
4954 InvalidateAfterReadINTEL = 3,5234 _reserved_bit_7: bool = false,
4955 ConstCachedINTEL = 4,5235 _reserved_bit_8: bool = false,
4956};5236 _reserved_bit_9: bool = false,
4957pub const StoreCacheControl = enum(u32) {5237 _reserved_bit_10: bool = false,
4958 UncachedINTEL = 0,5238 _reserved_bit_11: bool = false,
4959 WriteThroughINTEL = 1,5239 _reserved_bit_12: bool = false,
4960 WriteBackINTEL = 2,5240 _reserved_bit_13: bool = false,
4961 StreamingINTEL = 3,5241 _reserved_bit_14: bool = false,
5242 _reserved_bit_15: bool = false,
5243 _reserved_bit_16: bool = false,
5244 _reserved_bit_17: bool = false,
5245 _reserved_bit_18: bool = false,
5246 _reserved_bit_19: bool = false,
5247 _reserved_bit_20: bool = false,
5248 _reserved_bit_21: bool = false,
5249 _reserved_bit_22: bool = false,
5250 _reserved_bit_23: bool = false,
5251 _reserved_bit_24: bool = false,
5252 _reserved_bit_25: bool = false,
5253 _reserved_bit_26: bool = false,
5254 _reserved_bit_27: bool = false,
5255 _reserved_bit_28: bool = false,
5256 _reserved_bit_29: bool = false,
5257 _reserved_bit_30: bool = false,
5258 _reserved_bit_31: bool = false,
4962};5259};
4963pub const NamedMaximumNumberOfRegisters = enum(u32) {5260pub const TensorClampMode = enum(u32) {
4964 AutoINTEL = 0,5261 undefined = 0,
5262 constant = 1,
5263 clamp_to_edge = 2,
5264 repeat = 3,
5265 repeat_mirrored = 4,
4965};5266};
4966pub const @"OpenCL.DebugInfo.100.DebugInfoFlags" = packed struct {5267pub const TensorAddressingOperands = packed struct {
4967 FlagIsProtected: bool = false,5268 tensor_view: bool = false,
4968 FlagIsPrivate: bool = false,5269 decode_func: bool = false,
4969 FlagIsLocal: bool = false,5270 _reserved_bit_2: bool = false,
4970 FlagIsDefinition: bool = false,5271 _reserved_bit_3: bool = false,
4971 FlagFwdDecl: bool = false,5272 _reserved_bit_4: bool = false,
4972 FlagArtificial: bool = false,5273 _reserved_bit_5: bool = false,
4973 FlagExplicit: bool = false,5274 _reserved_bit_6: bool = false,
4974 FlagPrototyped: bool = false,5275 _reserved_bit_7: bool = false,
4975 FlagObjectPointer: bool = false,5276 _reserved_bit_8: bool = false,
4976 FlagStaticMember: bool = false,5277 _reserved_bit_9: bool = false,
4977 FlagIndirectVariable: bool = false,5278 _reserved_bit_10: bool = false,
4978 FlagLValueReference: bool = false,5279 _reserved_bit_11: bool = false,
4979 FlagRValueReference: bool = false,5280 _reserved_bit_12: bool = false,
4980 FlagIsOptimized: bool = false,5281 _reserved_bit_13: bool = false,
4981 FlagIsEnumClass: bool = false,5282 _reserved_bit_14: bool = false,
4982 FlagTypePassByValue: bool = false,5283 _reserved_bit_15: bool = false,
4983 FlagTypePassByReference: bool = false,5284 _reserved_bit_16: bool = false,
4984 _reserved_bit_17: bool = false,5285 _reserved_bit_17: bool = false,
4985 _reserved_bit_18: bool = false,5286 _reserved_bit_18: bool = false,
4986 _reserved_bit_19: bool = false,5287 _reserved_bit_19: bool = false,
...@@ -4996,76 +5297,81 @@ pub const @"OpenCL.DebugInfo.100.DebugInfoFlags" = packed struct {...@@ -4996,76 +5297,81 @@ pub const @"OpenCL.DebugInfo.100.DebugInfoFlags" = packed struct {
4996 _reserved_bit_29: bool = false,5297 _reserved_bit_29: bool = false,
4997 _reserved_bit_30: bool = false,5298 _reserved_bit_30: bool = false,
4998 _reserved_bit_31: bool = false,5299 _reserved_bit_31: bool = false,
5300
5301 pub const Extended = struct {
5302 tensor_view: ?struct { id_ref: Id } = null,
5303 decode_func: ?struct { id_ref: Id } = null,
5304 _reserved_bit_2: bool = false,
5305 _reserved_bit_3: bool = false,
5306 _reserved_bit_4: bool = false,
5307 _reserved_bit_5: bool = false,
5308 _reserved_bit_6: bool = false,
5309 _reserved_bit_7: bool = false,
5310 _reserved_bit_8: bool = false,
5311 _reserved_bit_9: bool = false,
5312 _reserved_bit_10: bool = false,
5313 _reserved_bit_11: bool = false,
5314 _reserved_bit_12: bool = false,
5315 _reserved_bit_13: bool = false,
5316 _reserved_bit_14: bool = false,
5317 _reserved_bit_15: bool = false,
5318 _reserved_bit_16: bool = false,
5319 _reserved_bit_17: bool = false,
5320 _reserved_bit_18: bool = false,
5321 _reserved_bit_19: bool = false,
5322 _reserved_bit_20: bool = false,
5323 _reserved_bit_21: bool = false,
5324 _reserved_bit_22: bool = false,
5325 _reserved_bit_23: bool = false,
5326 _reserved_bit_24: bool = false,
5327 _reserved_bit_25: bool = false,
5328 _reserved_bit_26: bool = false,
5329 _reserved_bit_27: bool = false,
5330 _reserved_bit_28: bool = false,
5331 _reserved_bit_29: bool = false,
5332 _reserved_bit_30: bool = false,
5333 _reserved_bit_31: bool = false,
5334 };
4999};5335};
5000pub const @"OpenCL.DebugInfo.100.DebugBaseTypeAttributeEncoding" = enum(u32) {5336pub const InitializationModeQualifier = enum(u32) {
5001 Unspecified = 0,5337 init_on_device_reprogram_intel = 0,
5002 Address = 1,5338 init_on_device_reset_intel = 1,
5003 Boolean = 2,
5004 Float = 3,
5005 Signed = 4,
5006 SignedChar = 5,
5007 Unsigned = 6,
5008 UnsignedChar = 7,
5009};
5010pub const @"OpenCL.DebugInfo.100.DebugCompositeType" = enum(u32) {
5011 Class = 0,
5012 Structure = 1,
5013 Union = 2,
5014};5339};
5015pub const @"OpenCL.DebugInfo.100.DebugTypeQualifier" = enum(u32) {5340pub const LoadCacheControl = enum(u32) {
5016 ConstType = 0,5341 uncached_intel = 0,
5017 VolatileType = 1,5342 cached_intel = 1,
5018 RestrictType = 2,5343 streaming_intel = 2,
5019 AtomicType = 3,5344 invalidate_after_read_intel = 3,
5345 const_cached_intel = 4,
5020};5346};
5021pub const @"OpenCL.DebugInfo.100.DebugOperation" = enum(u32) {5347pub const StoreCacheControl = enum(u32) {
5022 Deref = 0,5348 uncached_intel = 0,
5023 Plus = 1,5349 write_through_intel = 1,
5024 Minus = 2,5350 write_back_intel = 2,
5025 PlusUconst = 3,5351 streaming_intel = 3,
5026 BitPiece = 4,
5027 Swap = 5,
5028 Xderef = 6,
5029 StackValue = 7,
5030 Constu = 8,
5031 Fragment = 9,
5032
5033 pub const Extended = union(@"OpenCL.DebugInfo.100.DebugOperation") {
5034 Deref,
5035 Plus,
5036 Minus,
5037 PlusUconst: struct { literal_integer: LiteralInteger },
5038 BitPiece: struct { literal_integer_0: LiteralInteger, literal_integer_1: LiteralInteger },
5039 Swap,
5040 Xderef,
5041 StackValue,
5042 Constu: struct { literal_integer: LiteralInteger },
5043 Fragment: struct { literal_integer_0: LiteralInteger, literal_integer_1: LiteralInteger },
5044 };
5045};5352};
5046pub const @"OpenCL.DebugInfo.100.DebugImportedEntity" = enum(u32) {5353pub const NamedMaximumNumberOfRegisters = enum(u32) {
5047 ImportedModule = 0,5354 auto_intel = 0,
5048 ImportedDeclaration = 1,
5049};5355};
5050pub const @"NonSemantic.Shader.DebugInfo.100.DebugInfoFlags" = packed struct {5356pub const MatrixMultiplyAccumulateOperands = packed struct {
5051 FlagIsProtected: bool = false,5357 matrix_a_signed_components_intel: bool = false,
5052 FlagIsPrivate: bool = false,5358 matrix_b_signed_components_intel: bool = false,
5053 FlagIsLocal: bool = false,5359 matrix_cb_float16intel: bool = false,
5054 FlagIsDefinition: bool = false,5360 matrix_result_b_float16intel: bool = false,
5055 FlagFwdDecl: bool = false,5361 matrix_a_packed_int8intel: bool = false,
5056 FlagArtificial: bool = false,5362 matrix_b_packed_int8intel: bool = false,
5057 FlagExplicit: bool = false,5363 matrix_a_packed_int4intel: bool = false,
5058 FlagPrototyped: bool = false,5364 matrix_b_packed_int4intel: bool = false,
5059 FlagObjectPointer: bool = false,5365 matrix_atf32intel: bool = false,
5060 FlagStaticMember: bool = false,5366 matrix_btf32intel: bool = false,
5061 FlagIndirectVariable: bool = false,5367 matrix_a_packed_float16intel: bool = false,
5062 FlagLValueReference: bool = false,5368 matrix_b_packed_float16intel: bool = false,
5063 FlagRValueReference: bool = false,5369 matrix_a_packed_b_float16intel: bool = false,
5064 FlagIsOptimized: bool = false,5370 matrix_b_packed_b_float16intel: bool = false,
5065 FlagIsEnumClass: bool = false,5371 _reserved_bit_14: bool = false,
5066 FlagTypePassByValue: bool = false,5372 _reserved_bit_15: bool = false,
5067 FlagTypePassByReference: bool = false,5373 _reserved_bit_16: bool = false,
5068 FlagUnknownPhysicalLayout: bool = false,5374 _reserved_bit_17: bool = false,
5069 _reserved_bit_18: bool = false,5375 _reserved_bit_18: bool = false,
5070 _reserved_bit_19: bool = false,5376 _reserved_bit_19: bool = false,
5071 _reserved_bit_20: bool = false,5377 _reserved_bit_20: bool = false,
...@@ -5081,12 +5387,40 @@ pub const @"NonSemantic.Shader.DebugInfo.100.DebugInfoFlags" = packed struct {...@@ -5081,12 +5387,40 @@ pub const @"NonSemantic.Shader.DebugInfo.100.DebugInfoFlags" = packed struct {
5081 _reserved_bit_30: bool = false,5387 _reserved_bit_30: bool = false,
5082 _reserved_bit_31: bool = false,5388 _reserved_bit_31: bool = false,
5083};5389};
5084pub const @"NonSemantic.Shader.DebugInfo.100.BuildIdentifierFlags" = packed struct {5390pub const FPEncoding = enum(u32) {
5085 IdentifierPossibleDuplicates: bool = false,5391 b_float16khr = 0,
5086 _reserved_bit_1: bool = false,5392 float8e4m3ext = 4214,
5087 _reserved_bit_2: bool = false,5393 float8e5m2ext = 4215,
5088 _reserved_bit_3: bool = false,5394};
5089 _reserved_bit_4: bool = false,5395pub const CooperativeVectorMatrixLayout = enum(u32) {
5396 row_major_nv = 0,
5397 column_major_nv = 1,
5398 inferencing_optimal_nv = 2,
5399 training_optimal_nv = 3,
5400};
5401pub const ComponentType = enum(u32) {
5402 float16nv = 0,
5403 float32nv = 1,
5404 float64nv = 2,
5405 signed_int8nv = 3,
5406 signed_int16nv = 4,
5407 signed_int32nv = 5,
5408 signed_int64nv = 6,
5409 unsigned_int8nv = 7,
5410 unsigned_int16nv = 8,
5411 unsigned_int32nv = 9,
5412 unsigned_int64nv = 10,
5413 signed_int8packed_nv = 1000491000,
5414 unsigned_int8packed_nv = 1000491001,
5415 float_e4m3nv = 1000491002,
5416 float_e5m2nv = 1000491003,
5417};
5418pub const TensorOperands = packed struct {
5419 nontemporal_arm: bool = false,
5420 out_of_bounds_value_arm: bool = false,
5421 make_element_available_arm: bool = false,
5422 make_element_visible_arm: bool = false,
5423 non_private_element_arm: bool = false,
5090 _reserved_bit_5: bool = false,5424 _reserved_bit_5: bool = false,
5091 _reserved_bit_6: bool = false,5425 _reserved_bit_6: bool = false,
5092 _reserved_bit_7: bool = false,5426 _reserved_bit_7: bool = false,
...@@ -5114,59 +5448,205 @@ pub const @"NonSemantic.Shader.DebugInfo.100.BuildIdentifierFlags" = packed stru...@@ -5114,59 +5448,205 @@ pub const @"NonSemantic.Shader.DebugInfo.100.BuildIdentifierFlags" = packed stru
5114 _reserved_bit_29: bool = false,5448 _reserved_bit_29: bool = false,
5115 _reserved_bit_30: bool = false,5449 _reserved_bit_30: bool = false,
5116 _reserved_bit_31: bool = false,5450 _reserved_bit_31: bool = false,
5451
5452 pub const Extended = struct {
5453 nontemporal_arm: bool = false,
5454 out_of_bounds_value_arm: ?struct { id_ref: Id } = null,
5455 make_element_available_arm: ?struct { id_ref: Id } = null,
5456 make_element_visible_arm: ?struct { id_ref: Id } = null,
5457 non_private_element_arm: bool = false,
5458 _reserved_bit_5: bool = false,
5459 _reserved_bit_6: bool = false,
5460 _reserved_bit_7: bool = false,
5461 _reserved_bit_8: bool = false,
5462 _reserved_bit_9: bool = false,
5463 _reserved_bit_10: bool = false,
5464 _reserved_bit_11: bool = false,
5465 _reserved_bit_12: bool = false,
5466 _reserved_bit_13: bool = false,
5467 _reserved_bit_14: bool = false,
5468 _reserved_bit_15: bool = false,
5469 _reserved_bit_16: bool = false,
5470 _reserved_bit_17: bool = false,
5471 _reserved_bit_18: bool = false,
5472 _reserved_bit_19: bool = false,
5473 _reserved_bit_20: bool = false,
5474 _reserved_bit_21: bool = false,
5475 _reserved_bit_22: bool = false,
5476 _reserved_bit_23: bool = false,
5477 _reserved_bit_24: bool = false,
5478 _reserved_bit_25: bool = false,
5479 _reserved_bit_26: bool = false,
5480 _reserved_bit_27: bool = false,
5481 _reserved_bit_28: bool = false,
5482 _reserved_bit_29: bool = false,
5483 _reserved_bit_30: bool = false,
5484 _reserved_bit_31: bool = false,
5485 };
5117};5486};
5118pub const @"NonSemantic.Shader.DebugInfo.100.DebugBaseTypeAttributeEncoding" = enum(u32) {5487pub const @"DebugInfo.DebugInfoFlags" = packed struct {
5119 Unspecified = 0,5488 flag_is_protected: bool = false,
5120 Address = 1,5489 flag_is_private: bool = false,
5121 Boolean = 2,5490 flag_is_local: bool = false,
5122 Float = 3,5491 flag_is_definition: bool = false,
5123 Signed = 4,5492 flag_fwd_decl: bool = false,
5124 SignedChar = 5,5493 flag_artificial: bool = false,
5125 Unsigned = 6,5494 flag_explicit: bool = false,
5126 UnsignedChar = 7,5495 flag_prototyped: bool = false,
5496 flag_object_pointer: bool = false,
5497 flag_static_member: bool = false,
5498 flag_indirect_variable: bool = false,
5499 flag_l_value_reference: bool = false,
5500 flag_r_value_reference: bool = false,
5501 flag_is_optimized: bool = false,
5502 _reserved_bit_14: bool = false,
5503 _reserved_bit_15: bool = false,
5504 _reserved_bit_16: bool = false,
5505 _reserved_bit_17: bool = false,
5506 _reserved_bit_18: bool = false,
5507 _reserved_bit_19: bool = false,
5508 _reserved_bit_20: bool = false,
5509 _reserved_bit_21: bool = false,
5510 _reserved_bit_22: bool = false,
5511 _reserved_bit_23: bool = false,
5512 _reserved_bit_24: bool = false,
5513 _reserved_bit_25: bool = false,
5514 _reserved_bit_26: bool = false,
5515 _reserved_bit_27: bool = false,
5516 _reserved_bit_28: bool = false,
5517 _reserved_bit_29: bool = false,
5518 _reserved_bit_30: bool = false,
5519 _reserved_bit_31: bool = false,
5127};5520};
5128pub const @"NonSemantic.Shader.DebugInfo.100.DebugCompositeType" = enum(u32) {5521pub const @"DebugInfo.DebugBaseTypeAttributeEncoding" = enum(u32) {
5129 Class = 0,5522 unspecified = 0,
5130 Structure = 1,5523 address = 1,
5131 Union = 2,5524 boolean = 2,
5525 float = 4,
5526 signed = 5,
5527 signed_char = 6,
5528 unsigned = 7,
5529 unsigned_char = 8,
5132};5530};
5133pub const @"NonSemantic.Shader.DebugInfo.100.DebugTypeQualifier" = enum(u32) {5531pub const @"DebugInfo.DebugCompositeType" = enum(u32) {
5134 ConstType = 0,5532 class = 0,
5135 VolatileType = 1,5533 structure = 1,
5136 RestrictType = 2,5534 @"union" = 2,
5137 AtomicType = 3,
5138};5535};
5139pub const @"NonSemantic.Shader.DebugInfo.100.DebugOperation" = enum(u32) {5536pub const @"DebugInfo.DebugTypeQualifier" = enum(u32) {
5140 Deref = 0,5537 const_type = 0,
5141 Plus = 1,5538 volatile_type = 1,
5142 Minus = 2,5539 restrict_type = 2,
5143 PlusUconst = 3,5540};
5144 BitPiece = 4,5541pub const @"DebugInfo.DebugOperation" = enum(u32) {
5145 Swap = 5,5542 deref = 0,
5146 Xderef = 6,5543 plus = 1,
5147 StackValue = 7,5544 minus = 2,
5148 Constu = 8,5545 plus_uconst = 3,
5149 Fragment = 9,5546 bit_piece = 4,
5547 swap = 5,
5548 xderef = 6,
5549 stack_value = 7,
5550 constu = 8,
51505551
5151 pub const Extended = union(@"NonSemantic.Shader.DebugInfo.100.DebugOperation") {5552 pub const Extended = union(@"DebugInfo.DebugOperation") {
5152 Deref,5553 deref,
5153 Plus,5554 plus,
5154 Minus,5555 minus,
5155 PlusUconst: struct { id_ref: IdRef },5556 plus_uconst: struct { literal_integer: LiteralInteger },
5156 BitPiece: struct { id_ref_0: IdRef, id_ref_1: IdRef },5557 bit_piece: struct { literal_integer_0: LiteralInteger, literal_integer_1: LiteralInteger },
5157 Swap,5558 swap,
5158 Xderef,5559 xderef,
5159 StackValue,5560 stack_value,
5160 Constu: struct { id_ref: IdRef },5561 constu: struct { literal_integer: LiteralInteger },
5161 Fragment: struct { id_ref_0: IdRef, id_ref_1: IdRef },
5162 };5562 };
5163};5563};
5164pub const @"NonSemantic.Shader.DebugInfo.100.DebugImportedEntity" = enum(u32) {5564pub const @"OpenCL.DebugInfo.100.DebugInfoFlags" = packed struct {
5165 ImportedModule = 0,5565 flag_is_protected: bool = false,
5166 ImportedDeclaration = 1,5566 flag_is_private: bool = false,
5567 flag_is_local: bool = false,
5568 flag_is_definition: bool = false,
5569 flag_fwd_decl: bool = false,
5570 flag_artificial: bool = false,
5571 flag_explicit: bool = false,
5572 flag_prototyped: bool = false,
5573 flag_object_pointer: bool = false,
5574 flag_static_member: bool = false,
5575 flag_indirect_variable: bool = false,
5576 flag_l_value_reference: bool = false,
5577 flag_r_value_reference: bool = false,
5578 flag_is_optimized: bool = false,
5579 flag_is_enum_class: bool = false,
5580 flag_type_pass_by_value: bool = false,
5581 flag_type_pass_by_reference: bool = false,
5582 _reserved_bit_17: bool = false,
5583 _reserved_bit_18: bool = false,
5584 _reserved_bit_19: bool = false,
5585 _reserved_bit_20: bool = false,
5586 _reserved_bit_21: bool = false,
5587 _reserved_bit_22: bool = false,
5588 _reserved_bit_23: bool = false,
5589 _reserved_bit_24: bool = false,
5590 _reserved_bit_25: bool = false,
5591 _reserved_bit_26: bool = false,
5592 _reserved_bit_27: bool = false,
5593 _reserved_bit_28: bool = false,
5594 _reserved_bit_29: bool = false,
5595 _reserved_bit_30: bool = false,
5596 _reserved_bit_31: bool = false,
5597};
5598pub const @"OpenCL.DebugInfo.100.DebugBaseTypeAttributeEncoding" = enum(u32) {
5599 unspecified = 0,
5600 address = 1,
5601 boolean = 2,
5602 float = 3,
5603 signed = 4,
5604 signed_char = 5,
5605 unsigned = 6,
5606 unsigned_char = 7,
5607};
5608pub const @"OpenCL.DebugInfo.100.DebugCompositeType" = enum(u32) {
5609 class = 0,
5610 structure = 1,
5611 @"union" = 2,
5612};
5613pub const @"OpenCL.DebugInfo.100.DebugTypeQualifier" = enum(u32) {
5614 const_type = 0,
5615 volatile_type = 1,
5616 restrict_type = 2,
5617 atomic_type = 3,
5618};
5619pub const @"OpenCL.DebugInfo.100.DebugOperation" = enum(u32) {
5620 deref = 0,
5621 plus = 1,
5622 minus = 2,
5623 plus_uconst = 3,
5624 bit_piece = 4,
5625 swap = 5,
5626 xderef = 6,
5627 stack_value = 7,
5628 constu = 8,
5629 fragment = 9,
5630
5631 pub const Extended = union(@"OpenCL.DebugInfo.100.DebugOperation") {
5632 deref,
5633 plus,
5634 minus,
5635 plus_uconst: struct { literal_integer: LiteralInteger },
5636 bit_piece: struct { literal_integer_0: LiteralInteger, literal_integer_1: LiteralInteger },
5637 swap,
5638 xderef,
5639 stack_value,
5640 constu: struct { literal_integer: LiteralInteger },
5641 fragment: struct { literal_integer_0: LiteralInteger, literal_integer_1: LiteralInteger },
5642 };
5643};
5644pub const @"OpenCL.DebugInfo.100.DebugImportedEntity" = enum(u32) {
5645 imported_module = 0,
5646 imported_declaration = 1,
5167};5647};
5168pub const @"NonSemantic.ClspvReflection.6.KernelPropertyFlags" = packed struct {5648pub const @"NonSemantic.ClspvReflection.6.KernelPropertyFlags" = packed struct {
5169 MayUsePrintf: bool = false,5649 may_use_printf: bool = false,
5170 _reserved_bit_1: bool = false,5650 _reserved_bit_1: bool = false,
5171 _reserved_bit_2: bool = false,5651 _reserved_bit_2: bool = false,
5172 _reserved_bit_3: bool = false,5652 _reserved_bit_3: bool = false,
...@@ -5199,21 +5679,55 @@ pub const @"NonSemantic.ClspvReflection.6.KernelPropertyFlags" = packed struct {...@@ -5199,21 +5679,55 @@ pub const @"NonSemantic.ClspvReflection.6.KernelPropertyFlags" = packed struct {
5199 _reserved_bit_30: bool = false,5679 _reserved_bit_30: bool = false,
5200 _reserved_bit_31: bool = false,5680 _reserved_bit_31: bool = false,
5201};5681};
5202pub const @"DebugInfo.DebugInfoFlags" = packed struct {5682pub const @"NonSemantic.Shader.DebugInfo.100.DebugInfoFlags" = packed struct {
5203 FlagIsProtected: bool = false,5683 flag_is_protected: bool = false,
5204 FlagIsPrivate: bool = false,5684 flag_is_private: bool = false,
5205 FlagIsLocal: bool = false,5685 flag_is_local: bool = false,
5206 FlagIsDefinition: bool = false,5686 flag_is_definition: bool = false,
5207 FlagFwdDecl: bool = false,5687 flag_fwd_decl: bool = false,
5208 FlagArtificial: bool = false,5688 flag_artificial: bool = false,
5209 FlagExplicit: bool = false,5689 flag_explicit: bool = false,
5210 FlagPrototyped: bool = false,5690 flag_prototyped: bool = false,
5211 FlagObjectPointer: bool = false,5691 flag_object_pointer: bool = false,
5212 FlagStaticMember: bool = false,5692 flag_static_member: bool = false,
5213 FlagIndirectVariable: bool = false,5693 flag_indirect_variable: bool = false,
5214 FlagLValueReference: bool = false,5694 flag_l_value_reference: bool = false,
5215 FlagRValueReference: bool = false,5695 flag_r_value_reference: bool = false,
5216 FlagIsOptimized: bool = false,5696 flag_is_optimized: bool = false,
5697 flag_is_enum_class: bool = false,
5698 flag_type_pass_by_value: bool = false,
5699 flag_type_pass_by_reference: bool = false,
5700 flag_unknown_physical_layout: bool = false,
5701 _reserved_bit_18: bool = false,
5702 _reserved_bit_19: bool = false,
5703 _reserved_bit_20: bool = false,
5704 _reserved_bit_21: bool = false,
5705 _reserved_bit_22: bool = false,
5706 _reserved_bit_23: bool = false,
5707 _reserved_bit_24: bool = false,
5708 _reserved_bit_25: bool = false,
5709 _reserved_bit_26: bool = false,
5710 _reserved_bit_27: bool = false,
5711 _reserved_bit_28: bool = false,
5712 _reserved_bit_29: bool = false,
5713 _reserved_bit_30: bool = false,
5714 _reserved_bit_31: bool = false,
5715};
5716pub const @"NonSemantic.Shader.DebugInfo.100.BuildIdentifierFlags" = packed struct {
5717 identifier_possible_duplicates: bool = false,
5718 _reserved_bit_1: bool = false,
5719 _reserved_bit_2: bool = false,
5720 _reserved_bit_3: bool = false,
5721 _reserved_bit_4: bool = false,
5722 _reserved_bit_5: bool = false,
5723 _reserved_bit_6: bool = false,
5724 _reserved_bit_7: bool = false,
5725 _reserved_bit_8: bool = false,
5726 _reserved_bit_9: bool = false,
5727 _reserved_bit_10: bool = false,
5728 _reserved_bit_11: bool = false,
5729 _reserved_bit_12: bool = false,
5730 _reserved_bit_13: bool = false,
5217 _reserved_bit_14: bool = false,5731 _reserved_bit_14: bool = false,
5218 _reserved_bit_15: bool = false,5732 _reserved_bit_15: bool = false,
5219 _reserved_bit_16: bool = false,5733 _reserved_bit_16: bool = false,
...@@ -5233,11298 +5747,12669 @@ pub const @"DebugInfo.DebugInfoFlags" = packed struct {...@@ -5233,11298 +5747,12669 @@ pub const @"DebugInfo.DebugInfoFlags" = packed struct {
5233 _reserved_bit_30: bool = false,5747 _reserved_bit_30: bool = false,
5234 _reserved_bit_31: bool = false,5748 _reserved_bit_31: bool = false,
5235};5749};
5236pub const @"DebugInfo.DebugBaseTypeAttributeEncoding" = enum(u32) {5750pub const @"NonSemantic.Shader.DebugInfo.100.DebugBaseTypeAttributeEncoding" = enum(u32) {
5237 Unspecified = 0,5751 unspecified = 0,
5238 Address = 1,5752 address = 1,
5239 Boolean = 2,5753 boolean = 2,
5240 Float = 4,5754 float = 3,
5241 Signed = 5,5755 signed = 4,
5242 SignedChar = 6,5756 signed_char = 5,
5243 Unsigned = 7,5757 unsigned = 6,
5244 UnsignedChar = 8,5758 unsigned_char = 7,
5245};5759};
5246pub const @"DebugInfo.DebugCompositeType" = enum(u32) {5760pub const @"NonSemantic.Shader.DebugInfo.100.DebugCompositeType" = enum(u32) {
5247 Class = 0,5761 class = 0,
5248 Structure = 1,5762 structure = 1,
5249 Union = 2,5763 @"union" = 2,
5250};5764};
5251pub const @"DebugInfo.DebugTypeQualifier" = enum(u32) {5765pub const @"NonSemantic.Shader.DebugInfo.100.DebugTypeQualifier" = enum(u32) {
5252 ConstType = 0,5766 const_type = 0,
5253 VolatileType = 1,5767 volatile_type = 1,
5254 RestrictType = 2,5768 restrict_type = 2,
5769 atomic_type = 3,
5255};5770};
5256pub const @"DebugInfo.DebugOperation" = enum(u32) {5771pub const @"NonSemantic.Shader.DebugInfo.100.DebugOperation" = enum(u32) {
5257 Deref = 0,5772 deref = 0,
5258 Plus = 1,5773 plus = 1,
5259 Minus = 2,5774 minus = 2,
5260 PlusUconst = 3,5775 plus_uconst = 3,
5261 BitPiece = 4,5776 bit_piece = 4,
5262 Swap = 5,5777 swap = 5,
5263 Xderef = 6,5778 xderef = 6,
5264 StackValue = 7,5779 stack_value = 7,
5265 Constu = 8,5780 constu = 8,
5781 fragment = 9,
52665782
5267 pub const Extended = union(@"DebugInfo.DebugOperation") {5783 pub const Extended = union(@"NonSemantic.Shader.DebugInfo.100.DebugOperation") {
5268 Deref,5784 deref,
5269 Plus,5785 plus,
5270 Minus,5786 minus,
5271 PlusUconst: struct { literal_integer: LiteralInteger },5787 plus_uconst: struct { id_ref: Id },
5272 BitPiece: struct { literal_integer_0: LiteralInteger, literal_integer_1: LiteralInteger },5788 bit_piece: struct { id_ref_0: Id, id_ref_1: Id },
5273 Swap,5789 swap,
5274 Xderef,5790 xderef,
5275 StackValue,5791 stack_value,
5276 Constu: struct { literal_integer: LiteralInteger },5792 constu: struct { id_ref: Id },
5793 fragment: struct { id_ref_0: Id, id_ref_1: Id },
5277 };5794 };
5278};5795};
5796pub const @"NonSemantic.Shader.DebugInfo.100.DebugImportedEntity" = enum(u32) {
5797 imported_module = 0,
5798 imported_declaration = 1,
5799};
5279pub const InstructionSet = enum {5800pub const InstructionSet = enum {
5280 core,5801 core,
5281 @"OpenCL.std",5802 spv_amd_shader_trinary_minmax,
5282 @"GLSL.std.450",5803 spv_ext_inst_type_tosa_001000_1,
5283 @"OpenCL.DebugInfo.100",5804 non_semantic_vksp_reflection,
5284 SPV_AMD_shader_ballot,5805 spv_amd_shader_explicit_vertex_parameter,
5285 @"NonSemantic.Shader.DebugInfo.100",5806 debug_info,
5286 @"NonSemantic.VkspReflection",5807 non_semantic_debug_break,
5287 @"NonSemantic.ClspvReflection.6",5808 open_cl_debug_info_100,
5288 SPV_AMD_gcn_shader,5809 non_semantic_clspv_reflection_6,
5289 SPV_AMD_shader_trinary_minmax,5810 glsl_std_450,
5290 DebugInfo,5811 spv_amd_shader_ballot,
5291 @"NonSemantic.DebugPrintf",5812 non_semantic_debug_printf,
5292 SPV_AMD_shader_explicit_vertex_parameter,5813 spv_amd_gcn_shader,
5293 @"NonSemantic.DebugBreak",5814 open_cl_std,
5815 non_semantic_shader_debug_info_100,
5294 zig,5816 zig,
52955817
5296 pub fn instructions(self: InstructionSet) []const Instruction {5818 pub fn instructions(self: InstructionSet) []const Instruction {
5297 return switch (self) {5819 return switch (self) {
5298 .core => &[_]Instruction{5820 .core => &.{
5299 .{5821 .{
5300 .name = "OpNop",5822 .name = "OpNop",
5301 .opcode = 0,5823 .opcode = 0,
5302 .operands = &[_]Operand{},5824 .operands = &.{},
5303 },5825 },
5304 .{5826 .{
5305 .name = "OpUndef",5827 .name = "OpUndef",
5306 .opcode = 1,5828 .opcode = 1,
5307 .operands = &[_]Operand{5829 .operands = &.{
5308 .{ .kind = .IdResultType, .quantifier = .required },5830 .{ .kind = .id_result_type, .quantifier = .required },
5309 .{ .kind = .IdResult, .quantifier = .required },5831 .{ .kind = .id_result, .quantifier = .required },
5310 },5832 },
5311 },5833 },
5312 .{5834 .{
5313 .name = "OpSourceContinued",5835 .name = "OpSourceContinued",
5314 .opcode = 2,5836 .opcode = 2,
5315 .operands = &[_]Operand{5837 .operands = &.{
5316 .{ .kind = .LiteralString, .quantifier = .required },5838 .{ .kind = .literal_string, .quantifier = .required },
5317 },5839 },
5318 },5840 },
5319 .{5841 .{
5320 .name = "OpSource",5842 .name = "OpSource",
5321 .opcode = 3,5843 .opcode = 3,
5322 .operands = &[_]Operand{5844 .operands = &.{
5323 .{ .kind = .SourceLanguage, .quantifier = .required },5845 .{ .kind = .source_language, .quantifier = .required },
5324 .{ .kind = .LiteralInteger, .quantifier = .required },5846 .{ .kind = .literal_integer, .quantifier = .required },
5325 .{ .kind = .IdRef, .quantifier = .optional },5847 .{ .kind = .id_ref, .quantifier = .optional },
5326 .{ .kind = .LiteralString, .quantifier = .optional },5848 .{ .kind = .literal_string, .quantifier = .optional },
5327 },5849 },
5328 },5850 },
5329 .{5851 .{
5330 .name = "OpSourceExtension",5852 .name = "OpSourceExtension",
5331 .opcode = 4,5853 .opcode = 4,
5332 .operands = &[_]Operand{5854 .operands = &.{
5333 .{ .kind = .LiteralString, .quantifier = .required },5855 .{ .kind = .literal_string, .quantifier = .required },
5334 },5856 },
5335 },5857 },
5336 .{5858 .{
5337 .name = "OpName",5859 .name = "OpName",
5338 .opcode = 5,5860 .opcode = 5,
5339 .operands = &[_]Operand{5861 .operands = &.{
5340 .{ .kind = .IdRef, .quantifier = .required },5862 .{ .kind = .id_ref, .quantifier = .required },
5341 .{ .kind = .LiteralString, .quantifier = .required },5863 .{ .kind = .literal_string, .quantifier = .required },
5342 },5864 },
5343 },5865 },
5344 .{5866 .{
5345 .name = "OpMemberName",5867 .name = "OpMemberName",
5346 .opcode = 6,5868 .opcode = 6,
5347 .operands = &[_]Operand{5869 .operands = &.{
5348 .{ .kind = .IdRef, .quantifier = .required },5870 .{ .kind = .id_ref, .quantifier = .required },
5349 .{ .kind = .LiteralInteger, .quantifier = .required },5871 .{ .kind = .literal_integer, .quantifier = .required },
5350 .{ .kind = .LiteralString, .quantifier = .required },5872 .{ .kind = .literal_string, .quantifier = .required },
5351 },5873 },
5352 },5874 },
5353 .{5875 .{
5354 .name = "OpString",5876 .name = "OpString",
5355 .opcode = 7,5877 .opcode = 7,
5356 .operands = &[_]Operand{5878 .operands = &.{
5357 .{ .kind = .IdResult, .quantifier = .required },5879 .{ .kind = .id_result, .quantifier = .required },
5358 .{ .kind = .LiteralString, .quantifier = .required },5880 .{ .kind = .literal_string, .quantifier = .required },
5359 },5881 },
5360 },5882 },
5361 .{5883 .{
5362 .name = "OpLine",5884 .name = "OpLine",
5363 .opcode = 8,5885 .opcode = 8,
5364 .operands = &[_]Operand{5886 .operands = &.{
5365 .{ .kind = .IdRef, .quantifier = .required },5887 .{ .kind = .id_ref, .quantifier = .required },
5366 .{ .kind = .LiteralInteger, .quantifier = .required },5888 .{ .kind = .literal_integer, .quantifier = .required },
5367 .{ .kind = .LiteralInteger, .quantifier = .required },5889 .{ .kind = .literal_integer, .quantifier = .required },
5368 },5890 },
5369 },5891 },
5370 .{5892 .{
5371 .name = "OpExtension",5893 .name = "OpExtension",
5372 .opcode = 10,5894 .opcode = 10,
5373 .operands = &[_]Operand{5895 .operands = &.{
5374 .{ .kind = .LiteralString, .quantifier = .required },5896 .{ .kind = .literal_string, .quantifier = .required },
5375 },5897 },
5376 },5898 },
5377 .{5899 .{
5378 .name = "OpExtInstImport",5900 .name = "OpExtInstImport",
5379 .opcode = 11,5901 .opcode = 11,
5380 .operands = &[_]Operand{5902 .operands = &.{
5381 .{ .kind = .IdResult, .quantifier = .required },5903 .{ .kind = .id_result, .quantifier = .required },
5382 .{ .kind = .LiteralString, .quantifier = .required },5904 .{ .kind = .literal_string, .quantifier = .required },
5383 },5905 },
5384 },5906 },
5385 .{5907 .{
5386 .name = "OpExtInst",5908 .name = "OpExtInst",
5387 .opcode = 12,5909 .opcode = 12,
5388 .operands = &[_]Operand{5910 .operands = &.{
5389 .{ .kind = .IdResultType, .quantifier = .required },5911 .{ .kind = .id_result_type, .quantifier = .required },
5390 .{ .kind = .IdResult, .quantifier = .required },5912 .{ .kind = .id_result, .quantifier = .required },
5391 .{ .kind = .IdRef, .quantifier = .required },5913 .{ .kind = .id_ref, .quantifier = .required },
5392 .{ .kind = .LiteralExtInstInteger, .quantifier = .required },5914 .{ .kind = .literal_ext_inst_integer, .quantifier = .required },
5393 .{ .kind = .IdRef, .quantifier = .variadic },5915 .{ .kind = .id_ref, .quantifier = .variadic },
5394 },5916 },
5395 },5917 },
5396 .{5918 .{
5397 .name = "OpMemoryModel",5919 .name = "OpMemoryModel",
5398 .opcode = 14,5920 .opcode = 14,
5399 .operands = &[_]Operand{5921 .operands = &.{
5400 .{ .kind = .AddressingModel, .quantifier = .required },5922 .{ .kind = .addressing_model, .quantifier = .required },
5401 .{ .kind = .MemoryModel, .quantifier = .required },5923 .{ .kind = .memory_model, .quantifier = .required },
5402 },5924 },
5403 },5925 },
5404 .{5926 .{
5405 .name = "OpEntryPoint",5927 .name = "OpEntryPoint",
5406 .opcode = 15,5928 .opcode = 15,
5407 .operands = &[_]Operand{5929 .operands = &.{
5408 .{ .kind = .ExecutionModel, .quantifier = .required },5930 .{ .kind = .execution_model, .quantifier = .required },
5409 .{ .kind = .IdRef, .quantifier = .required },5931 .{ .kind = .id_ref, .quantifier = .required },
5410 .{ .kind = .LiteralString, .quantifier = .required },5932 .{ .kind = .literal_string, .quantifier = .required },
5411 .{ .kind = .IdRef, .quantifier = .variadic },5933 .{ .kind = .id_ref, .quantifier = .variadic },
5412 },5934 },
5413 },5935 },
5414 .{5936 .{
5415 .name = "OpExecutionMode",5937 .name = "OpExecutionMode",
5416 .opcode = 16,5938 .opcode = 16,
5417 .operands = &[_]Operand{5939 .operands = &.{
5418 .{ .kind = .IdRef, .quantifier = .required },5940 .{ .kind = .id_ref, .quantifier = .required },
5419 .{ .kind = .ExecutionMode, .quantifier = .required },5941 .{ .kind = .execution_mode, .quantifier = .required },
5420 },5942 },
5421 },5943 },
5422 .{5944 .{
5423 .name = "OpCapability",5945 .name = "OpCapability",
5424 .opcode = 17,5946 .opcode = 17,
5425 .operands = &[_]Operand{5947 .operands = &.{
5426 .{ .kind = .Capability, .quantifier = .required },5948 .{ .kind = .capability, .quantifier = .required },
5427 },5949 },
5428 },5950 },
5429 .{5951 .{
5430 .name = "OpTypeVoid",5952 .name = "OpTypeVoid",
5431 .opcode = 19,5953 .opcode = 19,
5432 .operands = &[_]Operand{5954 .operands = &.{
5433 .{ .kind = .IdResult, .quantifier = .required },5955 .{ .kind = .id_result, .quantifier = .required },
5434 },5956 },
5435 },5957 },
5436 .{5958 .{
5437 .name = "OpTypeBool",5959 .name = "OpTypeBool",
5438 .opcode = 20,5960 .opcode = 20,
5439 .operands = &[_]Operand{5961 .operands = &.{
5440 .{ .kind = .IdResult, .quantifier = .required },5962 .{ .kind = .id_result, .quantifier = .required },
5441 },5963 },
5442 },5964 },
5443 .{5965 .{
5444 .name = "OpTypeInt",5966 .name = "OpTypeInt",
5445 .opcode = 21,5967 .opcode = 21,
5446 .operands = &[_]Operand{5968 .operands = &.{
5447 .{ .kind = .IdResult, .quantifier = .required },5969 .{ .kind = .id_result, .quantifier = .required },
5448 .{ .kind = .LiteralInteger, .quantifier = .required },5970 .{ .kind = .literal_integer, .quantifier = .required },
5449 .{ .kind = .LiteralInteger, .quantifier = .required },5971 .{ .kind = .literal_integer, .quantifier = .required },
5450 },5972 },
5451 },5973 },
5452 .{5974 .{
5453 .name = "OpTypeFloat",5975 .name = "OpTypeFloat",
5454 .opcode = 22,5976 .opcode = 22,
5455 .operands = &[_]Operand{5977 .operands = &.{
5456 .{ .kind = .IdResult, .quantifier = .required },5978 .{ .kind = .id_result, .quantifier = .required },
5457 .{ .kind = .LiteralInteger, .quantifier = .required },5979 .{ .kind = .literal_integer, .quantifier = .required },
5980 .{ .kind = .fp_encoding, .quantifier = .optional },
5458 },5981 },
5459 },5982 },
5460 .{5983 .{
5461 .name = "OpTypeVector",5984 .name = "OpTypeVector",
5462 .opcode = 23,5985 .opcode = 23,
5463 .operands = &[_]Operand{5986 .operands = &.{
5464 .{ .kind = .IdResult, .quantifier = .required },5987 .{ .kind = .id_result, .quantifier = .required },
5465 .{ .kind = .IdRef, .quantifier = .required },5988 .{ .kind = .id_ref, .quantifier = .required },
5466 .{ .kind = .LiteralInteger, .quantifier = .required },5989 .{ .kind = .literal_integer, .quantifier = .required },
5467 },5990 },
5468 },5991 },
5469 .{5992 .{
5470 .name = "OpTypeMatrix",5993 .name = "OpTypeMatrix",
5471 .opcode = 24,5994 .opcode = 24,
5472 .operands = &[_]Operand{5995 .operands = &.{
5473 .{ .kind = .IdResult, .quantifier = .required },5996 .{ .kind = .id_result, .quantifier = .required },
5474 .{ .kind = .IdRef, .quantifier = .required },5997 .{ .kind = .id_ref, .quantifier = .required },
5475 .{ .kind = .LiteralInteger, .quantifier = .required },5998 .{ .kind = .literal_integer, .quantifier = .required },
5476 },5999 },
5477 },6000 },
5478 .{6001 .{
5479 .name = "OpTypeImage",6002 .name = "OpTypeImage",
5480 .opcode = 25,6003 .opcode = 25,
5481 .operands = &[_]Operand{6004 .operands = &.{
5482 .{ .kind = .IdResult, .quantifier = .required },6005 .{ .kind = .id_result, .quantifier = .required },
5483 .{ .kind = .IdRef, .quantifier = .required },6006 .{ .kind = .id_ref, .quantifier = .required },
5484 .{ .kind = .Dim, .quantifier = .required },6007 .{ .kind = .dim, .quantifier = .required },
5485 .{ .kind = .LiteralInteger, .quantifier = .required },6008 .{ .kind = .literal_integer, .quantifier = .required },
5486 .{ .kind = .LiteralInteger, .quantifier = .required },6009 .{ .kind = .literal_integer, .quantifier = .required },
5487 .{ .kind = .LiteralInteger, .quantifier = .required },6010 .{ .kind = .literal_integer, .quantifier = .required },
5488 .{ .kind = .LiteralInteger, .quantifier = .required },6011 .{ .kind = .literal_integer, .quantifier = .required },
5489 .{ .kind = .ImageFormat, .quantifier = .required },6012 .{ .kind = .image_format, .quantifier = .required },
5490 .{ .kind = .AccessQualifier, .quantifier = .optional },6013 .{ .kind = .access_qualifier, .quantifier = .optional },
5491 },6014 },
5492 },6015 },
5493 .{6016 .{
5494 .name = "OpTypeSampler",6017 .name = "OpTypeSampler",
5495 .opcode = 26,6018 .opcode = 26,
5496 .operands = &[_]Operand{6019 .operands = &.{
5497 .{ .kind = .IdResult, .quantifier = .required },6020 .{ .kind = .id_result, .quantifier = .required },
5498 },6021 },
5499 },6022 },
5500 .{6023 .{
5501 .name = "OpTypeSampledImage",6024 .name = "OpTypeSampledImage",
5502 .opcode = 27,6025 .opcode = 27,
5503 .operands = &[_]Operand{6026 .operands = &.{
5504 .{ .kind = .IdResult, .quantifier = .required },6027 .{ .kind = .id_result, .quantifier = .required },
5505 .{ .kind = .IdRef, .quantifier = .required },6028 .{ .kind = .id_ref, .quantifier = .required },
5506 },6029 },
5507 },6030 },
5508 .{6031 .{
5509 .name = "OpTypeArray",6032 .name = "OpTypeArray",
5510 .opcode = 28,6033 .opcode = 28,
5511 .operands = &[_]Operand{6034 .operands = &.{
5512 .{ .kind = .IdResult, .quantifier = .required },6035 .{ .kind = .id_result, .quantifier = .required },
5513 .{ .kind = .IdRef, .quantifier = .required },6036 .{ .kind = .id_ref, .quantifier = .required },
5514 .{ .kind = .IdRef, .quantifier = .required },6037 .{ .kind = .id_ref, .quantifier = .required },
5515 },6038 },
5516 },6039 },
5517 .{6040 .{
5518 .name = "OpTypeRuntimeArray",6041 .name = "OpTypeRuntimeArray",
5519 .opcode = 29,6042 .opcode = 29,
5520 .operands = &[_]Operand{6043 .operands = &.{
5521 .{ .kind = .IdResult, .quantifier = .required },6044 .{ .kind = .id_result, .quantifier = .required },
5522 .{ .kind = .IdRef, .quantifier = .required },6045 .{ .kind = .id_ref, .quantifier = .required },
5523 },6046 },
5524 },6047 },
5525 .{6048 .{
5526 .name = "OpTypeStruct",6049 .name = "OpTypeStruct",
5527 .opcode = 30,6050 .opcode = 30,
5528 .operands = &[_]Operand{6051 .operands = &.{
5529 .{ .kind = .IdResult, .quantifier = .required },6052 .{ .kind = .id_result, .quantifier = .required },
5530 .{ .kind = .IdRef, .quantifier = .variadic },6053 .{ .kind = .id_ref, .quantifier = .variadic },
5531 },6054 },
5532 },6055 },
5533 .{6056 .{
5534 .name = "OpTypeOpaque",6057 .name = "OpTypeOpaque",
5535 .opcode = 31,6058 .opcode = 31,
5536 .operands = &[_]Operand{6059 .operands = &.{
5537 .{ .kind = .IdResult, .quantifier = .required },6060 .{ .kind = .id_result, .quantifier = .required },
5538 .{ .kind = .LiteralString, .quantifier = .required },6061 .{ .kind = .literal_string, .quantifier = .required },
5539 },6062 },
5540 },6063 },
5541 .{6064 .{
5542 .name = "OpTypePointer",6065 .name = "OpTypePointer",
5543 .opcode = 32,6066 .opcode = 32,
5544 .operands = &[_]Operand{6067 .operands = &.{
5545 .{ .kind = .IdResult, .quantifier = .required },6068 .{ .kind = .id_result, .quantifier = .required },
5546 .{ .kind = .StorageClass, .quantifier = .required },6069 .{ .kind = .storage_class, .quantifier = .required },
5547 .{ .kind = .IdRef, .quantifier = .required },6070 .{ .kind = .id_ref, .quantifier = .required },
5548 },6071 },
5549 },6072 },
5550 .{6073 .{
5551 .name = "OpTypeFunction",6074 .name = "OpTypeFunction",
5552 .opcode = 33,6075 .opcode = 33,
5553 .operands = &[_]Operand{6076 .operands = &.{
5554 .{ .kind = .IdResult, .quantifier = .required },6077 .{ .kind = .id_result, .quantifier = .required },
5555 .{ .kind = .IdRef, .quantifier = .required },6078 .{ .kind = .id_ref, .quantifier = .required },
5556 .{ .kind = .IdRef, .quantifier = .variadic },6079 .{ .kind = .id_ref, .quantifier = .variadic },
5557 },6080 },
5558 },6081 },
5559 .{6082 .{
5560 .name = "OpTypeEvent",6083 .name = "OpTypeEvent",
5561 .opcode = 34,6084 .opcode = 34,
5562 .operands = &[_]Operand{6085 .operands = &.{
5563 .{ .kind = .IdResult, .quantifier = .required },6086 .{ .kind = .id_result, .quantifier = .required },
5564 },6087 },
5565 },6088 },
5566 .{6089 .{
5567 .name = "OpTypeDeviceEvent",6090 .name = "OpTypeDeviceEvent",
5568 .opcode = 35,6091 .opcode = 35,
5569 .operands = &[_]Operand{6092 .operands = &.{
5570 .{ .kind = .IdResult, .quantifier = .required },6093 .{ .kind = .id_result, .quantifier = .required },
5571 },6094 },
5572 },6095 },
5573 .{6096 .{
5574 .name = "OpTypeReserveId",6097 .name = "OpTypeReserveId",
5575 .opcode = 36,6098 .opcode = 36,
5576 .operands = &[_]Operand{6099 .operands = &.{
5577 .{ .kind = .IdResult, .quantifier = .required },6100 .{ .kind = .id_result, .quantifier = .required },
5578 },6101 },
5579 },6102 },
5580 .{6103 .{
5581 .name = "OpTypeQueue",6104 .name = "OpTypeQueue",
5582 .opcode = 37,6105 .opcode = 37,
5583 .operands = &[_]Operand{6106 .operands = &.{
5584 .{ .kind = .IdResult, .quantifier = .required },6107 .{ .kind = .id_result, .quantifier = .required },
5585 },6108 },
5586 },6109 },
5587 .{6110 .{
5588 .name = "OpTypePipe",6111 .name = "OpTypePipe",
5589 .opcode = 38,6112 .opcode = 38,
5590 .operands = &[_]Operand{6113 .operands = &.{
5591 .{ .kind = .IdResult, .quantifier = .required },6114 .{ .kind = .id_result, .quantifier = .required },
5592 .{ .kind = .AccessQualifier, .quantifier = .required },6115 .{ .kind = .access_qualifier, .quantifier = .required },
5593 },6116 },
5594 },6117 },
5595 .{6118 .{
5596 .name = "OpTypeForwardPointer",6119 .name = "OpTypeForwardPointer",
5597 .opcode = 39,6120 .opcode = 39,
5598 .operands = &[_]Operand{6121 .operands = &.{
5599 .{ .kind = .IdRef, .quantifier = .required },6122 .{ .kind = .id_ref, .quantifier = .required },
5600 .{ .kind = .StorageClass, .quantifier = .required },6123 .{ .kind = .storage_class, .quantifier = .required },
5601 },6124 },
5602 },6125 },
5603 .{6126 .{
5604 .name = "OpConstantTrue",6127 .name = "OpConstantTrue",
5605 .opcode = 41,6128 .opcode = 41,
5606 .operands = &[_]Operand{6129 .operands = &.{
5607 .{ .kind = .IdResultType, .quantifier = .required },6130 .{ .kind = .id_result_type, .quantifier = .required },
5608 .{ .kind = .IdResult, .quantifier = .required },6131 .{ .kind = .id_result, .quantifier = .required },
5609 },6132 },
5610 },6133 },
5611 .{6134 .{
5612 .name = "OpConstantFalse",6135 .name = "OpConstantFalse",
5613 .opcode = 42,6136 .opcode = 42,
5614 .operands = &[_]Operand{6137 .operands = &.{
5615 .{ .kind = .IdResultType, .quantifier = .required },6138 .{ .kind = .id_result_type, .quantifier = .required },
5616 .{ .kind = .IdResult, .quantifier = .required },6139 .{ .kind = .id_result, .quantifier = .required },
5617 },6140 },
5618 },6141 },
5619 .{6142 .{
5620 .name = "OpConstant",6143 .name = "OpConstant",
5621 .opcode = 43,6144 .opcode = 43,
5622 .operands = &[_]Operand{6145 .operands = &.{
5623 .{ .kind = .IdResultType, .quantifier = .required },6146 .{ .kind = .id_result_type, .quantifier = .required },
5624 .{ .kind = .IdResult, .quantifier = .required },6147 .{ .kind = .id_result, .quantifier = .required },
5625 .{ .kind = .LiteralContextDependentNumber, .quantifier = .required },6148 .{ .kind = .literal_context_dependent_number, .quantifier = .required },
5626 },6149 },
5627 },6150 },
5628 .{6151 .{
5629 .name = "OpConstantComposite",6152 .name = "OpConstantComposite",
5630 .opcode = 44,6153 .opcode = 44,
5631 .operands = &[_]Operand{6154 .operands = &.{
5632 .{ .kind = .IdResultType, .quantifier = .required },6155 .{ .kind = .id_result_type, .quantifier = .required },
5633 .{ .kind = .IdResult, .quantifier = .required },6156 .{ .kind = .id_result, .quantifier = .required },
5634 .{ .kind = .IdRef, .quantifier = .variadic },6157 .{ .kind = .id_ref, .quantifier = .variadic },
5635 },6158 },
5636 },6159 },
5637 .{6160 .{
5638 .name = "OpConstantSampler",6161 .name = "OpConstantSampler",
5639 .opcode = 45,6162 .opcode = 45,
5640 .operands = &[_]Operand{6163 .operands = &.{
5641 .{ .kind = .IdResultType, .quantifier = .required },6164 .{ .kind = .id_result_type, .quantifier = .required },
5642 .{ .kind = .IdResult, .quantifier = .required },6165 .{ .kind = .id_result, .quantifier = .required },
5643 .{ .kind = .SamplerAddressingMode, .quantifier = .required },6166 .{ .kind = .sampler_addressing_mode, .quantifier = .required },
5644 .{ .kind = .LiteralInteger, .quantifier = .required },6167 .{ .kind = .literal_integer, .quantifier = .required },
5645 .{ .kind = .SamplerFilterMode, .quantifier = .required },6168 .{ .kind = .sampler_filter_mode, .quantifier = .required },
5646 },6169 },
5647 },6170 },
5648 .{6171 .{
5649 .name = "OpConstantNull",6172 .name = "OpConstantNull",
5650 .opcode = 46,6173 .opcode = 46,
5651 .operands = &[_]Operand{6174 .operands = &.{
5652 .{ .kind = .IdResultType, .quantifier = .required },6175 .{ .kind = .id_result_type, .quantifier = .required },
5653 .{ .kind = .IdResult, .quantifier = .required },6176 .{ .kind = .id_result, .quantifier = .required },
5654 },6177 },
5655 },6178 },
5656 .{6179 .{
5657 .name = "OpSpecConstantTrue",6180 .name = "OpSpecConstantTrue",
5658 .opcode = 48,6181 .opcode = 48,
5659 .operands = &[_]Operand{6182 .operands = &.{
5660 .{ .kind = .IdResultType, .quantifier = .required },6183 .{ .kind = .id_result_type, .quantifier = .required },
5661 .{ .kind = .IdResult, .quantifier = .required },6184 .{ .kind = .id_result, .quantifier = .required },
5662 },6185 },
5663 },6186 },
5664 .{6187 .{
5665 .name = "OpSpecConstantFalse",6188 .name = "OpSpecConstantFalse",
5666 .opcode = 49,6189 .opcode = 49,
5667 .operands = &[_]Operand{6190 .operands = &.{
5668 .{ .kind = .IdResultType, .quantifier = .required },6191 .{ .kind = .id_result_type, .quantifier = .required },
5669 .{ .kind = .IdResult, .quantifier = .required },6192 .{ .kind = .id_result, .quantifier = .required },
5670 },6193 },
5671 },6194 },
5672 .{6195 .{
5673 .name = "OpSpecConstant",6196 .name = "OpSpecConstant",
5674 .opcode = 50,6197 .opcode = 50,
5675 .operands = &[_]Operand{6198 .operands = &.{
5676 .{ .kind = .IdResultType, .quantifier = .required },6199 .{ .kind = .id_result_type, .quantifier = .required },
5677 .{ .kind = .IdResult, .quantifier = .required },6200 .{ .kind = .id_result, .quantifier = .required },
5678 .{ .kind = .LiteralContextDependentNumber, .quantifier = .required },6201 .{ .kind = .literal_context_dependent_number, .quantifier = .required },
5679 },6202 },
5680 },6203 },
5681 .{6204 .{
5682 .name = "OpSpecConstantComposite",6205 .name = "OpSpecConstantComposite",
5683 .opcode = 51,6206 .opcode = 51,
5684 .operands = &[_]Operand{6207 .operands = &.{
5685 .{ .kind = .IdResultType, .quantifier = .required },6208 .{ .kind = .id_result_type, .quantifier = .required },
5686 .{ .kind = .IdResult, .quantifier = .required },6209 .{ .kind = .id_result, .quantifier = .required },
5687 .{ .kind = .IdRef, .quantifier = .variadic },6210 .{ .kind = .id_ref, .quantifier = .variadic },
5688 },6211 },
5689 },6212 },
5690 .{6213 .{
5691 .name = "OpSpecConstantOp",6214 .name = "OpSpecConstantOp",
5692 .opcode = 52,6215 .opcode = 52,
5693 .operands = &[_]Operand{6216 .operands = &.{
5694 .{ .kind = .IdResultType, .quantifier = .required },6217 .{ .kind = .id_result_type, .quantifier = .required },
5695 .{ .kind = .IdResult, .quantifier = .required },6218 .{ .kind = .id_result, .quantifier = .required },
5696 .{ .kind = .LiteralSpecConstantOpInteger, .quantifier = .required },6219 .{ .kind = .literal_spec_constant_op_integer, .quantifier = .required },
5697 },6220 },
5698 },6221 },
5699 .{6222 .{
5700 .name = "OpFunction",6223 .name = "OpFunction",
5701 .opcode = 54,6224 .opcode = 54,
5702 .operands = &[_]Operand{6225 .operands = &.{
5703 .{ .kind = .IdResultType, .quantifier = .required },6226 .{ .kind = .id_result_type, .quantifier = .required },
5704 .{ .kind = .IdResult, .quantifier = .required },6227 .{ .kind = .id_result, .quantifier = .required },
5705 .{ .kind = .FunctionControl, .quantifier = .required },6228 .{ .kind = .function_control, .quantifier = .required },
5706 .{ .kind = .IdRef, .quantifier = .required },6229 .{ .kind = .id_ref, .quantifier = .required },
5707 },6230 },
5708 },6231 },
5709 .{6232 .{
5710 .name = "OpFunctionParameter",6233 .name = "OpFunctionParameter",
5711 .opcode = 55,6234 .opcode = 55,
5712 .operands = &[_]Operand{6235 .operands = &.{
5713 .{ .kind = .IdResultType, .quantifier = .required },6236 .{ .kind = .id_result_type, .quantifier = .required },
5714 .{ .kind = .IdResult, .quantifier = .required },6237 .{ .kind = .id_result, .quantifier = .required },
5715 },6238 },
5716 },6239 },
5717 .{6240 .{
5718 .name = "OpFunctionEnd",6241 .name = "OpFunctionEnd",
5719 .opcode = 56,6242 .opcode = 56,
5720 .operands = &[_]Operand{},6243 .operands = &.{},
5721 },6244 },
5722 .{6245 .{
5723 .name = "OpFunctionCall",6246 .name = "OpFunctionCall",
5724 .opcode = 57,6247 .opcode = 57,
5725 .operands = &[_]Operand{6248 .operands = &.{
5726 .{ .kind = .IdResultType, .quantifier = .required },6249 .{ .kind = .id_result_type, .quantifier = .required },
5727 .{ .kind = .IdResult, .quantifier = .required },6250 .{ .kind = .id_result, .quantifier = .required },
5728 .{ .kind = .IdRef, .quantifier = .required },6251 .{ .kind = .id_ref, .quantifier = .required },
5729 .{ .kind = .IdRef, .quantifier = .variadic },6252 .{ .kind = .id_ref, .quantifier = .variadic },
5730 },6253 },
5731 },6254 },
5732 .{6255 .{
5733 .name = "OpVariable",6256 .name = "OpVariable",
5734 .opcode = 59,6257 .opcode = 59,
5735 .operands = &[_]Operand{6258 .operands = &.{
5736 .{ .kind = .IdResultType, .quantifier = .required },6259 .{ .kind = .id_result_type, .quantifier = .required },
5737 .{ .kind = .IdResult, .quantifier = .required },6260 .{ .kind = .id_result, .quantifier = .required },
5738 .{ .kind = .StorageClass, .quantifier = .required },6261 .{ .kind = .storage_class, .quantifier = .required },
5739 .{ .kind = .IdRef, .quantifier = .optional },6262 .{ .kind = .id_ref, .quantifier = .optional },
5740 },6263 },
5741 },6264 },
5742 .{6265 .{
5743 .name = "OpImageTexelPointer",6266 .name = "OpImageTexelPointer",
5744 .opcode = 60,6267 .opcode = 60,
5745 .operands = &[_]Operand{6268 .operands = &.{
5746 .{ .kind = .IdResultType, .quantifier = .required },6269 .{ .kind = .id_result_type, .quantifier = .required },
5747 .{ .kind = .IdResult, .quantifier = .required },6270 .{ .kind = .id_result, .quantifier = .required },
5748 .{ .kind = .IdRef, .quantifier = .required },6271 .{ .kind = .id_ref, .quantifier = .required },
5749 .{ .kind = .IdRef, .quantifier = .required },6272 .{ .kind = .id_ref, .quantifier = .required },
5750 .{ .kind = .IdRef, .quantifier = .required },6273 .{ .kind = .id_ref, .quantifier = .required },
5751 },6274 },
5752 },6275 },
5753 .{6276 .{
5754 .name = "OpLoad",6277 .name = "OpLoad",
5755 .opcode = 61,6278 .opcode = 61,
5756 .operands = &[_]Operand{6279 .operands = &.{
5757 .{ .kind = .IdResultType, .quantifier = .required },6280 .{ .kind = .id_result_type, .quantifier = .required },
5758 .{ .kind = .IdResult, .quantifier = .required },6281 .{ .kind = .id_result, .quantifier = .required },
5759 .{ .kind = .IdRef, .quantifier = .required },6282 .{ .kind = .id_ref, .quantifier = .required },
5760 .{ .kind = .MemoryAccess, .quantifier = .optional },6283 .{ .kind = .memory_access, .quantifier = .optional },
5761 },6284 },
5762 },6285 },
5763 .{6286 .{
5764 .name = "OpStore",6287 .name = "OpStore",
5765 .opcode = 62,6288 .opcode = 62,
5766 .operands = &[_]Operand{6289 .operands = &.{
5767 .{ .kind = .IdRef, .quantifier = .required },6290 .{ .kind = .id_ref, .quantifier = .required },
5768 .{ .kind = .IdRef, .quantifier = .required },6291 .{ .kind = .id_ref, .quantifier = .required },
5769 .{ .kind = .MemoryAccess, .quantifier = .optional },6292 .{ .kind = .memory_access, .quantifier = .optional },
5770 },6293 },
5771 },6294 },
5772 .{6295 .{
5773 .name = "OpCopyMemory",6296 .name = "OpCopyMemory",
5774 .opcode = 63,6297 .opcode = 63,
5775 .operands = &[_]Operand{6298 .operands = &.{
5776 .{ .kind = .IdRef, .quantifier = .required },6299 .{ .kind = .id_ref, .quantifier = .required },
5777 .{ .kind = .IdRef, .quantifier = .required },6300 .{ .kind = .id_ref, .quantifier = .required },
5778 .{ .kind = .MemoryAccess, .quantifier = .optional },6301 .{ .kind = .memory_access, .quantifier = .optional },
5779 .{ .kind = .MemoryAccess, .quantifier = .optional },6302 .{ .kind = .memory_access, .quantifier = .optional },
5780 },6303 },
5781 },6304 },
5782 .{6305 .{
5783 .name = "OpCopyMemorySized",6306 .name = "OpCopyMemorySized",
5784 .opcode = 64,6307 .opcode = 64,
5785 .operands = &[_]Operand{6308 .operands = &.{
5786 .{ .kind = .IdRef, .quantifier = .required },6309 .{ .kind = .id_ref, .quantifier = .required },
5787 .{ .kind = .IdRef, .quantifier = .required },6310 .{ .kind = .id_ref, .quantifier = .required },
5788 .{ .kind = .IdRef, .quantifier = .required },6311 .{ .kind = .id_ref, .quantifier = .required },
5789 .{ .kind = .MemoryAccess, .quantifier = .optional },6312 .{ .kind = .memory_access, .quantifier = .optional },
5790 .{ .kind = .MemoryAccess, .quantifier = .optional },6313 .{ .kind = .memory_access, .quantifier = .optional },
5791 },6314 },
5792 },6315 },
5793 .{6316 .{
5794 .name = "OpAccessChain",6317 .name = "OpAccessChain",
5795 .opcode = 65,6318 .opcode = 65,
5796 .operands = &[_]Operand{6319 .operands = &.{
5797 .{ .kind = .IdResultType, .quantifier = .required },6320 .{ .kind = .id_result_type, .quantifier = .required },
5798 .{ .kind = .IdResult, .quantifier = .required },6321 .{ .kind = .id_result, .quantifier = .required },
5799 .{ .kind = .IdRef, .quantifier = .required },6322 .{ .kind = .id_ref, .quantifier = .required },
5800 .{ .kind = .IdRef, .quantifier = .variadic },6323 .{ .kind = .id_ref, .quantifier = .variadic },
5801 },6324 },
5802 },6325 },
5803 .{6326 .{
5804 .name = "OpInBoundsAccessChain",6327 .name = "OpInBoundsAccessChain",
5805 .opcode = 66,6328 .opcode = 66,
5806 .operands = &[_]Operand{6329 .operands = &.{
5807 .{ .kind = .IdResultType, .quantifier = .required },6330 .{ .kind = .id_result_type, .quantifier = .required },
5808 .{ .kind = .IdResult, .quantifier = .required },6331 .{ .kind = .id_result, .quantifier = .required },
5809 .{ .kind = .IdRef, .quantifier = .required },6332 .{ .kind = .id_ref, .quantifier = .required },
5810 .{ .kind = .IdRef, .quantifier = .variadic },6333 .{ .kind = .id_ref, .quantifier = .variadic },
5811 },6334 },
5812 },6335 },
5813 .{6336 .{
5814 .name = "OpPtrAccessChain",6337 .name = "OpPtrAccessChain",
5815 .opcode = 67,6338 .opcode = 67,
5816 .operands = &[_]Operand{6339 .operands = &.{
5817 .{ .kind = .IdResultType, .quantifier = .required },6340 .{ .kind = .id_result_type, .quantifier = .required },
5818 .{ .kind = .IdResult, .quantifier = .required },6341 .{ .kind = .id_result, .quantifier = .required },
5819 .{ .kind = .IdRef, .quantifier = .required },6342 .{ .kind = .id_ref, .quantifier = .required },
5820 .{ .kind = .IdRef, .quantifier = .required },6343 .{ .kind = .id_ref, .quantifier = .required },
5821 .{ .kind = .IdRef, .quantifier = .variadic },6344 .{ .kind = .id_ref, .quantifier = .variadic },
5822 },6345 },
5823 },6346 },
5824 .{6347 .{
5825 .name = "OpArrayLength",6348 .name = "OpArrayLength",
5826 .opcode = 68,6349 .opcode = 68,
5827 .operands = &[_]Operand{6350 .operands = &.{
5828 .{ .kind = .IdResultType, .quantifier = .required },6351 .{ .kind = .id_result_type, .quantifier = .required },
5829 .{ .kind = .IdResult, .quantifier = .required },6352 .{ .kind = .id_result, .quantifier = .required },
5830 .{ .kind = .IdRef, .quantifier = .required },6353 .{ .kind = .id_ref, .quantifier = .required },
5831 .{ .kind = .LiteralInteger, .quantifier = .required },6354 .{ .kind = .literal_integer, .quantifier = .required },
5832 },6355 },
5833 },6356 },
5834 .{6357 .{
5835 .name = "OpGenericPtrMemSemantics",6358 .name = "OpGenericPtrMemSemantics",
5836 .opcode = 69,6359 .opcode = 69,
5837 .operands = &[_]Operand{6360 .operands = &.{
5838 .{ .kind = .IdResultType, .quantifier = .required },6361 .{ .kind = .id_result_type, .quantifier = .required },
5839 .{ .kind = .IdResult, .quantifier = .required },6362 .{ .kind = .id_result, .quantifier = .required },
5840 .{ .kind = .IdRef, .quantifier = .required },6363 .{ .kind = .id_ref, .quantifier = .required },
5841 },6364 },
5842 },6365 },
5843 .{6366 .{
5844 .name = "OpInBoundsPtrAccessChain",6367 .name = "OpInBoundsPtrAccessChain",
5845 .opcode = 70,6368 .opcode = 70,
5846 .operands = &[_]Operand{6369 .operands = &.{
5847 .{ .kind = .IdResultType, .quantifier = .required },6370 .{ .kind = .id_result_type, .quantifier = .required },
5848 .{ .kind = .IdResult, .quantifier = .required },6371 .{ .kind = .id_result, .quantifier = .required },
5849 .{ .kind = .IdRef, .quantifier = .required },6372 .{ .kind = .id_ref, .quantifier = .required },
5850 .{ .kind = .IdRef, .quantifier = .required },6373 .{ .kind = .id_ref, .quantifier = .required },
5851 .{ .kind = .IdRef, .quantifier = .variadic },6374 .{ .kind = .id_ref, .quantifier = .variadic },
5852 },6375 },
5853 },6376 },
5854 .{6377 .{
5855 .name = "OpDecorate",6378 .name = "OpDecorate",
5856 .opcode = 71,6379 .opcode = 71,
5857 .operands = &[_]Operand{6380 .operands = &.{
5858 .{ .kind = .IdRef, .quantifier = .required },6381 .{ .kind = .id_ref, .quantifier = .required },
5859 .{ .kind = .Decoration, .quantifier = .required },6382 .{ .kind = .decoration, .quantifier = .required },
5860 },6383 },
5861 },6384 },
5862 .{6385 .{
5863 .name = "OpMemberDecorate",6386 .name = "OpMemberDecorate",
5864 .opcode = 72,6387 .opcode = 72,
5865 .operands = &[_]Operand{6388 .operands = &.{
5866 .{ .kind = .IdRef, .quantifier = .required },6389 .{ .kind = .id_ref, .quantifier = .required },
5867 .{ .kind = .LiteralInteger, .quantifier = .required },6390 .{ .kind = .literal_integer, .quantifier = .required },
5868 .{ .kind = .Decoration, .quantifier = .required },6391 .{ .kind = .decoration, .quantifier = .required },
5869 },6392 },
5870 },6393 },
5871 .{6394 .{
5872 .name = "OpDecorationGroup",6395 .name = "OpDecorationGroup",
5873 .opcode = 73,6396 .opcode = 73,
5874 .operands = &[_]Operand{6397 .operands = &.{
5875 .{ .kind = .IdResult, .quantifier = .required },6398 .{ .kind = .id_result, .quantifier = .required },
5876 },6399 },
5877 },6400 },
5878 .{6401 .{
5879 .name = "OpGroupDecorate",6402 .name = "OpGroupDecorate",
5880 .opcode = 74,6403 .opcode = 74,
5881 .operands = &[_]Operand{6404 .operands = &.{
5882 .{ .kind = .IdRef, .quantifier = .required },6405 .{ .kind = .id_ref, .quantifier = .required },
5883 .{ .kind = .IdRef, .quantifier = .variadic },6406 .{ .kind = .id_ref, .quantifier = .variadic },
5884 },6407 },
5885 },6408 },
5886 .{6409 .{
5887 .name = "OpGroupMemberDecorate",6410 .name = "OpGroupMemberDecorate",
5888 .opcode = 75,6411 .opcode = 75,
5889 .operands = &[_]Operand{6412 .operands = &.{
5890 .{ .kind = .IdRef, .quantifier = .required },6413 .{ .kind = .id_ref, .quantifier = .required },
5891 .{ .kind = .PairIdRefLiteralInteger, .quantifier = .variadic },6414 .{ .kind = .pair_id_ref_literal_integer, .quantifier = .variadic },
5892 },6415 },
5893 },6416 },
5894 .{6417 .{
5895 .name = "OpVectorExtractDynamic",6418 .name = "OpVectorExtractDynamic",
5896 .opcode = 77,6419 .opcode = 77,
5897 .operands = &[_]Operand{6420 .operands = &.{
5898 .{ .kind = .IdResultType, .quantifier = .required },6421 .{ .kind = .id_result_type, .quantifier = .required },
5899 .{ .kind = .IdResult, .quantifier = .required },6422 .{ .kind = .id_result, .quantifier = .required },
5900 .{ .kind = .IdRef, .quantifier = .required },6423 .{ .kind = .id_ref, .quantifier = .required },
5901 .{ .kind = .IdRef, .quantifier = .required },6424 .{ .kind = .id_ref, .quantifier = .required },
5902 },6425 },
5903 },6426 },
5904 .{6427 .{
5905 .name = "OpVectorInsertDynamic",6428 .name = "OpVectorInsertDynamic",
5906 .opcode = 78,6429 .opcode = 78,
5907 .operands = &[_]Operand{6430 .operands = &.{
5908 .{ .kind = .IdResultType, .quantifier = .required },6431 .{ .kind = .id_result_type, .quantifier = .required },
5909 .{ .kind = .IdResult, .quantifier = .required },6432 .{ .kind = .id_result, .quantifier = .required },
5910 .{ .kind = .IdRef, .quantifier = .required },6433 .{ .kind = .id_ref, .quantifier = .required },
5911 .{ .kind = .IdRef, .quantifier = .required },6434 .{ .kind = .id_ref, .quantifier = .required },
5912 .{ .kind = .IdRef, .quantifier = .required },6435 .{ .kind = .id_ref, .quantifier = .required },
5913 },6436 },
5914 },6437 },
5915 .{6438 .{
5916 .name = "OpVectorShuffle",6439 .name = "OpVectorShuffle",
5917 .opcode = 79,6440 .opcode = 79,
5918 .operands = &[_]Operand{6441 .operands = &.{
5919 .{ .kind = .IdResultType, .quantifier = .required },6442 .{ .kind = .id_result_type, .quantifier = .required },
5920 .{ .kind = .IdResult, .quantifier = .required },6443 .{ .kind = .id_result, .quantifier = .required },
5921 .{ .kind = .IdRef, .quantifier = .required },6444 .{ .kind = .id_ref, .quantifier = .required },
5922 .{ .kind = .IdRef, .quantifier = .required },6445 .{ .kind = .id_ref, .quantifier = .required },
5923 .{ .kind = .LiteralInteger, .quantifier = .variadic },6446 .{ .kind = .literal_integer, .quantifier = .variadic },
5924 },6447 },
5925 },6448 },
5926 .{6449 .{
5927 .name = "OpCompositeConstruct",6450 .name = "OpCompositeConstruct",
5928 .opcode = 80,6451 .opcode = 80,
5929 .operands = &[_]Operand{6452 .operands = &.{
5930 .{ .kind = .IdResultType, .quantifier = .required },6453 .{ .kind = .id_result_type, .quantifier = .required },
5931 .{ .kind = .IdResult, .quantifier = .required },6454 .{ .kind = .id_result, .quantifier = .required },
5932 .{ .kind = .IdRef, .quantifier = .variadic },6455 .{ .kind = .id_ref, .quantifier = .variadic },
5933 },6456 },
5934 },6457 },
5935 .{6458 .{
5936 .name = "OpCompositeExtract",6459 .name = "OpCompositeExtract",
5937 .opcode = 81,6460 .opcode = 81,
5938 .operands = &[_]Operand{6461 .operands = &.{
5939 .{ .kind = .IdResultType, .quantifier = .required },6462 .{ .kind = .id_result_type, .quantifier = .required },
5940 .{ .kind = .IdResult, .quantifier = .required },6463 .{ .kind = .id_result, .quantifier = .required },
5941 .{ .kind = .IdRef, .quantifier = .required },6464 .{ .kind = .id_ref, .quantifier = .required },
5942 .{ .kind = .LiteralInteger, .quantifier = .variadic },6465 .{ .kind = .literal_integer, .quantifier = .variadic },
5943 },6466 },
5944 },6467 },
5945 .{6468 .{
5946 .name = "OpCompositeInsert",6469 .name = "OpCompositeInsert",
5947 .opcode = 82,6470 .opcode = 82,
5948 .operands = &[_]Operand{6471 .operands = &.{
5949 .{ .kind = .IdResultType, .quantifier = .required },6472 .{ .kind = .id_result_type, .quantifier = .required },
5950 .{ .kind = .IdResult, .quantifier = .required },6473 .{ .kind = .id_result, .quantifier = .required },
5951 .{ .kind = .IdRef, .quantifier = .required },6474 .{ .kind = .id_ref, .quantifier = .required },
5952 .{ .kind = .IdRef, .quantifier = .required },6475 .{ .kind = .id_ref, .quantifier = .required },
5953 .{ .kind = .LiteralInteger, .quantifier = .variadic },6476 .{ .kind = .literal_integer, .quantifier = .variadic },
5954 },6477 },
5955 },6478 },
5956 .{6479 .{
5957 .name = "OpCopyObject",6480 .name = "OpCopyObject",
5958 .opcode = 83,6481 .opcode = 83,
5959 .operands = &[_]Operand{6482 .operands = &.{
5960 .{ .kind = .IdResultType, .quantifier = .required },6483 .{ .kind = .id_result_type, .quantifier = .required },
5961 .{ .kind = .IdResult, .quantifier = .required },6484 .{ .kind = .id_result, .quantifier = .required },
5962 .{ .kind = .IdRef, .quantifier = .required },6485 .{ .kind = .id_ref, .quantifier = .required },
5963 },6486 },
5964 },6487 },
5965 .{6488 .{
5966 .name = "OpTranspose",6489 .name = "OpTranspose",
5967 .opcode = 84,6490 .opcode = 84,
5968 .operands = &[_]Operand{6491 .operands = &.{
5969 .{ .kind = .IdResultType, .quantifier = .required },6492 .{ .kind = .id_result_type, .quantifier = .required },
5970 .{ .kind = .IdResult, .quantifier = .required },6493 .{ .kind = .id_result, .quantifier = .required },
5971 .{ .kind = .IdRef, .quantifier = .required },6494 .{ .kind = .id_ref, .quantifier = .required },
5972 },6495 },
5973 },6496 },
5974 .{6497 .{
5975 .name = "OpSampledImage",6498 .name = "OpSampledImage",
5976 .opcode = 86,6499 .opcode = 86,
5977 .operands = &[_]Operand{6500 .operands = &.{
5978 .{ .kind = .IdResultType, .quantifier = .required },6501 .{ .kind = .id_result_type, .quantifier = .required },
5979 .{ .kind = .IdResult, .quantifier = .required },6502 .{ .kind = .id_result, .quantifier = .required },
5980 .{ .kind = .IdRef, .quantifier = .required },6503 .{ .kind = .id_ref, .quantifier = .required },
5981 .{ .kind = .IdRef, .quantifier = .required },6504 .{ .kind = .id_ref, .quantifier = .required },
5982 },6505 },
5983 },6506 },
5984 .{6507 .{
5985 .name = "OpImageSampleImplicitLod",6508 .name = "OpImageSampleImplicitLod",
5986 .opcode = 87,6509 .opcode = 87,
5987 .operands = &[_]Operand{6510 .operands = &.{
5988 .{ .kind = .IdResultType, .quantifier = .required },6511 .{ .kind = .id_result_type, .quantifier = .required },
5989 .{ .kind = .IdResult, .quantifier = .required },6512 .{ .kind = .id_result, .quantifier = .required },
5990 .{ .kind = .IdRef, .quantifier = .required },6513 .{ .kind = .id_ref, .quantifier = .required },
5991 .{ .kind = .IdRef, .quantifier = .required },6514 .{ .kind = .id_ref, .quantifier = .required },
5992 .{ .kind = .ImageOperands, .quantifier = .optional },6515 .{ .kind = .image_operands, .quantifier = .optional },
5993 },6516 },
5994 },6517 },
5995 .{6518 .{
5996 .name = "OpImageSampleExplicitLod",6519 .name = "OpImageSampleExplicitLod",
5997 .opcode = 88,6520 .opcode = 88,
5998 .operands = &[_]Operand{6521 .operands = &.{
5999 .{ .kind = .IdResultType, .quantifier = .required },6522 .{ .kind = .id_result_type, .quantifier = .required },
6000 .{ .kind = .IdResult, .quantifier = .required },6523 .{ .kind = .id_result, .quantifier = .required },
6001 .{ .kind = .IdRef, .quantifier = .required },6524 .{ .kind = .id_ref, .quantifier = .required },
6002 .{ .kind = .IdRef, .quantifier = .required },6525 .{ .kind = .id_ref, .quantifier = .required },
6003 .{ .kind = .ImageOperands, .quantifier = .required },6526 .{ .kind = .image_operands, .quantifier = .required },
6004 },6527 },
6005 },6528 },
6006 .{6529 .{
6007 .name = "OpImageSampleDrefImplicitLod",6530 .name = "OpImageSampleDrefImplicitLod",
6008 .opcode = 89,6531 .opcode = 89,
6009 .operands = &[_]Operand{6532 .operands = &.{
6010 .{ .kind = .IdResultType, .quantifier = .required },6533 .{ .kind = .id_result_type, .quantifier = .required },
6011 .{ .kind = .IdResult, .quantifier = .required },6534 .{ .kind = .id_result, .quantifier = .required },
6012 .{ .kind = .IdRef, .quantifier = .required },6535 .{ .kind = .id_ref, .quantifier = .required },
6013 .{ .kind = .IdRef, .quantifier = .required },6536 .{ .kind = .id_ref, .quantifier = .required },
6014 .{ .kind = .IdRef, .quantifier = .required },6537 .{ .kind = .id_ref, .quantifier = .required },
6015 .{ .kind = .ImageOperands, .quantifier = .optional },6538 .{ .kind = .image_operands, .quantifier = .optional },
6016 },6539 },
6017 },6540 },
6018 .{6541 .{
6019 .name = "OpImageSampleDrefExplicitLod",6542 .name = "OpImageSampleDrefExplicitLod",
6020 .opcode = 90,6543 .opcode = 90,
6021 .operands = &[_]Operand{6544 .operands = &.{
6022 .{ .kind = .IdResultType, .quantifier = .required },6545 .{ .kind = .id_result_type, .quantifier = .required },
6023 .{ .kind = .IdResult, .quantifier = .required },6546 .{ .kind = .id_result, .quantifier = .required },
6024 .{ .kind = .IdRef, .quantifier = .required },6547 .{ .kind = .id_ref, .quantifier = .required },
6025 .{ .kind = .IdRef, .quantifier = .required },6548 .{ .kind = .id_ref, .quantifier = .required },
6026 .{ .kind = .IdRef, .quantifier = .required },6549 .{ .kind = .id_ref, .quantifier = .required },
6027 .{ .kind = .ImageOperands, .quantifier = .required },6550 .{ .kind = .image_operands, .quantifier = .required },
6028 },6551 },
6029 },6552 },
6030 .{6553 .{
6031 .name = "OpImageSampleProjImplicitLod",6554 .name = "OpImageSampleProjImplicitLod",
6032 .opcode = 91,6555 .opcode = 91,
6033 .operands = &[_]Operand{6556 .operands = &.{
6034 .{ .kind = .IdResultType, .quantifier = .required },6557 .{ .kind = .id_result_type, .quantifier = .required },
6035 .{ .kind = .IdResult, .quantifier = .required },6558 .{ .kind = .id_result, .quantifier = .required },
6036 .{ .kind = .IdRef, .quantifier = .required },6559 .{ .kind = .id_ref, .quantifier = .required },
6037 .{ .kind = .IdRef, .quantifier = .required },6560 .{ .kind = .id_ref, .quantifier = .required },
6038 .{ .kind = .ImageOperands, .quantifier = .optional },6561 .{ .kind = .image_operands, .quantifier = .optional },
6039 },6562 },
6040 },6563 },
6041 .{6564 .{
6042 .name = "OpImageSampleProjExplicitLod",6565 .name = "OpImageSampleProjExplicitLod",
6043 .opcode = 92,6566 .opcode = 92,
6044 .operands = &[_]Operand{6567 .operands = &.{
6045 .{ .kind = .IdResultType, .quantifier = .required },6568 .{ .kind = .id_result_type, .quantifier = .required },
6046 .{ .kind = .IdResult, .quantifier = .required },6569 .{ .kind = .id_result, .quantifier = .required },
6047 .{ .kind = .IdRef, .quantifier = .required },6570 .{ .kind = .id_ref, .quantifier = .required },
6048 .{ .kind = .IdRef, .quantifier = .required },6571 .{ .kind = .id_ref, .quantifier = .required },
6049 .{ .kind = .ImageOperands, .quantifier = .required },6572 .{ .kind = .image_operands, .quantifier = .required },
6050 },6573 },
6051 },6574 },
6052 .{6575 .{
6053 .name = "OpImageSampleProjDrefImplicitLod",6576 .name = "OpImageSampleProjDrefImplicitLod",
6054 .opcode = 93,6577 .opcode = 93,
6055 .operands = &[_]Operand{6578 .operands = &.{
6056 .{ .kind = .IdResultType, .quantifier = .required },6579 .{ .kind = .id_result_type, .quantifier = .required },
6057 .{ .kind = .IdResult, .quantifier = .required },6580 .{ .kind = .id_result, .quantifier = .required },
6058 .{ .kind = .IdRef, .quantifier = .required },6581 .{ .kind = .id_ref, .quantifier = .required },
6059 .{ .kind = .IdRef, .quantifier = .required },6582 .{ .kind = .id_ref, .quantifier = .required },
6060 .{ .kind = .IdRef, .quantifier = .required },6583 .{ .kind = .id_ref, .quantifier = .required },
6061 .{ .kind = .ImageOperands, .quantifier = .optional },6584 .{ .kind = .image_operands, .quantifier = .optional },
6062 },6585 },
6063 },6586 },
6064 .{6587 .{
6065 .name = "OpImageSampleProjDrefExplicitLod",6588 .name = "OpImageSampleProjDrefExplicitLod",
6066 .opcode = 94,6589 .opcode = 94,
6067 .operands = &[_]Operand{6590 .operands = &.{
6068 .{ .kind = .IdResultType, .quantifier = .required },6591 .{ .kind = .id_result_type, .quantifier = .required },
6069 .{ .kind = .IdResult, .quantifier = .required },6592 .{ .kind = .id_result, .quantifier = .required },
6070 .{ .kind = .IdRef, .quantifier = .required },6593 .{ .kind = .id_ref, .quantifier = .required },
6071 .{ .kind = .IdRef, .quantifier = .required },6594 .{ .kind = .id_ref, .quantifier = .required },
6072 .{ .kind = .IdRef, .quantifier = .required },6595 .{ .kind = .id_ref, .quantifier = .required },
6073 .{ .kind = .ImageOperands, .quantifier = .required },6596 .{ .kind = .image_operands, .quantifier = .required },
6074 },6597 },
6075 },6598 },
6076 .{6599 .{
6077 .name = "OpImageFetch",6600 .name = "OpImageFetch",
6078 .opcode = 95,6601 .opcode = 95,
6079 .operands = &[_]Operand{6602 .operands = &.{
6080 .{ .kind = .IdResultType, .quantifier = .required },6603 .{ .kind = .id_result_type, .quantifier = .required },
6081 .{ .kind = .IdResult, .quantifier = .required },6604 .{ .kind = .id_result, .quantifier = .required },
6082 .{ .kind = .IdRef, .quantifier = .required },6605 .{ .kind = .id_ref, .quantifier = .required },
6083 .{ .kind = .IdRef, .quantifier = .required },6606 .{ .kind = .id_ref, .quantifier = .required },
6084 .{ .kind = .ImageOperands, .quantifier = .optional },6607 .{ .kind = .image_operands, .quantifier = .optional },
6085 },6608 },
6086 },6609 },
6087 .{6610 .{
6088 .name = "OpImageGather",6611 .name = "OpImageGather",
6089 .opcode = 96,6612 .opcode = 96,
6090 .operands = &[_]Operand{6613 .operands = &.{
6091 .{ .kind = .IdResultType, .quantifier = .required },6614 .{ .kind = .id_result_type, .quantifier = .required },
6092 .{ .kind = .IdResult, .quantifier = .required },6615 .{ .kind = .id_result, .quantifier = .required },
6093 .{ .kind = .IdRef, .quantifier = .required },6616 .{ .kind = .id_ref, .quantifier = .required },
6094 .{ .kind = .IdRef, .quantifier = .required },6617 .{ .kind = .id_ref, .quantifier = .required },
6095 .{ .kind = .IdRef, .quantifier = .required },6618 .{ .kind = .id_ref, .quantifier = .required },
6096 .{ .kind = .ImageOperands, .quantifier = .optional },6619 .{ .kind = .image_operands, .quantifier = .optional },
6097 },6620 },
6098 },6621 },
6099 .{6622 .{
6100 .name = "OpImageDrefGather",6623 .name = "OpImageDrefGather",
6101 .opcode = 97,6624 .opcode = 97,
6102 .operands = &[_]Operand{6625 .operands = &.{
6103 .{ .kind = .IdResultType, .quantifier = .required },6626 .{ .kind = .id_result_type, .quantifier = .required },
6104 .{ .kind = .IdResult, .quantifier = .required },6627 .{ .kind = .id_result, .quantifier = .required },
6105 .{ .kind = .IdRef, .quantifier = .required },6628 .{ .kind = .id_ref, .quantifier = .required },
6106 .{ .kind = .IdRef, .quantifier = .required },6629 .{ .kind = .id_ref, .quantifier = .required },
6107 .{ .kind = .IdRef, .quantifier = .required },6630 .{ .kind = .id_ref, .quantifier = .required },
6108 .{ .kind = .ImageOperands, .quantifier = .optional },6631 .{ .kind = .image_operands, .quantifier = .optional },
6109 },6632 },
6110 },6633 },
6111 .{6634 .{
6112 .name = "OpImageRead",6635 .name = "OpImageRead",
6113 .opcode = 98,6636 .opcode = 98,
6114 .operands = &[_]Operand{6637 .operands = &.{
6115 .{ .kind = .IdResultType, .quantifier = .required },6638 .{ .kind = .id_result_type, .quantifier = .required },
6116 .{ .kind = .IdResult, .quantifier = .required },6639 .{ .kind = .id_result, .quantifier = .required },
6117 .{ .kind = .IdRef, .quantifier = .required },6640 .{ .kind = .id_ref, .quantifier = .required },
6118 .{ .kind = .IdRef, .quantifier = .required },6641 .{ .kind = .id_ref, .quantifier = .required },
6119 .{ .kind = .ImageOperands, .quantifier = .optional },6642 .{ .kind = .image_operands, .quantifier = .optional },
6120 },6643 },
6121 },6644 },
6122 .{6645 .{
6123 .name = "OpImageWrite",6646 .name = "OpImageWrite",
6124 .opcode = 99,6647 .opcode = 99,
6125 .operands = &[_]Operand{6648 .operands = &.{
6126 .{ .kind = .IdRef, .quantifier = .required },6649 .{ .kind = .id_ref, .quantifier = .required },
6127 .{ .kind = .IdRef, .quantifier = .required },6650 .{ .kind = .id_ref, .quantifier = .required },
6128 .{ .kind = .IdRef, .quantifier = .required },6651 .{ .kind = .id_ref, .quantifier = .required },
6129 .{ .kind = .ImageOperands, .quantifier = .optional },6652 .{ .kind = .image_operands, .quantifier = .optional },
6130 },6653 },
6131 },6654 },
6132 .{6655 .{
6133 .name = "OpImage",6656 .name = "OpImage",
6134 .opcode = 100,6657 .opcode = 100,
6135 .operands = &[_]Operand{6658 .operands = &.{
6136 .{ .kind = .IdResultType, .quantifier = .required },6659 .{ .kind = .id_result_type, .quantifier = .required },
6137 .{ .kind = .IdResult, .quantifier = .required },6660 .{ .kind = .id_result, .quantifier = .required },
6138 .{ .kind = .IdRef, .quantifier = .required },6661 .{ .kind = .id_ref, .quantifier = .required },
6139 },6662 },
6140 },6663 },
6141 .{6664 .{
6142 .name = "OpImageQueryFormat",6665 .name = "OpImageQueryFormat",
6143 .opcode = 101,6666 .opcode = 101,
6144 .operands = &[_]Operand{6667 .operands = &.{
6145 .{ .kind = .IdResultType, .quantifier = .required },6668 .{ .kind = .id_result_type, .quantifier = .required },
6146 .{ .kind = .IdResult, .quantifier = .required },6669 .{ .kind = .id_result, .quantifier = .required },
6147 .{ .kind = .IdRef, .quantifier = .required },6670 .{ .kind = .id_ref, .quantifier = .required },
6148 },6671 },
6149 },6672 },
6150 .{6673 .{
6151 .name = "OpImageQueryOrder",6674 .name = "OpImageQueryOrder",
6152 .opcode = 102,6675 .opcode = 102,
6153 .operands = &[_]Operand{6676 .operands = &.{
6154 .{ .kind = .IdResultType, .quantifier = .required },6677 .{ .kind = .id_result_type, .quantifier = .required },
6155 .{ .kind = .IdResult, .quantifier = .required },6678 .{ .kind = .id_result, .quantifier = .required },
6156 .{ .kind = .IdRef, .quantifier = .required },6679 .{ .kind = .id_ref, .quantifier = .required },
6157 },6680 },
6158 },6681 },
6159 .{6682 .{
6160 .name = "OpImageQuerySizeLod",6683 .name = "OpImageQuerySizeLod",
6161 .opcode = 103,6684 .opcode = 103,
6162 .operands = &[_]Operand{6685 .operands = &.{
6163 .{ .kind = .IdResultType, .quantifier = .required },6686 .{ .kind = .id_result_type, .quantifier = .required },
6164 .{ .kind = .IdResult, .quantifier = .required },6687 .{ .kind = .id_result, .quantifier = .required },
6165 .{ .kind = .IdRef, .quantifier = .required },6688 .{ .kind = .id_ref, .quantifier = .required },
6166 .{ .kind = .IdRef, .quantifier = .required },6689 .{ .kind = .id_ref, .quantifier = .required },
6167 },6690 },
6168 },6691 },
6169 .{6692 .{
6170 .name = "OpImageQuerySize",6693 .name = "OpImageQuerySize",
6171 .opcode = 104,6694 .opcode = 104,
6172 .operands = &[_]Operand{6695 .operands = &.{
6173 .{ .kind = .IdResultType, .quantifier = .required },6696 .{ .kind = .id_result_type, .quantifier = .required },
6174 .{ .kind = .IdResult, .quantifier = .required },6697 .{ .kind = .id_result, .quantifier = .required },
6175 .{ .kind = .IdRef, .quantifier = .required },6698 .{ .kind = .id_ref, .quantifier = .required },
6176 },6699 },
6177 },6700 },
6178 .{6701 .{
6179 .name = "OpImageQueryLod",6702 .name = "OpImageQueryLod",
6180 .opcode = 105,6703 .opcode = 105,
6181 .operands = &[_]Operand{6704 .operands = &.{
6182 .{ .kind = .IdResultType, .quantifier = .required },6705 .{ .kind = .id_result_type, .quantifier = .required },
6183 .{ .kind = .IdResult, .quantifier = .required },6706 .{ .kind = .id_result, .quantifier = .required },
6184 .{ .kind = .IdRef, .quantifier = .required },6707 .{ .kind = .id_ref, .quantifier = .required },
6185 .{ .kind = .IdRef, .quantifier = .required },6708 .{ .kind = .id_ref, .quantifier = .required },
6186 },6709 },
6187 },6710 },
6188 .{6711 .{
6189 .name = "OpImageQueryLevels",6712 .name = "OpImageQueryLevels",
6190 .opcode = 106,6713 .opcode = 106,
6191 .operands = &[_]Operand{6714 .operands = &.{
6192 .{ .kind = .IdResultType, .quantifier = .required },6715 .{ .kind = .id_result_type, .quantifier = .required },
6193 .{ .kind = .IdResult, .quantifier = .required },6716 .{ .kind = .id_result, .quantifier = .required },
6194 .{ .kind = .IdRef, .quantifier = .required },6717 .{ .kind = .id_ref, .quantifier = .required },
6195 },6718 },
6196 },6719 },
6197 .{6720 .{
6198 .name = "OpImageQuerySamples",6721 .name = "OpImageQuerySamples",
6199 .opcode = 107,6722 .opcode = 107,
6200 .operands = &[_]Operand{6723 .operands = &.{
6201 .{ .kind = .IdResultType, .quantifier = .required },6724 .{ .kind = .id_result_type, .quantifier = .required },
6202 .{ .kind = .IdResult, .quantifier = .required },6725 .{ .kind = .id_result, .quantifier = .required },
6203 .{ .kind = .IdRef, .quantifier = .required },6726 .{ .kind = .id_ref, .quantifier = .required },
6204 },6727 },
6205 },6728 },
6206 .{6729 .{
6207 .name = "OpConvertFToU",6730 .name = "OpConvertFToU",
6208 .opcode = 109,6731 .opcode = 109,
6209 .operands = &[_]Operand{6732 .operands = &.{
6210 .{ .kind = .IdResultType, .quantifier = .required },6733 .{ .kind = .id_result_type, .quantifier = .required },
6211 .{ .kind = .IdResult, .quantifier = .required },6734 .{ .kind = .id_result, .quantifier = .required },
6212 .{ .kind = .IdRef, .quantifier = .required },6735 .{ .kind = .id_ref, .quantifier = .required },
6213 },6736 },
6214 },6737 },
6215 .{6738 .{
6216 .name = "OpConvertFToS",6739 .name = "OpConvertFToS",
6217 .opcode = 110,6740 .opcode = 110,
6218 .operands = &[_]Operand{6741 .operands = &.{
6219 .{ .kind = .IdResultType, .quantifier = .required },6742 .{ .kind = .id_result_type, .quantifier = .required },
6220 .{ .kind = .IdResult, .quantifier = .required },6743 .{ .kind = .id_result, .quantifier = .required },
6221 .{ .kind = .IdRef, .quantifier = .required },6744 .{ .kind = .id_ref, .quantifier = .required },
6222 },6745 },
6223 },6746 },
6224 .{6747 .{
6225 .name = "OpConvertSToF",6748 .name = "OpConvertSToF",
6226 .opcode = 111,6749 .opcode = 111,
6227 .operands = &[_]Operand{6750 .operands = &.{
6228 .{ .kind = .IdResultType, .quantifier = .required },6751 .{ .kind = .id_result_type, .quantifier = .required },
6229 .{ .kind = .IdResult, .quantifier = .required },6752 .{ .kind = .id_result, .quantifier = .required },
6230 .{ .kind = .IdRef, .quantifier = .required },6753 .{ .kind = .id_ref, .quantifier = .required },
6231 },6754 },
6232 },6755 },
6233 .{6756 .{
6234 .name = "OpConvertUToF",6757 .name = "OpConvertUToF",
6235 .opcode = 112,6758 .opcode = 112,
6236 .operands = &[_]Operand{6759 .operands = &.{
6237 .{ .kind = .IdResultType, .quantifier = .required },6760 .{ .kind = .id_result_type, .quantifier = .required },
6238 .{ .kind = .IdResult, .quantifier = .required },6761 .{ .kind = .id_result, .quantifier = .required },
6239 .{ .kind = .IdRef, .quantifier = .required },6762 .{ .kind = .id_ref, .quantifier = .required },
6240 },6763 },
6241 },6764 },
6242 .{6765 .{
6243 .name = "OpUConvert",6766 .name = "OpUConvert",
6244 .opcode = 113,6767 .opcode = 113,
6245 .operands = &[_]Operand{6768 .operands = &.{
6246 .{ .kind = .IdResultType, .quantifier = .required },6769 .{ .kind = .id_result_type, .quantifier = .required },
6247 .{ .kind = .IdResult, .quantifier = .required },6770 .{ .kind = .id_result, .quantifier = .required },
6248 .{ .kind = .IdRef, .quantifier = .required },6771 .{ .kind = .id_ref, .quantifier = .required },
6249 },6772 },
6250 },6773 },
6251 .{6774 .{
6252 .name = "OpSConvert",6775 .name = "OpSConvert",
6253 .opcode = 114,6776 .opcode = 114,
6254 .operands = &[_]Operand{6777 .operands = &.{
6255 .{ .kind = .IdResultType, .quantifier = .required },6778 .{ .kind = .id_result_type, .quantifier = .required },
6256 .{ .kind = .IdResult, .quantifier = .required },6779 .{ .kind = .id_result, .quantifier = .required },
6257 .{ .kind = .IdRef, .quantifier = .required },6780 .{ .kind = .id_ref, .quantifier = .required },
6258 },6781 },
6259 },6782 },
6260 .{6783 .{
6261 .name = "OpFConvert",6784 .name = "OpFConvert",
6262 .opcode = 115,6785 .opcode = 115,
6263 .operands = &[_]Operand{6786 .operands = &.{
6264 .{ .kind = .IdResultType, .quantifier = .required },6787 .{ .kind = .id_result_type, .quantifier = .required },
6265 .{ .kind = .IdResult, .quantifier = .required },6788 .{ .kind = .id_result, .quantifier = .required },
6266 .{ .kind = .IdRef, .quantifier = .required },6789 .{ .kind = .id_ref, .quantifier = .required },
6267 },6790 },
6268 },6791 },
6269 .{6792 .{
6270 .name = "OpQuantizeToF16",6793 .name = "OpQuantizeToF16",
6271 .opcode = 116,6794 .opcode = 116,
6272 .operands = &[_]Operand{6795 .operands = &.{
6273 .{ .kind = .IdResultType, .quantifier = .required },6796 .{ .kind = .id_result_type, .quantifier = .required },
6274 .{ .kind = .IdResult, .quantifier = .required },6797 .{ .kind = .id_result, .quantifier = .required },
6275 .{ .kind = .IdRef, .quantifier = .required },6798 .{ .kind = .id_ref, .quantifier = .required },
6276 },6799 },
6277 },6800 },
6278 .{6801 .{
6279 .name = "OpConvertPtrToU",6802 .name = "OpConvertPtrToU",
6280 .opcode = 117,6803 .opcode = 117,
6281 .operands = &[_]Operand{6804 .operands = &.{
6282 .{ .kind = .IdResultType, .quantifier = .required },6805 .{ .kind = .id_result_type, .quantifier = .required },
6283 .{ .kind = .IdResult, .quantifier = .required },6806 .{ .kind = .id_result, .quantifier = .required },
6284 .{ .kind = .IdRef, .quantifier = .required },6807 .{ .kind = .id_ref, .quantifier = .required },
6285 },6808 },
6286 },6809 },
6287 .{6810 .{
6288 .name = "OpSatConvertSToU",6811 .name = "OpSatConvertSToU",
6289 .opcode = 118,6812 .opcode = 118,
6290 .operands = &[_]Operand{6813 .operands = &.{
6291 .{ .kind = .IdResultType, .quantifier = .required },6814 .{ .kind = .id_result_type, .quantifier = .required },
6292 .{ .kind = .IdResult, .quantifier = .required },6815 .{ .kind = .id_result, .quantifier = .required },
6293 .{ .kind = .IdRef, .quantifier = .required },6816 .{ .kind = .id_ref, .quantifier = .required },
6294 },6817 },
6295 },6818 },
6296 .{6819 .{
6297 .name = "OpSatConvertUToS",6820 .name = "OpSatConvertUToS",
6298 .opcode = 119,6821 .opcode = 119,
6299 .operands = &[_]Operand{6822 .operands = &.{
6300 .{ .kind = .IdResultType, .quantifier = .required },6823 .{ .kind = .id_result_type, .quantifier = .required },
6301 .{ .kind = .IdResult, .quantifier = .required },6824 .{ .kind = .id_result, .quantifier = .required },
6302 .{ .kind = .IdRef, .quantifier = .required },6825 .{ .kind = .id_ref, .quantifier = .required },
6303 },6826 },
6304 },6827 },
6305 .{6828 .{
6306 .name = "OpConvertUToPtr",6829 .name = "OpConvertUToPtr",
6307 .opcode = 120,6830 .opcode = 120,
6308 .operands = &[_]Operand{6831 .operands = &.{
6309 .{ .kind = .IdResultType, .quantifier = .required },6832 .{ .kind = .id_result_type, .quantifier = .required },
6310 .{ .kind = .IdResult, .quantifier = .required },6833 .{ .kind = .id_result, .quantifier = .required },
6311 .{ .kind = .IdRef, .quantifier = .required },6834 .{ .kind = .id_ref, .quantifier = .required },
6312 },6835 },
6313 },6836 },
6314 .{6837 .{
6315 .name = "OpPtrCastToGeneric",6838 .name = "OpPtrCastToGeneric",
6316 .opcode = 121,6839 .opcode = 121,
6317 .operands = &[_]Operand{6840 .operands = &.{
6318 .{ .kind = .IdResultType, .quantifier = .required },6841 .{ .kind = .id_result_type, .quantifier = .required },
6319 .{ .kind = .IdResult, .quantifier = .required },6842 .{ .kind = .id_result, .quantifier = .required },
6320 .{ .kind = .IdRef, .quantifier = .required },6843 .{ .kind = .id_ref, .quantifier = .required },
6321 },6844 },
6322 },6845 },
6323 .{6846 .{
6324 .name = "OpGenericCastToPtr",6847 .name = "OpGenericCastToPtr",
6325 .opcode = 122,6848 .opcode = 122,
6326 .operands = &[_]Operand{6849 .operands = &.{
6327 .{ .kind = .IdResultType, .quantifier = .required },6850 .{ .kind = .id_result_type, .quantifier = .required },
6328 .{ .kind = .IdResult, .quantifier = .required },6851 .{ .kind = .id_result, .quantifier = .required },
6329 .{ .kind = .IdRef, .quantifier = .required },6852 .{ .kind = .id_ref, .quantifier = .required },
6330 },6853 },
6331 },6854 },
6332 .{6855 .{
6333 .name = "OpGenericCastToPtrExplicit",6856 .name = "OpGenericCastToPtrExplicit",
6334 .opcode = 123,6857 .opcode = 123,
6335 .operands = &[_]Operand{6858 .operands = &.{
6336 .{ .kind = .IdResultType, .quantifier = .required },6859 .{ .kind = .id_result_type, .quantifier = .required },
6337 .{ .kind = .IdResult, .quantifier = .required },6860 .{ .kind = .id_result, .quantifier = .required },
6338 .{ .kind = .IdRef, .quantifier = .required },6861 .{ .kind = .id_ref, .quantifier = .required },
6339 .{ .kind = .StorageClass, .quantifier = .required },6862 .{ .kind = .storage_class, .quantifier = .required },
6340 },6863 },
6341 },6864 },
6342 .{6865 .{
6343 .name = "OpBitcast",6866 .name = "OpBitcast",
6344 .opcode = 124,6867 .opcode = 124,
6345 .operands = &[_]Operand{6868 .operands = &.{
6346 .{ .kind = .IdResultType, .quantifier = .required },6869 .{ .kind = .id_result_type, .quantifier = .required },
6347 .{ .kind = .IdResult, .quantifier = .required },6870 .{ .kind = .id_result, .quantifier = .required },
6348 .{ .kind = .IdRef, .quantifier = .required },6871 .{ .kind = .id_ref, .quantifier = .required },
6349 },6872 },
6350 },6873 },
6351 .{6874 .{
6352 .name = "OpSNegate",6875 .name = "OpSNegate",
6353 .opcode = 126,6876 .opcode = 126,
6354 .operands = &[_]Operand{6877 .operands = &.{
6355 .{ .kind = .IdResultType, .quantifier = .required },6878 .{ .kind = .id_result_type, .quantifier = .required },
6356 .{ .kind = .IdResult, .quantifier = .required },6879 .{ .kind = .id_result, .quantifier = .required },
6357 .{ .kind = .IdRef, .quantifier = .required },6880 .{ .kind = .id_ref, .quantifier = .required },
6358 },6881 },
6359 },6882 },
6360 .{6883 .{
6361 .name = "OpFNegate",6884 .name = "OpFNegate",
6362 .opcode = 127,6885 .opcode = 127,
6363 .operands = &[_]Operand{6886 .operands = &.{
6364 .{ .kind = .IdResultType, .quantifier = .required },6887 .{ .kind = .id_result_type, .quantifier = .required },
6365 .{ .kind = .IdResult, .quantifier = .required },6888 .{ .kind = .id_result, .quantifier = .required },
6366 .{ .kind = .IdRef, .quantifier = .required },6889 .{ .kind = .id_ref, .quantifier = .required },
6367 },6890 },
6368 },6891 },
6369 .{6892 .{
6370 .name = "OpIAdd",6893 .name = "OpIAdd",
6371 .opcode = 128,6894 .opcode = 128,
6372 .operands = &[_]Operand{6895 .operands = &.{
6373 .{ .kind = .IdResultType, .quantifier = .required },6896 .{ .kind = .id_result_type, .quantifier = .required },
6374 .{ .kind = .IdResult, .quantifier = .required },6897 .{ .kind = .id_result, .quantifier = .required },
6375 .{ .kind = .IdRef, .quantifier = .required },6898 .{ .kind = .id_ref, .quantifier = .required },
6376 .{ .kind = .IdRef, .quantifier = .required },6899 .{ .kind = .id_ref, .quantifier = .required },
6377 },6900 },
6378 },6901 },
6379 .{6902 .{
6380 .name = "OpFAdd",6903 .name = "OpFAdd",
6381 .opcode = 129,6904 .opcode = 129,
6382 .operands = &[_]Operand{6905 .operands = &.{
6383 .{ .kind = .IdResultType, .quantifier = .required },6906 .{ .kind = .id_result_type, .quantifier = .required },
6384 .{ .kind = .IdResult, .quantifier = .required },6907 .{ .kind = .id_result, .quantifier = .required },
6385 .{ .kind = .IdRef, .quantifier = .required },6908 .{ .kind = .id_ref, .quantifier = .required },
6386 .{ .kind = .IdRef, .quantifier = .required },6909 .{ .kind = .id_ref, .quantifier = .required },
6387 },6910 },
6388 },6911 },
6389 .{6912 .{
6390 .name = "OpISub",6913 .name = "OpISub",
6391 .opcode = 130,6914 .opcode = 130,
6392 .operands = &[_]Operand{6915 .operands = &.{
6393 .{ .kind = .IdResultType, .quantifier = .required },6916 .{ .kind = .id_result_type, .quantifier = .required },
6394 .{ .kind = .IdResult, .quantifier = .required },6917 .{ .kind = .id_result, .quantifier = .required },
6395 .{ .kind = .IdRef, .quantifier = .required },6918 .{ .kind = .id_ref, .quantifier = .required },
6396 .{ .kind = .IdRef, .quantifier = .required },6919 .{ .kind = .id_ref, .quantifier = .required },
6397 },6920 },
6398 },6921 },
6399 .{6922 .{
6400 .name = "OpFSub",6923 .name = "OpFSub",
6401 .opcode = 131,6924 .opcode = 131,
6402 .operands = &[_]Operand{6925 .operands = &.{
6403 .{ .kind = .IdResultType, .quantifier = .required },6926 .{ .kind = .id_result_type, .quantifier = .required },
6404 .{ .kind = .IdResult, .quantifier = .required },6927 .{ .kind = .id_result, .quantifier = .required },
6405 .{ .kind = .IdRef, .quantifier = .required },6928 .{ .kind = .id_ref, .quantifier = .required },
6406 .{ .kind = .IdRef, .quantifier = .required },6929 .{ .kind = .id_ref, .quantifier = .required },
6407 },6930 },
6408 },6931 },
6409 .{6932 .{
6410 .name = "OpIMul",6933 .name = "OpIMul",
6411 .opcode = 132,6934 .opcode = 132,
6412 .operands = &[_]Operand{6935 .operands = &.{
6413 .{ .kind = .IdResultType, .quantifier = .required },6936 .{ .kind = .id_result_type, .quantifier = .required },
6414 .{ .kind = .IdResult, .quantifier = .required },6937 .{ .kind = .id_result, .quantifier = .required },
6415 .{ .kind = .IdRef, .quantifier = .required },6938 .{ .kind = .id_ref, .quantifier = .required },
6416 .{ .kind = .IdRef, .quantifier = .required },6939 .{ .kind = .id_ref, .quantifier = .required },
6417 },6940 },
6418 },6941 },
6419 .{6942 .{
6420 .name = "OpFMul",6943 .name = "OpFMul",
6421 .opcode = 133,6944 .opcode = 133,
6422 .operands = &[_]Operand{6945 .operands = &.{
6423 .{ .kind = .IdResultType, .quantifier = .required },6946 .{ .kind = .id_result_type, .quantifier = .required },
6424 .{ .kind = .IdResult, .quantifier = .required },6947 .{ .kind = .id_result, .quantifier = .required },
6425 .{ .kind = .IdRef, .quantifier = .required },6948 .{ .kind = .id_ref, .quantifier = .required },
6426 .{ .kind = .IdRef, .quantifier = .required },6949 .{ .kind = .id_ref, .quantifier = .required },
6427 },6950 },
6428 },6951 },
6429 .{6952 .{
6430 .name = "OpUDiv",6953 .name = "OpUDiv",
6431 .opcode = 134,6954 .opcode = 134,
6432 .operands = &[_]Operand{6955 .operands = &.{
6433 .{ .kind = .IdResultType, .quantifier = .required },6956 .{ .kind = .id_result_type, .quantifier = .required },
6434 .{ .kind = .IdResult, .quantifier = .required },6957 .{ .kind = .id_result, .quantifier = .required },
6435 .{ .kind = .IdRef, .quantifier = .required },6958 .{ .kind = .id_ref, .quantifier = .required },
6436 .{ .kind = .IdRef, .quantifier = .required },6959 .{ .kind = .id_ref, .quantifier = .required },
6437 },6960 },
6438 },6961 },
6439 .{6962 .{
6440 .name = "OpSDiv",6963 .name = "OpSDiv",
6441 .opcode = 135,6964 .opcode = 135,
6442 .operands = &[_]Operand{6965 .operands = &.{
6443 .{ .kind = .IdResultType, .quantifier = .required },6966 .{ .kind = .id_result_type, .quantifier = .required },
6444 .{ .kind = .IdResult, .quantifier = .required },6967 .{ .kind = .id_result, .quantifier = .required },
6445 .{ .kind = .IdRef, .quantifier = .required },6968 .{ .kind = .id_ref, .quantifier = .required },
6446 .{ .kind = .IdRef, .quantifier = .required },6969 .{ .kind = .id_ref, .quantifier = .required },
6447 },6970 },
6448 },6971 },
6449 .{6972 .{
6450 .name = "OpFDiv",6973 .name = "OpFDiv",
6451 .opcode = 136,6974 .opcode = 136,
6452 .operands = &[_]Operand{6975 .operands = &.{
6453 .{ .kind = .IdResultType, .quantifier = .required },6976 .{ .kind = .id_result_type, .quantifier = .required },
6454 .{ .kind = .IdResult, .quantifier = .required },6977 .{ .kind = .id_result, .quantifier = .required },
6455 .{ .kind = .IdRef, .quantifier = .required },6978 .{ .kind = .id_ref, .quantifier = .required },
6456 .{ .kind = .IdRef, .quantifier = .required },6979 .{ .kind = .id_ref, .quantifier = .required },
6457 },6980 },
6458 },6981 },
6459 .{6982 .{
6460 .name = "OpUMod",6983 .name = "OpUMod",
6461 .opcode = 137,6984 .opcode = 137,
6462 .operands = &[_]Operand{6985 .operands = &.{
6463 .{ .kind = .IdResultType, .quantifier = .required },6986 .{ .kind = .id_result_type, .quantifier = .required },
6464 .{ .kind = .IdResult, .quantifier = .required },6987 .{ .kind = .id_result, .quantifier = .required },
6465 .{ .kind = .IdRef, .quantifier = .required },6988 .{ .kind = .id_ref, .quantifier = .required },
6466 .{ .kind = .IdRef, .quantifier = .required },6989 .{ .kind = .id_ref, .quantifier = .required },
6467 },6990 },
6468 },6991 },
6469 .{6992 .{
6470 .name = "OpSRem",6993 .name = "OpSRem",
6471 .opcode = 138,6994 .opcode = 138,
6472 .operands = &[_]Operand{6995 .operands = &.{
6473 .{ .kind = .IdResultType, .quantifier = .required },6996 .{ .kind = .id_result_type, .quantifier = .required },
6474 .{ .kind = .IdResult, .quantifier = .required },6997 .{ .kind = .id_result, .quantifier = .required },
6475 .{ .kind = .IdRef, .quantifier = .required },6998 .{ .kind = .id_ref, .quantifier = .required },
6476 .{ .kind = .IdRef, .quantifier = .required },6999 .{ .kind = .id_ref, .quantifier = .required },
6477 },7000 },
6478 },7001 },
6479 .{7002 .{
6480 .name = "OpSMod",7003 .name = "OpSMod",
6481 .opcode = 139,7004 .opcode = 139,
6482 .operands = &[_]Operand{7005 .operands = &.{
6483 .{ .kind = .IdResultType, .quantifier = .required },7006 .{ .kind = .id_result_type, .quantifier = .required },
6484 .{ .kind = .IdResult, .quantifier = .required },7007 .{ .kind = .id_result, .quantifier = .required },
6485 .{ .kind = .IdRef, .quantifier = .required },7008 .{ .kind = .id_ref, .quantifier = .required },
6486 .{ .kind = .IdRef, .quantifier = .required },7009 .{ .kind = .id_ref, .quantifier = .required },
6487 },7010 },
6488 },7011 },
6489 .{7012 .{
6490 .name = "OpFRem",7013 .name = "OpFRem",
6491 .opcode = 140,7014 .opcode = 140,
6492 .operands = &[_]Operand{7015 .operands = &.{
6493 .{ .kind = .IdResultType, .quantifier = .required },7016 .{ .kind = .id_result_type, .quantifier = .required },
6494 .{ .kind = .IdResult, .quantifier = .required },7017 .{ .kind = .id_result, .quantifier = .required },
6495 .{ .kind = .IdRef, .quantifier = .required },7018 .{ .kind = .id_ref, .quantifier = .required },
6496 .{ .kind = .IdRef, .quantifier = .required },7019 .{ .kind = .id_ref, .quantifier = .required },
6497 },7020 },
6498 },7021 },
6499 .{7022 .{
6500 .name = "OpFMod",7023 .name = "OpFMod",
6501 .opcode = 141,7024 .opcode = 141,
6502 .operands = &[_]Operand{7025 .operands = &.{
6503 .{ .kind = .IdResultType, .quantifier = .required },7026 .{ .kind = .id_result_type, .quantifier = .required },
6504 .{ .kind = .IdResult, .quantifier = .required },7027 .{ .kind = .id_result, .quantifier = .required },
6505 .{ .kind = .IdRef, .quantifier = .required },7028 .{ .kind = .id_ref, .quantifier = .required },
6506 .{ .kind = .IdRef, .quantifier = .required },7029 .{ .kind = .id_ref, .quantifier = .required },
6507 },7030 },
6508 },7031 },
6509 .{7032 .{
6510 .name = "OpVectorTimesScalar",7033 .name = "OpVectorTimesScalar",
6511 .opcode = 142,7034 .opcode = 142,
6512 .operands = &[_]Operand{7035 .operands = &.{
6513 .{ .kind = .IdResultType, .quantifier = .required },7036 .{ .kind = .id_result_type, .quantifier = .required },
6514 .{ .kind = .IdResult, .quantifier = .required },7037 .{ .kind = .id_result, .quantifier = .required },
6515 .{ .kind = .IdRef, .quantifier = .required },7038 .{ .kind = .id_ref, .quantifier = .required },
6516 .{ .kind = .IdRef, .quantifier = .required },7039 .{ .kind = .id_ref, .quantifier = .required },
6517 },7040 },
6518 },7041 },
6519 .{7042 .{
6520 .name = "OpMatrixTimesScalar",7043 .name = "OpMatrixTimesScalar",
6521 .opcode = 143,7044 .opcode = 143,
6522 .operands = &[_]Operand{7045 .operands = &.{
6523 .{ .kind = .IdResultType, .quantifier = .required },7046 .{ .kind = .id_result_type, .quantifier = .required },
6524 .{ .kind = .IdResult, .quantifier = .required },7047 .{ .kind = .id_result, .quantifier = .required },
6525 .{ .kind = .IdRef, .quantifier = .required },7048 .{ .kind = .id_ref, .quantifier = .required },
6526 .{ .kind = .IdRef, .quantifier = .required },7049 .{ .kind = .id_ref, .quantifier = .required },
6527 },7050 },
6528 },7051 },
6529 .{7052 .{
6530 .name = "OpVectorTimesMatrix",7053 .name = "OpVectorTimesMatrix",
6531 .opcode = 144,7054 .opcode = 144,
6532 .operands = &[_]Operand{7055 .operands = &.{
6533 .{ .kind = .IdResultType, .quantifier = .required },7056 .{ .kind = .id_result_type, .quantifier = .required },
6534 .{ .kind = .IdResult, .quantifier = .required },7057 .{ .kind = .id_result, .quantifier = .required },
6535 .{ .kind = .IdRef, .quantifier = .required },7058 .{ .kind = .id_ref, .quantifier = .required },
6536 .{ .kind = .IdRef, .quantifier = .required },7059 .{ .kind = .id_ref, .quantifier = .required },
6537 },7060 },
6538 },7061 },
6539 .{7062 .{
6540 .name = "OpMatrixTimesVector",7063 .name = "OpMatrixTimesVector",
6541 .opcode = 145,7064 .opcode = 145,
6542 .operands = &[_]Operand{7065 .operands = &.{
6543 .{ .kind = .IdResultType, .quantifier = .required },7066 .{ .kind = .id_result_type, .quantifier = .required },
6544 .{ .kind = .IdResult, .quantifier = .required },7067 .{ .kind = .id_result, .quantifier = .required },
6545 .{ .kind = .IdRef, .quantifier = .required },7068 .{ .kind = .id_ref, .quantifier = .required },
6546 .{ .kind = .IdRef, .quantifier = .required },7069 .{ .kind = .id_ref, .quantifier = .required },
6547 },7070 },
6548 },7071 },
6549 .{7072 .{
6550 .name = "OpMatrixTimesMatrix",7073 .name = "OpMatrixTimesMatrix",
6551 .opcode = 146,7074 .opcode = 146,
6552 .operands = &[_]Operand{7075 .operands = &.{
6553 .{ .kind = .IdResultType, .quantifier = .required },7076 .{ .kind = .id_result_type, .quantifier = .required },
6554 .{ .kind = .IdResult, .quantifier = .required },7077 .{ .kind = .id_result, .quantifier = .required },
6555 .{ .kind = .IdRef, .quantifier = .required },7078 .{ .kind = .id_ref, .quantifier = .required },
6556 .{ .kind = .IdRef, .quantifier = .required },7079 .{ .kind = .id_ref, .quantifier = .required },
6557 },7080 },
6558 },7081 },
6559 .{7082 .{
6560 .name = "OpOuterProduct",7083 .name = "OpOuterProduct",
6561 .opcode = 147,7084 .opcode = 147,
6562 .operands = &[_]Operand{7085 .operands = &.{
6563 .{ .kind = .IdResultType, .quantifier = .required },7086 .{ .kind = .id_result_type, .quantifier = .required },
6564 .{ .kind = .IdResult, .quantifier = .required },7087 .{ .kind = .id_result, .quantifier = .required },
6565 .{ .kind = .IdRef, .quantifier = .required },7088 .{ .kind = .id_ref, .quantifier = .required },
6566 .{ .kind = .IdRef, .quantifier = .required },7089 .{ .kind = .id_ref, .quantifier = .required },
6567 },7090 },
6568 },7091 },
6569 .{7092 .{
6570 .name = "OpDot",7093 .name = "OpDot",
6571 .opcode = 148,7094 .opcode = 148,
6572 .operands = &[_]Operand{7095 .operands = &.{
6573 .{ .kind = .IdResultType, .quantifier = .required },7096 .{ .kind = .id_result_type, .quantifier = .required },
6574 .{ .kind = .IdResult, .quantifier = .required },7097 .{ .kind = .id_result, .quantifier = .required },
6575 .{ .kind = .IdRef, .quantifier = .required },7098 .{ .kind = .id_ref, .quantifier = .required },
6576 .{ .kind = .IdRef, .quantifier = .required },7099 .{ .kind = .id_ref, .quantifier = .required },
6577 },7100 },
6578 },7101 },
6579 .{7102 .{
6580 .name = "OpIAddCarry",7103 .name = "OpIAddCarry",
6581 .opcode = 149,7104 .opcode = 149,
6582 .operands = &[_]Operand{7105 .operands = &.{
6583 .{ .kind = .IdResultType, .quantifier = .required },7106 .{ .kind = .id_result_type, .quantifier = .required },
6584 .{ .kind = .IdResult, .quantifier = .required },7107 .{ .kind = .id_result, .quantifier = .required },
6585 .{ .kind = .IdRef, .quantifier = .required },7108 .{ .kind = .id_ref, .quantifier = .required },
6586 .{ .kind = .IdRef, .quantifier = .required },7109 .{ .kind = .id_ref, .quantifier = .required },
6587 },7110 },
6588 },7111 },
6589 .{7112 .{
6590 .name = "OpISubBorrow",7113 .name = "OpISubBorrow",
6591 .opcode = 150,7114 .opcode = 150,
6592 .operands = &[_]Operand{7115 .operands = &.{
6593 .{ .kind = .IdResultType, .quantifier = .required },7116 .{ .kind = .id_result_type, .quantifier = .required },
6594 .{ .kind = .IdResult, .quantifier = .required },7117 .{ .kind = .id_result, .quantifier = .required },
6595 .{ .kind = .IdRef, .quantifier = .required },7118 .{ .kind = .id_ref, .quantifier = .required },
6596 .{ .kind = .IdRef, .quantifier = .required },7119 .{ .kind = .id_ref, .quantifier = .required },
6597 },7120 },
6598 },7121 },
6599 .{7122 .{
6600 .name = "OpUMulExtended",7123 .name = "OpUMulExtended",
6601 .opcode = 151,7124 .opcode = 151,
6602 .operands = &[_]Operand{7125 .operands = &.{
6603 .{ .kind = .IdResultType, .quantifier = .required },7126 .{ .kind = .id_result_type, .quantifier = .required },
6604 .{ .kind = .IdResult, .quantifier = .required },7127 .{ .kind = .id_result, .quantifier = .required },
6605 .{ .kind = .IdRef, .quantifier = .required },7128 .{ .kind = .id_ref, .quantifier = .required },
6606 .{ .kind = .IdRef, .quantifier = .required },7129 .{ .kind = .id_ref, .quantifier = .required },
6607 },7130 },
6608 },7131 },
6609 .{7132 .{
6610 .name = "OpSMulExtended",7133 .name = "OpSMulExtended",
6611 .opcode = 152,7134 .opcode = 152,
6612 .operands = &[_]Operand{7135 .operands = &.{
6613 .{ .kind = .IdResultType, .quantifier = .required },7136 .{ .kind = .id_result_type, .quantifier = .required },
6614 .{ .kind = .IdResult, .quantifier = .required },7137 .{ .kind = .id_result, .quantifier = .required },
6615 .{ .kind = .IdRef, .quantifier = .required },7138 .{ .kind = .id_ref, .quantifier = .required },
6616 .{ .kind = .IdRef, .quantifier = .required },7139 .{ .kind = .id_ref, .quantifier = .required },
6617 },7140 },
6618 },7141 },
6619 .{7142 .{
6620 .name = "OpAny",7143 .name = "OpAny",
6621 .opcode = 154,7144 .opcode = 154,
6622 .operands = &[_]Operand{7145 .operands = &.{
6623 .{ .kind = .IdResultType, .quantifier = .required },7146 .{ .kind = .id_result_type, .quantifier = .required },
6624 .{ .kind = .IdResult, .quantifier = .required },7147 .{ .kind = .id_result, .quantifier = .required },
6625 .{ .kind = .IdRef, .quantifier = .required },7148 .{ .kind = .id_ref, .quantifier = .required },
6626 },7149 },
6627 },7150 },
6628 .{7151 .{
6629 .name = "OpAll",7152 .name = "OpAll",
6630 .opcode = 155,7153 .opcode = 155,
6631 .operands = &[_]Operand{7154 .operands = &.{
6632 .{ .kind = .IdResultType, .quantifier = .required },7155 .{ .kind = .id_result_type, .quantifier = .required },
6633 .{ .kind = .IdResult, .quantifier = .required },7156 .{ .kind = .id_result, .quantifier = .required },
6634 .{ .kind = .IdRef, .quantifier = .required },7157 .{ .kind = .id_ref, .quantifier = .required },
6635 },7158 },
6636 },7159 },
6637 .{7160 .{
6638 .name = "OpIsNan",7161 .name = "OpIsNan",
6639 .opcode = 156,7162 .opcode = 156,
6640 .operands = &[_]Operand{7163 .operands = &.{
6641 .{ .kind = .IdResultType, .quantifier = .required },7164 .{ .kind = .id_result_type, .quantifier = .required },
6642 .{ .kind = .IdResult, .quantifier = .required },7165 .{ .kind = .id_result, .quantifier = .required },
6643 .{ .kind = .IdRef, .quantifier = .required },7166 .{ .kind = .id_ref, .quantifier = .required },
6644 },7167 },
6645 },7168 },
6646 .{7169 .{
6647 .name = "OpIsInf",7170 .name = "OpIsInf",
6648 .opcode = 157,7171 .opcode = 157,
6649 .operands = &[_]Operand{7172 .operands = &.{
6650 .{ .kind = .IdResultType, .quantifier = .required },7173 .{ .kind = .id_result_type, .quantifier = .required },
6651 .{ .kind = .IdResult, .quantifier = .required },7174 .{ .kind = .id_result, .quantifier = .required },
6652 .{ .kind = .IdRef, .quantifier = .required },7175 .{ .kind = .id_ref, .quantifier = .required },
6653 },7176 },
6654 },7177 },
6655 .{7178 .{
6656 .name = "OpIsFinite",7179 .name = "OpIsFinite",
6657 .opcode = 158,7180 .opcode = 158,
6658 .operands = &[_]Operand{7181 .operands = &.{
6659 .{ .kind = .IdResultType, .quantifier = .required },7182 .{ .kind = .id_result_type, .quantifier = .required },
6660 .{ .kind = .IdResult, .quantifier = .required },7183 .{ .kind = .id_result, .quantifier = .required },
6661 .{ .kind = .IdRef, .quantifier = .required },7184 .{ .kind = .id_ref, .quantifier = .required },
6662 },7185 },
6663 },7186 },
6664 .{7187 .{
6665 .name = "OpIsNormal",7188 .name = "OpIsNormal",
6666 .opcode = 159,7189 .opcode = 159,
6667 .operands = &[_]Operand{7190 .operands = &.{
6668 .{ .kind = .IdResultType, .quantifier = .required },7191 .{ .kind = .id_result_type, .quantifier = .required },
6669 .{ .kind = .IdResult, .quantifier = .required },7192 .{ .kind = .id_result, .quantifier = .required },
6670 .{ .kind = .IdRef, .quantifier = .required },7193 .{ .kind = .id_ref, .quantifier = .required },
6671 },7194 },
6672 },7195 },
6673 .{7196 .{
6674 .name = "OpSignBitSet",7197 .name = "OpSignBitSet",
6675 .opcode = 160,7198 .opcode = 160,
6676 .operands = &[_]Operand{7199 .operands = &.{
6677 .{ .kind = .IdResultType, .quantifier = .required },7200 .{ .kind = .id_result_type, .quantifier = .required },
6678 .{ .kind = .IdResult, .quantifier = .required },7201 .{ .kind = .id_result, .quantifier = .required },
6679 .{ .kind = .IdRef, .quantifier = .required },7202 .{ .kind = .id_ref, .quantifier = .required },
6680 },7203 },
6681 },7204 },
6682 .{7205 .{
6683 .name = "OpLessOrGreater",7206 .name = "OpLessOrGreater",
6684 .opcode = 161,7207 .opcode = 161,
6685 .operands = &[_]Operand{7208 .operands = &.{
6686 .{ .kind = .IdResultType, .quantifier = .required },7209 .{ .kind = .id_result_type, .quantifier = .required },
6687 .{ .kind = .IdResult, .quantifier = .required },7210 .{ .kind = .id_result, .quantifier = .required },
6688 .{ .kind = .IdRef, .quantifier = .required },7211 .{ .kind = .id_ref, .quantifier = .required },
6689 .{ .kind = .IdRef, .quantifier = .required },7212 .{ .kind = .id_ref, .quantifier = .required },
6690 },7213 },
6691 },7214 },
6692 .{7215 .{
6693 .name = "OpOrdered",7216 .name = "OpOrdered",
6694 .opcode = 162,7217 .opcode = 162,
6695 .operands = &[_]Operand{7218 .operands = &.{
6696 .{ .kind = .IdResultType, .quantifier = .required },7219 .{ .kind = .id_result_type, .quantifier = .required },
6697 .{ .kind = .IdResult, .quantifier = .required },7220 .{ .kind = .id_result, .quantifier = .required },
6698 .{ .kind = .IdRef, .quantifier = .required },7221 .{ .kind = .id_ref, .quantifier = .required },
6699 .{ .kind = .IdRef, .quantifier = .required },7222 .{ .kind = .id_ref, .quantifier = .required },
6700 },7223 },
6701 },7224 },
6702 .{7225 .{
6703 .name = "OpUnordered",7226 .name = "OpUnordered",
6704 .opcode = 163,7227 .opcode = 163,
6705 .operands = &[_]Operand{7228 .operands = &.{
6706 .{ .kind = .IdResultType, .quantifier = .required },7229 .{ .kind = .id_result_type, .quantifier = .required },
6707 .{ .kind = .IdResult, .quantifier = .required },7230 .{ .kind = .id_result, .quantifier = .required },
6708 .{ .kind = .IdRef, .quantifier = .required },7231 .{ .kind = .id_ref, .quantifier = .required },
6709 .{ .kind = .IdRef, .quantifier = .required },7232 .{ .kind = .id_ref, .quantifier = .required },
6710 },7233 },
6711 },7234 },
6712 .{7235 .{
6713 .name = "OpLogicalEqual",7236 .name = "OpLogicalEqual",
6714 .opcode = 164,7237 .opcode = 164,
6715 .operands = &[_]Operand{7238 .operands = &.{
6716 .{ .kind = .IdResultType, .quantifier = .required },7239 .{ .kind = .id_result_type, .quantifier = .required },
6717 .{ .kind = .IdResult, .quantifier = .required },7240 .{ .kind = .id_result, .quantifier = .required },
6718 .{ .kind = .IdRef, .quantifier = .required },7241 .{ .kind = .id_ref, .quantifier = .required },
6719 .{ .kind = .IdRef, .quantifier = .required },7242 .{ .kind = .id_ref, .quantifier = .required },
6720 },7243 },
6721 },7244 },
6722 .{7245 .{
6723 .name = "OpLogicalNotEqual",7246 .name = "OpLogicalNotEqual",
6724 .opcode = 165,7247 .opcode = 165,
6725 .operands = &[_]Operand{7248 .operands = &.{
6726 .{ .kind = .IdResultType, .quantifier = .required },7249 .{ .kind = .id_result_type, .quantifier = .required },
6727 .{ .kind = .IdResult, .quantifier = .required },7250 .{ .kind = .id_result, .quantifier = .required },
6728 .{ .kind = .IdRef, .quantifier = .required },7251 .{ .kind = .id_ref, .quantifier = .required },
6729 .{ .kind = .IdRef, .quantifier = .required },7252 .{ .kind = .id_ref, .quantifier = .required },
6730 },7253 },
6731 },7254 },
6732 .{7255 .{
6733 .name = "OpLogicalOr",7256 .name = "OpLogicalOr",
6734 .opcode = 166,7257 .opcode = 166,
6735 .operands = &[_]Operand{7258 .operands = &.{
6736 .{ .kind = .IdResultType, .quantifier = .required },7259 .{ .kind = .id_result_type, .quantifier = .required },
6737 .{ .kind = .IdResult, .quantifier = .required },7260 .{ .kind = .id_result, .quantifier = .required },
6738 .{ .kind = .IdRef, .quantifier = .required },7261 .{ .kind = .id_ref, .quantifier = .required },
6739 .{ .kind = .IdRef, .quantifier = .required },7262 .{ .kind = .id_ref, .quantifier = .required },
6740 },7263 },
6741 },7264 },
6742 .{7265 .{
6743 .name = "OpLogicalAnd",7266 .name = "OpLogicalAnd",
6744 .opcode = 167,7267 .opcode = 167,
6745 .operands = &[_]Operand{7268 .operands = &.{
6746 .{ .kind = .IdResultType, .quantifier = .required },7269 .{ .kind = .id_result_type, .quantifier = .required },
6747 .{ .kind = .IdResult, .quantifier = .required },7270 .{ .kind = .id_result, .quantifier = .required },
6748 .{ .kind = .IdRef, .quantifier = .required },7271 .{ .kind = .id_ref, .quantifier = .required },
6749 .{ .kind = .IdRef, .quantifier = .required },7272 .{ .kind = .id_ref, .quantifier = .required },
6750 },7273 },
6751 },7274 },
6752 .{7275 .{
6753 .name = "OpLogicalNot",7276 .name = "OpLogicalNot",
6754 .opcode = 168,7277 .opcode = 168,
6755 .operands = &[_]Operand{7278 .operands = &.{
6756 .{ .kind = .IdResultType, .quantifier = .required },7279 .{ .kind = .id_result_type, .quantifier = .required },
6757 .{ .kind = .IdResult, .quantifier = .required },7280 .{ .kind = .id_result, .quantifier = .required },
6758 .{ .kind = .IdRef, .quantifier = .required },7281 .{ .kind = .id_ref, .quantifier = .required },
6759 },7282 },
6760 },7283 },
6761 .{7284 .{
6762 .name = "OpSelect",7285 .name = "OpSelect",
6763 .opcode = 169,7286 .opcode = 169,
6764 .operands = &[_]Operand{7287 .operands = &.{
6765 .{ .kind = .IdResultType, .quantifier = .required },7288 .{ .kind = .id_result_type, .quantifier = .required },
6766 .{ .kind = .IdResult, .quantifier = .required },7289 .{ .kind = .id_result, .quantifier = .required },
6767 .{ .kind = .IdRef, .quantifier = .required },7290 .{ .kind = .id_ref, .quantifier = .required },
6768 .{ .kind = .IdRef, .quantifier = .required },7291 .{ .kind = .id_ref, .quantifier = .required },
6769 .{ .kind = .IdRef, .quantifier = .required },7292 .{ .kind = .id_ref, .quantifier = .required },
6770 },7293 },
6771 },7294 },
6772 .{7295 .{
6773 .name = "OpIEqual",7296 .name = "OpIEqual",
6774 .opcode = 170,7297 .opcode = 170,
6775 .operands = &[_]Operand{7298 .operands = &.{
6776 .{ .kind = .IdResultType, .quantifier = .required },7299 .{ .kind = .id_result_type, .quantifier = .required },
6777 .{ .kind = .IdResult, .quantifier = .required },7300 .{ .kind = .id_result, .quantifier = .required },
6778 .{ .kind = .IdRef, .quantifier = .required },7301 .{ .kind = .id_ref, .quantifier = .required },
6779 .{ .kind = .IdRef, .quantifier = .required },7302 .{ .kind = .id_ref, .quantifier = .required },
6780 },7303 },
6781 },7304 },
6782 .{7305 .{
6783 .name = "OpINotEqual",7306 .name = "OpINotEqual",
6784 .opcode = 171,7307 .opcode = 171,
6785 .operands = &[_]Operand{7308 .operands = &.{
6786 .{ .kind = .IdResultType, .quantifier = .required },7309 .{ .kind = .id_result_type, .quantifier = .required },
6787 .{ .kind = .IdResult, .quantifier = .required },7310 .{ .kind = .id_result, .quantifier = .required },
6788 .{ .kind = .IdRef, .quantifier = .required },7311 .{ .kind = .id_ref, .quantifier = .required },
6789 .{ .kind = .IdRef, .quantifier = .required },7312 .{ .kind = .id_ref, .quantifier = .required },
6790 },7313 },
6791 },7314 },
6792 .{7315 .{
6793 .name = "OpUGreaterThan",7316 .name = "OpUGreaterThan",
6794 .opcode = 172,7317 .opcode = 172,
6795 .operands = &[_]Operand{7318 .operands = &.{
6796 .{ .kind = .IdResultType, .quantifier = .required },7319 .{ .kind = .id_result_type, .quantifier = .required },
6797 .{ .kind = .IdResult, .quantifier = .required },7320 .{ .kind = .id_result, .quantifier = .required },
6798 .{ .kind = .IdRef, .quantifier = .required },7321 .{ .kind = .id_ref, .quantifier = .required },
6799 .{ .kind = .IdRef, .quantifier = .required },7322 .{ .kind = .id_ref, .quantifier = .required },
6800 },7323 },
6801 },7324 },
6802 .{7325 .{
6803 .name = "OpSGreaterThan",7326 .name = "OpSGreaterThan",
6804 .opcode = 173,7327 .opcode = 173,
6805 .operands = &[_]Operand{7328 .operands = &.{
6806 .{ .kind = .IdResultType, .quantifier = .required },7329 .{ .kind = .id_result_type, .quantifier = .required },
6807 .{ .kind = .IdResult, .quantifier = .required },7330 .{ .kind = .id_result, .quantifier = .required },
6808 .{ .kind = .IdRef, .quantifier = .required },7331 .{ .kind = .id_ref, .quantifier = .required },
6809 .{ .kind = .IdRef, .quantifier = .required },7332 .{ .kind = .id_ref, .quantifier = .required },
6810 },7333 },
6811 },7334 },
6812 .{7335 .{
6813 .name = "OpUGreaterThanEqual",7336 .name = "OpUGreaterThanEqual",
6814 .opcode = 174,7337 .opcode = 174,
6815 .operands = &[_]Operand{7338 .operands = &.{
6816 .{ .kind = .IdResultType, .quantifier = .required },7339 .{ .kind = .id_result_type, .quantifier = .required },
6817 .{ .kind = .IdResult, .quantifier = .required },7340 .{ .kind = .id_result, .quantifier = .required },
6818 .{ .kind = .IdRef, .quantifier = .required },7341 .{ .kind = .id_ref, .quantifier = .required },
6819 .{ .kind = .IdRef, .quantifier = .required },7342 .{ .kind = .id_ref, .quantifier = .required },
6820 },7343 },
6821 },7344 },
6822 .{7345 .{
6823 .name = "OpSGreaterThanEqual",7346 .name = "OpSGreaterThanEqual",
6824 .opcode = 175,7347 .opcode = 175,
6825 .operands = &[_]Operand{7348 .operands = &.{
6826 .{ .kind = .IdResultType, .quantifier = .required },7349 .{ .kind = .id_result_type, .quantifier = .required },
6827 .{ .kind = .IdResult, .quantifier = .required },7350 .{ .kind = .id_result, .quantifier = .required },
6828 .{ .kind = .IdRef, .quantifier = .required },7351 .{ .kind = .id_ref, .quantifier = .required },
6829 .{ .kind = .IdRef, .quantifier = .required },7352 .{ .kind = .id_ref, .quantifier = .required },
6830 },7353 },
6831 },7354 },
6832 .{7355 .{
6833 .name = "OpULessThan",7356 .name = "OpULessThan",
6834 .opcode = 176,7357 .opcode = 176,
6835 .operands = &[_]Operand{7358 .operands = &.{
6836 .{ .kind = .IdResultType, .quantifier = .required },7359 .{ .kind = .id_result_type, .quantifier = .required },
6837 .{ .kind = .IdResult, .quantifier = .required },7360 .{ .kind = .id_result, .quantifier = .required },
6838 .{ .kind = .IdRef, .quantifier = .required },7361 .{ .kind = .id_ref, .quantifier = .required },
6839 .{ .kind = .IdRef, .quantifier = .required },7362 .{ .kind = .id_ref, .quantifier = .required },
6840 },7363 },
6841 },7364 },
6842 .{7365 .{
6843 .name = "OpSLessThan",7366 .name = "OpSLessThan",
6844 .opcode = 177,7367 .opcode = 177,
6845 .operands = &[_]Operand{7368 .operands = &.{
6846 .{ .kind = .IdResultType, .quantifier = .required },7369 .{ .kind = .id_result_type, .quantifier = .required },
6847 .{ .kind = .IdResult, .quantifier = .required },7370 .{ .kind = .id_result, .quantifier = .required },
6848 .{ .kind = .IdRef, .quantifier = .required },7371 .{ .kind = .id_ref, .quantifier = .required },
6849 .{ .kind = .IdRef, .quantifier = .required },7372 .{ .kind = .id_ref, .quantifier = .required },
6850 },7373 },
6851 },7374 },
6852 .{7375 .{
6853 .name = "OpULessThanEqual",7376 .name = "OpULessThanEqual",
6854 .opcode = 178,7377 .opcode = 178,
6855 .operands = &[_]Operand{7378 .operands = &.{
6856 .{ .kind = .IdResultType, .quantifier = .required },7379 .{ .kind = .id_result_type, .quantifier = .required },
6857 .{ .kind = .IdResult, .quantifier = .required },7380 .{ .kind = .id_result, .quantifier = .required },
6858 .{ .kind = .IdRef, .quantifier = .required },7381 .{ .kind = .id_ref, .quantifier = .required },
6859 .{ .kind = .IdRef, .quantifier = .required },7382 .{ .kind = .id_ref, .quantifier = .required },
6860 },7383 },
6861 },7384 },
6862 .{7385 .{
6863 .name = "OpSLessThanEqual",7386 .name = "OpSLessThanEqual",
6864 .opcode = 179,7387 .opcode = 179,
6865 .operands = &[_]Operand{7388 .operands = &.{
6866 .{ .kind = .IdResultType, .quantifier = .required },7389 .{ .kind = .id_result_type, .quantifier = .required },
6867 .{ .kind = .IdResult, .quantifier = .required },7390 .{ .kind = .id_result, .quantifier = .required },
6868 .{ .kind = .IdRef, .quantifier = .required },7391 .{ .kind = .id_ref, .quantifier = .required },
6869 .{ .kind = .IdRef, .quantifier = .required },7392 .{ .kind = .id_ref, .quantifier = .required },
6870 },7393 },
6871 },7394 },
6872 .{7395 .{
6873 .name = "OpFOrdEqual",7396 .name = "OpFOrdEqual",
6874 .opcode = 180,7397 .opcode = 180,
6875 .operands = &[_]Operand{7398 .operands = &.{
6876 .{ .kind = .IdResultType, .quantifier = .required },7399 .{ .kind = .id_result_type, .quantifier = .required },
6877 .{ .kind = .IdResult, .quantifier = .required },7400 .{ .kind = .id_result, .quantifier = .required },
6878 .{ .kind = .IdRef, .quantifier = .required },7401 .{ .kind = .id_ref, .quantifier = .required },
6879 .{ .kind = .IdRef, .quantifier = .required },7402 .{ .kind = .id_ref, .quantifier = .required },
6880 },7403 },
6881 },7404 },
6882 .{7405 .{
6883 .name = "OpFUnordEqual",7406 .name = "OpFUnordEqual",
6884 .opcode = 181,7407 .opcode = 181,
6885 .operands = &[_]Operand{7408 .operands = &.{
6886 .{ .kind = .IdResultType, .quantifier = .required },7409 .{ .kind = .id_result_type, .quantifier = .required },
6887 .{ .kind = .IdResult, .quantifier = .required },7410 .{ .kind = .id_result, .quantifier = .required },
6888 .{ .kind = .IdRef, .quantifier = .required },7411 .{ .kind = .id_ref, .quantifier = .required },
6889 .{ .kind = .IdRef, .quantifier = .required },7412 .{ .kind = .id_ref, .quantifier = .required },
6890 },7413 },
6891 },7414 },
6892 .{7415 .{
6893 .name = "OpFOrdNotEqual",7416 .name = "OpFOrdNotEqual",
6894 .opcode = 182,7417 .opcode = 182,
6895 .operands = &[_]Operand{7418 .operands = &.{
6896 .{ .kind = .IdResultType, .quantifier = .required },7419 .{ .kind = .id_result_type, .quantifier = .required },
6897 .{ .kind = .IdResult, .quantifier = .required },7420 .{ .kind = .id_result, .quantifier = .required },
6898 .{ .kind = .IdRef, .quantifier = .required },7421 .{ .kind = .id_ref, .quantifier = .required },
6899 .{ .kind = .IdRef, .quantifier = .required },7422 .{ .kind = .id_ref, .quantifier = .required },
6900 },7423 },
6901 },7424 },
6902 .{7425 .{
6903 .name = "OpFUnordNotEqual",7426 .name = "OpFUnordNotEqual",
6904 .opcode = 183,7427 .opcode = 183,
6905 .operands = &[_]Operand{7428 .operands = &.{
6906 .{ .kind = .IdResultType, .quantifier = .required },7429 .{ .kind = .id_result_type, .quantifier = .required },
6907 .{ .kind = .IdResult, .quantifier = .required },7430 .{ .kind = .id_result, .quantifier = .required },
6908 .{ .kind = .IdRef, .quantifier = .required },7431 .{ .kind = .id_ref, .quantifier = .required },
6909 .{ .kind = .IdRef, .quantifier = .required },7432 .{ .kind = .id_ref, .quantifier = .required },
6910 },7433 },
6911 },7434 },
6912 .{7435 .{
6913 .name = "OpFOrdLessThan",7436 .name = "OpFOrdLessThan",
6914 .opcode = 184,7437 .opcode = 184,
6915 .operands = &[_]Operand{7438 .operands = &.{
6916 .{ .kind = .IdResultType, .quantifier = .required },7439 .{ .kind = .id_result_type, .quantifier = .required },
6917 .{ .kind = .IdResult, .quantifier = .required },7440 .{ .kind = .id_result, .quantifier = .required },
6918 .{ .kind = .IdRef, .quantifier = .required },7441 .{ .kind = .id_ref, .quantifier = .required },
6919 .{ .kind = .IdRef, .quantifier = .required },7442 .{ .kind = .id_ref, .quantifier = .required },
6920 },7443 },
6921 },7444 },
6922 .{7445 .{
6923 .name = "OpFUnordLessThan",7446 .name = "OpFUnordLessThan",
6924 .opcode = 185,7447 .opcode = 185,
6925 .operands = &[_]Operand{7448 .operands = &.{
6926 .{ .kind = .IdResultType, .quantifier = .required },7449 .{ .kind = .id_result_type, .quantifier = .required },
6927 .{ .kind = .IdResult, .quantifier = .required },7450 .{ .kind = .id_result, .quantifier = .required },
6928 .{ .kind = .IdRef, .quantifier = .required },7451 .{ .kind = .id_ref, .quantifier = .required },
6929 .{ .kind = .IdRef, .quantifier = .required },7452 .{ .kind = .id_ref, .quantifier = .required },
6930 },7453 },
6931 },7454 },
6932 .{7455 .{
6933 .name = "OpFOrdGreaterThan",7456 .name = "OpFOrdGreaterThan",
6934 .opcode = 186,7457 .opcode = 186,
6935 .operands = &[_]Operand{7458 .operands = &.{
6936 .{ .kind = .IdResultType, .quantifier = .required },7459 .{ .kind = .id_result_type, .quantifier = .required },
6937 .{ .kind = .IdResult, .quantifier = .required },7460 .{ .kind = .id_result, .quantifier = .required },
6938 .{ .kind = .IdRef, .quantifier = .required },7461 .{ .kind = .id_ref, .quantifier = .required },
6939 .{ .kind = .IdRef, .quantifier = .required },7462 .{ .kind = .id_ref, .quantifier = .required },
6940 },7463 },
6941 },7464 },
6942 .{7465 .{
6943 .name = "OpFUnordGreaterThan",7466 .name = "OpFUnordGreaterThan",
6944 .opcode = 187,7467 .opcode = 187,
6945 .operands = &[_]Operand{7468 .operands = &.{
6946 .{ .kind = .IdResultType, .quantifier = .required },7469 .{ .kind = .id_result_type, .quantifier = .required },
6947 .{ .kind = .IdResult, .quantifier = .required },7470 .{ .kind = .id_result, .quantifier = .required },
6948 .{ .kind = .IdRef, .quantifier = .required },7471 .{ .kind = .id_ref, .quantifier = .required },
6949 .{ .kind = .IdRef, .quantifier = .required },7472 .{ .kind = .id_ref, .quantifier = .required },
6950 },7473 },
6951 },7474 },
6952 .{7475 .{
6953 .name = "OpFOrdLessThanEqual",7476 .name = "OpFOrdLessThanEqual",
6954 .opcode = 188,7477 .opcode = 188,
6955 .operands = &[_]Operand{7478 .operands = &.{
6956 .{ .kind = .IdResultType, .quantifier = .required },7479 .{ .kind = .id_result_type, .quantifier = .required },
6957 .{ .kind = .IdResult, .quantifier = .required },7480 .{ .kind = .id_result, .quantifier = .required },
6958 .{ .kind = .IdRef, .quantifier = .required },7481 .{ .kind = .id_ref, .quantifier = .required },
6959 .{ .kind = .IdRef, .quantifier = .required },7482 .{ .kind = .id_ref, .quantifier = .required },
6960 },7483 },
6961 },7484 },
6962 .{7485 .{
6963 .name = "OpFUnordLessThanEqual",7486 .name = "OpFUnordLessThanEqual",
6964 .opcode = 189,7487 .opcode = 189,
6965 .operands = &[_]Operand{7488 .operands = &.{
6966 .{ .kind = .IdResultType, .quantifier = .required },7489 .{ .kind = .id_result_type, .quantifier = .required },
6967 .{ .kind = .IdResult, .quantifier = .required },7490 .{ .kind = .id_result, .quantifier = .required },
6968 .{ .kind = .IdRef, .quantifier = .required },7491 .{ .kind = .id_ref, .quantifier = .required },
6969 .{ .kind = .IdRef, .quantifier = .required },7492 .{ .kind = .id_ref, .quantifier = .required },
6970 },7493 },
6971 },7494 },
6972 .{7495 .{
6973 .name = "OpFOrdGreaterThanEqual",7496 .name = "OpFOrdGreaterThanEqual",
6974 .opcode = 190,7497 .opcode = 190,
6975 .operands = &[_]Operand{7498 .operands = &.{
6976 .{ .kind = .IdResultType, .quantifier = .required },7499 .{ .kind = .id_result_type, .quantifier = .required },
6977 .{ .kind = .IdResult, .quantifier = .required },7500 .{ .kind = .id_result, .quantifier = .required },
6978 .{ .kind = .IdRef, .quantifier = .required },7501 .{ .kind = .id_ref, .quantifier = .required },
6979 .{ .kind = .IdRef, .quantifier = .required },7502 .{ .kind = .id_ref, .quantifier = .required },
6980 },7503 },
6981 },7504 },
6982 .{7505 .{
6983 .name = "OpFUnordGreaterThanEqual",7506 .name = "OpFUnordGreaterThanEqual",
6984 .opcode = 191,7507 .opcode = 191,
6985 .operands = &[_]Operand{7508 .operands = &.{
6986 .{ .kind = .IdResultType, .quantifier = .required },7509 .{ .kind = .id_result_type, .quantifier = .required },
6987 .{ .kind = .IdResult, .quantifier = .required },7510 .{ .kind = .id_result, .quantifier = .required },
6988 .{ .kind = .IdRef, .quantifier = .required },7511 .{ .kind = .id_ref, .quantifier = .required },
6989 .{ .kind = .IdRef, .quantifier = .required },7512 .{ .kind = .id_ref, .quantifier = .required },
6990 },7513 },
6991 },7514 },
6992 .{7515 .{
6993 .name = "OpShiftRightLogical",7516 .name = "OpShiftRightLogical",
6994 .opcode = 194,7517 .opcode = 194,
6995 .operands = &[_]Operand{7518 .operands = &.{
6996 .{ .kind = .IdResultType, .quantifier = .required },7519 .{ .kind = .id_result_type, .quantifier = .required },
6997 .{ .kind = .IdResult, .quantifier = .required },7520 .{ .kind = .id_result, .quantifier = .required },
6998 .{ .kind = .IdRef, .quantifier = .required },7521 .{ .kind = .id_ref, .quantifier = .required },
6999 .{ .kind = .IdRef, .quantifier = .required },7522 .{ .kind = .id_ref, .quantifier = .required },
7000 },7523 },
7001 },7524 },
7002 .{7525 .{
7003 .name = "OpShiftRightArithmetic",7526 .name = "OpShiftRightArithmetic",
7004 .opcode = 195,7527 .opcode = 195,
7005 .operands = &[_]Operand{7528 .operands = &.{
7006 .{ .kind = .IdResultType, .quantifier = .required },7529 .{ .kind = .id_result_type, .quantifier = .required },
7007 .{ .kind = .IdResult, .quantifier = .required },7530 .{ .kind = .id_result, .quantifier = .required },
7008 .{ .kind = .IdRef, .quantifier = .required },7531 .{ .kind = .id_ref, .quantifier = .required },
7009 .{ .kind = .IdRef, .quantifier = .required },7532 .{ .kind = .id_ref, .quantifier = .required },
7010 },7533 },
7011 },7534 },
7012 .{7535 .{
7013 .name = "OpShiftLeftLogical",7536 .name = "OpShiftLeftLogical",
7014 .opcode = 196,7537 .opcode = 196,
7015 .operands = &[_]Operand{7538 .operands = &.{
7016 .{ .kind = .IdResultType, .quantifier = .required },7539 .{ .kind = .id_result_type, .quantifier = .required },
7017 .{ .kind = .IdResult, .quantifier = .required },7540 .{ .kind = .id_result, .quantifier = .required },
7018 .{ .kind = .IdRef, .quantifier = .required },7541 .{ .kind = .id_ref, .quantifier = .required },
7019 .{ .kind = .IdRef, .quantifier = .required },7542 .{ .kind = .id_ref, .quantifier = .required },
7020 },7543 },
7021 },7544 },
7022 .{7545 .{
7023 .name = "OpBitwiseOr",7546 .name = "OpBitwiseOr",
7024 .opcode = 197,7547 .opcode = 197,
7025 .operands = &[_]Operand{7548 .operands = &.{
7026 .{ .kind = .IdResultType, .quantifier = .required },7549 .{ .kind = .id_result_type, .quantifier = .required },
7027 .{ .kind = .IdResult, .quantifier = .required },7550 .{ .kind = .id_result, .quantifier = .required },
7028 .{ .kind = .IdRef, .quantifier = .required },7551 .{ .kind = .id_ref, .quantifier = .required },
7029 .{ .kind = .IdRef, .quantifier = .required },7552 .{ .kind = .id_ref, .quantifier = .required },
7030 },7553 },
7031 },7554 },
7032 .{7555 .{
7033 .name = "OpBitwiseXor",7556 .name = "OpBitwiseXor",
7034 .opcode = 198,7557 .opcode = 198,
7035 .operands = &[_]Operand{7558 .operands = &.{
7036 .{ .kind = .IdResultType, .quantifier = .required },7559 .{ .kind = .id_result_type, .quantifier = .required },
7037 .{ .kind = .IdResult, .quantifier = .required },7560 .{ .kind = .id_result, .quantifier = .required },
7038 .{ .kind = .IdRef, .quantifier = .required },7561 .{ .kind = .id_ref, .quantifier = .required },
7039 .{ .kind = .IdRef, .quantifier = .required },7562 .{ .kind = .id_ref, .quantifier = .required },
7040 },7563 },
7041 },7564 },
7042 .{7565 .{
7043 .name = "OpBitwiseAnd",7566 .name = "OpBitwiseAnd",
7044 .opcode = 199,7567 .opcode = 199,
7045 .operands = &[_]Operand{7568 .operands = &.{
7046 .{ .kind = .IdResultType, .quantifier = .required },7569 .{ .kind = .id_result_type, .quantifier = .required },
7047 .{ .kind = .IdResult, .quantifier = .required },7570 .{ .kind = .id_result, .quantifier = .required },
7048 .{ .kind = .IdRef, .quantifier = .required },7571 .{ .kind = .id_ref, .quantifier = .required },
7049 .{ .kind = .IdRef, .quantifier = .required },7572 .{ .kind = .id_ref, .quantifier = .required },
7050 },7573 },
7051 },7574 },
7052 .{7575 .{
7053 .name = "OpNot",7576 .name = "OpNot",
7054 .opcode = 200,7577 .opcode = 200,
7055 .operands = &[_]Operand{7578 .operands = &.{
7056 .{ .kind = .IdResultType, .quantifier = .required },7579 .{ .kind = .id_result_type, .quantifier = .required },
7057 .{ .kind = .IdResult, .quantifier = .required },7580 .{ .kind = .id_result, .quantifier = .required },
7058 .{ .kind = .IdRef, .quantifier = .required },7581 .{ .kind = .id_ref, .quantifier = .required },
7059 },7582 },
7060 },7583 },
7061 .{7584 .{
7062 .name = "OpBitFieldInsert",7585 .name = "OpBitFieldInsert",
7063 .opcode = 201,7586 .opcode = 201,
7064 .operands = &[_]Operand{7587 .operands = &.{
7065 .{ .kind = .IdResultType, .quantifier = .required },7588 .{ .kind = .id_result_type, .quantifier = .required },
7066 .{ .kind = .IdResult, .quantifier = .required },7589 .{ .kind = .id_result, .quantifier = .required },
7067 .{ .kind = .IdRef, .quantifier = .required },7590 .{ .kind = .id_ref, .quantifier = .required },
7068 .{ .kind = .IdRef, .quantifier = .required },7591 .{ .kind = .id_ref, .quantifier = .required },
7069 .{ .kind = .IdRef, .quantifier = .required },7592 .{ .kind = .id_ref, .quantifier = .required },
7070 .{ .kind = .IdRef, .quantifier = .required },7593 .{ .kind = .id_ref, .quantifier = .required },
7071 },7594 },
7072 },7595 },
7073 .{7596 .{
7074 .name = "OpBitFieldSExtract",7597 .name = "OpBitFieldSExtract",
7075 .opcode = 202,7598 .opcode = 202,
7076 .operands = &[_]Operand{7599 .operands = &.{
7077 .{ .kind = .IdResultType, .quantifier = .required },7600 .{ .kind = .id_result_type, .quantifier = .required },
7078 .{ .kind = .IdResult, .quantifier = .required },7601 .{ .kind = .id_result, .quantifier = .required },
7079 .{ .kind = .IdRef, .quantifier = .required },7602 .{ .kind = .id_ref, .quantifier = .required },
7080 .{ .kind = .IdRef, .quantifier = .required },7603 .{ .kind = .id_ref, .quantifier = .required },
7081 .{ .kind = .IdRef, .quantifier = .required },7604 .{ .kind = .id_ref, .quantifier = .required },
7082 },7605 },
7083 },7606 },
7084 .{7607 .{
7085 .name = "OpBitFieldUExtract",7608 .name = "OpBitFieldUExtract",
7086 .opcode = 203,7609 .opcode = 203,
7087 .operands = &[_]Operand{7610 .operands = &.{
7088 .{ .kind = .IdResultType, .quantifier = .required },7611 .{ .kind = .id_result_type, .quantifier = .required },
7089 .{ .kind = .IdResult, .quantifier = .required },7612 .{ .kind = .id_result, .quantifier = .required },
7090 .{ .kind = .IdRef, .quantifier = .required },7613 .{ .kind = .id_ref, .quantifier = .required },
7091 .{ .kind = .IdRef, .quantifier = .required },7614 .{ .kind = .id_ref, .quantifier = .required },
7092 .{ .kind = .IdRef, .quantifier = .required },7615 .{ .kind = .id_ref, .quantifier = .required },
7093 },7616 },
7094 },7617 },
7095 .{7618 .{
7096 .name = "OpBitReverse",7619 .name = "OpBitReverse",
7097 .opcode = 204,7620 .opcode = 204,
7098 .operands = &[_]Operand{7621 .operands = &.{
7099 .{ .kind = .IdResultType, .quantifier = .required },7622 .{ .kind = .id_result_type, .quantifier = .required },
7100 .{ .kind = .IdResult, .quantifier = .required },7623 .{ .kind = .id_result, .quantifier = .required },
7101 .{ .kind = .IdRef, .quantifier = .required },7624 .{ .kind = .id_ref, .quantifier = .required },
7102 },7625 },
7103 },7626 },
7104 .{7627 .{
7105 .name = "OpBitCount",7628 .name = "OpBitCount",
7106 .opcode = 205,7629 .opcode = 205,
7107 .operands = &[_]Operand{7630 .operands = &.{
7108 .{ .kind = .IdResultType, .quantifier = .required },7631 .{ .kind = .id_result_type, .quantifier = .required },
7109 .{ .kind = .IdResult, .quantifier = .required },7632 .{ .kind = .id_result, .quantifier = .required },
7110 .{ .kind = .IdRef, .quantifier = .required },7633 .{ .kind = .id_ref, .quantifier = .required },
7111 },7634 },
7112 },7635 },
7113 .{7636 .{
7114 .name = "OpDPdx",7637 .name = "OpDPdx",
7115 .opcode = 207,7638 .opcode = 207,
7116 .operands = &[_]Operand{7639 .operands = &.{
7117 .{ .kind = .IdResultType, .quantifier = .required },7640 .{ .kind = .id_result_type, .quantifier = .required },
7118 .{ .kind = .IdResult, .quantifier = .required },7641 .{ .kind = .id_result, .quantifier = .required },
7119 .{ .kind = .IdRef, .quantifier = .required },7642 .{ .kind = .id_ref, .quantifier = .required },
7120 },7643 },
7121 },7644 },
7122 .{7645 .{
7123 .name = "OpDPdy",7646 .name = "OpDPdy",
7124 .opcode = 208,7647 .opcode = 208,
7125 .operands = &[_]Operand{7648 .operands = &.{
7126 .{ .kind = .IdResultType, .quantifier = .required },7649 .{ .kind = .id_result_type, .quantifier = .required },
7127 .{ .kind = .IdResult, .quantifier = .required },7650 .{ .kind = .id_result, .quantifier = .required },
7128 .{ .kind = .IdRef, .quantifier = .required },7651 .{ .kind = .id_ref, .quantifier = .required },
7129 },7652 },
7130 },7653 },
7131 .{7654 .{
7132 .name = "OpFwidth",7655 .name = "OpFwidth",
7133 .opcode = 209,7656 .opcode = 209,
7134 .operands = &[_]Operand{7657 .operands = &.{
7135 .{ .kind = .IdResultType, .quantifier = .required },7658 .{ .kind = .id_result_type, .quantifier = .required },
7136 .{ .kind = .IdResult, .quantifier = .required },7659 .{ .kind = .id_result, .quantifier = .required },
7137 .{ .kind = .IdRef, .quantifier = .required },7660 .{ .kind = .id_ref, .quantifier = .required },
7138 },7661 },
7139 },7662 },
7140 .{7663 .{
7141 .name = "OpDPdxFine",7664 .name = "OpDPdxFine",
7142 .opcode = 210,7665 .opcode = 210,
7143 .operands = &[_]Operand{7666 .operands = &.{
7144 .{ .kind = .IdResultType, .quantifier = .required },7667 .{ .kind = .id_result_type, .quantifier = .required },
7145 .{ .kind = .IdResult, .quantifier = .required },7668 .{ .kind = .id_result, .quantifier = .required },
7146 .{ .kind = .IdRef, .quantifier = .required },7669 .{ .kind = .id_ref, .quantifier = .required },
7147 },7670 },
7148 },7671 },
7149 .{7672 .{
7150 .name = "OpDPdyFine",7673 .name = "OpDPdyFine",
7151 .opcode = 211,7674 .opcode = 211,
7152 .operands = &[_]Operand{7675 .operands = &.{
7153 .{ .kind = .IdResultType, .quantifier = .required },7676 .{ .kind = .id_result_type, .quantifier = .required },
7154 .{ .kind = .IdResult, .quantifier = .required },7677 .{ .kind = .id_result, .quantifier = .required },
7155 .{ .kind = .IdRef, .quantifier = .required },7678 .{ .kind = .id_ref, .quantifier = .required },
7156 },7679 },
7157 },7680 },
7158 .{7681 .{
7159 .name = "OpFwidthFine",7682 .name = "OpFwidthFine",
7160 .opcode = 212,7683 .opcode = 212,
7161 .operands = &[_]Operand{7684 .operands = &.{
7162 .{ .kind = .IdResultType, .quantifier = .required },7685 .{ .kind = .id_result_type, .quantifier = .required },
7163 .{ .kind = .IdResult, .quantifier = .required },7686 .{ .kind = .id_result, .quantifier = .required },
7164 .{ .kind = .IdRef, .quantifier = .required },7687 .{ .kind = .id_ref, .quantifier = .required },
7165 },7688 },
7166 },7689 },
7167 .{7690 .{
7168 .name = "OpDPdxCoarse",7691 .name = "OpDPdxCoarse",
7169 .opcode = 213,7692 .opcode = 213,
7170 .operands = &[_]Operand{7693 .operands = &.{
7171 .{ .kind = .IdResultType, .quantifier = .required },7694 .{ .kind = .id_result_type, .quantifier = .required },
7172 .{ .kind = .IdResult, .quantifier = .required },7695 .{ .kind = .id_result, .quantifier = .required },
7173 .{ .kind = .IdRef, .quantifier = .required },7696 .{ .kind = .id_ref, .quantifier = .required },
7174 },7697 },
7175 },7698 },
7176 .{7699 .{
7177 .name = "OpDPdyCoarse",7700 .name = "OpDPdyCoarse",
7178 .opcode = 214,7701 .opcode = 214,
7179 .operands = &[_]Operand{7702 .operands = &.{
7180 .{ .kind = .IdResultType, .quantifier = .required },7703 .{ .kind = .id_result_type, .quantifier = .required },
7181 .{ .kind = .IdResult, .quantifier = .required },7704 .{ .kind = .id_result, .quantifier = .required },
7182 .{ .kind = .IdRef, .quantifier = .required },7705 .{ .kind = .id_ref, .quantifier = .required },
7183 },7706 },
7184 },7707 },
7185 .{7708 .{
7186 .name = "OpFwidthCoarse",7709 .name = "OpFwidthCoarse",
7187 .opcode = 215,7710 .opcode = 215,
7188 .operands = &[_]Operand{7711 .operands = &.{
7189 .{ .kind = .IdResultType, .quantifier = .required },7712 .{ .kind = .id_result_type, .quantifier = .required },
7190 .{ .kind = .IdResult, .quantifier = .required },7713 .{ .kind = .id_result, .quantifier = .required },
7191 .{ .kind = .IdRef, .quantifier = .required },7714 .{ .kind = .id_ref, .quantifier = .required },
7192 },7715 },
7193 },7716 },
7194 .{7717 .{
7195 .name = "OpEmitVertex",7718 .name = "OpEmitVertex",
7196 .opcode = 218,7719 .opcode = 218,
7197 .operands = &[_]Operand{},7720 .operands = &.{},
7198 },7721 },
7199 .{7722 .{
7200 .name = "OpEndPrimitive",7723 .name = "OpEndPrimitive",
7201 .opcode = 219,7724 .opcode = 219,
7202 .operands = &[_]Operand{},7725 .operands = &.{},
7203 },7726 },
7204 .{7727 .{
7205 .name = "OpEmitStreamVertex",7728 .name = "OpEmitStreamVertex",
7206 .opcode = 220,7729 .opcode = 220,
7207 .operands = &[_]Operand{7730 .operands = &.{
7208 .{ .kind = .IdRef, .quantifier = .required },7731 .{ .kind = .id_ref, .quantifier = .required },
7209 },7732 },
7210 },7733 },
7211 .{7734 .{
7212 .name = "OpEndStreamPrimitive",7735 .name = "OpEndStreamPrimitive",
7213 .opcode = 221,7736 .opcode = 221,
7214 .operands = &[_]Operand{7737 .operands = &.{
7215 .{ .kind = .IdRef, .quantifier = .required },7738 .{ .kind = .id_ref, .quantifier = .required },
7216 },7739 },
7217 },7740 },
7218 .{7741 .{
7219 .name = "OpControlBarrier",7742 .name = "OpControlBarrier",
7220 .opcode = 224,7743 .opcode = 224,
7221 .operands = &[_]Operand{7744 .operands = &.{
7222 .{ .kind = .IdScope, .quantifier = .required },7745 .{ .kind = .id_scope, .quantifier = .required },
7223 .{ .kind = .IdScope, .quantifier = .required },7746 .{ .kind = .id_scope, .quantifier = .required },
7224 .{ .kind = .IdMemorySemantics, .quantifier = .required },7747 .{ .kind = .id_memory_semantics, .quantifier = .required },
7225 },7748 },
7226 },7749 },
7227 .{7750 .{
7228 .name = "OpMemoryBarrier",7751 .name = "OpMemoryBarrier",
7229 .opcode = 225,7752 .opcode = 225,
7230 .operands = &[_]Operand{7753 .operands = &.{
7231 .{ .kind = .IdScope, .quantifier = .required },7754 .{ .kind = .id_scope, .quantifier = .required },
7232 .{ .kind = .IdMemorySemantics, .quantifier = .required },7755 .{ .kind = .id_memory_semantics, .quantifier = .required },
7233 },7756 },
7234 },7757 },
7235 .{7758 .{
7236 .name = "OpAtomicLoad",7759 .name = "OpAtomicLoad",
7237 .opcode = 227,7760 .opcode = 227,
7238 .operands = &[_]Operand{7761 .operands = &.{
7239 .{ .kind = .IdResultType, .quantifier = .required },7762 .{ .kind = .id_result_type, .quantifier = .required },
7240 .{ .kind = .IdResult, .quantifier = .required },7763 .{ .kind = .id_result, .quantifier = .required },
7241 .{ .kind = .IdRef, .quantifier = .required },7764 .{ .kind = .id_ref, .quantifier = .required },
7242 .{ .kind = .IdScope, .quantifier = .required },7765 .{ .kind = .id_scope, .quantifier = .required },
7243 .{ .kind = .IdMemorySemantics, .quantifier = .required },7766 .{ .kind = .id_memory_semantics, .quantifier = .required },
7244 },7767 },
7245 },7768 },
7246 .{7769 .{
7247 .name = "OpAtomicStore",7770 .name = "OpAtomicStore",
7248 .opcode = 228,7771 .opcode = 228,
7249 .operands = &[_]Operand{7772 .operands = &.{
7250 .{ .kind = .IdRef, .quantifier = .required },7773 .{ .kind = .id_ref, .quantifier = .required },
7251 .{ .kind = .IdScope, .quantifier = .required },7774 .{ .kind = .id_scope, .quantifier = .required },
7252 .{ .kind = .IdMemorySemantics, .quantifier = .required },7775 .{ .kind = .id_memory_semantics, .quantifier = .required },
7253 .{ .kind = .IdRef, .quantifier = .required },7776 .{ .kind = .id_ref, .quantifier = .required },
7254 },7777 },
7255 },7778 },
7256 .{7779 .{
7257 .name = "OpAtomicExchange",7780 .name = "OpAtomicExchange",
7258 .opcode = 229,7781 .opcode = 229,
7259 .operands = &[_]Operand{7782 .operands = &.{
7260 .{ .kind = .IdResultType, .quantifier = .required },7783 .{ .kind = .id_result_type, .quantifier = .required },
7261 .{ .kind = .IdResult, .quantifier = .required },7784 .{ .kind = .id_result, .quantifier = .required },
7262 .{ .kind = .IdRef, .quantifier = .required },7785 .{ .kind = .id_ref, .quantifier = .required },
7263 .{ .kind = .IdScope, .quantifier = .required },7786 .{ .kind = .id_scope, .quantifier = .required },
7264 .{ .kind = .IdMemorySemantics, .quantifier = .required },7787 .{ .kind = .id_memory_semantics, .quantifier = .required },
7265 .{ .kind = .IdRef, .quantifier = .required },7788 .{ .kind = .id_ref, .quantifier = .required },
7266 },7789 },
7267 },7790 },
7268 .{7791 .{
7269 .name = "OpAtomicCompareExchange",7792 .name = "OpAtomicCompareExchange",
7270 .opcode = 230,7793 .opcode = 230,
7271 .operands = &[_]Operand{7794 .operands = &.{
7272 .{ .kind = .IdResultType, .quantifier = .required },7795 .{ .kind = .id_result_type, .quantifier = .required },
7273 .{ .kind = .IdResult, .quantifier = .required },7796 .{ .kind = .id_result, .quantifier = .required },
7274 .{ .kind = .IdRef, .quantifier = .required },7797 .{ .kind = .id_ref, .quantifier = .required },
7275 .{ .kind = .IdScope, .quantifier = .required },7798 .{ .kind = .id_scope, .quantifier = .required },
7276 .{ .kind = .IdMemorySemantics, .quantifier = .required },7799 .{ .kind = .id_memory_semantics, .quantifier = .required },
7277 .{ .kind = .IdMemorySemantics, .quantifier = .required },7800 .{ .kind = .id_memory_semantics, .quantifier = .required },
7278 .{ .kind = .IdRef, .quantifier = .required },7801 .{ .kind = .id_ref, .quantifier = .required },
7279 .{ .kind = .IdRef, .quantifier = .required },7802 .{ .kind = .id_ref, .quantifier = .required },
7280 },7803 },
7281 },7804 },
7282 .{7805 .{
7283 .name = "OpAtomicCompareExchangeWeak",7806 .name = "OpAtomicCompareExchangeWeak",
7284 .opcode = 231,7807 .opcode = 231,
7285 .operands = &[_]Operand{7808 .operands = &.{
7286 .{ .kind = .IdResultType, .quantifier = .required },7809 .{ .kind = .id_result_type, .quantifier = .required },
7287 .{ .kind = .IdResult, .quantifier = .required },7810 .{ .kind = .id_result, .quantifier = .required },
7288 .{ .kind = .IdRef, .quantifier = .required },7811 .{ .kind = .id_ref, .quantifier = .required },
7289 .{ .kind = .IdScope, .quantifier = .required },7812 .{ .kind = .id_scope, .quantifier = .required },
7290 .{ .kind = .IdMemorySemantics, .quantifier = .required },7813 .{ .kind = .id_memory_semantics, .quantifier = .required },
7291 .{ .kind = .IdMemorySemantics, .quantifier = .required },7814 .{ .kind = .id_memory_semantics, .quantifier = .required },
7292 .{ .kind = .IdRef, .quantifier = .required },7815 .{ .kind = .id_ref, .quantifier = .required },
7293 .{ .kind = .IdRef, .quantifier = .required },7816 .{ .kind = .id_ref, .quantifier = .required },
7294 },7817 },
7295 },7818 },
7296 .{7819 .{
7297 .name = "OpAtomicIIncrement",7820 .name = "OpAtomicIIncrement",
7298 .opcode = 232,7821 .opcode = 232,
7299 .operands = &[_]Operand{7822 .operands = &.{
7300 .{ .kind = .IdResultType, .quantifier = .required },7823 .{ .kind = .id_result_type, .quantifier = .required },
7301 .{ .kind = .IdResult, .quantifier = .required },7824 .{ .kind = .id_result, .quantifier = .required },
7302 .{ .kind = .IdRef, .quantifier = .required },7825 .{ .kind = .id_ref, .quantifier = .required },
7303 .{ .kind = .IdScope, .quantifier = .required },7826 .{ .kind = .id_scope, .quantifier = .required },
7304 .{ .kind = .IdMemorySemantics, .quantifier = .required },7827 .{ .kind = .id_memory_semantics, .quantifier = .required },
7305 },7828 },
7306 },7829 },
7307 .{7830 .{
7308 .name = "OpAtomicIDecrement",7831 .name = "OpAtomicIDecrement",
7309 .opcode = 233,7832 .opcode = 233,
7310 .operands = &[_]Operand{7833 .operands = &.{
7311 .{ .kind = .IdResultType, .quantifier = .required },7834 .{ .kind = .id_result_type, .quantifier = .required },
7312 .{ .kind = .IdResult, .quantifier = .required },7835 .{ .kind = .id_result, .quantifier = .required },
7313 .{ .kind = .IdRef, .quantifier = .required },7836 .{ .kind = .id_ref, .quantifier = .required },
7314 .{ .kind = .IdScope, .quantifier = .required },7837 .{ .kind = .id_scope, .quantifier = .required },
7315 .{ .kind = .IdMemorySemantics, .quantifier = .required },7838 .{ .kind = .id_memory_semantics, .quantifier = .required },
7316 },7839 },
7317 },7840 },
7318 .{7841 .{
7319 .name = "OpAtomicIAdd",7842 .name = "OpAtomicIAdd",
7320 .opcode = 234,7843 .opcode = 234,
7321 .operands = &[_]Operand{7844 .operands = &.{
7322 .{ .kind = .IdResultType, .quantifier = .required },7845 .{ .kind = .id_result_type, .quantifier = .required },
7323 .{ .kind = .IdResult, .quantifier = .required },7846 .{ .kind = .id_result, .quantifier = .required },
7324 .{ .kind = .IdRef, .quantifier = .required },7847 .{ .kind = .id_ref, .quantifier = .required },
7325 .{ .kind = .IdScope, .quantifier = .required },7848 .{ .kind = .id_scope, .quantifier = .required },
7326 .{ .kind = .IdMemorySemantics, .quantifier = .required },7849 .{ .kind = .id_memory_semantics, .quantifier = .required },
7327 .{ .kind = .IdRef, .quantifier = .required },7850 .{ .kind = .id_ref, .quantifier = .required },
7328 },7851 },
7329 },7852 },
7330 .{7853 .{
7331 .name = "OpAtomicISub",7854 .name = "OpAtomicISub",
7332 .opcode = 235,7855 .opcode = 235,
7333 .operands = &[_]Operand{7856 .operands = &.{
7334 .{ .kind = .IdResultType, .quantifier = .required },7857 .{ .kind = .id_result_type, .quantifier = .required },
7335 .{ .kind = .IdResult, .quantifier = .required },7858 .{ .kind = .id_result, .quantifier = .required },
7336 .{ .kind = .IdRef, .quantifier = .required },7859 .{ .kind = .id_ref, .quantifier = .required },
7337 .{ .kind = .IdScope, .quantifier = .required },7860 .{ .kind = .id_scope, .quantifier = .required },
7338 .{ .kind = .IdMemorySemantics, .quantifier = .required },7861 .{ .kind = .id_memory_semantics, .quantifier = .required },
7339 .{ .kind = .IdRef, .quantifier = .required },7862 .{ .kind = .id_ref, .quantifier = .required },
7340 },7863 },
7341 },7864 },
7342 .{7865 .{
7343 .name = "OpAtomicSMin",7866 .name = "OpAtomicSMin",
7344 .opcode = 236,7867 .opcode = 236,
7345 .operands = &[_]Operand{7868 .operands = &.{
7346 .{ .kind = .IdResultType, .quantifier = .required },7869 .{ .kind = .id_result_type, .quantifier = .required },
7347 .{ .kind = .IdResult, .quantifier = .required },7870 .{ .kind = .id_result, .quantifier = .required },
7348 .{ .kind = .IdRef, .quantifier = .required },7871 .{ .kind = .id_ref, .quantifier = .required },
7349 .{ .kind = .IdScope, .quantifier = .required },7872 .{ .kind = .id_scope, .quantifier = .required },
7350 .{ .kind = .IdMemorySemantics, .quantifier = .required },7873 .{ .kind = .id_memory_semantics, .quantifier = .required },
7351 .{ .kind = .IdRef, .quantifier = .required },7874 .{ .kind = .id_ref, .quantifier = .required },
7352 },7875 },
7353 },7876 },
7354 .{7877 .{
7355 .name = "OpAtomicUMin",7878 .name = "OpAtomicUMin",
7356 .opcode = 237,7879 .opcode = 237,
7357 .operands = &[_]Operand{7880 .operands = &.{
7358 .{ .kind = .IdResultType, .quantifier = .required },7881 .{ .kind = .id_result_type, .quantifier = .required },
7359 .{ .kind = .IdResult, .quantifier = .required },7882 .{ .kind = .id_result, .quantifier = .required },
7360 .{ .kind = .IdRef, .quantifier = .required },7883 .{ .kind = .id_ref, .quantifier = .required },
7361 .{ .kind = .IdScope, .quantifier = .required },7884 .{ .kind = .id_scope, .quantifier = .required },
7362 .{ .kind = .IdMemorySemantics, .quantifier = .required },7885 .{ .kind = .id_memory_semantics, .quantifier = .required },
7363 .{ .kind = .IdRef, .quantifier = .required },7886 .{ .kind = .id_ref, .quantifier = .required },
7364 },7887 },
7365 },7888 },
7366 .{7889 .{
7367 .name = "OpAtomicSMax",7890 .name = "OpAtomicSMax",
7368 .opcode = 238,7891 .opcode = 238,
7369 .operands = &[_]Operand{7892 .operands = &.{
7370 .{ .kind = .IdResultType, .quantifier = .required },7893 .{ .kind = .id_result_type, .quantifier = .required },
7371 .{ .kind = .IdResult, .quantifier = .required },7894 .{ .kind = .id_result, .quantifier = .required },
7372 .{ .kind = .IdRef, .quantifier = .required },7895 .{ .kind = .id_ref, .quantifier = .required },
7373 .{ .kind = .IdScope, .quantifier = .required },7896 .{ .kind = .id_scope, .quantifier = .required },
7374 .{ .kind = .IdMemorySemantics, .quantifier = .required },7897 .{ .kind = .id_memory_semantics, .quantifier = .required },
7375 .{ .kind = .IdRef, .quantifier = .required },7898 .{ .kind = .id_ref, .quantifier = .required },
7376 },7899 },
7377 },7900 },
7378 .{7901 .{
7379 .name = "OpAtomicUMax",7902 .name = "OpAtomicUMax",
7380 .opcode = 239,7903 .opcode = 239,
7381 .operands = &[_]Operand{7904 .operands = &.{
7382 .{ .kind = .IdResultType, .quantifier = .required },7905 .{ .kind = .id_result_type, .quantifier = .required },
7383 .{ .kind = .IdResult, .quantifier = .required },7906 .{ .kind = .id_result, .quantifier = .required },
7384 .{ .kind = .IdRef, .quantifier = .required },7907 .{ .kind = .id_ref, .quantifier = .required },
7385 .{ .kind = .IdScope, .quantifier = .required },7908 .{ .kind = .id_scope, .quantifier = .required },
7386 .{ .kind = .IdMemorySemantics, .quantifier = .required },7909 .{ .kind = .id_memory_semantics, .quantifier = .required },
7387 .{ .kind = .IdRef, .quantifier = .required },7910 .{ .kind = .id_ref, .quantifier = .required },
7388 },7911 },
7389 },7912 },
7390 .{7913 .{
7391 .name = "OpAtomicAnd",7914 .name = "OpAtomicAnd",
7392 .opcode = 240,7915 .opcode = 240,
7393 .operands = &[_]Operand{7916 .operands = &.{
7394 .{ .kind = .IdResultType, .quantifier = .required },7917 .{ .kind = .id_result_type, .quantifier = .required },
7395 .{ .kind = .IdResult, .quantifier = .required },7918 .{ .kind = .id_result, .quantifier = .required },
7396 .{ .kind = .IdRef, .quantifier = .required },7919 .{ .kind = .id_ref, .quantifier = .required },
7397 .{ .kind = .IdScope, .quantifier = .required },7920 .{ .kind = .id_scope, .quantifier = .required },
7398 .{ .kind = .IdMemorySemantics, .quantifier = .required },7921 .{ .kind = .id_memory_semantics, .quantifier = .required },
7399 .{ .kind = .IdRef, .quantifier = .required },7922 .{ .kind = .id_ref, .quantifier = .required },
7400 },7923 },
7401 },7924 },
7402 .{7925 .{
7403 .name = "OpAtomicOr",7926 .name = "OpAtomicOr",
7404 .opcode = 241,7927 .opcode = 241,
7405 .operands = &[_]Operand{7928 .operands = &.{
7406 .{ .kind = .IdResultType, .quantifier = .required },7929 .{ .kind = .id_result_type, .quantifier = .required },
7407 .{ .kind = .IdResult, .quantifier = .required },7930 .{ .kind = .id_result, .quantifier = .required },
7408 .{ .kind = .IdRef, .quantifier = .required },7931 .{ .kind = .id_ref, .quantifier = .required },
7409 .{ .kind = .IdScope, .quantifier = .required },7932 .{ .kind = .id_scope, .quantifier = .required },
7410 .{ .kind = .IdMemorySemantics, .quantifier = .required },7933 .{ .kind = .id_memory_semantics, .quantifier = .required },
7411 .{ .kind = .IdRef, .quantifier = .required },7934 .{ .kind = .id_ref, .quantifier = .required },
7412 },7935 },
7413 },7936 },
7414 .{7937 .{
7415 .name = "OpAtomicXor",7938 .name = "OpAtomicXor",
7416 .opcode = 242,7939 .opcode = 242,
7417 .operands = &[_]Operand{7940 .operands = &.{
7418 .{ .kind = .IdResultType, .quantifier = .required },7941 .{ .kind = .id_result_type, .quantifier = .required },
7419 .{ .kind = .IdResult, .quantifier = .required },7942 .{ .kind = .id_result, .quantifier = .required },
7420 .{ .kind = .IdRef, .quantifier = .required },7943 .{ .kind = .id_ref, .quantifier = .required },
7421 .{ .kind = .IdScope, .quantifier = .required },7944 .{ .kind = .id_scope, .quantifier = .required },
7422 .{ .kind = .IdMemorySemantics, .quantifier = .required },7945 .{ .kind = .id_memory_semantics, .quantifier = .required },
7423 .{ .kind = .IdRef, .quantifier = .required },7946 .{ .kind = .id_ref, .quantifier = .required },
7424 },7947 },
7425 },7948 },
7426 .{7949 .{
7427 .name = "OpPhi",7950 .name = "OpPhi",
7428 .opcode = 245,7951 .opcode = 245,
7429 .operands = &[_]Operand{7952 .operands = &.{
7430 .{ .kind = .IdResultType, .quantifier = .required },7953 .{ .kind = .id_result_type, .quantifier = .required },
7431 .{ .kind = .IdResult, .quantifier = .required },7954 .{ .kind = .id_result, .quantifier = .required },
7432 .{ .kind = .PairIdRefIdRef, .quantifier = .variadic },7955 .{ .kind = .pair_id_ref_id_ref, .quantifier = .variadic },
7433 },7956 },
7434 },7957 },
7435 .{7958 .{
7436 .name = "OpLoopMerge",7959 .name = "OpLoopMerge",
7437 .opcode = 246,7960 .opcode = 246,
7438 .operands = &[_]Operand{7961 .operands = &.{
7439 .{ .kind = .IdRef, .quantifier = .required },7962 .{ .kind = .id_ref, .quantifier = .required },
7440 .{ .kind = .IdRef, .quantifier = .required },7963 .{ .kind = .id_ref, .quantifier = .required },
7441 .{ .kind = .LoopControl, .quantifier = .required },7964 .{ .kind = .loop_control, .quantifier = .required },
7442 },7965 },
7443 },7966 },
7444 .{7967 .{
7445 .name = "OpSelectionMerge",7968 .name = "OpSelectionMerge",
7446 .opcode = 247,7969 .opcode = 247,
7447 .operands = &[_]Operand{7970 .operands = &.{
7448 .{ .kind = .IdRef, .quantifier = .required },7971 .{ .kind = .id_ref, .quantifier = .required },
7449 .{ .kind = .SelectionControl, .quantifier = .required },7972 .{ .kind = .selection_control, .quantifier = .required },
7450 },7973 },
7451 },7974 },
7452 .{7975 .{
7453 .name = "OpLabel",7976 .name = "OpLabel",
7454 .opcode = 248,7977 .opcode = 248,
7455 .operands = &[_]Operand{7978 .operands = &.{
7456 .{ .kind = .IdResult, .quantifier = .required },7979 .{ .kind = .id_result, .quantifier = .required },
7457 },7980 },
7458 },7981 },
7459 .{7982 .{
7460 .name = "OpBranch",7983 .name = "OpBranch",
7461 .opcode = 249,7984 .opcode = 249,
7462 .operands = &[_]Operand{7985 .operands = &.{
7463 .{ .kind = .IdRef, .quantifier = .required },7986 .{ .kind = .id_ref, .quantifier = .required },
7464 },7987 },
7465 },7988 },
7466 .{7989 .{
7467 .name = "OpBranchConditional",7990 .name = "OpBranchConditional",
7468 .opcode = 250,7991 .opcode = 250,
7469 .operands = &[_]Operand{7992 .operands = &.{
7470 .{ .kind = .IdRef, .quantifier = .required },7993 .{ .kind = .id_ref, .quantifier = .required },
7471 .{ .kind = .IdRef, .quantifier = .required },7994 .{ .kind = .id_ref, .quantifier = .required },
7472 .{ .kind = .IdRef, .quantifier = .required },7995 .{ .kind = .id_ref, .quantifier = .required },
7473 .{ .kind = .LiteralInteger, .quantifier = .variadic },7996 .{ .kind = .literal_integer, .quantifier = .variadic },
7474 },7997 },
7475 },7998 },
7476 .{7999 .{
7477 .name = "OpSwitch",8000 .name = "OpSwitch",
7478 .opcode = 251,8001 .opcode = 251,
7479 .operands = &[_]Operand{8002 .operands = &.{
7480 .{ .kind = .IdRef, .quantifier = .required },8003 .{ .kind = .id_ref, .quantifier = .required },
7481 .{ .kind = .IdRef, .quantifier = .required },8004 .{ .kind = .id_ref, .quantifier = .required },
7482 .{ .kind = .PairLiteralIntegerIdRef, .quantifier = .variadic },8005 .{ .kind = .pair_literal_integer_id_ref, .quantifier = .variadic },
7483 },8006 },
7484 },8007 },
7485 .{8008 .{
7486 .name = "OpKill",8009 .name = "OpKill",
7487 .opcode = 252,8010 .opcode = 252,
7488 .operands = &[_]Operand{},8011 .operands = &.{},
7489 },8012 },
7490 .{8013 .{
7491 .name = "OpReturn",8014 .name = "OpReturn",
7492 .opcode = 253,8015 .opcode = 253,
7493 .operands = &[_]Operand{},8016 .operands = &.{},
7494 },8017 },
7495 .{8018 .{
7496 .name = "OpReturnValue",8019 .name = "OpReturnValue",
7497 .opcode = 254,8020 .opcode = 254,
7498 .operands = &[_]Operand{8021 .operands = &.{
7499 .{ .kind = .IdRef, .quantifier = .required },8022 .{ .kind = .id_ref, .quantifier = .required },
7500 },8023 },
7501 },8024 },
7502 .{8025 .{
7503 .name = "OpUnreachable",8026 .name = "OpUnreachable",
7504 .opcode = 255,8027 .opcode = 255,
7505 .operands = &[_]Operand{},8028 .operands = &.{},
7506 },8029 },
7507 .{8030 .{
7508 .name = "OpLifetimeStart",8031 .name = "OpLifetimeStart",
7509 .opcode = 256,8032 .opcode = 256,
7510 .operands = &[_]Operand{8033 .operands = &.{
7511 .{ .kind = .IdRef, .quantifier = .required },8034 .{ .kind = .id_ref, .quantifier = .required },
7512 .{ .kind = .LiteralInteger, .quantifier = .required },8035 .{ .kind = .literal_integer, .quantifier = .required },
7513 },8036 },
7514 },8037 },
7515 .{8038 .{
7516 .name = "OpLifetimeStop",8039 .name = "OpLifetimeStop",
7517 .opcode = 257,8040 .opcode = 257,
7518 .operands = &[_]Operand{8041 .operands = &.{
7519 .{ .kind = .IdRef, .quantifier = .required },8042 .{ .kind = .id_ref, .quantifier = .required },
7520 .{ .kind = .LiteralInteger, .quantifier = .required },8043 .{ .kind = .literal_integer, .quantifier = .required },
7521 },8044 },
7522 },8045 },
7523 .{8046 .{
7524 .name = "OpGroupAsyncCopy",8047 .name = "OpGroupAsyncCopy",
7525 .opcode = 259,8048 .opcode = 259,
7526 .operands = &[_]Operand{8049 .operands = &.{
7527 .{ .kind = .IdResultType, .quantifier = .required },8050 .{ .kind = .id_result_type, .quantifier = .required },
7528 .{ .kind = .IdResult, .quantifier = .required },8051 .{ .kind = .id_result, .quantifier = .required },
7529 .{ .kind = .IdScope, .quantifier = .required },8052 .{ .kind = .id_scope, .quantifier = .required },
7530 .{ .kind = .IdRef, .quantifier = .required },8053 .{ .kind = .id_ref, .quantifier = .required },
7531 .{ .kind = .IdRef, .quantifier = .required },8054 .{ .kind = .id_ref, .quantifier = .required },
7532 .{ .kind = .IdRef, .quantifier = .required },8055 .{ .kind = .id_ref, .quantifier = .required },
7533 .{ .kind = .IdRef, .quantifier = .required },8056 .{ .kind = .id_ref, .quantifier = .required },
7534 .{ .kind = .IdRef, .quantifier = .required },8057 .{ .kind = .id_ref, .quantifier = .required },
7535 },8058 },
7536 },8059 },
7537 .{8060 .{
7538 .name = "OpGroupWaitEvents",8061 .name = "OpGroupWaitEvents",
7539 .opcode = 260,8062 .opcode = 260,
7540 .operands = &[_]Operand{8063 .operands = &.{
7541 .{ .kind = .IdScope, .quantifier = .required },8064 .{ .kind = .id_scope, .quantifier = .required },
7542 .{ .kind = .IdRef, .quantifier = .required },8065 .{ .kind = .id_ref, .quantifier = .required },
7543 .{ .kind = .IdRef, .quantifier = .required },8066 .{ .kind = .id_ref, .quantifier = .required },
7544 },8067 },
7545 },8068 },
7546 .{8069 .{
7547 .name = "OpGroupAll",8070 .name = "OpGroupAll",
7548 .opcode = 261,8071 .opcode = 261,
7549 .operands = &[_]Operand{8072 .operands = &.{
7550 .{ .kind = .IdResultType, .quantifier = .required },8073 .{ .kind = .id_result_type, .quantifier = .required },
7551 .{ .kind = .IdResult, .quantifier = .required },8074 .{ .kind = .id_result, .quantifier = .required },
7552 .{ .kind = .IdScope, .quantifier = .required },8075 .{ .kind = .id_scope, .quantifier = .required },
7553 .{ .kind = .IdRef, .quantifier = .required },8076 .{ .kind = .id_ref, .quantifier = .required },
7554 },8077 },
7555 },8078 },
7556 .{8079 .{
7557 .name = "OpGroupAny",8080 .name = "OpGroupAny",
7558 .opcode = 262,8081 .opcode = 262,
7559 .operands = &[_]Operand{8082 .operands = &.{
7560 .{ .kind = .IdResultType, .quantifier = .required },8083 .{ .kind = .id_result_type, .quantifier = .required },
7561 .{ .kind = .IdResult, .quantifier = .required },8084 .{ .kind = .id_result, .quantifier = .required },
7562 .{ .kind = .IdScope, .quantifier = .required },8085 .{ .kind = .id_scope, .quantifier = .required },
7563 .{ .kind = .IdRef, .quantifier = .required },8086 .{ .kind = .id_ref, .quantifier = .required },
7564 },8087 },
7565 },8088 },
7566 .{8089 .{
7567 .name = "OpGroupBroadcast",8090 .name = "OpGroupBroadcast",
7568 .opcode = 263,8091 .opcode = 263,
7569 .operands = &[_]Operand{8092 .operands = &.{
7570 .{ .kind = .IdResultType, .quantifier = .required },8093 .{ .kind = .id_result_type, .quantifier = .required },
7571 .{ .kind = .IdResult, .quantifier = .required },8094 .{ .kind = .id_result, .quantifier = .required },
7572 .{ .kind = .IdScope, .quantifier = .required },8095 .{ .kind = .id_scope, .quantifier = .required },
7573 .{ .kind = .IdRef, .quantifier = .required },8096 .{ .kind = .id_ref, .quantifier = .required },
7574 .{ .kind = .IdRef, .quantifier = .required },8097 .{ .kind = .id_ref, .quantifier = .required },
7575 },8098 },
7576 },8099 },
7577 .{8100 .{
7578 .name = "OpGroupIAdd",8101 .name = "OpGroupIAdd",
7579 .opcode = 264,8102 .opcode = 264,
7580 .operands = &[_]Operand{8103 .operands = &.{
7581 .{ .kind = .IdResultType, .quantifier = .required },8104 .{ .kind = .id_result_type, .quantifier = .required },
7582 .{ .kind = .IdResult, .quantifier = .required },8105 .{ .kind = .id_result, .quantifier = .required },
7583 .{ .kind = .IdScope, .quantifier = .required },8106 .{ .kind = .id_scope, .quantifier = .required },
7584 .{ .kind = .GroupOperation, .quantifier = .required },8107 .{ .kind = .group_operation, .quantifier = .required },
7585 .{ .kind = .IdRef, .quantifier = .required },8108 .{ .kind = .id_ref, .quantifier = .required },
7586 },8109 },
7587 },8110 },
7588 .{8111 .{
7589 .name = "OpGroupFAdd",8112 .name = "OpGroupFAdd",
7590 .opcode = 265,8113 .opcode = 265,
7591 .operands = &[_]Operand{8114 .operands = &.{
7592 .{ .kind = .IdResultType, .quantifier = .required },8115 .{ .kind = .id_result_type, .quantifier = .required },
7593 .{ .kind = .IdResult, .quantifier = .required },8116 .{ .kind = .id_result, .quantifier = .required },
7594 .{ .kind = .IdScope, .quantifier = .required },8117 .{ .kind = .id_scope, .quantifier = .required },
7595 .{ .kind = .GroupOperation, .quantifier = .required },8118 .{ .kind = .group_operation, .quantifier = .required },
7596 .{ .kind = .IdRef, .quantifier = .required },8119 .{ .kind = .id_ref, .quantifier = .required },
7597 },8120 },
7598 },8121 },
7599 .{8122 .{
7600 .name = "OpGroupFMin",8123 .name = "OpGroupFMin",
7601 .opcode = 266,8124 .opcode = 266,
7602 .operands = &[_]Operand{8125 .operands = &.{
7603 .{ .kind = .IdResultType, .quantifier = .required },8126 .{ .kind = .id_result_type, .quantifier = .required },
7604 .{ .kind = .IdResult, .quantifier = .required },8127 .{ .kind = .id_result, .quantifier = .required },
7605 .{ .kind = .IdScope, .quantifier = .required },8128 .{ .kind = .id_scope, .quantifier = .required },
7606 .{ .kind = .GroupOperation, .quantifier = .required },8129 .{ .kind = .group_operation, .quantifier = .required },
7607 .{ .kind = .IdRef, .quantifier = .required },8130 .{ .kind = .id_ref, .quantifier = .required },
7608 },8131 },
7609 },8132 },
7610 .{8133 .{
7611 .name = "OpGroupUMin",8134 .name = "OpGroupUMin",
7612 .opcode = 267,8135 .opcode = 267,
7613 .operands = &[_]Operand{8136 .operands = &.{
7614 .{ .kind = .IdResultType, .quantifier = .required },8137 .{ .kind = .id_result_type, .quantifier = .required },
7615 .{ .kind = .IdResult, .quantifier = .required },8138 .{ .kind = .id_result, .quantifier = .required },
7616 .{ .kind = .IdScope, .quantifier = .required },8139 .{ .kind = .id_scope, .quantifier = .required },
7617 .{ .kind = .GroupOperation, .quantifier = .required },8140 .{ .kind = .group_operation, .quantifier = .required },
7618 .{ .kind = .IdRef, .quantifier = .required },8141 .{ .kind = .id_ref, .quantifier = .required },
7619 },8142 },
7620 },8143 },
7621 .{8144 .{
7622 .name = "OpGroupSMin",8145 .name = "OpGroupSMin",
7623 .opcode = 268,8146 .opcode = 268,
7624 .operands = &[_]Operand{8147 .operands = &.{
7625 .{ .kind = .IdResultType, .quantifier = .required },8148 .{ .kind = .id_result_type, .quantifier = .required },
7626 .{ .kind = .IdResult, .quantifier = .required },8149 .{ .kind = .id_result, .quantifier = .required },
7627 .{ .kind = .IdScope, .quantifier = .required },8150 .{ .kind = .id_scope, .quantifier = .required },
7628 .{ .kind = .GroupOperation, .quantifier = .required },8151 .{ .kind = .group_operation, .quantifier = .required },
7629 .{ .kind = .IdRef, .quantifier = .required },8152 .{ .kind = .id_ref, .quantifier = .required },
7630 },8153 },
7631 },8154 },
7632 .{8155 .{
7633 .name = "OpGroupFMax",8156 .name = "OpGroupFMax",
7634 .opcode = 269,8157 .opcode = 269,
7635 .operands = &[_]Operand{8158 .operands = &.{
7636 .{ .kind = .IdResultType, .quantifier = .required },8159 .{ .kind = .id_result_type, .quantifier = .required },
7637 .{ .kind = .IdResult, .quantifier = .required },8160 .{ .kind = .id_result, .quantifier = .required },
7638 .{ .kind = .IdScope, .quantifier = .required },8161 .{ .kind = .id_scope, .quantifier = .required },
7639 .{ .kind = .GroupOperation, .quantifier = .required },8162 .{ .kind = .group_operation, .quantifier = .required },
7640 .{ .kind = .IdRef, .quantifier = .required },8163 .{ .kind = .id_ref, .quantifier = .required },
7641 },8164 },
7642 },8165 },
7643 .{8166 .{
7644 .name = "OpGroupUMax",8167 .name = "OpGroupUMax",
7645 .opcode = 270,8168 .opcode = 270,
7646 .operands = &[_]Operand{8169 .operands = &.{
7647 .{ .kind = .IdResultType, .quantifier = .required },8170 .{ .kind = .id_result_type, .quantifier = .required },
7648 .{ .kind = .IdResult, .quantifier = .required },8171 .{ .kind = .id_result, .quantifier = .required },
7649 .{ .kind = .IdScope, .quantifier = .required },8172 .{ .kind = .id_scope, .quantifier = .required },
7650 .{ .kind = .GroupOperation, .quantifier = .required },8173 .{ .kind = .group_operation, .quantifier = .required },
7651 .{ .kind = .IdRef, .quantifier = .required },8174 .{ .kind = .id_ref, .quantifier = .required },
7652 },8175 },
7653 },8176 },
7654 .{8177 .{
7655 .name = "OpGroupSMax",8178 .name = "OpGroupSMax",
7656 .opcode = 271,8179 .opcode = 271,
7657 .operands = &[_]Operand{8180 .operands = &.{
7658 .{ .kind = .IdResultType, .quantifier = .required },8181 .{ .kind = .id_result_type, .quantifier = .required },
7659 .{ .kind = .IdResult, .quantifier = .required },8182 .{ .kind = .id_result, .quantifier = .required },
7660 .{ .kind = .IdScope, .quantifier = .required },8183 .{ .kind = .id_scope, .quantifier = .required },
7661 .{ .kind = .GroupOperation, .quantifier = .required },8184 .{ .kind = .group_operation, .quantifier = .required },
7662 .{ .kind = .IdRef, .quantifier = .required },8185 .{ .kind = .id_ref, .quantifier = .required },
7663 },8186 },
7664 },8187 },
7665 .{8188 .{
7666 .name = "OpReadPipe",8189 .name = "OpReadPipe",
7667 .opcode = 274,8190 .opcode = 274,
7668 .operands = &[_]Operand{8191 .operands = &.{
7669 .{ .kind = .IdResultType, .quantifier = .required },8192 .{ .kind = .id_result_type, .quantifier = .required },
7670 .{ .kind = .IdResult, .quantifier = .required },8193 .{ .kind = .id_result, .quantifier = .required },
7671 .{ .kind = .IdRef, .quantifier = .required },8194 .{ .kind = .id_ref, .quantifier = .required },
7672 .{ .kind = .IdRef, .quantifier = .required },8195 .{ .kind = .id_ref, .quantifier = .required },
7673 .{ .kind = .IdRef, .quantifier = .required },8196 .{ .kind = .id_ref, .quantifier = .required },
7674 .{ .kind = .IdRef, .quantifier = .required },8197 .{ .kind = .id_ref, .quantifier = .required },
7675 },8198 },
7676 },8199 },
7677 .{8200 .{
7678 .name = "OpWritePipe",8201 .name = "OpWritePipe",
7679 .opcode = 275,8202 .opcode = 275,
7680 .operands = &[_]Operand{8203 .operands = &.{
7681 .{ .kind = .IdResultType, .quantifier = .required },8204 .{ .kind = .id_result_type, .quantifier = .required },
7682 .{ .kind = .IdResult, .quantifier = .required },8205 .{ .kind = .id_result, .quantifier = .required },
7683 .{ .kind = .IdRef, .quantifier = .required },8206 .{ .kind = .id_ref, .quantifier = .required },
7684 .{ .kind = .IdRef, .quantifier = .required },8207 .{ .kind = .id_ref, .quantifier = .required },
7685 .{ .kind = .IdRef, .quantifier = .required },8208 .{ .kind = .id_ref, .quantifier = .required },
7686 .{ .kind = .IdRef, .quantifier = .required },8209 .{ .kind = .id_ref, .quantifier = .required },
7687 },8210 },
7688 },8211 },
7689 .{8212 .{
7690 .name = "OpReservedReadPipe",8213 .name = "OpReservedReadPipe",
7691 .opcode = 276,8214 .opcode = 276,
7692 .operands = &[_]Operand{8215 .operands = &.{
7693 .{ .kind = .IdResultType, .quantifier = .required },8216 .{ .kind = .id_result_type, .quantifier = .required },
7694 .{ .kind = .IdResult, .quantifier = .required },8217 .{ .kind = .id_result, .quantifier = .required },
7695 .{ .kind = .IdRef, .quantifier = .required },8218 .{ .kind = .id_ref, .quantifier = .required },
7696 .{ .kind = .IdRef, .quantifier = .required },8219 .{ .kind = .id_ref, .quantifier = .required },
7697 .{ .kind = .IdRef, .quantifier = .required },8220 .{ .kind = .id_ref, .quantifier = .required },
7698 .{ .kind = .IdRef, .quantifier = .required },8221 .{ .kind = .id_ref, .quantifier = .required },
7699 .{ .kind = .IdRef, .quantifier = .required },8222 .{ .kind = .id_ref, .quantifier = .required },
7700 .{ .kind = .IdRef, .quantifier = .required },8223 .{ .kind = .id_ref, .quantifier = .required },
7701 },8224 },
7702 },8225 },
7703 .{8226 .{
7704 .name = "OpReservedWritePipe",8227 .name = "OpReservedWritePipe",
7705 .opcode = 277,8228 .opcode = 277,
7706 .operands = &[_]Operand{8229 .operands = &.{
7707 .{ .kind = .IdResultType, .quantifier = .required },8230 .{ .kind = .id_result_type, .quantifier = .required },
7708 .{ .kind = .IdResult, .quantifier = .required },8231 .{ .kind = .id_result, .quantifier = .required },
7709 .{ .kind = .IdRef, .quantifier = .required },8232 .{ .kind = .id_ref, .quantifier = .required },
7710 .{ .kind = .IdRef, .quantifier = .required },8233 .{ .kind = .id_ref, .quantifier = .required },
7711 .{ .kind = .IdRef, .quantifier = .required },8234 .{ .kind = .id_ref, .quantifier = .required },
7712 .{ .kind = .IdRef, .quantifier = .required },8235 .{ .kind = .id_ref, .quantifier = .required },
7713 .{ .kind = .IdRef, .quantifier = .required },8236 .{ .kind = .id_ref, .quantifier = .required },
7714 .{ .kind = .IdRef, .quantifier = .required },8237 .{ .kind = .id_ref, .quantifier = .required },
7715 },8238 },
7716 },8239 },
7717 .{8240 .{
7718 .name = "OpReserveReadPipePackets",8241 .name = "OpReserveReadPipePackets",
7719 .opcode = 278,8242 .opcode = 278,
7720 .operands = &[_]Operand{8243 .operands = &.{
7721 .{ .kind = .IdResultType, .quantifier = .required },8244 .{ .kind = .id_result_type, .quantifier = .required },
7722 .{ .kind = .IdResult, .quantifier = .required },8245 .{ .kind = .id_result, .quantifier = .required },
7723 .{ .kind = .IdRef, .quantifier = .required },8246 .{ .kind = .id_ref, .quantifier = .required },
7724 .{ .kind = .IdRef, .quantifier = .required },8247 .{ .kind = .id_ref, .quantifier = .required },
7725 .{ .kind = .IdRef, .quantifier = .required },8248 .{ .kind = .id_ref, .quantifier = .required },
7726 .{ .kind = .IdRef, .quantifier = .required },8249 .{ .kind = .id_ref, .quantifier = .required },
7727 },8250 },
7728 },8251 },
7729 .{8252 .{
7730 .name = "OpReserveWritePipePackets",8253 .name = "OpReserveWritePipePackets",
7731 .opcode = 279,8254 .opcode = 279,
7732 .operands = &[_]Operand{8255 .operands = &.{
7733 .{ .kind = .IdResultType, .quantifier = .required },8256 .{ .kind = .id_result_type, .quantifier = .required },
7734 .{ .kind = .IdResult, .quantifier = .required },8257 .{ .kind = .id_result, .quantifier = .required },
7735 .{ .kind = .IdRef, .quantifier = .required },8258 .{ .kind = .id_ref, .quantifier = .required },
7736 .{ .kind = .IdRef, .quantifier = .required },8259 .{ .kind = .id_ref, .quantifier = .required },
7737 .{ .kind = .IdRef, .quantifier = .required },8260 .{ .kind = .id_ref, .quantifier = .required },
7738 .{ .kind = .IdRef, .quantifier = .required },8261 .{ .kind = .id_ref, .quantifier = .required },
7739 },8262 },
7740 },8263 },
7741 .{8264 .{
7742 .name = "OpCommitReadPipe",8265 .name = "OpCommitReadPipe",
7743 .opcode = 280,8266 .opcode = 280,
7744 .operands = &[_]Operand{8267 .operands = &.{
7745 .{ .kind = .IdRef, .quantifier = .required },8268 .{ .kind = .id_ref, .quantifier = .required },
7746 .{ .kind = .IdRef, .quantifier = .required },8269 .{ .kind = .id_ref, .quantifier = .required },
7747 .{ .kind = .IdRef, .quantifier = .required },8270 .{ .kind = .id_ref, .quantifier = .required },
7748 .{ .kind = .IdRef, .quantifier = .required },8271 .{ .kind = .id_ref, .quantifier = .required },
7749 },8272 },
7750 },8273 },
7751 .{8274 .{
7752 .name = "OpCommitWritePipe",8275 .name = "OpCommitWritePipe",
7753 .opcode = 281,8276 .opcode = 281,
7754 .operands = &[_]Operand{8277 .operands = &.{
7755 .{ .kind = .IdRef, .quantifier = .required },8278 .{ .kind = .id_ref, .quantifier = .required },
7756 .{ .kind = .IdRef, .quantifier = .required },8279 .{ .kind = .id_ref, .quantifier = .required },
7757 .{ .kind = .IdRef, .quantifier = .required },8280 .{ .kind = .id_ref, .quantifier = .required },
7758 .{ .kind = .IdRef, .quantifier = .required },8281 .{ .kind = .id_ref, .quantifier = .required },
7759 },8282 },
7760 },8283 },
7761 .{8284 .{
7762 .name = "OpIsValidReserveId",8285 .name = "OpIsValidReserveId",
7763 .opcode = 282,8286 .opcode = 282,
7764 .operands = &[_]Operand{8287 .operands = &.{
7765 .{ .kind = .IdResultType, .quantifier = .required },8288 .{ .kind = .id_result_type, .quantifier = .required },
7766 .{ .kind = .IdResult, .quantifier = .required },8289 .{ .kind = .id_result, .quantifier = .required },
7767 .{ .kind = .IdRef, .quantifier = .required },8290 .{ .kind = .id_ref, .quantifier = .required },
7768 },8291 },
7769 },8292 },
7770 .{8293 .{
7771 .name = "OpGetNumPipePackets",8294 .name = "OpGetNumPipePackets",
7772 .opcode = 283,8295 .opcode = 283,
7773 .operands = &[_]Operand{8296 .operands = &.{
7774 .{ .kind = .IdResultType, .quantifier = .required },8297 .{ .kind = .id_result_type, .quantifier = .required },
7775 .{ .kind = .IdResult, .quantifier = .required },8298 .{ .kind = .id_result, .quantifier = .required },
7776 .{ .kind = .IdRef, .quantifier = .required },8299 .{ .kind = .id_ref, .quantifier = .required },
7777 .{ .kind = .IdRef, .quantifier = .required },8300 .{ .kind = .id_ref, .quantifier = .required },
7778 .{ .kind = .IdRef, .quantifier = .required },8301 .{ .kind = .id_ref, .quantifier = .required },
7779 },8302 },
7780 },8303 },
7781 .{8304 .{
7782 .name = "OpGetMaxPipePackets",8305 .name = "OpGetMaxPipePackets",
7783 .opcode = 284,8306 .opcode = 284,
7784 .operands = &[_]Operand{8307 .operands = &.{
7785 .{ .kind = .IdResultType, .quantifier = .required },8308 .{ .kind = .id_result_type, .quantifier = .required },
7786 .{ .kind = .IdResult, .quantifier = .required },8309 .{ .kind = .id_result, .quantifier = .required },
7787 .{ .kind = .IdRef, .quantifier = .required },8310 .{ .kind = .id_ref, .quantifier = .required },
7788 .{ .kind = .IdRef, .quantifier = .required },8311 .{ .kind = .id_ref, .quantifier = .required },
7789 .{ .kind = .IdRef, .quantifier = .required },8312 .{ .kind = .id_ref, .quantifier = .required },
7790 },8313 },
7791 },8314 },
7792 .{8315 .{
7793 .name = "OpGroupReserveReadPipePackets",8316 .name = "OpGroupReserveReadPipePackets",
7794 .opcode = 285,8317 .opcode = 285,
7795 .operands = &[_]Operand{8318 .operands = &.{
7796 .{ .kind = .IdResultType, .quantifier = .required },8319 .{ .kind = .id_result_type, .quantifier = .required },
7797 .{ .kind = .IdResult, .quantifier = .required },8320 .{ .kind = .id_result, .quantifier = .required },
7798 .{ .kind = .IdScope, .quantifier = .required },8321 .{ .kind = .id_scope, .quantifier = .required },
7799 .{ .kind = .IdRef, .quantifier = .required },8322 .{ .kind = .id_ref, .quantifier = .required },
7800 .{ .kind = .IdRef, .quantifier = .required },8323 .{ .kind = .id_ref, .quantifier = .required },
7801 .{ .kind = .IdRef, .quantifier = .required },8324 .{ .kind = .id_ref, .quantifier = .required },
7802 .{ .kind = .IdRef, .quantifier = .required },8325 .{ .kind = .id_ref, .quantifier = .required },
7803 },8326 },
7804 },8327 },
7805 .{8328 .{
7806 .name = "OpGroupReserveWritePipePackets",8329 .name = "OpGroupReserveWritePipePackets",
7807 .opcode = 286,8330 .opcode = 286,
7808 .operands = &[_]Operand{8331 .operands = &.{
7809 .{ .kind = .IdResultType, .quantifier = .required },8332 .{ .kind = .id_result_type, .quantifier = .required },
7810 .{ .kind = .IdResult, .quantifier = .required },8333 .{ .kind = .id_result, .quantifier = .required },
7811 .{ .kind = .IdScope, .quantifier = .required },8334 .{ .kind = .id_scope, .quantifier = .required },
7812 .{ .kind = .IdRef, .quantifier = .required },8335 .{ .kind = .id_ref, .quantifier = .required },
7813 .{ .kind = .IdRef, .quantifier = .required },8336 .{ .kind = .id_ref, .quantifier = .required },
7814 .{ .kind = .IdRef, .quantifier = .required },8337 .{ .kind = .id_ref, .quantifier = .required },
7815 .{ .kind = .IdRef, .quantifier = .required },8338 .{ .kind = .id_ref, .quantifier = .required },
7816 },8339 },
7817 },8340 },
7818 .{8341 .{
7819 .name = "OpGroupCommitReadPipe",8342 .name = "OpGroupCommitReadPipe",
7820 .opcode = 287,8343 .opcode = 287,
7821 .operands = &[_]Operand{8344 .operands = &.{
7822 .{ .kind = .IdScope, .quantifier = .required },8345 .{ .kind = .id_scope, .quantifier = .required },
7823 .{ .kind = .IdRef, .quantifier = .required },8346 .{ .kind = .id_ref, .quantifier = .required },
7824 .{ .kind = .IdRef, .quantifier = .required },8347 .{ .kind = .id_ref, .quantifier = .required },
7825 .{ .kind = .IdRef, .quantifier = .required },8348 .{ .kind = .id_ref, .quantifier = .required },
7826 .{ .kind = .IdRef, .quantifier = .required },8349 .{ .kind = .id_ref, .quantifier = .required },
7827 },8350 },
7828 },8351 },
7829 .{8352 .{
7830 .name = "OpGroupCommitWritePipe",8353 .name = "OpGroupCommitWritePipe",
7831 .opcode = 288,8354 .opcode = 288,
7832 .operands = &[_]Operand{8355 .operands = &.{
7833 .{ .kind = .IdScope, .quantifier = .required },8356 .{ .kind = .id_scope, .quantifier = .required },
7834 .{ .kind = .IdRef, .quantifier = .required },8357 .{ .kind = .id_ref, .quantifier = .required },
7835 .{ .kind = .IdRef, .quantifier = .required },8358 .{ .kind = .id_ref, .quantifier = .required },
7836 .{ .kind = .IdRef, .quantifier = .required },8359 .{ .kind = .id_ref, .quantifier = .required },
7837 .{ .kind = .IdRef, .quantifier = .required },8360 .{ .kind = .id_ref, .quantifier = .required },
7838 },8361 },
7839 },8362 },
7840 .{8363 .{
7841 .name = "OpEnqueueMarker",8364 .name = "OpEnqueueMarker",
7842 .opcode = 291,8365 .opcode = 291,
7843 .operands = &[_]Operand{8366 .operands = &.{
7844 .{ .kind = .IdResultType, .quantifier = .required },8367 .{ .kind = .id_result_type, .quantifier = .required },
7845 .{ .kind = .IdResult, .quantifier = .required },8368 .{ .kind = .id_result, .quantifier = .required },
7846 .{ .kind = .IdRef, .quantifier = .required },8369 .{ .kind = .id_ref, .quantifier = .required },
7847 .{ .kind = .IdRef, .quantifier = .required },8370 .{ .kind = .id_ref, .quantifier = .required },
7848 .{ .kind = .IdRef, .quantifier = .required },8371 .{ .kind = .id_ref, .quantifier = .required },
7849 .{ .kind = .IdRef, .quantifier = .required },8372 .{ .kind = .id_ref, .quantifier = .required },
7850 },8373 },
7851 },8374 },
7852 .{8375 .{
7853 .name = "OpEnqueueKernel",8376 .name = "OpEnqueueKernel",
7854 .opcode = 292,8377 .opcode = 292,
7855 .operands = &[_]Operand{8378 .operands = &.{
7856 .{ .kind = .IdResultType, .quantifier = .required },8379 .{ .kind = .id_result_type, .quantifier = .required },
7857 .{ .kind = .IdResult, .quantifier = .required },8380 .{ .kind = .id_result, .quantifier = .required },
7858 .{ .kind = .IdRef, .quantifier = .required },8381 .{ .kind = .id_ref, .quantifier = .required },
7859 .{ .kind = .IdRef, .quantifier = .required },8382 .{ .kind = .id_ref, .quantifier = .required },
7860 .{ .kind = .IdRef, .quantifier = .required },8383 .{ .kind = .id_ref, .quantifier = .required },
7861 .{ .kind = .IdRef, .quantifier = .required },8384 .{ .kind = .id_ref, .quantifier = .required },
7862 .{ .kind = .IdRef, .quantifier = .required },8385 .{ .kind = .id_ref, .quantifier = .required },
7863 .{ .kind = .IdRef, .quantifier = .required },8386 .{ .kind = .id_ref, .quantifier = .required },
7864 .{ .kind = .IdRef, .quantifier = .required },8387 .{ .kind = .id_ref, .quantifier = .required },
7865 .{ .kind = .IdRef, .quantifier = .required },8388 .{ .kind = .id_ref, .quantifier = .required },
7866 .{ .kind = .IdRef, .quantifier = .required },8389 .{ .kind = .id_ref, .quantifier = .required },
7867 .{ .kind = .IdRef, .quantifier = .required },8390 .{ .kind = .id_ref, .quantifier = .required },
7868 .{ .kind = .IdRef, .quantifier = .variadic },8391 .{ .kind = .id_ref, .quantifier = .variadic },
7869 },8392 },
7870 },8393 },
7871 .{8394 .{
7872 .name = "OpGetKernelNDrangeSubGroupCount",8395 .name = "OpGetKernelNDrangeSubGroupCount",
7873 .opcode = 293,8396 .opcode = 293,
7874 .operands = &[_]Operand{8397 .operands = &.{
7875 .{ .kind = .IdResultType, .quantifier = .required },8398 .{ .kind = .id_result_type, .quantifier = .required },
7876 .{ .kind = .IdResult, .quantifier = .required },8399 .{ .kind = .id_result, .quantifier = .required },
7877 .{ .kind = .IdRef, .quantifier = .required },8400 .{ .kind = .id_ref, .quantifier = .required },
7878 .{ .kind = .IdRef, .quantifier = .required },8401 .{ .kind = .id_ref, .quantifier = .required },
7879 .{ .kind = .IdRef, .quantifier = .required },8402 .{ .kind = .id_ref, .quantifier = .required },
7880 .{ .kind = .IdRef, .quantifier = .required },8403 .{ .kind = .id_ref, .quantifier = .required },
7881 .{ .kind = .IdRef, .quantifier = .required },8404 .{ .kind = .id_ref, .quantifier = .required },
7882 },8405 },
7883 },8406 },
7884 .{8407 .{
7885 .name = "OpGetKernelNDrangeMaxSubGroupSize",8408 .name = "OpGetKernelNDrangeMaxSubGroupSize",
7886 .opcode = 294,8409 .opcode = 294,
7887 .operands = &[_]Operand{8410 .operands = &.{
7888 .{ .kind = .IdResultType, .quantifier = .required },8411 .{ .kind = .id_result_type, .quantifier = .required },
7889 .{ .kind = .IdResult, .quantifier = .required },8412 .{ .kind = .id_result, .quantifier = .required },
7890 .{ .kind = .IdRef, .quantifier = .required },8413 .{ .kind = .id_ref, .quantifier = .required },
7891 .{ .kind = .IdRef, .quantifier = .required },8414 .{ .kind = .id_ref, .quantifier = .required },
7892 .{ .kind = .IdRef, .quantifier = .required },8415 .{ .kind = .id_ref, .quantifier = .required },
7893 .{ .kind = .IdRef, .quantifier = .required },8416 .{ .kind = .id_ref, .quantifier = .required },
7894 .{ .kind = .IdRef, .quantifier = .required },8417 .{ .kind = .id_ref, .quantifier = .required },
7895 },8418 },
7896 },8419 },
7897 .{8420 .{
7898 .name = "OpGetKernelWorkGroupSize",8421 .name = "OpGetKernelWorkGroupSize",
7899 .opcode = 295,8422 .opcode = 295,
7900 .operands = &[_]Operand{8423 .operands = &.{
7901 .{ .kind = .IdResultType, .quantifier = .required },8424 .{ .kind = .id_result_type, .quantifier = .required },
7902 .{ .kind = .IdResult, .quantifier = .required },8425 .{ .kind = .id_result, .quantifier = .required },
7903 .{ .kind = .IdRef, .quantifier = .required },8426 .{ .kind = .id_ref, .quantifier = .required },
7904 .{ .kind = .IdRef, .quantifier = .required },8427 .{ .kind = .id_ref, .quantifier = .required },
7905 .{ .kind = .IdRef, .quantifier = .required },8428 .{ .kind = .id_ref, .quantifier = .required },
7906 .{ .kind = .IdRef, .quantifier = .required },8429 .{ .kind = .id_ref, .quantifier = .required },
7907 },8430 },
7908 },8431 },
7909 .{8432 .{
7910 .name = "OpGetKernelPreferredWorkGroupSizeMultiple",8433 .name = "OpGetKernelPreferredWorkGroupSizeMultiple",
7911 .opcode = 296,8434 .opcode = 296,
7912 .operands = &[_]Operand{8435 .operands = &.{
7913 .{ .kind = .IdResultType, .quantifier = .required },8436 .{ .kind = .id_result_type, .quantifier = .required },
7914 .{ .kind = .IdResult, .quantifier = .required },8437 .{ .kind = .id_result, .quantifier = .required },
7915 .{ .kind = .IdRef, .quantifier = .required },8438 .{ .kind = .id_ref, .quantifier = .required },
7916 .{ .kind = .IdRef, .quantifier = .required },8439 .{ .kind = .id_ref, .quantifier = .required },
7917 .{ .kind = .IdRef, .quantifier = .required },8440 .{ .kind = .id_ref, .quantifier = .required },
7918 .{ .kind = .IdRef, .quantifier = .required },8441 .{ .kind = .id_ref, .quantifier = .required },
7919 },8442 },
7920 },8443 },
7921 .{8444 .{
7922 .name = "OpRetainEvent",8445 .name = "OpRetainEvent",
7923 .opcode = 297,8446 .opcode = 297,
7924 .operands = &[_]Operand{8447 .operands = &.{
7925 .{ .kind = .IdRef, .quantifier = .required },8448 .{ .kind = .id_ref, .quantifier = .required },
7926 },8449 },
7927 },8450 },
7928 .{8451 .{
7929 .name = "OpReleaseEvent",8452 .name = "OpReleaseEvent",
7930 .opcode = 298,8453 .opcode = 298,
7931 .operands = &[_]Operand{8454 .operands = &.{
7932 .{ .kind = .IdRef, .quantifier = .required },8455 .{ .kind = .id_ref, .quantifier = .required },
7933 },8456 },
7934 },8457 },
7935 .{8458 .{
7936 .name = "OpCreateUserEvent",8459 .name = "OpCreateUserEvent",
7937 .opcode = 299,8460 .opcode = 299,
7938 .operands = &[_]Operand{8461 .operands = &.{
7939 .{ .kind = .IdResultType, .quantifier = .required },8462 .{ .kind = .id_result_type, .quantifier = .required },
7940 .{ .kind = .IdResult, .quantifier = .required },8463 .{ .kind = .id_result, .quantifier = .required },
7941 },8464 },
7942 },8465 },
7943 .{8466 .{
7944 .name = "OpIsValidEvent",8467 .name = "OpIsValidEvent",
7945 .opcode = 300,8468 .opcode = 300,
7946 .operands = &[_]Operand{8469 .operands = &.{
7947 .{ .kind = .IdResultType, .quantifier = .required },8470 .{ .kind = .id_result_type, .quantifier = .required },
7948 .{ .kind = .IdResult, .quantifier = .required },8471 .{ .kind = .id_result, .quantifier = .required },
7949 .{ .kind = .IdRef, .quantifier = .required },8472 .{ .kind = .id_ref, .quantifier = .required },
7950 },8473 },
7951 },8474 },
7952 .{8475 .{
7953 .name = "OpSetUserEventStatus",8476 .name = "OpSetUserEventStatus",
7954 .opcode = 301,8477 .opcode = 301,
7955 .operands = &[_]Operand{8478 .operands = &.{
7956 .{ .kind = .IdRef, .quantifier = .required },8479 .{ .kind = .id_ref, .quantifier = .required },
7957 .{ .kind = .IdRef, .quantifier = .required },8480 .{ .kind = .id_ref, .quantifier = .required },
7958 },8481 },
7959 },8482 },
7960 .{8483 .{
7961 .name = "OpCaptureEventProfilingInfo",8484 .name = "OpCaptureEventProfilingInfo",
7962 .opcode = 302,8485 .opcode = 302,
7963 .operands = &[_]Operand{8486 .operands = &.{
7964 .{ .kind = .IdRef, .quantifier = .required },8487 .{ .kind = .id_ref, .quantifier = .required },
7965 .{ .kind = .IdRef, .quantifier = .required },8488 .{ .kind = .id_ref, .quantifier = .required },
7966 .{ .kind = .IdRef, .quantifier = .required },8489 .{ .kind = .id_ref, .quantifier = .required },
7967 },8490 },
7968 },8491 },
7969 .{8492 .{
7970 .name = "OpGetDefaultQueue",8493 .name = "OpGetDefaultQueue",
7971 .opcode = 303,8494 .opcode = 303,
7972 .operands = &[_]Operand{8495 .operands = &.{
7973 .{ .kind = .IdResultType, .quantifier = .required },8496 .{ .kind = .id_result_type, .quantifier = .required },
7974 .{ .kind = .IdResult, .quantifier = .required },8497 .{ .kind = .id_result, .quantifier = .required },
7975 },8498 },
7976 },8499 },
7977 .{8500 .{
7978 .name = "OpBuildNDRange",8501 .name = "OpBuildNDRange",
7979 .opcode = 304,8502 .opcode = 304,
7980 .operands = &[_]Operand{8503 .operands = &.{
7981 .{ .kind = .IdResultType, .quantifier = .required },8504 .{ .kind = .id_result_type, .quantifier = .required },
7982 .{ .kind = .IdResult, .quantifier = .required },8505 .{ .kind = .id_result, .quantifier = .required },
7983 .{ .kind = .IdRef, .quantifier = .required },8506 .{ .kind = .id_ref, .quantifier = .required },
7984 .{ .kind = .IdRef, .quantifier = .required },8507 .{ .kind = .id_ref, .quantifier = .required },
7985 .{ .kind = .IdRef, .quantifier = .required },8508 .{ .kind = .id_ref, .quantifier = .required },
7986 },8509 },
7987 },8510 },
7988 .{8511 .{
7989 .name = "OpImageSparseSampleImplicitLod",8512 .name = "OpImageSparseSampleImplicitLod",
7990 .opcode = 305,8513 .opcode = 305,
7991 .operands = &[_]Operand{8514 .operands = &.{
7992 .{ .kind = .IdResultType, .quantifier = .required },8515 .{ .kind = .id_result_type, .quantifier = .required },
7993 .{ .kind = .IdResult, .quantifier = .required },8516 .{ .kind = .id_result, .quantifier = .required },
7994 .{ .kind = .IdRef, .quantifier = .required },8517 .{ .kind = .id_ref, .quantifier = .required },
7995 .{ .kind = .IdRef, .quantifier = .required },8518 .{ .kind = .id_ref, .quantifier = .required },
7996 .{ .kind = .ImageOperands, .quantifier = .optional },8519 .{ .kind = .image_operands, .quantifier = .optional },
7997 },8520 },
7998 },8521 },
7999 .{8522 .{
8000 .name = "OpImageSparseSampleExplicitLod",8523 .name = "OpImageSparseSampleExplicitLod",
8001 .opcode = 306,8524 .opcode = 306,
8002 .operands = &[_]Operand{8525 .operands = &.{
8003 .{ .kind = .IdResultType, .quantifier = .required },8526 .{ .kind = .id_result_type, .quantifier = .required },
8004 .{ .kind = .IdResult, .quantifier = .required },8527 .{ .kind = .id_result, .quantifier = .required },
8005 .{ .kind = .IdRef, .quantifier = .required },8528 .{ .kind = .id_ref, .quantifier = .required },
8006 .{ .kind = .IdRef, .quantifier = .required },8529 .{ .kind = .id_ref, .quantifier = .required },
8007 .{ .kind = .ImageOperands, .quantifier = .required },8530 .{ .kind = .image_operands, .quantifier = .required },
8008 },8531 },
8009 },8532 },
8010 .{8533 .{
8011 .name = "OpImageSparseSampleDrefImplicitLod",8534 .name = "OpImageSparseSampleDrefImplicitLod",
8012 .opcode = 307,8535 .opcode = 307,
8013 .operands = &[_]Operand{8536 .operands = &.{
8014 .{ .kind = .IdResultType, .quantifier = .required },8537 .{ .kind = .id_result_type, .quantifier = .required },
8015 .{ .kind = .IdResult, .quantifier = .required },8538 .{ .kind = .id_result, .quantifier = .required },
8016 .{ .kind = .IdRef, .quantifier = .required },8539 .{ .kind = .id_ref, .quantifier = .required },
8017 .{ .kind = .IdRef, .quantifier = .required },8540 .{ .kind = .id_ref, .quantifier = .required },
8018 .{ .kind = .IdRef, .quantifier = .required },8541 .{ .kind = .id_ref, .quantifier = .required },
8019 .{ .kind = .ImageOperands, .quantifier = .optional },8542 .{ .kind = .image_operands, .quantifier = .optional },
8020 },8543 },
8021 },8544 },
8022 .{8545 .{
8023 .name = "OpImageSparseSampleDrefExplicitLod",8546 .name = "OpImageSparseSampleDrefExplicitLod",
8024 .opcode = 308,8547 .opcode = 308,
8025 .operands = &[_]Operand{8548 .operands = &.{
8026 .{ .kind = .IdResultType, .quantifier = .required },8549 .{ .kind = .id_result_type, .quantifier = .required },
8027 .{ .kind = .IdResult, .quantifier = .required },8550 .{ .kind = .id_result, .quantifier = .required },
8028 .{ .kind = .IdRef, .quantifier = .required },8551 .{ .kind = .id_ref, .quantifier = .required },
8029 .{ .kind = .IdRef, .quantifier = .required },8552 .{ .kind = .id_ref, .quantifier = .required },
8030 .{ .kind = .IdRef, .quantifier = .required },8553 .{ .kind = .id_ref, .quantifier = .required },
8031 .{ .kind = .ImageOperands, .quantifier = .required },8554 .{ .kind = .image_operands, .quantifier = .required },
8032 },8555 },
8033 },8556 },
8034 .{8557 .{
8035 .name = "OpImageSparseSampleProjImplicitLod",8558 .name = "OpImageSparseSampleProjImplicitLod",
8036 .opcode = 309,8559 .opcode = 309,
8037 .operands = &[_]Operand{8560 .operands = &.{
8038 .{ .kind = .IdResultType, .quantifier = .required },8561 .{ .kind = .id_result_type, .quantifier = .required },
8039 .{ .kind = .IdResult, .quantifier = .required },8562 .{ .kind = .id_result, .quantifier = .required },
8040 .{ .kind = .IdRef, .quantifier = .required },8563 .{ .kind = .id_ref, .quantifier = .required },
8041 .{ .kind = .IdRef, .quantifier = .required },8564 .{ .kind = .id_ref, .quantifier = .required },
8042 .{ .kind = .ImageOperands, .quantifier = .optional },8565 .{ .kind = .image_operands, .quantifier = .optional },
8043 },8566 },
8044 },8567 },
8045 .{8568 .{
8046 .name = "OpImageSparseSampleProjExplicitLod",8569 .name = "OpImageSparseSampleProjExplicitLod",
8047 .opcode = 310,8570 .opcode = 310,
8048 .operands = &[_]Operand{8571 .operands = &.{
8049 .{ .kind = .IdResultType, .quantifier = .required },8572 .{ .kind = .id_result_type, .quantifier = .required },
8050 .{ .kind = .IdResult, .quantifier = .required },8573 .{ .kind = .id_result, .quantifier = .required },
8051 .{ .kind = .IdRef, .quantifier = .required },8574 .{ .kind = .id_ref, .quantifier = .required },
8052 .{ .kind = .IdRef, .quantifier = .required },8575 .{ .kind = .id_ref, .quantifier = .required },
8053 .{ .kind = .ImageOperands, .quantifier = .required },8576 .{ .kind = .image_operands, .quantifier = .required },
8054 },8577 },
8055 },8578 },
8056 .{8579 .{
8057 .name = "OpImageSparseSampleProjDrefImplicitLod",8580 .name = "OpImageSparseSampleProjDrefImplicitLod",
8058 .opcode = 311,8581 .opcode = 311,
8059 .operands = &[_]Operand{8582 .operands = &.{
8060 .{ .kind = .IdResultType, .quantifier = .required },8583 .{ .kind = .id_result_type, .quantifier = .required },
8061 .{ .kind = .IdResult, .quantifier = .required },8584 .{ .kind = .id_result, .quantifier = .required },
8062 .{ .kind = .IdRef, .quantifier = .required },8585 .{ .kind = .id_ref, .quantifier = .required },
8063 .{ .kind = .IdRef, .quantifier = .required },8586 .{ .kind = .id_ref, .quantifier = .required },
8064 .{ .kind = .IdRef, .quantifier = .required },8587 .{ .kind = .id_ref, .quantifier = .required },
8065 .{ .kind = .ImageOperands, .quantifier = .optional },8588 .{ .kind = .image_operands, .quantifier = .optional },
8066 },8589 },
8067 },8590 },
8068 .{8591 .{
8069 .name = "OpImageSparseSampleProjDrefExplicitLod",8592 .name = "OpImageSparseSampleProjDrefExplicitLod",
8070 .opcode = 312,8593 .opcode = 312,
8071 .operands = &[_]Operand{8594 .operands = &.{
8072 .{ .kind = .IdResultType, .quantifier = .required },8595 .{ .kind = .id_result_type, .quantifier = .required },
8073 .{ .kind = .IdResult, .quantifier = .required },8596 .{ .kind = .id_result, .quantifier = .required },
8074 .{ .kind = .IdRef, .quantifier = .required },8597 .{ .kind = .id_ref, .quantifier = .required },
8075 .{ .kind = .IdRef, .quantifier = .required },8598 .{ .kind = .id_ref, .quantifier = .required },
8076 .{ .kind = .IdRef, .quantifier = .required },8599 .{ .kind = .id_ref, .quantifier = .required },
8077 .{ .kind = .ImageOperands, .quantifier = .required },8600 .{ .kind = .image_operands, .quantifier = .required },
8078 },8601 },
8079 },8602 },
8080 .{8603 .{
8081 .name = "OpImageSparseFetch",8604 .name = "OpImageSparseFetch",
8082 .opcode = 313,8605 .opcode = 313,
8083 .operands = &[_]Operand{8606 .operands = &.{
8084 .{ .kind = .IdResultType, .quantifier = .required },8607 .{ .kind = .id_result_type, .quantifier = .required },
8085 .{ .kind = .IdResult, .quantifier = .required },8608 .{ .kind = .id_result, .quantifier = .required },
8086 .{ .kind = .IdRef, .quantifier = .required },8609 .{ .kind = .id_ref, .quantifier = .required },
8087 .{ .kind = .IdRef, .quantifier = .required },8610 .{ .kind = .id_ref, .quantifier = .required },
8088 .{ .kind = .ImageOperands, .quantifier = .optional },8611 .{ .kind = .image_operands, .quantifier = .optional },
8089 },8612 },
8090 },8613 },
8091 .{8614 .{
8092 .name = "OpImageSparseGather",8615 .name = "OpImageSparseGather",
8093 .opcode = 314,8616 .opcode = 314,
8094 .operands = &[_]Operand{8617 .operands = &.{
8095 .{ .kind = .IdResultType, .quantifier = .required },8618 .{ .kind = .id_result_type, .quantifier = .required },
8096 .{ .kind = .IdResult, .quantifier = .required },8619 .{ .kind = .id_result, .quantifier = .required },
8097 .{ .kind = .IdRef, .quantifier = .required },8620 .{ .kind = .id_ref, .quantifier = .required },
8098 .{ .kind = .IdRef, .quantifier = .required },8621 .{ .kind = .id_ref, .quantifier = .required },
8099 .{ .kind = .IdRef, .quantifier = .required },8622 .{ .kind = .id_ref, .quantifier = .required },
8100 .{ .kind = .ImageOperands, .quantifier = .optional },8623 .{ .kind = .image_operands, .quantifier = .optional },
8101 },8624 },
8102 },8625 },
8103 .{8626 .{
8104 .name = "OpImageSparseDrefGather",8627 .name = "OpImageSparseDrefGather",
8105 .opcode = 315,8628 .opcode = 315,
8106 .operands = &[_]Operand{8629 .operands = &.{
8107 .{ .kind = .IdResultType, .quantifier = .required },8630 .{ .kind = .id_result_type, .quantifier = .required },
8108 .{ .kind = .IdResult, .quantifier = .required },8631 .{ .kind = .id_result, .quantifier = .required },
8109 .{ .kind = .IdRef, .quantifier = .required },8632 .{ .kind = .id_ref, .quantifier = .required },
8110 .{ .kind = .IdRef, .quantifier = .required },8633 .{ .kind = .id_ref, .quantifier = .required },
8111 .{ .kind = .IdRef, .quantifier = .required },8634 .{ .kind = .id_ref, .quantifier = .required },
8112 .{ .kind = .ImageOperands, .quantifier = .optional },8635 .{ .kind = .image_operands, .quantifier = .optional },
8113 },8636 },
8114 },8637 },
8115 .{8638 .{
8116 .name = "OpImageSparseTexelsResident",8639 .name = "OpImageSparseTexelsResident",
8117 .opcode = 316,8640 .opcode = 316,
8118 .operands = &[_]Operand{8641 .operands = &.{
8119 .{ .kind = .IdResultType, .quantifier = .required },8642 .{ .kind = .id_result_type, .quantifier = .required },
8120 .{ .kind = .IdResult, .quantifier = .required },8643 .{ .kind = .id_result, .quantifier = .required },
8121 .{ .kind = .IdRef, .quantifier = .required },8644 .{ .kind = .id_ref, .quantifier = .required },
8122 },8645 },
8123 },8646 },
8124 .{8647 .{
8125 .name = "OpNoLine",8648 .name = "OpNoLine",
8126 .opcode = 317,8649 .opcode = 317,
8127 .operands = &[_]Operand{},8650 .operands = &.{},
8128 },8651 },
8129 .{8652 .{
8130 .name = "OpAtomicFlagTestAndSet",8653 .name = "OpAtomicFlagTestAndSet",
8131 .opcode = 318,8654 .opcode = 318,
8132 .operands = &[_]Operand{8655 .operands = &.{
8133 .{ .kind = .IdResultType, .quantifier = .required },8656 .{ .kind = .id_result_type, .quantifier = .required },
8134 .{ .kind = .IdResult, .quantifier = .required },8657 .{ .kind = .id_result, .quantifier = .required },
8135 .{ .kind = .IdRef, .quantifier = .required },8658 .{ .kind = .id_ref, .quantifier = .required },
8136 .{ .kind = .IdScope, .quantifier = .required },8659 .{ .kind = .id_scope, .quantifier = .required },
8137 .{ .kind = .IdMemorySemantics, .quantifier = .required },8660 .{ .kind = .id_memory_semantics, .quantifier = .required },
8138 },8661 },
8139 },8662 },
8140 .{8663 .{
8141 .name = "OpAtomicFlagClear",8664 .name = "OpAtomicFlagClear",
8142 .opcode = 319,8665 .opcode = 319,
8143 .operands = &[_]Operand{8666 .operands = &.{
8144 .{ .kind = .IdRef, .quantifier = .required },8667 .{ .kind = .id_ref, .quantifier = .required },
8145 .{ .kind = .IdScope, .quantifier = .required },8668 .{ .kind = .id_scope, .quantifier = .required },
8146 .{ .kind = .IdMemorySemantics, .quantifier = .required },8669 .{ .kind = .id_memory_semantics, .quantifier = .required },
8147 },8670 },
8148 },8671 },
8149 .{8672 .{
8150 .name = "OpImageSparseRead",8673 .name = "OpImageSparseRead",
8151 .opcode = 320,8674 .opcode = 320,
8152 .operands = &[_]Operand{8675 .operands = &.{
8153 .{ .kind = .IdResultType, .quantifier = .required },8676 .{ .kind = .id_result_type, .quantifier = .required },
8154 .{ .kind = .IdResult, .quantifier = .required },8677 .{ .kind = .id_result, .quantifier = .required },
8155 .{ .kind = .IdRef, .quantifier = .required },8678 .{ .kind = .id_ref, .quantifier = .required },
8156 .{ .kind = .IdRef, .quantifier = .required },8679 .{ .kind = .id_ref, .quantifier = .required },
8157 .{ .kind = .ImageOperands, .quantifier = .optional },8680 .{ .kind = .image_operands, .quantifier = .optional },
8158 },8681 },
8159 },8682 },
8160 .{8683 .{
8161 .name = "OpSizeOf",8684 .name = "OpSizeOf",
8162 .opcode = 321,8685 .opcode = 321,
8163 .operands = &[_]Operand{8686 .operands = &.{
8164 .{ .kind = .IdResultType, .quantifier = .required },8687 .{ .kind = .id_result_type, .quantifier = .required },
8165 .{ .kind = .IdResult, .quantifier = .required },8688 .{ .kind = .id_result, .quantifier = .required },
8166 .{ .kind = .IdRef, .quantifier = .required },8689 .{ .kind = .id_ref, .quantifier = .required },
8167 },8690 },
8168 },8691 },
8169 .{8692 .{
8170 .name = "OpTypePipeStorage",8693 .name = "OpTypePipeStorage",
8171 .opcode = 322,8694 .opcode = 322,
8172 .operands = &[_]Operand{8695 .operands = &.{
8173 .{ .kind = .IdResult, .quantifier = .required },8696 .{ .kind = .id_result, .quantifier = .required },
8174 },8697 },
8175 },8698 },
8176 .{8699 .{
8177 .name = "OpConstantPipeStorage",8700 .name = "OpConstantPipeStorage",
8178 .opcode = 323,8701 .opcode = 323,
8179 .operands = &[_]Operand{8702 .operands = &.{
8180 .{ .kind = .IdResultType, .quantifier = .required },8703 .{ .kind = .id_result_type, .quantifier = .required },
8181 .{ .kind = .IdResult, .quantifier = .required },8704 .{ .kind = .id_result, .quantifier = .required },
8182 .{ .kind = .LiteralInteger, .quantifier = .required },8705 .{ .kind = .literal_integer, .quantifier = .required },
8183 .{ .kind = .LiteralInteger, .quantifier = .required },8706 .{ .kind = .literal_integer, .quantifier = .required },
8184 .{ .kind = .LiteralInteger, .quantifier = .required },8707 .{ .kind = .literal_integer, .quantifier = .required },
8185 },8708 },
8186 },8709 },
8187 .{8710 .{
8188 .name = "OpCreatePipeFromPipeStorage",8711 .name = "OpCreatePipeFromPipeStorage",
8189 .opcode = 324,8712 .opcode = 324,
8190 .operands = &[_]Operand{8713 .operands = &.{
8191 .{ .kind = .IdResultType, .quantifier = .required },8714 .{ .kind = .id_result_type, .quantifier = .required },
8192 .{ .kind = .IdResult, .quantifier = .required },8715 .{ .kind = .id_result, .quantifier = .required },
8193 .{ .kind = .IdRef, .quantifier = .required },8716 .{ .kind = .id_ref, .quantifier = .required },
8194 },8717 },
8195 },8718 },
8196 .{8719 .{
8197 .name = "OpGetKernelLocalSizeForSubgroupCount",8720 .name = "OpGetKernelLocalSizeForSubgroupCount",
8198 .opcode = 325,8721 .opcode = 325,
8199 .operands = &[_]Operand{8722 .operands = &.{
8200 .{ .kind = .IdResultType, .quantifier = .required },8723 .{ .kind = .id_result_type, .quantifier = .required },
8201 .{ .kind = .IdResult, .quantifier = .required },8724 .{ .kind = .id_result, .quantifier = .required },
8202 .{ .kind = .IdRef, .quantifier = .required },8725 .{ .kind = .id_ref, .quantifier = .required },
8203 .{ .kind = .IdRef, .quantifier = .required },8726 .{ .kind = .id_ref, .quantifier = .required },
8204 .{ .kind = .IdRef, .quantifier = .required },8727 .{ .kind = .id_ref, .quantifier = .required },
8205 .{ .kind = .IdRef, .quantifier = .required },8728 .{ .kind = .id_ref, .quantifier = .required },
8206 .{ .kind = .IdRef, .quantifier = .required },8729 .{ .kind = .id_ref, .quantifier = .required },
8207 },8730 },
8208 },8731 },
8209 .{8732 .{
8210 .name = "OpGetKernelMaxNumSubgroups",8733 .name = "OpGetKernelMaxNumSubgroups",
8211 .opcode = 326,8734 .opcode = 326,
8212 .operands = &[_]Operand{8735 .operands = &.{
8213 .{ .kind = .IdResultType, .quantifier = .required },8736 .{ .kind = .id_result_type, .quantifier = .required },
8214 .{ .kind = .IdResult, .quantifier = .required },8737 .{ .kind = .id_result, .quantifier = .required },
8215 .{ .kind = .IdRef, .quantifier = .required },8738 .{ .kind = .id_ref, .quantifier = .required },
8216 .{ .kind = .IdRef, .quantifier = .required },8739 .{ .kind = .id_ref, .quantifier = .required },
8217 .{ .kind = .IdRef, .quantifier = .required },8740 .{ .kind = .id_ref, .quantifier = .required },
8218 .{ .kind = .IdRef, .quantifier = .required },8741 .{ .kind = .id_ref, .quantifier = .required },
8219 },8742 },
8220 },8743 },
8221 .{8744 .{
8222 .name = "OpTypeNamedBarrier",8745 .name = "OpTypeNamedBarrier",
8223 .opcode = 327,8746 .opcode = 327,
8224 .operands = &[_]Operand{8747 .operands = &.{
8225 .{ .kind = .IdResult, .quantifier = .required },8748 .{ .kind = .id_result, .quantifier = .required },
8226 },8749 },
8227 },8750 },
8228 .{8751 .{
8229 .name = "OpNamedBarrierInitialize",8752 .name = "OpNamedBarrierInitialize",
8230 .opcode = 328,8753 .opcode = 328,
8231 .operands = &[_]Operand{8754 .operands = &.{
8232 .{ .kind = .IdResultType, .quantifier = .required },8755 .{ .kind = .id_result_type, .quantifier = .required },
8233 .{ .kind = .IdResult, .quantifier = .required },8756 .{ .kind = .id_result, .quantifier = .required },
8234 .{ .kind = .IdRef, .quantifier = .required },8757 .{ .kind = .id_ref, .quantifier = .required },
8235 },8758 },
8236 },8759 },
8237 .{8760 .{
8238 .name = "OpMemoryNamedBarrier",8761 .name = "OpMemoryNamedBarrier",
8239 .opcode = 329,8762 .opcode = 329,
8240 .operands = &[_]Operand{8763 .operands = &.{
8241 .{ .kind = .IdRef, .quantifier = .required },8764 .{ .kind = .id_ref, .quantifier = .required },
8242 .{ .kind = .IdScope, .quantifier = .required },8765 .{ .kind = .id_scope, .quantifier = .required },
8243 .{ .kind = .IdMemorySemantics, .quantifier = .required },8766 .{ .kind = .id_memory_semantics, .quantifier = .required },
8244 },8767 },
8245 },8768 },
8246 .{8769 .{
8247 .name = "OpModuleProcessed",8770 .name = "OpModuleProcessed",
8248 .opcode = 330,8771 .opcode = 330,
8249 .operands = &[_]Operand{8772 .operands = &.{
8250 .{ .kind = .LiteralString, .quantifier = .required },8773 .{ .kind = .literal_string, .quantifier = .required },
8251 },8774 },
8252 },8775 },
8253 .{8776 .{
8254 .name = "OpExecutionModeId",8777 .name = "OpExecutionModeId",
8255 .opcode = 331,8778 .opcode = 331,
8256 .operands = &[_]Operand{8779 .operands = &.{
8257 .{ .kind = .IdRef, .quantifier = .required },8780 .{ .kind = .id_ref, .quantifier = .required },
8258 .{ .kind = .ExecutionMode, .quantifier = .required },8781 .{ .kind = .execution_mode, .quantifier = .required },
8259 },8782 },
8260 },8783 },
8261 .{8784 .{
8262 .name = "OpDecorateId",8785 .name = "OpDecorateId",
8263 .opcode = 332,8786 .opcode = 332,
8264 .operands = &[_]Operand{8787 .operands = &.{
8265 .{ .kind = .IdRef, .quantifier = .required },8788 .{ .kind = .id_ref, .quantifier = .required },
8266 .{ .kind = .Decoration, .quantifier = .required },8789 .{ .kind = .decoration, .quantifier = .required },
8267 },8790 },
8268 },8791 },
8269 .{8792 .{
8270 .name = "OpGroupNonUniformElect",8793 .name = "OpGroupNonUniformElect",
8271 .opcode = 333,8794 .opcode = 333,
8272 .operands = &[_]Operand{8795 .operands = &.{
8273 .{ .kind = .IdResultType, .quantifier = .required },8796 .{ .kind = .id_result_type, .quantifier = .required },
8274 .{ .kind = .IdResult, .quantifier = .required },8797 .{ .kind = .id_result, .quantifier = .required },
8275 .{ .kind = .IdScope, .quantifier = .required },8798 .{ .kind = .id_scope, .quantifier = .required },
8276 },8799 },
8277 },8800 },
8278 .{8801 .{
8279 .name = "OpGroupNonUniformAll",8802 .name = "OpGroupNonUniformAll",
8280 .opcode = 334,8803 .opcode = 334,
8281 .operands = &[_]Operand{8804 .operands = &.{
8282 .{ .kind = .IdResultType, .quantifier = .required },8805 .{ .kind = .id_result_type, .quantifier = .required },
8283 .{ .kind = .IdResult, .quantifier = .required },8806 .{ .kind = .id_result, .quantifier = .required },
8284 .{ .kind = .IdScope, .quantifier = .required },8807 .{ .kind = .id_scope, .quantifier = .required },
8285 .{ .kind = .IdRef, .quantifier = .required },8808 .{ .kind = .id_ref, .quantifier = .required },
8286 },8809 },
8287 },8810 },
8288 .{8811 .{
8289 .name = "OpGroupNonUniformAny",8812 .name = "OpGroupNonUniformAny",
8290 .opcode = 335,8813 .opcode = 335,
8291 .operands = &[_]Operand{8814 .operands = &.{
8292 .{ .kind = .IdResultType, .quantifier = .required },8815 .{ .kind = .id_result_type, .quantifier = .required },
8293 .{ .kind = .IdResult, .quantifier = .required },8816 .{ .kind = .id_result, .quantifier = .required },
8294 .{ .kind = .IdScope, .quantifier = .required },8817 .{ .kind = .id_scope, .quantifier = .required },
8295 .{ .kind = .IdRef, .quantifier = .required },8818 .{ .kind = .id_ref, .quantifier = .required },
8296 },8819 },
8297 },8820 },
8298 .{8821 .{
8299 .name = "OpGroupNonUniformAllEqual",8822 .name = "OpGroupNonUniformAllEqual",
8300 .opcode = 336,8823 .opcode = 336,
8301 .operands = &[_]Operand{8824 .operands = &.{
8302 .{ .kind = .IdResultType, .quantifier = .required },8825 .{ .kind = .id_result_type, .quantifier = .required },
8303 .{ .kind = .IdResult, .quantifier = .required },8826 .{ .kind = .id_result, .quantifier = .required },
8304 .{ .kind = .IdScope, .quantifier = .required },8827 .{ .kind = .id_scope, .quantifier = .required },
8305 .{ .kind = .IdRef, .quantifier = .required },8828 .{ .kind = .id_ref, .quantifier = .required },
8306 },8829 },
8307 },8830 },
8308 .{8831 .{
8309 .name = "OpGroupNonUniformBroadcast",8832 .name = "OpGroupNonUniformBroadcast",
8310 .opcode = 337,8833 .opcode = 337,
8311 .operands = &[_]Operand{8834 .operands = &.{
8312 .{ .kind = .IdResultType, .quantifier = .required },8835 .{ .kind = .id_result_type, .quantifier = .required },
8313 .{ .kind = .IdResult, .quantifier = .required },8836 .{ .kind = .id_result, .quantifier = .required },
8314 .{ .kind = .IdScope, .quantifier = .required },8837 .{ .kind = .id_scope, .quantifier = .required },
8315 .{ .kind = .IdRef, .quantifier = .required },8838 .{ .kind = .id_ref, .quantifier = .required },
8316 .{ .kind = .IdRef, .quantifier = .required },8839 .{ .kind = .id_ref, .quantifier = .required },
8317 },8840 },
8318 },8841 },
8319 .{8842 .{
8320 .name = "OpGroupNonUniformBroadcastFirst",8843 .name = "OpGroupNonUniformBroadcastFirst",
8321 .opcode = 338,8844 .opcode = 338,
8322 .operands = &[_]Operand{8845 .operands = &.{
8323 .{ .kind = .IdResultType, .quantifier = .required },8846 .{ .kind = .id_result_type, .quantifier = .required },
8324 .{ .kind = .IdResult, .quantifier = .required },8847 .{ .kind = .id_result, .quantifier = .required },
8325 .{ .kind = .IdScope, .quantifier = .required },8848 .{ .kind = .id_scope, .quantifier = .required },
8326 .{ .kind = .IdRef, .quantifier = .required },8849 .{ .kind = .id_ref, .quantifier = .required },
8327 },8850 },
8328 },8851 },
8329 .{8852 .{
8330 .name = "OpGroupNonUniformBallot",8853 .name = "OpGroupNonUniformBallot",
8331 .opcode = 339,8854 .opcode = 339,
8332 .operands = &[_]Operand{8855 .operands = &.{
8333 .{ .kind = .IdResultType, .quantifier = .required },8856 .{ .kind = .id_result_type, .quantifier = .required },
8334 .{ .kind = .IdResult, .quantifier = .required },8857 .{ .kind = .id_result, .quantifier = .required },
8335 .{ .kind = .IdScope, .quantifier = .required },8858 .{ .kind = .id_scope, .quantifier = .required },
8336 .{ .kind = .IdRef, .quantifier = .required },8859 .{ .kind = .id_ref, .quantifier = .required },
8337 },8860 },
8338 },8861 },
8339 .{8862 .{
8340 .name = "OpGroupNonUniformInverseBallot",8863 .name = "OpGroupNonUniformInverseBallot",
8341 .opcode = 340,8864 .opcode = 340,
8342 .operands = &[_]Operand{8865 .operands = &.{
8343 .{ .kind = .IdResultType, .quantifier = .required },8866 .{ .kind = .id_result_type, .quantifier = .required },
8344 .{ .kind = .IdResult, .quantifier = .required },8867 .{ .kind = .id_result, .quantifier = .required },
8345 .{ .kind = .IdScope, .quantifier = .required },8868 .{ .kind = .id_scope, .quantifier = .required },
8346 .{ .kind = .IdRef, .quantifier = .required },8869 .{ .kind = .id_ref, .quantifier = .required },
8347 },8870 },
8348 },8871 },
8349 .{8872 .{
8350 .name = "OpGroupNonUniformBallotBitExtract",8873 .name = "OpGroupNonUniformBallotBitExtract",
8351 .opcode = 341,8874 .opcode = 341,
8352 .operands = &[_]Operand{8875 .operands = &.{
8353 .{ .kind = .IdResultType, .quantifier = .required },8876 .{ .kind = .id_result_type, .quantifier = .required },
8354 .{ .kind = .IdResult, .quantifier = .required },8877 .{ .kind = .id_result, .quantifier = .required },
8355 .{ .kind = .IdScope, .quantifier = .required },8878 .{ .kind = .id_scope, .quantifier = .required },
8356 .{ .kind = .IdRef, .quantifier = .required },8879 .{ .kind = .id_ref, .quantifier = .required },
8357 .{ .kind = .IdRef, .quantifier = .required },8880 .{ .kind = .id_ref, .quantifier = .required },
8358 },8881 },
8359 },8882 },
8360 .{8883 .{
8361 .name = "OpGroupNonUniformBallotBitCount",8884 .name = "OpGroupNonUniformBallotBitCount",
8362 .opcode = 342,8885 .opcode = 342,
8363 .operands = &[_]Operand{8886 .operands = &.{
8364 .{ .kind = .IdResultType, .quantifier = .required },8887 .{ .kind = .id_result_type, .quantifier = .required },
8365 .{ .kind = .IdResult, .quantifier = .required },8888 .{ .kind = .id_result, .quantifier = .required },
8366 .{ .kind = .IdScope, .quantifier = .required },8889 .{ .kind = .id_scope, .quantifier = .required },
8367 .{ .kind = .GroupOperation, .quantifier = .required },8890 .{ .kind = .group_operation, .quantifier = .required },
8368 .{ .kind = .IdRef, .quantifier = .required },8891 .{ .kind = .id_ref, .quantifier = .required },
8369 },8892 },
8370 },8893 },
8371 .{8894 .{
8372 .name = "OpGroupNonUniformBallotFindLSB",8895 .name = "OpGroupNonUniformBallotFindLSB",
8373 .opcode = 343,8896 .opcode = 343,
8374 .operands = &[_]Operand{8897 .operands = &.{
8375 .{ .kind = .IdResultType, .quantifier = .required },8898 .{ .kind = .id_result_type, .quantifier = .required },
8376 .{ .kind = .IdResult, .quantifier = .required },8899 .{ .kind = .id_result, .quantifier = .required },
8377 .{ .kind = .IdScope, .quantifier = .required },8900 .{ .kind = .id_scope, .quantifier = .required },
8378 .{ .kind = .IdRef, .quantifier = .required },8901 .{ .kind = .id_ref, .quantifier = .required },
8379 },8902 },
8380 },8903 },
8381 .{8904 .{
8382 .name = "OpGroupNonUniformBallotFindMSB",8905 .name = "OpGroupNonUniformBallotFindMSB",
8383 .opcode = 344,8906 .opcode = 344,
8384 .operands = &[_]Operand{8907 .operands = &.{
8385 .{ .kind = .IdResultType, .quantifier = .required },8908 .{ .kind = .id_result_type, .quantifier = .required },
8386 .{ .kind = .IdResult, .quantifier = .required },8909 .{ .kind = .id_result, .quantifier = .required },
8387 .{ .kind = .IdScope, .quantifier = .required },8910 .{ .kind = .id_scope, .quantifier = .required },
8388 .{ .kind = .IdRef, .quantifier = .required },8911 .{ .kind = .id_ref, .quantifier = .required },
8389 },8912 },
8390 },8913 },
8391 .{8914 .{
8392 .name = "OpGroupNonUniformShuffle",8915 .name = "OpGroupNonUniformShuffle",
8393 .opcode = 345,8916 .opcode = 345,
8394 .operands = &[_]Operand{8917 .operands = &.{
8395 .{ .kind = .IdResultType, .quantifier = .required },8918 .{ .kind = .id_result_type, .quantifier = .required },
8396 .{ .kind = .IdResult, .quantifier = .required },8919 .{ .kind = .id_result, .quantifier = .required },
8397 .{ .kind = .IdScope, .quantifier = .required },8920 .{ .kind = .id_scope, .quantifier = .required },
8398 .{ .kind = .IdRef, .quantifier = .required },8921 .{ .kind = .id_ref, .quantifier = .required },
8399 .{ .kind = .IdRef, .quantifier = .required },8922 .{ .kind = .id_ref, .quantifier = .required },
8400 },8923 },
8401 },8924 },
8402 .{8925 .{
8403 .name = "OpGroupNonUniformShuffleXor",8926 .name = "OpGroupNonUniformShuffleXor",
8404 .opcode = 346,8927 .opcode = 346,
8405 .operands = &[_]Operand{8928 .operands = &.{
8406 .{ .kind = .IdResultType, .quantifier = .required },8929 .{ .kind = .id_result_type, .quantifier = .required },
8407 .{ .kind = .IdResult, .quantifier = .required },8930 .{ .kind = .id_result, .quantifier = .required },
8408 .{ .kind = .IdScope, .quantifier = .required },8931 .{ .kind = .id_scope, .quantifier = .required },
8409 .{ .kind = .IdRef, .quantifier = .required },8932 .{ .kind = .id_ref, .quantifier = .required },
8410 .{ .kind = .IdRef, .quantifier = .required },8933 .{ .kind = .id_ref, .quantifier = .required },
8411 },8934 },
8412 },8935 },
8413 .{8936 .{
8414 .name = "OpGroupNonUniformShuffleUp",8937 .name = "OpGroupNonUniformShuffleUp",
8415 .opcode = 347,8938 .opcode = 347,
8416 .operands = &[_]Operand{8939 .operands = &.{
8417 .{ .kind = .IdResultType, .quantifier = .required },8940 .{ .kind = .id_result_type, .quantifier = .required },
8418 .{ .kind = .IdResult, .quantifier = .required },8941 .{ .kind = .id_result, .quantifier = .required },
8419 .{ .kind = .IdScope, .quantifier = .required },8942 .{ .kind = .id_scope, .quantifier = .required },
8420 .{ .kind = .IdRef, .quantifier = .required },8943 .{ .kind = .id_ref, .quantifier = .required },
8421 .{ .kind = .IdRef, .quantifier = .required },8944 .{ .kind = .id_ref, .quantifier = .required },
8422 },8945 },
8423 },8946 },
8424 .{8947 .{
8425 .name = "OpGroupNonUniformShuffleDown",8948 .name = "OpGroupNonUniformShuffleDown",
8426 .opcode = 348,8949 .opcode = 348,
8427 .operands = &[_]Operand{8950 .operands = &.{
8428 .{ .kind = .IdResultType, .quantifier = .required },8951 .{ .kind = .id_result_type, .quantifier = .required },
8429 .{ .kind = .IdResult, .quantifier = .required },8952 .{ .kind = .id_result, .quantifier = .required },
8430 .{ .kind = .IdScope, .quantifier = .required },8953 .{ .kind = .id_scope, .quantifier = .required },
8431 .{ .kind = .IdRef, .quantifier = .required },8954 .{ .kind = .id_ref, .quantifier = .required },
8432 .{ .kind = .IdRef, .quantifier = .required },8955 .{ .kind = .id_ref, .quantifier = .required },
8433 },8956 },
8434 },8957 },
8435 .{8958 .{
8436 .name = "OpGroupNonUniformIAdd",8959 .name = "OpGroupNonUniformIAdd",
8437 .opcode = 349,8960 .opcode = 349,
8438 .operands = &[_]Operand{8961 .operands = &.{
8439 .{ .kind = .IdResultType, .quantifier = .required },8962 .{ .kind = .id_result_type, .quantifier = .required },
8440 .{ .kind = .IdResult, .quantifier = .required },8963 .{ .kind = .id_result, .quantifier = .required },
8441 .{ .kind = .IdScope, .quantifier = .required },8964 .{ .kind = .id_scope, .quantifier = .required },
8442 .{ .kind = .GroupOperation, .quantifier = .required },8965 .{ .kind = .group_operation, .quantifier = .required },
8443 .{ .kind = .IdRef, .quantifier = .required },8966 .{ .kind = .id_ref, .quantifier = .required },
8444 .{ .kind = .IdRef, .quantifier = .optional },8967 .{ .kind = .id_ref, .quantifier = .optional },
8445 },8968 },
8446 },8969 },
8447 .{8970 .{
8448 .name = "OpGroupNonUniformFAdd",8971 .name = "OpGroupNonUniformFAdd",
8449 .opcode = 350,8972 .opcode = 350,
8450 .operands = &[_]Operand{8973 .operands = &.{
8451 .{ .kind = .IdResultType, .quantifier = .required },8974 .{ .kind = .id_result_type, .quantifier = .required },
8452 .{ .kind = .IdResult, .quantifier = .required },8975 .{ .kind = .id_result, .quantifier = .required },
8453 .{ .kind = .IdScope, .quantifier = .required },8976 .{ .kind = .id_scope, .quantifier = .required },
8454 .{ .kind = .GroupOperation, .quantifier = .required },8977 .{ .kind = .group_operation, .quantifier = .required },
8455 .{ .kind = .IdRef, .quantifier = .required },8978 .{ .kind = .id_ref, .quantifier = .required },
8456 .{ .kind = .IdRef, .quantifier = .optional },8979 .{ .kind = .id_ref, .quantifier = .optional },
8457 },8980 },
8458 },8981 },
8459 .{8982 .{
8460 .name = "OpGroupNonUniformIMul",8983 .name = "OpGroupNonUniformIMul",
8461 .opcode = 351,8984 .opcode = 351,
8462 .operands = &[_]Operand{8985 .operands = &.{
8463 .{ .kind = .IdResultType, .quantifier = .required },8986 .{ .kind = .id_result_type, .quantifier = .required },
8464 .{ .kind = .IdResult, .quantifier = .required },8987 .{ .kind = .id_result, .quantifier = .required },
8465 .{ .kind = .IdScope, .quantifier = .required },8988 .{ .kind = .id_scope, .quantifier = .required },
8466 .{ .kind = .GroupOperation, .quantifier = .required },8989 .{ .kind = .group_operation, .quantifier = .required },
8467 .{ .kind = .IdRef, .quantifier = .required },8990 .{ .kind = .id_ref, .quantifier = .required },
8468 .{ .kind = .IdRef, .quantifier = .optional },8991 .{ .kind = .id_ref, .quantifier = .optional },
8469 },8992 },
8470 },8993 },
8471 .{8994 .{
8472 .name = "OpGroupNonUniformFMul",8995 .name = "OpGroupNonUniformFMul",
8473 .opcode = 352,8996 .opcode = 352,
8474 .operands = &[_]Operand{8997 .operands = &.{
8475 .{ .kind = .IdResultType, .quantifier = .required },8998 .{ .kind = .id_result_type, .quantifier = .required },
8476 .{ .kind = .IdResult, .quantifier = .required },8999 .{ .kind = .id_result, .quantifier = .required },
8477 .{ .kind = .IdScope, .quantifier = .required },9000 .{ .kind = .id_scope, .quantifier = .required },
8478 .{ .kind = .GroupOperation, .quantifier = .required },9001 .{ .kind = .group_operation, .quantifier = .required },
8479 .{ .kind = .IdRef, .quantifier = .required },9002 .{ .kind = .id_ref, .quantifier = .required },
8480 .{ .kind = .IdRef, .quantifier = .optional },9003 .{ .kind = .id_ref, .quantifier = .optional },
8481 },9004 },
8482 },9005 },
8483 .{9006 .{
8484 .name = "OpGroupNonUniformSMin",9007 .name = "OpGroupNonUniformSMin",
8485 .opcode = 353,9008 .opcode = 353,
8486 .operands = &[_]Operand{9009 .operands = &.{
8487 .{ .kind = .IdResultType, .quantifier = .required },9010 .{ .kind = .id_result_type, .quantifier = .required },
8488 .{ .kind = .IdResult, .quantifier = .required },9011 .{ .kind = .id_result, .quantifier = .required },
8489 .{ .kind = .IdScope, .quantifier = .required },9012 .{ .kind = .id_scope, .quantifier = .required },
8490 .{ .kind = .GroupOperation, .quantifier = .required },9013 .{ .kind = .group_operation, .quantifier = .required },
8491 .{ .kind = .IdRef, .quantifier = .required },9014 .{ .kind = .id_ref, .quantifier = .required },
8492 .{ .kind = .IdRef, .quantifier = .optional },9015 .{ .kind = .id_ref, .quantifier = .optional },
8493 },9016 },
8494 },9017 },
8495 .{9018 .{
8496 .name = "OpGroupNonUniformUMin",9019 .name = "OpGroupNonUniformUMin",
8497 .opcode = 354,9020 .opcode = 354,
8498 .operands = &[_]Operand{9021 .operands = &.{
8499 .{ .kind = .IdResultType, .quantifier = .required },9022 .{ .kind = .id_result_type, .quantifier = .required },
8500 .{ .kind = .IdResult, .quantifier = .required },9023 .{ .kind = .id_result, .quantifier = .required },
8501 .{ .kind = .IdScope, .quantifier = .required },9024 .{ .kind = .id_scope, .quantifier = .required },
8502 .{ .kind = .GroupOperation, .quantifier = .required },9025 .{ .kind = .group_operation, .quantifier = .required },
8503 .{ .kind = .IdRef, .quantifier = .required },9026 .{ .kind = .id_ref, .quantifier = .required },
8504 .{ .kind = .IdRef, .quantifier = .optional },9027 .{ .kind = .id_ref, .quantifier = .optional },
8505 },9028 },
8506 },9029 },
8507 .{9030 .{
8508 .name = "OpGroupNonUniformFMin",9031 .name = "OpGroupNonUniformFMin",
8509 .opcode = 355,9032 .opcode = 355,
8510 .operands = &[_]Operand{9033 .operands = &.{
8511 .{ .kind = .IdResultType, .quantifier = .required },9034 .{ .kind = .id_result_type, .quantifier = .required },
8512 .{ .kind = .IdResult, .quantifier = .required },9035 .{ .kind = .id_result, .quantifier = .required },
8513 .{ .kind = .IdScope, .quantifier = .required },9036 .{ .kind = .id_scope, .quantifier = .required },
8514 .{ .kind = .GroupOperation, .quantifier = .required },9037 .{ .kind = .group_operation, .quantifier = .required },
8515 .{ .kind = .IdRef, .quantifier = .required },9038 .{ .kind = .id_ref, .quantifier = .required },
8516 .{ .kind = .IdRef, .quantifier = .optional },9039 .{ .kind = .id_ref, .quantifier = .optional },
8517 },9040 },
8518 },9041 },
8519 .{9042 .{
8520 .name = "OpGroupNonUniformSMax",9043 .name = "OpGroupNonUniformSMax",
8521 .opcode = 356,9044 .opcode = 356,
8522 .operands = &[_]Operand{9045 .operands = &.{
8523 .{ .kind = .IdResultType, .quantifier = .required },9046 .{ .kind = .id_result_type, .quantifier = .required },
8524 .{ .kind = .IdResult, .quantifier = .required },9047 .{ .kind = .id_result, .quantifier = .required },
8525 .{ .kind = .IdScope, .quantifier = .required },9048 .{ .kind = .id_scope, .quantifier = .required },
8526 .{ .kind = .GroupOperation, .quantifier = .required },9049 .{ .kind = .group_operation, .quantifier = .required },
8527 .{ .kind = .IdRef, .quantifier = .required },9050 .{ .kind = .id_ref, .quantifier = .required },
8528 .{ .kind = .IdRef, .quantifier = .optional },9051 .{ .kind = .id_ref, .quantifier = .optional },
8529 },9052 },
8530 },9053 },
8531 .{9054 .{
8532 .name = "OpGroupNonUniformUMax",9055 .name = "OpGroupNonUniformUMax",
8533 .opcode = 357,9056 .opcode = 357,
8534 .operands = &[_]Operand{9057 .operands = &.{
8535 .{ .kind = .IdResultType, .quantifier = .required },9058 .{ .kind = .id_result_type, .quantifier = .required },
8536 .{ .kind = .IdResult, .quantifier = .required },9059 .{ .kind = .id_result, .quantifier = .required },
8537 .{ .kind = .IdScope, .quantifier = .required },9060 .{ .kind = .id_scope, .quantifier = .required },
8538 .{ .kind = .GroupOperation, .quantifier = .required },9061 .{ .kind = .group_operation, .quantifier = .required },
8539 .{ .kind = .IdRef, .quantifier = .required },9062 .{ .kind = .id_ref, .quantifier = .required },
8540 .{ .kind = .IdRef, .quantifier = .optional },9063 .{ .kind = .id_ref, .quantifier = .optional },
8541 },9064 },
8542 },9065 },
8543 .{9066 .{
8544 .name = "OpGroupNonUniformFMax",9067 .name = "OpGroupNonUniformFMax",
8545 .opcode = 358,9068 .opcode = 358,
8546 .operands = &[_]Operand{9069 .operands = &.{
8547 .{ .kind = .IdResultType, .quantifier = .required },9070 .{ .kind = .id_result_type, .quantifier = .required },
8548 .{ .kind = .IdResult, .quantifier = .required },9071 .{ .kind = .id_result, .quantifier = .required },
8549 .{ .kind = .IdScope, .quantifier = .required },9072 .{ .kind = .id_scope, .quantifier = .required },
8550 .{ .kind = .GroupOperation, .quantifier = .required },9073 .{ .kind = .group_operation, .quantifier = .required },
8551 .{ .kind = .IdRef, .quantifier = .required },9074 .{ .kind = .id_ref, .quantifier = .required },
8552 .{ .kind = .IdRef, .quantifier = .optional },9075 .{ .kind = .id_ref, .quantifier = .optional },
8553 },9076 },
8554 },9077 },
8555 .{9078 .{
8556 .name = "OpGroupNonUniformBitwiseAnd",9079 .name = "OpGroupNonUniformBitwiseAnd",
8557 .opcode = 359,9080 .opcode = 359,
8558 .operands = &[_]Operand{9081 .operands = &.{
8559 .{ .kind = .IdResultType, .quantifier = .required },9082 .{ .kind = .id_result_type, .quantifier = .required },
8560 .{ .kind = .IdResult, .quantifier = .required },9083 .{ .kind = .id_result, .quantifier = .required },
8561 .{ .kind = .IdScope, .quantifier = .required },9084 .{ .kind = .id_scope, .quantifier = .required },
8562 .{ .kind = .GroupOperation, .quantifier = .required },9085 .{ .kind = .group_operation, .quantifier = .required },
8563 .{ .kind = .IdRef, .quantifier = .required },9086 .{ .kind = .id_ref, .quantifier = .required },
8564 .{ .kind = .IdRef, .quantifier = .optional },9087 .{ .kind = .id_ref, .quantifier = .optional },
8565 },9088 },
8566 },9089 },
8567 .{9090 .{
8568 .name = "OpGroupNonUniformBitwiseOr",9091 .name = "OpGroupNonUniformBitwiseOr",
8569 .opcode = 360,9092 .opcode = 360,
8570 .operands = &[_]Operand{9093 .operands = &.{
8571 .{ .kind = .IdResultType, .quantifier = .required },9094 .{ .kind = .id_result_type, .quantifier = .required },
8572 .{ .kind = .IdResult, .quantifier = .required },9095 .{ .kind = .id_result, .quantifier = .required },
8573 .{ .kind = .IdScope, .quantifier = .required },9096 .{ .kind = .id_scope, .quantifier = .required },
8574 .{ .kind = .GroupOperation, .quantifier = .required },9097 .{ .kind = .group_operation, .quantifier = .required },
8575 .{ .kind = .IdRef, .quantifier = .required },9098 .{ .kind = .id_ref, .quantifier = .required },
8576 .{ .kind = .IdRef, .quantifier = .optional },9099 .{ .kind = .id_ref, .quantifier = .optional },
8577 },9100 },
8578 },9101 },
8579 .{9102 .{
8580 .name = "OpGroupNonUniformBitwiseXor",9103 .name = "OpGroupNonUniformBitwiseXor",
8581 .opcode = 361,9104 .opcode = 361,
8582 .operands = &[_]Operand{9105 .operands = &.{
8583 .{ .kind = .IdResultType, .quantifier = .required },9106 .{ .kind = .id_result_type, .quantifier = .required },
8584 .{ .kind = .IdResult, .quantifier = .required },9107 .{ .kind = .id_result, .quantifier = .required },
8585 .{ .kind = .IdScope, .quantifier = .required },9108 .{ .kind = .id_scope, .quantifier = .required },
8586 .{ .kind = .GroupOperation, .quantifier = .required },9109 .{ .kind = .group_operation, .quantifier = .required },
8587 .{ .kind = .IdRef, .quantifier = .required },9110 .{ .kind = .id_ref, .quantifier = .required },
8588 .{ .kind = .IdRef, .quantifier = .optional },9111 .{ .kind = .id_ref, .quantifier = .optional },
8589 },9112 },
8590 },9113 },
8591 .{9114 .{
8592 .name = "OpGroupNonUniformLogicalAnd",9115 .name = "OpGroupNonUniformLogicalAnd",
8593 .opcode = 362,9116 .opcode = 362,
8594 .operands = &[_]Operand{9117 .operands = &.{
8595 .{ .kind = .IdResultType, .quantifier = .required },9118 .{ .kind = .id_result_type, .quantifier = .required },
8596 .{ .kind = .IdResult, .quantifier = .required },9119 .{ .kind = .id_result, .quantifier = .required },
8597 .{ .kind = .IdScope, .quantifier = .required },9120 .{ .kind = .id_scope, .quantifier = .required },
8598 .{ .kind = .GroupOperation, .quantifier = .required },9121 .{ .kind = .group_operation, .quantifier = .required },
8599 .{ .kind = .IdRef, .quantifier = .required },9122 .{ .kind = .id_ref, .quantifier = .required },
8600 .{ .kind = .IdRef, .quantifier = .optional },9123 .{ .kind = .id_ref, .quantifier = .optional },
8601 },9124 },
8602 },9125 },
8603 .{9126 .{
8604 .name = "OpGroupNonUniformLogicalOr",9127 .name = "OpGroupNonUniformLogicalOr",
8605 .opcode = 363,9128 .opcode = 363,
8606 .operands = &[_]Operand{9129 .operands = &.{
8607 .{ .kind = .IdResultType, .quantifier = .required },9130 .{ .kind = .id_result_type, .quantifier = .required },
8608 .{ .kind = .IdResult, .quantifier = .required },9131 .{ .kind = .id_result, .quantifier = .required },
8609 .{ .kind = .IdScope, .quantifier = .required },9132 .{ .kind = .id_scope, .quantifier = .required },
8610 .{ .kind = .GroupOperation, .quantifier = .required },9133 .{ .kind = .group_operation, .quantifier = .required },
8611 .{ .kind = .IdRef, .quantifier = .required },9134 .{ .kind = .id_ref, .quantifier = .required },
8612 .{ .kind = .IdRef, .quantifier = .optional },9135 .{ .kind = .id_ref, .quantifier = .optional },
8613 },9136 },
8614 },9137 },
8615 .{9138 .{
8616 .name = "OpGroupNonUniformLogicalXor",9139 .name = "OpGroupNonUniformLogicalXor",
8617 .opcode = 364,9140 .opcode = 364,
8618 .operands = &[_]Operand{9141 .operands = &.{
8619 .{ .kind = .IdResultType, .quantifier = .required },9142 .{ .kind = .id_result_type, .quantifier = .required },
8620 .{ .kind = .IdResult, .quantifier = .required },9143 .{ .kind = .id_result, .quantifier = .required },
8621 .{ .kind = .IdScope, .quantifier = .required },9144 .{ .kind = .id_scope, .quantifier = .required },
8622 .{ .kind = .GroupOperation, .quantifier = .required },9145 .{ .kind = .group_operation, .quantifier = .required },
8623 .{ .kind = .IdRef, .quantifier = .required },9146 .{ .kind = .id_ref, .quantifier = .required },
8624 .{ .kind = .IdRef, .quantifier = .optional },9147 .{ .kind = .id_ref, .quantifier = .optional },
8625 },9148 },
8626 },9149 },
8627 .{9150 .{
8628 .name = "OpGroupNonUniformQuadBroadcast",9151 .name = "OpGroupNonUniformQuadBroadcast",
8629 .opcode = 365,9152 .opcode = 365,
8630 .operands = &[_]Operand{9153 .operands = &.{
8631 .{ .kind = .IdResultType, .quantifier = .required },9154 .{ .kind = .id_result_type, .quantifier = .required },
8632 .{ .kind = .IdResult, .quantifier = .required },9155 .{ .kind = .id_result, .quantifier = .required },
8633 .{ .kind = .IdScope, .quantifier = .required },9156 .{ .kind = .id_scope, .quantifier = .required },
8634 .{ .kind = .IdRef, .quantifier = .required },9157 .{ .kind = .id_ref, .quantifier = .required },
8635 .{ .kind = .IdRef, .quantifier = .required },9158 .{ .kind = .id_ref, .quantifier = .required },
8636 },9159 },
8637 },9160 },
8638 .{9161 .{
8639 .name = "OpGroupNonUniformQuadSwap",9162 .name = "OpGroupNonUniformQuadSwap",
8640 .opcode = 366,9163 .opcode = 366,
8641 .operands = &[_]Operand{9164 .operands = &.{
8642 .{ .kind = .IdResultType, .quantifier = .required },9165 .{ .kind = .id_result_type, .quantifier = .required },
8643 .{ .kind = .IdResult, .quantifier = .required },9166 .{ .kind = .id_result, .quantifier = .required },
8644 .{ .kind = .IdScope, .quantifier = .required },9167 .{ .kind = .id_scope, .quantifier = .required },
8645 .{ .kind = .IdRef, .quantifier = .required },9168 .{ .kind = .id_ref, .quantifier = .required },
8646 .{ .kind = .IdRef, .quantifier = .required },9169 .{ .kind = .id_ref, .quantifier = .required },
8647 },9170 },
8648 },9171 },
8649 .{9172 .{
8650 .name = "OpCopyLogical",9173 .name = "OpCopyLogical",
8651 .opcode = 400,9174 .opcode = 400,
8652 .operands = &[_]Operand{9175 .operands = &.{
8653 .{ .kind = .IdResultType, .quantifier = .required },9176 .{ .kind = .id_result_type, .quantifier = .required },
8654 .{ .kind = .IdResult, .quantifier = .required },9177 .{ .kind = .id_result, .quantifier = .required },
8655 .{ .kind = .IdRef, .quantifier = .required },9178 .{ .kind = .id_ref, .quantifier = .required },
8656 },9179 },
8657 },9180 },
8658 .{9181 .{
8659 .name = "OpPtrEqual",9182 .name = "OpPtrEqual",
8660 .opcode = 401,9183 .opcode = 401,
8661 .operands = &[_]Operand{9184 .operands = &.{
8662 .{ .kind = .IdResultType, .quantifier = .required },9185 .{ .kind = .id_result_type, .quantifier = .required },
8663 .{ .kind = .IdResult, .quantifier = .required },9186 .{ .kind = .id_result, .quantifier = .required },
8664 .{ .kind = .IdRef, .quantifier = .required },9187 .{ .kind = .id_ref, .quantifier = .required },
8665 .{ .kind = .IdRef, .quantifier = .required },9188 .{ .kind = .id_ref, .quantifier = .required },
8666 },9189 },
8667 },9190 },
8668 .{9191 .{
8669 .name = "OpPtrNotEqual",9192 .name = "OpPtrNotEqual",
8670 .opcode = 402,9193 .opcode = 402,
8671 .operands = &[_]Operand{9194 .operands = &.{
8672 .{ .kind = .IdResultType, .quantifier = .required },9195 .{ .kind = .id_result_type, .quantifier = .required },
8673 .{ .kind = .IdResult, .quantifier = .required },9196 .{ .kind = .id_result, .quantifier = .required },
8674 .{ .kind = .IdRef, .quantifier = .required },9197 .{ .kind = .id_ref, .quantifier = .required },
8675 .{ .kind = .IdRef, .quantifier = .required },9198 .{ .kind = .id_ref, .quantifier = .required },
8676 },9199 },
8677 },9200 },
8678 .{9201 .{
8679 .name = "OpPtrDiff",9202 .name = "OpPtrDiff",
8680 .opcode = 403,9203 .opcode = 403,
8681 .operands = &[_]Operand{9204 .operands = &.{
8682 .{ .kind = .IdResultType, .quantifier = .required },9205 .{ .kind = .id_result_type, .quantifier = .required },
8683 .{ .kind = .IdResult, .quantifier = .required },9206 .{ .kind = .id_result, .quantifier = .required },
8684 .{ .kind = .IdRef, .quantifier = .required },9207 .{ .kind = .id_ref, .quantifier = .required },
8685 .{ .kind = .IdRef, .quantifier = .required },9208 .{ .kind = .id_ref, .quantifier = .required },
8686 },9209 },
8687 },9210 },
8688 .{9211 .{
8689 .name = "OpColorAttachmentReadEXT",9212 .name = "OpColorAttachmentReadEXT",
8690 .opcode = 4160,9213 .opcode = 4160,
8691 .operands = &[_]Operand{9214 .operands = &.{
8692 .{ .kind = .IdResultType, .quantifier = .required },9215 .{ .kind = .id_result_type, .quantifier = .required },
8693 .{ .kind = .IdResult, .quantifier = .required },9216 .{ .kind = .id_result, .quantifier = .required },
8694 .{ .kind = .IdRef, .quantifier = .required },9217 .{ .kind = .id_ref, .quantifier = .required },
8695 .{ .kind = .IdRef, .quantifier = .optional },9218 .{ .kind = .id_ref, .quantifier = .optional },
8696 },9219 },
8697 },9220 },
8698 .{9221 .{
8699 .name = "OpDepthAttachmentReadEXT",9222 .name = "OpDepthAttachmentReadEXT",
8700 .opcode = 4161,9223 .opcode = 4161,
8701 .operands = &[_]Operand{9224 .operands = &.{
8702 .{ .kind = .IdResultType, .quantifier = .required },9225 .{ .kind = .id_result_type, .quantifier = .required },
8703 .{ .kind = .IdResult, .quantifier = .required },9226 .{ .kind = .id_result, .quantifier = .required },
8704 .{ .kind = .IdRef, .quantifier = .optional },9227 .{ .kind = .id_ref, .quantifier = .optional },
8705 },9228 },
8706 },9229 },
8707 .{9230 .{
8708 .name = "OpStencilAttachmentReadEXT",9231 .name = "OpStencilAttachmentReadEXT",
8709 .opcode = 4162,9232 .opcode = 4162,
8710 .operands = &[_]Operand{9233 .operands = &.{
8711 .{ .kind = .IdResultType, .quantifier = .required },9234 .{ .kind = .id_result_type, .quantifier = .required },
8712 .{ .kind = .IdResult, .quantifier = .required },9235 .{ .kind = .id_result, .quantifier = .required },
8713 .{ .kind = .IdRef, .quantifier = .optional },9236 .{ .kind = .id_ref, .quantifier = .optional },
9237 },
9238 },
9239 .{
9240 .name = "OpTypeTensorARM",
9241 .opcode = 4163,
9242 .operands = &.{
9243 .{ .kind = .id_result, .quantifier = .required },
9244 .{ .kind = .id_ref, .quantifier = .required },
9245 .{ .kind = .id_ref, .quantifier = .optional },
9246 .{ .kind = .id_ref, .quantifier = .optional },
9247 },
9248 },
9249 .{
9250 .name = "OpTensorReadARM",
9251 .opcode = 4164,
9252 .operands = &.{
9253 .{ .kind = .id_result_type, .quantifier = .required },
9254 .{ .kind = .id_result, .quantifier = .required },
9255 .{ .kind = .id_ref, .quantifier = .required },
9256 .{ .kind = .id_ref, .quantifier = .required },
9257 .{ .kind = .tensor_operands, .quantifier = .optional },
9258 },
9259 },
9260 .{
9261 .name = "OpTensorWriteARM",
9262 .opcode = 4165,
9263 .operands = &.{
9264 .{ .kind = .id_ref, .quantifier = .required },
9265 .{ .kind = .id_ref, .quantifier = .required },
9266 .{ .kind = .id_ref, .quantifier = .required },
9267 .{ .kind = .tensor_operands, .quantifier = .optional },
9268 },
9269 },
9270 .{
9271 .name = "OpTensorQuerySizeARM",
9272 .opcode = 4166,
9273 .operands = &.{
9274 .{ .kind = .id_result_type, .quantifier = .required },
9275 .{ .kind = .id_result, .quantifier = .required },
9276 .{ .kind = .id_ref, .quantifier = .required },
9277 .{ .kind = .id_ref, .quantifier = .required },
9278 },
9279 },
9280 .{
9281 .name = "OpGraphConstantARM",
9282 .opcode = 4181,
9283 .operands = &.{
9284 .{ .kind = .id_result_type, .quantifier = .required },
9285 .{ .kind = .id_result, .quantifier = .required },
9286 .{ .kind = .literal_integer, .quantifier = .required },
9287 },
9288 },
9289 .{
9290 .name = "OpGraphEntryPointARM",
9291 .opcode = 4182,
9292 .operands = &.{
9293 .{ .kind = .id_ref, .quantifier = .required },
9294 .{ .kind = .literal_string, .quantifier = .required },
9295 .{ .kind = .id_ref, .quantifier = .variadic },
9296 },
9297 },
9298 .{
9299 .name = "OpGraphARM",
9300 .opcode = 4183,
9301 .operands = &.{
9302 .{ .kind = .id_result_type, .quantifier = .required },
9303 .{ .kind = .id_result, .quantifier = .required },
9304 },
9305 },
9306 .{
9307 .name = "OpGraphInputARM",
9308 .opcode = 4184,
9309 .operands = &.{
9310 .{ .kind = .id_result_type, .quantifier = .required },
9311 .{ .kind = .id_result, .quantifier = .required },
9312 .{ .kind = .id_ref, .quantifier = .required },
9313 .{ .kind = .id_ref, .quantifier = .variadic },
9314 },
9315 },
9316 .{
9317 .name = "OpGraphSetOutputARM",
9318 .opcode = 4185,
9319 .operands = &.{
9320 .{ .kind = .id_ref, .quantifier = .required },
9321 .{ .kind = .id_ref, .quantifier = .required },
9322 .{ .kind = .id_ref, .quantifier = .variadic },
9323 },
9324 },
9325 .{
9326 .name = "OpGraphEndARM",
9327 .opcode = 4186,
9328 .operands = &.{},
9329 },
9330 .{
9331 .name = "OpTypeGraphARM",
9332 .opcode = 4190,
9333 .operands = &.{
9334 .{ .kind = .id_result, .quantifier = .required },
9335 .{ .kind = .literal_integer, .quantifier = .required },
9336 .{ .kind = .id_ref, .quantifier = .variadic },
8714 },9337 },
8715 },9338 },
8716 .{9339 .{
8717 .name = "OpTerminateInvocation",9340 .name = "OpTerminateInvocation",
8718 .opcode = 4416,9341 .opcode = 4416,
8719 .operands = &[_]Operand{},9342 .operands = &.{},
9343 },
9344 .{
9345 .name = "OpTypeUntypedPointerKHR",
9346 .opcode = 4417,
9347 .operands = &.{
9348 .{ .kind = .id_result, .quantifier = .required },
9349 .{ .kind = .storage_class, .quantifier = .required },
9350 },
9351 },
9352 .{
9353 .name = "OpUntypedVariableKHR",
9354 .opcode = 4418,
9355 .operands = &.{
9356 .{ .kind = .id_result_type, .quantifier = .required },
9357 .{ .kind = .id_result, .quantifier = .required },
9358 .{ .kind = .storage_class, .quantifier = .required },
9359 .{ .kind = .id_ref, .quantifier = .optional },
9360 .{ .kind = .id_ref, .quantifier = .optional },
9361 },
9362 },
9363 .{
9364 .name = "OpUntypedAccessChainKHR",
9365 .opcode = 4419,
9366 .operands = &.{
9367 .{ .kind = .id_result_type, .quantifier = .required },
9368 .{ .kind = .id_result, .quantifier = .required },
9369 .{ .kind = .id_ref, .quantifier = .required },
9370 .{ .kind = .id_ref, .quantifier = .required },
9371 .{ .kind = .id_ref, .quantifier = .variadic },
9372 },
9373 },
9374 .{
9375 .name = "OpUntypedInBoundsAccessChainKHR",
9376 .opcode = 4420,
9377 .operands = &.{
9378 .{ .kind = .id_result_type, .quantifier = .required },
9379 .{ .kind = .id_result, .quantifier = .required },
9380 .{ .kind = .id_ref, .quantifier = .required },
9381 .{ .kind = .id_ref, .quantifier = .required },
9382 .{ .kind = .id_ref, .quantifier = .variadic },
9383 },
8720 },9384 },
8721 .{9385 .{
8722 .name = "OpSubgroupBallotKHR",9386 .name = "OpSubgroupBallotKHR",
8723 .opcode = 4421,9387 .opcode = 4421,
8724 .operands = &[_]Operand{9388 .operands = &.{
8725 .{ .kind = .IdResultType, .quantifier = .required },9389 .{ .kind = .id_result_type, .quantifier = .required },
8726 .{ .kind = .IdResult, .quantifier = .required },9390 .{ .kind = .id_result, .quantifier = .required },
8727 .{ .kind = .IdRef, .quantifier = .required },9391 .{ .kind = .id_ref, .quantifier = .required },
8728 },9392 },
8729 },9393 },
8730 .{9394 .{
8731 .name = "OpSubgroupFirstInvocationKHR",9395 .name = "OpSubgroupFirstInvocationKHR",
8732 .opcode = 4422,9396 .opcode = 4422,
8733 .operands = &[_]Operand{9397 .operands = &.{
8734 .{ .kind = .IdResultType, .quantifier = .required },9398 .{ .kind = .id_result_type, .quantifier = .required },
8735 .{ .kind = .IdResult, .quantifier = .required },9399 .{ .kind = .id_result, .quantifier = .required },
8736 .{ .kind = .IdRef, .quantifier = .required },9400 .{ .kind = .id_ref, .quantifier = .required },
9401 },
9402 },
9403 .{
9404 .name = "OpUntypedPtrAccessChainKHR",
9405 .opcode = 4423,
9406 .operands = &.{
9407 .{ .kind = .id_result_type, .quantifier = .required },
9408 .{ .kind = .id_result, .quantifier = .required },
9409 .{ .kind = .id_ref, .quantifier = .required },
9410 .{ .kind = .id_ref, .quantifier = .required },
9411 .{ .kind = .id_ref, .quantifier = .required },
9412 .{ .kind = .id_ref, .quantifier = .variadic },
9413 },
9414 },
9415 .{
9416 .name = "OpUntypedInBoundsPtrAccessChainKHR",
9417 .opcode = 4424,
9418 .operands = &.{
9419 .{ .kind = .id_result_type, .quantifier = .required },
9420 .{ .kind = .id_result, .quantifier = .required },
9421 .{ .kind = .id_ref, .quantifier = .required },
9422 .{ .kind = .id_ref, .quantifier = .required },
9423 .{ .kind = .id_ref, .quantifier = .required },
9424 .{ .kind = .id_ref, .quantifier = .variadic },
9425 },
9426 },
9427 .{
9428 .name = "OpUntypedArrayLengthKHR",
9429 .opcode = 4425,
9430 .operands = &.{
9431 .{ .kind = .id_result_type, .quantifier = .required },
9432 .{ .kind = .id_result, .quantifier = .required },
9433 .{ .kind = .id_ref, .quantifier = .required },
9434 .{ .kind = .id_ref, .quantifier = .required },
9435 .{ .kind = .literal_integer, .quantifier = .required },
9436 },
9437 },
9438 .{
9439 .name = "OpUntypedPrefetchKHR",
9440 .opcode = 4426,
9441 .operands = &.{
9442 .{ .kind = .id_ref, .quantifier = .required },
9443 .{ .kind = .id_ref, .quantifier = .required },
9444 .{ .kind = .id_ref, .quantifier = .optional },
9445 .{ .kind = .id_ref, .quantifier = .optional },
9446 .{ .kind = .id_ref, .quantifier = .optional },
8737 },9447 },
8738 },9448 },
8739 .{9449 .{
8740 .name = "OpSubgroupAllKHR",9450 .name = "OpSubgroupAllKHR",
8741 .opcode = 4428,9451 .opcode = 4428,
8742 .operands = &[_]Operand{9452 .operands = &.{
8743 .{ .kind = .IdResultType, .quantifier = .required },9453 .{ .kind = .id_result_type, .quantifier = .required },
8744 .{ .kind = .IdResult, .quantifier = .required },9454 .{ .kind = .id_result, .quantifier = .required },
8745 .{ .kind = .IdRef, .quantifier = .required },9455 .{ .kind = .id_ref, .quantifier = .required },
8746 },9456 },
8747 },9457 },
8748 .{9458 .{
8749 .name = "OpSubgroupAnyKHR",9459 .name = "OpSubgroupAnyKHR",
8750 .opcode = 4429,9460 .opcode = 4429,
8751 .operands = &[_]Operand{9461 .operands = &.{
8752 .{ .kind = .IdResultType, .quantifier = .required },9462 .{ .kind = .id_result_type, .quantifier = .required },
8753 .{ .kind = .IdResult, .quantifier = .required },9463 .{ .kind = .id_result, .quantifier = .required },
8754 .{ .kind = .IdRef, .quantifier = .required },9464 .{ .kind = .id_ref, .quantifier = .required },
8755 },9465 },
8756 },9466 },
8757 .{9467 .{
8758 .name = "OpSubgroupAllEqualKHR",9468 .name = "OpSubgroupAllEqualKHR",
8759 .opcode = 4430,9469 .opcode = 4430,
8760 .operands = &[_]Operand{9470 .operands = &.{
8761 .{ .kind = .IdResultType, .quantifier = .required },9471 .{ .kind = .id_result_type, .quantifier = .required },
8762 .{ .kind = .IdResult, .quantifier = .required },9472 .{ .kind = .id_result, .quantifier = .required },
8763 .{ .kind = .IdRef, .quantifier = .required },9473 .{ .kind = .id_ref, .quantifier = .required },
8764 },9474 },
8765 },9475 },
8766 .{9476 .{
8767 .name = "OpGroupNonUniformRotateKHR",9477 .name = "OpGroupNonUniformRotateKHR",
8768 .opcode = 4431,9478 .opcode = 4431,
8769 .operands = &[_]Operand{9479 .operands = &.{
8770 .{ .kind = .IdResultType, .quantifier = .required },9480 .{ .kind = .id_result_type, .quantifier = .required },
8771 .{ .kind = .IdResult, .quantifier = .required },9481 .{ .kind = .id_result, .quantifier = .required },
8772 .{ .kind = .IdScope, .quantifier = .required },9482 .{ .kind = .id_scope, .quantifier = .required },
8773 .{ .kind = .IdRef, .quantifier = .required },9483 .{ .kind = .id_ref, .quantifier = .required },
8774 .{ .kind = .IdRef, .quantifier = .required },9484 .{ .kind = .id_ref, .quantifier = .required },
8775 .{ .kind = .IdRef, .quantifier = .optional },9485 .{ .kind = .id_ref, .quantifier = .optional },
8776 },9486 },
8777 },9487 },
8778 .{9488 .{
8779 .name = "OpSubgroupReadInvocationKHR",9489 .name = "OpSubgroupReadInvocationKHR",
8780 .opcode = 4432,9490 .opcode = 4432,
8781 .operands = &[_]Operand{9491 .operands = &.{
8782 .{ .kind = .IdResultType, .quantifier = .required },9492 .{ .kind = .id_result_type, .quantifier = .required },
8783 .{ .kind = .IdResult, .quantifier = .required },9493 .{ .kind = .id_result, .quantifier = .required },
8784 .{ .kind = .IdRef, .quantifier = .required },9494 .{ .kind = .id_ref, .quantifier = .required },
8785 .{ .kind = .IdRef, .quantifier = .required },9495 .{ .kind = .id_ref, .quantifier = .required },
9496 },
9497 },
9498 .{
9499 .name = "OpExtInstWithForwardRefsKHR",
9500 .opcode = 4433,
9501 .operands = &.{
9502 .{ .kind = .id_result_type, .quantifier = .required },
9503 .{ .kind = .id_result, .quantifier = .required },
9504 .{ .kind = .id_ref, .quantifier = .required },
9505 .{ .kind = .literal_ext_inst_integer, .quantifier = .required },
9506 .{ .kind = .id_ref, .quantifier = .variadic },
8786 },9507 },
8787 },9508 },
8788 .{9509 .{
8789 .name = "OpTraceRayKHR",9510 .name = "OpTraceRayKHR",
8790 .opcode = 4445,9511 .opcode = 4445,
8791 .operands = &[_]Operand{9512 .operands = &.{
8792 .{ .kind = .IdRef, .quantifier = .required },9513 .{ .kind = .id_ref, .quantifier = .required },
8793 .{ .kind = .IdRef, .quantifier = .required },9514 .{ .kind = .id_ref, .quantifier = .required },
8794 .{ .kind = .IdRef, .quantifier = .required },9515 .{ .kind = .id_ref, .quantifier = .required },
8795 .{ .kind = .IdRef, .quantifier = .required },9516 .{ .kind = .id_ref, .quantifier = .required },
8796 .{ .kind = .IdRef, .quantifier = .required },9517 .{ .kind = .id_ref, .quantifier = .required },
8797 .{ .kind = .IdRef, .quantifier = .required },9518 .{ .kind = .id_ref, .quantifier = .required },
8798 .{ .kind = .IdRef, .quantifier = .required },9519 .{ .kind = .id_ref, .quantifier = .required },
8799 .{ .kind = .IdRef, .quantifier = .required },9520 .{ .kind = .id_ref, .quantifier = .required },
8800 .{ .kind = .IdRef, .quantifier = .required },9521 .{ .kind = .id_ref, .quantifier = .required },
8801 .{ .kind = .IdRef, .quantifier = .required },9522 .{ .kind = .id_ref, .quantifier = .required },
8802 .{ .kind = .IdRef, .quantifier = .required },9523 .{ .kind = .id_ref, .quantifier = .required },
8803 },9524 },
8804 },9525 },
8805 .{9526 .{
8806 .name = "OpExecuteCallableKHR",9527 .name = "OpExecuteCallableKHR",
8807 .opcode = 4446,9528 .opcode = 4446,
8808 .operands = &[_]Operand{9529 .operands = &.{
8809 .{ .kind = .IdRef, .quantifier = .required },9530 .{ .kind = .id_ref, .quantifier = .required },
8810 .{ .kind = .IdRef, .quantifier = .required },9531 .{ .kind = .id_ref, .quantifier = .required },
8811 },9532 },
8812 },9533 },
8813 .{9534 .{
8814 .name = "OpConvertUToAccelerationStructureKHR",9535 .name = "OpConvertUToAccelerationStructureKHR",
8815 .opcode = 4447,9536 .opcode = 4447,
8816 .operands = &[_]Operand{9537 .operands = &.{
8817 .{ .kind = .IdResultType, .quantifier = .required },9538 .{ .kind = .id_result_type, .quantifier = .required },
8818 .{ .kind = .IdResult, .quantifier = .required },9539 .{ .kind = .id_result, .quantifier = .required },
8819 .{ .kind = .IdRef, .quantifier = .required },9540 .{ .kind = .id_ref, .quantifier = .required },
8820 },9541 },
8821 },9542 },
8822 .{9543 .{
8823 .name = "OpIgnoreIntersectionKHR",9544 .name = "OpIgnoreIntersectionKHR",
8824 .opcode = 4448,9545 .opcode = 4448,
8825 .operands = &[_]Operand{},9546 .operands = &.{},
8826 },9547 },
8827 .{9548 .{
8828 .name = "OpTerminateRayKHR",9549 .name = "OpTerminateRayKHR",
8829 .opcode = 4449,9550 .opcode = 4449,
8830 .operands = &[_]Operand{},9551 .operands = &.{},
8831 },9552 },
8832 .{9553 .{
8833 .name = "OpSDot",9554 .name = "OpSDot",
8834 .opcode = 4450,9555 .opcode = 4450,
8835 .operands = &[_]Operand{9556 .operands = &.{
8836 .{ .kind = .IdResultType, .quantifier = .required },9557 .{ .kind = .id_result_type, .quantifier = .required },
8837 .{ .kind = .IdResult, .quantifier = .required },9558 .{ .kind = .id_result, .quantifier = .required },
8838 .{ .kind = .IdRef, .quantifier = .required },9559 .{ .kind = .id_ref, .quantifier = .required },
8839 .{ .kind = .IdRef, .quantifier = .required },9560 .{ .kind = .id_ref, .quantifier = .required },
8840 .{ .kind = .PackedVectorFormat, .quantifier = .optional },9561 .{ .kind = .packed_vector_format, .quantifier = .optional },
8841 },
8842 },
8843 .{
8844 .name = "OpSDotKHR",
8845 .opcode = 4450,
8846 .operands = &[_]Operand{
8847 .{ .kind = .IdResultType, .quantifier = .required },
8848 .{ .kind = .IdResult, .quantifier = .required },
8849 .{ .kind = .IdRef, .quantifier = .required },
8850 .{ .kind = .IdRef, .quantifier = .required },
8851 .{ .kind = .PackedVectorFormat, .quantifier = .optional },
8852 },9562 },
8853 },9563 },
8854 .{9564 .{
8855 .name = "OpUDot",9565 .name = "OpUDot",
8856 .opcode = 4451,9566 .opcode = 4451,
8857 .operands = &[_]Operand{9567 .operands = &.{
8858 .{ .kind = .IdResultType, .quantifier = .required },9568 .{ .kind = .id_result_type, .quantifier = .required },
8859 .{ .kind = .IdResult, .quantifier = .required },9569 .{ .kind = .id_result, .quantifier = .required },
8860 .{ .kind = .IdRef, .quantifier = .required },9570 .{ .kind = .id_ref, .quantifier = .required },
8861 .{ .kind = .IdRef, .quantifier = .required },9571 .{ .kind = .id_ref, .quantifier = .required },
8862 .{ .kind = .PackedVectorFormat, .quantifier = .optional },9572 .{ .kind = .packed_vector_format, .quantifier = .optional },
8863 },
8864 },
8865 .{
8866 .name = "OpUDotKHR",
8867 .opcode = 4451,
8868 .operands = &[_]Operand{
8869 .{ .kind = .IdResultType, .quantifier = .required },
8870 .{ .kind = .IdResult, .quantifier = .required },
8871 .{ .kind = .IdRef, .quantifier = .required },
8872 .{ .kind = .IdRef, .quantifier = .required },
8873 .{ .kind = .PackedVectorFormat, .quantifier = .optional },
8874 },9573 },
8875 },9574 },
8876 .{9575 .{
8877 .name = "OpSUDot",9576 .name = "OpSUDot",
8878 .opcode = 4452,9577 .opcode = 4452,
8879 .operands = &[_]Operand{9578 .operands = &.{
8880 .{ .kind = .IdResultType, .quantifier = .required },9579 .{ .kind = .id_result_type, .quantifier = .required },
8881 .{ .kind = .IdResult, .quantifier = .required },9580 .{ .kind = .id_result, .quantifier = .required },
8882 .{ .kind = .IdRef, .quantifier = .required },9581 .{ .kind = .id_ref, .quantifier = .required },
8883 .{ .kind = .IdRef, .quantifier = .required },9582 .{ .kind = .id_ref, .quantifier = .required },
8884 .{ .kind = .PackedVectorFormat, .quantifier = .optional },9583 .{ .kind = .packed_vector_format, .quantifier = .optional },
8885 },
8886 },
8887 .{
8888 .name = "OpSUDotKHR",
8889 .opcode = 4452,
8890 .operands = &[_]Operand{
8891 .{ .kind = .IdResultType, .quantifier = .required },
8892 .{ .kind = .IdResult, .quantifier = .required },
8893 .{ .kind = .IdRef, .quantifier = .required },
8894 .{ .kind = .IdRef, .quantifier = .required },
8895 .{ .kind = .PackedVectorFormat, .quantifier = .optional },
8896 },9584 },
8897 },9585 },
8898 .{9586 .{
8899 .name = "OpSDotAccSat",9587 .name = "OpSDotAccSat",
8900 .opcode = 4453,9588 .opcode = 4453,
8901 .operands = &[_]Operand{9589 .operands = &.{
8902 .{ .kind = .IdResultType, .quantifier = .required },9590 .{ .kind = .id_result_type, .quantifier = .required },
8903 .{ .kind = .IdResult, .quantifier = .required },9591 .{ .kind = .id_result, .quantifier = .required },
8904 .{ .kind = .IdRef, .quantifier = .required },9592 .{ .kind = .id_ref, .quantifier = .required },
8905 .{ .kind = .IdRef, .quantifier = .required },9593 .{ .kind = .id_ref, .quantifier = .required },
8906 .{ .kind = .IdRef, .quantifier = .required },9594 .{ .kind = .id_ref, .quantifier = .required },
8907 .{ .kind = .PackedVectorFormat, .quantifier = .optional },9595 .{ .kind = .packed_vector_format, .quantifier = .optional },
8908 },
8909 },
8910 .{
8911 .name = "OpSDotAccSatKHR",
8912 .opcode = 4453,
8913 .operands = &[_]Operand{
8914 .{ .kind = .IdResultType, .quantifier = .required },
8915 .{ .kind = .IdResult, .quantifier = .required },
8916 .{ .kind = .IdRef, .quantifier = .required },
8917 .{ .kind = .IdRef, .quantifier = .required },
8918 .{ .kind = .IdRef, .quantifier = .required },
8919 .{ .kind = .PackedVectorFormat, .quantifier = .optional },
8920 },9596 },
8921 },9597 },
8922 .{9598 .{
8923 .name = "OpUDotAccSat",9599 .name = "OpUDotAccSat",
8924 .opcode = 4454,9600 .opcode = 4454,
8925 .operands = &[_]Operand{9601 .operands = &.{
8926 .{ .kind = .IdResultType, .quantifier = .required },9602 .{ .kind = .id_result_type, .quantifier = .required },
8927 .{ .kind = .IdResult, .quantifier = .required },9603 .{ .kind = .id_result, .quantifier = .required },
8928 .{ .kind = .IdRef, .quantifier = .required },9604 .{ .kind = .id_ref, .quantifier = .required },
8929 .{ .kind = .IdRef, .quantifier = .required },9605 .{ .kind = .id_ref, .quantifier = .required },
8930 .{ .kind = .IdRef, .quantifier = .required },9606 .{ .kind = .id_ref, .quantifier = .required },
8931 .{ .kind = .PackedVectorFormat, .quantifier = .optional },9607 .{ .kind = .packed_vector_format, .quantifier = .optional },
8932 },
8933 },
8934 .{
8935 .name = "OpUDotAccSatKHR",
8936 .opcode = 4454,
8937 .operands = &[_]Operand{
8938 .{ .kind = .IdResultType, .quantifier = .required },
8939 .{ .kind = .IdResult, .quantifier = .required },
8940 .{ .kind = .IdRef, .quantifier = .required },
8941 .{ .kind = .IdRef, .quantifier = .required },
8942 .{ .kind = .IdRef, .quantifier = .required },
8943 .{ .kind = .PackedVectorFormat, .quantifier = .optional },
8944 },9608 },
8945 },9609 },
8946 .{9610 .{
8947 .name = "OpSUDotAccSat",9611 .name = "OpSUDotAccSat",
8948 .opcode = 4455,9612 .opcode = 4455,
8949 .operands = &[_]Operand{9613 .operands = &.{
8950 .{ .kind = .IdResultType, .quantifier = .required },9614 .{ .kind = .id_result_type, .quantifier = .required },
8951 .{ .kind = .IdResult, .quantifier = .required },9615 .{ .kind = .id_result, .quantifier = .required },
8952 .{ .kind = .IdRef, .quantifier = .required },9616 .{ .kind = .id_ref, .quantifier = .required },
8953 .{ .kind = .IdRef, .quantifier = .required },9617 .{ .kind = .id_ref, .quantifier = .required },
8954 .{ .kind = .IdRef, .quantifier = .required },9618 .{ .kind = .id_ref, .quantifier = .required },
8955 .{ .kind = .PackedVectorFormat, .quantifier = .optional },9619 .{ .kind = .packed_vector_format, .quantifier = .optional },
8956 },
8957 },
8958 .{
8959 .name = "OpSUDotAccSatKHR",
8960 .opcode = 4455,
8961 .operands = &[_]Operand{
8962 .{ .kind = .IdResultType, .quantifier = .required },
8963 .{ .kind = .IdResult, .quantifier = .required },
8964 .{ .kind = .IdRef, .quantifier = .required },
8965 .{ .kind = .IdRef, .quantifier = .required },
8966 .{ .kind = .IdRef, .quantifier = .required },
8967 .{ .kind = .PackedVectorFormat, .quantifier = .optional },
8968 },9620 },
8969 },9621 },
8970 .{9622 .{
8971 .name = "OpTypeCooperativeMatrixKHR",9623 .name = "OpTypeCooperativeMatrixKHR",
8972 .opcode = 4456,9624 .opcode = 4456,
8973 .operands = &[_]Operand{9625 .operands = &.{
8974 .{ .kind = .IdResult, .quantifier = .required },9626 .{ .kind = .id_result, .quantifier = .required },
8975 .{ .kind = .IdRef, .quantifier = .required },9627 .{ .kind = .id_ref, .quantifier = .required },
8976 .{ .kind = .IdScope, .quantifier = .required },9628 .{ .kind = .id_scope, .quantifier = .required },
8977 .{ .kind = .IdRef, .quantifier = .required },9629 .{ .kind = .id_ref, .quantifier = .required },
8978 .{ .kind = .IdRef, .quantifier = .required },9630 .{ .kind = .id_ref, .quantifier = .required },
8979 .{ .kind = .IdRef, .quantifier = .required },9631 .{ .kind = .id_ref, .quantifier = .required },
8980 },9632 },
8981 },9633 },
8982 .{9634 .{
8983 .name = "OpCooperativeMatrixLoadKHR",9635 .name = "OpCooperativeMatrixLoadKHR",
8984 .opcode = 4457,9636 .opcode = 4457,
8985 .operands = &[_]Operand{9637 .operands = &.{
8986 .{ .kind = .IdResultType, .quantifier = .required },9638 .{ .kind = .id_result_type, .quantifier = .required },
8987 .{ .kind = .IdResult, .quantifier = .required },9639 .{ .kind = .id_result, .quantifier = .required },
8988 .{ .kind = .IdRef, .quantifier = .required },9640 .{ .kind = .id_ref, .quantifier = .required },
8989 .{ .kind = .IdRef, .quantifier = .required },9641 .{ .kind = .id_ref, .quantifier = .required },
8990 .{ .kind = .IdRef, .quantifier = .optional },9642 .{ .kind = .id_ref, .quantifier = .optional },
8991 .{ .kind = .MemoryAccess, .quantifier = .optional },9643 .{ .kind = .memory_access, .quantifier = .optional },
8992 },9644 },
8993 },9645 },
8994 .{9646 .{
8995 .name = "OpCooperativeMatrixStoreKHR",9647 .name = "OpCooperativeMatrixStoreKHR",
8996 .opcode = 4458,9648 .opcode = 4458,
8997 .operands = &[_]Operand{9649 .operands = &.{
8998 .{ .kind = .IdRef, .quantifier = .required },9650 .{ .kind = .id_ref, .quantifier = .required },
8999 .{ .kind = .IdRef, .quantifier = .required },9651 .{ .kind = .id_ref, .quantifier = .required },
9000 .{ .kind = .IdRef, .quantifier = .required },9652 .{ .kind = .id_ref, .quantifier = .required },
9001 .{ .kind = .IdRef, .quantifier = .optional },9653 .{ .kind = .id_ref, .quantifier = .optional },
9002 .{ .kind = .MemoryAccess, .quantifier = .optional },9654 .{ .kind = .memory_access, .quantifier = .optional },
9003 },9655 },
9004 },9656 },
9005 .{9657 .{
9006 .name = "OpCooperativeMatrixMulAddKHR",9658 .name = "OpCooperativeMatrixMulAddKHR",
9007 .opcode = 4459,9659 .opcode = 4459,
9008 .operands = &[_]Operand{9660 .operands = &.{
9009 .{ .kind = .IdResultType, .quantifier = .required },9661 .{ .kind = .id_result_type, .quantifier = .required },
9010 .{ .kind = .IdResult, .quantifier = .required },9662 .{ .kind = .id_result, .quantifier = .required },
9011 .{ .kind = .IdRef, .quantifier = .required },9663 .{ .kind = .id_ref, .quantifier = .required },
9012 .{ .kind = .IdRef, .quantifier = .required },9664 .{ .kind = .id_ref, .quantifier = .required },
9013 .{ .kind = .IdRef, .quantifier = .required },9665 .{ .kind = .id_ref, .quantifier = .required },
9014 .{ .kind = .CooperativeMatrixOperands, .quantifier = .optional },9666 .{ .kind = .cooperative_matrix_operands, .quantifier = .optional },
9015 },9667 },
9016 },9668 },
9017 .{9669 .{
9018 .name = "OpCooperativeMatrixLengthKHR",9670 .name = "OpCooperativeMatrixLengthKHR",
9019 .opcode = 4460,9671 .opcode = 4460,
9020 .operands = &[_]Operand{9672 .operands = &.{
9021 .{ .kind = .IdResultType, .quantifier = .required },9673 .{ .kind = .id_result_type, .quantifier = .required },
9022 .{ .kind = .IdResult, .quantifier = .required },9674 .{ .kind = .id_result, .quantifier = .required },
9023 .{ .kind = .IdRef, .quantifier = .required },9675 .{ .kind = .id_ref, .quantifier = .required },
9676 },
9677 },
9678 .{
9679 .name = "OpConstantCompositeReplicateEXT",
9680 .opcode = 4461,
9681 .operands = &.{
9682 .{ .kind = .id_result_type, .quantifier = .required },
9683 .{ .kind = .id_result, .quantifier = .required },
9684 .{ .kind = .id_ref, .quantifier = .required },
9685 },
9686 },
9687 .{
9688 .name = "OpSpecConstantCompositeReplicateEXT",
9689 .opcode = 4462,
9690 .operands = &.{
9691 .{ .kind = .id_result_type, .quantifier = .required },
9692 .{ .kind = .id_result, .quantifier = .required },
9693 .{ .kind = .id_ref, .quantifier = .required },
9694 },
9695 },
9696 .{
9697 .name = "OpCompositeConstructReplicateEXT",
9698 .opcode = 4463,
9699 .operands = &.{
9700 .{ .kind = .id_result_type, .quantifier = .required },
9701 .{ .kind = .id_result, .quantifier = .required },
9702 .{ .kind = .id_ref, .quantifier = .required },
9024 },9703 },
9025 },9704 },
9026 .{9705 .{
9027 .name = "OpTypeRayQueryKHR",9706 .name = "OpTypeRayQueryKHR",
9028 .opcode = 4472,9707 .opcode = 4472,
9029 .operands = &[_]Operand{9708 .operands = &.{
9030 .{ .kind = .IdResult, .quantifier = .required },9709 .{ .kind = .id_result, .quantifier = .required },
9031 },9710 },
9032 },9711 },
9033 .{9712 .{
9034 .name = "OpRayQueryInitializeKHR",9713 .name = "OpRayQueryInitializeKHR",
9035 .opcode = 4473,9714 .opcode = 4473,
9036 .operands = &[_]Operand{9715 .operands = &.{
9037 .{ .kind = .IdRef, .quantifier = .required },9716 .{ .kind = .id_ref, .quantifier = .required },
9038 .{ .kind = .IdRef, .quantifier = .required },9717 .{ .kind = .id_ref, .quantifier = .required },
9039 .{ .kind = .IdRef, .quantifier = .required },9718 .{ .kind = .id_ref, .quantifier = .required },
9040 .{ .kind = .IdRef, .quantifier = .required },9719 .{ .kind = .id_ref, .quantifier = .required },
9041 .{ .kind = .IdRef, .quantifier = .required },9720 .{ .kind = .id_ref, .quantifier = .required },
9042 .{ .kind = .IdRef, .quantifier = .required },9721 .{ .kind = .id_ref, .quantifier = .required },
9043 .{ .kind = .IdRef, .quantifier = .required },9722 .{ .kind = .id_ref, .quantifier = .required },
9044 .{ .kind = .IdRef, .quantifier = .required },9723 .{ .kind = .id_ref, .quantifier = .required },
9045 },9724 },
9046 },9725 },
9047 .{9726 .{
9048 .name = "OpRayQueryTerminateKHR",9727 .name = "OpRayQueryTerminateKHR",
9049 .opcode = 4474,9728 .opcode = 4474,
9050 .operands = &[_]Operand{9729 .operands = &.{
9051 .{ .kind = .IdRef, .quantifier = .required },9730 .{ .kind = .id_ref, .quantifier = .required },
9052 },9731 },
9053 },9732 },
9054 .{9733 .{
9055 .name = "OpRayQueryGenerateIntersectionKHR",9734 .name = "OpRayQueryGenerateIntersectionKHR",
9056 .opcode = 4475,9735 .opcode = 4475,
9057 .operands = &[_]Operand{9736 .operands = &.{
9058 .{ .kind = .IdRef, .quantifier = .required },9737 .{ .kind = .id_ref, .quantifier = .required },
9059 .{ .kind = .IdRef, .quantifier = .required },9738 .{ .kind = .id_ref, .quantifier = .required },
9060 },9739 },
9061 },9740 },
9062 .{9741 .{
9063 .name = "OpRayQueryConfirmIntersectionKHR",9742 .name = "OpRayQueryConfirmIntersectionKHR",
9064 .opcode = 4476,9743 .opcode = 4476,
9065 .operands = &[_]Operand{9744 .operands = &.{
9066 .{ .kind = .IdRef, .quantifier = .required },9745 .{ .kind = .id_ref, .quantifier = .required },
9067 },9746 },
9068 },9747 },
9069 .{9748 .{
9070 .name = "OpRayQueryProceedKHR",9749 .name = "OpRayQueryProceedKHR",
9071 .opcode = 4477,9750 .opcode = 4477,
9072 .operands = &[_]Operand{9751 .operands = &.{
9073 .{ .kind = .IdResultType, .quantifier = .required },9752 .{ .kind = .id_result_type, .quantifier = .required },
9074 .{ .kind = .IdResult, .quantifier = .required },9753 .{ .kind = .id_result, .quantifier = .required },
9075 .{ .kind = .IdRef, .quantifier = .required },9754 .{ .kind = .id_ref, .quantifier = .required },
9076 },9755 },
9077 },9756 },
9078 .{9757 .{
9079 .name = "OpRayQueryGetIntersectionTypeKHR",9758 .name = "OpRayQueryGetIntersectionTypeKHR",
9080 .opcode = 4479,9759 .opcode = 4479,
9081 .operands = &[_]Operand{9760 .operands = &.{
9082 .{ .kind = .IdResultType, .quantifier = .required },9761 .{ .kind = .id_result_type, .quantifier = .required },
9083 .{ .kind = .IdResult, .quantifier = .required },9762 .{ .kind = .id_result, .quantifier = .required },
9084 .{ .kind = .IdRef, .quantifier = .required },9763 .{ .kind = .id_ref, .quantifier = .required },
9085 .{ .kind = .IdRef, .quantifier = .required },9764 .{ .kind = .id_ref, .quantifier = .required },
9086 },9765 },
9087 },9766 },
9088 .{9767 .{
9089 .name = "OpImageSampleWeightedQCOM",9768 .name = "OpImageSampleWeightedQCOM",
9090 .opcode = 4480,9769 .opcode = 4480,
9091 .operands = &[_]Operand{9770 .operands = &.{
9092 .{ .kind = .IdResultType, .quantifier = .required },9771 .{ .kind = .id_result_type, .quantifier = .required },
9093 .{ .kind = .IdResult, .quantifier = .required },9772 .{ .kind = .id_result, .quantifier = .required },
9094 .{ .kind = .IdRef, .quantifier = .required },9773 .{ .kind = .id_ref, .quantifier = .required },
9095 .{ .kind = .IdRef, .quantifier = .required },9774 .{ .kind = .id_ref, .quantifier = .required },
9096 .{ .kind = .IdRef, .quantifier = .required },9775 .{ .kind = .id_ref, .quantifier = .required },
9097 },9776 },
9098 },9777 },
9099 .{9778 .{
9100 .name = "OpImageBoxFilterQCOM",9779 .name = "OpImageBoxFilterQCOM",
9101 .opcode = 4481,9780 .opcode = 4481,
9102 .operands = &[_]Operand{9781 .operands = &.{
9103 .{ .kind = .IdResultType, .quantifier = .required },9782 .{ .kind = .id_result_type, .quantifier = .required },
9104 .{ .kind = .IdResult, .quantifier = .required },9783 .{ .kind = .id_result, .quantifier = .required },
9105 .{ .kind = .IdRef, .quantifier = .required },9784 .{ .kind = .id_ref, .quantifier = .required },
9106 .{ .kind = .IdRef, .quantifier = .required },9785 .{ .kind = .id_ref, .quantifier = .required },
9107 .{ .kind = .IdRef, .quantifier = .required },9786 .{ .kind = .id_ref, .quantifier = .required },
9108 },9787 },
9109 },9788 },
9110 .{9789 .{
9111 .name = "OpImageBlockMatchSSDQCOM",9790 .name = "OpImageBlockMatchSSDQCOM",
9112 .opcode = 4482,9791 .opcode = 4482,
9113 .operands = &[_]Operand{9792 .operands = &.{
9114 .{ .kind = .IdResultType, .quantifier = .required },9793 .{ .kind = .id_result_type, .quantifier = .required },
9115 .{ .kind = .IdResult, .quantifier = .required },9794 .{ .kind = .id_result, .quantifier = .required },
9116 .{ .kind = .IdRef, .quantifier = .required },9795 .{ .kind = .id_ref, .quantifier = .required },
9117 .{ .kind = .IdRef, .quantifier = .required },9796 .{ .kind = .id_ref, .quantifier = .required },
9118 .{ .kind = .IdRef, .quantifier = .required },9797 .{ .kind = .id_ref, .quantifier = .required },
9119 .{ .kind = .IdRef, .quantifier = .required },9798 .{ .kind = .id_ref, .quantifier = .required },
9120 .{ .kind = .IdRef, .quantifier = .required },9799 .{ .kind = .id_ref, .quantifier = .required },
9121 },9800 },
9122 },9801 },
9123 .{9802 .{
9124 .name = "OpImageBlockMatchSADQCOM",9803 .name = "OpImageBlockMatchSADQCOM",
9125 .opcode = 4483,9804 .opcode = 4483,
9126 .operands = &[_]Operand{9805 .operands = &.{
9127 .{ .kind = .IdResultType, .quantifier = .required },9806 .{ .kind = .id_result_type, .quantifier = .required },
9128 .{ .kind = .IdResult, .quantifier = .required },9807 .{ .kind = .id_result, .quantifier = .required },
9129 .{ .kind = .IdRef, .quantifier = .required },9808 .{ .kind = .id_ref, .quantifier = .required },
9130 .{ .kind = .IdRef, .quantifier = .required },9809 .{ .kind = .id_ref, .quantifier = .required },
9131 .{ .kind = .IdRef, .quantifier = .required },9810 .{ .kind = .id_ref, .quantifier = .required },
9132 .{ .kind = .IdRef, .quantifier = .required },9811 .{ .kind = .id_ref, .quantifier = .required },
9133 .{ .kind = .IdRef, .quantifier = .required },9812 .{ .kind = .id_ref, .quantifier = .required },
9134 },9813 },
9135 },9814 },
9136 .{9815 .{
9137 .name = "OpImageBlockMatchWindowSSDQCOM",9816 .name = "OpImageBlockMatchWindowSSDQCOM",
9138 .opcode = 4500,9817 .opcode = 4500,
9139 .operands = &[_]Operand{9818 .operands = &.{
9140 .{ .kind = .IdResultType, .quantifier = .required },9819 .{ .kind = .id_result_type, .quantifier = .required },
9141 .{ .kind = .IdResult, .quantifier = .required },9820 .{ .kind = .id_result, .quantifier = .required },
9142 .{ .kind = .IdRef, .quantifier = .required },9821 .{ .kind = .id_ref, .quantifier = .required },
9143 .{ .kind = .IdRef, .quantifier = .required },9822 .{ .kind = .id_ref, .quantifier = .required },
9144 .{ .kind = .IdRef, .quantifier = .required },9823 .{ .kind = .id_ref, .quantifier = .required },
9145 .{ .kind = .IdRef, .quantifier = .required },9824 .{ .kind = .id_ref, .quantifier = .required },
9146 .{ .kind = .IdRef, .quantifier = .required },9825 .{ .kind = .id_ref, .quantifier = .required },
9147 },9826 },
9148 },9827 },
9149 .{9828 .{
9150 .name = "OpImageBlockMatchWindowSADQCOM",9829 .name = "OpImageBlockMatchWindowSADQCOM",
9151 .opcode = 4501,9830 .opcode = 4501,
9152 .operands = &[_]Operand{9831 .operands = &.{
9153 .{ .kind = .IdResultType, .quantifier = .required },9832 .{ .kind = .id_result_type, .quantifier = .required },
9154 .{ .kind = .IdResult, .quantifier = .required },9833 .{ .kind = .id_result, .quantifier = .required },
9155 .{ .kind = .IdRef, .quantifier = .required },9834 .{ .kind = .id_ref, .quantifier = .required },
9156 .{ .kind = .IdRef, .quantifier = .required },9835 .{ .kind = .id_ref, .quantifier = .required },
9157 .{ .kind = .IdRef, .quantifier = .required },9836 .{ .kind = .id_ref, .quantifier = .required },
9158 .{ .kind = .IdRef, .quantifier = .required },9837 .{ .kind = .id_ref, .quantifier = .required },
9159 .{ .kind = .IdRef, .quantifier = .required },9838 .{ .kind = .id_ref, .quantifier = .required },
9160 },9839 },
9161 },9840 },
9162 .{9841 .{
9163 .name = "OpImageBlockMatchGatherSSDQCOM",9842 .name = "OpImageBlockMatchGatherSSDQCOM",
9164 .opcode = 4502,9843 .opcode = 4502,
9165 .operands = &[_]Operand{9844 .operands = &.{
9166 .{ .kind = .IdResultType, .quantifier = .required },9845 .{ .kind = .id_result_type, .quantifier = .required },
9167 .{ .kind = .IdResult, .quantifier = .required },9846 .{ .kind = .id_result, .quantifier = .required },
9168 .{ .kind = .IdRef, .quantifier = .required },9847 .{ .kind = .id_ref, .quantifier = .required },
9169 .{ .kind = .IdRef, .quantifier = .required },9848 .{ .kind = .id_ref, .quantifier = .required },
9170 .{ .kind = .IdRef, .quantifier = .required },9849 .{ .kind = .id_ref, .quantifier = .required },
9171 .{ .kind = .IdRef, .quantifier = .required },9850 .{ .kind = .id_ref, .quantifier = .required },
9172 .{ .kind = .IdRef, .quantifier = .required },9851 .{ .kind = .id_ref, .quantifier = .required },
9173 },9852 },
9174 },9853 },
9175 .{9854 .{
9176 .name = "OpImageBlockMatchGatherSADQCOM",9855 .name = "OpImageBlockMatchGatherSADQCOM",
9177 .opcode = 4503,9856 .opcode = 4503,
9178 .operands = &[_]Operand{9857 .operands = &.{
9179 .{ .kind = .IdResultType, .quantifier = .required },9858 .{ .kind = .id_result_type, .quantifier = .required },
9180 .{ .kind = .IdResult, .quantifier = .required },9859 .{ .kind = .id_result, .quantifier = .required },
9181 .{ .kind = .IdRef, .quantifier = .required },9860 .{ .kind = .id_ref, .quantifier = .required },
9182 .{ .kind = .IdRef, .quantifier = .required },9861 .{ .kind = .id_ref, .quantifier = .required },
9183 .{ .kind = .IdRef, .quantifier = .required },9862 .{ .kind = .id_ref, .quantifier = .required },
9184 .{ .kind = .IdRef, .quantifier = .required },9863 .{ .kind = .id_ref, .quantifier = .required },
9185 .{ .kind = .IdRef, .quantifier = .required },9864 .{ .kind = .id_ref, .quantifier = .required },
9186 },9865 },
9187 },9866 },
9188 .{9867 .{
9189 .name = "OpGroupIAddNonUniformAMD",9868 .name = "OpGroupIAddNonUniformAMD",
9190 .opcode = 5000,9869 .opcode = 5000,
9191 .operands = &[_]Operand{9870 .operands = &.{
9192 .{ .kind = .IdResultType, .quantifier = .required },9871 .{ .kind = .id_result_type, .quantifier = .required },
9193 .{ .kind = .IdResult, .quantifier = .required },9872 .{ .kind = .id_result, .quantifier = .required },
9194 .{ .kind = .IdScope, .quantifier = .required },9873 .{ .kind = .id_scope, .quantifier = .required },
9195 .{ .kind = .GroupOperation, .quantifier = .required },9874 .{ .kind = .group_operation, .quantifier = .required },
9196 .{ .kind = .IdRef, .quantifier = .required },9875 .{ .kind = .id_ref, .quantifier = .required },
9197 },9876 },
9198 },9877 },
9199 .{9878 .{
9200 .name = "OpGroupFAddNonUniformAMD",9879 .name = "OpGroupFAddNonUniformAMD",
9201 .opcode = 5001,9880 .opcode = 5001,
9202 .operands = &[_]Operand{9881 .operands = &.{
9203 .{ .kind = .IdResultType, .quantifier = .required },9882 .{ .kind = .id_result_type, .quantifier = .required },
9204 .{ .kind = .IdResult, .quantifier = .required },9883 .{ .kind = .id_result, .quantifier = .required },
9205 .{ .kind = .IdScope, .quantifier = .required },9884 .{ .kind = .id_scope, .quantifier = .required },
9206 .{ .kind = .GroupOperation, .quantifier = .required },9885 .{ .kind = .group_operation, .quantifier = .required },
9207 .{ .kind = .IdRef, .quantifier = .required },9886 .{ .kind = .id_ref, .quantifier = .required },
9208 },9887 },
9209 },9888 },
9210 .{9889 .{
9211 .name = "OpGroupFMinNonUniformAMD",9890 .name = "OpGroupFMinNonUniformAMD",
9212 .opcode = 5002,9891 .opcode = 5002,
9213 .operands = &[_]Operand{9892 .operands = &.{
9214 .{ .kind = .IdResultType, .quantifier = .required },9893 .{ .kind = .id_result_type, .quantifier = .required },
9215 .{ .kind = .IdResult, .quantifier = .required },9894 .{ .kind = .id_result, .quantifier = .required },
9216 .{ .kind = .IdScope, .quantifier = .required },9895 .{ .kind = .id_scope, .quantifier = .required },
9217 .{ .kind = .GroupOperation, .quantifier = .required },9896 .{ .kind = .group_operation, .quantifier = .required },
9218 .{ .kind = .IdRef, .quantifier = .required },9897 .{ .kind = .id_ref, .quantifier = .required },
9219 },9898 },
9220 },9899 },
9221 .{9900 .{
9222 .name = "OpGroupUMinNonUniformAMD",9901 .name = "OpGroupUMinNonUniformAMD",
9223 .opcode = 5003,9902 .opcode = 5003,
9224 .operands = &[_]Operand{9903 .operands = &.{
9225 .{ .kind = .IdResultType, .quantifier = .required },9904 .{ .kind = .id_result_type, .quantifier = .required },
9226 .{ .kind = .IdResult, .quantifier = .required },9905 .{ .kind = .id_result, .quantifier = .required },
9227 .{ .kind = .IdScope, .quantifier = .required },9906 .{ .kind = .id_scope, .quantifier = .required },
9228 .{ .kind = .GroupOperation, .quantifier = .required },9907 .{ .kind = .group_operation, .quantifier = .required },
9229 .{ .kind = .IdRef, .quantifier = .required },9908 .{ .kind = .id_ref, .quantifier = .required },
9230 },9909 },
9231 },9910 },
9232 .{9911 .{
9233 .name = "OpGroupSMinNonUniformAMD",9912 .name = "OpGroupSMinNonUniformAMD",
9234 .opcode = 5004,9913 .opcode = 5004,
9235 .operands = &[_]Operand{9914 .operands = &.{
9236 .{ .kind = .IdResultType, .quantifier = .required },9915 .{ .kind = .id_result_type, .quantifier = .required },
9237 .{ .kind = .IdResult, .quantifier = .required },9916 .{ .kind = .id_result, .quantifier = .required },
9238 .{ .kind = .IdScope, .quantifier = .required },9917 .{ .kind = .id_scope, .quantifier = .required },
9239 .{ .kind = .GroupOperation, .quantifier = .required },9918 .{ .kind = .group_operation, .quantifier = .required },
9240 .{ .kind = .IdRef, .quantifier = .required },9919 .{ .kind = .id_ref, .quantifier = .required },
9241 },9920 },
9242 },9921 },
9243 .{9922 .{
9244 .name = "OpGroupFMaxNonUniformAMD",9923 .name = "OpGroupFMaxNonUniformAMD",
9245 .opcode = 5005,9924 .opcode = 5005,
9246 .operands = &[_]Operand{9925 .operands = &.{
9247 .{ .kind = .IdResultType, .quantifier = .required },9926 .{ .kind = .id_result_type, .quantifier = .required },
9248 .{ .kind = .IdResult, .quantifier = .required },9927 .{ .kind = .id_result, .quantifier = .required },
9249 .{ .kind = .IdScope, .quantifier = .required },9928 .{ .kind = .id_scope, .quantifier = .required },
9250 .{ .kind = .GroupOperation, .quantifier = .required },9929 .{ .kind = .group_operation, .quantifier = .required },
9251 .{ .kind = .IdRef, .quantifier = .required },9930 .{ .kind = .id_ref, .quantifier = .required },
9252 },9931 },
9253 },9932 },
9254 .{9933 .{
9255 .name = "OpGroupUMaxNonUniformAMD",9934 .name = "OpGroupUMaxNonUniformAMD",
9256 .opcode = 5006,9935 .opcode = 5006,
9257 .operands = &[_]Operand{9936 .operands = &.{
9258 .{ .kind = .IdResultType, .quantifier = .required },9937 .{ .kind = .id_result_type, .quantifier = .required },
9259 .{ .kind = .IdResult, .quantifier = .required },9938 .{ .kind = .id_result, .quantifier = .required },
9260 .{ .kind = .IdScope, .quantifier = .required },9939 .{ .kind = .id_scope, .quantifier = .required },
9261 .{ .kind = .GroupOperation, .quantifier = .required },9940 .{ .kind = .group_operation, .quantifier = .required },
9262 .{ .kind = .IdRef, .quantifier = .required },9941 .{ .kind = .id_ref, .quantifier = .required },
9263 },9942 },
9264 },9943 },
9265 .{9944 .{
9266 .name = "OpGroupSMaxNonUniformAMD",9945 .name = "OpGroupSMaxNonUniformAMD",
9267 .opcode = 5007,9946 .opcode = 5007,
9268 .operands = &[_]Operand{9947 .operands = &.{
9269 .{ .kind = .IdResultType, .quantifier = .required },9948 .{ .kind = .id_result_type, .quantifier = .required },
9270 .{ .kind = .IdResult, .quantifier = .required },9949 .{ .kind = .id_result, .quantifier = .required },
9271 .{ .kind = .IdScope, .quantifier = .required },9950 .{ .kind = .id_scope, .quantifier = .required },
9272 .{ .kind = .GroupOperation, .quantifier = .required },9951 .{ .kind = .group_operation, .quantifier = .required },
9273 .{ .kind = .IdRef, .quantifier = .required },9952 .{ .kind = .id_ref, .quantifier = .required },
9274 },9953 },
9275 },9954 },
9276 .{9955 .{
9277 .name = "OpFragmentMaskFetchAMD",9956 .name = "OpFragmentMaskFetchAMD",
9278 .opcode = 5011,9957 .opcode = 5011,
9279 .operands = &[_]Operand{9958 .operands = &.{
9280 .{ .kind = .IdResultType, .quantifier = .required },9959 .{ .kind = .id_result_type, .quantifier = .required },
9281 .{ .kind = .IdResult, .quantifier = .required },9960 .{ .kind = .id_result, .quantifier = .required },
9282 .{ .kind = .IdRef, .quantifier = .required },9961 .{ .kind = .id_ref, .quantifier = .required },
9283 .{ .kind = .IdRef, .quantifier = .required },9962 .{ .kind = .id_ref, .quantifier = .required },
9284 },9963 },
9285 },9964 },
9286 .{9965 .{
9287 .name = "OpFragmentFetchAMD",9966 .name = "OpFragmentFetchAMD",
9288 .opcode = 5012,9967 .opcode = 5012,
9289 .operands = &[_]Operand{9968 .operands = &.{
9290 .{ .kind = .IdResultType, .quantifier = .required },9969 .{ .kind = .id_result_type, .quantifier = .required },
9291 .{ .kind = .IdResult, .quantifier = .required },9970 .{ .kind = .id_result, .quantifier = .required },
9292 .{ .kind = .IdRef, .quantifier = .required },9971 .{ .kind = .id_ref, .quantifier = .required },
9293 .{ .kind = .IdRef, .quantifier = .required },9972 .{ .kind = .id_ref, .quantifier = .required },
9294 .{ .kind = .IdRef, .quantifier = .required },9973 .{ .kind = .id_ref, .quantifier = .required },
9295 },9974 },
9296 },9975 },
9297 .{9976 .{
9298 .name = "OpReadClockKHR",9977 .name = "OpReadClockKHR",
9299 .opcode = 5056,9978 .opcode = 5056,
9300 .operands = &[_]Operand{9979 .operands = &.{
9301 .{ .kind = .IdResultType, .quantifier = .required },9980 .{ .kind = .id_result_type, .quantifier = .required },
9302 .{ .kind = .IdResult, .quantifier = .required },9981 .{ .kind = .id_result, .quantifier = .required },
9303 .{ .kind = .IdScope, .quantifier = .required },9982 .{ .kind = .id_scope, .quantifier = .required },
9304 },9983 },
9305 },9984 },
9306 .{9985 .{
9307 .name = "OpFinalizeNodePayloadsAMDX",9986 .name = "OpAllocateNodePayloadsAMDX",
9987 .opcode = 5074,
9988 .operands = &.{
9989 .{ .kind = .id_result_type, .quantifier = .required },
9990 .{ .kind = .id_result, .quantifier = .required },
9991 .{ .kind = .id_scope, .quantifier = .required },
9992 .{ .kind = .id_ref, .quantifier = .required },
9993 .{ .kind = .id_ref, .quantifier = .required },
9994 },
9995 },
9996 .{
9997 .name = "OpEnqueueNodePayloadsAMDX",
9308 .opcode = 5075,9998 .opcode = 5075,
9309 .operands = &[_]Operand{9999 .operands = &.{
9310 .{ .kind = .IdRef, .quantifier = .required },10000 .{ .kind = .id_ref, .quantifier = .required },
10001 },
10002 },
10003 .{
10004 .name = "OpTypeNodePayloadArrayAMDX",
10005 .opcode = 5076,
10006 .operands = &.{
10007 .{ .kind = .id_result, .quantifier = .required },
10008 .{ .kind = .id_ref, .quantifier = .required },
9311 },10009 },
9312 },10010 },
9313 .{10011 .{
9314 .name = "OpFinishWritingNodePayloadAMDX",10012 .name = "OpFinishWritingNodePayloadAMDX",
9315 .opcode = 5078,10013 .opcode = 5078,
9316 .operands = &[_]Operand{10014 .operands = &.{
9317 .{ .kind = .IdResultType, .quantifier = .required },10015 .{ .kind = .id_result_type, .quantifier = .required },
9318 .{ .kind = .IdResult, .quantifier = .required },10016 .{ .kind = .id_result, .quantifier = .required },
9319 .{ .kind = .IdRef, .quantifier = .required },10017 .{ .kind = .id_ref, .quantifier = .required },
9320 },10018 },
9321 },10019 },
9322 .{10020 .{
9323 .name = "OpInitializeNodePayloadsAMDX",10021 .name = "OpNodePayloadArrayLengthAMDX",
9324 .opcode = 5090,10022 .opcode = 5090,
9325 .operands = &[_]Operand{10023 .operands = &.{
9326 .{ .kind = .IdRef, .quantifier = .required },10024 .{ .kind = .id_result_type, .quantifier = .required },
9327 .{ .kind = .IdScope, .quantifier = .required },10025 .{ .kind = .id_result, .quantifier = .required },
9328 .{ .kind = .IdRef, .quantifier = .required },10026 .{ .kind = .id_ref, .quantifier = .required },
9329 .{ .kind = .IdRef, .quantifier = .required },10027 },
10028 },
10029 .{
10030 .name = "OpIsNodePayloadValidAMDX",
10031 .opcode = 5101,
10032 .operands = &.{
10033 .{ .kind = .id_result_type, .quantifier = .required },
10034 .{ .kind = .id_result, .quantifier = .required },
10035 .{ .kind = .id_ref, .quantifier = .required },
10036 .{ .kind = .id_ref, .quantifier = .required },
10037 },
10038 },
10039 .{
10040 .name = "OpConstantStringAMDX",
10041 .opcode = 5103,
10042 .operands = &.{
10043 .{ .kind = .id_result, .quantifier = .required },
10044 .{ .kind = .literal_string, .quantifier = .required },
10045 },
10046 },
10047 .{
10048 .name = "OpSpecConstantStringAMDX",
10049 .opcode = 5104,
10050 .operands = &.{
10051 .{ .kind = .id_result, .quantifier = .required },
10052 .{ .kind = .literal_string, .quantifier = .required },
9330 },10053 },
9331 },10054 },
9332 .{10055 .{
9333 .name = "OpGroupNonUniformQuadAllKHR",10056 .name = "OpGroupNonUniformQuadAllKHR",
9334 .opcode = 5110,10057 .opcode = 5110,
9335 .operands = &[_]Operand{10058 .operands = &.{
9336 .{ .kind = .IdResultType, .quantifier = .required },10059 .{ .kind = .id_result_type, .quantifier = .required },
9337 .{ .kind = .IdResult, .quantifier = .required },10060 .{ .kind = .id_result, .quantifier = .required },
9338 .{ .kind = .IdRef, .quantifier = .required },10061 .{ .kind = .id_ref, .quantifier = .required },
9339 },10062 },
9340 },10063 },
9341 .{10064 .{
9342 .name = "OpGroupNonUniformQuadAnyKHR",10065 .name = "OpGroupNonUniformQuadAnyKHR",
9343 .opcode = 5111,10066 .opcode = 5111,
9344 .operands = &[_]Operand{10067 .operands = &.{
9345 .{ .kind = .IdResultType, .quantifier = .required },10068 .{ .kind = .id_result_type, .quantifier = .required },
9346 .{ .kind = .IdResult, .quantifier = .required },10069 .{ .kind = .id_result, .quantifier = .required },
9347 .{ .kind = .IdRef, .quantifier = .required },10070 .{ .kind = .id_ref, .quantifier = .required },
9348 },10071 },
9349 },10072 },
9350 .{10073 .{
9351 .name = "OpHitObjectRecordHitMotionNV",10074 .name = "OpHitObjectRecordHitMotionNV",
9352 .opcode = 5249,10075 .opcode = 5249,
9353 .operands = &[_]Operand{10076 .operands = &.{
9354 .{ .kind = .IdRef, .quantifier = .required },10077 .{ .kind = .id_ref, .quantifier = .required },
9355 .{ .kind = .IdRef, .quantifier = .required },10078 .{ .kind = .id_ref, .quantifier = .required },
9356 .{ .kind = .IdRef, .quantifier = .required },10079 .{ .kind = .id_ref, .quantifier = .required },
9357 .{ .kind = .IdRef, .quantifier = .required },10080 .{ .kind = .id_ref, .quantifier = .required },
9358 .{ .kind = .IdRef, .quantifier = .required },10081 .{ .kind = .id_ref, .quantifier = .required },
9359 .{ .kind = .IdRef, .quantifier = .required },10082 .{ .kind = .id_ref, .quantifier = .required },
9360 .{ .kind = .IdRef, .quantifier = .required },10083 .{ .kind = .id_ref, .quantifier = .required },
9361 .{ .kind = .IdRef, .quantifier = .required },10084 .{ .kind = .id_ref, .quantifier = .required },
9362 .{ .kind = .IdRef, .quantifier = .required },10085 .{ .kind = .id_ref, .quantifier = .required },
9363 .{ .kind = .IdRef, .quantifier = .required },10086 .{ .kind = .id_ref, .quantifier = .required },
9364 .{ .kind = .IdRef, .quantifier = .required },10087 .{ .kind = .id_ref, .quantifier = .required },
9365 .{ .kind = .IdRef, .quantifier = .required },10088 .{ .kind = .id_ref, .quantifier = .required },
9366 .{ .kind = .IdRef, .quantifier = .required },10089 .{ .kind = .id_ref, .quantifier = .required },
9367 .{ .kind = .IdRef, .quantifier = .required },10090 .{ .kind = .id_ref, .quantifier = .required },
9368 },10091 },
9369 },10092 },
9370 .{10093 .{
9371 .name = "OpHitObjectRecordHitWithIndexMotionNV",10094 .name = "OpHitObjectRecordHitWithIndexMotionNV",
9372 .opcode = 5250,10095 .opcode = 5250,
9373 .operands = &[_]Operand{10096 .operands = &.{
9374 .{ .kind = .IdRef, .quantifier = .required },10097 .{ .kind = .id_ref, .quantifier = .required },
9375 .{ .kind = .IdRef, .quantifier = .required },10098 .{ .kind = .id_ref, .quantifier = .required },
9376 .{ .kind = .IdRef, .quantifier = .required },10099 .{ .kind = .id_ref, .quantifier = .required },
9377 .{ .kind = .IdRef, .quantifier = .required },10100 .{ .kind = .id_ref, .quantifier = .required },
9378 .{ .kind = .IdRef, .quantifier = .required },10101 .{ .kind = .id_ref, .quantifier = .required },
9379 .{ .kind = .IdRef, .quantifier = .required },10102 .{ .kind = .id_ref, .quantifier = .required },
9380 .{ .kind = .IdRef, .quantifier = .required },10103 .{ .kind = .id_ref, .quantifier = .required },
9381 .{ .kind = .IdRef, .quantifier = .required },10104 .{ .kind = .id_ref, .quantifier = .required },
9382 .{ .kind = .IdRef, .quantifier = .required },10105 .{ .kind = .id_ref, .quantifier = .required },
9383 .{ .kind = .IdRef, .quantifier = .required },10106 .{ .kind = .id_ref, .quantifier = .required },
9384 .{ .kind = .IdRef, .quantifier = .required },10107 .{ .kind = .id_ref, .quantifier = .required },
9385 .{ .kind = .IdRef, .quantifier = .required },10108 .{ .kind = .id_ref, .quantifier = .required },
9386 .{ .kind = .IdRef, .quantifier = .required },10109 .{ .kind = .id_ref, .quantifier = .required },
9387 },10110 },
9388 },10111 },
9389 .{10112 .{
9390 .name = "OpHitObjectRecordMissMotionNV",10113 .name = "OpHitObjectRecordMissMotionNV",
9391 .opcode = 5251,10114 .opcode = 5251,
9392 .operands = &[_]Operand{10115 .operands = &.{
9393 .{ .kind = .IdRef, .quantifier = .required },10116 .{ .kind = .id_ref, .quantifier = .required },
9394 .{ .kind = .IdRef, .quantifier = .required },10117 .{ .kind = .id_ref, .quantifier = .required },
9395 .{ .kind = .IdRef, .quantifier = .required },10118 .{ .kind = .id_ref, .quantifier = .required },
9396 .{ .kind = .IdRef, .quantifier = .required },10119 .{ .kind = .id_ref, .quantifier = .required },
9397 .{ .kind = .IdRef, .quantifier = .required },10120 .{ .kind = .id_ref, .quantifier = .required },
9398 .{ .kind = .IdRef, .quantifier = .required },10121 .{ .kind = .id_ref, .quantifier = .required },
9399 .{ .kind = .IdRef, .quantifier = .required },10122 .{ .kind = .id_ref, .quantifier = .required },
9400 },10123 },
9401 },10124 },
9402 .{10125 .{
9403 .name = "OpHitObjectGetWorldToObjectNV",10126 .name = "OpHitObjectGetWorldToObjectNV",
9404 .opcode = 5252,10127 .opcode = 5252,
9405 .operands = &[_]Operand{10128 .operands = &.{
9406 .{ .kind = .IdResultType, .quantifier = .required },10129 .{ .kind = .id_result_type, .quantifier = .required },
9407 .{ .kind = .IdResult, .quantifier = .required },10130 .{ .kind = .id_result, .quantifier = .required },
9408 .{ .kind = .IdRef, .quantifier = .required },10131 .{ .kind = .id_ref, .quantifier = .required },
9409 },10132 },
9410 },10133 },
9411 .{10134 .{
9412 .name = "OpHitObjectGetObjectToWorldNV",10135 .name = "OpHitObjectGetObjectToWorldNV",
9413 .opcode = 5253,10136 .opcode = 5253,
9414 .operands = &[_]Operand{10137 .operands = &.{
9415 .{ .kind = .IdResultType, .quantifier = .required },10138 .{ .kind = .id_result_type, .quantifier = .required },
9416 .{ .kind = .IdResult, .quantifier = .required },10139 .{ .kind = .id_result, .quantifier = .required },
9417 .{ .kind = .IdRef, .quantifier = .required },10140 .{ .kind = .id_ref, .quantifier = .required },
9418 },10141 },
9419 },10142 },
9420 .{10143 .{
9421 .name = "OpHitObjectGetObjectRayDirectionNV",10144 .name = "OpHitObjectGetObjectRayDirectionNV",
9422 .opcode = 5254,10145 .opcode = 5254,
9423 .operands = &[_]Operand{10146 .operands = &.{
9424 .{ .kind = .IdResultType, .quantifier = .required },10147 .{ .kind = .id_result_type, .quantifier = .required },
9425 .{ .kind = .IdResult, .quantifier = .required },10148 .{ .kind = .id_result, .quantifier = .required },
9426 .{ .kind = .IdRef, .quantifier = .required },10149 .{ .kind = .id_ref, .quantifier = .required },
9427 },10150 },
9428 },10151 },
9429 .{10152 .{
9430 .name = "OpHitObjectGetObjectRayOriginNV",10153 .name = "OpHitObjectGetObjectRayOriginNV",
9431 .opcode = 5255,10154 .opcode = 5255,
9432 .operands = &[_]Operand{10155 .operands = &.{
9433 .{ .kind = .IdResultType, .quantifier = .required },10156 .{ .kind = .id_result_type, .quantifier = .required },
9434 .{ .kind = .IdResult, .quantifier = .required },10157 .{ .kind = .id_result, .quantifier = .required },
9435 .{ .kind = .IdRef, .quantifier = .required },10158 .{ .kind = .id_ref, .quantifier = .required },
9436 },10159 },
9437 },10160 },
9438 .{10161 .{
9439 .name = "OpHitObjectTraceRayMotionNV",10162 .name = "OpHitObjectTraceRayMotionNV",
9440 .opcode = 5256,10163 .opcode = 5256,
9441 .operands = &[_]Operand{10164 .operands = &.{
9442 .{ .kind = .IdRef, .quantifier = .required },10165 .{ .kind = .id_ref, .quantifier = .required },
9443 .{ .kind = .IdRef, .quantifier = .required },10166 .{ .kind = .id_ref, .quantifier = .required },
9444 .{ .kind = .IdRef, .quantifier = .required },10167 .{ .kind = .id_ref, .quantifier = .required },
9445 .{ .kind = .IdRef, .quantifier = .required },10168 .{ .kind = .id_ref, .quantifier = .required },
9446 .{ .kind = .IdRef, .quantifier = .required },10169 .{ .kind = .id_ref, .quantifier = .required },
9447 .{ .kind = .IdRef, .quantifier = .required },10170 .{ .kind = .id_ref, .quantifier = .required },
9448 .{ .kind = .IdRef, .quantifier = .required },10171 .{ .kind = .id_ref, .quantifier = .required },
9449 .{ .kind = .IdRef, .quantifier = .required },10172 .{ .kind = .id_ref, .quantifier = .required },
9450 .{ .kind = .IdRef, .quantifier = .required },10173 .{ .kind = .id_ref, .quantifier = .required },
9451 .{ .kind = .IdRef, .quantifier = .required },10174 .{ .kind = .id_ref, .quantifier = .required },
9452 .{ .kind = .IdRef, .quantifier = .required },10175 .{ .kind = .id_ref, .quantifier = .required },
9453 .{ .kind = .IdRef, .quantifier = .required },10176 .{ .kind = .id_ref, .quantifier = .required },
9454 .{ .kind = .IdRef, .quantifier = .required },10177 .{ .kind = .id_ref, .quantifier = .required },
9455 },10178 },
9456 },10179 },
9457 .{10180 .{
9458 .name = "OpHitObjectGetShaderRecordBufferHandleNV",10181 .name = "OpHitObjectGetShaderRecordBufferHandleNV",
9459 .opcode = 5257,10182 .opcode = 5257,
9460 .operands = &[_]Operand{10183 .operands = &.{
9461 .{ .kind = .IdResultType, .quantifier = .required },10184 .{ .kind = .id_result_type, .quantifier = .required },
9462 .{ .kind = .IdResult, .quantifier = .required },10185 .{ .kind = .id_result, .quantifier = .required },
9463 .{ .kind = .IdRef, .quantifier = .required },10186 .{ .kind = .id_ref, .quantifier = .required },
9464 },10187 },
9465 },10188 },
9466 .{10189 .{
9467 .name = "OpHitObjectGetShaderBindingTableRecordIndexNV",10190 .name = "OpHitObjectGetShaderBindingTableRecordIndexNV",
9468 .opcode = 5258,10191 .opcode = 5258,
9469 .operands = &[_]Operand{10192 .operands = &.{
9470 .{ .kind = .IdResultType, .quantifier = .required },10193 .{ .kind = .id_result_type, .quantifier = .required },
9471 .{ .kind = .IdResult, .quantifier = .required },10194 .{ .kind = .id_result, .quantifier = .required },
9472 .{ .kind = .IdRef, .quantifier = .required },10195 .{ .kind = .id_ref, .quantifier = .required },
9473 },10196 },
9474 },10197 },
9475 .{10198 .{
9476 .name = "OpHitObjectRecordEmptyNV",10199 .name = "OpHitObjectRecordEmptyNV",
9477 .opcode = 5259,10200 .opcode = 5259,
9478 .operands = &[_]Operand{10201 .operands = &.{
9479 .{ .kind = .IdRef, .quantifier = .required },10202 .{ .kind = .id_ref, .quantifier = .required },
9480 },10203 },
9481 },10204 },
9482 .{10205 .{
9483 .name = "OpHitObjectTraceRayNV",10206 .name = "OpHitObjectTraceRayNV",
9484 .opcode = 5260,10207 .opcode = 5260,
9485 .operands = &[_]Operand{10208 .operands = &.{
9486 .{ .kind = .IdRef, .quantifier = .required },10209 .{ .kind = .id_ref, .quantifier = .required },
9487 .{ .kind = .IdRef, .quantifier = .required },10210 .{ .kind = .id_ref, .quantifier = .required },
9488 .{ .kind = .IdRef, .quantifier = .required },10211 .{ .kind = .id_ref, .quantifier = .required },
9489 .{ .kind = .IdRef, .quantifier = .required },10212 .{ .kind = .id_ref, .quantifier = .required },
9490 .{ .kind = .IdRef, .quantifier = .required },10213 .{ .kind = .id_ref, .quantifier = .required },
9491 .{ .kind = .IdRef, .quantifier = .required },10214 .{ .kind = .id_ref, .quantifier = .required },
9492 .{ .kind = .IdRef, .quantifier = .required },10215 .{ .kind = .id_ref, .quantifier = .required },
9493 .{ .kind = .IdRef, .quantifier = .required },10216 .{ .kind = .id_ref, .quantifier = .required },
9494 .{ .kind = .IdRef, .quantifier = .required },10217 .{ .kind = .id_ref, .quantifier = .required },
9495 .{ .kind = .IdRef, .quantifier = .required },10218 .{ .kind = .id_ref, .quantifier = .required },
9496 .{ .kind = .IdRef, .quantifier = .required },10219 .{ .kind = .id_ref, .quantifier = .required },
9497 .{ .kind = .IdRef, .quantifier = .required },10220 .{ .kind = .id_ref, .quantifier = .required },
9498 },10221 },
9499 },10222 },
9500 .{10223 .{
9501 .name = "OpHitObjectRecordHitNV",10224 .name = "OpHitObjectRecordHitNV",
9502 .opcode = 5261,10225 .opcode = 5261,
9503 .operands = &[_]Operand{10226 .operands = &.{
9504 .{ .kind = .IdRef, .quantifier = .required },10227 .{ .kind = .id_ref, .quantifier = .required },
9505 .{ .kind = .IdRef, .quantifier = .required },10228 .{ .kind = .id_ref, .quantifier = .required },
9506 .{ .kind = .IdRef, .quantifier = .required },10229 .{ .kind = .id_ref, .quantifier = .required },
9507 .{ .kind = .IdRef, .quantifier = .required },10230 .{ .kind = .id_ref, .quantifier = .required },
9508 .{ .kind = .IdRef, .quantifier = .required },10231 .{ .kind = .id_ref, .quantifier = .required },
9509 .{ .kind = .IdRef, .quantifier = .required },10232 .{ .kind = .id_ref, .quantifier = .required },
9510 .{ .kind = .IdRef, .quantifier = .required },10233 .{ .kind = .id_ref, .quantifier = .required },
9511 .{ .kind = .IdRef, .quantifier = .required },10234 .{ .kind = .id_ref, .quantifier = .required },
9512 .{ .kind = .IdRef, .quantifier = .required },10235 .{ .kind = .id_ref, .quantifier = .required },
9513 .{ .kind = .IdRef, .quantifier = .required },10236 .{ .kind = .id_ref, .quantifier = .required },
9514 .{ .kind = .IdRef, .quantifier = .required },10237 .{ .kind = .id_ref, .quantifier = .required },
9515 .{ .kind = .IdRef, .quantifier = .required },10238 .{ .kind = .id_ref, .quantifier = .required },
9516 .{ .kind = .IdRef, .quantifier = .required },10239 .{ .kind = .id_ref, .quantifier = .required },
9517 },10240 },
9518 },10241 },
9519 .{10242 .{
9520 .name = "OpHitObjectRecordHitWithIndexNV",10243 .name = "OpHitObjectRecordHitWithIndexNV",
9521 .opcode = 5262,10244 .opcode = 5262,
9522 .operands = &[_]Operand{10245 .operands = &.{
9523 .{ .kind = .IdRef, .quantifier = .required },10246 .{ .kind = .id_ref, .quantifier = .required },
9524 .{ .kind = .IdRef, .quantifier = .required },10247 .{ .kind = .id_ref, .quantifier = .required },
9525 .{ .kind = .IdRef, .quantifier = .required },10248 .{ .kind = .id_ref, .quantifier = .required },
9526 .{ .kind = .IdRef, .quantifier = .required },10249 .{ .kind = .id_ref, .quantifier = .required },
9527 .{ .kind = .IdRef, .quantifier = .required },10250 .{ .kind = .id_ref, .quantifier = .required },
9528 .{ .kind = .IdRef, .quantifier = .required },10251 .{ .kind = .id_ref, .quantifier = .required },
9529 .{ .kind = .IdRef, .quantifier = .required },10252 .{ .kind = .id_ref, .quantifier = .required },
9530 .{ .kind = .IdRef, .quantifier = .required },10253 .{ .kind = .id_ref, .quantifier = .required },
9531 .{ .kind = .IdRef, .quantifier = .required },10254 .{ .kind = .id_ref, .quantifier = .required },
9532 .{ .kind = .IdRef, .quantifier = .required },10255 .{ .kind = .id_ref, .quantifier = .required },
9533 .{ .kind = .IdRef, .quantifier = .required },10256 .{ .kind = .id_ref, .quantifier = .required },
9534 .{ .kind = .IdRef, .quantifier = .required },10257 .{ .kind = .id_ref, .quantifier = .required },
9535 },10258 },
9536 },10259 },
9537 .{10260 .{
9538 .name = "OpHitObjectRecordMissNV",10261 .name = "OpHitObjectRecordMissNV",
9539 .opcode = 5263,10262 .opcode = 5263,
9540 .operands = &[_]Operand{10263 .operands = &.{
9541 .{ .kind = .IdRef, .quantifier = .required },10264 .{ .kind = .id_ref, .quantifier = .required },
9542 .{ .kind = .IdRef, .quantifier = .required },10265 .{ .kind = .id_ref, .quantifier = .required },
9543 .{ .kind = .IdRef, .quantifier = .required },10266 .{ .kind = .id_ref, .quantifier = .required },
9544 .{ .kind = .IdRef, .quantifier = .required },10267 .{ .kind = .id_ref, .quantifier = .required },
9545 .{ .kind = .IdRef, .quantifier = .required },10268 .{ .kind = .id_ref, .quantifier = .required },
9546 .{ .kind = .IdRef, .quantifier = .required },10269 .{ .kind = .id_ref, .quantifier = .required },
9547 },10270 },
9548 },10271 },
9549 .{10272 .{
9550 .name = "OpHitObjectExecuteShaderNV",10273 .name = "OpHitObjectExecuteShaderNV",
9551 .opcode = 5264,10274 .opcode = 5264,
9552 .operands = &[_]Operand{10275 .operands = &.{
9553 .{ .kind = .IdRef, .quantifier = .required },10276 .{ .kind = .id_ref, .quantifier = .required },
9554 .{ .kind = .IdRef, .quantifier = .required },10277 .{ .kind = .id_ref, .quantifier = .required },
9555 },10278 },
9556 },10279 },
9557 .{10280 .{
9558 .name = "OpHitObjectGetCurrentTimeNV",10281 .name = "OpHitObjectGetCurrentTimeNV",
9559 .opcode = 5265,10282 .opcode = 5265,
9560 .operands = &[_]Operand{10283 .operands = &.{
9561 .{ .kind = .IdResultType, .quantifier = .required },10284 .{ .kind = .id_result_type, .quantifier = .required },
9562 .{ .kind = .IdResult, .quantifier = .required },10285 .{ .kind = .id_result, .quantifier = .required },
9563 .{ .kind = .IdRef, .quantifier = .required },10286 .{ .kind = .id_ref, .quantifier = .required },
9564 },10287 },
9565 },10288 },
9566 .{10289 .{
9567 .name = "OpHitObjectGetAttributesNV",10290 .name = "OpHitObjectGetAttributesNV",
9568 .opcode = 5266,10291 .opcode = 5266,
9569 .operands = &[_]Operand{10292 .operands = &.{
9570 .{ .kind = .IdRef, .quantifier = .required },10293 .{ .kind = .id_ref, .quantifier = .required },
9571 .{ .kind = .IdRef, .quantifier = .required },10294 .{ .kind = .id_ref, .quantifier = .required },
9572 },10295 },
9573 },10296 },
9574 .{10297 .{
9575 .name = "OpHitObjectGetHitKindNV",10298 .name = "OpHitObjectGetHitKindNV",
9576 .opcode = 5267,10299 .opcode = 5267,
9577 .operands = &[_]Operand{10300 .operands = &.{
9578 .{ .kind = .IdResultType, .quantifier = .required },10301 .{ .kind = .id_result_type, .quantifier = .required },
9579 .{ .kind = .IdResult, .quantifier = .required },10302 .{ .kind = .id_result, .quantifier = .required },
9580 .{ .kind = .IdRef, .quantifier = .required },10303 .{ .kind = .id_ref, .quantifier = .required },
9581 },10304 },
9582 },10305 },
9583 .{10306 .{
9584 .name = "OpHitObjectGetPrimitiveIndexNV",10307 .name = "OpHitObjectGetPrimitiveIndexNV",
9585 .opcode = 5268,10308 .opcode = 5268,
9586 .operands = &[_]Operand{10309 .operands = &.{
9587 .{ .kind = .IdResultType, .quantifier = .required },10310 .{ .kind = .id_result_type, .quantifier = .required },
9588 .{ .kind = .IdResult, .quantifier = .required },10311 .{ .kind = .id_result, .quantifier = .required },
9589 .{ .kind = .IdRef, .quantifier = .required },10312 .{ .kind = .id_ref, .quantifier = .required },
9590 },10313 },
9591 },10314 },
9592 .{10315 .{
9593 .name = "OpHitObjectGetGeometryIndexNV",10316 .name = "OpHitObjectGetGeometryIndexNV",
9594 .opcode = 5269,10317 .opcode = 5269,
9595 .operands = &[_]Operand{10318 .operands = &.{
9596 .{ .kind = .IdResultType, .quantifier = .required },10319 .{ .kind = .id_result_type, .quantifier = .required },
9597 .{ .kind = .IdResult, .quantifier = .required },10320 .{ .kind = .id_result, .quantifier = .required },
9598 .{ .kind = .IdRef, .quantifier = .required },10321 .{ .kind = .id_ref, .quantifier = .required },
9599 },10322 },
9600 },10323 },
9601 .{10324 .{
9602 .name = "OpHitObjectGetInstanceIdNV",10325 .name = "OpHitObjectGetInstanceIdNV",
9603 .opcode = 5270,10326 .opcode = 5270,
9604 .operands = &[_]Operand{10327 .operands = &.{
9605 .{ .kind = .IdResultType, .quantifier = .required },10328 .{ .kind = .id_result_type, .quantifier = .required },
9606 .{ .kind = .IdResult, .quantifier = .required },10329 .{ .kind = .id_result, .quantifier = .required },
9607 .{ .kind = .IdRef, .quantifier = .required },10330 .{ .kind = .id_ref, .quantifier = .required },
9608 },10331 },
9609 },10332 },
9610 .{10333 .{
9611 .name = "OpHitObjectGetInstanceCustomIndexNV",10334 .name = "OpHitObjectGetInstanceCustomIndexNV",
9612 .opcode = 5271,10335 .opcode = 5271,
9613 .operands = &[_]Operand{10336 .operands = &.{
9614 .{ .kind = .IdResultType, .quantifier = .required },10337 .{ .kind = .id_result_type, .quantifier = .required },
9615 .{ .kind = .IdResult, .quantifier = .required },10338 .{ .kind = .id_result, .quantifier = .required },
9616 .{ .kind = .IdRef, .quantifier = .required },10339 .{ .kind = .id_ref, .quantifier = .required },
9617 },10340 },
9618 },10341 },
9619 .{10342 .{
9620 .name = "OpHitObjectGetWorldRayDirectionNV",10343 .name = "OpHitObjectGetWorldRayDirectionNV",
9621 .opcode = 5272,10344 .opcode = 5272,
9622 .operands = &[_]Operand{10345 .operands = &.{
9623 .{ .kind = .IdResultType, .quantifier = .required },10346 .{ .kind = .id_result_type, .quantifier = .required },
9624 .{ .kind = .IdResult, .quantifier = .required },10347 .{ .kind = .id_result, .quantifier = .required },
9625 .{ .kind = .IdRef, .quantifier = .required },10348 .{ .kind = .id_ref, .quantifier = .required },
9626 },10349 },
9627 },10350 },
9628 .{10351 .{
9629 .name = "OpHitObjectGetWorldRayOriginNV",10352 .name = "OpHitObjectGetWorldRayOriginNV",
9630 .opcode = 5273,10353 .opcode = 5273,
9631 .operands = &[_]Operand{10354 .operands = &.{
9632 .{ .kind = .IdResultType, .quantifier = .required },10355 .{ .kind = .id_result_type, .quantifier = .required },
9633 .{ .kind = .IdResult, .quantifier = .required },10356 .{ .kind = .id_result, .quantifier = .required },
9634 .{ .kind = .IdRef, .quantifier = .required },10357 .{ .kind = .id_ref, .quantifier = .required },
9635 },10358 },
9636 },10359 },
9637 .{10360 .{
9638 .name = "OpHitObjectGetRayTMaxNV",10361 .name = "OpHitObjectGetRayTMaxNV",
9639 .opcode = 5274,10362 .opcode = 5274,
9640 .operands = &[_]Operand{10363 .operands = &.{
9641 .{ .kind = .IdResultType, .quantifier = .required },10364 .{ .kind = .id_result_type, .quantifier = .required },
9642 .{ .kind = .IdResult, .quantifier = .required },10365 .{ .kind = .id_result, .quantifier = .required },
9643 .{ .kind = .IdRef, .quantifier = .required },10366 .{ .kind = .id_ref, .quantifier = .required },
9644 },10367 },
9645 },10368 },
9646 .{10369 .{
9647 .name = "OpHitObjectGetRayTMinNV",10370 .name = "OpHitObjectGetRayTMinNV",
9648 .opcode = 5275,10371 .opcode = 5275,
9649 .operands = &[_]Operand{10372 .operands = &.{
9650 .{ .kind = .IdResultType, .quantifier = .required },10373 .{ .kind = .id_result_type, .quantifier = .required },
9651 .{ .kind = .IdResult, .quantifier = .required },10374 .{ .kind = .id_result, .quantifier = .required },
9652 .{ .kind = .IdRef, .quantifier = .required },10375 .{ .kind = .id_ref, .quantifier = .required },
9653 },10376 },
9654 },10377 },
9655 .{10378 .{
9656 .name = "OpHitObjectIsEmptyNV",10379 .name = "OpHitObjectIsEmptyNV",
9657 .opcode = 5276,10380 .opcode = 5276,
9658 .operands = &[_]Operand{10381 .operands = &.{
9659 .{ .kind = .IdResultType, .quantifier = .required },10382 .{ .kind = .id_result_type, .quantifier = .required },
9660 .{ .kind = .IdResult, .quantifier = .required },10383 .{ .kind = .id_result, .quantifier = .required },
9661 .{ .kind = .IdRef, .quantifier = .required },10384 .{ .kind = .id_ref, .quantifier = .required },
9662 },10385 },
9663 },10386 },
9664 .{10387 .{
9665 .name = "OpHitObjectIsHitNV",10388 .name = "OpHitObjectIsHitNV",
9666 .opcode = 5277,10389 .opcode = 5277,
9667 .operands = &[_]Operand{10390 .operands = &.{
9668 .{ .kind = .IdResultType, .quantifier = .required },10391 .{ .kind = .id_result_type, .quantifier = .required },
9669 .{ .kind = .IdResult, .quantifier = .required },10392 .{ .kind = .id_result, .quantifier = .required },
9670 .{ .kind = .IdRef, .quantifier = .required },10393 .{ .kind = .id_ref, .quantifier = .required },
9671 },10394 },
9672 },10395 },
9673 .{10396 .{
9674 .name = "OpHitObjectIsMissNV",10397 .name = "OpHitObjectIsMissNV",
9675 .opcode = 5278,10398 .opcode = 5278,
9676 .operands = &[_]Operand{10399 .operands = &.{
9677 .{ .kind = .IdResultType, .quantifier = .required },10400 .{ .kind = .id_result_type, .quantifier = .required },
9678 .{ .kind = .IdResult, .quantifier = .required },10401 .{ .kind = .id_result, .quantifier = .required },
9679 .{ .kind = .IdRef, .quantifier = .required },10402 .{ .kind = .id_ref, .quantifier = .required },
9680 },10403 },
9681 },10404 },
9682 .{10405 .{
9683 .name = "OpReorderThreadWithHitObjectNV",10406 .name = "OpReorderThreadWithHitObjectNV",
9684 .opcode = 5279,10407 .opcode = 5279,
9685 .operands = &[_]Operand{10408 .operands = &.{
9686 .{ .kind = .IdRef, .quantifier = .required },10409 .{ .kind = .id_ref, .quantifier = .required },
9687 .{ .kind = .IdRef, .quantifier = .optional },10410 .{ .kind = .id_ref, .quantifier = .optional },
9688 .{ .kind = .IdRef, .quantifier = .optional },10411 .{ .kind = .id_ref, .quantifier = .optional },
9689 },10412 },
9690 },10413 },
9691 .{10414 .{
9692 .name = "OpReorderThreadWithHintNV",10415 .name = "OpReorderThreadWithHintNV",
9693 .opcode = 5280,10416 .opcode = 5280,
9694 .operands = &[_]Operand{10417 .operands = &.{
9695 .{ .kind = .IdRef, .quantifier = .required },10418 .{ .kind = .id_ref, .quantifier = .required },
9696 .{ .kind = .IdRef, .quantifier = .required },10419 .{ .kind = .id_ref, .quantifier = .required },
9697 },10420 },
9698 },10421 },
9699 .{10422 .{
9700 .name = "OpTypeHitObjectNV",10423 .name = "OpTypeHitObjectNV",
9701 .opcode = 5281,10424 .opcode = 5281,
9702 .operands = &[_]Operand{10425 .operands = &.{
9703 .{ .kind = .IdResult, .quantifier = .required },10426 .{ .kind = .id_result, .quantifier = .required },
9704 },10427 },
9705 },10428 },
9706 .{10429 .{
9707 .name = "OpImageSampleFootprintNV",10430 .name = "OpImageSampleFootprintNV",
9708 .opcode = 5283,10431 .opcode = 5283,
9709 .operands = &[_]Operand{10432 .operands = &.{
9710 .{ .kind = .IdResultType, .quantifier = .required },10433 .{ .kind = .id_result_type, .quantifier = .required },
9711 .{ .kind = .IdResult, .quantifier = .required },10434 .{ .kind = .id_result, .quantifier = .required },
9712 .{ .kind = .IdRef, .quantifier = .required },10435 .{ .kind = .id_ref, .quantifier = .required },
9713 .{ .kind = .IdRef, .quantifier = .required },10436 .{ .kind = .id_ref, .quantifier = .required },
9714 .{ .kind = .IdRef, .quantifier = .required },10437 .{ .kind = .id_ref, .quantifier = .required },
9715 .{ .kind = .IdRef, .quantifier = .required },10438 .{ .kind = .id_ref, .quantifier = .required },
9716 .{ .kind = .ImageOperands, .quantifier = .optional },10439 .{ .kind = .image_operands, .quantifier = .optional },
10440 },
10441 },
10442 .{
10443 .name = "OpTypeCooperativeVectorNV",
10444 .opcode = 5288,
10445 .operands = &.{
10446 .{ .kind = .id_result, .quantifier = .required },
10447 .{ .kind = .id_ref, .quantifier = .required },
10448 .{ .kind = .id_ref, .quantifier = .required },
10449 },
10450 },
10451 .{
10452 .name = "OpCooperativeVectorMatrixMulNV",
10453 .opcode = 5289,
10454 .operands = &.{
10455 .{ .kind = .id_result_type, .quantifier = .required },
10456 .{ .kind = .id_result, .quantifier = .required },
10457 .{ .kind = .id_ref, .quantifier = .required },
10458 .{ .kind = .id_ref, .quantifier = .required },
10459 .{ .kind = .id_ref, .quantifier = .required },
10460 .{ .kind = .id_ref, .quantifier = .required },
10461 .{ .kind = .id_ref, .quantifier = .required },
10462 .{ .kind = .id_ref, .quantifier = .required },
10463 .{ .kind = .id_ref, .quantifier = .required },
10464 .{ .kind = .id_ref, .quantifier = .required },
10465 .{ .kind = .id_ref, .quantifier = .required },
10466 .{ .kind = .id_ref, .quantifier = .optional },
10467 .{ .kind = .cooperative_matrix_operands, .quantifier = .optional },
10468 },
10469 },
10470 .{
10471 .name = "OpCooperativeVectorOuterProductAccumulateNV",
10472 .opcode = 5290,
10473 .operands = &.{
10474 .{ .kind = .id_ref, .quantifier = .required },
10475 .{ .kind = .id_ref, .quantifier = .required },
10476 .{ .kind = .id_ref, .quantifier = .required },
10477 .{ .kind = .id_ref, .quantifier = .required },
10478 .{ .kind = .id_ref, .quantifier = .required },
10479 .{ .kind = .id_ref, .quantifier = .required },
10480 .{ .kind = .id_ref, .quantifier = .optional },
10481 },
10482 },
10483 .{
10484 .name = "OpCooperativeVectorReduceSumAccumulateNV",
10485 .opcode = 5291,
10486 .operands = &.{
10487 .{ .kind = .id_ref, .quantifier = .required },
10488 .{ .kind = .id_ref, .quantifier = .required },
10489 .{ .kind = .id_ref, .quantifier = .required },
10490 },
10491 },
10492 .{
10493 .name = "OpCooperativeVectorMatrixMulAddNV",
10494 .opcode = 5292,
10495 .operands = &.{
10496 .{ .kind = .id_result_type, .quantifier = .required },
10497 .{ .kind = .id_result, .quantifier = .required },
10498 .{ .kind = .id_ref, .quantifier = .required },
10499 .{ .kind = .id_ref, .quantifier = .required },
10500 .{ .kind = .id_ref, .quantifier = .required },
10501 .{ .kind = .id_ref, .quantifier = .required },
10502 .{ .kind = .id_ref, .quantifier = .required },
10503 .{ .kind = .id_ref, .quantifier = .required },
10504 .{ .kind = .id_ref, .quantifier = .required },
10505 .{ .kind = .id_ref, .quantifier = .required },
10506 .{ .kind = .id_ref, .quantifier = .required },
10507 .{ .kind = .id_ref, .quantifier = .required },
10508 .{ .kind = .id_ref, .quantifier = .required },
10509 .{ .kind = .id_ref, .quantifier = .required },
10510 .{ .kind = .id_ref, .quantifier = .optional },
10511 .{ .kind = .cooperative_matrix_operands, .quantifier = .optional },
10512 },
10513 },
10514 .{
10515 .name = "OpCooperativeMatrixConvertNV",
10516 .opcode = 5293,
10517 .operands = &.{
10518 .{ .kind = .id_result_type, .quantifier = .required },
10519 .{ .kind = .id_result, .quantifier = .required },
10520 .{ .kind = .id_ref, .quantifier = .required },
9717 },10521 },
9718 },10522 },
9719 .{10523 .{
9720 .name = "OpEmitMeshTasksEXT",10524 .name = "OpEmitMeshTasksEXT",
9721 .opcode = 5294,10525 .opcode = 5294,
9722 .operands = &[_]Operand{10526 .operands = &.{
9723 .{ .kind = .IdRef, .quantifier = .required },10527 .{ .kind = .id_ref, .quantifier = .required },
9724 .{ .kind = .IdRef, .quantifier = .required },10528 .{ .kind = .id_ref, .quantifier = .required },
9725 .{ .kind = .IdRef, .quantifier = .required },10529 .{ .kind = .id_ref, .quantifier = .required },
9726 .{ .kind = .IdRef, .quantifier = .optional },10530 .{ .kind = .id_ref, .quantifier = .optional },
9727 },10531 },
9728 },10532 },
9729 .{10533 .{
9730 .name = "OpSetMeshOutputsEXT",10534 .name = "OpSetMeshOutputsEXT",
9731 .opcode = 5295,10535 .opcode = 5295,
9732 .operands = &[_]Operand{10536 .operands = &.{
9733 .{ .kind = .IdRef, .quantifier = .required },10537 .{ .kind = .id_ref, .quantifier = .required },
9734 .{ .kind = .IdRef, .quantifier = .required },10538 .{ .kind = .id_ref, .quantifier = .required },
9735 },10539 },
9736 },10540 },
9737 .{10541 .{
9738 .name = "OpGroupNonUniformPartitionNV",10542 .name = "OpGroupNonUniformPartitionNV",
9739 .opcode = 5296,10543 .opcode = 5296,
9740 .operands = &[_]Operand{10544 .operands = &.{
9741 .{ .kind = .IdResultType, .quantifier = .required },10545 .{ .kind = .id_result_type, .quantifier = .required },
9742 .{ .kind = .IdResult, .quantifier = .required },10546 .{ .kind = .id_result, .quantifier = .required },
9743 .{ .kind = .IdRef, .quantifier = .required },10547 .{ .kind = .id_ref, .quantifier = .required },
9744 },10548 },
9745 },10549 },
9746 .{10550 .{
9747 .name = "OpWritePackedPrimitiveIndices4x8NV",10551 .name = "OpWritePackedPrimitiveIndices4x8NV",
9748 .opcode = 5299,10552 .opcode = 5299,
9749 .operands = &[_]Operand{10553 .operands = &.{
9750 .{ .kind = .IdRef, .quantifier = .required },10554 .{ .kind = .id_ref, .quantifier = .required },
9751 .{ .kind = .IdRef, .quantifier = .required },10555 .{ .kind = .id_ref, .quantifier = .required },
9752 },10556 },
9753 },10557 },
9754 .{10558 .{
9755 .name = "OpFetchMicroTriangleVertexPositionNV",10559 .name = "OpFetchMicroTriangleVertexPositionNV",
9756 .opcode = 5300,10560 .opcode = 5300,
9757 .operands = &[_]Operand{10561 .operands = &.{
9758 .{ .kind = .IdResultType, .quantifier = .required },10562 .{ .kind = .id_result_type, .quantifier = .required },
9759 .{ .kind = .IdResult, .quantifier = .required },10563 .{ .kind = .id_result, .quantifier = .required },
9760 .{ .kind = .IdRef, .quantifier = .required },10564 .{ .kind = .id_ref, .quantifier = .required },
9761 .{ .kind = .IdRef, .quantifier = .required },10565 .{ .kind = .id_ref, .quantifier = .required },
9762 .{ .kind = .IdRef, .quantifier = .required },10566 .{ .kind = .id_ref, .quantifier = .required },
9763 .{ .kind = .IdRef, .quantifier = .required },10567 .{ .kind = .id_ref, .quantifier = .required },
9764 .{ .kind = .IdRef, .quantifier = .required },10568 .{ .kind = .id_ref, .quantifier = .required },
9765 },10569 },
9766 },10570 },
9767 .{10571 .{
9768 .name = "OpFetchMicroTriangleVertexBarycentricNV",10572 .name = "OpFetchMicroTriangleVertexBarycentricNV",
9769 .opcode = 5301,10573 .opcode = 5301,
9770 .operands = &[_]Operand{10574 .operands = &.{
9771 .{ .kind = .IdResultType, .quantifier = .required },10575 .{ .kind = .id_result_type, .quantifier = .required },
9772 .{ .kind = .IdResult, .quantifier = .required },10576 .{ .kind = .id_result, .quantifier = .required },
9773 .{ .kind = .IdRef, .quantifier = .required },10577 .{ .kind = .id_ref, .quantifier = .required },
9774 .{ .kind = .IdRef, .quantifier = .required },10578 .{ .kind = .id_ref, .quantifier = .required },
9775 .{ .kind = .IdRef, .quantifier = .required },10579 .{ .kind = .id_ref, .quantifier = .required },
9776 .{ .kind = .IdRef, .quantifier = .required },10580 .{ .kind = .id_ref, .quantifier = .required },
9777 .{ .kind = .IdRef, .quantifier = .required },10581 .{ .kind = .id_ref, .quantifier = .required },
9778 },10582 },
9779 },10583 },
9780 .{10584 .{
9781 .name = "OpReportIntersectionNV",10585 .name = "OpCooperativeVectorLoadNV",
9782 .opcode = 5334,10586 .opcode = 5302,
9783 .operands = &[_]Operand{10587 .operands = &.{
9784 .{ .kind = .IdResultType, .quantifier = .required },10588 .{ .kind = .id_result_type, .quantifier = .required },
9785 .{ .kind = .IdResult, .quantifier = .required },10589 .{ .kind = .id_result, .quantifier = .required },
9786 .{ .kind = .IdRef, .quantifier = .required },10590 .{ .kind = .id_ref, .quantifier = .required },
9787 .{ .kind = .IdRef, .quantifier = .required },10591 .{ .kind = .id_ref, .quantifier = .required },
10592 .{ .kind = .memory_access, .quantifier = .optional },
10593 },
10594 },
10595 .{
10596 .name = "OpCooperativeVectorStoreNV",
10597 .opcode = 5303,
10598 .operands = &.{
10599 .{ .kind = .id_ref, .quantifier = .required },
10600 .{ .kind = .id_ref, .quantifier = .required },
10601 .{ .kind = .id_ref, .quantifier = .required },
10602 .{ .kind = .memory_access, .quantifier = .optional },
9788 },10603 },
9789 },10604 },
9790 .{10605 .{
9791 .name = "OpReportIntersectionKHR",10606 .name = "OpReportIntersectionKHR",
9792 .opcode = 5334,10607 .opcode = 5334,
9793 .operands = &[_]Operand{10608 .operands = &.{
9794 .{ .kind = .IdResultType, .quantifier = .required },10609 .{ .kind = .id_result_type, .quantifier = .required },
9795 .{ .kind = .IdResult, .quantifier = .required },10610 .{ .kind = .id_result, .quantifier = .required },
9796 .{ .kind = .IdRef, .quantifier = .required },10611 .{ .kind = .id_ref, .quantifier = .required },
9797 .{ .kind = .IdRef, .quantifier = .required },10612 .{ .kind = .id_ref, .quantifier = .required },
9798 },10613 },
9799 },10614 },
9800 .{10615 .{
9801 .name = "OpIgnoreIntersectionNV",10616 .name = "OpIgnoreIntersectionNV",
9802 .opcode = 5335,10617 .opcode = 5335,
9803 .operands = &[_]Operand{},10618 .operands = &.{},
9804 },10619 },
9805 .{10620 .{
9806 .name = "OpTerminateRayNV",10621 .name = "OpTerminateRayNV",
9807 .opcode = 5336,10622 .opcode = 5336,
9808 .operands = &[_]Operand{},10623 .operands = &.{},
9809 },10624 },
9810 .{10625 .{
9811 .name = "OpTraceNV",10626 .name = "OpTraceNV",
9812 .opcode = 5337,10627 .opcode = 5337,
9813 .operands = &[_]Operand{10628 .operands = &.{
9814 .{ .kind = .IdRef, .quantifier = .required },10629 .{ .kind = .id_ref, .quantifier = .required },
9815 .{ .kind = .IdRef, .quantifier = .required },10630 .{ .kind = .id_ref, .quantifier = .required },
9816 .{ .kind = .IdRef, .quantifier = .required },10631 .{ .kind = .id_ref, .quantifier = .required },
9817 .{ .kind = .IdRef, .quantifier = .required },10632 .{ .kind = .id_ref, .quantifier = .required },
9818 .{ .kind = .IdRef, .quantifier = .required },10633 .{ .kind = .id_ref, .quantifier = .required },
9819 .{ .kind = .IdRef, .quantifier = .required },10634 .{ .kind = .id_ref, .quantifier = .required },
9820 .{ .kind = .IdRef, .quantifier = .required },10635 .{ .kind = .id_ref, .quantifier = .required },
9821 .{ .kind = .IdRef, .quantifier = .required },10636 .{ .kind = .id_ref, .quantifier = .required },
9822 .{ .kind = .IdRef, .quantifier = .required },10637 .{ .kind = .id_ref, .quantifier = .required },
9823 .{ .kind = .IdRef, .quantifier = .required },10638 .{ .kind = .id_ref, .quantifier = .required },
9824 .{ .kind = .IdRef, .quantifier = .required },10639 .{ .kind = .id_ref, .quantifier = .required },
9825 },10640 },
9826 },10641 },
9827 .{10642 .{
9828 .name = "OpTraceMotionNV",10643 .name = "OpTraceMotionNV",
9829 .opcode = 5338,10644 .opcode = 5338,
9830 .operands = &[_]Operand{10645 .operands = &.{
9831 .{ .kind = .IdRef, .quantifier = .required },10646 .{ .kind = .id_ref, .quantifier = .required },
9832 .{ .kind = .IdRef, .quantifier = .required },10647 .{ .kind = .id_ref, .quantifier = .required },
9833 .{ .kind = .IdRef, .quantifier = .required },10648 .{ .kind = .id_ref, .quantifier = .required },
9834 .{ .kind = .IdRef, .quantifier = .required },10649 .{ .kind = .id_ref, .quantifier = .required },
9835 .{ .kind = .IdRef, .quantifier = .required },10650 .{ .kind = .id_ref, .quantifier = .required },
9836 .{ .kind = .IdRef, .quantifier = .required },10651 .{ .kind = .id_ref, .quantifier = .required },
9837 .{ .kind = .IdRef, .quantifier = .required },10652 .{ .kind = .id_ref, .quantifier = .required },
9838 .{ .kind = .IdRef, .quantifier = .required },10653 .{ .kind = .id_ref, .quantifier = .required },
9839 .{ .kind = .IdRef, .quantifier = .required },10654 .{ .kind = .id_ref, .quantifier = .required },
9840 .{ .kind = .IdRef, .quantifier = .required },10655 .{ .kind = .id_ref, .quantifier = .required },
9841 .{ .kind = .IdRef, .quantifier = .required },10656 .{ .kind = .id_ref, .quantifier = .required },
9842 .{ .kind = .IdRef, .quantifier = .required },10657 .{ .kind = .id_ref, .quantifier = .required },
9843 },10658 },
9844 },10659 },
9845 .{10660 .{
9846 .name = "OpTraceRayMotionNV",10661 .name = "OpTraceRayMotionNV",
9847 .opcode = 5339,10662 .opcode = 5339,
9848 .operands = &[_]Operand{10663 .operands = &.{
9849 .{ .kind = .IdRef, .quantifier = .required },10664 .{ .kind = .id_ref, .quantifier = .required },
9850 .{ .kind = .IdRef, .quantifier = .required },10665 .{ .kind = .id_ref, .quantifier = .required },
9851 .{ .kind = .IdRef, .quantifier = .required },10666 .{ .kind = .id_ref, .quantifier = .required },
9852 .{ .kind = .IdRef, .quantifier = .required },10667 .{ .kind = .id_ref, .quantifier = .required },
9853 .{ .kind = .IdRef, .quantifier = .required },10668 .{ .kind = .id_ref, .quantifier = .required },
9854 .{ .kind = .IdRef, .quantifier = .required },10669 .{ .kind = .id_ref, .quantifier = .required },
9855 .{ .kind = .IdRef, .quantifier = .required },10670 .{ .kind = .id_ref, .quantifier = .required },
9856 .{ .kind = .IdRef, .quantifier = .required },10671 .{ .kind = .id_ref, .quantifier = .required },
9857 .{ .kind = .IdRef, .quantifier = .required },10672 .{ .kind = .id_ref, .quantifier = .required },
9858 .{ .kind = .IdRef, .quantifier = .required },10673 .{ .kind = .id_ref, .quantifier = .required },
9859 .{ .kind = .IdRef, .quantifier = .required },10674 .{ .kind = .id_ref, .quantifier = .required },
9860 .{ .kind = .IdRef, .quantifier = .required },10675 .{ .kind = .id_ref, .quantifier = .required },
9861 },10676 },
9862 },10677 },
9863 .{10678 .{
9864 .name = "OpRayQueryGetIntersectionTriangleVertexPositionsKHR",10679 .name = "OpRayQueryGetIntersectionTriangleVertexPositionsKHR",
9865 .opcode = 5340,10680 .opcode = 5340,
9866 .operands = &[_]Operand{10681 .operands = &.{
9867 .{ .kind = .IdResultType, .quantifier = .required },10682 .{ .kind = .id_result_type, .quantifier = .required },
9868 .{ .kind = .IdResult, .quantifier = .required },10683 .{ .kind = .id_result, .quantifier = .required },
9869 .{ .kind = .IdRef, .quantifier = .required },10684 .{ .kind = .id_ref, .quantifier = .required },
9870 .{ .kind = .IdRef, .quantifier = .required },10685 .{ .kind = .id_ref, .quantifier = .required },
9871 },
9872 },
9873 .{
9874 .name = "OpTypeAccelerationStructureNV",
9875 .opcode = 5341,
9876 .operands = &[_]Operand{
9877 .{ .kind = .IdResult, .quantifier = .required },
9878 },10686 },
9879 },10687 },
9880 .{10688 .{
9881 .name = "OpTypeAccelerationStructureKHR",10689 .name = "OpTypeAccelerationStructureKHR",
9882 .opcode = 5341,10690 .opcode = 5341,
9883 .operands = &[_]Operand{10691 .operands = &.{
9884 .{ .kind = .IdResult, .quantifier = .required },10692 .{ .kind = .id_result, .quantifier = .required },
9885 },10693 },
9886 },10694 },
9887 .{10695 .{
9888 .name = "OpExecuteCallableNV",10696 .name = "OpExecuteCallableNV",
9889 .opcode = 5344,10697 .opcode = 5344,
9890 .operands = &[_]Operand{10698 .operands = &.{
9891 .{ .kind = .IdRef, .quantifier = .required },10699 .{ .kind = .id_ref, .quantifier = .required },
9892 .{ .kind = .IdRef, .quantifier = .required },10700 .{ .kind = .id_ref, .quantifier = .required },
10701 },
10702 },
10703 .{
10704 .name = "OpRayQueryGetClusterIdNV",
10705 .opcode = 5345,
10706 .operands = &.{
10707 .{ .kind = .id_result_type, .quantifier = .required },
10708 .{ .kind = .id_result, .quantifier = .required },
10709 .{ .kind = .id_ref, .quantifier = .required },
10710 .{ .kind = .id_ref, .quantifier = .required },
10711 },
10712 },
10713 .{
10714 .name = "OpHitObjectGetClusterIdNV",
10715 .opcode = 5346,
10716 .operands = &.{
10717 .{ .kind = .id_result_type, .quantifier = .required },
10718 .{ .kind = .id_result, .quantifier = .required },
10719 .{ .kind = .id_ref, .quantifier = .required },
9893 },10720 },
9894 },10721 },
9895 .{10722 .{
9896 .name = "OpTypeCooperativeMatrixNV",10723 .name = "OpTypeCooperativeMatrixNV",
9897 .opcode = 5358,10724 .opcode = 5358,
9898 .operands = &[_]Operand{10725 .operands = &.{
9899 .{ .kind = .IdResult, .quantifier = .required },10726 .{ .kind = .id_result, .quantifier = .required },
9900 .{ .kind = .IdRef, .quantifier = .required },10727 .{ .kind = .id_ref, .quantifier = .required },
9901 .{ .kind = .IdScope, .quantifier = .required },10728 .{ .kind = .id_scope, .quantifier = .required },
9902 .{ .kind = .IdRef, .quantifier = .required },10729 .{ .kind = .id_ref, .quantifier = .required },
9903 .{ .kind = .IdRef, .quantifier = .required },10730 .{ .kind = .id_ref, .quantifier = .required },
9904 },10731 },
9905 },10732 },
9906 .{10733 .{
9907 .name = "OpCooperativeMatrixLoadNV",10734 .name = "OpCooperativeMatrixLoadNV",
9908 .opcode = 5359,10735 .opcode = 5359,
9909 .operands = &[_]Operand{10736 .operands = &.{
9910 .{ .kind = .IdResultType, .quantifier = .required },10737 .{ .kind = .id_result_type, .quantifier = .required },
9911 .{ .kind = .IdResult, .quantifier = .required },10738 .{ .kind = .id_result, .quantifier = .required },
9912 .{ .kind = .IdRef, .quantifier = .required },10739 .{ .kind = .id_ref, .quantifier = .required },
9913 .{ .kind = .IdRef, .quantifier = .required },10740 .{ .kind = .id_ref, .quantifier = .required },
9914 .{ .kind = .IdRef, .quantifier = .required },10741 .{ .kind = .id_ref, .quantifier = .required },
9915 .{ .kind = .MemoryAccess, .quantifier = .optional },10742 .{ .kind = .memory_access, .quantifier = .optional },
9916 },10743 },
9917 },10744 },
9918 .{10745 .{
9919 .name = "OpCooperativeMatrixStoreNV",10746 .name = "OpCooperativeMatrixStoreNV",
9920 .opcode = 5360,10747 .opcode = 5360,
9921 .operands = &[_]Operand{10748 .operands = &.{
9922 .{ .kind = .IdRef, .quantifier = .required },10749 .{ .kind = .id_ref, .quantifier = .required },
9923 .{ .kind = .IdRef, .quantifier = .required },10750 .{ .kind = .id_ref, .quantifier = .required },
9924 .{ .kind = .IdRef, .quantifier = .required },10751 .{ .kind = .id_ref, .quantifier = .required },
9925 .{ .kind = .IdRef, .quantifier = .required },10752 .{ .kind = .id_ref, .quantifier = .required },
9926 .{ .kind = .MemoryAccess, .quantifier = .optional },10753 .{ .kind = .memory_access, .quantifier = .optional },
9927 },10754 },
9928 },10755 },
9929 .{10756 .{
9930 .name = "OpCooperativeMatrixMulAddNV",10757 .name = "OpCooperativeMatrixMulAddNV",
9931 .opcode = 5361,10758 .opcode = 5361,
9932 .operands = &[_]Operand{10759 .operands = &.{
9933 .{ .kind = .IdResultType, .quantifier = .required },10760 .{ .kind = .id_result_type, .quantifier = .required },
9934 .{ .kind = .IdResult, .quantifier = .required },10761 .{ .kind = .id_result, .quantifier = .required },
9935 .{ .kind = .IdRef, .quantifier = .required },10762 .{ .kind = .id_ref, .quantifier = .required },
9936 .{ .kind = .IdRef, .quantifier = .required },10763 .{ .kind = .id_ref, .quantifier = .required },
9937 .{ .kind = .IdRef, .quantifier = .required },10764 .{ .kind = .id_ref, .quantifier = .required },
9938 },10765 },
9939 },10766 },
9940 .{10767 .{
9941 .name = "OpCooperativeMatrixLengthNV",10768 .name = "OpCooperativeMatrixLengthNV",
9942 .opcode = 5362,10769 .opcode = 5362,
9943 .operands = &[_]Operand{10770 .operands = &.{
9944 .{ .kind = .IdResultType, .quantifier = .required },10771 .{ .kind = .id_result_type, .quantifier = .required },
9945 .{ .kind = .IdResult, .quantifier = .required },10772 .{ .kind = .id_result, .quantifier = .required },
9946 .{ .kind = .IdRef, .quantifier = .required },10773 .{ .kind = .id_ref, .quantifier = .required },
9947 },10774 },
9948 },10775 },
9949 .{10776 .{
9950 .name = "OpBeginInvocationInterlockEXT",10777 .name = "OpBeginInvocationInterlockEXT",
9951 .opcode = 5364,10778 .opcode = 5364,
9952 .operands = &[_]Operand{},10779 .operands = &.{},
9953 },10780 },
9954 .{10781 .{
9955 .name = "OpEndInvocationInterlockEXT",10782 .name = "OpEndInvocationInterlockEXT",
9956 .opcode = 5365,10783 .opcode = 5365,
9957 .operands = &[_]Operand{},10784 .operands = &.{},
9958 },10785 },
9959 .{10786 .{
9960 .name = "OpDemoteToHelperInvocation",10787 .name = "OpCooperativeMatrixReduceNV",
9961 .opcode = 5380,10788 .opcode = 5366,
9962 .operands = &[_]Operand{},10789 .operands = &.{
10790 .{ .kind = .id_result_type, .quantifier = .required },
10791 .{ .kind = .id_result, .quantifier = .required },
10792 .{ .kind = .id_ref, .quantifier = .required },
10793 .{ .kind = .cooperative_matrix_reduce, .quantifier = .required },
10794 .{ .kind = .id_ref, .quantifier = .required },
10795 },
9963 },10796 },
9964 .{10797 .{
9965 .name = "OpDemoteToHelperInvocationEXT",10798 .name = "OpCooperativeMatrixLoadTensorNV",
10799 .opcode = 5367,
10800 .operands = &.{
10801 .{ .kind = .id_result_type, .quantifier = .required },
10802 .{ .kind = .id_result, .quantifier = .required },
10803 .{ .kind = .id_ref, .quantifier = .required },
10804 .{ .kind = .id_ref, .quantifier = .required },
10805 .{ .kind = .id_ref, .quantifier = .required },
10806 .{ .kind = .memory_access, .quantifier = .required },
10807 .{ .kind = .tensor_addressing_operands, .quantifier = .required },
10808 },
10809 },
10810 .{
10811 .name = "OpCooperativeMatrixStoreTensorNV",
10812 .opcode = 5368,
10813 .operands = &.{
10814 .{ .kind = .id_ref, .quantifier = .required },
10815 .{ .kind = .id_ref, .quantifier = .required },
10816 .{ .kind = .id_ref, .quantifier = .required },
10817 .{ .kind = .memory_access, .quantifier = .required },
10818 .{ .kind = .tensor_addressing_operands, .quantifier = .required },
10819 },
10820 },
10821 .{
10822 .name = "OpCooperativeMatrixPerElementOpNV",
10823 .opcode = 5369,
10824 .operands = &.{
10825 .{ .kind = .id_result_type, .quantifier = .required },
10826 .{ .kind = .id_result, .quantifier = .required },
10827 .{ .kind = .id_ref, .quantifier = .required },
10828 .{ .kind = .id_ref, .quantifier = .required },
10829 .{ .kind = .id_ref, .quantifier = .variadic },
10830 },
10831 },
10832 .{
10833 .name = "OpTypeTensorLayoutNV",
10834 .opcode = 5370,
10835 .operands = &.{
10836 .{ .kind = .id_result, .quantifier = .required },
10837 .{ .kind = .id_ref, .quantifier = .required },
10838 .{ .kind = .id_ref, .quantifier = .required },
10839 },
10840 },
10841 .{
10842 .name = "OpTypeTensorViewNV",
10843 .opcode = 5371,
10844 .operands = &.{
10845 .{ .kind = .id_result, .quantifier = .required },
10846 .{ .kind = .id_ref, .quantifier = .required },
10847 .{ .kind = .id_ref, .quantifier = .required },
10848 .{ .kind = .id_ref, .quantifier = .variadic },
10849 },
10850 },
10851 .{
10852 .name = "OpCreateTensorLayoutNV",
10853 .opcode = 5372,
10854 .operands = &.{
10855 .{ .kind = .id_result_type, .quantifier = .required },
10856 .{ .kind = .id_result, .quantifier = .required },
10857 },
10858 },
10859 .{
10860 .name = "OpTensorLayoutSetDimensionNV",
10861 .opcode = 5373,
10862 .operands = &.{
10863 .{ .kind = .id_result_type, .quantifier = .required },
10864 .{ .kind = .id_result, .quantifier = .required },
10865 .{ .kind = .id_ref, .quantifier = .required },
10866 .{ .kind = .id_ref, .quantifier = .variadic },
10867 },
10868 },
10869 .{
10870 .name = "OpTensorLayoutSetStrideNV",
10871 .opcode = 5374,
10872 .operands = &.{
10873 .{ .kind = .id_result_type, .quantifier = .required },
10874 .{ .kind = .id_result, .quantifier = .required },
10875 .{ .kind = .id_ref, .quantifier = .required },
10876 .{ .kind = .id_ref, .quantifier = .variadic },
10877 },
10878 },
10879 .{
10880 .name = "OpTensorLayoutSliceNV",
10881 .opcode = 5375,
10882 .operands = &.{
10883 .{ .kind = .id_result_type, .quantifier = .required },
10884 .{ .kind = .id_result, .quantifier = .required },
10885 .{ .kind = .id_ref, .quantifier = .required },
10886 .{ .kind = .id_ref, .quantifier = .variadic },
10887 },
10888 },
10889 .{
10890 .name = "OpTensorLayoutSetClampValueNV",
10891 .opcode = 5376,
10892 .operands = &.{
10893 .{ .kind = .id_result_type, .quantifier = .required },
10894 .{ .kind = .id_result, .quantifier = .required },
10895 .{ .kind = .id_ref, .quantifier = .required },
10896 .{ .kind = .id_ref, .quantifier = .required },
10897 },
10898 },
10899 .{
10900 .name = "OpCreateTensorViewNV",
10901 .opcode = 5377,
10902 .operands = &.{
10903 .{ .kind = .id_result_type, .quantifier = .required },
10904 .{ .kind = .id_result, .quantifier = .required },
10905 },
10906 },
10907 .{
10908 .name = "OpTensorViewSetDimensionNV",
10909 .opcode = 5378,
10910 .operands = &.{
10911 .{ .kind = .id_result_type, .quantifier = .required },
10912 .{ .kind = .id_result, .quantifier = .required },
10913 .{ .kind = .id_ref, .quantifier = .required },
10914 .{ .kind = .id_ref, .quantifier = .variadic },
10915 },
10916 },
10917 .{
10918 .name = "OpTensorViewSetStrideNV",
10919 .opcode = 5379,
10920 .operands = &.{
10921 .{ .kind = .id_result_type, .quantifier = .required },
10922 .{ .kind = .id_result, .quantifier = .required },
10923 .{ .kind = .id_ref, .quantifier = .required },
10924 .{ .kind = .id_ref, .quantifier = .variadic },
10925 },
10926 },
10927 .{
10928 .name = "OpDemoteToHelperInvocation",
9966 .opcode = 5380,10929 .opcode = 5380,
9967 .operands = &[_]Operand{},10930 .operands = &.{},
9968 },10931 },
9969 .{10932 .{
9970 .name = "OpIsHelperInvocationEXT",10933 .name = "OpIsHelperInvocationEXT",
9971 .opcode = 5381,10934 .opcode = 5381,
9972 .operands = &[_]Operand{10935 .operands = &.{
9973 .{ .kind = .IdResultType, .quantifier = .required },10936 .{ .kind = .id_result_type, .quantifier = .required },
9974 .{ .kind = .IdResult, .quantifier = .required },10937 .{ .kind = .id_result, .quantifier = .required },
10938 },
10939 },
10940 .{
10941 .name = "OpTensorViewSetClipNV",
10942 .opcode = 5382,
10943 .operands = &.{
10944 .{ .kind = .id_result_type, .quantifier = .required },
10945 .{ .kind = .id_result, .quantifier = .required },
10946 .{ .kind = .id_ref, .quantifier = .required },
10947 .{ .kind = .id_ref, .quantifier = .required },
10948 .{ .kind = .id_ref, .quantifier = .required },
10949 .{ .kind = .id_ref, .quantifier = .required },
10950 .{ .kind = .id_ref, .quantifier = .required },
10951 },
10952 },
10953 .{
10954 .name = "OpTensorLayoutSetBlockSizeNV",
10955 .opcode = 5384,
10956 .operands = &.{
10957 .{ .kind = .id_result_type, .quantifier = .required },
10958 .{ .kind = .id_result, .quantifier = .required },
10959 .{ .kind = .id_ref, .quantifier = .required },
10960 .{ .kind = .id_ref, .quantifier = .variadic },
10961 },
10962 },
10963 .{
10964 .name = "OpCooperativeMatrixTransposeNV",
10965 .opcode = 5390,
10966 .operands = &.{
10967 .{ .kind = .id_result_type, .quantifier = .required },
10968 .{ .kind = .id_result, .quantifier = .required },
10969 .{ .kind = .id_ref, .quantifier = .required },
9975 },10970 },
9976 },10971 },
9977 .{10972 .{
9978 .name = "OpConvertUToImageNV",10973 .name = "OpConvertUToImageNV",
9979 .opcode = 5391,10974 .opcode = 5391,
9980 .operands = &[_]Operand{10975 .operands = &.{
9981 .{ .kind = .IdResultType, .quantifier = .required },10976 .{ .kind = .id_result_type, .quantifier = .required },
9982 .{ .kind = .IdResult, .quantifier = .required },10977 .{ .kind = .id_result, .quantifier = .required },
9983 .{ .kind = .IdRef, .quantifier = .required },10978 .{ .kind = .id_ref, .quantifier = .required },
9984 },10979 },
9985 },10980 },
9986 .{10981 .{
9987 .name = "OpConvertUToSamplerNV",10982 .name = "OpConvertUToSamplerNV",
9988 .opcode = 5392,10983 .opcode = 5392,
9989 .operands = &[_]Operand{10984 .operands = &.{
9990 .{ .kind = .IdResultType, .quantifier = .required },10985 .{ .kind = .id_result_type, .quantifier = .required },
9991 .{ .kind = .IdResult, .quantifier = .required },10986 .{ .kind = .id_result, .quantifier = .required },
9992 .{ .kind = .IdRef, .quantifier = .required },10987 .{ .kind = .id_ref, .quantifier = .required },
9993 },10988 },
9994 },10989 },
9995 .{10990 .{
9996 .name = "OpConvertImageToUNV",10991 .name = "OpConvertImageToUNV",
9997 .opcode = 5393,10992 .opcode = 5393,
9998 .operands = &[_]Operand{10993 .operands = &.{
9999 .{ .kind = .IdResultType, .quantifier = .required },10994 .{ .kind = .id_result_type, .quantifier = .required },
10000 .{ .kind = .IdResult, .quantifier = .required },10995 .{ .kind = .id_result, .quantifier = .required },
10001 .{ .kind = .IdRef, .quantifier = .required },10996 .{ .kind = .id_ref, .quantifier = .required },
10002 },10997 },
10003 },10998 },
10004 .{10999 .{
10005 .name = "OpConvertSamplerToUNV",11000 .name = "OpConvertSamplerToUNV",
10006 .opcode = 5394,11001 .opcode = 5394,
10007 .operands = &[_]Operand{11002 .operands = &.{
10008 .{ .kind = .IdResultType, .quantifier = .required },11003 .{ .kind = .id_result_type, .quantifier = .required },
10009 .{ .kind = .IdResult, .quantifier = .required },11004 .{ .kind = .id_result, .quantifier = .required },
10010 .{ .kind = .IdRef, .quantifier = .required },11005 .{ .kind = .id_ref, .quantifier = .required },
10011 },11006 },
10012 },11007 },
10013 .{11008 .{
10014 .name = "OpConvertUToSampledImageNV",11009 .name = "OpConvertUToSampledImageNV",
10015 .opcode = 5395,11010 .opcode = 5395,
10016 .operands = &[_]Operand{11011 .operands = &.{
10017 .{ .kind = .IdResultType, .quantifier = .required },11012 .{ .kind = .id_result_type, .quantifier = .required },
10018 .{ .kind = .IdResult, .quantifier = .required },11013 .{ .kind = .id_result, .quantifier = .required },
10019 .{ .kind = .IdRef, .quantifier = .required },11014 .{ .kind = .id_ref, .quantifier = .required },
10020 },11015 },
10021 },11016 },
10022 .{11017 .{
10023 .name = "OpConvertSampledImageToUNV",11018 .name = "OpConvertSampledImageToUNV",
10024 .opcode = 5396,11019 .opcode = 5396,
10025 .operands = &[_]Operand{11020 .operands = &.{
10026 .{ .kind = .IdResultType, .quantifier = .required },11021 .{ .kind = .id_result_type, .quantifier = .required },
10027 .{ .kind = .IdResult, .quantifier = .required },11022 .{ .kind = .id_result, .quantifier = .required },
10028 .{ .kind = .IdRef, .quantifier = .required },11023 .{ .kind = .id_ref, .quantifier = .required },
10029 },11024 },
10030 },11025 },
10031 .{11026 .{
10032 .name = "OpSamplerImageAddressingModeNV",11027 .name = "OpSamplerImageAddressingModeNV",
10033 .opcode = 5397,11028 .opcode = 5397,
10034 .operands = &[_]Operand{11029 .operands = &.{
10035 .{ .kind = .LiteralInteger, .quantifier = .required },11030 .{ .kind = .literal_integer, .quantifier = .required },
10036 },11031 },
10037 },11032 },
10038 .{11033 .{
10039 .name = "OpRawAccessChainNV",11034 .name = "OpRawAccessChainNV",
10040 .opcode = 5398,11035 .opcode = 5398,
10041 .operands = &[_]Operand{11036 .operands = &.{
10042 .{ .kind = .IdResultType, .quantifier = .required },11037 .{ .kind = .id_result_type, .quantifier = .required },
10043 .{ .kind = .IdResult, .quantifier = .required },11038 .{ .kind = .id_result, .quantifier = .required },
10044 .{ .kind = .IdRef, .quantifier = .required },11039 .{ .kind = .id_ref, .quantifier = .required },
10045 .{ .kind = .IdRef, .quantifier = .required },11040 .{ .kind = .id_ref, .quantifier = .required },
10046 .{ .kind = .IdRef, .quantifier = .required },11041 .{ .kind = .id_ref, .quantifier = .required },
10047 .{ .kind = .IdRef, .quantifier = .required },11042 .{ .kind = .id_ref, .quantifier = .required },
10048 .{ .kind = .RawAccessChainOperands, .quantifier = .optional },11043 .{ .kind = .raw_access_chain_operands, .quantifier = .optional },
11044 },
11045 },
11046 .{
11047 .name = "OpRayQueryGetIntersectionSpherePositionNV",
11048 .opcode = 5427,
11049 .operands = &.{
11050 .{ .kind = .id_result_type, .quantifier = .required },
11051 .{ .kind = .id_result, .quantifier = .required },
11052 .{ .kind = .id_ref, .quantifier = .required },
11053 .{ .kind = .id_ref, .quantifier = .required },
11054 },
11055 },
11056 .{
11057 .name = "OpRayQueryGetIntersectionSphereRadiusNV",
11058 .opcode = 5428,
11059 .operands = &.{
11060 .{ .kind = .id_result_type, .quantifier = .required },
11061 .{ .kind = .id_result, .quantifier = .required },
11062 .{ .kind = .id_ref, .quantifier = .required },
11063 .{ .kind = .id_ref, .quantifier = .required },
11064 },
11065 },
11066 .{
11067 .name = "OpRayQueryGetIntersectionLSSPositionsNV",
11068 .opcode = 5429,
11069 .operands = &.{
11070 .{ .kind = .id_result_type, .quantifier = .required },
11071 .{ .kind = .id_result, .quantifier = .required },
11072 .{ .kind = .id_ref, .quantifier = .required },
11073 .{ .kind = .id_ref, .quantifier = .required },
11074 },
11075 },
11076 .{
11077 .name = "OpRayQueryGetIntersectionLSSRadiiNV",
11078 .opcode = 5430,
11079 .operands = &.{
11080 .{ .kind = .id_result_type, .quantifier = .required },
11081 .{ .kind = .id_result, .quantifier = .required },
11082 .{ .kind = .id_ref, .quantifier = .required },
11083 .{ .kind = .id_ref, .quantifier = .required },
11084 },
11085 },
11086 .{
11087 .name = "OpRayQueryGetIntersectionLSSHitValueNV",
11088 .opcode = 5431,
11089 .operands = &.{
11090 .{ .kind = .id_result_type, .quantifier = .required },
11091 .{ .kind = .id_result, .quantifier = .required },
11092 .{ .kind = .id_ref, .quantifier = .required },
11093 .{ .kind = .id_ref, .quantifier = .required },
11094 },
11095 },
11096 .{
11097 .name = "OpHitObjectGetSpherePositionNV",
11098 .opcode = 5432,
11099 .operands = &.{
11100 .{ .kind = .id_result_type, .quantifier = .required },
11101 .{ .kind = .id_result, .quantifier = .required },
11102 .{ .kind = .id_ref, .quantifier = .required },
11103 },
11104 },
11105 .{
11106 .name = "OpHitObjectGetSphereRadiusNV",
11107 .opcode = 5433,
11108 .operands = &.{
11109 .{ .kind = .id_result_type, .quantifier = .required },
11110 .{ .kind = .id_result, .quantifier = .required },
11111 .{ .kind = .id_ref, .quantifier = .required },
11112 },
11113 },
11114 .{
11115 .name = "OpHitObjectGetLSSPositionsNV",
11116 .opcode = 5434,
11117 .operands = &.{
11118 .{ .kind = .id_result_type, .quantifier = .required },
11119 .{ .kind = .id_result, .quantifier = .required },
11120 .{ .kind = .id_ref, .quantifier = .required },
11121 },
11122 },
11123 .{
11124 .name = "OpHitObjectGetLSSRadiiNV",
11125 .opcode = 5435,
11126 .operands = &.{
11127 .{ .kind = .id_result_type, .quantifier = .required },
11128 .{ .kind = .id_result, .quantifier = .required },
11129 .{ .kind = .id_ref, .quantifier = .required },
11130 },
11131 },
11132 .{
11133 .name = "OpHitObjectIsSphereHitNV",
11134 .opcode = 5436,
11135 .operands = &.{
11136 .{ .kind = .id_result_type, .quantifier = .required },
11137 .{ .kind = .id_result, .quantifier = .required },
11138 .{ .kind = .id_ref, .quantifier = .required },
11139 },
11140 },
11141 .{
11142 .name = "OpHitObjectIsLSSHitNV",
11143 .opcode = 5437,
11144 .operands = &.{
11145 .{ .kind = .id_result_type, .quantifier = .required },
11146 .{ .kind = .id_result, .quantifier = .required },
11147 .{ .kind = .id_ref, .quantifier = .required },
11148 },
11149 },
11150 .{
11151 .name = "OpRayQueryIsSphereHitNV",
11152 .opcode = 5438,
11153 .operands = &.{
11154 .{ .kind = .id_result_type, .quantifier = .required },
11155 .{ .kind = .id_result, .quantifier = .required },
11156 .{ .kind = .id_ref, .quantifier = .required },
11157 .{ .kind = .id_ref, .quantifier = .required },
11158 },
11159 },
11160 .{
11161 .name = "OpRayQueryIsLSSHitNV",
11162 .opcode = 5439,
11163 .operands = &.{
11164 .{ .kind = .id_result_type, .quantifier = .required },
11165 .{ .kind = .id_result, .quantifier = .required },
11166 .{ .kind = .id_ref, .quantifier = .required },
11167 .{ .kind = .id_ref, .quantifier = .required },
10049 },11168 },
10050 },11169 },
10051 .{11170 .{
10052 .name = "OpSubgroupShuffleINTEL",11171 .name = "OpSubgroupShuffleINTEL",
10053 .opcode = 5571,11172 .opcode = 5571,
10054 .operands = &[_]Operand{11173 .operands = &.{
10055 .{ .kind = .IdResultType, .quantifier = .required },11174 .{ .kind = .id_result_type, .quantifier = .required },
10056 .{ .kind = .IdResult, .quantifier = .required },11175 .{ .kind = .id_result, .quantifier = .required },
10057 .{ .kind = .IdRef, .quantifier = .required },11176 .{ .kind = .id_ref, .quantifier = .required },
10058 .{ .kind = .IdRef, .quantifier = .required },11177 .{ .kind = .id_ref, .quantifier = .required },
10059 },11178 },
10060 },11179 },
10061 .{11180 .{
10062 .name = "OpSubgroupShuffleDownINTEL",11181 .name = "OpSubgroupShuffleDownINTEL",
10063 .opcode = 5572,11182 .opcode = 5572,
10064 .operands = &[_]Operand{11183 .operands = &.{
10065 .{ .kind = .IdResultType, .quantifier = .required },11184 .{ .kind = .id_result_type, .quantifier = .required },
10066 .{ .kind = .IdResult, .quantifier = .required },11185 .{ .kind = .id_result, .quantifier = .required },
10067 .{ .kind = .IdRef, .quantifier = .required },11186 .{ .kind = .id_ref, .quantifier = .required },
10068 .{ .kind = .IdRef, .quantifier = .required },11187 .{ .kind = .id_ref, .quantifier = .required },
10069 .{ .kind = .IdRef, .quantifier = .required },11188 .{ .kind = .id_ref, .quantifier = .required },
10070 },11189 },
10071 },11190 },
10072 .{11191 .{
10073 .name = "OpSubgroupShuffleUpINTEL",11192 .name = "OpSubgroupShuffleUpINTEL",
10074 .opcode = 5573,11193 .opcode = 5573,
10075 .operands = &[_]Operand{11194 .operands = &.{
10076 .{ .kind = .IdResultType, .quantifier = .required },11195 .{ .kind = .id_result_type, .quantifier = .required },
10077 .{ .kind = .IdResult, .quantifier = .required },11196 .{ .kind = .id_result, .quantifier = .required },
10078 .{ .kind = .IdRef, .quantifier = .required },11197 .{ .kind = .id_ref, .quantifier = .required },
10079 .{ .kind = .IdRef, .quantifier = .required },11198 .{ .kind = .id_ref, .quantifier = .required },
10080 .{ .kind = .IdRef, .quantifier = .required },11199 .{ .kind = .id_ref, .quantifier = .required },
10081 },11200 },
10082 },11201 },
10083 .{11202 .{
10084 .name = "OpSubgroupShuffleXorINTEL",11203 .name = "OpSubgroupShuffleXorINTEL",
10085 .opcode = 5574,11204 .opcode = 5574,
10086 .operands = &[_]Operand{11205 .operands = &.{
10087 .{ .kind = .IdResultType, .quantifier = .required },11206 .{ .kind = .id_result_type, .quantifier = .required },
10088 .{ .kind = .IdResult, .quantifier = .required },11207 .{ .kind = .id_result, .quantifier = .required },
10089 .{ .kind = .IdRef, .quantifier = .required },11208 .{ .kind = .id_ref, .quantifier = .required },
10090 .{ .kind = .IdRef, .quantifier = .required },11209 .{ .kind = .id_ref, .quantifier = .required },
10091 },11210 },
10092 },11211 },
10093 .{11212 .{
10094 .name = "OpSubgroupBlockReadINTEL",11213 .name = "OpSubgroupBlockReadINTEL",
10095 .opcode = 5575,11214 .opcode = 5575,
10096 .operands = &[_]Operand{11215 .operands = &.{
10097 .{ .kind = .IdResultType, .quantifier = .required },11216 .{ .kind = .id_result_type, .quantifier = .required },
10098 .{ .kind = .IdResult, .quantifier = .required },11217 .{ .kind = .id_result, .quantifier = .required },
10099 .{ .kind = .IdRef, .quantifier = .required },11218 .{ .kind = .id_ref, .quantifier = .required },
10100 },11219 },
10101 },11220 },
10102 .{11221 .{
10103 .name = "OpSubgroupBlockWriteINTEL",11222 .name = "OpSubgroupBlockWriteINTEL",
10104 .opcode = 5576,11223 .opcode = 5576,
10105 .operands = &[_]Operand{11224 .operands = &.{
10106 .{ .kind = .IdRef, .quantifier = .required },11225 .{ .kind = .id_ref, .quantifier = .required },
10107 .{ .kind = .IdRef, .quantifier = .required },11226 .{ .kind = .id_ref, .quantifier = .required },
10108 },11227 },
10109 },11228 },
10110 .{11229 .{
10111 .name = "OpSubgroupImageBlockReadINTEL",11230 .name = "OpSubgroupImageBlockReadINTEL",
10112 .opcode = 5577,11231 .opcode = 5577,
10113 .operands = &[_]Operand{11232 .operands = &.{
10114 .{ .kind = .IdResultType, .quantifier = .required },11233 .{ .kind = .id_result_type, .quantifier = .required },
10115 .{ .kind = .IdResult, .quantifier = .required },11234 .{ .kind = .id_result, .quantifier = .required },
10116 .{ .kind = .IdRef, .quantifier = .required },11235 .{ .kind = .id_ref, .quantifier = .required },
10117 .{ .kind = .IdRef, .quantifier = .required },11236 .{ .kind = .id_ref, .quantifier = .required },
10118 },11237 },
10119 },11238 },
10120 .{11239 .{
10121 .name = "OpSubgroupImageBlockWriteINTEL",11240 .name = "OpSubgroupImageBlockWriteINTEL",
10122 .opcode = 5578,11241 .opcode = 5578,
10123 .operands = &[_]Operand{11242 .operands = &.{
10124 .{ .kind = .IdRef, .quantifier = .required },11243 .{ .kind = .id_ref, .quantifier = .required },
10125 .{ .kind = .IdRef, .quantifier = .required },11244 .{ .kind = .id_ref, .quantifier = .required },
10126 .{ .kind = .IdRef, .quantifier = .required },11245 .{ .kind = .id_ref, .quantifier = .required },
10127 },11246 },
10128 },11247 },
10129 .{11248 .{
10130 .name = "OpSubgroupImageMediaBlockReadINTEL",11249 .name = "OpSubgroupImageMediaBlockReadINTEL",
10131 .opcode = 5580,11250 .opcode = 5580,
10132 .operands = &[_]Operand{11251 .operands = &.{
10133 .{ .kind = .IdResultType, .quantifier = .required },11252 .{ .kind = .id_result_type, .quantifier = .required },
10134 .{ .kind = .IdResult, .quantifier = .required },11253 .{ .kind = .id_result, .quantifier = .required },
10135 .{ .kind = .IdRef, .quantifier = .required },11254 .{ .kind = .id_ref, .quantifier = .required },
10136 .{ .kind = .IdRef, .quantifier = .required },11255 .{ .kind = .id_ref, .quantifier = .required },
10137 .{ .kind = .IdRef, .quantifier = .required },11256 .{ .kind = .id_ref, .quantifier = .required },
10138 .{ .kind = .IdRef, .quantifier = .required },11257 .{ .kind = .id_ref, .quantifier = .required },
10139 },11258 },
10140 },11259 },
10141 .{11260 .{
10142 .name = "OpSubgroupImageMediaBlockWriteINTEL",11261 .name = "OpSubgroupImageMediaBlockWriteINTEL",
10143 .opcode = 5581,11262 .opcode = 5581,
10144 .operands = &[_]Operand{11263 .operands = &.{
10145 .{ .kind = .IdRef, .quantifier = .required },11264 .{ .kind = .id_ref, .quantifier = .required },
10146 .{ .kind = .IdRef, .quantifier = .required },11265 .{ .kind = .id_ref, .quantifier = .required },
10147 .{ .kind = .IdRef, .quantifier = .required },11266 .{ .kind = .id_ref, .quantifier = .required },
10148 .{ .kind = .IdRef, .quantifier = .required },11267 .{ .kind = .id_ref, .quantifier = .required },
10149 .{ .kind = .IdRef, .quantifier = .required },11268 .{ .kind = .id_ref, .quantifier = .required },
10150 },11269 },
10151 },11270 },
10152 .{11271 .{
10153 .name = "OpUCountLeadingZerosINTEL",11272 .name = "OpUCountLeadingZerosINTEL",
10154 .opcode = 5585,11273 .opcode = 5585,
10155 .operands = &[_]Operand{11274 .operands = &.{
10156 .{ .kind = .IdResultType, .quantifier = .required },11275 .{ .kind = .id_result_type, .quantifier = .required },
10157 .{ .kind = .IdResult, .quantifier = .required },11276 .{ .kind = .id_result, .quantifier = .required },
10158 .{ .kind = .IdRef, .quantifier = .required },11277 .{ .kind = .id_ref, .quantifier = .required },
10159 },11278 },
10160 },11279 },
10161 .{11280 .{
10162 .name = "OpUCountTrailingZerosINTEL",11281 .name = "OpUCountTrailingZerosINTEL",
10163 .opcode = 5586,11282 .opcode = 5586,
10164 .operands = &[_]Operand{11283 .operands = &.{
10165 .{ .kind = .IdResultType, .quantifier = .required },11284 .{ .kind = .id_result_type, .quantifier = .required },
10166 .{ .kind = .IdResult, .quantifier = .required },11285 .{ .kind = .id_result, .quantifier = .required },
10167 .{ .kind = .IdRef, .quantifier = .required },11286 .{ .kind = .id_ref, .quantifier = .required },
10168 },11287 },
10169 },11288 },
10170 .{11289 .{
10171 .name = "OpAbsISubINTEL",11290 .name = "OpAbsISubINTEL",
10172 .opcode = 5587,11291 .opcode = 5587,
10173 .operands = &[_]Operand{11292 .operands = &.{
10174 .{ .kind = .IdResultType, .quantifier = .required },11293 .{ .kind = .id_result_type, .quantifier = .required },
10175 .{ .kind = .IdResult, .quantifier = .required },11294 .{ .kind = .id_result, .quantifier = .required },
10176 .{ .kind = .IdRef, .quantifier = .required },11295 .{ .kind = .id_ref, .quantifier = .required },
10177 .{ .kind = .IdRef, .quantifier = .required },11296 .{ .kind = .id_ref, .quantifier = .required },
10178 },11297 },
10179 },11298 },
10180 .{11299 .{
10181 .name = "OpAbsUSubINTEL",11300 .name = "OpAbsUSubINTEL",
10182 .opcode = 5588,11301 .opcode = 5588,
10183 .operands = &[_]Operand{11302 .operands = &.{
10184 .{ .kind = .IdResultType, .quantifier = .required },11303 .{ .kind = .id_result_type, .quantifier = .required },
10185 .{ .kind = .IdResult, .quantifier = .required },11304 .{ .kind = .id_result, .quantifier = .required },
10186 .{ .kind = .IdRef, .quantifier = .required },11305 .{ .kind = .id_ref, .quantifier = .required },
10187 .{ .kind = .IdRef, .quantifier = .required },11306 .{ .kind = .id_ref, .quantifier = .required },
10188 },11307 },
10189 },11308 },
10190 .{11309 .{
10191 .name = "OpIAddSatINTEL",11310 .name = "OpIAddSatINTEL",
10192 .opcode = 5589,11311 .opcode = 5589,
10193 .operands = &[_]Operand{11312 .operands = &.{
10194 .{ .kind = .IdResultType, .quantifier = .required },11313 .{ .kind = .id_result_type, .quantifier = .required },
10195 .{ .kind = .IdResult, .quantifier = .required },11314 .{ .kind = .id_result, .quantifier = .required },
10196 .{ .kind = .IdRef, .quantifier = .required },11315 .{ .kind = .id_ref, .quantifier = .required },
10197 .{ .kind = .IdRef, .quantifier = .required },11316 .{ .kind = .id_ref, .quantifier = .required },
10198 },11317 },
10199 },11318 },
10200 .{11319 .{
10201 .name = "OpUAddSatINTEL",11320 .name = "OpUAddSatINTEL",
10202 .opcode = 5590,11321 .opcode = 5590,
10203 .operands = &[_]Operand{11322 .operands = &.{
10204 .{ .kind = .IdResultType, .quantifier = .required },11323 .{ .kind = .id_result_type, .quantifier = .required },
10205 .{ .kind = .IdResult, .quantifier = .required },11324 .{ .kind = .id_result, .quantifier = .required },
10206 .{ .kind = .IdRef, .quantifier = .required },11325 .{ .kind = .id_ref, .quantifier = .required },
10207 .{ .kind = .IdRef, .quantifier = .required },11326 .{ .kind = .id_ref, .quantifier = .required },
10208 },11327 },
10209 },11328 },
10210 .{11329 .{
10211 .name = "OpIAverageINTEL",11330 .name = "OpIAverageINTEL",
10212 .opcode = 5591,11331 .opcode = 5591,
10213 .operands = &[_]Operand{11332 .operands = &.{
10214 .{ .kind = .IdResultType, .quantifier = .required },11333 .{ .kind = .id_result_type, .quantifier = .required },
10215 .{ .kind = .IdResult, .quantifier = .required },11334 .{ .kind = .id_result, .quantifier = .required },
10216 .{ .kind = .IdRef, .quantifier = .required },11335 .{ .kind = .id_ref, .quantifier = .required },
10217 .{ .kind = .IdRef, .quantifier = .required },11336 .{ .kind = .id_ref, .quantifier = .required },
10218 },11337 },
10219 },11338 },
10220 .{11339 .{
10221 .name = "OpUAverageINTEL",11340 .name = "OpUAverageINTEL",
10222 .opcode = 5592,11341 .opcode = 5592,
10223 .operands = &[_]Operand{11342 .operands = &.{
10224 .{ .kind = .IdResultType, .quantifier = .required },11343 .{ .kind = .id_result_type, .quantifier = .required },
10225 .{ .kind = .IdResult, .quantifier = .required },11344 .{ .kind = .id_result, .quantifier = .required },
10226 .{ .kind = .IdRef, .quantifier = .required },11345 .{ .kind = .id_ref, .quantifier = .required },
10227 .{ .kind = .IdRef, .quantifier = .required },11346 .{ .kind = .id_ref, .quantifier = .required },
10228 },11347 },
10229 },11348 },
10230 .{11349 .{
10231 .name = "OpIAverageRoundedINTEL",11350 .name = "OpIAverageRoundedINTEL",
10232 .opcode = 5593,11351 .opcode = 5593,
10233 .operands = &[_]Operand{11352 .operands = &.{
10234 .{ .kind = .IdResultType, .quantifier = .required },11353 .{ .kind = .id_result_type, .quantifier = .required },
10235 .{ .kind = .IdResult, .quantifier = .required },11354 .{ .kind = .id_result, .quantifier = .required },
10236 .{ .kind = .IdRef, .quantifier = .required },11355 .{ .kind = .id_ref, .quantifier = .required },
10237 .{ .kind = .IdRef, .quantifier = .required },11356 .{ .kind = .id_ref, .quantifier = .required },
10238 },11357 },
10239 },11358 },
10240 .{11359 .{
10241 .name = "OpUAverageRoundedINTEL",11360 .name = "OpUAverageRoundedINTEL",
10242 .opcode = 5594,11361 .opcode = 5594,
10243 .operands = &[_]Operand{11362 .operands = &.{
10244 .{ .kind = .IdResultType, .quantifier = .required },11363 .{ .kind = .id_result_type, .quantifier = .required },
10245 .{ .kind = .IdResult, .quantifier = .required },11364 .{ .kind = .id_result, .quantifier = .required },
10246 .{ .kind = .IdRef, .quantifier = .required },11365 .{ .kind = .id_ref, .quantifier = .required },
10247 .{ .kind = .IdRef, .quantifier = .required },11366 .{ .kind = .id_ref, .quantifier = .required },
10248 },11367 },
10249 },11368 },
10250 .{11369 .{
10251 .name = "OpISubSatINTEL",11370 .name = "OpISubSatINTEL",
10252 .opcode = 5595,11371 .opcode = 5595,
10253 .operands = &[_]Operand{11372 .operands = &.{
10254 .{ .kind = .IdResultType, .quantifier = .required },11373 .{ .kind = .id_result_type, .quantifier = .required },
10255 .{ .kind = .IdResult, .quantifier = .required },11374 .{ .kind = .id_result, .quantifier = .required },
10256 .{ .kind = .IdRef, .quantifier = .required },11375 .{ .kind = .id_ref, .quantifier = .required },
10257 .{ .kind = .IdRef, .quantifier = .required },11376 .{ .kind = .id_ref, .quantifier = .required },
10258 },11377 },
10259 },11378 },
10260 .{11379 .{
10261 .name = "OpUSubSatINTEL",11380 .name = "OpUSubSatINTEL",
10262 .opcode = 5596,11381 .opcode = 5596,
10263 .operands = &[_]Operand{11382 .operands = &.{
10264 .{ .kind = .IdResultType, .quantifier = .required },11383 .{ .kind = .id_result_type, .quantifier = .required },
10265 .{ .kind = .IdResult, .quantifier = .required },11384 .{ .kind = .id_result, .quantifier = .required },
10266 .{ .kind = .IdRef, .quantifier = .required },11385 .{ .kind = .id_ref, .quantifier = .required },
10267 .{ .kind = .IdRef, .quantifier = .required },11386 .{ .kind = .id_ref, .quantifier = .required },
10268 },11387 },
10269 },11388 },
10270 .{11389 .{
10271 .name = "OpIMul32x16INTEL",11390 .name = "OpIMul32x16INTEL",
10272 .opcode = 5597,11391 .opcode = 5597,
10273 .operands = &[_]Operand{11392 .operands = &.{
10274 .{ .kind = .IdResultType, .quantifier = .required },11393 .{ .kind = .id_result_type, .quantifier = .required },
10275 .{ .kind = .IdResult, .quantifier = .required },11394 .{ .kind = .id_result, .quantifier = .required },
10276 .{ .kind = .IdRef, .quantifier = .required },11395 .{ .kind = .id_ref, .quantifier = .required },
10277 .{ .kind = .IdRef, .quantifier = .required },11396 .{ .kind = .id_ref, .quantifier = .required },
10278 },11397 },
10279 },11398 },
10280 .{11399 .{
10281 .name = "OpUMul32x16INTEL",11400 .name = "OpUMul32x16INTEL",
10282 .opcode = 5598,11401 .opcode = 5598,
10283 .operands = &[_]Operand{11402 .operands = &.{
10284 .{ .kind = .IdResultType, .quantifier = .required },11403 .{ .kind = .id_result_type, .quantifier = .required },
10285 .{ .kind = .IdResult, .quantifier = .required },11404 .{ .kind = .id_result, .quantifier = .required },
10286 .{ .kind = .IdRef, .quantifier = .required },11405 .{ .kind = .id_ref, .quantifier = .required },
10287 .{ .kind = .IdRef, .quantifier = .required },11406 .{ .kind = .id_ref, .quantifier = .required },
10288 },11407 },
10289 },11408 },
10290 .{11409 .{
10291 .name = "OpConstantFunctionPointerINTEL",11410 .name = "OpConstantFunctionPointerINTEL",
10292 .opcode = 5600,11411 .opcode = 5600,
10293 .operands = &[_]Operand{11412 .operands = &.{
10294 .{ .kind = .IdResultType, .quantifier = .required },11413 .{ .kind = .id_result_type, .quantifier = .required },
10295 .{ .kind = .IdResult, .quantifier = .required },11414 .{ .kind = .id_result, .quantifier = .required },
10296 .{ .kind = .IdRef, .quantifier = .required },11415 .{ .kind = .id_ref, .quantifier = .required },
10297 },11416 },
10298 },11417 },
10299 .{11418 .{
10300 .name = "OpFunctionPointerCallINTEL",11419 .name = "OpFunctionPointerCallINTEL",
10301 .opcode = 5601,11420 .opcode = 5601,
10302 .operands = &[_]Operand{11421 .operands = &.{
10303 .{ .kind = .IdResultType, .quantifier = .required },11422 .{ .kind = .id_result_type, .quantifier = .required },
10304 .{ .kind = .IdResult, .quantifier = .required },11423 .{ .kind = .id_result, .quantifier = .required },
10305 .{ .kind = .IdRef, .quantifier = .variadic },11424 .{ .kind = .id_ref, .quantifier = .variadic },
10306 },11425 },
10307 },11426 },
10308 .{11427 .{
10309 .name = "OpAsmTargetINTEL",11428 .name = "OpAsmTargetINTEL",
10310 .opcode = 5609,11429 .opcode = 5609,
10311 .operands = &[_]Operand{11430 .operands = &.{
10312 .{ .kind = .IdResultType, .quantifier = .required },11431 .{ .kind = .id_result, .quantifier = .required },
10313 .{ .kind = .IdResult, .quantifier = .required },11432 .{ .kind = .literal_string, .quantifier = .required },
10314 .{ .kind = .LiteralString, .quantifier = .required },
10315 },11433 },
10316 },11434 },
10317 .{11435 .{
10318 .name = "OpAsmINTEL",11436 .name = "OpAsmINTEL",
10319 .opcode = 5610,11437 .opcode = 5610,
10320 .operands = &[_]Operand{11438 .operands = &.{
10321 .{ .kind = .IdResultType, .quantifier = .required },11439 .{ .kind = .id_result_type, .quantifier = .required },
10322 .{ .kind = .IdResult, .quantifier = .required },11440 .{ .kind = .id_result, .quantifier = .required },
10323 .{ .kind = .IdRef, .quantifier = .required },11441 .{ .kind = .id_ref, .quantifier = .required },
10324 .{ .kind = .IdRef, .quantifier = .required },11442 .{ .kind = .id_ref, .quantifier = .required },
10325 .{ .kind = .LiteralString, .quantifier = .required },11443 .{ .kind = .literal_string, .quantifier = .required },
10326 .{ .kind = .LiteralString, .quantifier = .required },11444 .{ .kind = .literal_string, .quantifier = .required },
10327 },11445 },
10328 },11446 },
10329 .{11447 .{
10330 .name = "OpAsmCallINTEL",11448 .name = "OpAsmCallINTEL",
10331 .opcode = 5611,11449 .opcode = 5611,
10332 .operands = &[_]Operand{11450 .operands = &.{
10333 .{ .kind = .IdResultType, .quantifier = .required },11451 .{ .kind = .id_result_type, .quantifier = .required },
10334 .{ .kind = .IdResult, .quantifier = .required },11452 .{ .kind = .id_result, .quantifier = .required },
10335 .{ .kind = .IdRef, .quantifier = .required },11453 .{ .kind = .id_ref, .quantifier = .required },
10336 .{ .kind = .IdRef, .quantifier = .variadic },11454 .{ .kind = .id_ref, .quantifier = .variadic },
10337 },11455 },
10338 },11456 },
10339 .{11457 .{
10340 .name = "OpAtomicFMinEXT",11458 .name = "OpAtomicFMinEXT",
10341 .opcode = 5614,11459 .opcode = 5614,
10342 .operands = &[_]Operand{11460 .operands = &.{
10343 .{ .kind = .IdResultType, .quantifier = .required },11461 .{ .kind = .id_result_type, .quantifier = .required },
10344 .{ .kind = .IdResult, .quantifier = .required },11462 .{ .kind = .id_result, .quantifier = .required },
10345 .{ .kind = .IdRef, .quantifier = .required },11463 .{ .kind = .id_ref, .quantifier = .required },
10346 .{ .kind = .IdScope, .quantifier = .required },11464 .{ .kind = .id_scope, .quantifier = .required },
10347 .{ .kind = .IdMemorySemantics, .quantifier = .required },11465 .{ .kind = .id_memory_semantics, .quantifier = .required },
10348 .{ .kind = .IdRef, .quantifier = .required },11466 .{ .kind = .id_ref, .quantifier = .required },
10349 },11467 },
10350 },11468 },
10351 .{11469 .{
10352 .name = "OpAtomicFMaxEXT",11470 .name = "OpAtomicFMaxEXT",
10353 .opcode = 5615,11471 .opcode = 5615,
10354 .operands = &[_]Operand{11472 .operands = &.{
10355 .{ .kind = .IdResultType, .quantifier = .required },11473 .{ .kind = .id_result_type, .quantifier = .required },
10356 .{ .kind = .IdResult, .quantifier = .required },11474 .{ .kind = .id_result, .quantifier = .required },
10357 .{ .kind = .IdRef, .quantifier = .required },11475 .{ .kind = .id_ref, .quantifier = .required },
10358 .{ .kind = .IdScope, .quantifier = .required },11476 .{ .kind = .id_scope, .quantifier = .required },
10359 .{ .kind = .IdMemorySemantics, .quantifier = .required },11477 .{ .kind = .id_memory_semantics, .quantifier = .required },
10360 .{ .kind = .IdRef, .quantifier = .required },11478 .{ .kind = .id_ref, .quantifier = .required },
10361 },11479 },
10362 },11480 },
10363 .{11481 .{
10364 .name = "OpAssumeTrueKHR",11482 .name = "OpAssumeTrueKHR",
10365 .opcode = 5630,11483 .opcode = 5630,
10366 .operands = &[_]Operand{11484 .operands = &.{
10367 .{ .kind = .IdRef, .quantifier = .required },11485 .{ .kind = .id_ref, .quantifier = .required },
10368 },11486 },
10369 },11487 },
10370 .{11488 .{
10371 .name = "OpExpectKHR",11489 .name = "OpExpectKHR",
10372 .opcode = 5631,11490 .opcode = 5631,
10373 .operands = &[_]Operand{11491 .operands = &.{
10374 .{ .kind = .IdResultType, .quantifier = .required },11492 .{ .kind = .id_result_type, .quantifier = .required },
10375 .{ .kind = .IdResult, .quantifier = .required },11493 .{ .kind = .id_result, .quantifier = .required },
10376 .{ .kind = .IdRef, .quantifier = .required },11494 .{ .kind = .id_ref, .quantifier = .required },
10377 .{ .kind = .IdRef, .quantifier = .required },11495 .{ .kind = .id_ref, .quantifier = .required },
10378 },11496 },
10379 },11497 },
10380 .{11498 .{
10381 .name = "OpDecorateString",11499 .name = "OpDecorateString",
10382 .opcode = 5632,11500 .opcode = 5632,
10383 .operands = &[_]Operand{11501 .operands = &.{
10384 .{ .kind = .IdRef, .quantifier = .required },11502 .{ .kind = .id_ref, .quantifier = .required },
10385 .{ .kind = .Decoration, .quantifier = .required },11503 .{ .kind = .decoration, .quantifier = .required },
10386 },
10387 },
10388 .{
10389 .name = "OpDecorateStringGOOGLE",
10390 .opcode = 5632,
10391 .operands = &[_]Operand{
10392 .{ .kind = .IdRef, .quantifier = .required },
10393 .{ .kind = .Decoration, .quantifier = .required },
10394 },11504 },
10395 },11505 },
10396 .{11506 .{
10397 .name = "OpMemberDecorateString",11507 .name = "OpMemberDecorateString",
10398 .opcode = 5633,11508 .opcode = 5633,
10399 .operands = &[_]Operand{11509 .operands = &.{
10400 .{ .kind = .IdRef, .quantifier = .required },11510 .{ .kind = .id_ref, .quantifier = .required },
10401 .{ .kind = .LiteralInteger, .quantifier = .required },11511 .{ .kind = .literal_integer, .quantifier = .required },
10402 .{ .kind = .Decoration, .quantifier = .required },11512 .{ .kind = .decoration, .quantifier = .required },
10403 },
10404 },
10405 .{
10406 .name = "OpMemberDecorateStringGOOGLE",
10407 .opcode = 5633,
10408 .operands = &[_]Operand{
10409 .{ .kind = .IdRef, .quantifier = .required },
10410 .{ .kind = .LiteralInteger, .quantifier = .required },
10411 .{ .kind = .Decoration, .quantifier = .required },
10412 },11513 },
10413 },11514 },
10414 .{11515 .{
10415 .name = "OpVmeImageINTEL",11516 .name = "OpVmeImageINTEL",
10416 .opcode = 5699,11517 .opcode = 5699,
10417 .operands = &[_]Operand{11518 .operands = &.{
10418 .{ .kind = .IdResultType, .quantifier = .required },11519 .{ .kind = .id_result_type, .quantifier = .required },
10419 .{ .kind = .IdResult, .quantifier = .required },11520 .{ .kind = .id_result, .quantifier = .required },
10420 .{ .kind = .IdRef, .quantifier = .required },11521 .{ .kind = .id_ref, .quantifier = .required },
10421 .{ .kind = .IdRef, .quantifier = .required },11522 .{ .kind = .id_ref, .quantifier = .required },
10422 },11523 },
10423 },11524 },
10424 .{11525 .{
10425 .name = "OpTypeVmeImageINTEL",11526 .name = "OpTypeVmeImageINTEL",
10426 .opcode = 5700,11527 .opcode = 5700,
10427 .operands = &[_]Operand{11528 .operands = &.{
10428 .{ .kind = .IdResult, .quantifier = .required },11529 .{ .kind = .id_result, .quantifier = .required },
10429 .{ .kind = .IdRef, .quantifier = .required },11530 .{ .kind = .id_ref, .quantifier = .required },
10430 },11531 },
10431 },11532 },
10432 .{11533 .{
10433 .name = "OpTypeAvcImePayloadINTEL",11534 .name = "OpTypeAvcImePayloadINTEL",
10434 .opcode = 5701,11535 .opcode = 5701,
10435 .operands = &[_]Operand{11536 .operands = &.{
10436 .{ .kind = .IdResult, .quantifier = .required },11537 .{ .kind = .id_result, .quantifier = .required },
10437 },11538 },
10438 },11539 },
10439 .{11540 .{
10440 .name = "OpTypeAvcRefPayloadINTEL",11541 .name = "OpTypeAvcRefPayloadINTEL",
10441 .opcode = 5702,11542 .opcode = 5702,
10442 .operands = &[_]Operand{11543 .operands = &.{
10443 .{ .kind = .IdResult, .quantifier = .required },11544 .{ .kind = .id_result, .quantifier = .required },
10444 },11545 },
10445 },11546 },
10446 .{11547 .{
10447 .name = "OpTypeAvcSicPayloadINTEL",11548 .name = "OpTypeAvcSicPayloadINTEL",
10448 .opcode = 5703,11549 .opcode = 5703,
10449 .operands = &[_]Operand{11550 .operands = &.{
10450 .{ .kind = .IdResult, .quantifier = .required },11551 .{ .kind = .id_result, .quantifier = .required },
10451 },11552 },
10452 },11553 },
10453 .{11554 .{
10454 .name = "OpTypeAvcMcePayloadINTEL",11555 .name = "OpTypeAvcMcePayloadINTEL",
10455 .opcode = 5704,11556 .opcode = 5704,
10456 .operands = &[_]Operand{11557 .operands = &.{
10457 .{ .kind = .IdResult, .quantifier = .required },11558 .{ .kind = .id_result, .quantifier = .required },
10458 },11559 },
10459 },11560 },
10460 .{11561 .{
10461 .name = "OpTypeAvcMceResultINTEL",11562 .name = "OpTypeAvcMceResultINTEL",
10462 .opcode = 5705,11563 .opcode = 5705,
10463 .operands = &[_]Operand{11564 .operands = &.{
10464 .{ .kind = .IdResult, .quantifier = .required },11565 .{ .kind = .id_result, .quantifier = .required },
10465 },11566 },
10466 },11567 },
10467 .{11568 .{
10468 .name = "OpTypeAvcImeResultINTEL",11569 .name = "OpTypeAvcImeResultINTEL",
10469 .opcode = 5706,11570 .opcode = 5706,
10470 .operands = &[_]Operand{11571 .operands = &.{
10471 .{ .kind = .IdResult, .quantifier = .required },11572 .{ .kind = .id_result, .quantifier = .required },
10472 },11573 },
10473 },11574 },
10474 .{11575 .{
10475 .name = "OpTypeAvcImeResultSingleReferenceStreamoutINTEL",11576 .name = "OpTypeAvcImeResultSingleReferenceStreamoutINTEL",
10476 .opcode = 5707,11577 .opcode = 5707,
10477 .operands = &[_]Operand{11578 .operands = &.{
10478 .{ .kind = .IdResult, .quantifier = .required },11579 .{ .kind = .id_result, .quantifier = .required },
10479 },11580 },
10480 },11581 },
10481 .{11582 .{
10482 .name = "OpTypeAvcImeResultDualReferenceStreamoutINTEL",11583 .name = "OpTypeAvcImeResultDualReferenceStreamoutINTEL",
10483 .opcode = 5708,11584 .opcode = 5708,
10484 .operands = &[_]Operand{11585 .operands = &.{
10485 .{ .kind = .IdResult, .quantifier = .required },11586 .{ .kind = .id_result, .quantifier = .required },
10486 },11587 },
10487 },11588 },
10488 .{11589 .{
10489 .name = "OpTypeAvcImeSingleReferenceStreaminINTEL",11590 .name = "OpTypeAvcImeSingleReferenceStreaminINTEL",
10490 .opcode = 5709,11591 .opcode = 5709,
10491 .operands = &[_]Operand{11592 .operands = &.{
10492 .{ .kind = .IdResult, .quantifier = .required },11593 .{ .kind = .id_result, .quantifier = .required },
10493 },11594 },
10494 },11595 },
10495 .{11596 .{
10496 .name = "OpTypeAvcImeDualReferenceStreaminINTEL",11597 .name = "OpTypeAvcImeDualReferenceStreaminINTEL",
10497 .opcode = 5710,11598 .opcode = 5710,
10498 .operands = &[_]Operand{11599 .operands = &.{
10499 .{ .kind = .IdResult, .quantifier = .required },11600 .{ .kind = .id_result, .quantifier = .required },
10500 },11601 },
10501 },11602 },
10502 .{11603 .{
10503 .name = "OpTypeAvcRefResultINTEL",11604 .name = "OpTypeAvcRefResultINTEL",
10504 .opcode = 5711,11605 .opcode = 5711,
10505 .operands = &[_]Operand{11606 .operands = &.{
10506 .{ .kind = .IdResult, .quantifier = .required },11607 .{ .kind = .id_result, .quantifier = .required },
10507 },11608 },
10508 },11609 },
10509 .{11610 .{
10510 .name = "OpTypeAvcSicResultINTEL",11611 .name = "OpTypeAvcSicResultINTEL",
10511 .opcode = 5712,11612 .opcode = 5712,
10512 .operands = &[_]Operand{11613 .operands = &.{
10513 .{ .kind = .IdResult, .quantifier = .required },11614 .{ .kind = .id_result, .quantifier = .required },
10514 },11615 },
10515 },11616 },
10516 .{11617 .{
10517 .name = "OpSubgroupAvcMceGetDefaultInterBaseMultiReferencePenaltyINTEL",11618 .name = "OpSubgroupAvcMceGetDefaultInterBaseMultiReferencePenaltyINTEL",
10518 .opcode = 5713,11619 .opcode = 5713,
10519 .operands = &[_]Operand{11620 .operands = &.{
10520 .{ .kind = .IdResultType, .quantifier = .required },11621 .{ .kind = .id_result_type, .quantifier = .required },
10521 .{ .kind = .IdResult, .quantifier = .required },11622 .{ .kind = .id_result, .quantifier = .required },
10522 .{ .kind = .IdRef, .quantifier = .required },11623 .{ .kind = .id_ref, .quantifier = .required },
10523 .{ .kind = .IdRef, .quantifier = .required },11624 .{ .kind = .id_ref, .quantifier = .required },
10524 },11625 },
10525 },11626 },
10526 .{11627 .{
10527 .name = "OpSubgroupAvcMceSetInterBaseMultiReferencePenaltyINTEL",11628 .name = "OpSubgroupAvcMceSetInterBaseMultiReferencePenaltyINTEL",
10528 .opcode = 5714,11629 .opcode = 5714,
10529 .operands = &[_]Operand{11630 .operands = &.{
10530 .{ .kind = .IdResultType, .quantifier = .required },11631 .{ .kind = .id_result_type, .quantifier = .required },
10531 .{ .kind = .IdResult, .quantifier = .required },11632 .{ .kind = .id_result, .quantifier = .required },
10532 .{ .kind = .IdRef, .quantifier = .required },11633 .{ .kind = .id_ref, .quantifier = .required },
10533 .{ .kind = .IdRef, .quantifier = .required },11634 .{ .kind = .id_ref, .quantifier = .required },
10534 },11635 },
10535 },11636 },
10536 .{11637 .{
10537 .name = "OpSubgroupAvcMceGetDefaultInterShapePenaltyINTEL",11638 .name = "OpSubgroupAvcMceGetDefaultInterShapePenaltyINTEL",
10538 .opcode = 5715,11639 .opcode = 5715,
10539 .operands = &[_]Operand{11640 .operands = &.{
10540 .{ .kind = .IdResultType, .quantifier = .required },11641 .{ .kind = .id_result_type, .quantifier = .required },
10541 .{ .kind = .IdResult, .quantifier = .required },11642 .{ .kind = .id_result, .quantifier = .required },
10542 .{ .kind = .IdRef, .quantifier = .required },11643 .{ .kind = .id_ref, .quantifier = .required },
10543 .{ .kind = .IdRef, .quantifier = .required },11644 .{ .kind = .id_ref, .quantifier = .required },
10544 },11645 },
10545 },11646 },
10546 .{11647 .{
10547 .name = "OpSubgroupAvcMceSetInterShapePenaltyINTEL",11648 .name = "OpSubgroupAvcMceSetInterShapePenaltyINTEL",
10548 .opcode = 5716,11649 .opcode = 5716,
10549 .operands = &[_]Operand{11650 .operands = &.{
10550 .{ .kind = .IdResultType, .quantifier = .required },11651 .{ .kind = .id_result_type, .quantifier = .required },
10551 .{ .kind = .IdResult, .quantifier = .required },11652 .{ .kind = .id_result, .quantifier = .required },
10552 .{ .kind = .IdRef, .quantifier = .required },11653 .{ .kind = .id_ref, .quantifier = .required },
10553 .{ .kind = .IdRef, .quantifier = .required },11654 .{ .kind = .id_ref, .quantifier = .required },
10554 },11655 },
10555 },11656 },
10556 .{11657 .{
10557 .name = "OpSubgroupAvcMceGetDefaultInterDirectionPenaltyINTEL",11658 .name = "OpSubgroupAvcMceGetDefaultInterDirectionPenaltyINTEL",
10558 .opcode = 5717,11659 .opcode = 5717,
10559 .operands = &[_]Operand{11660 .operands = &.{
10560 .{ .kind = .IdResultType, .quantifier = .required },11661 .{ .kind = .id_result_type, .quantifier = .required },
10561 .{ .kind = .IdResult, .quantifier = .required },11662 .{ .kind = .id_result, .quantifier = .required },
10562 .{ .kind = .IdRef, .quantifier = .required },11663 .{ .kind = .id_ref, .quantifier = .required },
10563 .{ .kind = .IdRef, .quantifier = .required },11664 .{ .kind = .id_ref, .quantifier = .required },
10564 },11665 },
10565 },11666 },
10566 .{11667 .{
10567 .name = "OpSubgroupAvcMceSetInterDirectionPenaltyINTEL",11668 .name = "OpSubgroupAvcMceSetInterDirectionPenaltyINTEL",
10568 .opcode = 5718,11669 .opcode = 5718,
10569 .operands = &[_]Operand{11670 .operands = &.{
10570 .{ .kind = .IdResultType, .quantifier = .required },11671 .{ .kind = .id_result_type, .quantifier = .required },
10571 .{ .kind = .IdResult, .quantifier = .required },11672 .{ .kind = .id_result, .quantifier = .required },
10572 .{ .kind = .IdRef, .quantifier = .required },11673 .{ .kind = .id_ref, .quantifier = .required },
10573 .{ .kind = .IdRef, .quantifier = .required },11674 .{ .kind = .id_ref, .quantifier = .required },
10574 },11675 },
10575 },11676 },
10576 .{11677 .{
10577 .name = "OpSubgroupAvcMceGetDefaultIntraLumaShapePenaltyINTEL",11678 .name = "OpSubgroupAvcMceGetDefaultIntraLumaShapePenaltyINTEL",
10578 .opcode = 5719,11679 .opcode = 5719,
10579 .operands = &[_]Operand{11680 .operands = &.{
10580 .{ .kind = .IdResultType, .quantifier = .required },11681 .{ .kind = .id_result_type, .quantifier = .required },
10581 .{ .kind = .IdResult, .quantifier = .required },11682 .{ .kind = .id_result, .quantifier = .required },
10582 .{ .kind = .IdRef, .quantifier = .required },11683 .{ .kind = .id_ref, .quantifier = .required },
10583 .{ .kind = .IdRef, .quantifier = .required },11684 .{ .kind = .id_ref, .quantifier = .required },
10584 },11685 },
10585 },11686 },
10586 .{11687 .{
10587 .name = "OpSubgroupAvcMceGetDefaultInterMotionVectorCostTableINTEL",11688 .name = "OpSubgroupAvcMceGetDefaultInterMotionVectorCostTableINTEL",
10588 .opcode = 5720,11689 .opcode = 5720,
10589 .operands = &[_]Operand{11690 .operands = &.{
10590 .{ .kind = .IdResultType, .quantifier = .required },11691 .{ .kind = .id_result_type, .quantifier = .required },
10591 .{ .kind = .IdResult, .quantifier = .required },11692 .{ .kind = .id_result, .quantifier = .required },
10592 .{ .kind = .IdRef, .quantifier = .required },11693 .{ .kind = .id_ref, .quantifier = .required },
10593 .{ .kind = .IdRef, .quantifier = .required },11694 .{ .kind = .id_ref, .quantifier = .required },
10594 },11695 },
10595 },11696 },
10596 .{11697 .{
10597 .name = "OpSubgroupAvcMceGetDefaultHighPenaltyCostTableINTEL",11698 .name = "OpSubgroupAvcMceGetDefaultHighPenaltyCostTableINTEL",
10598 .opcode = 5721,11699 .opcode = 5721,
10599 .operands = &[_]Operand{11700 .operands = &.{
10600 .{ .kind = .IdResultType, .quantifier = .required },11701 .{ .kind = .id_result_type, .quantifier = .required },
10601 .{ .kind = .IdResult, .quantifier = .required },11702 .{ .kind = .id_result, .quantifier = .required },
10602 },11703 },
10603 },11704 },
10604 .{11705 .{
10605 .name = "OpSubgroupAvcMceGetDefaultMediumPenaltyCostTableINTEL",11706 .name = "OpSubgroupAvcMceGetDefaultMediumPenaltyCostTableINTEL",
10606 .opcode = 5722,11707 .opcode = 5722,
10607 .operands = &[_]Operand{11708 .operands = &.{
10608 .{ .kind = .IdResultType, .quantifier = .required },11709 .{ .kind = .id_result_type, .quantifier = .required },
10609 .{ .kind = .IdResult, .quantifier = .required },11710 .{ .kind = .id_result, .quantifier = .required },
10610 },11711 },
10611 },11712 },
10612 .{11713 .{
10613 .name = "OpSubgroupAvcMceGetDefaultLowPenaltyCostTableINTEL",11714 .name = "OpSubgroupAvcMceGetDefaultLowPenaltyCostTableINTEL",
10614 .opcode = 5723,11715 .opcode = 5723,
10615 .operands = &[_]Operand{11716 .operands = &.{
10616 .{ .kind = .IdResultType, .quantifier = .required },11717 .{ .kind = .id_result_type, .quantifier = .required },
10617 .{ .kind = .IdResult, .quantifier = .required },11718 .{ .kind = .id_result, .quantifier = .required },
10618 },11719 },
10619 },11720 },
10620 .{11721 .{
10621 .name = "OpSubgroupAvcMceSetMotionVectorCostFunctionINTEL",11722 .name = "OpSubgroupAvcMceSetMotionVectorCostFunctionINTEL",
10622 .opcode = 5724,11723 .opcode = 5724,
10623 .operands = &[_]Operand{11724 .operands = &.{
10624 .{ .kind = .IdResultType, .quantifier = .required },11725 .{ .kind = .id_result_type, .quantifier = .required },
10625 .{ .kind = .IdResult, .quantifier = .required },11726 .{ .kind = .id_result, .quantifier = .required },
10626 .{ .kind = .IdRef, .quantifier = .required },11727 .{ .kind = .id_ref, .quantifier = .required },
10627 .{ .kind = .IdRef, .quantifier = .required },11728 .{ .kind = .id_ref, .quantifier = .required },
10628 .{ .kind = .IdRef, .quantifier = .required },11729 .{ .kind = .id_ref, .quantifier = .required },
10629 .{ .kind = .IdRef, .quantifier = .required },11730 .{ .kind = .id_ref, .quantifier = .required },
10630 },11731 },
10631 },11732 },
10632 .{11733 .{
10633 .name = "OpSubgroupAvcMceGetDefaultIntraLumaModePenaltyINTEL",11734 .name = "OpSubgroupAvcMceGetDefaultIntraLumaModePenaltyINTEL",
10634 .opcode = 5725,11735 .opcode = 5725,
10635 .operands = &[_]Operand{11736 .operands = &.{
10636 .{ .kind = .IdResultType, .quantifier = .required },11737 .{ .kind = .id_result_type, .quantifier = .required },
10637 .{ .kind = .IdResult, .quantifier = .required },11738 .{ .kind = .id_result, .quantifier = .required },
10638 .{ .kind = .IdRef, .quantifier = .required },11739 .{ .kind = .id_ref, .quantifier = .required },
10639 .{ .kind = .IdRef, .quantifier = .required },11740 .{ .kind = .id_ref, .quantifier = .required },
10640 },11741 },
10641 },11742 },
10642 .{11743 .{
10643 .name = "OpSubgroupAvcMceGetDefaultNonDcLumaIntraPenaltyINTEL",11744 .name = "OpSubgroupAvcMceGetDefaultNonDcLumaIntraPenaltyINTEL",
10644 .opcode = 5726,11745 .opcode = 5726,
10645 .operands = &[_]Operand{11746 .operands = &.{
10646 .{ .kind = .IdResultType, .quantifier = .required },11747 .{ .kind = .id_result_type, .quantifier = .required },
10647 .{ .kind = .IdResult, .quantifier = .required },11748 .{ .kind = .id_result, .quantifier = .required },
10648 },11749 },
10649 },11750 },
10650 .{11751 .{
10651 .name = "OpSubgroupAvcMceGetDefaultIntraChromaModeBasePenaltyINTEL",11752 .name = "OpSubgroupAvcMceGetDefaultIntraChromaModeBasePenaltyINTEL",
10652 .opcode = 5727,11753 .opcode = 5727,
10653 .operands = &[_]Operand{11754 .operands = &.{
10654 .{ .kind = .IdResultType, .quantifier = .required },11755 .{ .kind = .id_result_type, .quantifier = .required },
10655 .{ .kind = .IdResult, .quantifier = .required },11756 .{ .kind = .id_result, .quantifier = .required },
10656 },11757 },
10657 },11758 },
10658 .{11759 .{
10659 .name = "OpSubgroupAvcMceSetAcOnlyHaarINTEL",11760 .name = "OpSubgroupAvcMceSetAcOnlyHaarINTEL",
10660 .opcode = 5728,11761 .opcode = 5728,
10661 .operands = &[_]Operand{11762 .operands = &.{
10662 .{ .kind = .IdResultType, .quantifier = .required },11763 .{ .kind = .id_result_type, .quantifier = .required },
10663 .{ .kind = .IdResult, .quantifier = .required },11764 .{ .kind = .id_result, .quantifier = .required },
10664 .{ .kind = .IdRef, .quantifier = .required },11765 .{ .kind = .id_ref, .quantifier = .required },
10665 },11766 },
10666 },11767 },
10667 .{11768 .{
10668 .name = "OpSubgroupAvcMceSetSourceInterlacedFieldPolarityINTEL",11769 .name = "OpSubgroupAvcMceSetSourceInterlacedFieldPolarityINTEL",
10669 .opcode = 5729,11770 .opcode = 5729,
10670 .operands = &[_]Operand{11771 .operands = &.{
10671 .{ .kind = .IdResultType, .quantifier = .required },11772 .{ .kind = .id_result_type, .quantifier = .required },
10672 .{ .kind = .IdResult, .quantifier = .required },11773 .{ .kind = .id_result, .quantifier = .required },
10673 .{ .kind = .IdRef, .quantifier = .required },11774 .{ .kind = .id_ref, .quantifier = .required },
10674 .{ .kind = .IdRef, .quantifier = .required },11775 .{ .kind = .id_ref, .quantifier = .required },
10675 },11776 },
10676 },11777 },
10677 .{11778 .{
10678 .name = "OpSubgroupAvcMceSetSingleReferenceInterlacedFieldPolarityINTEL",11779 .name = "OpSubgroupAvcMceSetSingleReferenceInterlacedFieldPolarityINTEL",
10679 .opcode = 5730,11780 .opcode = 5730,
10680 .operands = &[_]Operand{11781 .operands = &.{
10681 .{ .kind = .IdResultType, .quantifier = .required },11782 .{ .kind = .id_result_type, .quantifier = .required },
10682 .{ .kind = .IdResult, .quantifier = .required },11783 .{ .kind = .id_result, .quantifier = .required },
10683 .{ .kind = .IdRef, .quantifier = .required },11784 .{ .kind = .id_ref, .quantifier = .required },
10684 .{ .kind = .IdRef, .quantifier = .required },11785 .{ .kind = .id_ref, .quantifier = .required },
10685 },11786 },
10686 },11787 },
10687 .{11788 .{
10688 .name = "OpSubgroupAvcMceSetDualReferenceInterlacedFieldPolaritiesINTEL",11789 .name = "OpSubgroupAvcMceSetDualReferenceInterlacedFieldPolaritiesINTEL",
10689 .opcode = 5731,11790 .opcode = 5731,
10690 .operands = &[_]Operand{11791 .operands = &.{
10691 .{ .kind = .IdResultType, .quantifier = .required },11792 .{ .kind = .id_result_type, .quantifier = .required },
10692 .{ .kind = .IdResult, .quantifier = .required },11793 .{ .kind = .id_result, .quantifier = .required },
10693 .{ .kind = .IdRef, .quantifier = .required },11794 .{ .kind = .id_ref, .quantifier = .required },
10694 .{ .kind = .IdRef, .quantifier = .required },11795 .{ .kind = .id_ref, .quantifier = .required },
10695 .{ .kind = .IdRef, .quantifier = .required },11796 .{ .kind = .id_ref, .quantifier = .required },
10696 },11797 },
10697 },11798 },
10698 .{11799 .{
10699 .name = "OpSubgroupAvcMceConvertToImePayloadINTEL",11800 .name = "OpSubgroupAvcMceConvertToImePayloadINTEL",
10700 .opcode = 5732,11801 .opcode = 5732,
10701 .operands = &[_]Operand{11802 .operands = &.{
10702 .{ .kind = .IdResultType, .quantifier = .required },11803 .{ .kind = .id_result_type, .quantifier = .required },
10703 .{ .kind = .IdResult, .quantifier = .required },11804 .{ .kind = .id_result, .quantifier = .required },
10704 .{ .kind = .IdRef, .quantifier = .required },11805 .{ .kind = .id_ref, .quantifier = .required },
10705 },11806 },
10706 },11807 },
10707 .{11808 .{
10708 .name = "OpSubgroupAvcMceConvertToImeResultINTEL",11809 .name = "OpSubgroupAvcMceConvertToImeResultINTEL",
10709 .opcode = 5733,11810 .opcode = 5733,
10710 .operands = &[_]Operand{11811 .operands = &.{
10711 .{ .kind = .IdResultType, .quantifier = .required },11812 .{ .kind = .id_result_type, .quantifier = .required },
10712 .{ .kind = .IdResult, .quantifier = .required },11813 .{ .kind = .id_result, .quantifier = .required },
10713 .{ .kind = .IdRef, .quantifier = .required },11814 .{ .kind = .id_ref, .quantifier = .required },
10714 },11815 },
10715 },11816 },
10716 .{11817 .{
10717 .name = "OpSubgroupAvcMceConvertToRefPayloadINTEL",11818 .name = "OpSubgroupAvcMceConvertToRefPayloadINTEL",
10718 .opcode = 5734,11819 .opcode = 5734,
10719 .operands = &[_]Operand{11820 .operands = &.{
10720 .{ .kind = .IdResultType, .quantifier = .required },11821 .{ .kind = .id_result_type, .quantifier = .required },
10721 .{ .kind = .IdResult, .quantifier = .required },11822 .{ .kind = .id_result, .quantifier = .required },
10722 .{ .kind = .IdRef, .quantifier = .required },11823 .{ .kind = .id_ref, .quantifier = .required },
10723 },11824 },
10724 },11825 },
10725 .{11826 .{
10726 .name = "OpSubgroupAvcMceConvertToRefResultINTEL",11827 .name = "OpSubgroupAvcMceConvertToRefResultINTEL",
10727 .opcode = 5735,11828 .opcode = 5735,
10728 .operands = &[_]Operand{11829 .operands = &.{
10729 .{ .kind = .IdResultType, .quantifier = .required },11830 .{ .kind = .id_result_type, .quantifier = .required },
10730 .{ .kind = .IdResult, .quantifier = .required },11831 .{ .kind = .id_result, .quantifier = .required },
10731 .{ .kind = .IdRef, .quantifier = .required },11832 .{ .kind = .id_ref, .quantifier = .required },
10732 },11833 },
10733 },11834 },
10734 .{11835 .{
10735 .name = "OpSubgroupAvcMceConvertToSicPayloadINTEL",11836 .name = "OpSubgroupAvcMceConvertToSicPayloadINTEL",
10736 .opcode = 5736,11837 .opcode = 5736,
10737 .operands = &[_]Operand{11838 .operands = &.{
10738 .{ .kind = .IdResultType, .quantifier = .required },11839 .{ .kind = .id_result_type, .quantifier = .required },
10739 .{ .kind = .IdResult, .quantifier = .required },11840 .{ .kind = .id_result, .quantifier = .required },
10740 .{ .kind = .IdRef, .quantifier = .required },11841 .{ .kind = .id_ref, .quantifier = .required },
10741 },11842 },
10742 },11843 },
10743 .{11844 .{
10744 .name = "OpSubgroupAvcMceConvertToSicResultINTEL",11845 .name = "OpSubgroupAvcMceConvertToSicResultINTEL",
10745 .opcode = 5737,11846 .opcode = 5737,
10746 .operands = &[_]Operand{11847 .operands = &.{
10747 .{ .kind = .IdResultType, .quantifier = .required },11848 .{ .kind = .id_result_type, .quantifier = .required },
10748 .{ .kind = .IdResult, .quantifier = .required },11849 .{ .kind = .id_result, .quantifier = .required },
10749 .{ .kind = .IdRef, .quantifier = .required },11850 .{ .kind = .id_ref, .quantifier = .required },
10750 },11851 },
10751 },11852 },
10752 .{11853 .{
10753 .name = "OpSubgroupAvcMceGetMotionVectorsINTEL",11854 .name = "OpSubgroupAvcMceGetMotionVectorsINTEL",
10754 .opcode = 5738,11855 .opcode = 5738,
10755 .operands = &[_]Operand{11856 .operands = &.{
10756 .{ .kind = .IdResultType, .quantifier = .required },11857 .{ .kind = .id_result_type, .quantifier = .required },
10757 .{ .kind = .IdResult, .quantifier = .required },11858 .{ .kind = .id_result, .quantifier = .required },
10758 .{ .kind = .IdRef, .quantifier = .required },11859 .{ .kind = .id_ref, .quantifier = .required },
10759 },11860 },
10760 },11861 },
10761 .{11862 .{
10762 .name = "OpSubgroupAvcMceGetInterDistortionsINTEL",11863 .name = "OpSubgroupAvcMceGetInterDistortionsINTEL",
10763 .opcode = 5739,11864 .opcode = 5739,
10764 .operands = &[_]Operand{11865 .operands = &.{
10765 .{ .kind = .IdResultType, .quantifier = .required },11866 .{ .kind = .id_result_type, .quantifier = .required },
10766 .{ .kind = .IdResult, .quantifier = .required },11867 .{ .kind = .id_result, .quantifier = .required },
10767 .{ .kind = .IdRef, .quantifier = .required },11868 .{ .kind = .id_ref, .quantifier = .required },
10768 },11869 },
10769 },11870 },
10770 .{11871 .{
10771 .name = "OpSubgroupAvcMceGetBestInterDistortionsINTEL",11872 .name = "OpSubgroupAvcMceGetBestInterDistortionsINTEL",
10772 .opcode = 5740,11873 .opcode = 5740,
10773 .operands = &[_]Operand{11874 .operands = &.{
10774 .{ .kind = .IdResultType, .quantifier = .required },11875 .{ .kind = .id_result_type, .quantifier = .required },
10775 .{ .kind = .IdResult, .quantifier = .required },11876 .{ .kind = .id_result, .quantifier = .required },
10776 .{ .kind = .IdRef, .quantifier = .required },11877 .{ .kind = .id_ref, .quantifier = .required },
10777 },11878 },
10778 },11879 },
10779 .{11880 .{
10780 .name = "OpSubgroupAvcMceGetInterMajorShapeINTEL",11881 .name = "OpSubgroupAvcMceGetInterMajorShapeINTEL",
10781 .opcode = 5741,11882 .opcode = 5741,
10782 .operands = &[_]Operand{11883 .operands = &.{
10783 .{ .kind = .IdResultType, .quantifier = .required },11884 .{ .kind = .id_result_type, .quantifier = .required },
10784 .{ .kind = .IdResult, .quantifier = .required },11885 .{ .kind = .id_result, .quantifier = .required },
10785 .{ .kind = .IdRef, .quantifier = .required },11886 .{ .kind = .id_ref, .quantifier = .required },
10786 },11887 },
10787 },11888 },
10788 .{11889 .{
10789 .name = "OpSubgroupAvcMceGetInterMinorShapeINTEL",11890 .name = "OpSubgroupAvcMceGetInterMinorShapeINTEL",
10790 .opcode = 5742,11891 .opcode = 5742,
10791 .operands = &[_]Operand{11892 .operands = &.{
10792 .{ .kind = .IdResultType, .quantifier = .required },11893 .{ .kind = .id_result_type, .quantifier = .required },
10793 .{ .kind = .IdResult, .quantifier = .required },11894 .{ .kind = .id_result, .quantifier = .required },
10794 .{ .kind = .IdRef, .quantifier = .required },11895 .{ .kind = .id_ref, .quantifier = .required },
10795 },11896 },
10796 },11897 },
10797 .{11898 .{
10798 .name = "OpSubgroupAvcMceGetInterDirectionsINTEL",11899 .name = "OpSubgroupAvcMceGetInterDirectionsINTEL",
10799 .opcode = 5743,11900 .opcode = 5743,
10800 .operands = &[_]Operand{11901 .operands = &.{
10801 .{ .kind = .IdResultType, .quantifier = .required },11902 .{ .kind = .id_result_type, .quantifier = .required },
10802 .{ .kind = .IdResult, .quantifier = .required },11903 .{ .kind = .id_result, .quantifier = .required },
10803 .{ .kind = .IdRef, .quantifier = .required },11904 .{ .kind = .id_ref, .quantifier = .required },
10804 },11905 },
10805 },11906 },
10806 .{11907 .{
10807 .name = "OpSubgroupAvcMceGetInterMotionVectorCountINTEL",11908 .name = "OpSubgroupAvcMceGetInterMotionVectorCountINTEL",
10808 .opcode = 5744,11909 .opcode = 5744,
10809 .operands = &[_]Operand{11910 .operands = &.{
10810 .{ .kind = .IdResultType, .quantifier = .required },11911 .{ .kind = .id_result_type, .quantifier = .required },
10811 .{ .kind = .IdResult, .quantifier = .required },11912 .{ .kind = .id_result, .quantifier = .required },
10812 .{ .kind = .IdRef, .quantifier = .required },11913 .{ .kind = .id_ref, .quantifier = .required },
10813 },11914 },
10814 },11915 },
10815 .{11916 .{
10816 .name = "OpSubgroupAvcMceGetInterReferenceIdsINTEL",11917 .name = "OpSubgroupAvcMceGetInterReferenceIdsINTEL",
10817 .opcode = 5745,11918 .opcode = 5745,
10818 .operands = &[_]Operand{11919 .operands = &.{
10819 .{ .kind = .IdResultType, .quantifier = .required },11920 .{ .kind = .id_result_type, .quantifier = .required },
10820 .{ .kind = .IdResult, .quantifier = .required },11921 .{ .kind = .id_result, .quantifier = .required },
10821 .{ .kind = .IdRef, .quantifier = .required },11922 .{ .kind = .id_ref, .quantifier = .required },
10822 },11923 },
10823 },11924 },
10824 .{11925 .{
10825 .name = "OpSubgroupAvcMceGetInterReferenceInterlacedFieldPolaritiesINTEL",11926 .name = "OpSubgroupAvcMceGetInterReferenceInterlacedFieldPolaritiesINTEL",
10826 .opcode = 5746,11927 .opcode = 5746,
10827 .operands = &[_]Operand{11928 .operands = &.{
10828 .{ .kind = .IdResultType, .quantifier = .required },11929 .{ .kind = .id_result_type, .quantifier = .required },
10829 .{ .kind = .IdResult, .quantifier = .required },11930 .{ .kind = .id_result, .quantifier = .required },
10830 .{ .kind = .IdRef, .quantifier = .required },11931 .{ .kind = .id_ref, .quantifier = .required },
10831 .{ .kind = .IdRef, .quantifier = .required },11932 .{ .kind = .id_ref, .quantifier = .required },
10832 .{ .kind = .IdRef, .quantifier = .required },11933 .{ .kind = .id_ref, .quantifier = .required },
10833 },11934 },
10834 },11935 },
10835 .{11936 .{
10836 .name = "OpSubgroupAvcImeInitializeINTEL",11937 .name = "OpSubgroupAvcImeInitializeINTEL",
10837 .opcode = 5747,11938 .opcode = 5747,
10838 .operands = &[_]Operand{11939 .operands = &.{
10839 .{ .kind = .IdResultType, .quantifier = .required },11940 .{ .kind = .id_result_type, .quantifier = .required },
10840 .{ .kind = .IdResult, .quantifier = .required },11941 .{ .kind = .id_result, .quantifier = .required },
10841 .{ .kind = .IdRef, .quantifier = .required },11942 .{ .kind = .id_ref, .quantifier = .required },
10842 .{ .kind = .IdRef, .quantifier = .required },11943 .{ .kind = .id_ref, .quantifier = .required },
10843 .{ .kind = .IdRef, .quantifier = .required },11944 .{ .kind = .id_ref, .quantifier = .required },
10844 },11945 },
10845 },11946 },
10846 .{11947 .{
10847 .name = "OpSubgroupAvcImeSetSingleReferenceINTEL",11948 .name = "OpSubgroupAvcImeSetSingleReferenceINTEL",
10848 .opcode = 5748,11949 .opcode = 5748,
10849 .operands = &[_]Operand{11950 .operands = &.{
10850 .{ .kind = .IdResultType, .quantifier = .required },11951 .{ .kind = .id_result_type, .quantifier = .required },
10851 .{ .kind = .IdResult, .quantifier = .required },11952 .{ .kind = .id_result, .quantifier = .required },
10852 .{ .kind = .IdRef, .quantifier = .required },11953 .{ .kind = .id_ref, .quantifier = .required },
10853 .{ .kind = .IdRef, .quantifier = .required },11954 .{ .kind = .id_ref, .quantifier = .required },
10854 .{ .kind = .IdRef, .quantifier = .required },11955 .{ .kind = .id_ref, .quantifier = .required },
10855 },11956 },
10856 },11957 },
10857 .{11958 .{
10858 .name = "OpSubgroupAvcImeSetDualReferenceINTEL",11959 .name = "OpSubgroupAvcImeSetDualReferenceINTEL",
10859 .opcode = 5749,11960 .opcode = 5749,
10860 .operands = &[_]Operand{11961 .operands = &.{
10861 .{ .kind = .IdResultType, .quantifier = .required },11962 .{ .kind = .id_result_type, .quantifier = .required },
10862 .{ .kind = .IdResult, .quantifier = .required },11963 .{ .kind = .id_result, .quantifier = .required },
10863 .{ .kind = .IdRef, .quantifier = .required },11964 .{ .kind = .id_ref, .quantifier = .required },
10864 .{ .kind = .IdRef, .quantifier = .required },11965 .{ .kind = .id_ref, .quantifier = .required },
10865 .{ .kind = .IdRef, .quantifier = .required },11966 .{ .kind = .id_ref, .quantifier = .required },
10866 .{ .kind = .IdRef, .quantifier = .required },11967 .{ .kind = .id_ref, .quantifier = .required },
10867 },11968 },
10868 },11969 },
10869 .{11970 .{
10870 .name = "OpSubgroupAvcImeRefWindowSizeINTEL",11971 .name = "OpSubgroupAvcImeRefWindowSizeINTEL",
10871 .opcode = 5750,11972 .opcode = 5750,
10872 .operands = &[_]Operand{11973 .operands = &.{
10873 .{ .kind = .IdResultType, .quantifier = .required },11974 .{ .kind = .id_result_type, .quantifier = .required },
10874 .{ .kind = .IdResult, .quantifier = .required },11975 .{ .kind = .id_result, .quantifier = .required },
10875 .{ .kind = .IdRef, .quantifier = .required },11976 .{ .kind = .id_ref, .quantifier = .required },
10876 .{ .kind = .IdRef, .quantifier = .required },11977 .{ .kind = .id_ref, .quantifier = .required },
10877 },11978 },
10878 },11979 },
10879 .{11980 .{
10880 .name = "OpSubgroupAvcImeAdjustRefOffsetINTEL",11981 .name = "OpSubgroupAvcImeAdjustRefOffsetINTEL",
10881 .opcode = 5751,11982 .opcode = 5751,
10882 .operands = &[_]Operand{11983 .operands = &.{
10883 .{ .kind = .IdResultType, .quantifier = .required },11984 .{ .kind = .id_result_type, .quantifier = .required },
10884 .{ .kind = .IdResult, .quantifier = .required },11985 .{ .kind = .id_result, .quantifier = .required },
10885 .{ .kind = .IdRef, .quantifier = .required },11986 .{ .kind = .id_ref, .quantifier = .required },
10886 .{ .kind = .IdRef, .quantifier = .required },11987 .{ .kind = .id_ref, .quantifier = .required },
10887 .{ .kind = .IdRef, .quantifier = .required },11988 .{ .kind = .id_ref, .quantifier = .required },
10888 .{ .kind = .IdRef, .quantifier = .required },11989 .{ .kind = .id_ref, .quantifier = .required },
10889 },11990 },
10890 },11991 },
10891 .{11992 .{
10892 .name = "OpSubgroupAvcImeConvertToMcePayloadINTEL",11993 .name = "OpSubgroupAvcImeConvertToMcePayloadINTEL",
10893 .opcode = 5752,11994 .opcode = 5752,
10894 .operands = &[_]Operand{11995 .operands = &.{
10895 .{ .kind = .IdResultType, .quantifier = .required },11996 .{ .kind = .id_result_type, .quantifier = .required },
10896 .{ .kind = .IdResult, .quantifier = .required },11997 .{ .kind = .id_result, .quantifier = .required },
10897 .{ .kind = .IdRef, .quantifier = .required },11998 .{ .kind = .id_ref, .quantifier = .required },
10898 },11999 },
10899 },12000 },
10900 .{12001 .{
10901 .name = "OpSubgroupAvcImeSetMaxMotionVectorCountINTEL",12002 .name = "OpSubgroupAvcImeSetMaxMotionVectorCountINTEL",
10902 .opcode = 5753,12003 .opcode = 5753,
10903 .operands = &[_]Operand{12004 .operands = &.{
10904 .{ .kind = .IdResultType, .quantifier = .required },12005 .{ .kind = .id_result_type, .quantifier = .required },
10905 .{ .kind = .IdResult, .quantifier = .required },12006 .{ .kind = .id_result, .quantifier = .required },
10906 .{ .kind = .IdRef, .quantifier = .required },12007 .{ .kind = .id_ref, .quantifier = .required },
10907 .{ .kind = .IdRef, .quantifier = .required },12008 .{ .kind = .id_ref, .quantifier = .required },
10908 },12009 },
10909 },12010 },
10910 .{12011 .{
10911 .name = "OpSubgroupAvcImeSetUnidirectionalMixDisableINTEL",12012 .name = "OpSubgroupAvcImeSetUnidirectionalMixDisableINTEL",
10912 .opcode = 5754,12013 .opcode = 5754,
10913 .operands = &[_]Operand{12014 .operands = &.{
10914 .{ .kind = .IdResultType, .quantifier = .required },12015 .{ .kind = .id_result_type, .quantifier = .required },
10915 .{ .kind = .IdResult, .quantifier = .required },12016 .{ .kind = .id_result, .quantifier = .required },
10916 .{ .kind = .IdRef, .quantifier = .required },12017 .{ .kind = .id_ref, .quantifier = .required },
10917 },12018 },
10918 },12019 },
10919 .{12020 .{
10920 .name = "OpSubgroupAvcImeSetEarlySearchTerminationThresholdINTEL",12021 .name = "OpSubgroupAvcImeSetEarlySearchTerminationThresholdINTEL",
10921 .opcode = 5755,12022 .opcode = 5755,
10922 .operands = &[_]Operand{12023 .operands = &.{
10923 .{ .kind = .IdResultType, .quantifier = .required },12024 .{ .kind = .id_result_type, .quantifier = .required },
10924 .{ .kind = .IdResult, .quantifier = .required },12025 .{ .kind = .id_result, .quantifier = .required },
10925 .{ .kind = .IdRef, .quantifier = .required },12026 .{ .kind = .id_ref, .quantifier = .required },
10926 .{ .kind = .IdRef, .quantifier = .required },12027 .{ .kind = .id_ref, .quantifier = .required },
10927 },12028 },
10928 },12029 },
10929 .{12030 .{
10930 .name = "OpSubgroupAvcImeSetWeightedSadINTEL",12031 .name = "OpSubgroupAvcImeSetWeightedSadINTEL",
10931 .opcode = 5756,12032 .opcode = 5756,
10932 .operands = &[_]Operand{12033 .operands = &.{
10933 .{ .kind = .IdResultType, .quantifier = .required },12034 .{ .kind = .id_result_type, .quantifier = .required },
10934 .{ .kind = .IdResult, .quantifier = .required },12035 .{ .kind = .id_result, .quantifier = .required },
10935 .{ .kind = .IdRef, .quantifier = .required },12036 .{ .kind = .id_ref, .quantifier = .required },
10936 .{ .kind = .IdRef, .quantifier = .required },12037 .{ .kind = .id_ref, .quantifier = .required },
10937 },12038 },
10938 },12039 },
10939 .{12040 .{
10940 .name = "OpSubgroupAvcImeEvaluateWithSingleReferenceINTEL",12041 .name = "OpSubgroupAvcImeEvaluateWithSingleReferenceINTEL",
10941 .opcode = 5757,12042 .opcode = 5757,
10942 .operands = &[_]Operand{12043 .operands = &.{
10943 .{ .kind = .IdResultType, .quantifier = .required },12044 .{ .kind = .id_result_type, .quantifier = .required },
10944 .{ .kind = .IdResult, .quantifier = .required },12045 .{ .kind = .id_result, .quantifier = .required },
10945 .{ .kind = .IdRef, .quantifier = .required },12046 .{ .kind = .id_ref, .quantifier = .required },
10946 .{ .kind = .IdRef, .quantifier = .required },12047 .{ .kind = .id_ref, .quantifier = .required },
10947 .{ .kind = .IdRef, .quantifier = .required },12048 .{ .kind = .id_ref, .quantifier = .required },
10948 },12049 },
10949 },12050 },
10950 .{12051 .{
10951 .name = "OpSubgroupAvcImeEvaluateWithDualReferenceINTEL",12052 .name = "OpSubgroupAvcImeEvaluateWithDualReferenceINTEL",
10952 .opcode = 5758,12053 .opcode = 5758,
10953 .operands = &[_]Operand{12054 .operands = &.{
10954 .{ .kind = .IdResultType, .quantifier = .required },12055 .{ .kind = .id_result_type, .quantifier = .required },
10955 .{ .kind = .IdResult, .quantifier = .required },12056 .{ .kind = .id_result, .quantifier = .required },
10956 .{ .kind = .IdRef, .quantifier = .required },12057 .{ .kind = .id_ref, .quantifier = .required },
10957 .{ .kind = .IdRef, .quantifier = .required },12058 .{ .kind = .id_ref, .quantifier = .required },
10958 .{ .kind = .IdRef, .quantifier = .required },12059 .{ .kind = .id_ref, .quantifier = .required },
10959 .{ .kind = .IdRef, .quantifier = .required },12060 .{ .kind = .id_ref, .quantifier = .required },
10960 },12061 },
10961 },12062 },
10962 .{12063 .{
10963 .name = "OpSubgroupAvcImeEvaluateWithSingleReferenceStreaminINTEL",12064 .name = "OpSubgroupAvcImeEvaluateWithSingleReferenceStreaminINTEL",
10964 .opcode = 5759,12065 .opcode = 5759,
10965 .operands = &[_]Operand{12066 .operands = &.{
10966 .{ .kind = .IdResultType, .quantifier = .required },12067 .{ .kind = .id_result_type, .quantifier = .required },
10967 .{ .kind = .IdResult, .quantifier = .required },12068 .{ .kind = .id_result, .quantifier = .required },
10968 .{ .kind = .IdRef, .quantifier = .required },12069 .{ .kind = .id_ref, .quantifier = .required },
10969 .{ .kind = .IdRef, .quantifier = .required },12070 .{ .kind = .id_ref, .quantifier = .required },
10970 .{ .kind = .IdRef, .quantifier = .required },12071 .{ .kind = .id_ref, .quantifier = .required },
10971 .{ .kind = .IdRef, .quantifier = .required },12072 .{ .kind = .id_ref, .quantifier = .required },
10972 },12073 },
10973 },12074 },
10974 .{12075 .{
10975 .name = "OpSubgroupAvcImeEvaluateWithDualReferenceStreaminINTEL",12076 .name = "OpSubgroupAvcImeEvaluateWithDualReferenceStreaminINTEL",
10976 .opcode = 5760,12077 .opcode = 5760,
10977 .operands = &[_]Operand{12078 .operands = &.{
10978 .{ .kind = .IdResultType, .quantifier = .required },12079 .{ .kind = .id_result_type, .quantifier = .required },
10979 .{ .kind = .IdResult, .quantifier = .required },12080 .{ .kind = .id_result, .quantifier = .required },
10980 .{ .kind = .IdRef, .quantifier = .required },12081 .{ .kind = .id_ref, .quantifier = .required },
10981 .{ .kind = .IdRef, .quantifier = .required },12082 .{ .kind = .id_ref, .quantifier = .required },
10982 .{ .kind = .IdRef, .quantifier = .required },12083 .{ .kind = .id_ref, .quantifier = .required },
10983 .{ .kind = .IdRef, .quantifier = .required },12084 .{ .kind = .id_ref, .quantifier = .required },
10984 .{ .kind = .IdRef, .quantifier = .required },12085 .{ .kind = .id_ref, .quantifier = .required },
10985 },12086 },
10986 },12087 },
10987 .{12088 .{
10988 .name = "OpSubgroupAvcImeEvaluateWithSingleReferenceStreamoutINTEL",12089 .name = "OpSubgroupAvcImeEvaluateWithSingleReferenceStreamoutINTEL",
10989 .opcode = 5761,12090 .opcode = 5761,
10990 .operands = &[_]Operand{12091 .operands = &.{
10991 .{ .kind = .IdResultType, .quantifier = .required },12092 .{ .kind = .id_result_type, .quantifier = .required },
10992 .{ .kind = .IdResult, .quantifier = .required },12093 .{ .kind = .id_result, .quantifier = .required },
10993 .{ .kind = .IdRef, .quantifier = .required },12094 .{ .kind = .id_ref, .quantifier = .required },
10994 .{ .kind = .IdRef, .quantifier = .required },12095 .{ .kind = .id_ref, .quantifier = .required },
10995 .{ .kind = .IdRef, .quantifier = .required },12096 .{ .kind = .id_ref, .quantifier = .required },
10996 },12097 },
10997 },12098 },
10998 .{12099 .{
10999 .name = "OpSubgroupAvcImeEvaluateWithDualReferenceStreamoutINTEL",12100 .name = "OpSubgroupAvcImeEvaluateWithDualReferenceStreamoutINTEL",
11000 .opcode = 5762,12101 .opcode = 5762,
11001 .operands = &[_]Operand{12102 .operands = &.{
11002 .{ .kind = .IdResultType, .quantifier = .required },12103 .{ .kind = .id_result_type, .quantifier = .required },
11003 .{ .kind = .IdResult, .quantifier = .required },12104 .{ .kind = .id_result, .quantifier = .required },
11004 .{ .kind = .IdRef, .quantifier = .required },12105 .{ .kind = .id_ref, .quantifier = .required },
11005 .{ .kind = .IdRef, .quantifier = .required },12106 .{ .kind = .id_ref, .quantifier = .required },
11006 .{ .kind = .IdRef, .quantifier = .required },12107 .{ .kind = .id_ref, .quantifier = .required },
11007 .{ .kind = .IdRef, .quantifier = .required },12108 .{ .kind = .id_ref, .quantifier = .required },
11008 },12109 },
11009 },12110 },
11010 .{12111 .{
11011 .name = "OpSubgroupAvcImeEvaluateWithSingleReferenceStreaminoutINTEL",12112 .name = "OpSubgroupAvcImeEvaluateWithSingleReferenceStreaminoutINTEL",
11012 .opcode = 5763,12113 .opcode = 5763,
11013 .operands = &[_]Operand{12114 .operands = &.{
11014 .{ .kind = .IdResultType, .quantifier = .required },12115 .{ .kind = .id_result_type, .quantifier = .required },
11015 .{ .kind = .IdResult, .quantifier = .required },12116 .{ .kind = .id_result, .quantifier = .required },
11016 .{ .kind = .IdRef, .quantifier = .required },12117 .{ .kind = .id_ref, .quantifier = .required },
11017 .{ .kind = .IdRef, .quantifier = .required },12118 .{ .kind = .id_ref, .quantifier = .required },
11018 .{ .kind = .IdRef, .quantifier = .required },12119 .{ .kind = .id_ref, .quantifier = .required },
11019 .{ .kind = .IdRef, .quantifier = .required },12120 .{ .kind = .id_ref, .quantifier = .required },
11020 },12121 },
11021 },12122 },
11022 .{12123 .{
11023 .name = "OpSubgroupAvcImeEvaluateWithDualReferenceStreaminoutINTEL",12124 .name = "OpSubgroupAvcImeEvaluateWithDualReferenceStreaminoutINTEL",
11024 .opcode = 5764,12125 .opcode = 5764,
11025 .operands = &[_]Operand{12126 .operands = &.{
11026 .{ .kind = .IdResultType, .quantifier = .required },12127 .{ .kind = .id_result_type, .quantifier = .required },
11027 .{ .kind = .IdResult, .quantifier = .required },12128 .{ .kind = .id_result, .quantifier = .required },
11028 .{ .kind = .IdRef, .quantifier = .required },12129 .{ .kind = .id_ref, .quantifier = .required },
11029 .{ .kind = .IdRef, .quantifier = .required },12130 .{ .kind = .id_ref, .quantifier = .required },
11030 .{ .kind = .IdRef, .quantifier = .required },12131 .{ .kind = .id_ref, .quantifier = .required },
11031 .{ .kind = .IdRef, .quantifier = .required },12132 .{ .kind = .id_ref, .quantifier = .required },
11032 .{ .kind = .IdRef, .quantifier = .required },12133 .{ .kind = .id_ref, .quantifier = .required },
11033 },12134 },
11034 },12135 },
11035 .{12136 .{
11036 .name = "OpSubgroupAvcImeConvertToMceResultINTEL",12137 .name = "OpSubgroupAvcImeConvertToMceResultINTEL",
11037 .opcode = 5765,12138 .opcode = 5765,
11038 .operands = &[_]Operand{12139 .operands = &.{
11039 .{ .kind = .IdResultType, .quantifier = .required },12140 .{ .kind = .id_result_type, .quantifier = .required },
11040 .{ .kind = .IdResult, .quantifier = .required },12141 .{ .kind = .id_result, .quantifier = .required },
11041 .{ .kind = .IdRef, .quantifier = .required },12142 .{ .kind = .id_ref, .quantifier = .required },
11042 },12143 },
11043 },12144 },
11044 .{12145 .{
11045 .name = "OpSubgroupAvcImeGetSingleReferenceStreaminINTEL",12146 .name = "OpSubgroupAvcImeGetSingleReferenceStreaminINTEL",
11046 .opcode = 5766,12147 .opcode = 5766,
11047 .operands = &[_]Operand{12148 .operands = &.{
11048 .{ .kind = .IdResultType, .quantifier = .required },12149 .{ .kind = .id_result_type, .quantifier = .required },
11049 .{ .kind = .IdResult, .quantifier = .required },12150 .{ .kind = .id_result, .quantifier = .required },
11050 .{ .kind = .IdRef, .quantifier = .required },12151 .{ .kind = .id_ref, .quantifier = .required },
11051 },12152 },
11052 },12153 },
11053 .{12154 .{
11054 .name = "OpSubgroupAvcImeGetDualReferenceStreaminINTEL",12155 .name = "OpSubgroupAvcImeGetDualReferenceStreaminINTEL",
11055 .opcode = 5767,12156 .opcode = 5767,
11056 .operands = &[_]Operand{12157 .operands = &.{
11057 .{ .kind = .IdResultType, .quantifier = .required },12158 .{ .kind = .id_result_type, .quantifier = .required },
11058 .{ .kind = .IdResult, .quantifier = .required },12159 .{ .kind = .id_result, .quantifier = .required },
11059 .{ .kind = .IdRef, .quantifier = .required },12160 .{ .kind = .id_ref, .quantifier = .required },
11060 },12161 },
11061 },12162 },
11062 .{12163 .{
11063 .name = "OpSubgroupAvcImeStripSingleReferenceStreamoutINTEL",12164 .name = "OpSubgroupAvcImeStripSingleReferenceStreamoutINTEL",
11064 .opcode = 5768,12165 .opcode = 5768,
11065 .operands = &[_]Operand{12166 .operands = &.{
11066 .{ .kind = .IdResultType, .quantifier = .required },12167 .{ .kind = .id_result_type, .quantifier = .required },
11067 .{ .kind = .IdResult, .quantifier = .required },12168 .{ .kind = .id_result, .quantifier = .required },
11068 .{ .kind = .IdRef, .quantifier = .required },12169 .{ .kind = .id_ref, .quantifier = .required },
11069 },12170 },
11070 },12171 },
11071 .{12172 .{
11072 .name = "OpSubgroupAvcImeStripDualReferenceStreamoutINTEL",12173 .name = "OpSubgroupAvcImeStripDualReferenceStreamoutINTEL",
11073 .opcode = 5769,12174 .opcode = 5769,
11074 .operands = &[_]Operand{12175 .operands = &.{
11075 .{ .kind = .IdResultType, .quantifier = .required },12176 .{ .kind = .id_result_type, .quantifier = .required },
11076 .{ .kind = .IdResult, .quantifier = .required },12177 .{ .kind = .id_result, .quantifier = .required },
11077 .{ .kind = .IdRef, .quantifier = .required },12178 .{ .kind = .id_ref, .quantifier = .required },
11078 },12179 },
11079 },12180 },
11080 .{12181 .{
11081 .name = "OpSubgroupAvcImeGetStreamoutSingleReferenceMajorShapeMotionVectorsINTEL",12182 .name = "OpSubgroupAvcImeGetStreamoutSingleReferenceMajorShapeMotionVectorsINTEL",
11082 .opcode = 5770,12183 .opcode = 5770,
11083 .operands = &[_]Operand{12184 .operands = &.{
11084 .{ .kind = .IdResultType, .quantifier = .required },12185 .{ .kind = .id_result_type, .quantifier = .required },
11085 .{ .kind = .IdResult, .quantifier = .required },12186 .{ .kind = .id_result, .quantifier = .required },
11086 .{ .kind = .IdRef, .quantifier = .required },12187 .{ .kind = .id_ref, .quantifier = .required },
11087 .{ .kind = .IdRef, .quantifier = .required },12188 .{ .kind = .id_ref, .quantifier = .required },
11088 },12189 },
11089 },12190 },
11090 .{12191 .{
11091 .name = "OpSubgroupAvcImeGetStreamoutSingleReferenceMajorShapeDistortionsINTEL",12192 .name = "OpSubgroupAvcImeGetStreamoutSingleReferenceMajorShapeDistortionsINTEL",
11092 .opcode = 5771,12193 .opcode = 5771,
11093 .operands = &[_]Operand{12194 .operands = &.{
11094 .{ .kind = .IdResultType, .quantifier = .required },12195 .{ .kind = .id_result_type, .quantifier = .required },
11095 .{ .kind = .IdResult, .quantifier = .required },12196 .{ .kind = .id_result, .quantifier = .required },
11096 .{ .kind = .IdRef, .quantifier = .required },12197 .{ .kind = .id_ref, .quantifier = .required },
11097 .{ .kind = .IdRef, .quantifier = .required },12198 .{ .kind = .id_ref, .quantifier = .required },
11098 },12199 },
11099 },12200 },
11100 .{12201 .{
11101 .name = "OpSubgroupAvcImeGetStreamoutSingleReferenceMajorShapeReferenceIdsINTEL",12202 .name = "OpSubgroupAvcImeGetStreamoutSingleReferenceMajorShapeReferenceIdsINTEL",
11102 .opcode = 5772,12203 .opcode = 5772,
11103 .operands = &[_]Operand{12204 .operands = &.{
11104 .{ .kind = .IdResultType, .quantifier = .required },12205 .{ .kind = .id_result_type, .quantifier = .required },
11105 .{ .kind = .IdResult, .quantifier = .required },12206 .{ .kind = .id_result, .quantifier = .required },
11106 .{ .kind = .IdRef, .quantifier = .required },12207 .{ .kind = .id_ref, .quantifier = .required },
11107 .{ .kind = .IdRef, .quantifier = .required },12208 .{ .kind = .id_ref, .quantifier = .required },
11108 },12209 },
11109 },12210 },
11110 .{12211 .{
11111 .name = "OpSubgroupAvcImeGetStreamoutDualReferenceMajorShapeMotionVectorsINTEL",12212 .name = "OpSubgroupAvcImeGetStreamoutDualReferenceMajorShapeMotionVectorsINTEL",
11112 .opcode = 5773,12213 .opcode = 5773,
11113 .operands = &[_]Operand{12214 .operands = &.{
11114 .{ .kind = .IdResultType, .quantifier = .required },12215 .{ .kind = .id_result_type, .quantifier = .required },
11115 .{ .kind = .IdResult, .quantifier = .required },12216 .{ .kind = .id_result, .quantifier = .required },
11116 .{ .kind = .IdRef, .quantifier = .required },12217 .{ .kind = .id_ref, .quantifier = .required },
11117 .{ .kind = .IdRef, .quantifier = .required },12218 .{ .kind = .id_ref, .quantifier = .required },
11118 .{ .kind = .IdRef, .quantifier = .required },12219 .{ .kind = .id_ref, .quantifier = .required },
11119 },12220 },
11120 },12221 },
11121 .{12222 .{
11122 .name = "OpSubgroupAvcImeGetStreamoutDualReferenceMajorShapeDistortionsINTEL",12223 .name = "OpSubgroupAvcImeGetStreamoutDualReferenceMajorShapeDistortionsINTEL",
11123 .opcode = 5774,12224 .opcode = 5774,
11124 .operands = &[_]Operand{12225 .operands = &.{
11125 .{ .kind = .IdResultType, .quantifier = .required },12226 .{ .kind = .id_result_type, .quantifier = .required },
11126 .{ .kind = .IdResult, .quantifier = .required },12227 .{ .kind = .id_result, .quantifier = .required },
11127 .{ .kind = .IdRef, .quantifier = .required },12228 .{ .kind = .id_ref, .quantifier = .required },
11128 .{ .kind = .IdRef, .quantifier = .required },12229 .{ .kind = .id_ref, .quantifier = .required },
11129 .{ .kind = .IdRef, .quantifier = .required },12230 .{ .kind = .id_ref, .quantifier = .required },
11130 },12231 },
11131 },12232 },
11132 .{12233 .{
11133 .name = "OpSubgroupAvcImeGetStreamoutDualReferenceMajorShapeReferenceIdsINTEL",12234 .name = "OpSubgroupAvcImeGetStreamoutDualReferenceMajorShapeReferenceIdsINTEL",
11134 .opcode = 5775,12235 .opcode = 5775,
11135 .operands = &[_]Operand{12236 .operands = &.{
11136 .{ .kind = .IdResultType, .quantifier = .required },12237 .{ .kind = .id_result_type, .quantifier = .required },
11137 .{ .kind = .IdResult, .quantifier = .required },12238 .{ .kind = .id_result, .quantifier = .required },
11138 .{ .kind = .IdRef, .quantifier = .required },12239 .{ .kind = .id_ref, .quantifier = .required },
11139 .{ .kind = .IdRef, .quantifier = .required },12240 .{ .kind = .id_ref, .quantifier = .required },
11140 .{ .kind = .IdRef, .quantifier = .required },12241 .{ .kind = .id_ref, .quantifier = .required },
11141 },12242 },
11142 },12243 },
11143 .{12244 .{
11144 .name = "OpSubgroupAvcImeGetBorderReachedINTEL",12245 .name = "OpSubgroupAvcImeGetBorderReachedINTEL",
11145 .opcode = 5776,12246 .opcode = 5776,
11146 .operands = &[_]Operand{12247 .operands = &.{
11147 .{ .kind = .IdResultType, .quantifier = .required },12248 .{ .kind = .id_result_type, .quantifier = .required },
11148 .{ .kind = .IdResult, .quantifier = .required },12249 .{ .kind = .id_result, .quantifier = .required },
11149 .{ .kind = .IdRef, .quantifier = .required },12250 .{ .kind = .id_ref, .quantifier = .required },
11150 .{ .kind = .IdRef, .quantifier = .required },12251 .{ .kind = .id_ref, .quantifier = .required },
11151 },12252 },
11152 },12253 },
11153 .{12254 .{
11154 .name = "OpSubgroupAvcImeGetTruncatedSearchIndicationINTEL",12255 .name = "OpSubgroupAvcImeGetTruncatedSearchIndicationINTEL",
11155 .opcode = 5777,12256 .opcode = 5777,
11156 .operands = &[_]Operand{12257 .operands = &.{
11157 .{ .kind = .IdResultType, .quantifier = .required },12258 .{ .kind = .id_result_type, .quantifier = .required },
11158 .{ .kind = .IdResult, .quantifier = .required },12259 .{ .kind = .id_result, .quantifier = .required },
11159 .{ .kind = .IdRef, .quantifier = .required },12260 .{ .kind = .id_ref, .quantifier = .required },
11160 },12261 },
11161 },12262 },
11162 .{12263 .{
11163 .name = "OpSubgroupAvcImeGetUnidirectionalEarlySearchTerminationINTEL",12264 .name = "OpSubgroupAvcImeGetUnidirectionalEarlySearchTerminationINTEL",
11164 .opcode = 5778,12265 .opcode = 5778,
11165 .operands = &[_]Operand{12266 .operands = &.{
11166 .{ .kind = .IdResultType, .quantifier = .required },12267 .{ .kind = .id_result_type, .quantifier = .required },
11167 .{ .kind = .IdResult, .quantifier = .required },12268 .{ .kind = .id_result, .quantifier = .required },
11168 .{ .kind = .IdRef, .quantifier = .required },12269 .{ .kind = .id_ref, .quantifier = .required },
11169 },12270 },
11170 },12271 },
11171 .{12272 .{
11172 .name = "OpSubgroupAvcImeGetWeightingPatternMinimumMotionVectorINTEL",12273 .name = "OpSubgroupAvcImeGetWeightingPatternMinimumMotionVectorINTEL",
11173 .opcode = 5779,12274 .opcode = 5779,
11174 .operands = &[_]Operand{12275 .operands = &.{
11175 .{ .kind = .IdResultType, .quantifier = .required },12276 .{ .kind = .id_result_type, .quantifier = .required },
11176 .{ .kind = .IdResult, .quantifier = .required },12277 .{ .kind = .id_result, .quantifier = .required },
11177 .{ .kind = .IdRef, .quantifier = .required },12278 .{ .kind = .id_ref, .quantifier = .required },
11178 },12279 },
11179 },12280 },
11180 .{12281 .{
11181 .name = "OpSubgroupAvcImeGetWeightingPatternMinimumDistortionINTEL",12282 .name = "OpSubgroupAvcImeGetWeightingPatternMinimumDistortionINTEL",
11182 .opcode = 5780,12283 .opcode = 5780,
11183 .operands = &[_]Operand{12284 .operands = &.{
11184 .{ .kind = .IdResultType, .quantifier = .required },12285 .{ .kind = .id_result_type, .quantifier = .required },
11185 .{ .kind = .IdResult, .quantifier = .required },12286 .{ .kind = .id_result, .quantifier = .required },
11186 .{ .kind = .IdRef, .quantifier = .required },12287 .{ .kind = .id_ref, .quantifier = .required },
11187 },12288 },
11188 },12289 },
11189 .{12290 .{
11190 .name = "OpSubgroupAvcFmeInitializeINTEL",12291 .name = "OpSubgroupAvcFmeInitializeINTEL",
11191 .opcode = 5781,12292 .opcode = 5781,
11192 .operands = &[_]Operand{12293 .operands = &.{
11193 .{ .kind = .IdResultType, .quantifier = .required },12294 .{ .kind = .id_result_type, .quantifier = .required },
11194 .{ .kind = .IdResult, .quantifier = .required },12295 .{ .kind = .id_result, .quantifier = .required },
11195 .{ .kind = .IdRef, .quantifier = .required },12296 .{ .kind = .id_ref, .quantifier = .required },
11196 .{ .kind = .IdRef, .quantifier = .required },12297 .{ .kind = .id_ref, .quantifier = .required },
11197 .{ .kind = .IdRef, .quantifier = .required },12298 .{ .kind = .id_ref, .quantifier = .required },
11198 .{ .kind = .IdRef, .quantifier = .required },12299 .{ .kind = .id_ref, .quantifier = .required },
11199 .{ .kind = .IdRef, .quantifier = .required },12300 .{ .kind = .id_ref, .quantifier = .required },
11200 .{ .kind = .IdRef, .quantifier = .required },12301 .{ .kind = .id_ref, .quantifier = .required },
11201 .{ .kind = .IdRef, .quantifier = .required },12302 .{ .kind = .id_ref, .quantifier = .required },
11202 },12303 },
11203 },12304 },
11204 .{12305 .{
11205 .name = "OpSubgroupAvcBmeInitializeINTEL",12306 .name = "OpSubgroupAvcBmeInitializeINTEL",
11206 .opcode = 5782,12307 .opcode = 5782,
11207 .operands = &[_]Operand{12308 .operands = &.{
11208 .{ .kind = .IdResultType, .quantifier = .required },12309 .{ .kind = .id_result_type, .quantifier = .required },
11209 .{ .kind = .IdResult, .quantifier = .required },12310 .{ .kind = .id_result, .quantifier = .required },
11210 .{ .kind = .IdRef, .quantifier = .required },12311 .{ .kind = .id_ref, .quantifier = .required },
11211 .{ .kind = .IdRef, .quantifier = .required },12312 .{ .kind = .id_ref, .quantifier = .required },
11212 .{ .kind = .IdRef, .quantifier = .required },12313 .{ .kind = .id_ref, .quantifier = .required },
11213 .{ .kind = .IdRef, .quantifier = .required },12314 .{ .kind = .id_ref, .quantifier = .required },
11214 .{ .kind = .IdRef, .quantifier = .required },12315 .{ .kind = .id_ref, .quantifier = .required },
11215 .{ .kind = .IdRef, .quantifier = .required },12316 .{ .kind = .id_ref, .quantifier = .required },
11216 .{ .kind = .IdRef, .quantifier = .required },12317 .{ .kind = .id_ref, .quantifier = .required },
11217 .{ .kind = .IdRef, .quantifier = .required },12318 .{ .kind = .id_ref, .quantifier = .required },
11218 },12319 },
11219 },12320 },
11220 .{12321 .{
11221 .name = "OpSubgroupAvcRefConvertToMcePayloadINTEL",12322 .name = "OpSubgroupAvcRefConvertToMcePayloadINTEL",
11222 .opcode = 5783,12323 .opcode = 5783,
11223 .operands = &[_]Operand{12324 .operands = &.{
11224 .{ .kind = .IdResultType, .quantifier = .required },12325 .{ .kind = .id_result_type, .quantifier = .required },
11225 .{ .kind = .IdResult, .quantifier = .required },12326 .{ .kind = .id_result, .quantifier = .required },
11226 .{ .kind = .IdRef, .quantifier = .required },12327 .{ .kind = .id_ref, .quantifier = .required },
11227 },12328 },
11228 },12329 },
11229 .{12330 .{
11230 .name = "OpSubgroupAvcRefSetBidirectionalMixDisableINTEL",12331 .name = "OpSubgroupAvcRefSetBidirectionalMixDisableINTEL",
11231 .opcode = 5784,12332 .opcode = 5784,
11232 .operands = &[_]Operand{12333 .operands = &.{
11233 .{ .kind = .IdResultType, .quantifier = .required },12334 .{ .kind = .id_result_type, .quantifier = .required },
11234 .{ .kind = .IdResult, .quantifier = .required },12335 .{ .kind = .id_result, .quantifier = .required },
11235 .{ .kind = .IdRef, .quantifier = .required },12336 .{ .kind = .id_ref, .quantifier = .required },
11236 },12337 },
11237 },12338 },
11238 .{12339 .{
11239 .name = "OpSubgroupAvcRefSetBilinearFilterEnableINTEL",12340 .name = "OpSubgroupAvcRefSetBilinearFilterEnableINTEL",
11240 .opcode = 5785,12341 .opcode = 5785,
11241 .operands = &[_]Operand{12342 .operands = &.{
11242 .{ .kind = .IdResultType, .quantifier = .required },12343 .{ .kind = .id_result_type, .quantifier = .required },
11243 .{ .kind = .IdResult, .quantifier = .required },12344 .{ .kind = .id_result, .quantifier = .required },
11244 .{ .kind = .IdRef, .quantifier = .required },12345 .{ .kind = .id_ref, .quantifier = .required },
11245 },12346 },
11246 },12347 },
11247 .{12348 .{
11248 .name = "OpSubgroupAvcRefEvaluateWithSingleReferenceINTEL",12349 .name = "OpSubgroupAvcRefEvaluateWithSingleReferenceINTEL",
11249 .opcode = 5786,12350 .opcode = 5786,
11250 .operands = &[_]Operand{12351 .operands = &.{
11251 .{ .kind = .IdResultType, .quantifier = .required },12352 .{ .kind = .id_result_type, .quantifier = .required },
11252 .{ .kind = .IdResult, .quantifier = .required },12353 .{ .kind = .id_result, .quantifier = .required },
11253 .{ .kind = .IdRef, .quantifier = .required },12354 .{ .kind = .id_ref, .quantifier = .required },
11254 .{ .kind = .IdRef, .quantifier = .required },12355 .{ .kind = .id_ref, .quantifier = .required },
11255 .{ .kind = .IdRef, .quantifier = .required },12356 .{ .kind = .id_ref, .quantifier = .required },
11256 },12357 },
11257 },12358 },
11258 .{12359 .{
11259 .name = "OpSubgroupAvcRefEvaluateWithDualReferenceINTEL",12360 .name = "OpSubgroupAvcRefEvaluateWithDualReferenceINTEL",
11260 .opcode = 5787,12361 .opcode = 5787,
11261 .operands = &[_]Operand{12362 .operands = &.{
11262 .{ .kind = .IdResultType, .quantifier = .required },12363 .{ .kind = .id_result_type, .quantifier = .required },
11263 .{ .kind = .IdResult, .quantifier = .required },12364 .{ .kind = .id_result, .quantifier = .required },
11264 .{ .kind = .IdRef, .quantifier = .required },12365 .{ .kind = .id_ref, .quantifier = .required },
11265 .{ .kind = .IdRef, .quantifier = .required },12366 .{ .kind = .id_ref, .quantifier = .required },
11266 .{ .kind = .IdRef, .quantifier = .required },12367 .{ .kind = .id_ref, .quantifier = .required },
11267 .{ .kind = .IdRef, .quantifier = .required },12368 .{ .kind = .id_ref, .quantifier = .required },
11268 },12369 },
11269 },12370 },
11270 .{12371 .{
11271 .name = "OpSubgroupAvcRefEvaluateWithMultiReferenceINTEL",12372 .name = "OpSubgroupAvcRefEvaluateWithMultiReferenceINTEL",
11272 .opcode = 5788,12373 .opcode = 5788,
11273 .operands = &[_]Operand{12374 .operands = &.{
11274 .{ .kind = .IdResultType, .quantifier = .required },12375 .{ .kind = .id_result_type, .quantifier = .required },
11275 .{ .kind = .IdResult, .quantifier = .required },12376 .{ .kind = .id_result, .quantifier = .required },
11276 .{ .kind = .IdRef, .quantifier = .required },12377 .{ .kind = .id_ref, .quantifier = .required },
11277 .{ .kind = .IdRef, .quantifier = .required },12378 .{ .kind = .id_ref, .quantifier = .required },
11278 .{ .kind = .IdRef, .quantifier = .required },12379 .{ .kind = .id_ref, .quantifier = .required },
11279 },12380 },
11280 },12381 },
11281 .{12382 .{
11282 .name = "OpSubgroupAvcRefEvaluateWithMultiReferenceInterlacedINTEL",12383 .name = "OpSubgroupAvcRefEvaluateWithMultiReferenceInterlacedINTEL",
11283 .opcode = 5789,12384 .opcode = 5789,
11284 .operands = &[_]Operand{12385 .operands = &.{
11285 .{ .kind = .IdResultType, .quantifier = .required },12386 .{ .kind = .id_result_type, .quantifier = .required },
11286 .{ .kind = .IdResult, .quantifier = .required },12387 .{ .kind = .id_result, .quantifier = .required },
11287 .{ .kind = .IdRef, .quantifier = .required },12388 .{ .kind = .id_ref, .quantifier = .required },
11288 .{ .kind = .IdRef, .quantifier = .required },12389 .{ .kind = .id_ref, .quantifier = .required },
11289 .{ .kind = .IdRef, .quantifier = .required },12390 .{ .kind = .id_ref, .quantifier = .required },
11290 .{ .kind = .IdRef, .quantifier = .required },12391 .{ .kind = .id_ref, .quantifier = .required },
11291 },12392 },
11292 },12393 },
11293 .{12394 .{
11294 .name = "OpSubgroupAvcRefConvertToMceResultINTEL",12395 .name = "OpSubgroupAvcRefConvertToMceResultINTEL",
11295 .opcode = 5790,12396 .opcode = 5790,
11296 .operands = &[_]Operand{12397 .operands = &.{
11297 .{ .kind = .IdResultType, .quantifier = .required },12398 .{ .kind = .id_result_type, .quantifier = .required },
11298 .{ .kind = .IdResult, .quantifier = .required },12399 .{ .kind = .id_result, .quantifier = .required },
11299 .{ .kind = .IdRef, .quantifier = .required },12400 .{ .kind = .id_ref, .quantifier = .required },
11300 },12401 },
11301 },12402 },
11302 .{12403 .{
11303 .name = "OpSubgroupAvcSicInitializeINTEL",12404 .name = "OpSubgroupAvcSicInitializeINTEL",
11304 .opcode = 5791,12405 .opcode = 5791,
11305 .operands = &[_]Operand{12406 .operands = &.{
11306 .{ .kind = .IdResultType, .quantifier = .required },12407 .{ .kind = .id_result_type, .quantifier = .required },
11307 .{ .kind = .IdResult, .quantifier = .required },12408 .{ .kind = .id_result, .quantifier = .required },
11308 .{ .kind = .IdRef, .quantifier = .required },12409 .{ .kind = .id_ref, .quantifier = .required },
11309 },12410 },
11310 },12411 },
11311 .{12412 .{
11312 .name = "OpSubgroupAvcSicConfigureSkcINTEL",12413 .name = "OpSubgroupAvcSicConfigureSkcINTEL",
11313 .opcode = 5792,12414 .opcode = 5792,
11314 .operands = &[_]Operand{12415 .operands = &.{
11315 .{ .kind = .IdResultType, .quantifier = .required },12416 .{ .kind = .id_result_type, .quantifier = .required },
11316 .{ .kind = .IdResult, .quantifier = .required },12417 .{ .kind = .id_result, .quantifier = .required },
11317 .{ .kind = .IdRef, .quantifier = .required },12418 .{ .kind = .id_ref, .quantifier = .required },
11318 .{ .kind = .IdRef, .quantifier = .required },12419 .{ .kind = .id_ref, .quantifier = .required },
11319 .{ .kind = .IdRef, .quantifier = .required },12420 .{ .kind = .id_ref, .quantifier = .required },
11320 .{ .kind = .IdRef, .quantifier = .required },12421 .{ .kind = .id_ref, .quantifier = .required },
11321 .{ .kind = .IdRef, .quantifier = .required },12422 .{ .kind = .id_ref, .quantifier = .required },
11322 .{ .kind = .IdRef, .quantifier = .required },12423 .{ .kind = .id_ref, .quantifier = .required },
11323 },12424 },
11324 },12425 },
11325 .{12426 .{
11326 .name = "OpSubgroupAvcSicConfigureIpeLumaINTEL",12427 .name = "OpSubgroupAvcSicConfigureIpeLumaINTEL",
11327 .opcode = 5793,12428 .opcode = 5793,
11328 .operands = &[_]Operand{12429 .operands = &.{
11329 .{ .kind = .IdResultType, .quantifier = .required },12430 .{ .kind = .id_result_type, .quantifier = .required },
11330 .{ .kind = .IdResult, .quantifier = .required },12431 .{ .kind = .id_result, .quantifier = .required },
11331 .{ .kind = .IdRef, .quantifier = .required },12432 .{ .kind = .id_ref, .quantifier = .required },
11332 .{ .kind = .IdRef, .quantifier = .required },12433 .{ .kind = .id_ref, .quantifier = .required },
11333 .{ .kind = .IdRef, .quantifier = .required },12434 .{ .kind = .id_ref, .quantifier = .required },
11334 .{ .kind = .IdRef, .quantifier = .required },12435 .{ .kind = .id_ref, .quantifier = .required },
11335 .{ .kind = .IdRef, .quantifier = .required },12436 .{ .kind = .id_ref, .quantifier = .required },
11336 .{ .kind = .IdRef, .quantifier = .required },12437 .{ .kind = .id_ref, .quantifier = .required },
11337 .{ .kind = .IdRef, .quantifier = .required },12438 .{ .kind = .id_ref, .quantifier = .required },
11338 .{ .kind = .IdRef, .quantifier = .required },12439 .{ .kind = .id_ref, .quantifier = .required },
11339 },12440 },
11340 },12441 },
11341 .{12442 .{
11342 .name = "OpSubgroupAvcSicConfigureIpeLumaChromaINTEL",12443 .name = "OpSubgroupAvcSicConfigureIpeLumaChromaINTEL",
11343 .opcode = 5794,12444 .opcode = 5794,
11344 .operands = &[_]Operand{12445 .operands = &.{
11345 .{ .kind = .IdResultType, .quantifier = .required },12446 .{ .kind = .id_result_type, .quantifier = .required },
11346 .{ .kind = .IdResult, .quantifier = .required },12447 .{ .kind = .id_result, .quantifier = .required },
11347 .{ .kind = .IdRef, .quantifier = .required },12448 .{ .kind = .id_ref, .quantifier = .required },
11348 .{ .kind = .IdRef, .quantifier = .required },12449 .{ .kind = .id_ref, .quantifier = .required },
11349 .{ .kind = .IdRef, .quantifier = .required },12450 .{ .kind = .id_ref, .quantifier = .required },
11350 .{ .kind = .IdRef, .quantifier = .required },12451 .{ .kind = .id_ref, .quantifier = .required },
11351 .{ .kind = .IdRef, .quantifier = .required },12452 .{ .kind = .id_ref, .quantifier = .required },
11352 .{ .kind = .IdRef, .quantifier = .required },12453 .{ .kind = .id_ref, .quantifier = .required },
11353 .{ .kind = .IdRef, .quantifier = .required },12454 .{ .kind = .id_ref, .quantifier = .required },
11354 .{ .kind = .IdRef, .quantifier = .required },12455 .{ .kind = .id_ref, .quantifier = .required },
11355 .{ .kind = .IdRef, .quantifier = .required },12456 .{ .kind = .id_ref, .quantifier = .required },
11356 .{ .kind = .IdRef, .quantifier = .required },12457 .{ .kind = .id_ref, .quantifier = .required },
11357 .{ .kind = .IdRef, .quantifier = .required },12458 .{ .kind = .id_ref, .quantifier = .required },
11358 },12459 },
11359 },12460 },
11360 .{12461 .{
11361 .name = "OpSubgroupAvcSicGetMotionVectorMaskINTEL",12462 .name = "OpSubgroupAvcSicGetMotionVectorMaskINTEL",
11362 .opcode = 5795,12463 .opcode = 5795,
11363 .operands = &[_]Operand{12464 .operands = &.{
11364 .{ .kind = .IdResultType, .quantifier = .required },12465 .{ .kind = .id_result_type, .quantifier = .required },
11365 .{ .kind = .IdResult, .quantifier = .required },12466 .{ .kind = .id_result, .quantifier = .required },
11366 .{ .kind = .IdRef, .quantifier = .required },12467 .{ .kind = .id_ref, .quantifier = .required },
11367 .{ .kind = .IdRef, .quantifier = .required },12468 .{ .kind = .id_ref, .quantifier = .required },
11368 },12469 },
11369 },12470 },
11370 .{12471 .{
11371 .name = "OpSubgroupAvcSicConvertToMcePayloadINTEL",12472 .name = "OpSubgroupAvcSicConvertToMcePayloadINTEL",
11372 .opcode = 5796,12473 .opcode = 5796,
11373 .operands = &[_]Operand{12474 .operands = &.{
11374 .{ .kind = .IdResultType, .quantifier = .required },12475 .{ .kind = .id_result_type, .quantifier = .required },
11375 .{ .kind = .IdResult, .quantifier = .required },12476 .{ .kind = .id_result, .quantifier = .required },
11376 .{ .kind = .IdRef, .quantifier = .required },12477 .{ .kind = .id_ref, .quantifier = .required },
11377 },12478 },
11378 },12479 },
11379 .{12480 .{
11380 .name = "OpSubgroupAvcSicSetIntraLumaShapePenaltyINTEL",12481 .name = "OpSubgroupAvcSicSetIntraLumaShapePenaltyINTEL",
11381 .opcode = 5797,12482 .opcode = 5797,
11382 .operands = &[_]Operand{12483 .operands = &.{
11383 .{ .kind = .IdResultType, .quantifier = .required },12484 .{ .kind = .id_result_type, .quantifier = .required },
11384 .{ .kind = .IdResult, .quantifier = .required },12485 .{ .kind = .id_result, .quantifier = .required },
11385 .{ .kind = .IdRef, .quantifier = .required },12486 .{ .kind = .id_ref, .quantifier = .required },
11386 .{ .kind = .IdRef, .quantifier = .required },12487 .{ .kind = .id_ref, .quantifier = .required },
11387 },12488 },
11388 },12489 },
11389 .{12490 .{
11390 .name = "OpSubgroupAvcSicSetIntraLumaModeCostFunctionINTEL",12491 .name = "OpSubgroupAvcSicSetIntraLumaModeCostFunctionINTEL",
11391 .opcode = 5798,12492 .opcode = 5798,
11392 .operands = &[_]Operand{12493 .operands = &.{
11393 .{ .kind = .IdResultType, .quantifier = .required },12494 .{ .kind = .id_result_type, .quantifier = .required },
11394 .{ .kind = .IdResult, .quantifier = .required },12495 .{ .kind = .id_result, .quantifier = .required },
11395 .{ .kind = .IdRef, .quantifier = .required },12496 .{ .kind = .id_ref, .quantifier = .required },
11396 .{ .kind = .IdRef, .quantifier = .required },12497 .{ .kind = .id_ref, .quantifier = .required },
11397 .{ .kind = .IdRef, .quantifier = .required },12498 .{ .kind = .id_ref, .quantifier = .required },
11398 .{ .kind = .IdRef, .quantifier = .required },12499 .{ .kind = .id_ref, .quantifier = .required },
11399 },12500 },
11400 },12501 },
11401 .{12502 .{
11402 .name = "OpSubgroupAvcSicSetIntraChromaModeCostFunctionINTEL",12503 .name = "OpSubgroupAvcSicSetIntraChromaModeCostFunctionINTEL",
11403 .opcode = 5799,12504 .opcode = 5799,
11404 .operands = &[_]Operand{12505 .operands = &.{
11405 .{ .kind = .IdResultType, .quantifier = .required },12506 .{ .kind = .id_result_type, .quantifier = .required },
11406 .{ .kind = .IdResult, .quantifier = .required },12507 .{ .kind = .id_result, .quantifier = .required },
11407 .{ .kind = .IdRef, .quantifier = .required },12508 .{ .kind = .id_ref, .quantifier = .required },
11408 .{ .kind = .IdRef, .quantifier = .required },12509 .{ .kind = .id_ref, .quantifier = .required },
11409 },12510 },
11410 },12511 },
11411 .{12512 .{
11412 .name = "OpSubgroupAvcSicSetBilinearFilterEnableINTEL",12513 .name = "OpSubgroupAvcSicSetBilinearFilterEnableINTEL",
11413 .opcode = 5800,12514 .opcode = 5800,
11414 .operands = &[_]Operand{12515 .operands = &.{
11415 .{ .kind = .IdResultType, .quantifier = .required },12516 .{ .kind = .id_result_type, .quantifier = .required },
11416 .{ .kind = .IdResult, .quantifier = .required },12517 .{ .kind = .id_result, .quantifier = .required },
11417 .{ .kind = .IdRef, .quantifier = .required },12518 .{ .kind = .id_ref, .quantifier = .required },
11418 },12519 },
11419 },12520 },
11420 .{12521 .{
11421 .name = "OpSubgroupAvcSicSetSkcForwardTransformEnableINTEL",12522 .name = "OpSubgroupAvcSicSetSkcForwardTransformEnableINTEL",
11422 .opcode = 5801,12523 .opcode = 5801,
11423 .operands = &[_]Operand{12524 .operands = &.{
11424 .{ .kind = .IdResultType, .quantifier = .required },12525 .{ .kind = .id_result_type, .quantifier = .required },
11425 .{ .kind = .IdResult, .quantifier = .required },12526 .{ .kind = .id_result, .quantifier = .required },
11426 .{ .kind = .IdRef, .quantifier = .required },12527 .{ .kind = .id_ref, .quantifier = .required },
11427 .{ .kind = .IdRef, .quantifier = .required },12528 .{ .kind = .id_ref, .quantifier = .required },
11428 },12529 },
11429 },12530 },
11430 .{12531 .{
11431 .name = "OpSubgroupAvcSicSetBlockBasedRawSkipSadINTEL",12532 .name = "OpSubgroupAvcSicSetBlockBasedRawSkipSadINTEL",
11432 .opcode = 5802,12533 .opcode = 5802,
11433 .operands = &[_]Operand{12534 .operands = &.{
11434 .{ .kind = .IdResultType, .quantifier = .required },12535 .{ .kind = .id_result_type, .quantifier = .required },
11435 .{ .kind = .IdResult, .quantifier = .required },12536 .{ .kind = .id_result, .quantifier = .required },
11436 .{ .kind = .IdRef, .quantifier = .required },12537 .{ .kind = .id_ref, .quantifier = .required },
11437 .{ .kind = .IdRef, .quantifier = .required },12538 .{ .kind = .id_ref, .quantifier = .required },
11438 },12539 },
11439 },12540 },
11440 .{12541 .{
11441 .name = "OpSubgroupAvcSicEvaluateIpeINTEL",12542 .name = "OpSubgroupAvcSicEvaluateIpeINTEL",
11442 .opcode = 5803,12543 .opcode = 5803,
11443 .operands = &[_]Operand{12544 .operands = &.{
11444 .{ .kind = .IdResultType, .quantifier = .required },12545 .{ .kind = .id_result_type, .quantifier = .required },
11445 .{ .kind = .IdResult, .quantifier = .required },12546 .{ .kind = .id_result, .quantifier = .required },
11446 .{ .kind = .IdRef, .quantifier = .required },12547 .{ .kind = .id_ref, .quantifier = .required },
11447 .{ .kind = .IdRef, .quantifier = .required },12548 .{ .kind = .id_ref, .quantifier = .required },
11448 },12549 },
11449 },12550 },
11450 .{12551 .{
11451 .name = "OpSubgroupAvcSicEvaluateWithSingleReferenceINTEL",12552 .name = "OpSubgroupAvcSicEvaluateWithSingleReferenceINTEL",
11452 .opcode = 5804,12553 .opcode = 5804,
11453 .operands = &[_]Operand{12554 .operands = &.{
11454 .{ .kind = .IdResultType, .quantifier = .required },12555 .{ .kind = .id_result_type, .quantifier = .required },
11455 .{ .kind = .IdResult, .quantifier = .required },12556 .{ .kind = .id_result, .quantifier = .required },
11456 .{ .kind = .IdRef, .quantifier = .required },12557 .{ .kind = .id_ref, .quantifier = .required },
11457 .{ .kind = .IdRef, .quantifier = .required },12558 .{ .kind = .id_ref, .quantifier = .required },
11458 .{ .kind = .IdRef, .quantifier = .required },12559 .{ .kind = .id_ref, .quantifier = .required },
11459 },12560 },
11460 },12561 },
11461 .{12562 .{
11462 .name = "OpSubgroupAvcSicEvaluateWithDualReferenceINTEL",12563 .name = "OpSubgroupAvcSicEvaluateWithDualReferenceINTEL",
11463 .opcode = 5805,12564 .opcode = 5805,
11464 .operands = &[_]Operand{12565 .operands = &.{
11465 .{ .kind = .IdResultType, .quantifier = .required },12566 .{ .kind = .id_result_type, .quantifier = .required },
11466 .{ .kind = .IdResult, .quantifier = .required },12567 .{ .kind = .id_result, .quantifier = .required },
11467 .{ .kind = .IdRef, .quantifier = .required },12568 .{ .kind = .id_ref, .quantifier = .required },
11468 .{ .kind = .IdRef, .quantifier = .required },12569 .{ .kind = .id_ref, .quantifier = .required },
11469 .{ .kind = .IdRef, .quantifier = .required },12570 .{ .kind = .id_ref, .quantifier = .required },
11470 .{ .kind = .IdRef, .quantifier = .required },12571 .{ .kind = .id_ref, .quantifier = .required },
11471 },12572 },
11472 },12573 },
11473 .{12574 .{
11474 .name = "OpSubgroupAvcSicEvaluateWithMultiReferenceINTEL",12575 .name = "OpSubgroupAvcSicEvaluateWithMultiReferenceINTEL",
11475 .opcode = 5806,12576 .opcode = 5806,
11476 .operands = &[_]Operand{12577 .operands = &.{
11477 .{ .kind = .IdResultType, .quantifier = .required },12578 .{ .kind = .id_result_type, .quantifier = .required },
11478 .{ .kind = .IdResult, .quantifier = .required },12579 .{ .kind = .id_result, .quantifier = .required },
11479 .{ .kind = .IdRef, .quantifier = .required },12580 .{ .kind = .id_ref, .quantifier = .required },
11480 .{ .kind = .IdRef, .quantifier = .required },12581 .{ .kind = .id_ref, .quantifier = .required },
11481 .{ .kind = .IdRef, .quantifier = .required },12582 .{ .kind = .id_ref, .quantifier = .required },
11482 },12583 },
11483 },12584 },
11484 .{12585 .{
11485 .name = "OpSubgroupAvcSicEvaluateWithMultiReferenceInterlacedINTEL",12586 .name = "OpSubgroupAvcSicEvaluateWithMultiReferenceInterlacedINTEL",
11486 .opcode = 5807,12587 .opcode = 5807,
11487 .operands = &[_]Operand{12588 .operands = &.{
11488 .{ .kind = .IdResultType, .quantifier = .required },12589 .{ .kind = .id_result_type, .quantifier = .required },
11489 .{ .kind = .IdResult, .quantifier = .required },12590 .{ .kind = .id_result, .quantifier = .required },
11490 .{ .kind = .IdRef, .quantifier = .required },12591 .{ .kind = .id_ref, .quantifier = .required },
11491 .{ .kind = .IdRef, .quantifier = .required },12592 .{ .kind = .id_ref, .quantifier = .required },
11492 .{ .kind = .IdRef, .quantifier = .required },12593 .{ .kind = .id_ref, .quantifier = .required },
11493 .{ .kind = .IdRef, .quantifier = .required },12594 .{ .kind = .id_ref, .quantifier = .required },
11494 },12595 },
11495 },12596 },
11496 .{12597 .{
11497 .name = "OpSubgroupAvcSicConvertToMceResultINTEL",12598 .name = "OpSubgroupAvcSicConvertToMceResultINTEL",
11498 .opcode = 5808,12599 .opcode = 5808,
11499 .operands = &[_]Operand{12600 .operands = &.{
11500 .{ .kind = .IdResultType, .quantifier = .required },12601 .{ .kind = .id_result_type, .quantifier = .required },
11501 .{ .kind = .IdResult, .quantifier = .required },12602 .{ .kind = .id_result, .quantifier = .required },
11502 .{ .kind = .IdRef, .quantifier = .required },12603 .{ .kind = .id_ref, .quantifier = .required },
11503 },12604 },
11504 },12605 },
11505 .{12606 .{
11506 .name = "OpSubgroupAvcSicGetIpeLumaShapeINTEL",12607 .name = "OpSubgroupAvcSicGetIpeLumaShapeINTEL",
11507 .opcode = 5809,12608 .opcode = 5809,
11508 .operands = &[_]Operand{12609 .operands = &.{
11509 .{ .kind = .IdResultType, .quantifier = .required },12610 .{ .kind = .id_result_type, .quantifier = .required },
11510 .{ .kind = .IdResult, .quantifier = .required },12611 .{ .kind = .id_result, .quantifier = .required },
11511 .{ .kind = .IdRef, .quantifier = .required },12612 .{ .kind = .id_ref, .quantifier = .required },
11512 },12613 },
11513 },12614 },
11514 .{12615 .{
11515 .name = "OpSubgroupAvcSicGetBestIpeLumaDistortionINTEL",12616 .name = "OpSubgroupAvcSicGetBestIpeLumaDistortionINTEL",
11516 .opcode = 5810,12617 .opcode = 5810,
11517 .operands = &[_]Operand{12618 .operands = &.{
11518 .{ .kind = .IdResultType, .quantifier = .required },12619 .{ .kind = .id_result_type, .quantifier = .required },
11519 .{ .kind = .IdResult, .quantifier = .required },12620 .{ .kind = .id_result, .quantifier = .required },
11520 .{ .kind = .IdRef, .quantifier = .required },12621 .{ .kind = .id_ref, .quantifier = .required },
11521 },12622 },
11522 },12623 },
11523 .{12624 .{
11524 .name = "OpSubgroupAvcSicGetBestIpeChromaDistortionINTEL",12625 .name = "OpSubgroupAvcSicGetBestIpeChromaDistortionINTEL",
11525 .opcode = 5811,12626 .opcode = 5811,
11526 .operands = &[_]Operand{12627 .operands = &.{
11527 .{ .kind = .IdResultType, .quantifier = .required },12628 .{ .kind = .id_result_type, .quantifier = .required },
11528 .{ .kind = .IdResult, .quantifier = .required },12629 .{ .kind = .id_result, .quantifier = .required },
11529 .{ .kind = .IdRef, .quantifier = .required },12630 .{ .kind = .id_ref, .quantifier = .required },
11530 },12631 },
11531 },12632 },
11532 .{12633 .{
11533 .name = "OpSubgroupAvcSicGetPackedIpeLumaModesINTEL",12634 .name = "OpSubgroupAvcSicGetPackedIpeLumaModesINTEL",
11534 .opcode = 5812,12635 .opcode = 5812,
11535 .operands = &[_]Operand{12636 .operands = &.{
11536 .{ .kind = .IdResultType, .quantifier = .required },12637 .{ .kind = .id_result_type, .quantifier = .required },
11537 .{ .kind = .IdResult, .quantifier = .required },12638 .{ .kind = .id_result, .quantifier = .required },
11538 .{ .kind = .IdRef, .quantifier = .required },12639 .{ .kind = .id_ref, .quantifier = .required },
11539 },12640 },
11540 },12641 },
11541 .{12642 .{
11542 .name = "OpSubgroupAvcSicGetIpeChromaModeINTEL",12643 .name = "OpSubgroupAvcSicGetIpeChromaModeINTEL",
11543 .opcode = 5813,12644 .opcode = 5813,
11544 .operands = &[_]Operand{12645 .operands = &.{
11545 .{ .kind = .IdResultType, .quantifier = .required },12646 .{ .kind = .id_result_type, .quantifier = .required },
11546 .{ .kind = .IdResult, .quantifier = .required },12647 .{ .kind = .id_result, .quantifier = .required },
11547 .{ .kind = .IdRef, .quantifier = .required },12648 .{ .kind = .id_ref, .quantifier = .required },
11548 },12649 },
11549 },12650 },
11550 .{12651 .{
11551 .name = "OpSubgroupAvcSicGetPackedSkcLumaCountThresholdINTEL",12652 .name = "OpSubgroupAvcSicGetPackedSkcLumaCountThresholdINTEL",
11552 .opcode = 5814,12653 .opcode = 5814,
11553 .operands = &[_]Operand{12654 .operands = &.{
11554 .{ .kind = .IdResultType, .quantifier = .required },12655 .{ .kind = .id_result_type, .quantifier = .required },
11555 .{ .kind = .IdResult, .quantifier = .required },12656 .{ .kind = .id_result, .quantifier = .required },
11556 .{ .kind = .IdRef, .quantifier = .required },12657 .{ .kind = .id_ref, .quantifier = .required },
11557 },12658 },
11558 },12659 },
11559 .{12660 .{
11560 .name = "OpSubgroupAvcSicGetPackedSkcLumaSumThresholdINTEL",12661 .name = "OpSubgroupAvcSicGetPackedSkcLumaSumThresholdINTEL",
11561 .opcode = 5815,12662 .opcode = 5815,
11562 .operands = &[_]Operand{12663 .operands = &.{
11563 .{ .kind = .IdResultType, .quantifier = .required },12664 .{ .kind = .id_result_type, .quantifier = .required },
11564 .{ .kind = .IdResult, .quantifier = .required },12665 .{ .kind = .id_result, .quantifier = .required },
11565 .{ .kind = .IdRef, .quantifier = .required },12666 .{ .kind = .id_ref, .quantifier = .required },
11566 },12667 },
11567 },12668 },
11568 .{12669 .{
11569 .name = "OpSubgroupAvcSicGetInterRawSadsINTEL",12670 .name = "OpSubgroupAvcSicGetInterRawSadsINTEL",
11570 .opcode = 5816,12671 .opcode = 5816,
11571 .operands = &[_]Operand{12672 .operands = &.{
11572 .{ .kind = .IdResultType, .quantifier = .required },12673 .{ .kind = .id_result_type, .quantifier = .required },
11573 .{ .kind = .IdResult, .quantifier = .required },12674 .{ .kind = .id_result, .quantifier = .required },
11574 .{ .kind = .IdRef, .quantifier = .required },12675 .{ .kind = .id_ref, .quantifier = .required },
11575 },12676 },
11576 },12677 },
11577 .{12678 .{
11578 .name = "OpVariableLengthArrayINTEL",12679 .name = "OpVariableLengthArrayINTEL",
11579 .opcode = 5818,12680 .opcode = 5818,
11580 .operands = &[_]Operand{12681 .operands = &.{
11581 .{ .kind = .IdResultType, .quantifier = .required },12682 .{ .kind = .id_result_type, .quantifier = .required },
11582 .{ .kind = .IdResult, .quantifier = .required },12683 .{ .kind = .id_result, .quantifier = .required },
11583 .{ .kind = .IdRef, .quantifier = .required },12684 .{ .kind = .id_ref, .quantifier = .required },
11584 },12685 },
11585 },12686 },
11586 .{12687 .{
11587 .name = "OpSaveMemoryINTEL",12688 .name = "OpSaveMemoryINTEL",
11588 .opcode = 5819,12689 .opcode = 5819,
11589 .operands = &[_]Operand{12690 .operands = &.{
11590 .{ .kind = .IdResultType, .quantifier = .required },12691 .{ .kind = .id_result_type, .quantifier = .required },
11591 .{ .kind = .IdResult, .quantifier = .required },12692 .{ .kind = .id_result, .quantifier = .required },
11592 },12693 },
11593 },12694 },
11594 .{12695 .{
11595 .name = "OpRestoreMemoryINTEL",12696 .name = "OpRestoreMemoryINTEL",
11596 .opcode = 5820,12697 .opcode = 5820,
11597 .operands = &[_]Operand{12698 .operands = &.{
11598 .{ .kind = .IdRef, .quantifier = .required },12699 .{ .kind = .id_ref, .quantifier = .required },
11599 },12700 },
11600 },12701 },
11601 .{12702 .{
11602 .name = "OpArbitraryFloatSinCosPiINTEL",12703 .name = "OpArbitraryFloatSinCosPiINTEL",
11603 .opcode = 5840,12704 .opcode = 5840,
11604 .operands = &[_]Operand{12705 .operands = &.{
11605 .{ .kind = .IdResultType, .quantifier = .required },12706 .{ .kind = .id_result_type, .quantifier = .required },
11606 .{ .kind = .IdResult, .quantifier = .required },12707 .{ .kind = .id_result, .quantifier = .required },
11607 .{ .kind = .IdRef, .quantifier = .required },12708 .{ .kind = .id_ref, .quantifier = .required },
11608 .{ .kind = .LiteralInteger, .quantifier = .required },12709 .{ .kind = .literal_integer, .quantifier = .required },
11609 .{ .kind = .LiteralInteger, .quantifier = .required },12710 .{ .kind = .literal_integer, .quantifier = .required },
11610 .{ .kind = .LiteralInteger, .quantifier = .required },12711 .{ .kind = .literal_integer, .quantifier = .required },
11611 .{ .kind = .LiteralInteger, .quantifier = .required },12712 .{ .kind = .literal_integer, .quantifier = .required },
11612 .{ .kind = .LiteralInteger, .quantifier = .required },12713 .{ .kind = .literal_integer, .quantifier = .required },
11613 .{ .kind = .LiteralInteger, .quantifier = .required },
11614 },12714 },
11615 },12715 },
11616 .{12716 .{
11617 .name = "OpArbitraryFloatCastINTEL",12717 .name = "OpArbitraryFloatCastINTEL",
11618 .opcode = 5841,12718 .opcode = 5841,
11619 .operands = &[_]Operand{12719 .operands = &.{
11620 .{ .kind = .IdResultType, .quantifier = .required },12720 .{ .kind = .id_result_type, .quantifier = .required },
11621 .{ .kind = .IdResult, .quantifier = .required },12721 .{ .kind = .id_result, .quantifier = .required },
11622 .{ .kind = .IdRef, .quantifier = .required },12722 .{ .kind = .id_ref, .quantifier = .required },
11623 .{ .kind = .LiteralInteger, .quantifier = .required },12723 .{ .kind = .literal_integer, .quantifier = .required },
11624 .{ .kind = .LiteralInteger, .quantifier = .required },12724 .{ .kind = .literal_integer, .quantifier = .required },
11625 .{ .kind = .LiteralInteger, .quantifier = .required },12725 .{ .kind = .literal_integer, .quantifier = .required },
11626 .{ .kind = .LiteralInteger, .quantifier = .required },12726 .{ .kind = .literal_integer, .quantifier = .required },
11627 .{ .kind = .LiteralInteger, .quantifier = .required },12727 .{ .kind = .literal_integer, .quantifier = .required },
11628 },12728 },
11629 },12729 },
11630 .{12730 .{
11631 .name = "OpArbitraryFloatCastFromIntINTEL",12731 .name = "OpArbitraryFloatCastFromIntINTEL",
11632 .opcode = 5842,12732 .opcode = 5842,
11633 .operands = &[_]Operand{12733 .operands = &.{
11634 .{ .kind = .IdResultType, .quantifier = .required },12734 .{ .kind = .id_result_type, .quantifier = .required },
11635 .{ .kind = .IdResult, .quantifier = .required },12735 .{ .kind = .id_result, .quantifier = .required },
11636 .{ .kind = .IdRef, .quantifier = .required },12736 .{ .kind = .id_ref, .quantifier = .required },
11637 .{ .kind = .LiteralInteger, .quantifier = .required },12737 .{ .kind = .literal_integer, .quantifier = .required },
11638 .{ .kind = .LiteralInteger, .quantifier = .required },12738 .{ .kind = .literal_integer, .quantifier = .required },
11639 .{ .kind = .LiteralInteger, .quantifier = .required },12739 .{ .kind = .literal_integer, .quantifier = .required },
11640 .{ .kind = .LiteralInteger, .quantifier = .required },12740 .{ .kind = .literal_integer, .quantifier = .required },
11641 .{ .kind = .LiteralInteger, .quantifier = .required },12741 .{ .kind = .literal_integer, .quantifier = .required },
11642 },12742 },
11643 },12743 },
11644 .{12744 .{
11645 .name = "OpArbitraryFloatCastToIntINTEL",12745 .name = "OpArbitraryFloatCastToIntINTEL",
11646 .opcode = 5843,12746 .opcode = 5843,
11647 .operands = &[_]Operand{12747 .operands = &.{
11648 .{ .kind = .IdResultType, .quantifier = .required },12748 .{ .kind = .id_result_type, .quantifier = .required },
11649 .{ .kind = .IdResult, .quantifier = .required },12749 .{ .kind = .id_result, .quantifier = .required },
11650 .{ .kind = .IdRef, .quantifier = .required },12750 .{ .kind = .id_ref, .quantifier = .required },
11651 .{ .kind = .LiteralInteger, .quantifier = .required },12751 .{ .kind = .literal_integer, .quantifier = .required },
11652 .{ .kind = .LiteralInteger, .quantifier = .required },12752 .{ .kind = .literal_integer, .quantifier = .required },
11653 .{ .kind = .LiteralInteger, .quantifier = .required },12753 .{ .kind = .literal_integer, .quantifier = .required },
11654 .{ .kind = .LiteralInteger, .quantifier = .required },12754 .{ .kind = .literal_integer, .quantifier = .required },
12755 .{ .kind = .literal_integer, .quantifier = .required },
11655 },12756 },
11656 },12757 },
11657 .{12758 .{
11658 .name = "OpArbitraryFloatAddINTEL",12759 .name = "OpArbitraryFloatAddINTEL",
11659 .opcode = 5846,12760 .opcode = 5846,
11660 .operands = &[_]Operand{12761 .operands = &.{
11661 .{ .kind = .IdResultType, .quantifier = .required },12762 .{ .kind = .id_result_type, .quantifier = .required },
11662 .{ .kind = .IdResult, .quantifier = .required },12763 .{ .kind = .id_result, .quantifier = .required },
11663 .{ .kind = .IdRef, .quantifier = .required },12764 .{ .kind = .id_ref, .quantifier = .required },
11664 .{ .kind = .LiteralInteger, .quantifier = .required },12765 .{ .kind = .literal_integer, .quantifier = .required },
11665 .{ .kind = .IdRef, .quantifier = .required },12766 .{ .kind = .id_ref, .quantifier = .required },
11666 .{ .kind = .LiteralInteger, .quantifier = .required },12767 .{ .kind = .literal_integer, .quantifier = .required },
11667 .{ .kind = .LiteralInteger, .quantifier = .required },12768 .{ .kind = .literal_integer, .quantifier = .required },
11668 .{ .kind = .LiteralInteger, .quantifier = .required },12769 .{ .kind = .literal_integer, .quantifier = .required },
11669 .{ .kind = .LiteralInteger, .quantifier = .required },12770 .{ .kind = .literal_integer, .quantifier = .required },
11670 .{ .kind = .LiteralInteger, .quantifier = .required },12771 .{ .kind = .literal_integer, .quantifier = .required },
11671 },12772 },
11672 },12773 },
11673 .{12774 .{
11674 .name = "OpArbitraryFloatSubINTEL",12775 .name = "OpArbitraryFloatSubINTEL",
11675 .opcode = 5847,12776 .opcode = 5847,
11676 .operands = &[_]Operand{12777 .operands = &.{
11677 .{ .kind = .IdResultType, .quantifier = .required },12778 .{ .kind = .id_result_type, .quantifier = .required },
11678 .{ .kind = .IdResult, .quantifier = .required },12779 .{ .kind = .id_result, .quantifier = .required },
11679 .{ .kind = .IdRef, .quantifier = .required },12780 .{ .kind = .id_ref, .quantifier = .required },
11680 .{ .kind = .LiteralInteger, .quantifier = .required },12781 .{ .kind = .literal_integer, .quantifier = .required },
11681 .{ .kind = .IdRef, .quantifier = .required },12782 .{ .kind = .id_ref, .quantifier = .required },
11682 .{ .kind = .LiteralInteger, .quantifier = .required },12783 .{ .kind = .literal_integer, .quantifier = .required },
11683 .{ .kind = .LiteralInteger, .quantifier = .required },12784 .{ .kind = .literal_integer, .quantifier = .required },
11684 .{ .kind = .LiteralInteger, .quantifier = .required },12785 .{ .kind = .literal_integer, .quantifier = .required },
11685 .{ .kind = .LiteralInteger, .quantifier = .required },12786 .{ .kind = .literal_integer, .quantifier = .required },
11686 .{ .kind = .LiteralInteger, .quantifier = .required },12787 .{ .kind = .literal_integer, .quantifier = .required },
11687 },12788 },
11688 },12789 },
11689 .{12790 .{
11690 .name = "OpArbitraryFloatMulINTEL",12791 .name = "OpArbitraryFloatMulINTEL",
11691 .opcode = 5848,12792 .opcode = 5848,
11692 .operands = &[_]Operand{12793 .operands = &.{
11693 .{ .kind = .IdResultType, .quantifier = .required },12794 .{ .kind = .id_result_type, .quantifier = .required },
11694 .{ .kind = .IdResult, .quantifier = .required },12795 .{ .kind = .id_result, .quantifier = .required },
11695 .{ .kind = .IdRef, .quantifier = .required },12796 .{ .kind = .id_ref, .quantifier = .required },
11696 .{ .kind = .LiteralInteger, .quantifier = .required },12797 .{ .kind = .literal_integer, .quantifier = .required },
11697 .{ .kind = .IdRef, .quantifier = .required },12798 .{ .kind = .id_ref, .quantifier = .required },
11698 .{ .kind = .LiteralInteger, .quantifier = .required },12799 .{ .kind = .literal_integer, .quantifier = .required },
11699 .{ .kind = .LiteralInteger, .quantifier = .required },12800 .{ .kind = .literal_integer, .quantifier = .required },
11700 .{ .kind = .LiteralInteger, .quantifier = .required },12801 .{ .kind = .literal_integer, .quantifier = .required },
11701 .{ .kind = .LiteralInteger, .quantifier = .required },12802 .{ .kind = .literal_integer, .quantifier = .required },
11702 .{ .kind = .LiteralInteger, .quantifier = .required },12803 .{ .kind = .literal_integer, .quantifier = .required },
11703 },12804 },
11704 },12805 },
11705 .{12806 .{
11706 .name = "OpArbitraryFloatDivINTEL",12807 .name = "OpArbitraryFloatDivINTEL",
11707 .opcode = 5849,12808 .opcode = 5849,
11708 .operands = &[_]Operand{12809 .operands = &.{
11709 .{ .kind = .IdResultType, .quantifier = .required },12810 .{ .kind = .id_result_type, .quantifier = .required },
11710 .{ .kind = .IdResult, .quantifier = .required },12811 .{ .kind = .id_result, .quantifier = .required },
11711 .{ .kind = .IdRef, .quantifier = .required },12812 .{ .kind = .id_ref, .quantifier = .required },
11712 .{ .kind = .LiteralInteger, .quantifier = .required },12813 .{ .kind = .literal_integer, .quantifier = .required },
11713 .{ .kind = .IdRef, .quantifier = .required },12814 .{ .kind = .id_ref, .quantifier = .required },
11714 .{ .kind = .LiteralInteger, .quantifier = .required },12815 .{ .kind = .literal_integer, .quantifier = .required },
11715 .{ .kind = .LiteralInteger, .quantifier = .required },12816 .{ .kind = .literal_integer, .quantifier = .required },
11716 .{ .kind = .LiteralInteger, .quantifier = .required },12817 .{ .kind = .literal_integer, .quantifier = .required },
11717 .{ .kind = .LiteralInteger, .quantifier = .required },12818 .{ .kind = .literal_integer, .quantifier = .required },
11718 .{ .kind = .LiteralInteger, .quantifier = .required },12819 .{ .kind = .literal_integer, .quantifier = .required },
11719 },12820 },
11720 },12821 },
11721 .{12822 .{
11722 .name = "OpArbitraryFloatGTINTEL",12823 .name = "OpArbitraryFloatGTINTEL",
11723 .opcode = 5850,12824 .opcode = 5850,
11724 .operands = &[_]Operand{12825 .operands = &.{
11725 .{ .kind = .IdResultType, .quantifier = .required },12826 .{ .kind = .id_result_type, .quantifier = .required },
11726 .{ .kind = .IdResult, .quantifier = .required },12827 .{ .kind = .id_result, .quantifier = .required },
11727 .{ .kind = .IdRef, .quantifier = .required },12828 .{ .kind = .id_ref, .quantifier = .required },
11728 .{ .kind = .LiteralInteger, .quantifier = .required },12829 .{ .kind = .literal_integer, .quantifier = .required },
11729 .{ .kind = .IdRef, .quantifier = .required },12830 .{ .kind = .id_ref, .quantifier = .required },
11730 .{ .kind = .LiteralInteger, .quantifier = .required },12831 .{ .kind = .literal_integer, .quantifier = .required },
11731 },12832 },
11732 },12833 },
11733 .{12834 .{
11734 .name = "OpArbitraryFloatGEINTEL",12835 .name = "OpArbitraryFloatGEINTEL",
11735 .opcode = 5851,12836 .opcode = 5851,
11736 .operands = &[_]Operand{12837 .operands = &.{
11737 .{ .kind = .IdResultType, .quantifier = .required },12838 .{ .kind = .id_result_type, .quantifier = .required },
11738 .{ .kind = .IdResult, .quantifier = .required },12839 .{ .kind = .id_result, .quantifier = .required },
11739 .{ .kind = .IdRef, .quantifier = .required },12840 .{ .kind = .id_ref, .quantifier = .required },
11740 .{ .kind = .LiteralInteger, .quantifier = .required },12841 .{ .kind = .literal_integer, .quantifier = .required },
11741 .{ .kind = .IdRef, .quantifier = .required },12842 .{ .kind = .id_ref, .quantifier = .required },
11742 .{ .kind = .LiteralInteger, .quantifier = .required },12843 .{ .kind = .literal_integer, .quantifier = .required },
11743 },12844 },
11744 },12845 },
11745 .{12846 .{
11746 .name = "OpArbitraryFloatLTINTEL",12847 .name = "OpArbitraryFloatLTINTEL",
11747 .opcode = 5852,12848 .opcode = 5852,
11748 .operands = &[_]Operand{12849 .operands = &.{
11749 .{ .kind = .IdResultType, .quantifier = .required },12850 .{ .kind = .id_result_type, .quantifier = .required },
11750 .{ .kind = .IdResult, .quantifier = .required },12851 .{ .kind = .id_result, .quantifier = .required },
11751 .{ .kind = .IdRef, .quantifier = .required },12852 .{ .kind = .id_ref, .quantifier = .required },
11752 .{ .kind = .LiteralInteger, .quantifier = .required },12853 .{ .kind = .literal_integer, .quantifier = .required },
11753 .{ .kind = .IdRef, .quantifier = .required },12854 .{ .kind = .id_ref, .quantifier = .required },
11754 .{ .kind = .LiteralInteger, .quantifier = .required },12855 .{ .kind = .literal_integer, .quantifier = .required },
11755 },12856 },
11756 },12857 },
11757 .{12858 .{
11758 .name = "OpArbitraryFloatLEINTEL",12859 .name = "OpArbitraryFloatLEINTEL",
11759 .opcode = 5853,12860 .opcode = 5853,
11760 .operands = &[_]Operand{12861 .operands = &.{
11761 .{ .kind = .IdResultType, .quantifier = .required },12862 .{ .kind = .id_result_type, .quantifier = .required },
11762 .{ .kind = .IdResult, .quantifier = .required },12863 .{ .kind = .id_result, .quantifier = .required },
11763 .{ .kind = .IdRef, .quantifier = .required },12864 .{ .kind = .id_ref, .quantifier = .required },
11764 .{ .kind = .LiteralInteger, .quantifier = .required },12865 .{ .kind = .literal_integer, .quantifier = .required },
11765 .{ .kind = .IdRef, .quantifier = .required },12866 .{ .kind = .id_ref, .quantifier = .required },
11766 .{ .kind = .LiteralInteger, .quantifier = .required },12867 .{ .kind = .literal_integer, .quantifier = .required },
11767 },12868 },
11768 },12869 },
11769 .{12870 .{
11770 .name = "OpArbitraryFloatEQINTEL",12871 .name = "OpArbitraryFloatEQINTEL",
11771 .opcode = 5854,12872 .opcode = 5854,
11772 .operands = &[_]Operand{12873 .operands = &.{
11773 .{ .kind = .IdResultType, .quantifier = .required },12874 .{ .kind = .id_result_type, .quantifier = .required },
11774 .{ .kind = .IdResult, .quantifier = .required },12875 .{ .kind = .id_result, .quantifier = .required },
11775 .{ .kind = .IdRef, .quantifier = .required },12876 .{ .kind = .id_ref, .quantifier = .required },
11776 .{ .kind = .LiteralInteger, .quantifier = .required },12877 .{ .kind = .literal_integer, .quantifier = .required },
11777 .{ .kind = .IdRef, .quantifier = .required },12878 .{ .kind = .id_ref, .quantifier = .required },
11778 .{ .kind = .LiteralInteger, .quantifier = .required },12879 .{ .kind = .literal_integer, .quantifier = .required },
11779 },12880 },
11780 },12881 },
11781 .{12882 .{
11782 .name = "OpArbitraryFloatRecipINTEL",12883 .name = "OpArbitraryFloatRecipINTEL",
11783 .opcode = 5855,12884 .opcode = 5855,
11784 .operands = &[_]Operand{12885 .operands = &.{
11785 .{ .kind = .IdResultType, .quantifier = .required },12886 .{ .kind = .id_result_type, .quantifier = .required },
11786 .{ .kind = .IdResult, .quantifier = .required },12887 .{ .kind = .id_result, .quantifier = .required },
11787 .{ .kind = .IdRef, .quantifier = .required },12888 .{ .kind = .id_ref, .quantifier = .required },
11788 .{ .kind = .LiteralInteger, .quantifier = .required },12889 .{ .kind = .literal_integer, .quantifier = .required },
11789 .{ .kind = .LiteralInteger, .quantifier = .required },12890 .{ .kind = .literal_integer, .quantifier = .required },
11790 .{ .kind = .LiteralInteger, .quantifier = .required },12891 .{ .kind = .literal_integer, .quantifier = .required },
11791 .{ .kind = .LiteralInteger, .quantifier = .required },12892 .{ .kind = .literal_integer, .quantifier = .required },
11792 .{ .kind = .LiteralInteger, .quantifier = .required },12893 .{ .kind = .literal_integer, .quantifier = .required },
11793 },12894 },
11794 },12895 },
11795 .{12896 .{
11796 .name = "OpArbitraryFloatRSqrtINTEL",12897 .name = "OpArbitraryFloatRSqrtINTEL",
11797 .opcode = 5856,12898 .opcode = 5856,
11798 .operands = &[_]Operand{12899 .operands = &.{
11799 .{ .kind = .IdResultType, .quantifier = .required },12900 .{ .kind = .id_result_type, .quantifier = .required },
11800 .{ .kind = .IdResult, .quantifier = .required },12901 .{ .kind = .id_result, .quantifier = .required },
11801 .{ .kind = .IdRef, .quantifier = .required },12902 .{ .kind = .id_ref, .quantifier = .required },
11802 .{ .kind = .LiteralInteger, .quantifier = .required },12903 .{ .kind = .literal_integer, .quantifier = .required },
11803 .{ .kind = .LiteralInteger, .quantifier = .required },12904 .{ .kind = .literal_integer, .quantifier = .required },
11804 .{ .kind = .LiteralInteger, .quantifier = .required },12905 .{ .kind = .literal_integer, .quantifier = .required },
11805 .{ .kind = .LiteralInteger, .quantifier = .required },12906 .{ .kind = .literal_integer, .quantifier = .required },
11806 .{ .kind = .LiteralInteger, .quantifier = .required },12907 .{ .kind = .literal_integer, .quantifier = .required },
11807 },12908 },
11808 },12909 },
11809 .{12910 .{
11810 .name = "OpArbitraryFloatCbrtINTEL",12911 .name = "OpArbitraryFloatCbrtINTEL",
11811 .opcode = 5857,12912 .opcode = 5857,
11812 .operands = &[_]Operand{12913 .operands = &.{
11813 .{ .kind = .IdResultType, .quantifier = .required },12914 .{ .kind = .id_result_type, .quantifier = .required },
11814 .{ .kind = .IdResult, .quantifier = .required },12915 .{ .kind = .id_result, .quantifier = .required },
11815 .{ .kind = .IdRef, .quantifier = .required },12916 .{ .kind = .id_ref, .quantifier = .required },
11816 .{ .kind = .LiteralInteger, .quantifier = .required },12917 .{ .kind = .literal_integer, .quantifier = .required },
11817 .{ .kind = .LiteralInteger, .quantifier = .required },12918 .{ .kind = .literal_integer, .quantifier = .required },
11818 .{ .kind = .LiteralInteger, .quantifier = .required },12919 .{ .kind = .literal_integer, .quantifier = .required },
11819 .{ .kind = .LiteralInteger, .quantifier = .required },12920 .{ .kind = .literal_integer, .quantifier = .required },
11820 .{ .kind = .LiteralInteger, .quantifier = .required },12921 .{ .kind = .literal_integer, .quantifier = .required },
11821 },12922 },
11822 },12923 },
11823 .{12924 .{
11824 .name = "OpArbitraryFloatHypotINTEL",12925 .name = "OpArbitraryFloatHypotINTEL",
11825 .opcode = 5858,12926 .opcode = 5858,
11826 .operands = &[_]Operand{12927 .operands = &.{
11827 .{ .kind = .IdResultType, .quantifier = .required },12928 .{ .kind = .id_result_type, .quantifier = .required },
11828 .{ .kind = .IdResult, .quantifier = .required },12929 .{ .kind = .id_result, .quantifier = .required },
11829 .{ .kind = .IdRef, .quantifier = .required },12930 .{ .kind = .id_ref, .quantifier = .required },
11830 .{ .kind = .LiteralInteger, .quantifier = .required },12931 .{ .kind = .literal_integer, .quantifier = .required },
11831 .{ .kind = .IdRef, .quantifier = .required },12932 .{ .kind = .id_ref, .quantifier = .required },
11832 .{ .kind = .LiteralInteger, .quantifier = .required },12933 .{ .kind = .literal_integer, .quantifier = .required },
11833 .{ .kind = .LiteralInteger, .quantifier = .required },12934 .{ .kind = .literal_integer, .quantifier = .required },
11834 .{ .kind = .LiteralInteger, .quantifier = .required },12935 .{ .kind = .literal_integer, .quantifier = .required },
11835 .{ .kind = .LiteralInteger, .quantifier = .required },12936 .{ .kind = .literal_integer, .quantifier = .required },
11836 .{ .kind = .LiteralInteger, .quantifier = .required },12937 .{ .kind = .literal_integer, .quantifier = .required },
11837 },12938 },
11838 },12939 },
11839 .{12940 .{
11840 .name = "OpArbitraryFloatSqrtINTEL",12941 .name = "OpArbitraryFloatSqrtINTEL",
11841 .opcode = 5859,12942 .opcode = 5859,
11842 .operands = &[_]Operand{12943 .operands = &.{
11843 .{ .kind = .IdResultType, .quantifier = .required },12944 .{ .kind = .id_result_type, .quantifier = .required },
11844 .{ .kind = .IdResult, .quantifier = .required },12945 .{ .kind = .id_result, .quantifier = .required },
11845 .{ .kind = .IdRef, .quantifier = .required },12946 .{ .kind = .id_ref, .quantifier = .required },
11846 .{ .kind = .LiteralInteger, .quantifier = .required },12947 .{ .kind = .literal_integer, .quantifier = .required },
11847 .{ .kind = .LiteralInteger, .quantifier = .required },12948 .{ .kind = .literal_integer, .quantifier = .required },
11848 .{ .kind = .LiteralInteger, .quantifier = .required },12949 .{ .kind = .literal_integer, .quantifier = .required },
11849 .{ .kind = .LiteralInteger, .quantifier = .required },12950 .{ .kind = .literal_integer, .quantifier = .required },
11850 .{ .kind = .LiteralInteger, .quantifier = .required },12951 .{ .kind = .literal_integer, .quantifier = .required },
11851 },12952 },
11852 },12953 },
11853 .{12954 .{
11854 .name = "OpArbitraryFloatLogINTEL",12955 .name = "OpArbitraryFloatLogINTEL",
11855 .opcode = 5860,12956 .opcode = 5860,
11856 .operands = &[_]Operand{12957 .operands = &.{
11857 .{ .kind = .IdResultType, .quantifier = .required },12958 .{ .kind = .id_result_type, .quantifier = .required },
11858 .{ .kind = .IdResult, .quantifier = .required },12959 .{ .kind = .id_result, .quantifier = .required },
11859 .{ .kind = .IdRef, .quantifier = .required },12960 .{ .kind = .id_ref, .quantifier = .required },
11860 .{ .kind = .LiteralInteger, .quantifier = .required },12961 .{ .kind = .literal_integer, .quantifier = .required },
11861 .{ .kind = .LiteralInteger, .quantifier = .required },12962 .{ .kind = .literal_integer, .quantifier = .required },
11862 .{ .kind = .LiteralInteger, .quantifier = .required },12963 .{ .kind = .literal_integer, .quantifier = .required },
11863 .{ .kind = .LiteralInteger, .quantifier = .required },12964 .{ .kind = .literal_integer, .quantifier = .required },
11864 .{ .kind = .LiteralInteger, .quantifier = .required },12965 .{ .kind = .literal_integer, .quantifier = .required },
11865 },12966 },
11866 },12967 },
11867 .{12968 .{
11868 .name = "OpArbitraryFloatLog2INTEL",12969 .name = "OpArbitraryFloatLog2INTEL",
11869 .opcode = 5861,12970 .opcode = 5861,
11870 .operands = &[_]Operand{12971 .operands = &.{
11871 .{ .kind = .IdResultType, .quantifier = .required },12972 .{ .kind = .id_result_type, .quantifier = .required },
11872 .{ .kind = .IdResult, .quantifier = .required },12973 .{ .kind = .id_result, .quantifier = .required },
11873 .{ .kind = .IdRef, .quantifier = .required },12974 .{ .kind = .id_ref, .quantifier = .required },
11874 .{ .kind = .LiteralInteger, .quantifier = .required },12975 .{ .kind = .literal_integer, .quantifier = .required },
11875 .{ .kind = .LiteralInteger, .quantifier = .required },12976 .{ .kind = .literal_integer, .quantifier = .required },
11876 .{ .kind = .LiteralInteger, .quantifier = .required },12977 .{ .kind = .literal_integer, .quantifier = .required },
11877 .{ .kind = .LiteralInteger, .quantifier = .required },12978 .{ .kind = .literal_integer, .quantifier = .required },
11878 .{ .kind = .LiteralInteger, .quantifier = .required },12979 .{ .kind = .literal_integer, .quantifier = .required },
11879 },12980 },
11880 },12981 },
11881 .{12982 .{
11882 .name = "OpArbitraryFloatLog10INTEL",12983 .name = "OpArbitraryFloatLog10INTEL",
11883 .opcode = 5862,12984 .opcode = 5862,
11884 .operands = &[_]Operand{12985 .operands = &.{
11885 .{ .kind = .IdResultType, .quantifier = .required },12986 .{ .kind = .id_result_type, .quantifier = .required },
11886 .{ .kind = .IdResult, .quantifier = .required },12987 .{ .kind = .id_result, .quantifier = .required },
11887 .{ .kind = .IdRef, .quantifier = .required },12988 .{ .kind = .id_ref, .quantifier = .required },
11888 .{ .kind = .LiteralInteger, .quantifier = .required },12989 .{ .kind = .literal_integer, .quantifier = .required },
11889 .{ .kind = .LiteralInteger, .quantifier = .required },12990 .{ .kind = .literal_integer, .quantifier = .required },
11890 .{ .kind = .LiteralInteger, .quantifier = .required },12991 .{ .kind = .literal_integer, .quantifier = .required },
11891 .{ .kind = .LiteralInteger, .quantifier = .required },12992 .{ .kind = .literal_integer, .quantifier = .required },
11892 .{ .kind = .LiteralInteger, .quantifier = .required },12993 .{ .kind = .literal_integer, .quantifier = .required },
11893 },12994 },
11894 },12995 },
11895 .{12996 .{
11896 .name = "OpArbitraryFloatLog1pINTEL",12997 .name = "OpArbitraryFloatLog1pINTEL",
11897 .opcode = 5863,12998 .opcode = 5863,
11898 .operands = &[_]Operand{12999 .operands = &.{
11899 .{ .kind = .IdResultType, .quantifier = .required },13000 .{ .kind = .id_result_type, .quantifier = .required },
11900 .{ .kind = .IdResult, .quantifier = .required },13001 .{ .kind = .id_result, .quantifier = .required },
11901 .{ .kind = .IdRef, .quantifier = .required },13002 .{ .kind = .id_ref, .quantifier = .required },
11902 .{ .kind = .LiteralInteger, .quantifier = .required },13003 .{ .kind = .literal_integer, .quantifier = .required },
11903 .{ .kind = .LiteralInteger, .quantifier = .required },13004 .{ .kind = .literal_integer, .quantifier = .required },
11904 .{ .kind = .LiteralInteger, .quantifier = .required },13005 .{ .kind = .literal_integer, .quantifier = .required },
11905 .{ .kind = .LiteralInteger, .quantifier = .required },13006 .{ .kind = .literal_integer, .quantifier = .required },
11906 .{ .kind = .LiteralInteger, .quantifier = .required },13007 .{ .kind = .literal_integer, .quantifier = .required },
11907 },13008 },
11908 },13009 },
11909 .{13010 .{
11910 .name = "OpArbitraryFloatExpINTEL",13011 .name = "OpArbitraryFloatExpINTEL",
11911 .opcode = 5864,13012 .opcode = 5864,
11912 .operands = &[_]Operand{13013 .operands = &.{
11913 .{ .kind = .IdResultType, .quantifier = .required },13014 .{ .kind = .id_result_type, .quantifier = .required },
11914 .{ .kind = .IdResult, .quantifier = .required },13015 .{ .kind = .id_result, .quantifier = .required },
11915 .{ .kind = .IdRef, .quantifier = .required },13016 .{ .kind = .id_ref, .quantifier = .required },
11916 .{ .kind = .LiteralInteger, .quantifier = .required },13017 .{ .kind = .literal_integer, .quantifier = .required },
11917 .{ .kind = .LiteralInteger, .quantifier = .required },13018 .{ .kind = .literal_integer, .quantifier = .required },
11918 .{ .kind = .LiteralInteger, .quantifier = .required },13019 .{ .kind = .literal_integer, .quantifier = .required },
11919 .{ .kind = .LiteralInteger, .quantifier = .required },13020 .{ .kind = .literal_integer, .quantifier = .required },
11920 .{ .kind = .LiteralInteger, .quantifier = .required },13021 .{ .kind = .literal_integer, .quantifier = .required },
11921 },13022 },
11922 },13023 },
11923 .{13024 .{
11924 .name = "OpArbitraryFloatExp2INTEL",13025 .name = "OpArbitraryFloatExp2INTEL",
11925 .opcode = 5865,13026 .opcode = 5865,
11926 .operands = &[_]Operand{13027 .operands = &.{
11927 .{ .kind = .IdResultType, .quantifier = .required },13028 .{ .kind = .id_result_type, .quantifier = .required },
11928 .{ .kind = .IdResult, .quantifier = .required },13029 .{ .kind = .id_result, .quantifier = .required },
11929 .{ .kind = .IdRef, .quantifier = .required },13030 .{ .kind = .id_ref, .quantifier = .required },
11930 .{ .kind = .LiteralInteger, .quantifier = .required },13031 .{ .kind = .literal_integer, .quantifier = .required },
11931 .{ .kind = .LiteralInteger, .quantifier = .required },13032 .{ .kind = .literal_integer, .quantifier = .required },
11932 .{ .kind = .LiteralInteger, .quantifier = .required },13033 .{ .kind = .literal_integer, .quantifier = .required },
11933 .{ .kind = .LiteralInteger, .quantifier = .required },13034 .{ .kind = .literal_integer, .quantifier = .required },
11934 .{ .kind = .LiteralInteger, .quantifier = .required },13035 .{ .kind = .literal_integer, .quantifier = .required },
11935 },13036 },
11936 },13037 },
11937 .{13038 .{
11938 .name = "OpArbitraryFloatExp10INTEL",13039 .name = "OpArbitraryFloatExp10INTEL",
11939 .opcode = 5866,13040 .opcode = 5866,
11940 .operands = &[_]Operand{13041 .operands = &.{
11941 .{ .kind = .IdResultType, .quantifier = .required },13042 .{ .kind = .id_result_type, .quantifier = .required },
11942 .{ .kind = .IdResult, .quantifier = .required },13043 .{ .kind = .id_result, .quantifier = .required },
11943 .{ .kind = .IdRef, .quantifier = .required },13044 .{ .kind = .id_ref, .quantifier = .required },
11944 .{ .kind = .LiteralInteger, .quantifier = .required },13045 .{ .kind = .literal_integer, .quantifier = .required },
11945 .{ .kind = .LiteralInteger, .quantifier = .required },13046 .{ .kind = .literal_integer, .quantifier = .required },
11946 .{ .kind = .LiteralInteger, .quantifier = .required },13047 .{ .kind = .literal_integer, .quantifier = .required },
11947 .{ .kind = .LiteralInteger, .quantifier = .required },13048 .{ .kind = .literal_integer, .quantifier = .required },
11948 .{ .kind = .LiteralInteger, .quantifier = .required },13049 .{ .kind = .literal_integer, .quantifier = .required },
11949 },13050 },
11950 },13051 },
11951 .{13052 .{
11952 .name = "OpArbitraryFloatExpm1INTEL",13053 .name = "OpArbitraryFloatExpm1INTEL",
11953 .opcode = 5867,13054 .opcode = 5867,
11954 .operands = &[_]Operand{13055 .operands = &.{
11955 .{ .kind = .IdResultType, .quantifier = .required },13056 .{ .kind = .id_result_type, .quantifier = .required },
11956 .{ .kind = .IdResult, .quantifier = .required },13057 .{ .kind = .id_result, .quantifier = .required },
11957 .{ .kind = .IdRef, .quantifier = .required },13058 .{ .kind = .id_ref, .quantifier = .required },
11958 .{ .kind = .LiteralInteger, .quantifier = .required },13059 .{ .kind = .literal_integer, .quantifier = .required },
11959 .{ .kind = .LiteralInteger, .quantifier = .required },13060 .{ .kind = .literal_integer, .quantifier = .required },
11960 .{ .kind = .LiteralInteger, .quantifier = .required },13061 .{ .kind = .literal_integer, .quantifier = .required },
11961 .{ .kind = .LiteralInteger, .quantifier = .required },13062 .{ .kind = .literal_integer, .quantifier = .required },
11962 .{ .kind = .LiteralInteger, .quantifier = .required },13063 .{ .kind = .literal_integer, .quantifier = .required },
11963 },13064 },
11964 },13065 },
11965 .{13066 .{
11966 .name = "OpArbitraryFloatSinINTEL",13067 .name = "OpArbitraryFloatSinINTEL",
11967 .opcode = 5868,13068 .opcode = 5868,
11968 .operands = &[_]Operand{13069 .operands = &.{
11969 .{ .kind = .IdResultType, .quantifier = .required },13070 .{ .kind = .id_result_type, .quantifier = .required },
11970 .{ .kind = .IdResult, .quantifier = .required },13071 .{ .kind = .id_result, .quantifier = .required },
11971 .{ .kind = .IdRef, .quantifier = .required },13072 .{ .kind = .id_ref, .quantifier = .required },
11972 .{ .kind = .LiteralInteger, .quantifier = .required },13073 .{ .kind = .literal_integer, .quantifier = .required },
11973 .{ .kind = .LiteralInteger, .quantifier = .required },13074 .{ .kind = .literal_integer, .quantifier = .required },
11974 .{ .kind = .LiteralInteger, .quantifier = .required },13075 .{ .kind = .literal_integer, .quantifier = .required },
11975 .{ .kind = .LiteralInteger, .quantifier = .required },13076 .{ .kind = .literal_integer, .quantifier = .required },
11976 .{ .kind = .LiteralInteger, .quantifier = .required },13077 .{ .kind = .literal_integer, .quantifier = .required },
11977 },13078 },
11978 },13079 },
11979 .{13080 .{
11980 .name = "OpArbitraryFloatCosINTEL",13081 .name = "OpArbitraryFloatCosINTEL",
11981 .opcode = 5869,13082 .opcode = 5869,
11982 .operands = &[_]Operand{13083 .operands = &.{
11983 .{ .kind = .IdResultType, .quantifier = .required },13084 .{ .kind = .id_result_type, .quantifier = .required },
11984 .{ .kind = .IdResult, .quantifier = .required },13085 .{ .kind = .id_result, .quantifier = .required },
11985 .{ .kind = .IdRef, .quantifier = .required },13086 .{ .kind = .id_ref, .quantifier = .required },
11986 .{ .kind = .LiteralInteger, .quantifier = .required },13087 .{ .kind = .literal_integer, .quantifier = .required },
11987 .{ .kind = .LiteralInteger, .quantifier = .required },13088 .{ .kind = .literal_integer, .quantifier = .required },
11988 .{ .kind = .LiteralInteger, .quantifier = .required },13089 .{ .kind = .literal_integer, .quantifier = .required },
11989 .{ .kind = .LiteralInteger, .quantifier = .required },13090 .{ .kind = .literal_integer, .quantifier = .required },
11990 .{ .kind = .LiteralInteger, .quantifier = .required },13091 .{ .kind = .literal_integer, .quantifier = .required },
11991 },13092 },
11992 },13093 },
11993 .{13094 .{
11994 .name = "OpArbitraryFloatSinCosINTEL",13095 .name = "OpArbitraryFloatSinCosINTEL",
11995 .opcode = 5870,13096 .opcode = 5870,
11996 .operands = &[_]Operand{13097 .operands = &.{
11997 .{ .kind = .IdResultType, .quantifier = .required },13098 .{ .kind = .id_result_type, .quantifier = .required },
11998 .{ .kind = .IdResult, .quantifier = .required },13099 .{ .kind = .id_result, .quantifier = .required },
11999 .{ .kind = .IdRef, .quantifier = .required },13100 .{ .kind = .id_ref, .quantifier = .required },
12000 .{ .kind = .LiteralInteger, .quantifier = .required },13101 .{ .kind = .literal_integer, .quantifier = .required },
12001 .{ .kind = .LiteralInteger, .quantifier = .required },13102 .{ .kind = .literal_integer, .quantifier = .required },
12002 .{ .kind = .LiteralInteger, .quantifier = .required },13103 .{ .kind = .literal_integer, .quantifier = .required },
12003 .{ .kind = .LiteralInteger, .quantifier = .required },13104 .{ .kind = .literal_integer, .quantifier = .required },
12004 .{ .kind = .LiteralInteger, .quantifier = .required },13105 .{ .kind = .literal_integer, .quantifier = .required },
12005 },13106 },
12006 },13107 },
12007 .{13108 .{
12008 .name = "OpArbitraryFloatSinPiINTEL",13109 .name = "OpArbitraryFloatSinPiINTEL",
12009 .opcode = 5871,13110 .opcode = 5871,
12010 .operands = &[_]Operand{13111 .operands = &.{
12011 .{ .kind = .IdResultType, .quantifier = .required },13112 .{ .kind = .id_result_type, .quantifier = .required },
12012 .{ .kind = .IdResult, .quantifier = .required },13113 .{ .kind = .id_result, .quantifier = .required },
12013 .{ .kind = .IdRef, .quantifier = .required },13114 .{ .kind = .id_ref, .quantifier = .required },
12014 .{ .kind = .LiteralInteger, .quantifier = .required },13115 .{ .kind = .literal_integer, .quantifier = .required },
12015 .{ .kind = .LiteralInteger, .quantifier = .required },13116 .{ .kind = .literal_integer, .quantifier = .required },
12016 .{ .kind = .LiteralInteger, .quantifier = .required },13117 .{ .kind = .literal_integer, .quantifier = .required },
12017 .{ .kind = .LiteralInteger, .quantifier = .required },13118 .{ .kind = .literal_integer, .quantifier = .required },
12018 .{ .kind = .LiteralInteger, .quantifier = .required },13119 .{ .kind = .literal_integer, .quantifier = .required },
12019 },13120 },
12020 },13121 },
12021 .{13122 .{
12022 .name = "OpArbitraryFloatCosPiINTEL",13123 .name = "OpArbitraryFloatCosPiINTEL",
12023 .opcode = 5872,13124 .opcode = 5872,
12024 .operands = &[_]Operand{13125 .operands = &.{
12025 .{ .kind = .IdResultType, .quantifier = .required },13126 .{ .kind = .id_result_type, .quantifier = .required },
12026 .{ .kind = .IdResult, .quantifier = .required },13127 .{ .kind = .id_result, .quantifier = .required },
12027 .{ .kind = .IdRef, .quantifier = .required },13128 .{ .kind = .id_ref, .quantifier = .required },
12028 .{ .kind = .LiteralInteger, .quantifier = .required },13129 .{ .kind = .literal_integer, .quantifier = .required },
12029 .{ .kind = .LiteralInteger, .quantifier = .required },13130 .{ .kind = .literal_integer, .quantifier = .required },
12030 .{ .kind = .LiteralInteger, .quantifier = .required },13131 .{ .kind = .literal_integer, .quantifier = .required },
12031 .{ .kind = .LiteralInteger, .quantifier = .required },13132 .{ .kind = .literal_integer, .quantifier = .required },
12032 .{ .kind = .LiteralInteger, .quantifier = .required },13133 .{ .kind = .literal_integer, .quantifier = .required },
12033 },13134 },
12034 },13135 },
12035 .{13136 .{
12036 .name = "OpArbitraryFloatASinINTEL",13137 .name = "OpArbitraryFloatASinINTEL",
12037 .opcode = 5873,13138 .opcode = 5873,
12038 .operands = &[_]Operand{13139 .operands = &.{
12039 .{ .kind = .IdResultType, .quantifier = .required },13140 .{ .kind = .id_result_type, .quantifier = .required },
12040 .{ .kind = .IdResult, .quantifier = .required },13141 .{ .kind = .id_result, .quantifier = .required },
12041 .{ .kind = .IdRef, .quantifier = .required },13142 .{ .kind = .id_ref, .quantifier = .required },
12042 .{ .kind = .LiteralInteger, .quantifier = .required },13143 .{ .kind = .literal_integer, .quantifier = .required },
12043 .{ .kind = .LiteralInteger, .quantifier = .required },13144 .{ .kind = .literal_integer, .quantifier = .required },
12044 .{ .kind = .LiteralInteger, .quantifier = .required },13145 .{ .kind = .literal_integer, .quantifier = .required },
12045 .{ .kind = .LiteralInteger, .quantifier = .required },13146 .{ .kind = .literal_integer, .quantifier = .required },
12046 .{ .kind = .LiteralInteger, .quantifier = .required },13147 .{ .kind = .literal_integer, .quantifier = .required },
12047 },13148 },
12048 },13149 },
12049 .{13150 .{
12050 .name = "OpArbitraryFloatASinPiINTEL",13151 .name = "OpArbitraryFloatASinPiINTEL",
12051 .opcode = 5874,13152 .opcode = 5874,
12052 .operands = &[_]Operand{13153 .operands = &.{
12053 .{ .kind = .IdResultType, .quantifier = .required },13154 .{ .kind = .id_result_type, .quantifier = .required },
12054 .{ .kind = .IdResult, .quantifier = .required },13155 .{ .kind = .id_result, .quantifier = .required },
12055 .{ .kind = .IdRef, .quantifier = .required },13156 .{ .kind = .id_ref, .quantifier = .required },
12056 .{ .kind = .LiteralInteger, .quantifier = .required },13157 .{ .kind = .literal_integer, .quantifier = .required },
12057 .{ .kind = .LiteralInteger, .quantifier = .required },13158 .{ .kind = .literal_integer, .quantifier = .required },
12058 .{ .kind = .LiteralInteger, .quantifier = .required },13159 .{ .kind = .literal_integer, .quantifier = .required },
12059 .{ .kind = .LiteralInteger, .quantifier = .required },13160 .{ .kind = .literal_integer, .quantifier = .required },
12060 .{ .kind = .LiteralInteger, .quantifier = .required },13161 .{ .kind = .literal_integer, .quantifier = .required },
12061 },13162 },
12062 },13163 },
12063 .{13164 .{
12064 .name = "OpArbitraryFloatACosINTEL",13165 .name = "OpArbitraryFloatACosINTEL",
12065 .opcode = 5875,13166 .opcode = 5875,
12066 .operands = &[_]Operand{13167 .operands = &.{
12067 .{ .kind = .IdResultType, .quantifier = .required },13168 .{ .kind = .id_result_type, .quantifier = .required },
12068 .{ .kind = .IdResult, .quantifier = .required },13169 .{ .kind = .id_result, .quantifier = .required },
12069 .{ .kind = .IdRef, .quantifier = .required },13170 .{ .kind = .id_ref, .quantifier = .required },
12070 .{ .kind = .LiteralInteger, .quantifier = .required },13171 .{ .kind = .literal_integer, .quantifier = .required },
12071 .{ .kind = .LiteralInteger, .quantifier = .required },13172 .{ .kind = .literal_integer, .quantifier = .required },
12072 .{ .kind = .LiteralInteger, .quantifier = .required },13173 .{ .kind = .literal_integer, .quantifier = .required },
12073 .{ .kind = .LiteralInteger, .quantifier = .required },13174 .{ .kind = .literal_integer, .quantifier = .required },
12074 .{ .kind = .LiteralInteger, .quantifier = .required },13175 .{ .kind = .literal_integer, .quantifier = .required },
12075 },13176 },
12076 },13177 },
12077 .{13178 .{
12078 .name = "OpArbitraryFloatACosPiINTEL",13179 .name = "OpArbitraryFloatACosPiINTEL",
12079 .opcode = 5876,13180 .opcode = 5876,
12080 .operands = &[_]Operand{13181 .operands = &.{
12081 .{ .kind = .IdResultType, .quantifier = .required },13182 .{ .kind = .id_result_type, .quantifier = .required },
12082 .{ .kind = .IdResult, .quantifier = .required },13183 .{ .kind = .id_result, .quantifier = .required },
12083 .{ .kind = .IdRef, .quantifier = .required },13184 .{ .kind = .id_ref, .quantifier = .required },
12084 .{ .kind = .LiteralInteger, .quantifier = .required },13185 .{ .kind = .literal_integer, .quantifier = .required },
12085 .{ .kind = .LiteralInteger, .quantifier = .required },13186 .{ .kind = .literal_integer, .quantifier = .required },
12086 .{ .kind = .LiteralInteger, .quantifier = .required },13187 .{ .kind = .literal_integer, .quantifier = .required },
12087 .{ .kind = .LiteralInteger, .quantifier = .required },13188 .{ .kind = .literal_integer, .quantifier = .required },
12088 .{ .kind = .LiteralInteger, .quantifier = .required },13189 .{ .kind = .literal_integer, .quantifier = .required },
12089 },13190 },
12090 },13191 },
12091 .{13192 .{
12092 .name = "OpArbitraryFloatATanINTEL",13193 .name = "OpArbitraryFloatATanINTEL",
12093 .opcode = 5877,13194 .opcode = 5877,
12094 .operands = &[_]Operand{13195 .operands = &.{
12095 .{ .kind = .IdResultType, .quantifier = .required },13196 .{ .kind = .id_result_type, .quantifier = .required },
12096 .{ .kind = .IdResult, .quantifier = .required },13197 .{ .kind = .id_result, .quantifier = .required },
12097 .{ .kind = .IdRef, .quantifier = .required },13198 .{ .kind = .id_ref, .quantifier = .required },
12098 .{ .kind = .LiteralInteger, .quantifier = .required },13199 .{ .kind = .literal_integer, .quantifier = .required },
12099 .{ .kind = .LiteralInteger, .quantifier = .required },13200 .{ .kind = .literal_integer, .quantifier = .required },
12100 .{ .kind = .LiteralInteger, .quantifier = .required },13201 .{ .kind = .literal_integer, .quantifier = .required },
12101 .{ .kind = .LiteralInteger, .quantifier = .required },13202 .{ .kind = .literal_integer, .quantifier = .required },
12102 .{ .kind = .LiteralInteger, .quantifier = .required },13203 .{ .kind = .literal_integer, .quantifier = .required },
12103 },13204 },
12104 },13205 },
12105 .{13206 .{
12106 .name = "OpArbitraryFloatATanPiINTEL",13207 .name = "OpArbitraryFloatATanPiINTEL",
12107 .opcode = 5878,13208 .opcode = 5878,
12108 .operands = &[_]Operand{13209 .operands = &.{
12109 .{ .kind = .IdResultType, .quantifier = .required },13210 .{ .kind = .id_result_type, .quantifier = .required },
12110 .{ .kind = .IdResult, .quantifier = .required },13211 .{ .kind = .id_result, .quantifier = .required },
12111 .{ .kind = .IdRef, .quantifier = .required },13212 .{ .kind = .id_ref, .quantifier = .required },
12112 .{ .kind = .LiteralInteger, .quantifier = .required },13213 .{ .kind = .literal_integer, .quantifier = .required },
12113 .{ .kind = .LiteralInteger, .quantifier = .required },13214 .{ .kind = .literal_integer, .quantifier = .required },
12114 .{ .kind = .LiteralInteger, .quantifier = .required },13215 .{ .kind = .literal_integer, .quantifier = .required },
12115 .{ .kind = .LiteralInteger, .quantifier = .required },13216 .{ .kind = .literal_integer, .quantifier = .required },
12116 .{ .kind = .LiteralInteger, .quantifier = .required },13217 .{ .kind = .literal_integer, .quantifier = .required },
12117 },13218 },
12118 },13219 },
12119 .{13220 .{
12120 .name = "OpArbitraryFloatATan2INTEL",13221 .name = "OpArbitraryFloatATan2INTEL",
12121 .opcode = 5879,13222 .opcode = 5879,
12122 .operands = &[_]Operand{13223 .operands = &.{
12123 .{ .kind = .IdResultType, .quantifier = .required },13224 .{ .kind = .id_result_type, .quantifier = .required },
12124 .{ .kind = .IdResult, .quantifier = .required },13225 .{ .kind = .id_result, .quantifier = .required },
12125 .{ .kind = .IdRef, .quantifier = .required },13226 .{ .kind = .id_ref, .quantifier = .required },
12126 .{ .kind = .LiteralInteger, .quantifier = .required },13227 .{ .kind = .literal_integer, .quantifier = .required },
12127 .{ .kind = .IdRef, .quantifier = .required },13228 .{ .kind = .id_ref, .quantifier = .required },
12128 .{ .kind = .LiteralInteger, .quantifier = .required },13229 .{ .kind = .literal_integer, .quantifier = .required },
12129 .{ .kind = .LiteralInteger, .quantifier = .required },13230 .{ .kind = .literal_integer, .quantifier = .required },
12130 .{ .kind = .LiteralInteger, .quantifier = .required },13231 .{ .kind = .literal_integer, .quantifier = .required },
12131 .{ .kind = .LiteralInteger, .quantifier = .required },13232 .{ .kind = .literal_integer, .quantifier = .required },
12132 .{ .kind = .LiteralInteger, .quantifier = .required },13233 .{ .kind = .literal_integer, .quantifier = .required },
12133 },13234 },
12134 },13235 },
12135 .{13236 .{
12136 .name = "OpArbitraryFloatPowINTEL",13237 .name = "OpArbitraryFloatPowINTEL",
12137 .opcode = 5880,13238 .opcode = 5880,
12138 .operands = &[_]Operand{13239 .operands = &.{
12139 .{ .kind = .IdResultType, .quantifier = .required },13240 .{ .kind = .id_result_type, .quantifier = .required },
12140 .{ .kind = .IdResult, .quantifier = .required },13241 .{ .kind = .id_result, .quantifier = .required },
12141 .{ .kind = .IdRef, .quantifier = .required },13242 .{ .kind = .id_ref, .quantifier = .required },
12142 .{ .kind = .LiteralInteger, .quantifier = .required },13243 .{ .kind = .literal_integer, .quantifier = .required },
12143 .{ .kind = .IdRef, .quantifier = .required },13244 .{ .kind = .id_ref, .quantifier = .required },
12144 .{ .kind = .LiteralInteger, .quantifier = .required },13245 .{ .kind = .literal_integer, .quantifier = .required },
12145 .{ .kind = .LiteralInteger, .quantifier = .required },13246 .{ .kind = .literal_integer, .quantifier = .required },
12146 .{ .kind = .LiteralInteger, .quantifier = .required },13247 .{ .kind = .literal_integer, .quantifier = .required },
12147 .{ .kind = .LiteralInteger, .quantifier = .required },13248 .{ .kind = .literal_integer, .quantifier = .required },
12148 .{ .kind = .LiteralInteger, .quantifier = .required },13249 .{ .kind = .literal_integer, .quantifier = .required },
12149 },13250 },
12150 },13251 },
12151 .{13252 .{
12152 .name = "OpArbitraryFloatPowRINTEL",13253 .name = "OpArbitraryFloatPowRINTEL",
12153 .opcode = 5881,13254 .opcode = 5881,
12154 .operands = &[_]Operand{13255 .operands = &.{
12155 .{ .kind = .IdResultType, .quantifier = .required },13256 .{ .kind = .id_result_type, .quantifier = .required },
12156 .{ .kind = .IdResult, .quantifier = .required },13257 .{ .kind = .id_result, .quantifier = .required },
12157 .{ .kind = .IdRef, .quantifier = .required },13258 .{ .kind = .id_ref, .quantifier = .required },
12158 .{ .kind = .LiteralInteger, .quantifier = .required },13259 .{ .kind = .literal_integer, .quantifier = .required },
12159 .{ .kind = .IdRef, .quantifier = .required },13260 .{ .kind = .id_ref, .quantifier = .required },
12160 .{ .kind = .LiteralInteger, .quantifier = .required },13261 .{ .kind = .literal_integer, .quantifier = .required },
12161 .{ .kind = .LiteralInteger, .quantifier = .required },13262 .{ .kind = .literal_integer, .quantifier = .required },
12162 .{ .kind = .LiteralInteger, .quantifier = .required },13263 .{ .kind = .literal_integer, .quantifier = .required },
12163 .{ .kind = .LiteralInteger, .quantifier = .required },13264 .{ .kind = .literal_integer, .quantifier = .required },
12164 .{ .kind = .LiteralInteger, .quantifier = .required },13265 .{ .kind = .literal_integer, .quantifier = .required },
12165 },13266 },
12166 },13267 },
12167 .{13268 .{
12168 .name = "OpArbitraryFloatPowNINTEL",13269 .name = "OpArbitraryFloatPowNINTEL",
12169 .opcode = 5882,13270 .opcode = 5882,
12170 .operands = &[_]Operand{13271 .operands = &.{
12171 .{ .kind = .IdResultType, .quantifier = .required },13272 .{ .kind = .id_result_type, .quantifier = .required },
12172 .{ .kind = .IdResult, .quantifier = .required },13273 .{ .kind = .id_result, .quantifier = .required },
12173 .{ .kind = .IdRef, .quantifier = .required },13274 .{ .kind = .id_ref, .quantifier = .required },
12174 .{ .kind = .LiteralInteger, .quantifier = .required },13275 .{ .kind = .literal_integer, .quantifier = .required },
12175 .{ .kind = .IdRef, .quantifier = .required },13276 .{ .kind = .id_ref, .quantifier = .required },
12176 .{ .kind = .LiteralInteger, .quantifier = .required },13277 .{ .kind = .literal_integer, .quantifier = .required },
12177 .{ .kind = .LiteralInteger, .quantifier = .required },13278 .{ .kind = .literal_integer, .quantifier = .required },
12178 .{ .kind = .LiteralInteger, .quantifier = .required },13279 .{ .kind = .literal_integer, .quantifier = .required },
12179 .{ .kind = .LiteralInteger, .quantifier = .required },13280 .{ .kind = .literal_integer, .quantifier = .required },
13281 .{ .kind = .literal_integer, .quantifier = .required },
12180 },13282 },
12181 },13283 },
12182 .{13284 .{
12183 .name = "OpLoopControlINTEL",13285 .name = "OpLoopControlINTEL",
12184 .opcode = 5887,13286 .opcode = 5887,
12185 .operands = &[_]Operand{13287 .operands = &.{
12186 .{ .kind = .LiteralInteger, .quantifier = .variadic },13288 .{ .kind = .literal_integer, .quantifier = .variadic },
12187 },13289 },
12188 },13290 },
12189 .{13291 .{
12190 .name = "OpAliasDomainDeclINTEL",13292 .name = "OpAliasDomainDeclINTEL",
12191 .opcode = 5911,13293 .opcode = 5911,
12192 .operands = &[_]Operand{13294 .operands = &.{
12193 .{ .kind = .IdResult, .quantifier = .required },13295 .{ .kind = .id_result, .quantifier = .required },
12194 .{ .kind = .IdRef, .quantifier = .optional },13296 .{ .kind = .id_ref, .quantifier = .optional },
12195 },13297 },
12196 },13298 },
12197 .{13299 .{
12198 .name = "OpAliasScopeDeclINTEL",13300 .name = "OpAliasScopeDeclINTEL",
12199 .opcode = 5912,13301 .opcode = 5912,
12200 .operands = &[_]Operand{13302 .operands = &.{
12201 .{ .kind = .IdResult, .quantifier = .required },13303 .{ .kind = .id_result, .quantifier = .required },
12202 .{ .kind = .IdRef, .quantifier = .required },13304 .{ .kind = .id_ref, .quantifier = .required },
12203 .{ .kind = .IdRef, .quantifier = .optional },13305 .{ .kind = .id_ref, .quantifier = .optional },
12204 },13306 },
12205 },13307 },
12206 .{13308 .{
12207 .name = "OpAliasScopeListDeclINTEL",13309 .name = "OpAliasScopeListDeclINTEL",
12208 .opcode = 5913,13310 .opcode = 5913,
12209 .operands = &[_]Operand{13311 .operands = &.{
12210 .{ .kind = .IdResult, .quantifier = .required },13312 .{ .kind = .id_result, .quantifier = .required },
12211 .{ .kind = .IdRef, .quantifier = .variadic },13313 .{ .kind = .id_ref, .quantifier = .variadic },
12212 },13314 },
12213 },13315 },
12214 .{13316 .{
12215 .name = "OpFixedSqrtINTEL",13317 .name = "OpFixedSqrtINTEL",
12216 .opcode = 5923,13318 .opcode = 5923,
12217 .operands = &[_]Operand{13319 .operands = &.{
12218 .{ .kind = .IdResultType, .quantifier = .required },13320 .{ .kind = .id_result_type, .quantifier = .required },
12219 .{ .kind = .IdResult, .quantifier = .required },13321 .{ .kind = .id_result, .quantifier = .required },
12220 .{ .kind = .IdRef, .quantifier = .required },13322 .{ .kind = .id_ref, .quantifier = .required },
12221 .{ .kind = .IdRef, .quantifier = .required },13323 .{ .kind = .literal_integer, .quantifier = .required },
12222 .{ .kind = .LiteralInteger, .quantifier = .required },13324 .{ .kind = .literal_integer, .quantifier = .required },
12223 .{ .kind = .LiteralInteger, .quantifier = .required },13325 .{ .kind = .literal_integer, .quantifier = .required },
12224 .{ .kind = .LiteralInteger, .quantifier = .required },13326 .{ .kind = .literal_integer, .quantifier = .required },
12225 .{ .kind = .LiteralInteger, .quantifier = .required },13327 .{ .kind = .literal_integer, .quantifier = .required },
12226 .{ .kind = .LiteralInteger, .quantifier = .required },
12227 },13328 },
12228 },13329 },
12229 .{13330 .{
12230 .name = "OpFixedRecipINTEL",13331 .name = "OpFixedRecipINTEL",
12231 .opcode = 5924,13332 .opcode = 5924,
12232 .operands = &[_]Operand{13333 .operands = &.{
12233 .{ .kind = .IdResultType, .quantifier = .required },13334 .{ .kind = .id_result_type, .quantifier = .required },
12234 .{ .kind = .IdResult, .quantifier = .required },13335 .{ .kind = .id_result, .quantifier = .required },
12235 .{ .kind = .IdRef, .quantifier = .required },13336 .{ .kind = .id_ref, .quantifier = .required },
12236 .{ .kind = .IdRef, .quantifier = .required },13337 .{ .kind = .literal_integer, .quantifier = .required },
12237 .{ .kind = .LiteralInteger, .quantifier = .required },13338 .{ .kind = .literal_integer, .quantifier = .required },
12238 .{ .kind = .LiteralInteger, .quantifier = .required },13339 .{ .kind = .literal_integer, .quantifier = .required },
12239 .{ .kind = .LiteralInteger, .quantifier = .required },13340 .{ .kind = .literal_integer, .quantifier = .required },
12240 .{ .kind = .LiteralInteger, .quantifier = .required },13341 .{ .kind = .literal_integer, .quantifier = .required },
12241 .{ .kind = .LiteralInteger, .quantifier = .required },
12242 },13342 },
12243 },13343 },
12244 .{13344 .{
12245 .name = "OpFixedRsqrtINTEL",13345 .name = "OpFixedRsqrtINTEL",
12246 .opcode = 5925,13346 .opcode = 5925,
12247 .operands = &[_]Operand{13347 .operands = &.{
12248 .{ .kind = .IdResultType, .quantifier = .required },13348 .{ .kind = .id_result_type, .quantifier = .required },
12249 .{ .kind = .IdResult, .quantifier = .required },13349 .{ .kind = .id_result, .quantifier = .required },
12250 .{ .kind = .IdRef, .quantifier = .required },13350 .{ .kind = .id_ref, .quantifier = .required },
12251 .{ .kind = .IdRef, .quantifier = .required },13351 .{ .kind = .literal_integer, .quantifier = .required },
12252 .{ .kind = .LiteralInteger, .quantifier = .required },13352 .{ .kind = .literal_integer, .quantifier = .required },
12253 .{ .kind = .LiteralInteger, .quantifier = .required },13353 .{ .kind = .literal_integer, .quantifier = .required },
12254 .{ .kind = .LiteralInteger, .quantifier = .required },13354 .{ .kind = .literal_integer, .quantifier = .required },
12255 .{ .kind = .LiteralInteger, .quantifier = .required },13355 .{ .kind = .literal_integer, .quantifier = .required },
12256 .{ .kind = .LiteralInteger, .quantifier = .required },
12257 },13356 },
12258 },13357 },
12259 .{13358 .{
12260 .name = "OpFixedSinINTEL",13359 .name = "OpFixedSinINTEL",
12261 .opcode = 5926,13360 .opcode = 5926,
12262 .operands = &[_]Operand{13361 .operands = &.{
12263 .{ .kind = .IdResultType, .quantifier = .required },13362 .{ .kind = .id_result_type, .quantifier = .required },
12264 .{ .kind = .IdResult, .quantifier = .required },13363 .{ .kind = .id_result, .quantifier = .required },
12265 .{ .kind = .IdRef, .quantifier = .required },13364 .{ .kind = .id_ref, .quantifier = .required },
12266 .{ .kind = .IdRef, .quantifier = .required },13365 .{ .kind = .literal_integer, .quantifier = .required },
12267 .{ .kind = .LiteralInteger, .quantifier = .required },13366 .{ .kind = .literal_integer, .quantifier = .required },
12268 .{ .kind = .LiteralInteger, .quantifier = .required },13367 .{ .kind = .literal_integer, .quantifier = .required },
12269 .{ .kind = .LiteralInteger, .quantifier = .required },13368 .{ .kind = .literal_integer, .quantifier = .required },
12270 .{ .kind = .LiteralInteger, .quantifier = .required },13369 .{ .kind = .literal_integer, .quantifier = .required },
12271 .{ .kind = .LiteralInteger, .quantifier = .required },
12272 },13370 },
12273 },13371 },
12274 .{13372 .{
12275 .name = "OpFixedCosINTEL",13373 .name = "OpFixedCosINTEL",
12276 .opcode = 5927,13374 .opcode = 5927,
12277 .operands = &[_]Operand{13375 .operands = &.{
12278 .{ .kind = .IdResultType, .quantifier = .required },13376 .{ .kind = .id_result_type, .quantifier = .required },
12279 .{ .kind = .IdResult, .quantifier = .required },13377 .{ .kind = .id_result, .quantifier = .required },
12280 .{ .kind = .IdRef, .quantifier = .required },13378 .{ .kind = .id_ref, .quantifier = .required },
12281 .{ .kind = .IdRef, .quantifier = .required },13379 .{ .kind = .literal_integer, .quantifier = .required },
12282 .{ .kind = .LiteralInteger, .quantifier = .required },13380 .{ .kind = .literal_integer, .quantifier = .required },
12283 .{ .kind = .LiteralInteger, .quantifier = .required },13381 .{ .kind = .literal_integer, .quantifier = .required },
12284 .{ .kind = .LiteralInteger, .quantifier = .required },13382 .{ .kind = .literal_integer, .quantifier = .required },
12285 .{ .kind = .LiteralInteger, .quantifier = .required },13383 .{ .kind = .literal_integer, .quantifier = .required },
12286 .{ .kind = .LiteralInteger, .quantifier = .required },
12287 },13384 },
12288 },13385 },
12289 .{13386 .{
12290 .name = "OpFixedSinCosINTEL",13387 .name = "OpFixedSinCosINTEL",
12291 .opcode = 5928,13388 .opcode = 5928,
12292 .operands = &[_]Operand{13389 .operands = &.{
12293 .{ .kind = .IdResultType, .quantifier = .required },13390 .{ .kind = .id_result_type, .quantifier = .required },
12294 .{ .kind = .IdResult, .quantifier = .required },13391 .{ .kind = .id_result, .quantifier = .required },
12295 .{ .kind = .IdRef, .quantifier = .required },13392 .{ .kind = .id_ref, .quantifier = .required },
12296 .{ .kind = .IdRef, .quantifier = .required },13393 .{ .kind = .literal_integer, .quantifier = .required },
12297 .{ .kind = .LiteralInteger, .quantifier = .required },13394 .{ .kind = .literal_integer, .quantifier = .required },
12298 .{ .kind = .LiteralInteger, .quantifier = .required },13395 .{ .kind = .literal_integer, .quantifier = .required },
12299 .{ .kind = .LiteralInteger, .quantifier = .required },13396 .{ .kind = .literal_integer, .quantifier = .required },
12300 .{ .kind = .LiteralInteger, .quantifier = .required },13397 .{ .kind = .literal_integer, .quantifier = .required },
12301 .{ .kind = .LiteralInteger, .quantifier = .required },
12302 },13398 },
12303 },13399 },
12304 .{13400 .{
12305 .name = "OpFixedSinPiINTEL",13401 .name = "OpFixedSinPiINTEL",
12306 .opcode = 5929,13402 .opcode = 5929,
12307 .operands = &[_]Operand{13403 .operands = &.{
12308 .{ .kind = .IdResultType, .quantifier = .required },13404 .{ .kind = .id_result_type, .quantifier = .required },
12309 .{ .kind = .IdResult, .quantifier = .required },13405 .{ .kind = .id_result, .quantifier = .required },
12310 .{ .kind = .IdRef, .quantifier = .required },13406 .{ .kind = .id_ref, .quantifier = .required },
12311 .{ .kind = .IdRef, .quantifier = .required },13407 .{ .kind = .literal_integer, .quantifier = .required },
12312 .{ .kind = .LiteralInteger, .quantifier = .required },13408 .{ .kind = .literal_integer, .quantifier = .required },
12313 .{ .kind = .LiteralInteger, .quantifier = .required },13409 .{ .kind = .literal_integer, .quantifier = .required },
12314 .{ .kind = .LiteralInteger, .quantifier = .required },13410 .{ .kind = .literal_integer, .quantifier = .required },
12315 .{ .kind = .LiteralInteger, .quantifier = .required },13411 .{ .kind = .literal_integer, .quantifier = .required },
12316 .{ .kind = .LiteralInteger, .quantifier = .required },
12317 },13412 },
12318 },13413 },
12319 .{13414 .{
12320 .name = "OpFixedCosPiINTEL",13415 .name = "OpFixedCosPiINTEL",
12321 .opcode = 5930,13416 .opcode = 5930,
12322 .operands = &[_]Operand{13417 .operands = &.{
12323 .{ .kind = .IdResultType, .quantifier = .required },13418 .{ .kind = .id_result_type, .quantifier = .required },
12324 .{ .kind = .IdResult, .quantifier = .required },13419 .{ .kind = .id_result, .quantifier = .required },
12325 .{ .kind = .IdRef, .quantifier = .required },13420 .{ .kind = .id_ref, .quantifier = .required },
12326 .{ .kind = .IdRef, .quantifier = .required },13421 .{ .kind = .literal_integer, .quantifier = .required },
12327 .{ .kind = .LiteralInteger, .quantifier = .required },13422 .{ .kind = .literal_integer, .quantifier = .required },
12328 .{ .kind = .LiteralInteger, .quantifier = .required },13423 .{ .kind = .literal_integer, .quantifier = .required },
12329 .{ .kind = .LiteralInteger, .quantifier = .required },13424 .{ .kind = .literal_integer, .quantifier = .required },
12330 .{ .kind = .LiteralInteger, .quantifier = .required },13425 .{ .kind = .literal_integer, .quantifier = .required },
12331 .{ .kind = .LiteralInteger, .quantifier = .required },
12332 },13426 },
12333 },13427 },
12334 .{13428 .{
12335 .name = "OpFixedSinCosPiINTEL",13429 .name = "OpFixedSinCosPiINTEL",
12336 .opcode = 5931,13430 .opcode = 5931,
12337 .operands = &[_]Operand{13431 .operands = &.{
12338 .{ .kind = .IdResultType, .quantifier = .required },13432 .{ .kind = .id_result_type, .quantifier = .required },
12339 .{ .kind = .IdResult, .quantifier = .required },13433 .{ .kind = .id_result, .quantifier = .required },
12340 .{ .kind = .IdRef, .quantifier = .required },13434 .{ .kind = .id_ref, .quantifier = .required },
12341 .{ .kind = .IdRef, .quantifier = .required },13435 .{ .kind = .literal_integer, .quantifier = .required },
12342 .{ .kind = .LiteralInteger, .quantifier = .required },13436 .{ .kind = .literal_integer, .quantifier = .required },
12343 .{ .kind = .LiteralInteger, .quantifier = .required },13437 .{ .kind = .literal_integer, .quantifier = .required },
12344 .{ .kind = .LiteralInteger, .quantifier = .required },13438 .{ .kind = .literal_integer, .quantifier = .required },
12345 .{ .kind = .LiteralInteger, .quantifier = .required },13439 .{ .kind = .literal_integer, .quantifier = .required },
12346 .{ .kind = .LiteralInteger, .quantifier = .required },
12347 },13440 },
12348 },13441 },
12349 .{13442 .{
12350 .name = "OpFixedLogINTEL",13443 .name = "OpFixedLogINTEL",
12351 .opcode = 5932,13444 .opcode = 5932,
12352 .operands = &[_]Operand{13445 .operands = &.{
12353 .{ .kind = .IdResultType, .quantifier = .required },13446 .{ .kind = .id_result_type, .quantifier = .required },
12354 .{ .kind = .IdResult, .quantifier = .required },13447 .{ .kind = .id_result, .quantifier = .required },
12355 .{ .kind = .IdRef, .quantifier = .required },13448 .{ .kind = .id_ref, .quantifier = .required },
12356 .{ .kind = .IdRef, .quantifier = .required },13449 .{ .kind = .literal_integer, .quantifier = .required },
12357 .{ .kind = .LiteralInteger, .quantifier = .required },13450 .{ .kind = .literal_integer, .quantifier = .required },
12358 .{ .kind = .LiteralInteger, .quantifier = .required },13451 .{ .kind = .literal_integer, .quantifier = .required },
12359 .{ .kind = .LiteralInteger, .quantifier = .required },13452 .{ .kind = .literal_integer, .quantifier = .required },
12360 .{ .kind = .LiteralInteger, .quantifier = .required },13453 .{ .kind = .literal_integer, .quantifier = .required },
12361 .{ .kind = .LiteralInteger, .quantifier = .required },
12362 },13454 },
12363 },13455 },
12364 .{13456 .{
12365 .name = "OpFixedExpINTEL",13457 .name = "OpFixedExpINTEL",
12366 .opcode = 5933,13458 .opcode = 5933,
12367 .operands = &[_]Operand{13459 .operands = &.{
12368 .{ .kind = .IdResultType, .quantifier = .required },13460 .{ .kind = .id_result_type, .quantifier = .required },
12369 .{ .kind = .IdResult, .quantifier = .required },13461 .{ .kind = .id_result, .quantifier = .required },
12370 .{ .kind = .IdRef, .quantifier = .required },13462 .{ .kind = .id_ref, .quantifier = .required },
12371 .{ .kind = .IdRef, .quantifier = .required },13463 .{ .kind = .literal_integer, .quantifier = .required },
12372 .{ .kind = .LiteralInteger, .quantifier = .required },13464 .{ .kind = .literal_integer, .quantifier = .required },
12373 .{ .kind = .LiteralInteger, .quantifier = .required },13465 .{ .kind = .literal_integer, .quantifier = .required },
12374 .{ .kind = .LiteralInteger, .quantifier = .required },13466 .{ .kind = .literal_integer, .quantifier = .required },
12375 .{ .kind = .LiteralInteger, .quantifier = .required },13467 .{ .kind = .literal_integer, .quantifier = .required },
12376 .{ .kind = .LiteralInteger, .quantifier = .required },
12377 },13468 },
12378 },13469 },
12379 .{13470 .{
12380 .name = "OpPtrCastToCrossWorkgroupINTEL",13471 .name = "OpPtrCastToCrossWorkgroupINTEL",
12381 .opcode = 5934,13472 .opcode = 5934,
12382 .operands = &[_]Operand{13473 .operands = &.{
12383 .{ .kind = .IdResultType, .quantifier = .required },13474 .{ .kind = .id_result_type, .quantifier = .required },
12384 .{ .kind = .IdResult, .quantifier = .required },13475 .{ .kind = .id_result, .quantifier = .required },
12385 .{ .kind = .IdRef, .quantifier = .required },13476 .{ .kind = .id_ref, .quantifier = .required },
12386 },13477 },
12387 },13478 },
12388 .{13479 .{
12389 .name = "OpCrossWorkgroupCastToPtrINTEL",13480 .name = "OpCrossWorkgroupCastToPtrINTEL",
12390 .opcode = 5938,13481 .opcode = 5938,
12391 .operands = &[_]Operand{13482 .operands = &.{
12392 .{ .kind = .IdResultType, .quantifier = .required },13483 .{ .kind = .id_result_type, .quantifier = .required },
12393 .{ .kind = .IdResult, .quantifier = .required },13484 .{ .kind = .id_result, .quantifier = .required },
12394 .{ .kind = .IdRef, .quantifier = .required },13485 .{ .kind = .id_ref, .quantifier = .required },
12395 },13486 },
12396 },13487 },
12397 .{13488 .{
12398 .name = "OpReadPipeBlockingINTEL",13489 .name = "OpReadPipeBlockingINTEL",
12399 .opcode = 5946,13490 .opcode = 5946,
12400 .operands = &[_]Operand{13491 .operands = &.{
12401 .{ .kind = .IdResultType, .quantifier = .required },13492 .{ .kind = .id_result_type, .quantifier = .required },
12402 .{ .kind = .IdResult, .quantifier = .required },13493 .{ .kind = .id_result, .quantifier = .required },
12403 .{ .kind = .IdRef, .quantifier = .required },13494 .{ .kind = .id_ref, .quantifier = .required },
12404 .{ .kind = .IdRef, .quantifier = .required },13495 .{ .kind = .id_ref, .quantifier = .required },
12405 },13496 },
12406 },13497 },
12407 .{13498 .{
12408 .name = "OpWritePipeBlockingINTEL",13499 .name = "OpWritePipeBlockingINTEL",
12409 .opcode = 5947,13500 .opcode = 5947,
12410 .operands = &[_]Operand{13501 .operands = &.{
12411 .{ .kind = .IdResultType, .quantifier = .required },13502 .{ .kind = .id_result_type, .quantifier = .required },
12412 .{ .kind = .IdResult, .quantifier = .required },13503 .{ .kind = .id_result, .quantifier = .required },
12413 .{ .kind = .IdRef, .quantifier = .required },13504 .{ .kind = .id_ref, .quantifier = .required },
12414 .{ .kind = .IdRef, .quantifier = .required },13505 .{ .kind = .id_ref, .quantifier = .required },
12415 },13506 },
12416 },13507 },
12417 .{13508 .{
12418 .name = "OpFPGARegINTEL",13509 .name = "OpFPGARegINTEL",
12419 .opcode = 5949,13510 .opcode = 5949,
12420 .operands = &[_]Operand{13511 .operands = &.{
12421 .{ .kind = .IdResultType, .quantifier = .required },13512 .{ .kind = .id_result_type, .quantifier = .required },
12422 .{ .kind = .IdResult, .quantifier = .required },13513 .{ .kind = .id_result, .quantifier = .required },
12423 .{ .kind = .IdRef, .quantifier = .required },13514 .{ .kind = .id_ref, .quantifier = .required },
12424 .{ .kind = .IdRef, .quantifier = .required },
12425 },13515 },
12426 },13516 },
12427 .{13517 .{
12428 .name = "OpRayQueryGetRayTMinKHR",13518 .name = "OpRayQueryGetRayTMinKHR",
12429 .opcode = 6016,13519 .opcode = 6016,
12430 .operands = &[_]Operand{13520 .operands = &.{
12431 .{ .kind = .IdResultType, .quantifier = .required },13521 .{ .kind = .id_result_type, .quantifier = .required },
12432 .{ .kind = .IdResult, .quantifier = .required },13522 .{ .kind = .id_result, .quantifier = .required },
12433 .{ .kind = .IdRef, .quantifier = .required },13523 .{ .kind = .id_ref, .quantifier = .required },
12434 },13524 },
12435 },13525 },
12436 .{13526 .{
12437 .name = "OpRayQueryGetRayFlagsKHR",13527 .name = "OpRayQueryGetRayFlagsKHR",
12438 .opcode = 6017,13528 .opcode = 6017,
12439 .operands = &[_]Operand{13529 .operands = &.{
12440 .{ .kind = .IdResultType, .quantifier = .required },13530 .{ .kind = .id_result_type, .quantifier = .required },
12441 .{ .kind = .IdResult, .quantifier = .required },13531 .{ .kind = .id_result, .quantifier = .required },
12442 .{ .kind = .IdRef, .quantifier = .required },13532 .{ .kind = .id_ref, .quantifier = .required },
12443 },13533 },
12444 },13534 },
12445 .{13535 .{
12446 .name = "OpRayQueryGetIntersectionTKHR",13536 .name = "OpRayQueryGetIntersectionTKHR",
12447 .opcode = 6018,13537 .opcode = 6018,
12448 .operands = &[_]Operand{13538 .operands = &.{
12449 .{ .kind = .IdResultType, .quantifier = .required },13539 .{ .kind = .id_result_type, .quantifier = .required },
12450 .{ .kind = .IdResult, .quantifier = .required },13540 .{ .kind = .id_result, .quantifier = .required },
12451 .{ .kind = .IdRef, .quantifier = .required },13541 .{ .kind = .id_ref, .quantifier = .required },
12452 .{ .kind = .IdRef, .quantifier = .required },13542 .{ .kind = .id_ref, .quantifier = .required },
12453 },13543 },
12454 },13544 },
12455 .{13545 .{
12456 .name = "OpRayQueryGetIntersectionInstanceCustomIndexKHR",13546 .name = "OpRayQueryGetIntersectionInstanceCustomIndexKHR",
12457 .opcode = 6019,13547 .opcode = 6019,
12458 .operands = &[_]Operand{13548 .operands = &.{
12459 .{ .kind = .IdResultType, .quantifier = .required },13549 .{ .kind = .id_result_type, .quantifier = .required },
12460 .{ .kind = .IdResult, .quantifier = .required },13550 .{ .kind = .id_result, .quantifier = .required },
12461 .{ .kind = .IdRef, .quantifier = .required },13551 .{ .kind = .id_ref, .quantifier = .required },
12462 .{ .kind = .IdRef, .quantifier = .required },13552 .{ .kind = .id_ref, .quantifier = .required },
12463 },13553 },
12464 },13554 },
12465 .{13555 .{
12466 .name = "OpRayQueryGetIntersectionInstanceIdKHR",13556 .name = "OpRayQueryGetIntersectionInstanceIdKHR",
12467 .opcode = 6020,13557 .opcode = 6020,
12468 .operands = &[_]Operand{13558 .operands = &.{
12469 .{ .kind = .IdResultType, .quantifier = .required },13559 .{ .kind = .id_result_type, .quantifier = .required },
12470 .{ .kind = .IdResult, .quantifier = .required },13560 .{ .kind = .id_result, .quantifier = .required },
12471 .{ .kind = .IdRef, .quantifier = .required },13561 .{ .kind = .id_ref, .quantifier = .required },
12472 .{ .kind = .IdRef, .quantifier = .required },13562 .{ .kind = .id_ref, .quantifier = .required },
12473 },13563 },
12474 },13564 },
12475 .{13565 .{
12476 .name = "OpRayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetKHR",13566 .name = "OpRayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetKHR",
12477 .opcode = 6021,13567 .opcode = 6021,
12478 .operands = &[_]Operand{13568 .operands = &.{
12479 .{ .kind = .IdResultType, .quantifier = .required },13569 .{ .kind = .id_result_type, .quantifier = .required },
12480 .{ .kind = .IdResult, .quantifier = .required },13570 .{ .kind = .id_result, .quantifier = .required },
12481 .{ .kind = .IdRef, .quantifier = .required },13571 .{ .kind = .id_ref, .quantifier = .required },
12482 .{ .kind = .IdRef, .quantifier = .required },13572 .{ .kind = .id_ref, .quantifier = .required },
12483 },13573 },
12484 },13574 },
12485 .{13575 .{
12486 .name = "OpRayQueryGetIntersectionGeometryIndexKHR",13576 .name = "OpRayQueryGetIntersectionGeometryIndexKHR",
12487 .opcode = 6022,13577 .opcode = 6022,
12488 .operands = &[_]Operand{13578 .operands = &.{
12489 .{ .kind = .IdResultType, .quantifier = .required },13579 .{ .kind = .id_result_type, .quantifier = .required },
12490 .{ .kind = .IdResult, .quantifier = .required },13580 .{ .kind = .id_result, .quantifier = .required },
12491 .{ .kind = .IdRef, .quantifier = .required },13581 .{ .kind = .id_ref, .quantifier = .required },
12492 .{ .kind = .IdRef, .quantifier = .required },13582 .{ .kind = .id_ref, .quantifier = .required },
12493 },13583 },
12494 },13584 },
12495 .{13585 .{
12496 .name = "OpRayQueryGetIntersectionPrimitiveIndexKHR",13586 .name = "OpRayQueryGetIntersectionPrimitiveIndexKHR",
12497 .opcode = 6023,13587 .opcode = 6023,
12498 .operands = &[_]Operand{13588 .operands = &.{
12499 .{ .kind = .IdResultType, .quantifier = .required },13589 .{ .kind = .id_result_type, .quantifier = .required },
12500 .{ .kind = .IdResult, .quantifier = .required },13590 .{ .kind = .id_result, .quantifier = .required },
12501 .{ .kind = .IdRef, .quantifier = .required },13591 .{ .kind = .id_ref, .quantifier = .required },
12502 .{ .kind = .IdRef, .quantifier = .required },13592 .{ .kind = .id_ref, .quantifier = .required },
12503 },13593 },
12504 },13594 },
12505 .{13595 .{
12506 .name = "OpRayQueryGetIntersectionBarycentricsKHR",13596 .name = "OpRayQueryGetIntersectionBarycentricsKHR",
12507 .opcode = 6024,13597 .opcode = 6024,
12508 .operands = &[_]Operand{13598 .operands = &.{
12509 .{ .kind = .IdResultType, .quantifier = .required },13599 .{ .kind = .id_result_type, .quantifier = .required },
12510 .{ .kind = .IdResult, .quantifier = .required },13600 .{ .kind = .id_result, .quantifier = .required },
12511 .{ .kind = .IdRef, .quantifier = .required },13601 .{ .kind = .id_ref, .quantifier = .required },
12512 .{ .kind = .IdRef, .quantifier = .required },13602 .{ .kind = .id_ref, .quantifier = .required },
12513 },13603 },
12514 },13604 },
12515 .{13605 .{
12516 .name = "OpRayQueryGetIntersectionFrontFaceKHR",13606 .name = "OpRayQueryGetIntersectionFrontFaceKHR",
12517 .opcode = 6025,13607 .opcode = 6025,
12518 .operands = &[_]Operand{13608 .operands = &.{
12519 .{ .kind = .IdResultType, .quantifier = .required },13609 .{ .kind = .id_result_type, .quantifier = .required },
12520 .{ .kind = .IdResult, .quantifier = .required },13610 .{ .kind = .id_result, .quantifier = .required },
12521 .{ .kind = .IdRef, .quantifier = .required },13611 .{ .kind = .id_ref, .quantifier = .required },
12522 .{ .kind = .IdRef, .quantifier = .required },13612 .{ .kind = .id_ref, .quantifier = .required },
12523 },13613 },
12524 },13614 },
12525 .{13615 .{
12526 .name = "OpRayQueryGetIntersectionCandidateAABBOpaqueKHR",13616 .name = "OpRayQueryGetIntersectionCandidateAABBOpaqueKHR",
12527 .opcode = 6026,13617 .opcode = 6026,
12528 .operands = &[_]Operand{13618 .operands = &.{
12529 .{ .kind = .IdResultType, .quantifier = .required },13619 .{ .kind = .id_result_type, .quantifier = .required },
12530 .{ .kind = .IdResult, .quantifier = .required },13620 .{ .kind = .id_result, .quantifier = .required },
12531 .{ .kind = .IdRef, .quantifier = .required },13621 .{ .kind = .id_ref, .quantifier = .required },
12532 },13622 },
12533 },13623 },
12534 .{13624 .{
12535 .name = "OpRayQueryGetIntersectionObjectRayDirectionKHR",13625 .name = "OpRayQueryGetIntersectionObjectRayDirectionKHR",
12536 .opcode = 6027,13626 .opcode = 6027,
12537 .operands = &[_]Operand{13627 .operands = &.{
12538 .{ .kind = .IdResultType, .quantifier = .required },13628 .{ .kind = .id_result_type, .quantifier = .required },
12539 .{ .kind = .IdResult, .quantifier = .required },13629 .{ .kind = .id_result, .quantifier = .required },
12540 .{ .kind = .IdRef, .quantifier = .required },13630 .{ .kind = .id_ref, .quantifier = .required },
12541 .{ .kind = .IdRef, .quantifier = .required },13631 .{ .kind = .id_ref, .quantifier = .required },
12542 },13632 },
12543 },13633 },
12544 .{13634 .{
12545 .name = "OpRayQueryGetIntersectionObjectRayOriginKHR",13635 .name = "OpRayQueryGetIntersectionObjectRayOriginKHR",
12546 .opcode = 6028,13636 .opcode = 6028,
12547 .operands = &[_]Operand{13637 .operands = &.{
12548 .{ .kind = .IdResultType, .quantifier = .required },13638 .{ .kind = .id_result_type, .quantifier = .required },
12549 .{ .kind = .IdResult, .quantifier = .required },13639 .{ .kind = .id_result, .quantifier = .required },
12550 .{ .kind = .IdRef, .quantifier = .required },13640 .{ .kind = .id_ref, .quantifier = .required },
12551 .{ .kind = .IdRef, .quantifier = .required },13641 .{ .kind = .id_ref, .quantifier = .required },
12552 },13642 },
12553 },13643 },
12554 .{13644 .{
12555 .name = "OpRayQueryGetWorldRayDirectionKHR",13645 .name = "OpRayQueryGetWorldRayDirectionKHR",
12556 .opcode = 6029,13646 .opcode = 6029,
12557 .operands = &[_]Operand{13647 .operands = &.{
12558 .{ .kind = .IdResultType, .quantifier = .required },13648 .{ .kind = .id_result_type, .quantifier = .required },
12559 .{ .kind = .IdResult, .quantifier = .required },13649 .{ .kind = .id_result, .quantifier = .required },
12560 .{ .kind = .IdRef, .quantifier = .required },13650 .{ .kind = .id_ref, .quantifier = .required },
12561 },13651 },
12562 },13652 },
12563 .{13653 .{
12564 .name = "OpRayQueryGetWorldRayOriginKHR",13654 .name = "OpRayQueryGetWorldRayOriginKHR",
12565 .opcode = 6030,13655 .opcode = 6030,
12566 .operands = &[_]Operand{13656 .operands = &.{
12567 .{ .kind = .IdResultType, .quantifier = .required },13657 .{ .kind = .id_result_type, .quantifier = .required },
12568 .{ .kind = .IdResult, .quantifier = .required },13658 .{ .kind = .id_result, .quantifier = .required },
12569 .{ .kind = .IdRef, .quantifier = .required },13659 .{ .kind = .id_ref, .quantifier = .required },
12570 },13660 },
12571 },13661 },
12572 .{13662 .{
12573 .name = "OpRayQueryGetIntersectionObjectToWorldKHR",13663 .name = "OpRayQueryGetIntersectionObjectToWorldKHR",
12574 .opcode = 6031,13664 .opcode = 6031,
12575 .operands = &[_]Operand{13665 .operands = &.{
12576 .{ .kind = .IdResultType, .quantifier = .required },13666 .{ .kind = .id_result_type, .quantifier = .required },
12577 .{ .kind = .IdResult, .quantifier = .required },13667 .{ .kind = .id_result, .quantifier = .required },
12578 .{ .kind = .IdRef, .quantifier = .required },13668 .{ .kind = .id_ref, .quantifier = .required },
12579 .{ .kind = .IdRef, .quantifier = .required },13669 .{ .kind = .id_ref, .quantifier = .required },
12580 },13670 },
12581 },13671 },
12582 .{13672 .{
12583 .name = "OpRayQueryGetIntersectionWorldToObjectKHR",13673 .name = "OpRayQueryGetIntersectionWorldToObjectKHR",
12584 .opcode = 6032,13674 .opcode = 6032,
12585 .operands = &[_]Operand{13675 .operands = &.{
12586 .{ .kind = .IdResultType, .quantifier = .required },13676 .{ .kind = .id_result_type, .quantifier = .required },
12587 .{ .kind = .IdResult, .quantifier = .required },13677 .{ .kind = .id_result, .quantifier = .required },
12588 .{ .kind = .IdRef, .quantifier = .required },13678 .{ .kind = .id_ref, .quantifier = .required },
12589 .{ .kind = .IdRef, .quantifier = .required },13679 .{ .kind = .id_ref, .quantifier = .required },
12590 },13680 },
12591 },13681 },
12592 .{13682 .{
12593 .name = "OpAtomicFAddEXT",13683 .name = "OpAtomicFAddEXT",
12594 .opcode = 6035,13684 .opcode = 6035,
12595 .operands = &[_]Operand{13685 .operands = &.{
12596 .{ .kind = .IdResultType, .quantifier = .required },13686 .{ .kind = .id_result_type, .quantifier = .required },
12597 .{ .kind = .IdResult, .quantifier = .required },13687 .{ .kind = .id_result, .quantifier = .required },
12598 .{ .kind = .IdRef, .quantifier = .required },13688 .{ .kind = .id_ref, .quantifier = .required },
12599 .{ .kind = .IdScope, .quantifier = .required },13689 .{ .kind = .id_scope, .quantifier = .required },
12600 .{ .kind = .IdMemorySemantics, .quantifier = .required },13690 .{ .kind = .id_memory_semantics, .quantifier = .required },
12601 .{ .kind = .IdRef, .quantifier = .required },13691 .{ .kind = .id_ref, .quantifier = .required },
12602 },13692 },
12603 },13693 },
12604 .{13694 .{
12605 .name = "OpTypeBufferSurfaceINTEL",13695 .name = "OpTypeBufferSurfaceINTEL",
12606 .opcode = 6086,13696 .opcode = 6086,
12607 .operands = &[_]Operand{13697 .operands = &.{
12608 .{ .kind = .IdResult, .quantifier = .required },13698 .{ .kind = .id_result, .quantifier = .required },
12609 .{ .kind = .AccessQualifier, .quantifier = .required },13699 .{ .kind = .access_qualifier, .quantifier = .required },
12610 },13700 },
12611 },13701 },
12612 .{13702 .{
12613 .name = "OpTypeStructContinuedINTEL",13703 .name = "OpTypeStructContinuedINTEL",
12614 .opcode = 6090,13704 .opcode = 6090,
12615 .operands = &[_]Operand{13705 .operands = &.{
12616 .{ .kind = .IdRef, .quantifier = .variadic },13706 .{ .kind = .id_ref, .quantifier = .variadic },
12617 },13707 },
12618 },13708 },
12619 .{13709 .{
12620 .name = "OpConstantCompositeContinuedINTEL",13710 .name = "OpConstantCompositeContinuedINTEL",
12621 .opcode = 6091,13711 .opcode = 6091,
12622 .operands = &[_]Operand{13712 .operands = &.{
12623 .{ .kind = .IdRef, .quantifier = .variadic },13713 .{ .kind = .id_ref, .quantifier = .variadic },
12624 },13714 },
12625 },13715 },
12626 .{13716 .{
12627 .name = "OpSpecConstantCompositeContinuedINTEL",13717 .name = "OpSpecConstantCompositeContinuedINTEL",
12628 .opcode = 6092,13718 .opcode = 6092,
12629 .operands = &[_]Operand{13719 .operands = &.{
12630 .{ .kind = .IdRef, .quantifier = .variadic },13720 .{ .kind = .id_ref, .quantifier = .variadic },
12631 },13721 },
12632 },13722 },
12633 .{13723 .{
12634 .name = "OpCompositeConstructContinuedINTEL",13724 .name = "OpCompositeConstructContinuedINTEL",
12635 .opcode = 6096,13725 .opcode = 6096,
12636 .operands = &[_]Operand{13726 .operands = &.{
12637 .{ .kind = .IdResultType, .quantifier = .required },13727 .{ .kind = .id_result_type, .quantifier = .required },
12638 .{ .kind = .IdResult, .quantifier = .required },13728 .{ .kind = .id_result, .quantifier = .required },
12639 .{ .kind = .IdRef, .quantifier = .variadic },13729 .{ .kind = .id_ref, .quantifier = .variadic },
12640 },13730 },
12641 },13731 },
12642 .{13732 .{
12643 .name = "OpConvertFToBF16INTEL",13733 .name = "OpConvertFToBF16INTEL",
12644 .opcode = 6116,13734 .opcode = 6116,
12645 .operands = &[_]Operand{13735 .operands = &.{
12646 .{ .kind = .IdResultType, .quantifier = .required },13736 .{ .kind = .id_result_type, .quantifier = .required },
12647 .{ .kind = .IdResult, .quantifier = .required },13737 .{ .kind = .id_result, .quantifier = .required },
12648 .{ .kind = .IdRef, .quantifier = .required },13738 .{ .kind = .id_ref, .quantifier = .required },
12649 },13739 },
12650 },13740 },
12651 .{13741 .{
12652 .name = "OpConvertBF16ToFINTEL",13742 .name = "OpConvertBF16ToFINTEL",
12653 .opcode = 6117,13743 .opcode = 6117,
12654 .operands = &[_]Operand{13744 .operands = &.{
12655 .{ .kind = .IdResultType, .quantifier = .required },13745 .{ .kind = .id_result_type, .quantifier = .required },
12656 .{ .kind = .IdResult, .quantifier = .required },13746 .{ .kind = .id_result, .quantifier = .required },
12657 .{ .kind = .IdRef, .quantifier = .required },13747 .{ .kind = .id_ref, .quantifier = .required },
12658 },13748 },
12659 },13749 },
12660 .{13750 .{
12661 .name = "OpControlBarrierArriveINTEL",13751 .name = "OpControlBarrierArriveINTEL",
12662 .opcode = 6142,13752 .opcode = 6142,
12663 .operands = &[_]Operand{13753 .operands = &.{
12664 .{ .kind = .IdScope, .quantifier = .required },13754 .{ .kind = .id_scope, .quantifier = .required },
12665 .{ .kind = .IdScope, .quantifier = .required },13755 .{ .kind = .id_scope, .quantifier = .required },
12666 .{ .kind = .IdMemorySemantics, .quantifier = .required },13756 .{ .kind = .id_memory_semantics, .quantifier = .required },
12667 },13757 },
12668 },13758 },
12669 .{13759 .{
12670 .name = "OpControlBarrierWaitINTEL",13760 .name = "OpControlBarrierWaitINTEL",
12671 .opcode = 6143,13761 .opcode = 6143,
12672 .operands = &[_]Operand{13762 .operands = &.{
12673 .{ .kind = .IdScope, .quantifier = .required },13763 .{ .kind = .id_scope, .quantifier = .required },
12674 .{ .kind = .IdScope, .quantifier = .required },13764 .{ .kind = .id_scope, .quantifier = .required },
12675 .{ .kind = .IdMemorySemantics, .quantifier = .required },13765 .{ .kind = .id_memory_semantics, .quantifier = .required },
12676 },13766 },
12677 },13767 },
12678 .{13768 .{
12679 .name = "OpGroupIMulKHR",13769 .name = "OpArithmeticFenceEXT",
12680 .opcode = 6401,13770 .opcode = 6145,
12681 .operands = &[_]Operand{13771 .operands = &.{
12682 .{ .kind = .IdResultType, .quantifier = .required },13772 .{ .kind = .id_result_type, .quantifier = .required },
12683 .{ .kind = .IdResult, .quantifier = .required },13773 .{ .kind = .id_result, .quantifier = .required },
12684 .{ .kind = .IdScope, .quantifier = .required },13774 .{ .kind = .id_ref, .quantifier = .required },
12685 .{ .kind = .GroupOperation, .quantifier = .required },
12686 .{ .kind = .IdRef, .quantifier = .required },
12687 },13775 },
12688 },13776 },
12689 .{13777 .{
12690 .name = "OpGroupFMulKHR",13778 .name = "OpTaskSequenceCreateINTEL",
12691 .opcode = 6402,13779 .opcode = 6163,
12692 .operands = &[_]Operand{13780 .operands = &.{
12693 .{ .kind = .IdResultType, .quantifier = .required },13781 .{ .kind = .id_result_type, .quantifier = .required },
12694 .{ .kind = .IdResult, .quantifier = .required },13782 .{ .kind = .id_result, .quantifier = .required },
12695 .{ .kind = .IdScope, .quantifier = .required },13783 .{ .kind = .id_ref, .quantifier = .required },
12696 .{ .kind = .GroupOperation, .quantifier = .required },13784 .{ .kind = .literal_integer, .quantifier = .required },
12697 .{ .kind = .IdRef, .quantifier = .required },13785 .{ .kind = .literal_integer, .quantifier = .required },
13786 .{ .kind = .literal_integer, .quantifier = .required },
13787 .{ .kind = .literal_integer, .quantifier = .required },
12698 },13788 },
12699 },13789 },
12700 .{13790 .{
12701 .name = "OpGroupBitwiseAndKHR",13791 .name = "OpTaskSequenceAsyncINTEL",
12702 .opcode = 6403,13792 .opcode = 6164,
12703 .operands = &[_]Operand{13793 .operands = &.{
12704 .{ .kind = .IdResultType, .quantifier = .required },13794 .{ .kind = .id_ref, .quantifier = .required },
12705 .{ .kind = .IdResult, .quantifier = .required },13795 .{ .kind = .id_ref, .quantifier = .variadic },
12706 .{ .kind = .IdScope, .quantifier = .required },
12707 .{ .kind = .GroupOperation, .quantifier = .required },
12708 .{ .kind = .IdRef, .quantifier = .required },
12709 },13796 },
12710 },13797 },
12711 .{13798 .{
12712 .name = "OpGroupBitwiseOrKHR",13799 .name = "OpTaskSequenceGetINTEL",
12713 .opcode = 6404,13800 .opcode = 6165,
12714 .operands = &[_]Operand{13801 .operands = &.{
12715 .{ .kind = .IdResultType, .quantifier = .required },13802 .{ .kind = .id_result_type, .quantifier = .required },
12716 .{ .kind = .IdResult, .quantifier = .required },13803 .{ .kind = .id_result, .quantifier = .required },
12717 .{ .kind = .IdScope, .quantifier = .required },13804 .{ .kind = .id_ref, .quantifier = .required },
12718 .{ .kind = .GroupOperation, .quantifier = .required },
12719 .{ .kind = .IdRef, .quantifier = .required },
12720 },13805 },
12721 },13806 },
12722 .{13807 .{
12723 .name = "OpGroupBitwiseXorKHR",13808 .name = "OpTaskSequenceReleaseINTEL",
12724 .opcode = 6405,13809 .opcode = 6166,
12725 .operands = &[_]Operand{13810 .operands = &.{
12726 .{ .kind = .IdResultType, .quantifier = .required },13811 .{ .kind = .id_ref, .quantifier = .required },
12727 .{ .kind = .IdResult, .quantifier = .required },
12728 .{ .kind = .IdScope, .quantifier = .required },
12729 .{ .kind = .GroupOperation, .quantifier = .required },
12730 .{ .kind = .IdRef, .quantifier = .required },
12731 },13812 },
12732 },13813 },
12733 .{13814 .{
12734 .name = "OpGroupLogicalAndKHR",13815 .name = "OpTypeTaskSequenceINTEL",
12735 .opcode = 6406,13816 .opcode = 6199,
12736 .operands = &[_]Operand{13817 .operands = &.{
12737 .{ .kind = .IdResultType, .quantifier = .required },13818 .{ .kind = .id_result, .quantifier = .required },
12738 .{ .kind = .IdResult, .quantifier = .required },
12739 .{ .kind = .IdScope, .quantifier = .required },
12740 .{ .kind = .GroupOperation, .quantifier = .required },
12741 .{ .kind = .IdRef, .quantifier = .required },
12742 },13819 },
12743 },13820 },
12744 .{13821 .{
12745 .name = "OpGroupLogicalOrKHR",13822 .name = "OpSubgroupBlockPrefetchINTEL",
12746 .opcode = 6407,13823 .opcode = 6221,
12747 .operands = &[_]Operand{13824 .operands = &.{
12748 .{ .kind = .IdResultType, .quantifier = .required },13825 .{ .kind = .id_ref, .quantifier = .required },
12749 .{ .kind = .IdResult, .quantifier = .required },13826 .{ .kind = .id_ref, .quantifier = .required },
12750 .{ .kind = .IdScope, .quantifier = .required },13827 .{ .kind = .memory_access, .quantifier = .optional },
12751 .{ .kind = .GroupOperation, .quantifier = .required },
12752 .{ .kind = .IdRef, .quantifier = .required },
12753 },13828 },
12754 },13829 },
12755 .{13830 .{
12756 .name = "OpGroupLogicalXorKHR",13831 .name = "OpSubgroup2DBlockLoadINTEL",
12757 .opcode = 6408,13832 .opcode = 6231,
12758 .operands = &[_]Operand{13833 .operands = &.{
12759 .{ .kind = .IdResultType, .quantifier = .required },13834 .{ .kind = .id_ref, .quantifier = .required },
12760 .{ .kind = .IdResult, .quantifier = .required },13835 .{ .kind = .id_ref, .quantifier = .required },
12761 .{ .kind = .IdScope, .quantifier = .required },13836 .{ .kind = .id_ref, .quantifier = .required },
12762 .{ .kind = .GroupOperation, .quantifier = .required },13837 .{ .kind = .id_ref, .quantifier = .required },
12763 .{ .kind = .IdRef, .quantifier = .required },13838 .{ .kind = .id_ref, .quantifier = .required },
13839 .{ .kind = .id_ref, .quantifier = .required },
13840 .{ .kind = .id_ref, .quantifier = .required },
13841 .{ .kind = .id_ref, .quantifier = .required },
13842 .{ .kind = .id_ref, .quantifier = .required },
13843 .{ .kind = .id_ref, .quantifier = .required },
12764 },13844 },
12765 },13845 },
12766 .{13846 .{
12767 .name = "OpMaskedGatherINTEL",13847 .name = "OpSubgroup2DBlockLoadTransformINTEL",
12768 .opcode = 6428,13848 .opcode = 6232,
12769 .operands = &[_]Operand{13849 .operands = &.{
12770 .{ .kind = .IdResultType, .quantifier = .required },13850 .{ .kind = .id_ref, .quantifier = .required },
12771 .{ .kind = .IdResult, .quantifier = .required },13851 .{ .kind = .id_ref, .quantifier = .required },
12772 .{ .kind = .IdRef, .quantifier = .required },13852 .{ .kind = .id_ref, .quantifier = .required },
12773 .{ .kind = .LiteralInteger, .quantifier = .required },13853 .{ .kind = .id_ref, .quantifier = .required },
12774 .{ .kind = .IdRef, .quantifier = .required },13854 .{ .kind = .id_ref, .quantifier = .required },
12775 .{ .kind = .IdRef, .quantifier = .required },13855 .{ .kind = .id_ref, .quantifier = .required },
13856 .{ .kind = .id_ref, .quantifier = .required },
13857 .{ .kind = .id_ref, .quantifier = .required },
13858 .{ .kind = .id_ref, .quantifier = .required },
13859 .{ .kind = .id_ref, .quantifier = .required },
12776 },13860 },
12777 },13861 },
12778 .{13862 .{
12779 .name = "OpMaskedScatterINTEL",13863 .name = "OpSubgroup2DBlockLoadTransposeINTEL",
12780 .opcode = 6429,13864 .opcode = 6233,
12781 .operands = &[_]Operand{13865 .operands = &.{
12782 .{ .kind = .IdRef, .quantifier = .required },13866 .{ .kind = .id_ref, .quantifier = .required },
12783 .{ .kind = .IdRef, .quantifier = .required },13867 .{ .kind = .id_ref, .quantifier = .required },
12784 .{ .kind = .LiteralInteger, .quantifier = .required },13868 .{ .kind = .id_ref, .quantifier = .required },
12785 .{ .kind = .IdRef, .quantifier = .required },13869 .{ .kind = .id_ref, .quantifier = .required },
13870 .{ .kind = .id_ref, .quantifier = .required },
13871 .{ .kind = .id_ref, .quantifier = .required },
13872 .{ .kind = .id_ref, .quantifier = .required },
13873 .{ .kind = .id_ref, .quantifier = .required },
13874 .{ .kind = .id_ref, .quantifier = .required },
13875 .{ .kind = .id_ref, .quantifier = .required },
12786 },13876 },
12787 },13877 },
12788 },
12789 .@"OpenCL.std" => &[_]Instruction{
12790 .{13878 .{
12791 .name = "acos",13879 .name = "OpSubgroup2DBlockPrefetchINTEL",
12792 .opcode = 0,13880 .opcode = 6234,
12793 .operands = &[_]Operand{13881 .operands = &.{
12794 .{ .kind = .IdRef, .quantifier = .required },13882 .{ .kind = .id_ref, .quantifier = .required },
13883 .{ .kind = .id_ref, .quantifier = .required },
13884 .{ .kind = .id_ref, .quantifier = .required },
13885 .{ .kind = .id_ref, .quantifier = .required },
13886 .{ .kind = .id_ref, .quantifier = .required },
13887 .{ .kind = .id_ref, .quantifier = .required },
13888 .{ .kind = .id_ref, .quantifier = .required },
13889 .{ .kind = .id_ref, .quantifier = .required },
13890 .{ .kind = .id_ref, .quantifier = .required },
12795 },13891 },
12796 },13892 },
12797 .{13893 .{
12798 .name = "acosh",13894 .name = "OpSubgroup2DBlockStoreINTEL",
12799 .opcode = 1,13895 .opcode = 6235,
12800 .operands = &[_]Operand{13896 .operands = &.{
12801 .{ .kind = .IdRef, .quantifier = .required },13897 .{ .kind = .id_ref, .quantifier = .required },
13898 .{ .kind = .id_ref, .quantifier = .required },
13899 .{ .kind = .id_ref, .quantifier = .required },
13900 .{ .kind = .id_ref, .quantifier = .required },
13901 .{ .kind = .id_ref, .quantifier = .required },
13902 .{ .kind = .id_ref, .quantifier = .required },
13903 .{ .kind = .id_ref, .quantifier = .required },
13904 .{ .kind = .id_ref, .quantifier = .required },
13905 .{ .kind = .id_ref, .quantifier = .required },
13906 .{ .kind = .id_ref, .quantifier = .required },
13907 },
13908 },
13909 .{
13910 .name = "OpSubgroupMatrixMultiplyAccumulateINTEL",
13911 .opcode = 6237,
13912 .operands = &.{
13913 .{ .kind = .id_result_type, .quantifier = .required },
13914 .{ .kind = .id_result, .quantifier = .required },
13915 .{ .kind = .id_ref, .quantifier = .required },
13916 .{ .kind = .id_ref, .quantifier = .required },
13917 .{ .kind = .id_ref, .quantifier = .required },
13918 .{ .kind = .id_ref, .quantifier = .required },
13919 .{ .kind = .matrix_multiply_accumulate_operands, .quantifier = .optional },
13920 },
13921 },
13922 .{
13923 .name = "OpBitwiseFunctionINTEL",
13924 .opcode = 6242,
13925 .operands = &.{
13926 .{ .kind = .id_result_type, .quantifier = .required },
13927 .{ .kind = .id_result, .quantifier = .required },
13928 .{ .kind = .id_ref, .quantifier = .required },
13929 .{ .kind = .id_ref, .quantifier = .required },
13930 .{ .kind = .id_ref, .quantifier = .required },
13931 .{ .kind = .id_ref, .quantifier = .required },
12802 },13932 },
12803 },13933 },
12804 .{13934 .{
12805 .name = "acospi",13935 .name = "OpGroupIMulKHR",
12806 .opcode = 2,13936 .opcode = 6401,
12807 .operands = &[_]Operand{13937 .operands = &.{
12808 .{ .kind = .IdRef, .quantifier = .required },13938 .{ .kind = .id_result_type, .quantifier = .required },
13939 .{ .kind = .id_result, .quantifier = .required },
13940 .{ .kind = .id_scope, .quantifier = .required },
13941 .{ .kind = .group_operation, .quantifier = .required },
13942 .{ .kind = .id_ref, .quantifier = .required },
12809 },13943 },
12810 },13944 },
12811 .{13945 .{
12812 .name = "asin",13946 .name = "OpGroupFMulKHR",
12813 .opcode = 3,13947 .opcode = 6402,
12814 .operands = &[_]Operand{13948 .operands = &.{
12815 .{ .kind = .IdRef, .quantifier = .required },13949 .{ .kind = .id_result_type, .quantifier = .required },
12816 },13950 .{ .kind = .id_result, .quantifier = .required },
13951 .{ .kind = .id_scope, .quantifier = .required },
13952 .{ .kind = .group_operation, .quantifier = .required },
13953 .{ .kind = .id_ref, .quantifier = .required },
13954 },
12817 },13955 },
12818 .{13956 .{
12819 .name = "asinh",13957 .name = "OpGroupBitwiseAndKHR",
13958 .opcode = 6403,
13959 .operands = &.{
13960 .{ .kind = .id_result_type, .quantifier = .required },
13961 .{ .kind = .id_result, .quantifier = .required },
13962 .{ .kind = .id_scope, .quantifier = .required },
13963 .{ .kind = .group_operation, .quantifier = .required },
13964 .{ .kind = .id_ref, .quantifier = .required },
13965 },
13966 },
13967 .{
13968 .name = "OpGroupBitwiseOrKHR",
13969 .opcode = 6404,
13970 .operands = &.{
13971 .{ .kind = .id_result_type, .quantifier = .required },
13972 .{ .kind = .id_result, .quantifier = .required },
13973 .{ .kind = .id_scope, .quantifier = .required },
13974 .{ .kind = .group_operation, .quantifier = .required },
13975 .{ .kind = .id_ref, .quantifier = .required },
13976 },
13977 },
13978 .{
13979 .name = "OpGroupBitwiseXorKHR",
13980 .opcode = 6405,
13981 .operands = &.{
13982 .{ .kind = .id_result_type, .quantifier = .required },
13983 .{ .kind = .id_result, .quantifier = .required },
13984 .{ .kind = .id_scope, .quantifier = .required },
13985 .{ .kind = .group_operation, .quantifier = .required },
13986 .{ .kind = .id_ref, .quantifier = .required },
13987 },
13988 },
13989 .{
13990 .name = "OpGroupLogicalAndKHR",
13991 .opcode = 6406,
13992 .operands = &.{
13993 .{ .kind = .id_result_type, .quantifier = .required },
13994 .{ .kind = .id_result, .quantifier = .required },
13995 .{ .kind = .id_scope, .quantifier = .required },
13996 .{ .kind = .group_operation, .quantifier = .required },
13997 .{ .kind = .id_ref, .quantifier = .required },
13998 },
13999 },
14000 .{
14001 .name = "OpGroupLogicalOrKHR",
14002 .opcode = 6407,
14003 .operands = &.{
14004 .{ .kind = .id_result_type, .quantifier = .required },
14005 .{ .kind = .id_result, .quantifier = .required },
14006 .{ .kind = .id_scope, .quantifier = .required },
14007 .{ .kind = .group_operation, .quantifier = .required },
14008 .{ .kind = .id_ref, .quantifier = .required },
14009 },
14010 },
14011 .{
14012 .name = "OpGroupLogicalXorKHR",
14013 .opcode = 6408,
14014 .operands = &.{
14015 .{ .kind = .id_result_type, .quantifier = .required },
14016 .{ .kind = .id_result, .quantifier = .required },
14017 .{ .kind = .id_scope, .quantifier = .required },
14018 .{ .kind = .group_operation, .quantifier = .required },
14019 .{ .kind = .id_ref, .quantifier = .required },
14020 },
14021 },
14022 .{
14023 .name = "OpRoundFToTF32INTEL",
14024 .opcode = 6426,
14025 .operands = &.{
14026 .{ .kind = .id_result_type, .quantifier = .required },
14027 .{ .kind = .id_result, .quantifier = .required },
14028 .{ .kind = .id_ref, .quantifier = .required },
14029 },
14030 },
14031 .{
14032 .name = "OpMaskedGatherINTEL",
14033 .opcode = 6428,
14034 .operands = &.{
14035 .{ .kind = .id_result_type, .quantifier = .required },
14036 .{ .kind = .id_result, .quantifier = .required },
14037 .{ .kind = .id_ref, .quantifier = .required },
14038 .{ .kind = .literal_integer, .quantifier = .required },
14039 .{ .kind = .id_ref, .quantifier = .required },
14040 .{ .kind = .id_ref, .quantifier = .required },
14041 },
14042 },
14043 .{
14044 .name = "OpMaskedScatterINTEL",
14045 .opcode = 6429,
14046 .operands = &.{
14047 .{ .kind = .id_ref, .quantifier = .required },
14048 .{ .kind = .id_ref, .quantifier = .required },
14049 .{ .kind = .literal_integer, .quantifier = .required },
14050 .{ .kind = .id_ref, .quantifier = .required },
14051 },
14052 },
14053 .{
14054 .name = "OpConvertHandleToImageINTEL",
14055 .opcode = 6529,
14056 .operands = &.{
14057 .{ .kind = .id_result_type, .quantifier = .required },
14058 .{ .kind = .id_result, .quantifier = .required },
14059 .{ .kind = .id_ref, .quantifier = .required },
14060 },
14061 },
14062 .{
14063 .name = "OpConvertHandleToSamplerINTEL",
14064 .opcode = 6530,
14065 .operands = &.{
14066 .{ .kind = .id_result_type, .quantifier = .required },
14067 .{ .kind = .id_result, .quantifier = .required },
14068 .{ .kind = .id_ref, .quantifier = .required },
14069 },
14070 },
14071 .{
14072 .name = "OpConvertHandleToSampledImageINTEL",
14073 .opcode = 6531,
14074 .operands = &.{
14075 .{ .kind = .id_result_type, .quantifier = .required },
14076 .{ .kind = .id_result, .quantifier = .required },
14077 .{ .kind = .id_ref, .quantifier = .required },
14078 },
14079 },
14080 },
14081 .spv_amd_shader_trinary_minmax => &.{
14082 .{
14083 .name = "FMin3AMD",
14084 .opcode = 1,
14085 .operands = &.{
14086 .{ .kind = .id_ref, .quantifier = .required },
14087 .{ .kind = .id_ref, .quantifier = .required },
14088 .{ .kind = .id_ref, .quantifier = .required },
14089 },
14090 },
14091 .{
14092 .name = "UMin3AMD",
14093 .opcode = 2,
14094 .operands = &.{
14095 .{ .kind = .id_ref, .quantifier = .required },
14096 .{ .kind = .id_ref, .quantifier = .required },
14097 .{ .kind = .id_ref, .quantifier = .required },
14098 },
14099 },
14100 .{
14101 .name = "SMin3AMD",
14102 .opcode = 3,
14103 .operands = &.{
14104 .{ .kind = .id_ref, .quantifier = .required },
14105 .{ .kind = .id_ref, .quantifier = .required },
14106 .{ .kind = .id_ref, .quantifier = .required },
14107 },
14108 },
14109 .{
14110 .name = "FMax3AMD",
12820 .opcode = 4,14111 .opcode = 4,
12821 .operands = &[_]Operand{14112 .operands = &.{
12822 .{ .kind = .IdRef, .quantifier = .required },14113 .{ .kind = .id_ref, .quantifier = .required },
14114 .{ .kind = .id_ref, .quantifier = .required },
14115 .{ .kind = .id_ref, .quantifier = .required },
12823 },14116 },
12824 },14117 },
12825 .{14118 .{
12826 .name = "asinpi",14119 .name = "UMax3AMD",
12827 .opcode = 5,14120 .opcode = 5,
12828 .operands = &[_]Operand{14121 .operands = &.{
12829 .{ .kind = .IdRef, .quantifier = .required },14122 .{ .kind = .id_ref, .quantifier = .required },
14123 .{ .kind = .id_ref, .quantifier = .required },
14124 .{ .kind = .id_ref, .quantifier = .required },
12830 },14125 },
12831 },14126 },
12832 .{14127 .{
12833 .name = "atan",14128 .name = "SMax3AMD",
12834 .opcode = 6,14129 .opcode = 6,
12835 .operands = &[_]Operand{14130 .operands = &.{
12836 .{ .kind = .IdRef, .quantifier = .required },14131 .{ .kind = .id_ref, .quantifier = .required },
14132 .{ .kind = .id_ref, .quantifier = .required },
14133 .{ .kind = .id_ref, .quantifier = .required },
12837 },14134 },
12838 },14135 },
12839 .{14136 .{
12840 .name = "atan2",14137 .name = "FMid3AMD",
12841 .opcode = 7,14138 .opcode = 7,
12842 .operands = &[_]Operand{14139 .operands = &.{
12843 .{ .kind = .IdRef, .quantifier = .required },14140 .{ .kind = .id_ref, .quantifier = .required },
12844 .{ .kind = .IdRef, .quantifier = .required },14141 .{ .kind = .id_ref, .quantifier = .required },
14142 .{ .kind = .id_ref, .quantifier = .required },
12845 },14143 },
12846 },14144 },
12847 .{14145 .{
12848 .name = "atanh",14146 .name = "UMid3AMD",
12849 .opcode = 8,14147 .opcode = 8,
12850 .operands = &[_]Operand{14148 .operands = &.{
12851 .{ .kind = .IdRef, .quantifier = .required },14149 .{ .kind = .id_ref, .quantifier = .required },
14150 .{ .kind = .id_ref, .quantifier = .required },
14151 .{ .kind = .id_ref, .quantifier = .required },
12852 },14152 },
12853 },14153 },
12854 .{14154 .{
12855 .name = "atanpi",14155 .name = "SMid3AMD",
12856 .opcode = 9,14156 .opcode = 9,
12857 .operands = &[_]Operand{14157 .operands = &.{
12858 .{ .kind = .IdRef, .quantifier = .required },14158 .{ .kind = .id_ref, .quantifier = .required },
14159 .{ .kind = .id_ref, .quantifier = .required },
14160 .{ .kind = .id_ref, .quantifier = .required },
12859 },14161 },
12860 },14162 },
14163 },
14164 .spv_ext_inst_type_tosa_001000_1 => &.{
12861 .{14165 .{
12862 .name = "atan2pi",14166 .name = "ARGMAX",
14167 .opcode = 0,
14168 .operands = &.{
14169 .{ .kind = .id_ref, .quantifier = .required },
14170 .{ .kind = .id_ref, .quantifier = .required },
14171 .{ .kind = .id_ref, .quantifier = .required },
14172 },
14173 },
14174 .{
14175 .name = "AVG_POOL2D",
14176 .opcode = 1,
14177 .operands = &.{
14178 .{ .kind = .id_ref, .quantifier = .required },
14179 .{ .kind = .id_ref, .quantifier = .required },
14180 .{ .kind = .id_ref, .quantifier = .required },
14181 .{ .kind = .id_ref, .quantifier = .required },
14182 .{ .kind = .id_ref, .quantifier = .required },
14183 .{ .kind = .id_ref, .quantifier = .required },
14184 .{ .kind = .id_ref, .quantifier = .required },
14185 },
14186 },
14187 .{
14188 .name = "CONV2D",
14189 .opcode = 2,
14190 .operands = &.{
14191 .{ .kind = .id_ref, .quantifier = .required },
14192 .{ .kind = .id_ref, .quantifier = .required },
14193 .{ .kind = .id_ref, .quantifier = .required },
14194 .{ .kind = .id_ref, .quantifier = .required },
14195 .{ .kind = .id_ref, .quantifier = .required },
14196 .{ .kind = .id_ref, .quantifier = .required },
14197 .{ .kind = .id_ref, .quantifier = .required },
14198 .{ .kind = .id_ref, .quantifier = .required },
14199 .{ .kind = .id_ref, .quantifier = .required },
14200 .{ .kind = .id_ref, .quantifier = .required },
14201 },
14202 },
14203 .{
14204 .name = "CONV3D",
14205 .opcode = 3,
14206 .operands = &.{
14207 .{ .kind = .id_ref, .quantifier = .required },
14208 .{ .kind = .id_ref, .quantifier = .required },
14209 .{ .kind = .id_ref, .quantifier = .required },
14210 .{ .kind = .id_ref, .quantifier = .required },
14211 .{ .kind = .id_ref, .quantifier = .required },
14212 .{ .kind = .id_ref, .quantifier = .required },
14213 .{ .kind = .id_ref, .quantifier = .required },
14214 .{ .kind = .id_ref, .quantifier = .required },
14215 .{ .kind = .id_ref, .quantifier = .required },
14216 .{ .kind = .id_ref, .quantifier = .required },
14217 },
14218 },
14219 .{
14220 .name = "DEPTHWISE_CONV2D",
14221 .opcode = 4,
14222 .operands = &.{
14223 .{ .kind = .id_ref, .quantifier = .required },
14224 .{ .kind = .id_ref, .quantifier = .required },
14225 .{ .kind = .id_ref, .quantifier = .required },
14226 .{ .kind = .id_ref, .quantifier = .required },
14227 .{ .kind = .id_ref, .quantifier = .required },
14228 .{ .kind = .id_ref, .quantifier = .required },
14229 .{ .kind = .id_ref, .quantifier = .required },
14230 .{ .kind = .id_ref, .quantifier = .required },
14231 .{ .kind = .id_ref, .quantifier = .required },
14232 .{ .kind = .id_ref, .quantifier = .required },
14233 },
14234 },
14235 .{
14236 .name = "FFT2D",
14237 .opcode = 5,
14238 .operands = &.{
14239 .{ .kind = .id_ref, .quantifier = .required },
14240 .{ .kind = .id_ref, .quantifier = .required },
14241 .{ .kind = .id_ref, .quantifier = .required },
14242 .{ .kind = .id_ref, .quantifier = .required },
14243 },
14244 },
14245 .{
14246 .name = "MATMUL",
14247 .opcode = 6,
14248 .operands = &.{
14249 .{ .kind = .id_ref, .quantifier = .required },
14250 .{ .kind = .id_ref, .quantifier = .required },
14251 .{ .kind = .id_ref, .quantifier = .required },
14252 .{ .kind = .id_ref, .quantifier = .required },
14253 },
14254 },
14255 .{
14256 .name = "MAX_POOL2D",
14257 .opcode = 7,
14258 .operands = &.{
14259 .{ .kind = .id_ref, .quantifier = .required },
14260 .{ .kind = .id_ref, .quantifier = .required },
14261 .{ .kind = .id_ref, .quantifier = .required },
14262 .{ .kind = .id_ref, .quantifier = .required },
14263 .{ .kind = .id_ref, .quantifier = .required },
14264 },
14265 },
14266 .{
14267 .name = "RFFT2D",
14268 .opcode = 8,
14269 .operands = &.{
14270 .{ .kind = .id_ref, .quantifier = .required },
14271 .{ .kind = .id_ref, .quantifier = .required },
14272 },
14273 },
14274 .{
14275 .name = "TRANSPOSE_CONV2D",
14276 .opcode = 9,
14277 .operands = &.{
14278 .{ .kind = .id_ref, .quantifier = .required },
14279 .{ .kind = .id_ref, .quantifier = .required },
14280 .{ .kind = .id_ref, .quantifier = .required },
14281 .{ .kind = .id_ref, .quantifier = .required },
14282 .{ .kind = .id_ref, .quantifier = .required },
14283 .{ .kind = .id_ref, .quantifier = .required },
14284 .{ .kind = .id_ref, .quantifier = .required },
14285 .{ .kind = .id_ref, .quantifier = .required },
14286 .{ .kind = .id_ref, .quantifier = .required },
14287 },
14288 },
14289 .{
14290 .name = "CLAMP",
12863 .opcode = 10,14291 .opcode = 10,
12864 .operands = &[_]Operand{14292 .operands = &.{
12865 .{ .kind = .IdRef, .quantifier = .required },14293 .{ .kind = .id_ref, .quantifier = .required },
12866 .{ .kind = .IdRef, .quantifier = .required },14294 .{ .kind = .id_ref, .quantifier = .required },
14295 .{ .kind = .id_ref, .quantifier = .required },
14296 .{ .kind = .id_ref, .quantifier = .required },
12867 },14297 },
12868 },14298 },
12869 .{14299 .{
12870 .name = "cbrt",14300 .name = "ERF",
12871 .opcode = 11,14301 .opcode = 11,
12872 .operands = &[_]Operand{14302 .operands = &.{
12873 .{ .kind = .IdRef, .quantifier = .required },14303 .{ .kind = .id_ref, .quantifier = .required },
12874 },14304 },
12875 },14305 },
12876 .{14306 .{
12877 .name = "ceil",14307 .name = "SIGMOID",
12878 .opcode = 12,14308 .opcode = 12,
12879 .operands = &[_]Operand{14309 .operands = &.{
12880 .{ .kind = .IdRef, .quantifier = .required },14310 .{ .kind = .id_ref, .quantifier = .required },
12881 },14311 },
12882 },14312 },
12883 .{14313 .{
12884 .name = "copysign",14314 .name = "TANH",
12885 .opcode = 13,14315 .opcode = 13,
12886 .operands = &[_]Operand{14316 .operands = &.{
12887 .{ .kind = .IdRef, .quantifier = .required },14317 .{ .kind = .id_ref, .quantifier = .required },
12888 .{ .kind = .IdRef, .quantifier = .required },
12889 },14318 },
12890 },14319 },
12891 .{14320 .{
12892 .name = "cos",14321 .name = "ADD",
12893 .opcode = 14,14322 .opcode = 14,
12894 .operands = &[_]Operand{14323 .operands = &.{
12895 .{ .kind = .IdRef, .quantifier = .required },14324 .{ .kind = .id_ref, .quantifier = .required },
14325 .{ .kind = .id_ref, .quantifier = .required },
12896 },14326 },
12897 },14327 },
12898 .{14328 .{
12899 .name = "cosh",14329 .name = "ARITHMETIC_RIGHT_SHIFT",
12900 .opcode = 15,14330 .opcode = 15,
12901 .operands = &[_]Operand{14331 .operands = &.{
12902 .{ .kind = .IdRef, .quantifier = .required },14332 .{ .kind = .id_ref, .quantifier = .required },
14333 .{ .kind = .id_ref, .quantifier = .required },
14334 .{ .kind = .id_ref, .quantifier = .required },
12903 },14335 },
12904 },14336 },
12905 .{14337 .{
12906 .name = "cospi",14338 .name = "BITWISE_AND",
12907 .opcode = 16,14339 .opcode = 16,
12908 .operands = &[_]Operand{14340 .operands = &.{
12909 .{ .kind = .IdRef, .quantifier = .required },14341 .{ .kind = .id_ref, .quantifier = .required },
14342 .{ .kind = .id_ref, .quantifier = .required },
12910 },14343 },
12911 },14344 },
12912 .{14345 .{
12913 .name = "erfc",14346 .name = "BITWISE_OR",
12914 .opcode = 17,14347 .opcode = 17,
12915 .operands = &[_]Operand{14348 .operands = &.{
12916 .{ .kind = .IdRef, .quantifier = .required },14349 .{ .kind = .id_ref, .quantifier = .required },
14350 .{ .kind = .id_ref, .quantifier = .required },
12917 },14351 },
12918 },14352 },
12919 .{14353 .{
12920 .name = "erf",14354 .name = "BITWISE_XOR",
12921 .opcode = 18,14355 .opcode = 18,
12922 .operands = &[_]Operand{14356 .operands = &.{
12923 .{ .kind = .IdRef, .quantifier = .required },14357 .{ .kind = .id_ref, .quantifier = .required },
14358 .{ .kind = .id_ref, .quantifier = .required },
12924 },14359 },
12925 },14360 },
12926 .{14361 .{
12927 .name = "exp",14362 .name = "INTDIV",
12928 .opcode = 19,14363 .opcode = 19,
12929 .operands = &[_]Operand{14364 .operands = &.{
12930 .{ .kind = .IdRef, .quantifier = .required },14365 .{ .kind = .id_ref, .quantifier = .required },
14366 .{ .kind = .id_ref, .quantifier = .required },
12931 },14367 },
12932 },14368 },
12933 .{14369 .{
12934 .name = "exp2",14370 .name = "LOGICAL_AND",
12935 .opcode = 20,14371 .opcode = 20,
12936 .operands = &[_]Operand{14372 .operands = &.{
12937 .{ .kind = .IdRef, .quantifier = .required },14373 .{ .kind = .id_ref, .quantifier = .required },
14374 .{ .kind = .id_ref, .quantifier = .required },
12938 },14375 },
12939 },14376 },
12940 .{14377 .{
12941 .name = "exp10",14378 .name = "LOGICAL_LEFT_SHIFT",
12942 .opcode = 21,14379 .opcode = 21,
12943 .operands = &[_]Operand{14380 .operands = &.{
12944 .{ .kind = .IdRef, .quantifier = .required },14381 .{ .kind = .id_ref, .quantifier = .required },
14382 .{ .kind = .id_ref, .quantifier = .required },
12945 },14383 },
12946 },14384 },
12947 .{14385 .{
12948 .name = "expm1",14386 .name = "LOGICAL_RIGHT_SHIFT",
12949 .opcode = 22,14387 .opcode = 22,
12950 .operands = &[_]Operand{14388 .operands = &.{
12951 .{ .kind = .IdRef, .quantifier = .required },14389 .{ .kind = .id_ref, .quantifier = .required },
14390 .{ .kind = .id_ref, .quantifier = .required },
12952 },14391 },
12953 },14392 },
12954 .{14393 .{
12955 .name = "fabs",14394 .name = "LOGICAL_OR",
12956 .opcode = 23,14395 .opcode = 23,
12957 .operands = &[_]Operand{14396 .operands = &.{
12958 .{ .kind = .IdRef, .quantifier = .required },14397 .{ .kind = .id_ref, .quantifier = .required },
14398 .{ .kind = .id_ref, .quantifier = .required },
12959 },14399 },
12960 },14400 },
12961 .{14401 .{
12962 .name = "fdim",14402 .name = "LOGICAL_XOR",
12963 .opcode = 24,14403 .opcode = 24,
12964 .operands = &[_]Operand{14404 .operands = &.{
12965 .{ .kind = .IdRef, .quantifier = .required },14405 .{ .kind = .id_ref, .quantifier = .required },
12966 .{ .kind = .IdRef, .quantifier = .required },14406 .{ .kind = .id_ref, .quantifier = .required },
12967 },14407 },
12968 },14408 },
12969 .{14409 .{
12970 .name = "floor",14410 .name = "MAXIMUM",
12971 .opcode = 25,14411 .opcode = 25,
12972 .operands = &[_]Operand{14412 .operands = &.{
12973 .{ .kind = .IdRef, .quantifier = .required },14413 .{ .kind = .id_ref, .quantifier = .required },
14414 .{ .kind = .id_ref, .quantifier = .required },
14415 .{ .kind = .id_ref, .quantifier = .required },
12974 },14416 },
12975 },14417 },
12976 .{14418 .{
12977 .name = "fma",14419 .name = "MINIMUM",
12978 .opcode = 26,14420 .opcode = 26,
12979 .operands = &[_]Operand{14421 .operands = &.{
12980 .{ .kind = .IdRef, .quantifier = .required },14422 .{ .kind = .id_ref, .quantifier = .required },
12981 .{ .kind = .IdRef, .quantifier = .required },14423 .{ .kind = .id_ref, .quantifier = .required },
12982 .{ .kind = .IdRef, .quantifier = .required },14424 .{ .kind = .id_ref, .quantifier = .required },
12983 },14425 },
12984 },14426 },
12985 .{14427 .{
12986 .name = "fmax",14428 .name = "MUL",
12987 .opcode = 27,14429 .opcode = 27,
12988 .operands = &[_]Operand{14430 .operands = &.{
12989 .{ .kind = .IdRef, .quantifier = .required },14431 .{ .kind = .id_ref, .quantifier = .required },
12990 .{ .kind = .IdRef, .quantifier = .required },14432 .{ .kind = .id_ref, .quantifier = .required },
14433 .{ .kind = .id_ref, .quantifier = .required },
12991 },14434 },
12992 },14435 },
12993 .{14436 .{
12994 .name = "fmin",14437 .name = "POW",
12995 .opcode = 28,14438 .opcode = 28,
12996 .operands = &[_]Operand{14439 .operands = &.{
12997 .{ .kind = .IdRef, .quantifier = .required },14440 .{ .kind = .id_ref, .quantifier = .required },
12998 .{ .kind = .IdRef, .quantifier = .required },14441 .{ .kind = .id_ref, .quantifier = .required },
12999 },14442 },
13000 },14443 },
13001 .{14444 .{
13002 .name = "fmod",14445 .name = "SUB",
13003 .opcode = 29,14446 .opcode = 29,
13004 .operands = &[_]Operand{14447 .operands = &.{
13005 .{ .kind = .IdRef, .quantifier = .required },14448 .{ .kind = .id_ref, .quantifier = .required },
13006 .{ .kind = .IdRef, .quantifier = .required },14449 .{ .kind = .id_ref, .quantifier = .required },
13007 },14450 },
13008 },14451 },
13009 .{14452 .{
13010 .name = "fract",14453 .name = "TABLE",
13011 .opcode = 30,14454 .opcode = 30,
13012 .operands = &[_]Operand{14455 .operands = &.{
13013 .{ .kind = .IdRef, .quantifier = .required },14456 .{ .kind = .id_ref, .quantifier = .required },
13014 .{ .kind = .IdRef, .quantifier = .required },14457 .{ .kind = .id_ref, .quantifier = .required },
13015 },14458 },
13016 },14459 },
13017 .{14460 .{
13018 .name = "frexp",14461 .name = "ABS",
13019 .opcode = 31,14462 .opcode = 31,
13020 .operands = &[_]Operand{14463 .operands = &.{
13021 .{ .kind = .IdRef, .quantifier = .required },14464 .{ .kind = .id_ref, .quantifier = .required },
13022 .{ .kind = .IdRef, .quantifier = .required },
13023 },14465 },
13024 },14466 },
13025 .{14467 .{
13026 .name = "hypot",14468 .name = "BITWISE_NOT",
13027 .opcode = 32,14469 .opcode = 32,
13028 .operands = &[_]Operand{14470 .operands = &.{
13029 .{ .kind = .IdRef, .quantifier = .required },14471 .{ .kind = .id_ref, .quantifier = .required },
13030 .{ .kind = .IdRef, .quantifier = .required },
13031 },14472 },
13032 },14473 },
13033 .{14474 .{
13034 .name = "ilogb",14475 .name = "CEIL",
13035 .opcode = 33,14476 .opcode = 33,
13036 .operands = &[_]Operand{14477 .operands = &.{
13037 .{ .kind = .IdRef, .quantifier = .required },14478 .{ .kind = .id_ref, .quantifier = .required },
13038 },14479 },
13039 },14480 },
13040 .{14481 .{
13041 .name = "ldexp",14482 .name = "CLZ",
13042 .opcode = 34,14483 .opcode = 34,
13043 .operands = &[_]Operand{14484 .operands = &.{
13044 .{ .kind = .IdRef, .quantifier = .required },14485 .{ .kind = .id_ref, .quantifier = .required },
13045 .{ .kind = .IdRef, .quantifier = .required },
13046 },14486 },
13047 },14487 },
13048 .{14488 .{
13049 .name = "lgamma",14489 .name = "COS",
13050 .opcode = 35,14490 .opcode = 35,
13051 .operands = &[_]Operand{14491 .operands = &.{
13052 .{ .kind = .IdRef, .quantifier = .required },14492 .{ .kind = .id_ref, .quantifier = .required },
13053 },14493 },
13054 },14494 },
13055 .{14495 .{
13056 .name = "lgamma_r",14496 .name = "EXP",
13057 .opcode = 36,14497 .opcode = 36,
13058 .operands = &[_]Operand{14498 .operands = &.{
13059 .{ .kind = .IdRef, .quantifier = .required },14499 .{ .kind = .id_ref, .quantifier = .required },
13060 .{ .kind = .IdRef, .quantifier = .required },
13061 },14500 },
13062 },14501 },
13063 .{14502 .{
13064 .name = "log",14503 .name = "FLOOR",
13065 .opcode = 37,14504 .opcode = 37,
13066 .operands = &[_]Operand{14505 .operands = &.{
13067 .{ .kind = .IdRef, .quantifier = .required },14506 .{ .kind = .id_ref, .quantifier = .required },
13068 },14507 },
13069 },14508 },
13070 .{14509 .{
13071 .name = "log2",14510 .name = "LOG",
13072 .opcode = 38,14511 .opcode = 38,
13073 .operands = &[_]Operand{14512 .operands = &.{
13074 .{ .kind = .IdRef, .quantifier = .required },14513 .{ .kind = .id_ref, .quantifier = .required },
13075 },14514 },
13076 },14515 },
13077 .{14516 .{
13078 .name = "log10",14517 .name = "LOGICAL_NOT",
13079 .opcode = 39,14518 .opcode = 39,
13080 .operands = &[_]Operand{14519 .operands = &.{
13081 .{ .kind = .IdRef, .quantifier = .required },14520 .{ .kind = .id_ref, .quantifier = .required },
13082 },14521 },
13083 },14522 },
13084 .{14523 .{
13085 .name = "log1p",14524 .name = "NEGATE",
13086 .opcode = 40,14525 .opcode = 40,
13087 .operands = &[_]Operand{14526 .operands = &.{
13088 .{ .kind = .IdRef, .quantifier = .required },14527 .{ .kind = .id_ref, .quantifier = .required },
14528 .{ .kind = .id_ref, .quantifier = .required },
14529 .{ .kind = .id_ref, .quantifier = .required },
13089 },14530 },
13090 },14531 },
13091 .{14532 .{
13092 .name = "logb",14533 .name = "RECIPROCAL",
13093 .opcode = 41,14534 .opcode = 41,
13094 .operands = &[_]Operand{14535 .operands = &.{
13095 .{ .kind = .IdRef, .quantifier = .required },14536 .{ .kind = .id_ref, .quantifier = .required },
13096 },14537 },
13097 },14538 },
13098 .{14539 .{
13099 .name = "mad",14540 .name = "RSQRT",
13100 .opcode = 42,14541 .opcode = 42,
13101 .operands = &[_]Operand{14542 .operands = &.{
13102 .{ .kind = .IdRef, .quantifier = .required },14543 .{ .kind = .id_ref, .quantifier = .required },
13103 .{ .kind = .IdRef, .quantifier = .required },
13104 .{ .kind = .IdRef, .quantifier = .required },
13105 },14544 },
13106 },14545 },
13107 .{14546 .{
13108 .name = "maxmag",14547 .name = "SIN",
13109 .opcode = 43,14548 .opcode = 43,
13110 .operands = &[_]Operand{14549 .operands = &.{
13111 .{ .kind = .IdRef, .quantifier = .required },14550 .{ .kind = .id_ref, .quantifier = .required },
13112 .{ .kind = .IdRef, .quantifier = .required },
13113 },14551 },
13114 },14552 },
13115 .{14553 .{
13116 .name = "minmag",14554 .name = "SELECT",
13117 .opcode = 44,14555 .opcode = 44,
13118 .operands = &[_]Operand{14556 .operands = &.{
13119 .{ .kind = .IdRef, .quantifier = .required },14557 .{ .kind = .id_ref, .quantifier = .required },
13120 .{ .kind = .IdRef, .quantifier = .required },14558 .{ .kind = .id_ref, .quantifier = .required },
14559 .{ .kind = .id_ref, .quantifier = .required },
13121 },14560 },
13122 },14561 },
13123 .{14562 .{
13124 .name = "modf",14563 .name = "EQUAL",
13125 .opcode = 45,14564 .opcode = 45,
13126 .operands = &[_]Operand{14565 .operands = &.{
13127 .{ .kind = .IdRef, .quantifier = .required },14566 .{ .kind = .id_ref, .quantifier = .required },
13128 .{ .kind = .IdRef, .quantifier = .required },14567 .{ .kind = .id_ref, .quantifier = .required },
13129 },14568 },
13130 },14569 },
13131 .{14570 .{
13132 .name = "nan",14571 .name = "GREATER",
13133 .opcode = 46,14572 .opcode = 46,
13134 .operands = &[_]Operand{14573 .operands = &.{
13135 .{ .kind = .IdRef, .quantifier = .required },14574 .{ .kind = .id_ref, .quantifier = .required },
14575 .{ .kind = .id_ref, .quantifier = .required },
13136 },14576 },
13137 },14577 },
13138 .{14578 .{
13139 .name = "nextafter",14579 .name = "GREATER_EQUAL",
13140 .opcode = 47,14580 .opcode = 47,
13141 .operands = &[_]Operand{14581 .operands = &.{
13142 .{ .kind = .IdRef, .quantifier = .required },14582 .{ .kind = .id_ref, .quantifier = .required },
13143 .{ .kind = .IdRef, .quantifier = .required },14583 .{ .kind = .id_ref, .quantifier = .required },
13144 },14584 },
13145 },14585 },
13146 .{14586 .{
13147 .name = "pow",14587 .name = "REDUCE_ALL",
13148 .opcode = 48,14588 .opcode = 48,
13149 .operands = &[_]Operand{14589 .operands = &.{
13150 .{ .kind = .IdRef, .quantifier = .required },14590 .{ .kind = .id_ref, .quantifier = .required },
13151 .{ .kind = .IdRef, .quantifier = .required },14591 .{ .kind = .id_ref, .quantifier = .required },
13152 },14592 },
13153 },14593 },
13154 .{14594 .{
13155 .name = "pown",14595 .name = "REDUCE_ANY",
13156 .opcode = 49,14596 .opcode = 49,
13157 .operands = &[_]Operand{14597 .operands = &.{
13158 .{ .kind = .IdRef, .quantifier = .required },14598 .{ .kind = .id_ref, .quantifier = .required },
13159 .{ .kind = .IdRef, .quantifier = .required },14599 .{ .kind = .id_ref, .quantifier = .required },
13160 },14600 },
13161 },14601 },
13162 .{14602 .{
13163 .name = "powr",14603 .name = "REDUCE_MAX",
13164 .opcode = 50,14604 .opcode = 50,
13165 .operands = &[_]Operand{14605 .operands = &.{
13166 .{ .kind = .IdRef, .quantifier = .required },14606 .{ .kind = .id_ref, .quantifier = .required },
13167 .{ .kind = .IdRef, .quantifier = .required },14607 .{ .kind = .id_ref, .quantifier = .required },
14608 .{ .kind = .id_ref, .quantifier = .required },
13168 },14609 },
13169 },14610 },
13170 .{14611 .{
13171 .name = "remainder",14612 .name = "REDUCE_MIN",
13172 .opcode = 51,14613 .opcode = 51,
13173 .operands = &[_]Operand{14614 .operands = &.{
13174 .{ .kind = .IdRef, .quantifier = .required },14615 .{ .kind = .id_ref, .quantifier = .required },
13175 .{ .kind = .IdRef, .quantifier = .required },14616 .{ .kind = .id_ref, .quantifier = .required },
14617 .{ .kind = .id_ref, .quantifier = .required },
13176 },14618 },
13177 },14619 },
13178 .{14620 .{
13179 .name = "remquo",14621 .name = "REDUCE_PRODUCT",
13180 .opcode = 52,14622 .opcode = 52,
13181 .operands = &[_]Operand{14623 .operands = &.{
13182 .{ .kind = .IdRef, .quantifier = .required },14624 .{ .kind = .id_ref, .quantifier = .required },
13183 .{ .kind = .IdRef, .quantifier = .required },14625 .{ .kind = .id_ref, .quantifier = .required },
13184 .{ .kind = .IdRef, .quantifier = .required },
13185 },14626 },
13186 },14627 },
13187 .{14628 .{
13188 .name = "rint",14629 .name = "REDUCE_SUM",
13189 .opcode = 53,14630 .opcode = 53,
13190 .operands = &[_]Operand{14631 .operands = &.{
13191 .{ .kind = .IdRef, .quantifier = .required },14632 .{ .kind = .id_ref, .quantifier = .required },
14633 .{ .kind = .id_ref, .quantifier = .required },
13192 },14634 },
13193 },14635 },
13194 .{14636 .{
13195 .name = "rootn",14637 .name = "CONCAT",
13196 .opcode = 54,14638 .opcode = 54,
13197 .operands = &[_]Operand{14639 .operands = &.{
13198 .{ .kind = .IdRef, .quantifier = .required },14640 .{ .kind = .id_ref, .quantifier = .required },
13199 .{ .kind = .IdRef, .quantifier = .required },14641 .{ .kind = .id_ref, .quantifier = .variadic },
13200 },14642 },
13201 },14643 },
13202 .{14644 .{
13203 .name = "round",14645 .name = "PAD",
13204 .opcode = 55,14646 .opcode = 55,
13205 .operands = &[_]Operand{14647 .operands = &.{
13206 .{ .kind = .IdRef, .quantifier = .required },14648 .{ .kind = .id_ref, .quantifier = .required },
14649 .{ .kind = .id_ref, .quantifier = .required },
14650 .{ .kind = .id_ref, .quantifier = .required },
13207 },14651 },
13208 },14652 },
13209 .{14653 .{
13210 .name = "rsqrt",14654 .name = "RESHAPE",
13211 .opcode = 56,14655 .opcode = 56,
13212 .operands = &[_]Operand{14656 .operands = &.{
13213 .{ .kind = .IdRef, .quantifier = .required },14657 .{ .kind = .id_ref, .quantifier = .required },
14658 .{ .kind = .id_ref, .quantifier = .required },
13214 },14659 },
13215 },14660 },
13216 .{14661 .{
13217 .name = "sin",14662 .name = "REVERSE",
13218 .opcode = 57,14663 .opcode = 57,
13219 .operands = &[_]Operand{14664 .operands = &.{
13220 .{ .kind = .IdRef, .quantifier = .required },14665 .{ .kind = .id_ref, .quantifier = .required },
14666 .{ .kind = .id_ref, .quantifier = .required },
13221 },14667 },
13222 },14668 },
13223 .{14669 .{
13224 .name = "sincos",14670 .name = "SLICE",
13225 .opcode = 58,14671 .opcode = 58,
13226 .operands = &[_]Operand{14672 .operands = &.{
13227 .{ .kind = .IdRef, .quantifier = .required },14673 .{ .kind = .id_ref, .quantifier = .required },
13228 .{ .kind = .IdRef, .quantifier = .required },14674 .{ .kind = .id_ref, .quantifier = .required },
14675 .{ .kind = .id_ref, .quantifier = .required },
13229 },14676 },
13230 },14677 },
13231 .{14678 .{
13232 .name = "sinh",14679 .name = "TILE",
13233 .opcode = 59,14680 .opcode = 59,
13234 .operands = &[_]Operand{14681 .operands = &.{
13235 .{ .kind = .IdRef, .quantifier = .required },14682 .{ .kind = .id_ref, .quantifier = .required },
14683 .{ .kind = .id_ref, .quantifier = .required },
13236 },14684 },
13237 },14685 },
13238 .{14686 .{
13239 .name = "sinpi",14687 .name = "TRANSPOSE",
13240 .opcode = 60,14688 .opcode = 60,
13241 .operands = &[_]Operand{14689 .operands = &.{
13242 .{ .kind = .IdRef, .quantifier = .required },14690 .{ .kind = .id_ref, .quantifier = .required },
14691 .{ .kind = .id_ref, .quantifier = .required },
13243 },14692 },
13244 },14693 },
13245 .{14694 .{
13246 .name = "sqrt",14695 .name = "GATHER",
13247 .opcode = 61,14696 .opcode = 61,
13248 .operands = &[_]Operand{14697 .operands = &.{
13249 .{ .kind = .IdRef, .quantifier = .required },14698 .{ .kind = .id_ref, .quantifier = .required },
14699 .{ .kind = .id_ref, .quantifier = .required },
13250 },14700 },
13251 },14701 },
13252 .{14702 .{
13253 .name = "tan",14703 .name = "SCATTER",
13254 .opcode = 62,14704 .opcode = 62,
13255 .operands = &[_]Operand{14705 .operands = &.{
13256 .{ .kind = .IdRef, .quantifier = .required },14706 .{ .kind = .id_ref, .quantifier = .required },
14707 .{ .kind = .id_ref, .quantifier = .required },
14708 .{ .kind = .id_ref, .quantifier = .required },
13257 },14709 },
13258 },14710 },
13259 .{14711 .{
13260 .name = "tanh",14712 .name = "RESIZE",
13261 .opcode = 63,14713 .opcode = 63,
13262 .operands = &[_]Operand{14714 .operands = &.{
13263 .{ .kind = .IdRef, .quantifier = .required },14715 .{ .kind = .id_ref, .quantifier = .required },
14716 .{ .kind = .id_ref, .quantifier = .required },
14717 .{ .kind = .id_ref, .quantifier = .required },
14718 .{ .kind = .id_ref, .quantifier = .required },
14719 .{ .kind = .id_ref, .quantifier = .required },
13264 },14720 },
13265 },14721 },
13266 .{14722 .{
13267 .name = "tanpi",14723 .name = "CAST",
13268 .opcode = 64,14724 .opcode = 64,
13269 .operands = &[_]Operand{14725 .operands = &.{
13270 .{ .kind = .IdRef, .quantifier = .required },14726 .{ .kind = .id_ref, .quantifier = .required },
13271 },14727 },
13272 },14728 },
13273 .{14729 .{
13274 .name = "tgamma",14730 .name = "RESCALE",
13275 .opcode = 65,14731 .opcode = 65,
13276 .operands = &[_]Operand{14732 .operands = &.{
13277 .{ .kind = .IdRef, .quantifier = .required },14733 .{ .kind = .id_ref, .quantifier = .required },
14734 .{ .kind = .id_ref, .quantifier = .required },
14735 .{ .kind = .id_ref, .quantifier = .required },
14736 .{ .kind = .id_ref, .quantifier = .required },
14737 .{ .kind = .id_ref, .quantifier = .required },
14738 .{ .kind = .id_ref, .quantifier = .required },
14739 .{ .kind = .id_ref, .quantifier = .required },
14740 .{ .kind = .id_ref, .quantifier = .required },
14741 .{ .kind = .id_ref, .quantifier = .required },
14742 .{ .kind = .id_ref, .quantifier = .required },
13278 },14743 },
13279 },14744 },
14745 },
14746 .non_semantic_vksp_reflection => &.{
13280 .{14747 .{
13281 .name = "trunc",14748 .name = "Configuration",
13282 .opcode = 66,14749 .opcode = 1,
13283 .operands = &[_]Operand{14750 .operands = &.{
13284 .{ .kind = .IdRef, .quantifier = .required },14751 .{ .kind = .id_ref, .quantifier = .required },
14752 .{ .kind = .id_ref, .quantifier = .required },
14753 .{ .kind = .id_ref, .quantifier = .required },
14754 .{ .kind = .id_ref, .quantifier = .required },
14755 .{ .kind = .id_ref, .quantifier = .required },
14756 .{ .kind = .id_ref, .quantifier = .required },
14757 .{ .kind = .id_ref, .quantifier = .required },
14758 .{ .kind = .id_ref, .quantifier = .required },
14759 .{ .kind = .id_ref, .quantifier = .required },
13285 },14760 },
13286 },14761 },
13287 .{14762 .{
13288 .name = "half_cos",14763 .name = "StartCounter",
13289 .opcode = 67,14764 .opcode = 2,
13290 .operands = &[_]Operand{14765 .operands = &.{
13291 .{ .kind = .IdRef, .quantifier = .required },14766 .{ .kind = .id_ref, .quantifier = .required },
13292 },14767 },
13293 },14768 },
13294 .{14769 .{
13295 .name = "half_divide",14770 .name = "StopCounter",
13296 .opcode = 68,14771 .opcode = 3,
13297 .operands = &[_]Operand{14772 .operands = &.{
13298 .{ .kind = .IdRef, .quantifier = .required },14773 .{ .kind = .id_ref, .quantifier = .required },
13299 .{ .kind = .IdRef, .quantifier = .required },
13300 },14774 },
13301 },14775 },
13302 .{14776 .{
13303 .name = "half_exp",14777 .name = "PushConstants",
13304 .opcode = 69,14778 .opcode = 4,
13305 .operands = &[_]Operand{14779 .operands = &.{
13306 .{ .kind = .IdRef, .quantifier = .required },14780 .{ .kind = .id_ref, .quantifier = .required },
14781 .{ .kind = .id_ref, .quantifier = .required },
14782 .{ .kind = .id_ref, .quantifier = .required },
14783 .{ .kind = .id_ref, .quantifier = .required },
13307 },14784 },
13308 },14785 },
13309 .{14786 .{
13310 .name = "half_exp2",14787 .name = "SpecializationMapEntry",
13311 .opcode = 70,14788 .opcode = 5,
13312 .operands = &[_]Operand{14789 .operands = &.{
13313 .{ .kind = .IdRef, .quantifier = .required },14790 .{ .kind = .id_ref, .quantifier = .required },
14791 .{ .kind = .id_ref, .quantifier = .required },
14792 .{ .kind = .id_ref, .quantifier = .required },
13314 },14793 },
13315 },14794 },
13316 .{14795 .{
13317 .name = "half_exp10",14796 .name = "DescriptorSetBuffer",
13318 .opcode = 71,14797 .opcode = 6,
13319 .operands = &[_]Operand{14798 .operands = &.{
13320 .{ .kind = .IdRef, .quantifier = .required },14799 .{ .kind = .id_ref, .quantifier = .required },
14800 .{ .kind = .id_ref, .quantifier = .required },
14801 .{ .kind = .id_ref, .quantifier = .required },
14802 .{ .kind = .id_ref, .quantifier = .required },
14803 .{ .kind = .id_ref, .quantifier = .required },
14804 .{ .kind = .id_ref, .quantifier = .required },
14805 .{ .kind = .id_ref, .quantifier = .required },
14806 .{ .kind = .id_ref, .quantifier = .required },
14807 .{ .kind = .id_ref, .quantifier = .required },
14808 .{ .kind = .id_ref, .quantifier = .required },
14809 .{ .kind = .id_ref, .quantifier = .required },
14810 .{ .kind = .id_ref, .quantifier = .required },
14811 .{ .kind = .id_ref, .quantifier = .required },
14812 .{ .kind = .id_ref, .quantifier = .required },
14813 .{ .kind = .id_ref, .quantifier = .required },
13321 },14814 },
13322 },14815 },
13323 .{14816 .{
13324 .name = "half_log",14817 .name = "DescriptorSetImage",
13325 .opcode = 72,14818 .opcode = 7,
13326 .operands = &[_]Operand{14819 .operands = &.{
13327 .{ .kind = .IdRef, .quantifier = .required },14820 .{ .kind = .id_ref, .quantifier = .required },
14821 .{ .kind = .id_ref, .quantifier = .required },
14822 .{ .kind = .id_ref, .quantifier = .required },
14823 .{ .kind = .id_ref, .quantifier = .required },
14824 .{ .kind = .id_ref, .quantifier = .required },
14825 .{ .kind = .id_ref, .quantifier = .required },
14826 .{ .kind = .id_ref, .quantifier = .required },
14827 .{ .kind = .id_ref, .quantifier = .required },
14828 .{ .kind = .id_ref, .quantifier = .required },
14829 .{ .kind = .id_ref, .quantifier = .required },
14830 .{ .kind = .id_ref, .quantifier = .required },
14831 .{ .kind = .id_ref, .quantifier = .required },
14832 .{ .kind = .id_ref, .quantifier = .required },
14833 .{ .kind = .id_ref, .quantifier = .required },
14834 .{ .kind = .id_ref, .quantifier = .required },
14835 .{ .kind = .id_ref, .quantifier = .required },
14836 .{ .kind = .id_ref, .quantifier = .required },
14837 .{ .kind = .id_ref, .quantifier = .required },
14838 .{ .kind = .id_ref, .quantifier = .required },
14839 .{ .kind = .id_ref, .quantifier = .required },
14840 .{ .kind = .id_ref, .quantifier = .required },
14841 .{ .kind = .id_ref, .quantifier = .required },
14842 .{ .kind = .id_ref, .quantifier = .required },
14843 .{ .kind = .id_ref, .quantifier = .required },
14844 .{ .kind = .id_ref, .quantifier = .required },
14845 .{ .kind = .id_ref, .quantifier = .required },
14846 .{ .kind = .id_ref, .quantifier = .required },
14847 .{ .kind = .id_ref, .quantifier = .required },
14848 .{ .kind = .id_ref, .quantifier = .required },
14849 .{ .kind = .id_ref, .quantifier = .required },
14850 .{ .kind = .id_ref, .quantifier = .required },
14851 .{ .kind = .id_ref, .quantifier = .required },
14852 .{ .kind = .id_ref, .quantifier = .required },
13328 },14853 },
13329 },14854 },
13330 .{14855 .{
13331 .name = "half_log2",14856 .name = "DescriptorSetSampler",
13332 .opcode = 73,14857 .opcode = 8,
13333 .operands = &[_]Operand{14858 .operands = &.{
13334 .{ .kind = .IdRef, .quantifier = .required },14859 .{ .kind = .id_ref, .quantifier = .required },
14860 .{ .kind = .id_ref, .quantifier = .required },
14861 .{ .kind = .id_ref, .quantifier = .required },
14862 .{ .kind = .id_ref, .quantifier = .required },
14863 .{ .kind = .id_ref, .quantifier = .required },
14864 .{ .kind = .id_ref, .quantifier = .required },
14865 .{ .kind = .id_ref, .quantifier = .required },
14866 .{ .kind = .id_ref, .quantifier = .required },
14867 .{ .kind = .id_ref, .quantifier = .required },
14868 .{ .kind = .id_ref, .quantifier = .required },
14869 .{ .kind = .id_ref, .quantifier = .required },
14870 .{ .kind = .id_ref, .quantifier = .required },
14871 .{ .kind = .id_ref, .quantifier = .required },
14872 .{ .kind = .id_ref, .quantifier = .required },
14873 .{ .kind = .id_ref, .quantifier = .required },
14874 .{ .kind = .id_ref, .quantifier = .required },
14875 .{ .kind = .id_ref, .quantifier = .required },
14876 .{ .kind = .id_ref, .quantifier = .required },
14877 .{ .kind = .id_ref, .quantifier = .required },
13335 },14878 },
13336 },14879 },
14880 },
14881 .spv_amd_shader_explicit_vertex_parameter => &.{
13337 .{14882 .{
13338 .name = "half_log10",14883 .name = "InterpolateAtVertexAMD",
13339 .opcode = 74,14884 .opcode = 1,
13340 .operands = &[_]Operand{14885 .operands = &.{
13341 .{ .kind = .IdRef, .quantifier = .required },14886 .{ .kind = .id_ref, .quantifier = .required },
14887 .{ .kind = .id_ref, .quantifier = .required },
13342 },14888 },
13343 },14889 },
14890 },
14891 .debug_info => &.{
13344 .{14892 .{
13345 .name = "half_powr",14893 .name = "DebugInfoNone",
13346 .opcode = 75,14894 .opcode = 0,
13347 .operands = &[_]Operand{14895 .operands = &.{},
13348 .{ .kind = .IdRef, .quantifier = .required },
13349 .{ .kind = .IdRef, .quantifier = .required },
13350 },
13351 },14896 },
13352 .{14897 .{
13353 .name = "half_recip",14898 .name = "DebugCompilationUnit",
13354 .opcode = 76,14899 .opcode = 1,
13355 .operands = &[_]Operand{14900 .operands = &.{
13356 .{ .kind = .IdRef, .quantifier = .required },14901 .{ .kind = .id_ref, .quantifier = .required },
14902 .{ .kind = .literal_integer, .quantifier = .required },
14903 .{ .kind = .literal_integer, .quantifier = .required },
13357 },14904 },
13358 },14905 },
13359 .{14906 .{
13360 .name = "half_rsqrt",14907 .name = "DebugTypeBasic",
13361 .opcode = 77,14908 .opcode = 2,
13362 .operands = &[_]Operand{14909 .operands = &.{
13363 .{ .kind = .IdRef, .quantifier = .required },14910 .{ .kind = .id_ref, .quantifier = .required },
14911 .{ .kind = .id_ref, .quantifier = .required },
14912 .{ .kind = .debug_info_debug_base_type_attribute_encoding, .quantifier = .required },
13364 },14913 },
13365 },14914 },
13366 .{14915 .{
13367 .name = "half_sin",14916 .name = "DebugTypePointer",
13368 .opcode = 78,14917 .opcode = 3,
13369 .operands = &[_]Operand{14918 .operands = &.{
13370 .{ .kind = .IdRef, .quantifier = .required },14919 .{ .kind = .id_ref, .quantifier = .required },
14920 .{ .kind = .storage_class, .quantifier = .required },
14921 .{ .kind = .debug_info_debug_info_flags, .quantifier = .required },
13371 },14922 },
13372 },14923 },
13373 .{14924 .{
13374 .name = "half_sqrt",14925 .name = "DebugTypeQualifier",
13375 .opcode = 79,14926 .opcode = 4,
13376 .operands = &[_]Operand{14927 .operands = &.{
13377 .{ .kind = .IdRef, .quantifier = .required },14928 .{ .kind = .id_ref, .quantifier = .required },
14929 .{ .kind = .debug_info_debug_type_qualifier, .quantifier = .required },
13378 },14930 },
13379 },14931 },
13380 .{14932 .{
13381 .name = "half_tan",14933 .name = "DebugTypeArray",
13382 .opcode = 80,14934 .opcode = 5,
13383 .operands = &[_]Operand{14935 .operands = &.{
13384 .{ .kind = .IdRef, .quantifier = .required },14936 .{ .kind = .id_ref, .quantifier = .required },
14937 .{ .kind = .id_ref, .quantifier = .variadic },
13385 },14938 },
13386 },14939 },
13387 .{14940 .{
13388 .name = "native_cos",14941 .name = "DebugTypeVector",
13389 .opcode = 81,14942 .opcode = 6,
13390 .operands = &[_]Operand{14943 .operands = &.{
13391 .{ .kind = .IdRef, .quantifier = .required },14944 .{ .kind = .id_ref, .quantifier = .required },
14945 .{ .kind = .literal_integer, .quantifier = .required },
13392 },14946 },
13393 },14947 },
13394 .{14948 .{
13395 .name = "native_divide",14949 .name = "DebugTypedef",
13396 .opcode = 82,14950 .opcode = 7,
13397 .operands = &[_]Operand{14951 .operands = &.{
13398 .{ .kind = .IdRef, .quantifier = .required },14952 .{ .kind = .id_ref, .quantifier = .required },
13399 .{ .kind = .IdRef, .quantifier = .required },14953 .{ .kind = .id_ref, .quantifier = .required },
14954 .{ .kind = .id_ref, .quantifier = .required },
14955 .{ .kind = .literal_integer, .quantifier = .required },
14956 .{ .kind = .literal_integer, .quantifier = .required },
14957 .{ .kind = .id_ref, .quantifier = .required },
13400 },14958 },
13401 },14959 },
13402 .{14960 .{
13403 .name = "native_exp",14961 .name = "DebugTypeFunction",
13404 .opcode = 83,14962 .opcode = 8,
13405 .operands = &[_]Operand{14963 .operands = &.{
13406 .{ .kind = .IdRef, .quantifier = .required },14964 .{ .kind = .id_ref, .quantifier = .required },
14965 .{ .kind = .id_ref, .quantifier = .variadic },
13407 },14966 },
13408 },14967 },
13409 .{14968 .{
13410 .name = "native_exp2",14969 .name = "DebugTypeEnum",
13411 .opcode = 84,14970 .opcode = 9,
13412 .operands = &[_]Operand{14971 .operands = &.{
13413 .{ .kind = .IdRef, .quantifier = .required },14972 .{ .kind = .id_ref, .quantifier = .required },
14973 .{ .kind = .id_ref, .quantifier = .required },
14974 .{ .kind = .id_ref, .quantifier = .required },
14975 .{ .kind = .literal_integer, .quantifier = .required },
14976 .{ .kind = .literal_integer, .quantifier = .required },
14977 .{ .kind = .id_ref, .quantifier = .required },
14978 .{ .kind = .id_ref, .quantifier = .required },
14979 .{ .kind = .debug_info_debug_info_flags, .quantifier = .required },
14980 .{ .kind = .pair_id_ref_id_ref, .quantifier = .variadic },
13414 },14981 },
13415 },14982 },
13416 .{14983 .{
13417 .name = "native_exp10",14984 .name = "DebugTypeComposite",
13418 .opcode = 85,14985 .opcode = 10,
13419 .operands = &[_]Operand{14986 .operands = &.{
13420 .{ .kind = .IdRef, .quantifier = .required },14987 .{ .kind = .id_ref, .quantifier = .required },
14988 .{ .kind = .debug_info_debug_composite_type, .quantifier = .required },
14989 .{ .kind = .id_ref, .quantifier = .required },
14990 .{ .kind = .literal_integer, .quantifier = .required },
14991 .{ .kind = .literal_integer, .quantifier = .required },
14992 .{ .kind = .id_ref, .quantifier = .required },
14993 .{ .kind = .id_ref, .quantifier = .required },
14994 .{ .kind = .debug_info_debug_info_flags, .quantifier = .required },
14995 .{ .kind = .id_ref, .quantifier = .variadic },
13421 },14996 },
13422 },14997 },
13423 .{14998 .{
13424 .name = "native_log",14999 .name = "DebugTypeMember",
13425 .opcode = 86,15000 .opcode = 11,
13426 .operands = &[_]Operand{15001 .operands = &.{
13427 .{ .kind = .IdRef, .quantifier = .required },15002 .{ .kind = .id_ref, .quantifier = .required },
15003 .{ .kind = .id_ref, .quantifier = .required },
15004 .{ .kind = .id_ref, .quantifier = .required },
15005 .{ .kind = .literal_integer, .quantifier = .required },
15006 .{ .kind = .literal_integer, .quantifier = .required },
15007 .{ .kind = .id_ref, .quantifier = .required },
15008 .{ .kind = .id_ref, .quantifier = .required },
15009 .{ .kind = .id_ref, .quantifier = .required },
15010 .{ .kind = .debug_info_debug_info_flags, .quantifier = .required },
15011 .{ .kind = .id_ref, .quantifier = .optional },
13428 },15012 },
13429 },15013 },
13430 .{15014 .{
13431 .name = "native_log2",15015 .name = "DebugTypeInheritance",
13432 .opcode = 87,15016 .opcode = 12,
13433 .operands = &[_]Operand{15017 .operands = &.{
13434 .{ .kind = .IdRef, .quantifier = .required },15018 .{ .kind = .id_ref, .quantifier = .required },
15019 .{ .kind = .id_ref, .quantifier = .required },
15020 .{ .kind = .id_ref, .quantifier = .required },
15021 .{ .kind = .id_ref, .quantifier = .required },
15022 .{ .kind = .debug_info_debug_info_flags, .quantifier = .required },
13435 },15023 },
13436 },15024 },
13437 .{15025 .{
13438 .name = "native_log10",15026 .name = "DebugTypePtrToMember",
13439 .opcode = 88,15027 .opcode = 13,
13440 .operands = &[_]Operand{15028 .operands = &.{
13441 .{ .kind = .IdRef, .quantifier = .required },15029 .{ .kind = .id_ref, .quantifier = .required },
15030 .{ .kind = .id_ref, .quantifier = .required },
13442 },15031 },
13443 },15032 },
13444 .{15033 .{
13445 .name = "native_powr",15034 .name = "DebugTypeTemplate",
13446 .opcode = 89,15035 .opcode = 14,
13447 .operands = &[_]Operand{15036 .operands = &.{
13448 .{ .kind = .IdRef, .quantifier = .required },15037 .{ .kind = .id_ref, .quantifier = .required },
13449 .{ .kind = .IdRef, .quantifier = .required },15038 .{ .kind = .id_ref, .quantifier = .variadic },
13450 },15039 },
13451 },15040 },
13452 .{15041 .{
13453 .name = "native_recip",15042 .name = "DebugTypeTemplateParameter",
13454 .opcode = 90,15043 .opcode = 15,
13455 .operands = &[_]Operand{15044 .operands = &.{
13456 .{ .kind = .IdRef, .quantifier = .required },15045 .{ .kind = .id_ref, .quantifier = .required },
15046 .{ .kind = .id_ref, .quantifier = .required },
15047 .{ .kind = .id_ref, .quantifier = .required },
15048 .{ .kind = .id_ref, .quantifier = .required },
15049 .{ .kind = .literal_integer, .quantifier = .required },
15050 .{ .kind = .literal_integer, .quantifier = .required },
13457 },15051 },
13458 },15052 },
13459 .{15053 .{
13460 .name = "native_rsqrt",15054 .name = "DebugTypeTemplateTemplateParameter",
13461 .opcode = 91,15055 .opcode = 16,
13462 .operands = &[_]Operand{15056 .operands = &.{
13463 .{ .kind = .IdRef, .quantifier = .required },15057 .{ .kind = .id_ref, .quantifier = .required },
15058 .{ .kind = .id_ref, .quantifier = .required },
15059 .{ .kind = .id_ref, .quantifier = .required },
15060 .{ .kind = .literal_integer, .quantifier = .required },
15061 .{ .kind = .literal_integer, .quantifier = .required },
13464 },15062 },
13465 },15063 },
13466 .{15064 .{
13467 .name = "native_sin",15065 .name = "DebugTypeTemplateParameterPack",
13468 .opcode = 92,15066 .opcode = 17,
13469 .operands = &[_]Operand{15067 .operands = &.{
13470 .{ .kind = .IdRef, .quantifier = .required },15068 .{ .kind = .id_ref, .quantifier = .required },
15069 .{ .kind = .id_ref, .quantifier = .required },
15070 .{ .kind = .literal_integer, .quantifier = .required },
15071 .{ .kind = .literal_integer, .quantifier = .required },
15072 .{ .kind = .id_ref, .quantifier = .variadic },
13471 },15073 },
13472 },15074 },
13473 .{15075 .{
13474 .name = "native_sqrt",15076 .name = "DebugGlobalVariable",
13475 .opcode = 93,15077 .opcode = 18,
13476 .operands = &[_]Operand{15078 .operands = &.{
13477 .{ .kind = .IdRef, .quantifier = .required },15079 .{ .kind = .id_ref, .quantifier = .required },
15080 .{ .kind = .id_ref, .quantifier = .required },
15081 .{ .kind = .id_ref, .quantifier = .required },
15082 .{ .kind = .literal_integer, .quantifier = .required },
15083 .{ .kind = .literal_integer, .quantifier = .required },
15084 .{ .kind = .id_ref, .quantifier = .required },
15085 .{ .kind = .id_ref, .quantifier = .required },
15086 .{ .kind = .id_ref, .quantifier = .required },
15087 .{ .kind = .debug_info_debug_info_flags, .quantifier = .required },
15088 .{ .kind = .id_ref, .quantifier = .optional },
13478 },15089 },
13479 },15090 },
13480 .{15091 .{
13481 .name = "native_tan",15092 .name = "DebugFunctionDeclaration",
13482 .opcode = 94,15093 .opcode = 19,
13483 .operands = &[_]Operand{15094 .operands = &.{
13484 .{ .kind = .IdRef, .quantifier = .required },15095 .{ .kind = .id_ref, .quantifier = .required },
15096 .{ .kind = .id_ref, .quantifier = .required },
15097 .{ .kind = .id_ref, .quantifier = .required },
15098 .{ .kind = .literal_integer, .quantifier = .required },
15099 .{ .kind = .literal_integer, .quantifier = .required },
15100 .{ .kind = .id_ref, .quantifier = .required },
15101 .{ .kind = .id_ref, .quantifier = .required },
15102 .{ .kind = .debug_info_debug_info_flags, .quantifier = .required },
13485 },15103 },
13486 },15104 },
13487 .{15105 .{
13488 .name = "fclamp",15106 .name = "DebugFunction",
13489 .opcode = 95,15107 .opcode = 20,
13490 .operands = &[_]Operand{15108 .operands = &.{
13491 .{ .kind = .IdRef, .quantifier = .required },15109 .{ .kind = .id_ref, .quantifier = .required },
13492 .{ .kind = .IdRef, .quantifier = .required },15110 .{ .kind = .id_ref, .quantifier = .required },
13493 .{ .kind = .IdRef, .quantifier = .required },15111 .{ .kind = .id_ref, .quantifier = .required },
15112 .{ .kind = .literal_integer, .quantifier = .required },
15113 .{ .kind = .literal_integer, .quantifier = .required },
15114 .{ .kind = .id_ref, .quantifier = .required },
15115 .{ .kind = .id_ref, .quantifier = .required },
15116 .{ .kind = .debug_info_debug_info_flags, .quantifier = .required },
15117 .{ .kind = .literal_integer, .quantifier = .required },
15118 .{ .kind = .id_ref, .quantifier = .required },
15119 .{ .kind = .id_ref, .quantifier = .optional },
13494 },15120 },
13495 },15121 },
13496 .{15122 .{
13497 .name = "degrees",15123 .name = "DebugLexicalBlock",
13498 .opcode = 96,15124 .opcode = 21,
13499 .operands = &[_]Operand{15125 .operands = &.{
13500 .{ .kind = .IdRef, .quantifier = .required },15126 .{ .kind = .id_ref, .quantifier = .required },
15127 .{ .kind = .literal_integer, .quantifier = .required },
15128 .{ .kind = .literal_integer, .quantifier = .required },
15129 .{ .kind = .id_ref, .quantifier = .required },
15130 .{ .kind = .id_ref, .quantifier = .optional },
13501 },15131 },
13502 },15132 },
13503 .{15133 .{
13504 .name = "fmax_common",15134 .name = "DebugLexicalBlockDiscriminator",
13505 .opcode = 97,15135 .opcode = 22,
13506 .operands = &[_]Operand{15136 .operands = &.{
13507 .{ .kind = .IdRef, .quantifier = .required },15137 .{ .kind = .id_ref, .quantifier = .required },
13508 .{ .kind = .IdRef, .quantifier = .required },15138 .{ .kind = .literal_integer, .quantifier = .required },
15139 .{ .kind = .id_ref, .quantifier = .required },
13509 },15140 },
13510 },15141 },
13511 .{15142 .{
13512 .name = "fmin_common",15143 .name = "DebugScope",
13513 .opcode = 98,15144 .opcode = 23,
13514 .operands = &[_]Operand{15145 .operands = &.{
13515 .{ .kind = .IdRef, .quantifier = .required },15146 .{ .kind = .id_ref, .quantifier = .required },
13516 .{ .kind = .IdRef, .quantifier = .required },15147 .{ .kind = .id_ref, .quantifier = .optional },
13517 },15148 },
13518 },15149 },
13519 .{15150 .{
13520 .name = "mix",15151 .name = "DebugNoScope",
13521 .opcode = 99,15152 .opcode = 24,
13522 .operands = &[_]Operand{15153 .operands = &.{},
13523 .{ .kind = .IdRef, .quantifier = .required },15154 },
13524 .{ .kind = .IdRef, .quantifier = .required },15155 .{
13525 .{ .kind = .IdRef, .quantifier = .required },15156 .name = "DebugInlinedAt",
15157 .opcode = 25,
15158 .operands = &.{
15159 .{ .kind = .literal_integer, .quantifier = .required },
15160 .{ .kind = .id_ref, .quantifier = .required },
15161 .{ .kind = .id_ref, .quantifier = .optional },
13526 },15162 },
13527 },15163 },
13528 .{15164 .{
13529 .name = "radians",15165 .name = "DebugLocalVariable",
13530 .opcode = 100,15166 .opcode = 26,
13531 .operands = &[_]Operand{15167 .operands = &.{
13532 .{ .kind = .IdRef, .quantifier = .required },15168 .{ .kind = .id_ref, .quantifier = .required },
15169 .{ .kind = .id_ref, .quantifier = .required },
15170 .{ .kind = .id_ref, .quantifier = .required },
15171 .{ .kind = .literal_integer, .quantifier = .required },
15172 .{ .kind = .literal_integer, .quantifier = .required },
15173 .{ .kind = .id_ref, .quantifier = .required },
15174 .{ .kind = .literal_integer, .quantifier = .optional },
13533 },15175 },
13534 },15176 },
13535 .{15177 .{
13536 .name = "step",15178 .name = "DebugInlinedVariable",
13537 .opcode = 101,15179 .opcode = 27,
13538 .operands = &[_]Operand{15180 .operands = &.{
13539 .{ .kind = .IdRef, .quantifier = .required },15181 .{ .kind = .id_ref, .quantifier = .required },
13540 .{ .kind = .IdRef, .quantifier = .required },15182 .{ .kind = .id_ref, .quantifier = .required },
13541 },15183 },
13542 },15184 },
13543 .{15185 .{
13544 .name = "smoothstep",15186 .name = "DebugDeclare",
13545 .opcode = 102,15187 .opcode = 28,
13546 .operands = &[_]Operand{15188 .operands = &.{
13547 .{ .kind = .IdRef, .quantifier = .required },15189 .{ .kind = .id_ref, .quantifier = .required },
13548 .{ .kind = .IdRef, .quantifier = .required },15190 .{ .kind = .id_ref, .quantifier = .required },
13549 .{ .kind = .IdRef, .quantifier = .required },15191 .{ .kind = .id_ref, .quantifier = .required },
13550 },15192 },
13551 },15193 },
13552 .{15194 .{
13553 .name = "sign",15195 .name = "DebugValue",
13554 .opcode = 103,15196 .opcode = 29,
13555 .operands = &[_]Operand{15197 .operands = &.{
13556 .{ .kind = .IdRef, .quantifier = .required },15198 .{ .kind = .id_ref, .quantifier = .required },
15199 .{ .kind = .id_ref, .quantifier = .required },
15200 .{ .kind = .id_ref, .quantifier = .variadic },
13557 },15201 },
13558 },15202 },
13559 .{15203 .{
13560 .name = "cross",15204 .name = "DebugOperation",
13561 .opcode = 104,15205 .opcode = 30,
13562 .operands = &[_]Operand{15206 .operands = &.{
13563 .{ .kind = .IdRef, .quantifier = .required },15207 .{ .kind = .debug_info_debug_operation, .quantifier = .required },
13564 .{ .kind = .IdRef, .quantifier = .required },15208 .{ .kind = .literal_integer, .quantifier = .variadic },
13565 },15209 },
13566 },15210 },
13567 .{15211 .{
13568 .name = "distance",15212 .name = "DebugExpression",
13569 .opcode = 105,15213 .opcode = 31,
13570 .operands = &[_]Operand{15214 .operands = &.{
13571 .{ .kind = .IdRef, .quantifier = .required },15215 .{ .kind = .id_ref, .quantifier = .variadic },
13572 .{ .kind = .IdRef, .quantifier = .required },
13573 },15216 },
13574 },15217 },
13575 .{15218 .{
13576 .name = "length",15219 .name = "DebugMacroDef",
13577 .opcode = 106,15220 .opcode = 32,
13578 .operands = &[_]Operand{15221 .operands = &.{
13579 .{ .kind = .IdRef, .quantifier = .required },15222 .{ .kind = .id_ref, .quantifier = .required },
15223 .{ .kind = .literal_integer, .quantifier = .required },
15224 .{ .kind = .id_ref, .quantifier = .required },
15225 .{ .kind = .id_ref, .quantifier = .optional },
13580 },15226 },
13581 },15227 },
13582 .{15228 .{
13583 .name = "normalize",15229 .name = "DebugMacroUndef",
13584 .opcode = 107,15230 .opcode = 33,
13585 .operands = &[_]Operand{15231 .operands = &.{
13586 .{ .kind = .IdRef, .quantifier = .required },15232 .{ .kind = .id_ref, .quantifier = .required },
15233 .{ .kind = .literal_integer, .quantifier = .required },
15234 .{ .kind = .id_ref, .quantifier = .required },
13587 },15235 },
13588 },15236 },
15237 },
15238 .non_semantic_debug_break => &.{
13589 .{15239 .{
13590 .name = "fast_distance",15240 .name = "DebugBreak",
13591 .opcode = 108,15241 .opcode = 1,
13592 .operands = &[_]Operand{15242 .operands = &.{},
13593 .{ .kind = .IdRef, .quantifier = .required },15243 },
13594 .{ .kind = .IdRef, .quantifier = .required },15244 },
15245 .open_cl_debug_info_100 => &.{
15246 .{
15247 .name = "DebugInfoNone",
15248 .opcode = 0,
15249 .operands = &.{},
15250 },
15251 .{
15252 .name = "DebugCompilationUnit",
15253 .opcode = 1,
15254 .operands = &.{
15255 .{ .kind = .literal_integer, .quantifier = .required },
15256 .{ .kind = .literal_integer, .quantifier = .required },
15257 .{ .kind = .id_ref, .quantifier = .required },
15258 .{ .kind = .source_language, .quantifier = .required },
13595 },15259 },
13596 },15260 },
13597 .{15261 .{
13598 .name = "fast_length",15262 .name = "DebugTypeBasic",
13599 .opcode = 109,15263 .opcode = 2,
13600 .operands = &[_]Operand{15264 .operands = &.{
13601 .{ .kind = .IdRef, .quantifier = .required },15265 .{ .kind = .id_ref, .quantifier = .required },
15266 .{ .kind = .id_ref, .quantifier = .required },
15267 .{ .kind = .open_cl_debug_info_100_debug_base_type_attribute_encoding, .quantifier = .required },
13602 },15268 },
13603 },15269 },
13604 .{15270 .{
13605 .name = "fast_normalize",15271 .name = "DebugTypePointer",
13606 .opcode = 110,15272 .opcode = 3,
13607 .operands = &[_]Operand{15273 .operands = &.{
13608 .{ .kind = .IdRef, .quantifier = .required },15274 .{ .kind = .id_ref, .quantifier = .required },
15275 .{ .kind = .storage_class, .quantifier = .required },
15276 .{ .kind = .open_cl_debug_info_100_debug_info_flags, .quantifier = .required },
13609 },15277 },
13610 },15278 },
13611 .{15279 .{
13612 .name = "s_abs",15280 .name = "DebugTypeQualifier",
13613 .opcode = 141,15281 .opcode = 4,
13614 .operands = &[_]Operand{15282 .operands = &.{
13615 .{ .kind = .IdRef, .quantifier = .required },15283 .{ .kind = .id_ref, .quantifier = .required },
15284 .{ .kind = .open_cl_debug_info_100_debug_type_qualifier, .quantifier = .required },
13616 },15285 },
13617 },15286 },
13618 .{15287 .{
13619 .name = "s_abs_diff",15288 .name = "DebugTypeArray",
13620 .opcode = 142,15289 .opcode = 5,
13621 .operands = &[_]Operand{15290 .operands = &.{
13622 .{ .kind = .IdRef, .quantifier = .required },15291 .{ .kind = .id_ref, .quantifier = .required },
13623 .{ .kind = .IdRef, .quantifier = .required },15292 .{ .kind = .id_ref, .quantifier = .variadic },
13624 },15293 },
13625 },15294 },
13626 .{15295 .{
13627 .name = "s_add_sat",15296 .name = "DebugTypeVector",
13628 .opcode = 143,15297 .opcode = 6,
13629 .operands = &[_]Operand{15298 .operands = &.{
13630 .{ .kind = .IdRef, .quantifier = .required },15299 .{ .kind = .id_ref, .quantifier = .required },
13631 .{ .kind = .IdRef, .quantifier = .required },15300 .{ .kind = .literal_integer, .quantifier = .required },
13632 },15301 },
13633 },15302 },
13634 .{15303 .{
13635 .name = "u_add_sat",15304 .name = "DebugTypedef",
13636 .opcode = 144,15305 .opcode = 7,
13637 .operands = &[_]Operand{15306 .operands = &.{
13638 .{ .kind = .IdRef, .quantifier = .required },15307 .{ .kind = .id_ref, .quantifier = .required },
13639 .{ .kind = .IdRef, .quantifier = .required },15308 .{ .kind = .id_ref, .quantifier = .required },
15309 .{ .kind = .id_ref, .quantifier = .required },
15310 .{ .kind = .literal_integer, .quantifier = .required },
15311 .{ .kind = .literal_integer, .quantifier = .required },
15312 .{ .kind = .id_ref, .quantifier = .required },
13640 },15313 },
13641 },15314 },
13642 .{15315 .{
13643 .name = "s_hadd",15316 .name = "DebugTypeFunction",
13644 .opcode = 145,15317 .opcode = 8,
13645 .operands = &[_]Operand{15318 .operands = &.{
13646 .{ .kind = .IdRef, .quantifier = .required },15319 .{ .kind = .open_cl_debug_info_100_debug_info_flags, .quantifier = .required },
13647 .{ .kind = .IdRef, .quantifier = .required },15320 .{ .kind = .id_ref, .quantifier = .required },
15321 .{ .kind = .id_ref, .quantifier = .variadic },
13648 },15322 },
13649 },15323 },
13650 .{15324 .{
13651 .name = "u_hadd",15325 .name = "DebugTypeEnum",
13652 .opcode = 146,15326 .opcode = 9,
13653 .operands = &[_]Operand{15327 .operands = &.{
13654 .{ .kind = .IdRef, .quantifier = .required },15328 .{ .kind = .id_ref, .quantifier = .required },
13655 .{ .kind = .IdRef, .quantifier = .required },15329 .{ .kind = .id_ref, .quantifier = .required },
15330 .{ .kind = .id_ref, .quantifier = .required },
15331 .{ .kind = .literal_integer, .quantifier = .required },
15332 .{ .kind = .literal_integer, .quantifier = .required },
15333 .{ .kind = .id_ref, .quantifier = .required },
15334 .{ .kind = .id_ref, .quantifier = .required },
15335 .{ .kind = .open_cl_debug_info_100_debug_info_flags, .quantifier = .required },
15336 .{ .kind = .pair_id_ref_id_ref, .quantifier = .variadic },
13656 },15337 },
13657 },15338 },
13658 .{15339 .{
13659 .name = "s_rhadd",15340 .name = "DebugTypeComposite",
13660 .opcode = 147,15341 .opcode = 10,
13661 .operands = &[_]Operand{15342 .operands = &.{
13662 .{ .kind = .IdRef, .quantifier = .required },15343 .{ .kind = .id_ref, .quantifier = .required },
13663 .{ .kind = .IdRef, .quantifier = .required },15344 .{ .kind = .open_cl_debug_info_100_debug_composite_type, .quantifier = .required },
15345 .{ .kind = .id_ref, .quantifier = .required },
15346 .{ .kind = .literal_integer, .quantifier = .required },
15347 .{ .kind = .literal_integer, .quantifier = .required },
15348 .{ .kind = .id_ref, .quantifier = .required },
15349 .{ .kind = .id_ref, .quantifier = .required },
15350 .{ .kind = .id_ref, .quantifier = .required },
15351 .{ .kind = .open_cl_debug_info_100_debug_info_flags, .quantifier = .required },
15352 .{ .kind = .id_ref, .quantifier = .variadic },
13664 },15353 },
13665 },15354 },
13666 .{15355 .{
13667 .name = "u_rhadd",15356 .name = "DebugTypeMember",
13668 .opcode = 148,15357 .opcode = 11,
13669 .operands = &[_]Operand{15358 .operands = &.{
13670 .{ .kind = .IdRef, .quantifier = .required },15359 .{ .kind = .id_ref, .quantifier = .required },
13671 .{ .kind = .IdRef, .quantifier = .required },15360 .{ .kind = .id_ref, .quantifier = .required },
15361 .{ .kind = .id_ref, .quantifier = .required },
15362 .{ .kind = .literal_integer, .quantifier = .required },
15363 .{ .kind = .literal_integer, .quantifier = .required },
15364 .{ .kind = .id_ref, .quantifier = .required },
15365 .{ .kind = .id_ref, .quantifier = .required },
15366 .{ .kind = .id_ref, .quantifier = .required },
15367 .{ .kind = .open_cl_debug_info_100_debug_info_flags, .quantifier = .required },
15368 .{ .kind = .id_ref, .quantifier = .optional },
13672 },15369 },
13673 },15370 },
13674 .{15371 .{
13675 .name = "s_clamp",15372 .name = "DebugTypeInheritance",
13676 .opcode = 149,15373 .opcode = 12,
13677 .operands = &[_]Operand{15374 .operands = &.{
13678 .{ .kind = .IdRef, .quantifier = .required },15375 .{ .kind = .id_ref, .quantifier = .required },
13679 .{ .kind = .IdRef, .quantifier = .required },15376 .{ .kind = .id_ref, .quantifier = .required },
13680 .{ .kind = .IdRef, .quantifier = .required },15377 .{ .kind = .id_ref, .quantifier = .required },
15378 .{ .kind = .id_ref, .quantifier = .required },
15379 .{ .kind = .open_cl_debug_info_100_debug_info_flags, .quantifier = .required },
13681 },15380 },
13682 },15381 },
13683 .{15382 .{
13684 .name = "u_clamp",15383 .name = "DebugTypePtrToMember",
13685 .opcode = 150,15384 .opcode = 13,
13686 .operands = &[_]Operand{15385 .operands = &.{
13687 .{ .kind = .IdRef, .quantifier = .required },15386 .{ .kind = .id_ref, .quantifier = .required },
13688 .{ .kind = .IdRef, .quantifier = .required },15387 .{ .kind = .id_ref, .quantifier = .required },
13689 .{ .kind = .IdRef, .quantifier = .required },
13690 },15388 },
13691 },15389 },
13692 .{15390 .{
13693 .name = "clz",15391 .name = "DebugTypeTemplate",
13694 .opcode = 151,15392 .opcode = 14,
13695 .operands = &[_]Operand{15393 .operands = &.{
13696 .{ .kind = .IdRef, .quantifier = .required },15394 .{ .kind = .id_ref, .quantifier = .required },
15395 .{ .kind = .id_ref, .quantifier = .variadic },
13697 },15396 },
13698 },15397 },
13699 .{15398 .{
13700 .name = "ctz",15399 .name = "DebugTypeTemplateParameter",
13701 .opcode = 152,15400 .opcode = 15,
13702 .operands = &[_]Operand{15401 .operands = &.{
13703 .{ .kind = .IdRef, .quantifier = .required },15402 .{ .kind = .id_ref, .quantifier = .required },
15403 .{ .kind = .id_ref, .quantifier = .required },
15404 .{ .kind = .id_ref, .quantifier = .required },
15405 .{ .kind = .id_ref, .quantifier = .required },
15406 .{ .kind = .literal_integer, .quantifier = .required },
15407 .{ .kind = .literal_integer, .quantifier = .required },
13704 },15408 },
13705 },15409 },
13706 .{15410 .{
13707 .name = "s_mad_hi",15411 .name = "DebugTypeTemplateTemplateParameter",
13708 .opcode = 153,15412 .opcode = 16,
13709 .operands = &[_]Operand{15413 .operands = &.{
13710 .{ .kind = .IdRef, .quantifier = .required },15414 .{ .kind = .id_ref, .quantifier = .required },
13711 .{ .kind = .IdRef, .quantifier = .required },15415 .{ .kind = .id_ref, .quantifier = .required },
13712 .{ .kind = .IdRef, .quantifier = .required },15416 .{ .kind = .id_ref, .quantifier = .required },
15417 .{ .kind = .literal_integer, .quantifier = .required },
15418 .{ .kind = .literal_integer, .quantifier = .required },
13713 },15419 },
13714 },15420 },
13715 .{15421 .{
13716 .name = "u_mad_sat",15422 .name = "DebugTypeTemplateParameterPack",
13717 .opcode = 154,15423 .opcode = 17,
13718 .operands = &[_]Operand{15424 .operands = &.{
13719 .{ .kind = .IdRef, .quantifier = .required },15425 .{ .kind = .id_ref, .quantifier = .required },
13720 .{ .kind = .IdRef, .quantifier = .required },15426 .{ .kind = .id_ref, .quantifier = .required },
13721 .{ .kind = .IdRef, .quantifier = .required },15427 .{ .kind = .literal_integer, .quantifier = .required },
15428 .{ .kind = .literal_integer, .quantifier = .required },
15429 .{ .kind = .id_ref, .quantifier = .variadic },
13722 },15430 },
13723 },15431 },
13724 .{15432 .{
13725 .name = "s_mad_sat",15433 .name = "DebugGlobalVariable",
13726 .opcode = 155,15434 .opcode = 18,
13727 .operands = &[_]Operand{15435 .operands = &.{
13728 .{ .kind = .IdRef, .quantifier = .required },15436 .{ .kind = .id_ref, .quantifier = .required },
13729 .{ .kind = .IdRef, .quantifier = .required },15437 .{ .kind = .id_ref, .quantifier = .required },
13730 .{ .kind = .IdRef, .quantifier = .required },15438 .{ .kind = .id_ref, .quantifier = .required },
15439 .{ .kind = .literal_integer, .quantifier = .required },
15440 .{ .kind = .literal_integer, .quantifier = .required },
15441 .{ .kind = .id_ref, .quantifier = .required },
15442 .{ .kind = .id_ref, .quantifier = .required },
15443 .{ .kind = .id_ref, .quantifier = .required },
15444 .{ .kind = .open_cl_debug_info_100_debug_info_flags, .quantifier = .required },
15445 .{ .kind = .id_ref, .quantifier = .optional },
13731 },15446 },
13732 },15447 },
13733 .{15448 .{
13734 .name = "s_max",15449 .name = "DebugFunctionDeclaration",
13735 .opcode = 156,15450 .opcode = 19,
13736 .operands = &[_]Operand{15451 .operands = &.{
13737 .{ .kind = .IdRef, .quantifier = .required },15452 .{ .kind = .id_ref, .quantifier = .required },
13738 .{ .kind = .IdRef, .quantifier = .required },15453 .{ .kind = .id_ref, .quantifier = .required },
15454 .{ .kind = .id_ref, .quantifier = .required },
15455 .{ .kind = .literal_integer, .quantifier = .required },
15456 .{ .kind = .literal_integer, .quantifier = .required },
15457 .{ .kind = .id_ref, .quantifier = .required },
15458 .{ .kind = .id_ref, .quantifier = .required },
15459 .{ .kind = .open_cl_debug_info_100_debug_info_flags, .quantifier = .required },
13739 },15460 },
13740 },15461 },
13741 .{15462 .{
13742 .name = "u_max",15463 .name = "DebugFunction",
13743 .opcode = 157,15464 .opcode = 20,
13744 .operands = &[_]Operand{15465 .operands = &.{
13745 .{ .kind = .IdRef, .quantifier = .required },15466 .{ .kind = .id_ref, .quantifier = .required },
13746 .{ .kind = .IdRef, .quantifier = .required },15467 .{ .kind = .id_ref, .quantifier = .required },
15468 .{ .kind = .id_ref, .quantifier = .required },
15469 .{ .kind = .literal_integer, .quantifier = .required },
15470 .{ .kind = .literal_integer, .quantifier = .required },
15471 .{ .kind = .id_ref, .quantifier = .required },
15472 .{ .kind = .id_ref, .quantifier = .required },
15473 .{ .kind = .open_cl_debug_info_100_debug_info_flags, .quantifier = .required },
15474 .{ .kind = .literal_integer, .quantifier = .required },
15475 .{ .kind = .id_ref, .quantifier = .required },
15476 .{ .kind = .id_ref, .quantifier = .optional },
13747 },15477 },
13748 },15478 },
13749 .{15479 .{
13750 .name = "s_min",15480 .name = "DebugLexicalBlock",
13751 .opcode = 158,15481 .opcode = 21,
13752 .operands = &[_]Operand{15482 .operands = &.{
13753 .{ .kind = .IdRef, .quantifier = .required },15483 .{ .kind = .id_ref, .quantifier = .required },
13754 .{ .kind = .IdRef, .quantifier = .required },15484 .{ .kind = .literal_integer, .quantifier = .required },
15485 .{ .kind = .literal_integer, .quantifier = .required },
15486 .{ .kind = .id_ref, .quantifier = .required },
15487 .{ .kind = .id_ref, .quantifier = .optional },
13755 },15488 },
13756 },15489 },
13757 .{15490 .{
13758 .name = "u_min",15491 .name = "DebugLexicalBlockDiscriminator",
13759 .opcode = 159,15492 .opcode = 22,
13760 .operands = &[_]Operand{15493 .operands = &.{
13761 .{ .kind = .IdRef, .quantifier = .required },15494 .{ .kind = .id_ref, .quantifier = .required },
13762 .{ .kind = .IdRef, .quantifier = .required },15495 .{ .kind = .literal_integer, .quantifier = .required },
15496 .{ .kind = .id_ref, .quantifier = .required },
13763 },15497 },
13764 },15498 },
13765 .{15499 .{
13766 .name = "s_mul_hi",15500 .name = "DebugScope",
13767 .opcode = 160,15501 .opcode = 23,
13768 .operands = &[_]Operand{15502 .operands = &.{
13769 .{ .kind = .IdRef, .quantifier = .required },15503 .{ .kind = .id_ref, .quantifier = .required },
13770 .{ .kind = .IdRef, .quantifier = .required },15504 .{ .kind = .id_ref, .quantifier = .optional },
13771 },15505 },
13772 },15506 },
13773 .{15507 .{
13774 .name = "rotate",15508 .name = "DebugNoScope",
13775 .opcode = 161,15509 .opcode = 24,
13776 .operands = &[_]Operand{15510 .operands = &.{},
13777 .{ .kind = .IdRef, .quantifier = .required },15511 },
13778 .{ .kind = .IdRef, .quantifier = .required },15512 .{
15513 .name = "DebugInlinedAt",
15514 .opcode = 25,
15515 .operands = &.{
15516 .{ .kind = .literal_integer, .quantifier = .required },
15517 .{ .kind = .id_ref, .quantifier = .required },
15518 .{ .kind = .id_ref, .quantifier = .optional },
13779 },15519 },
13780 },15520 },
13781 .{15521 .{
13782 .name = "s_sub_sat",15522 .name = "DebugLocalVariable",
13783 .opcode = 162,15523 .opcode = 26,
13784 .operands = &[_]Operand{15524 .operands = &.{
13785 .{ .kind = .IdRef, .quantifier = .required },15525 .{ .kind = .id_ref, .quantifier = .required },
13786 .{ .kind = .IdRef, .quantifier = .required },15526 .{ .kind = .id_ref, .quantifier = .required },
15527 .{ .kind = .id_ref, .quantifier = .required },
15528 .{ .kind = .literal_integer, .quantifier = .required },
15529 .{ .kind = .literal_integer, .quantifier = .required },
15530 .{ .kind = .id_ref, .quantifier = .required },
15531 .{ .kind = .open_cl_debug_info_100_debug_info_flags, .quantifier = .required },
15532 .{ .kind = .literal_integer, .quantifier = .optional },
13787 },15533 },
13788 },15534 },
13789 .{15535 .{
13790 .name = "u_sub_sat",15536 .name = "DebugInlinedVariable",
13791 .opcode = 163,15537 .opcode = 27,
13792 .operands = &[_]Operand{15538 .operands = &.{
13793 .{ .kind = .IdRef, .quantifier = .required },15539 .{ .kind = .id_ref, .quantifier = .required },
13794 .{ .kind = .IdRef, .quantifier = .required },15540 .{ .kind = .id_ref, .quantifier = .required },
13795 },15541 },
13796 },15542 },
13797 .{15543 .{
13798 .name = "u_upsample",15544 .name = "DebugDeclare",
13799 .opcode = 164,15545 .opcode = 28,
13800 .operands = &[_]Operand{15546 .operands = &.{
13801 .{ .kind = .IdRef, .quantifier = .required },15547 .{ .kind = .id_ref, .quantifier = .required },
13802 .{ .kind = .IdRef, .quantifier = .required },15548 .{ .kind = .id_ref, .quantifier = .required },
15549 .{ .kind = .id_ref, .quantifier = .required },
13803 },15550 },
13804 },15551 },
13805 .{15552 .{
13806 .name = "s_upsample",15553 .name = "DebugValue",
13807 .opcode = 165,15554 .opcode = 29,
13808 .operands = &[_]Operand{15555 .operands = &.{
13809 .{ .kind = .IdRef, .quantifier = .required },15556 .{ .kind = .id_ref, .quantifier = .required },
13810 .{ .kind = .IdRef, .quantifier = .required },15557 .{ .kind = .id_ref, .quantifier = .required },
15558 .{ .kind = .id_ref, .quantifier = .required },
15559 .{ .kind = .id_ref, .quantifier = .variadic },
13811 },15560 },
13812 },15561 },
13813 .{15562 .{
13814 .name = "popcount",15563 .name = "DebugOperation",
13815 .opcode = 166,15564 .opcode = 30,
13816 .operands = &[_]Operand{15565 .operands = &.{
13817 .{ .kind = .IdRef, .quantifier = .required },15566 .{ .kind = .open_cl_debug_info_100_debug_operation, .quantifier = .required },
15567 .{ .kind = .literal_integer, .quantifier = .variadic },
13818 },15568 },
13819 },15569 },
13820 .{15570 .{
13821 .name = "s_mad24",15571 .name = "DebugExpression",
13822 .opcode = 167,15572 .opcode = 31,
13823 .operands = &[_]Operand{15573 .operands = &.{
13824 .{ .kind = .IdRef, .quantifier = .required },15574 .{ .kind = .id_ref, .quantifier = .variadic },
13825 .{ .kind = .IdRef, .quantifier = .required },
13826 .{ .kind = .IdRef, .quantifier = .required },
13827 },15575 },
13828 },15576 },
13829 .{15577 .{
13830 .name = "u_mad24",15578 .name = "DebugMacroDef",
13831 .opcode = 168,15579 .opcode = 32,
13832 .operands = &[_]Operand{15580 .operands = &.{
13833 .{ .kind = .IdRef, .quantifier = .required },15581 .{ .kind = .id_ref, .quantifier = .required },
13834 .{ .kind = .IdRef, .quantifier = .required },15582 .{ .kind = .literal_integer, .quantifier = .required },
13835 .{ .kind = .IdRef, .quantifier = .required },15583 .{ .kind = .id_ref, .quantifier = .required },
15584 .{ .kind = .id_ref, .quantifier = .optional },
13836 },15585 },
13837 },15586 },
13838 .{15587 .{
13839 .name = "s_mul24",15588 .name = "DebugMacroUndef",
13840 .opcode = 169,15589 .opcode = 33,
13841 .operands = &[_]Operand{15590 .operands = &.{
13842 .{ .kind = .IdRef, .quantifier = .required },15591 .{ .kind = .id_ref, .quantifier = .required },
13843 .{ .kind = .IdRef, .quantifier = .required },15592 .{ .kind = .literal_integer, .quantifier = .required },
15593 .{ .kind = .id_ref, .quantifier = .required },
13844 },15594 },
13845 },15595 },
13846 .{15596 .{
13847 .name = "u_mul24",15597 .name = "DebugImportedEntity",
13848 .opcode = 170,15598 .opcode = 34,
13849 .operands = &[_]Operand{15599 .operands = &.{
13850 .{ .kind = .IdRef, .quantifier = .required },15600 .{ .kind = .id_ref, .quantifier = .required },
13851 .{ .kind = .IdRef, .quantifier = .required },15601 .{ .kind = .open_cl_debug_info_100_debug_imported_entity, .quantifier = .required },
15602 .{ .kind = .id_ref, .quantifier = .required },
15603 .{ .kind = .id_ref, .quantifier = .required },
15604 .{ .kind = .literal_integer, .quantifier = .required },
15605 .{ .kind = .literal_integer, .quantifier = .required },
15606 .{ .kind = .id_ref, .quantifier = .required },
13852 },15607 },
13853 },15608 },
13854 .{15609 .{
13855 .name = "vloadn",15610 .name = "DebugSource",
13856 .opcode = 171,15611 .opcode = 35,
13857 .operands = &[_]Operand{15612 .operands = &.{
13858 .{ .kind = .IdRef, .quantifier = .required },15613 .{ .kind = .id_ref, .quantifier = .required },
13859 .{ .kind = .IdRef, .quantifier = .required },15614 .{ .kind = .id_ref, .quantifier = .optional },
13860 .{ .kind = .LiteralInteger, .quantifier = .required },
13861 },15615 },
13862 },15616 },
13863 .{15617 .{
13864 .name = "vstoren",15618 .name = "DebugModuleINTEL",
13865 .opcode = 172,15619 .opcode = 36,
13866 .operands = &[_]Operand{15620 .operands = &.{
13867 .{ .kind = .IdRef, .quantifier = .required },15621 .{ .kind = .id_ref, .quantifier = .required },
13868 .{ .kind = .IdRef, .quantifier = .required },15622 .{ .kind = .id_ref, .quantifier = .required },
13869 .{ .kind = .IdRef, .quantifier = .required },15623 .{ .kind = .id_ref, .quantifier = .required },
15624 .{ .kind = .literal_integer, .quantifier = .required },
15625 .{ .kind = .id_ref, .quantifier = .required },
15626 .{ .kind = .id_ref, .quantifier = .required },
15627 .{ .kind = .id_ref, .quantifier = .required },
15628 .{ .kind = .literal_integer, .quantifier = .required },
13870 },15629 },
13871 },15630 },
15631 },
15632 .non_semantic_clspv_reflection_6 => &.{
13872 .{15633 .{
13873 .name = "vload_half",15634 .name = "Kernel",
13874 .opcode = 173,15635 .opcode = 1,
13875 .operands = &[_]Operand{15636 .operands = &.{
13876 .{ .kind = .IdRef, .quantifier = .required },15637 .{ .kind = .id_ref, .quantifier = .required },
13877 .{ .kind = .IdRef, .quantifier = .required },15638 .{ .kind = .id_ref, .quantifier = .required },
15639 .{ .kind = .id_ref, .quantifier = .optional },
15640 .{ .kind = .id_ref, .quantifier = .optional },
15641 .{ .kind = .id_ref, .quantifier = .optional },
13878 },15642 },
13879 },15643 },
13880 .{15644 .{
13881 .name = "vload_halfn",15645 .name = "ArgumentInfo",
13882 .opcode = 174,15646 .opcode = 2,
13883 .operands = &[_]Operand{15647 .operands = &.{
13884 .{ .kind = .IdRef, .quantifier = .required },15648 .{ .kind = .id_ref, .quantifier = .required },
13885 .{ .kind = .IdRef, .quantifier = .required },15649 .{ .kind = .id_ref, .quantifier = .optional },
13886 .{ .kind = .LiteralInteger, .quantifier = .required },15650 .{ .kind = .id_ref, .quantifier = .optional },
15651 .{ .kind = .id_ref, .quantifier = .optional },
15652 .{ .kind = .id_ref, .quantifier = .optional },
13887 },15653 },
13888 },15654 },
13889 .{15655 .{
13890 .name = "vstore_half",15656 .name = "ArgumentStorageBuffer",
13891 .opcode = 175,15657 .opcode = 3,
13892 .operands = &[_]Operand{15658 .operands = &.{
13893 .{ .kind = .IdRef, .quantifier = .required },15659 .{ .kind = .id_ref, .quantifier = .required },
13894 .{ .kind = .IdRef, .quantifier = .required },15660 .{ .kind = .id_ref, .quantifier = .required },
13895 .{ .kind = .IdRef, .quantifier = .required },15661 .{ .kind = .id_ref, .quantifier = .required },
15662 .{ .kind = .id_ref, .quantifier = .required },
15663 .{ .kind = .id_ref, .quantifier = .optional },
13896 },15664 },
13897 },15665 },
13898 .{15666 .{
13899 .name = "vstore_half_r",15667 .name = "ArgumentUniform",
13900 .opcode = 176,15668 .opcode = 4,
13901 .operands = &[_]Operand{15669 .operands = &.{
13902 .{ .kind = .IdRef, .quantifier = .required },15670 .{ .kind = .id_ref, .quantifier = .required },
13903 .{ .kind = .IdRef, .quantifier = .required },15671 .{ .kind = .id_ref, .quantifier = .required },
13904 .{ .kind = .IdRef, .quantifier = .required },15672 .{ .kind = .id_ref, .quantifier = .required },
13905 .{ .kind = .FPRoundingMode, .quantifier = .required },15673 .{ .kind = .id_ref, .quantifier = .required },
15674 .{ .kind = .id_ref, .quantifier = .optional },
15675 },
15676 },
15677 .{
15678 .name = "ArgumentPodStorageBuffer",
15679 .opcode = 5,
15680 .operands = &.{
15681 .{ .kind = .id_ref, .quantifier = .required },
15682 .{ .kind = .id_ref, .quantifier = .required },
15683 .{ .kind = .id_ref, .quantifier = .required },
15684 .{ .kind = .id_ref, .quantifier = .required },
15685 .{ .kind = .id_ref, .quantifier = .required },
15686 .{ .kind = .id_ref, .quantifier = .required },
15687 .{ .kind = .id_ref, .quantifier = .optional },
15688 },
15689 },
15690 .{
15691 .name = "ArgumentPodUniform",
15692 .opcode = 6,
15693 .operands = &.{
15694 .{ .kind = .id_ref, .quantifier = .required },
15695 .{ .kind = .id_ref, .quantifier = .required },
15696 .{ .kind = .id_ref, .quantifier = .required },
15697 .{ .kind = .id_ref, .quantifier = .required },
15698 .{ .kind = .id_ref, .quantifier = .required },
15699 .{ .kind = .id_ref, .quantifier = .required },
15700 .{ .kind = .id_ref, .quantifier = .optional },
15701 },
15702 },
15703 .{
15704 .name = "ArgumentPodPushConstant",
15705 .opcode = 7,
15706 .operands = &.{
15707 .{ .kind = .id_ref, .quantifier = .required },
15708 .{ .kind = .id_ref, .quantifier = .required },
15709 .{ .kind = .id_ref, .quantifier = .required },
15710 .{ .kind = .id_ref, .quantifier = .required },
15711 .{ .kind = .id_ref, .quantifier = .optional },
15712 },
15713 },
15714 .{
15715 .name = "ArgumentSampledImage",
15716 .opcode = 8,
15717 .operands = &.{
15718 .{ .kind = .id_ref, .quantifier = .required },
15719 .{ .kind = .id_ref, .quantifier = .required },
15720 .{ .kind = .id_ref, .quantifier = .required },
15721 .{ .kind = .id_ref, .quantifier = .required },
15722 .{ .kind = .id_ref, .quantifier = .optional },
15723 },
15724 },
15725 .{
15726 .name = "ArgumentStorageImage",
15727 .opcode = 9,
15728 .operands = &.{
15729 .{ .kind = .id_ref, .quantifier = .required },
15730 .{ .kind = .id_ref, .quantifier = .required },
15731 .{ .kind = .id_ref, .quantifier = .required },
15732 .{ .kind = .id_ref, .quantifier = .required },
15733 .{ .kind = .id_ref, .quantifier = .optional },
15734 },
15735 },
15736 .{
15737 .name = "ArgumentSampler",
15738 .opcode = 10,
15739 .operands = &.{
15740 .{ .kind = .id_ref, .quantifier = .required },
15741 .{ .kind = .id_ref, .quantifier = .required },
15742 .{ .kind = .id_ref, .quantifier = .required },
15743 .{ .kind = .id_ref, .quantifier = .required },
15744 .{ .kind = .id_ref, .quantifier = .optional },
15745 },
15746 },
15747 .{
15748 .name = "ArgumentWorkgroup",
15749 .opcode = 11,
15750 .operands = &.{
15751 .{ .kind = .id_ref, .quantifier = .required },
15752 .{ .kind = .id_ref, .quantifier = .required },
15753 .{ .kind = .id_ref, .quantifier = .required },
15754 .{ .kind = .id_ref, .quantifier = .required },
15755 .{ .kind = .id_ref, .quantifier = .optional },
15756 },
15757 },
15758 .{
15759 .name = "SpecConstantWorkgroupSize",
15760 .opcode = 12,
15761 .operands = &.{
15762 .{ .kind = .id_ref, .quantifier = .required },
15763 .{ .kind = .id_ref, .quantifier = .required },
15764 .{ .kind = .id_ref, .quantifier = .required },
15765 },
15766 },
15767 .{
15768 .name = "SpecConstantGlobalOffset",
15769 .opcode = 13,
15770 .operands = &.{
15771 .{ .kind = .id_ref, .quantifier = .required },
15772 .{ .kind = .id_ref, .quantifier = .required },
15773 .{ .kind = .id_ref, .quantifier = .required },
15774 },
15775 },
15776 .{
15777 .name = "SpecConstantWorkDim",
15778 .opcode = 14,
15779 .operands = &.{
15780 .{ .kind = .id_ref, .quantifier = .required },
15781 },
15782 },
15783 .{
15784 .name = "PushConstantGlobalOffset",
15785 .opcode = 15,
15786 .operands = &.{
15787 .{ .kind = .id_ref, .quantifier = .required },
15788 .{ .kind = .id_ref, .quantifier = .required },
15789 },
15790 },
15791 .{
15792 .name = "PushConstantEnqueuedLocalSize",
15793 .opcode = 16,
15794 .operands = &.{
15795 .{ .kind = .id_ref, .quantifier = .required },
15796 .{ .kind = .id_ref, .quantifier = .required },
15797 },
15798 },
15799 .{
15800 .name = "PushConstantGlobalSize",
15801 .opcode = 17,
15802 .operands = &.{
15803 .{ .kind = .id_ref, .quantifier = .required },
15804 .{ .kind = .id_ref, .quantifier = .required },
15805 },
15806 },
15807 .{
15808 .name = "PushConstantRegionOffset",
15809 .opcode = 18,
15810 .operands = &.{
15811 .{ .kind = .id_ref, .quantifier = .required },
15812 .{ .kind = .id_ref, .quantifier = .required },
15813 },
15814 },
15815 .{
15816 .name = "PushConstantNumWorkgroups",
15817 .opcode = 19,
15818 .operands = &.{
15819 .{ .kind = .id_ref, .quantifier = .required },
15820 .{ .kind = .id_ref, .quantifier = .required },
15821 },
15822 },
15823 .{
15824 .name = "PushConstantRegionGroupOffset",
15825 .opcode = 20,
15826 .operands = &.{
15827 .{ .kind = .id_ref, .quantifier = .required },
15828 .{ .kind = .id_ref, .quantifier = .required },
15829 },
15830 },
15831 .{
15832 .name = "ConstantDataStorageBuffer",
15833 .opcode = 21,
15834 .operands = &.{
15835 .{ .kind = .id_ref, .quantifier = .required },
15836 .{ .kind = .id_ref, .quantifier = .required },
15837 .{ .kind = .id_ref, .quantifier = .required },
15838 },
15839 },
15840 .{
15841 .name = "ConstantDataUniform",
15842 .opcode = 22,
15843 .operands = &.{
15844 .{ .kind = .id_ref, .quantifier = .required },
15845 .{ .kind = .id_ref, .quantifier = .required },
15846 .{ .kind = .id_ref, .quantifier = .required },
15847 },
15848 },
15849 .{
15850 .name = "LiteralSampler",
15851 .opcode = 23,
15852 .operands = &.{
15853 .{ .kind = .id_ref, .quantifier = .required },
15854 .{ .kind = .id_ref, .quantifier = .required },
15855 .{ .kind = .id_ref, .quantifier = .required },
15856 },
15857 },
15858 .{
15859 .name = "PropertyRequiredWorkgroupSize",
15860 .opcode = 24,
15861 .operands = &.{
15862 .{ .kind = .id_ref, .quantifier = .required },
15863 .{ .kind = .id_ref, .quantifier = .required },
15864 .{ .kind = .id_ref, .quantifier = .required },
15865 .{ .kind = .id_ref, .quantifier = .required },
15866 },
15867 },
15868 .{
15869 .name = "SpecConstantSubgroupMaxSize",
15870 .opcode = 25,
15871 .operands = &.{
15872 .{ .kind = .id_ref, .quantifier = .required },
15873 },
15874 },
15875 .{
15876 .name = "ArgumentPointerPushConstant",
15877 .opcode = 26,
15878 .operands = &.{
15879 .{ .kind = .id_ref, .quantifier = .required },
15880 .{ .kind = .id_ref, .quantifier = .required },
15881 .{ .kind = .id_ref, .quantifier = .required },
15882 .{ .kind = .id_ref, .quantifier = .required },
15883 .{ .kind = .id_ref, .quantifier = .optional },
15884 },
15885 },
15886 .{
15887 .name = "ArgumentPointerUniform",
15888 .opcode = 27,
15889 .operands = &.{
15890 .{ .kind = .id_ref, .quantifier = .required },
15891 .{ .kind = .id_ref, .quantifier = .required },
15892 .{ .kind = .id_ref, .quantifier = .required },
15893 .{ .kind = .id_ref, .quantifier = .required },
15894 .{ .kind = .id_ref, .quantifier = .required },
15895 .{ .kind = .id_ref, .quantifier = .required },
15896 .{ .kind = .id_ref, .quantifier = .optional },
13906 },15897 },
13907 },15898 },
13908 .{15899 .{
13909 .name = "vstore_halfn",15900 .name = "ProgramScopeVariablesStorageBuffer",
13910 .opcode = 177,15901 .opcode = 28,
13911 .operands = &[_]Operand{15902 .operands = &.{
13912 .{ .kind = .IdRef, .quantifier = .required },15903 .{ .kind = .id_ref, .quantifier = .required },
13913 .{ .kind = .IdRef, .quantifier = .required },15904 .{ .kind = .id_ref, .quantifier = .required },
13914 .{ .kind = .IdRef, .quantifier = .required },15905 .{ .kind = .id_ref, .quantifier = .required },
13915 },15906 },
13916 },15907 },
13917 .{15908 .{
13918 .name = "vstore_halfn_r",15909 .name = "ProgramScopeVariablePointerRelocation",
13919 .opcode = 178,15910 .opcode = 29,
13920 .operands = &[_]Operand{15911 .operands = &.{
13921 .{ .kind = .IdRef, .quantifier = .required },15912 .{ .kind = .id_ref, .quantifier = .required },
13922 .{ .kind = .IdRef, .quantifier = .required },15913 .{ .kind = .id_ref, .quantifier = .required },
13923 .{ .kind = .IdRef, .quantifier = .required },15914 .{ .kind = .id_ref, .quantifier = .required },
13924 .{ .kind = .FPRoundingMode, .quantifier = .required },
13925 },15915 },
13926 },15916 },
13927 .{15917 .{
13928 .name = "vloada_halfn",15918 .name = "ImageArgumentInfoChannelOrderPushConstant",
13929 .opcode = 179,15919 .opcode = 30,
13930 .operands = &[_]Operand{15920 .operands = &.{
13931 .{ .kind = .IdRef, .quantifier = .required },15921 .{ .kind = .id_ref, .quantifier = .required },
13932 .{ .kind = .IdRef, .quantifier = .required },15922 .{ .kind = .id_ref, .quantifier = .required },
13933 .{ .kind = .LiteralInteger, .quantifier = .required },15923 .{ .kind = .id_ref, .quantifier = .required },
15924 .{ .kind = .id_ref, .quantifier = .required },
13934 },15925 },
13935 },15926 },
13936 .{15927 .{
13937 .name = "vstorea_halfn",15928 .name = "ImageArgumentInfoChannelDataTypePushConstant",
13938 .opcode = 180,15929 .opcode = 31,
13939 .operands = &[_]Operand{15930 .operands = &.{
13940 .{ .kind = .IdRef, .quantifier = .required },15931 .{ .kind = .id_ref, .quantifier = .required },
13941 .{ .kind = .IdRef, .quantifier = .required },15932 .{ .kind = .id_ref, .quantifier = .required },
13942 .{ .kind = .IdRef, .quantifier = .required },15933 .{ .kind = .id_ref, .quantifier = .required },
15934 .{ .kind = .id_ref, .quantifier = .required },
13943 },15935 },
13944 },15936 },
13945 .{15937 .{
13946 .name = "vstorea_halfn_r",15938 .name = "ImageArgumentInfoChannelOrderUniform",
13947 .opcode = 181,15939 .opcode = 32,
13948 .operands = &[_]Operand{15940 .operands = &.{
13949 .{ .kind = .IdRef, .quantifier = .required },15941 .{ .kind = .id_ref, .quantifier = .required },
13950 .{ .kind = .IdRef, .quantifier = .required },15942 .{ .kind = .id_ref, .quantifier = .required },
13951 .{ .kind = .IdRef, .quantifier = .required },15943 .{ .kind = .id_ref, .quantifier = .required },
13952 .{ .kind = .FPRoundingMode, .quantifier = .required },15944 .{ .kind = .id_ref, .quantifier = .required },
15945 .{ .kind = .id_ref, .quantifier = .required },
15946 .{ .kind = .id_ref, .quantifier = .required },
13953 },15947 },
13954 },15948 },
13955 .{15949 .{
13956 .name = "shuffle",15950 .name = "ImageArgumentInfoChannelDataTypeUniform",
13957 .opcode = 182,15951 .opcode = 33,
13958 .operands = &[_]Operand{15952 .operands = &.{
13959 .{ .kind = .IdRef, .quantifier = .required },15953 .{ .kind = .id_ref, .quantifier = .required },
13960 .{ .kind = .IdRef, .quantifier = .required },15954 .{ .kind = .id_ref, .quantifier = .required },
15955 .{ .kind = .id_ref, .quantifier = .required },
15956 .{ .kind = .id_ref, .quantifier = .required },
15957 .{ .kind = .id_ref, .quantifier = .required },
15958 .{ .kind = .id_ref, .quantifier = .required },
13961 },15959 },
13962 },15960 },
13963 .{15961 .{
13964 .name = "shuffle2",15962 .name = "ArgumentStorageTexelBuffer",
13965 .opcode = 183,15963 .opcode = 34,
13966 .operands = &[_]Operand{15964 .operands = &.{
13967 .{ .kind = .IdRef, .quantifier = .required },15965 .{ .kind = .id_ref, .quantifier = .required },
13968 .{ .kind = .IdRef, .quantifier = .required },15966 .{ .kind = .id_ref, .quantifier = .required },
13969 .{ .kind = .IdRef, .quantifier = .required },15967 .{ .kind = .id_ref, .quantifier = .required },
15968 .{ .kind = .id_ref, .quantifier = .required },
15969 .{ .kind = .id_ref, .quantifier = .optional },
13970 },15970 },
13971 },15971 },
13972 .{15972 .{
13973 .name = "printf",15973 .name = "ArgumentUniformTexelBuffer",
13974 .opcode = 184,15974 .opcode = 35,
13975 .operands = &[_]Operand{15975 .operands = &.{
13976 .{ .kind = .IdRef, .quantifier = .required },15976 .{ .kind = .id_ref, .quantifier = .required },
13977 .{ .kind = .IdRef, .quantifier = .variadic },15977 .{ .kind = .id_ref, .quantifier = .required },
15978 .{ .kind = .id_ref, .quantifier = .required },
15979 .{ .kind = .id_ref, .quantifier = .required },
15980 .{ .kind = .id_ref, .quantifier = .optional },
13978 },15981 },
13979 },15982 },
13980 .{15983 .{
13981 .name = "prefetch",15984 .name = "ConstantDataPointerPushConstant",
13982 .opcode = 185,15985 .opcode = 36,
13983 .operands = &[_]Operand{15986 .operands = &.{
13984 .{ .kind = .IdRef, .quantifier = .required },15987 .{ .kind = .id_ref, .quantifier = .required },
13985 .{ .kind = .IdRef, .quantifier = .required },15988 .{ .kind = .id_ref, .quantifier = .required },
15989 .{ .kind = .id_ref, .quantifier = .required },
13986 },15990 },
13987 },15991 },
13988 .{15992 .{
13989 .name = "bitselect",15993 .name = "ProgramScopeVariablePointerPushConstant",
13990 .opcode = 186,15994 .opcode = 37,
13991 .operands = &[_]Operand{15995 .operands = &.{
13992 .{ .kind = .IdRef, .quantifier = .required },15996 .{ .kind = .id_ref, .quantifier = .required },
13993 .{ .kind = .IdRef, .quantifier = .required },15997 .{ .kind = .id_ref, .quantifier = .required },
13994 .{ .kind = .IdRef, .quantifier = .required },15998 .{ .kind = .id_ref, .quantifier = .required },
13995 },15999 },
13996 },16000 },
13997 .{16001 .{
13998 .name = "select",16002 .name = "PrintfInfo",
13999 .opcode = 187,16003 .opcode = 38,
14000 .operands = &[_]Operand{16004 .operands = &.{
14001 .{ .kind = .IdRef, .quantifier = .required },16005 .{ .kind = .id_ref, .quantifier = .required },
14002 .{ .kind = .IdRef, .quantifier = .required },16006 .{ .kind = .id_ref, .quantifier = .required },
14003 .{ .kind = .IdRef, .quantifier = .required },16007 .{ .kind = .id_ref, .quantifier = .variadic },
14004 },16008 },
14005 },16009 },
14006 .{16010 .{
14007 .name = "u_abs",16011 .name = "PrintfBufferStorageBuffer",
14008 .opcode = 201,16012 .opcode = 39,
14009 .operands = &[_]Operand{16013 .operands = &.{
14010 .{ .kind = .IdRef, .quantifier = .required },16014 .{ .kind = .id_ref, .quantifier = .required },
16015 .{ .kind = .id_ref, .quantifier = .required },
16016 .{ .kind = .id_ref, .quantifier = .required },
14011 },16017 },
14012 },16018 },
14013 .{16019 .{
14014 .name = "u_abs_diff",16020 .name = "PrintfBufferPointerPushConstant",
14015 .opcode = 202,16021 .opcode = 40,
14016 .operands = &[_]Operand{16022 .operands = &.{
14017 .{ .kind = .IdRef, .quantifier = .required },16023 .{ .kind = .id_ref, .quantifier = .required },
14018 .{ .kind = .IdRef, .quantifier = .required },16024 .{ .kind = .id_ref, .quantifier = .required },
16025 .{ .kind = .id_ref, .quantifier = .required },
14019 },16026 },
14020 },16027 },
14021 .{16028 .{
14022 .name = "u_mul_hi",16029 .name = "NormalizedSamplerMaskPushConstant",
14023 .opcode = 203,16030 .opcode = 41,
14024 .operands = &[_]Operand{16031 .operands = &.{
14025 .{ .kind = .IdRef, .quantifier = .required },16032 .{ .kind = .id_ref, .quantifier = .required },
14026 .{ .kind = .IdRef, .quantifier = .required },16033 .{ .kind = .id_ref, .quantifier = .required },
16034 .{ .kind = .id_ref, .quantifier = .required },
16035 .{ .kind = .id_ref, .quantifier = .required },
14027 },16036 },
14028 },16037 },
14029 .{16038 .{
14030 .name = "u_mad_hi",16039 .name = "WorkgroupVariableSize",
14031 .opcode = 204,16040 .opcode = 42,
14032 .operands = &[_]Operand{16041 .operands = &.{
14033 .{ .kind = .IdRef, .quantifier = .required },16042 .{ .kind = .id_ref, .quantifier = .required },
14034 .{ .kind = .IdRef, .quantifier = .required },16043 .{ .kind = .id_ref, .quantifier = .required },
14035 .{ .kind = .IdRef, .quantifier = .required },
14036 },16044 },
14037 },16045 },
14038 },16046 },
14039 .@"GLSL.std.450" => &[_]Instruction{16047 .glsl_std_450 => &.{
14040 .{16048 .{
14041 .name = "Round",16049 .name = "Round",
14042 .opcode = 1,16050 .opcode = 1,
14043 .operands = &[_]Operand{16051 .operands = &.{
14044 .{ .kind = .IdRef, .quantifier = .required },16052 .{ .kind = .id_ref, .quantifier = .required },
14045 },16053 },
14046 },16054 },
14047 .{16055 .{
14048 .name = "RoundEven",16056 .name = "RoundEven",
14049 .opcode = 2,16057 .opcode = 2,
14050 .operands = &[_]Operand{16058 .operands = &.{
14051 .{ .kind = .IdRef, .quantifier = .required },16059 .{ .kind = .id_ref, .quantifier = .required },
14052 },16060 },
14053 },16061 },
14054 .{16062 .{
14055 .name = "Trunc",16063 .name = "Trunc",
14056 .opcode = 3,16064 .opcode = 3,
14057 .operands = &[_]Operand{16065 .operands = &.{
14058 .{ .kind = .IdRef, .quantifier = .required },16066 .{ .kind = .id_ref, .quantifier = .required },
14059 },16067 },
14060 },16068 },
14061 .{16069 .{
14062 .name = "FAbs",16070 .name = "FAbs",
14063 .opcode = 4,16071 .opcode = 4,
14064 .operands = &[_]Operand{16072 .operands = &.{
14065 .{ .kind = .IdRef, .quantifier = .required },16073 .{ .kind = .id_ref, .quantifier = .required },
14066 },16074 },
14067 },16075 },
14068 .{16076 .{
14069 .name = "SAbs",16077 .name = "SAbs",
14070 .opcode = 5,16078 .opcode = 5,
14071 .operands = &[_]Operand{16079 .operands = &.{
14072 .{ .kind = .IdRef, .quantifier = .required },16080 .{ .kind = .id_ref, .quantifier = .required },
14073 },16081 },
14074 },16082 },
14075 .{16083 .{
14076 .name = "FSign",16084 .name = "FSign",
14077 .opcode = 6,16085 .opcode = 6,
14078 .operands = &[_]Operand{16086 .operands = &.{
14079 .{ .kind = .IdRef, .quantifier = .required },16087 .{ .kind = .id_ref, .quantifier = .required },
14080 },16088 },
14081 },16089 },
14082 .{16090 .{
14083 .name = "SSign",16091 .name = "SSign",
14084 .opcode = 7,16092 .opcode = 7,
14085 .operands = &[_]Operand{16093 .operands = &.{
14086 .{ .kind = .IdRef, .quantifier = .required },16094 .{ .kind = .id_ref, .quantifier = .required },
14087 },16095 },
14088 },16096 },
14089 .{16097 .{
14090 .name = "Floor",16098 .name = "Floor",
14091 .opcode = 8,16099 .opcode = 8,
14092 .operands = &[_]Operand{16100 .operands = &.{
14093 .{ .kind = .IdRef, .quantifier = .required },16101 .{ .kind = .id_ref, .quantifier = .required },
14094 },16102 },
14095 },16103 },
14096 .{16104 .{
14097 .name = "Ceil",16105 .name = "Ceil",
14098 .opcode = 9,16106 .opcode = 9,
14099 .operands = &[_]Operand{16107 .operands = &.{
14100 .{ .kind = .IdRef, .quantifier = .required },16108 .{ .kind = .id_ref, .quantifier = .required },
14101 },16109 },
14102 },16110 },
14103 .{16111 .{
14104 .name = "Fract",16112 .name = "Fract",
14105 .opcode = 10,16113 .opcode = 10,
14106 .operands = &[_]Operand{16114 .operands = &.{
14107 .{ .kind = .IdRef, .quantifier = .required },16115 .{ .kind = .id_ref, .quantifier = .required },
14108 },16116 },
14109 },16117 },
14110 .{16118 .{
14111 .name = "Radians",16119 .name = "Radians",
14112 .opcode = 11,16120 .opcode = 11,
14113 .operands = &[_]Operand{16121 .operands = &.{
14114 .{ .kind = .IdRef, .quantifier = .required },16122 .{ .kind = .id_ref, .quantifier = .required },
14115 },16123 },
14116 },16124 },
14117 .{16125 .{
14118 .name = "Degrees",16126 .name = "Degrees",
14119 .opcode = 12,16127 .opcode = 12,
14120 .operands = &[_]Operand{16128 .operands = &.{
14121 .{ .kind = .IdRef, .quantifier = .required },16129 .{ .kind = .id_ref, .quantifier = .required },
14122 },16130 },
14123 },16131 },
14124 .{16132 .{
14125 .name = "Sin",16133 .name = "Sin",
14126 .opcode = 13,16134 .opcode = 13,
14127 .operands = &[_]Operand{16135 .operands = &.{
14128 .{ .kind = .IdRef, .quantifier = .required },16136 .{ .kind = .id_ref, .quantifier = .required },
14129 },16137 },
14130 },16138 },
14131 .{16139 .{
14132 .name = "Cos",16140 .name = "Cos",
14133 .opcode = 14,16141 .opcode = 14,
14134 .operands = &[_]Operand{16142 .operands = &.{
14135 .{ .kind = .IdRef, .quantifier = .required },16143 .{ .kind = .id_ref, .quantifier = .required },
14136 },16144 },
14137 },16145 },
14138 .{16146 .{
14139 .name = "Tan",16147 .name = "Tan",
14140 .opcode = 15,16148 .opcode = 15,
14141 .operands = &[_]Operand{16149 .operands = &.{
14142 .{ .kind = .IdRef, .quantifier = .required },16150 .{ .kind = .id_ref, .quantifier = .required },
14143 },16151 },
14144 },16152 },
14145 .{16153 .{
14146 .name = "Asin",16154 .name = "Asin",
14147 .opcode = 16,16155 .opcode = 16,
14148 .operands = &[_]Operand{16156 .operands = &.{
14149 .{ .kind = .IdRef, .quantifier = .required },16157 .{ .kind = .id_ref, .quantifier = .required },
14150 },16158 },
14151 },16159 },
14152 .{16160 .{
14153 .name = "Acos",16161 .name = "Acos",
14154 .opcode = 17,16162 .opcode = 17,
14155 .operands = &[_]Operand{16163 .operands = &.{
14156 .{ .kind = .IdRef, .quantifier = .required },16164 .{ .kind = .id_ref, .quantifier = .required },
14157 },16165 },
14158 },16166 },
14159 .{16167 .{
14160 .name = "Atan",16168 .name = "Atan",
14161 .opcode = 18,16169 .opcode = 18,
14162 .operands = &[_]Operand{16170 .operands = &.{
14163 .{ .kind = .IdRef, .quantifier = .required },16171 .{ .kind = .id_ref, .quantifier = .required },
14164 },16172 },
14165 },16173 },
14166 .{16174 .{
14167 .name = "Sinh",16175 .name = "Sinh",
14168 .opcode = 19,16176 .opcode = 19,
14169 .operands = &[_]Operand{16177 .operands = &.{
14170 .{ .kind = .IdRef, .quantifier = .required },16178 .{ .kind = .id_ref, .quantifier = .required },
14171 },16179 },
14172 },16180 },
14173 .{16181 .{
14174 .name = "Cosh",16182 .name = "Cosh",
14175 .opcode = 20,16183 .opcode = 20,
14176 .operands = &[_]Operand{16184 .operands = &.{
14177 .{ .kind = .IdRef, .quantifier = .required },16185 .{ .kind = .id_ref, .quantifier = .required },
14178 },16186 },
14179 },16187 },
14180 .{16188 .{
14181 .name = "Tanh",16189 .name = "Tanh",
14182 .opcode = 21,16190 .opcode = 21,
14183 .operands = &[_]Operand{16191 .operands = &.{
14184 .{ .kind = .IdRef, .quantifier = .required },16192 .{ .kind = .id_ref, .quantifier = .required },
14185 },16193 },
14186 },16194 },
14187 .{16195 .{
14188 .name = "Asinh",16196 .name = "Asinh",
14189 .opcode = 22,16197 .opcode = 22,
14190 .operands = &[_]Operand{16198 .operands = &.{
14191 .{ .kind = .IdRef, .quantifier = .required },16199 .{ .kind = .id_ref, .quantifier = .required },
14192 },16200 },
14193 },16201 },
14194 .{16202 .{
14195 .name = "Acosh",16203 .name = "Acosh",
14196 .opcode = 23,16204 .opcode = 23,
14197 .operands = &[_]Operand{16205 .operands = &.{
14198 .{ .kind = .IdRef, .quantifier = .required },16206 .{ .kind = .id_ref, .quantifier = .required },
14199 },16207 },
14200 },16208 },
14201 .{16209 .{
14202 .name = "Atanh",16210 .name = "Atanh",
14203 .opcode = 24,16211 .opcode = 24,
14204 .operands = &[_]Operand{16212 .operands = &.{
14205 .{ .kind = .IdRef, .quantifier = .required },16213 .{ .kind = .id_ref, .quantifier = .required },
14206 },16214 },
14207 },16215 },
14208 .{16216 .{
14209 .name = "Atan2",16217 .name = "Atan2",
14210 .opcode = 25,16218 .opcode = 25,
14211 .operands = &[_]Operand{16219 .operands = &.{
14212 .{ .kind = .IdRef, .quantifier = .required },16220 .{ .kind = .id_ref, .quantifier = .required },
14213 .{ .kind = .IdRef, .quantifier = .required },16221 .{ .kind = .id_ref, .quantifier = .required },
14214 },16222 },
14215 },16223 },
14216 .{16224 .{
14217 .name = "Pow",16225 .name = "Pow",
14218 .opcode = 26,16226 .opcode = 26,
14219 .operands = &[_]Operand{16227 .operands = &.{
14220 .{ .kind = .IdRef, .quantifier = .required },16228 .{ .kind = .id_ref, .quantifier = .required },
14221 .{ .kind = .IdRef, .quantifier = .required },16229 .{ .kind = .id_ref, .quantifier = .required },
14222 },16230 },
14223 },16231 },
14224 .{16232 .{
14225 .name = "Exp",16233 .name = "Exp",
14226 .opcode = 27,16234 .opcode = 27,
14227 .operands = &[_]Operand{16235 .operands = &.{
14228 .{ .kind = .IdRef, .quantifier = .required },16236 .{ .kind = .id_ref, .quantifier = .required },
14229 },16237 },
14230 },16238 },
14231 .{16239 .{
14232 .name = "Log",16240 .name = "Log",
14233 .opcode = 28,16241 .opcode = 28,
14234 .operands = &[_]Operand{16242 .operands = &.{
14235 .{ .kind = .IdRef, .quantifier = .required },16243 .{ .kind = .id_ref, .quantifier = .required },
14236 },16244 },
14237 },16245 },
14238 .{16246 .{
14239 .name = "Exp2",16247 .name = "Exp2",
14240 .opcode = 29,16248 .opcode = 29,
14241 .operands = &[_]Operand{16249 .operands = &.{
14242 .{ .kind = .IdRef, .quantifier = .required },16250 .{ .kind = .id_ref, .quantifier = .required },
14243 },16251 },
14244 },16252 },
14245 .{16253 .{
14246 .name = "Log2",16254 .name = "Log2",
14247 .opcode = 30,16255 .opcode = 30,
14248 .operands = &[_]Operand{16256 .operands = &.{
14249 .{ .kind = .IdRef, .quantifier = .required },16257 .{ .kind = .id_ref, .quantifier = .required },
14250 },16258 },
14251 },16259 },
14252 .{16260 .{
14253 .name = "Sqrt",16261 .name = "Sqrt",
14254 .opcode = 31,16262 .opcode = 31,
14255 .operands = &[_]Operand{16263 .operands = &.{
14256 .{ .kind = .IdRef, .quantifier = .required },16264 .{ .kind = .id_ref, .quantifier = .required },
14257 },16265 },
14258 },16266 },
14259 .{16267 .{
14260 .name = "InverseSqrt",16268 .name = "InverseSqrt",
14261 .opcode = 32,16269 .opcode = 32,
14262 .operands = &[_]Operand{16270 .operands = &.{
14263 .{ .kind = .IdRef, .quantifier = .required },16271 .{ .kind = .id_ref, .quantifier = .required },
14264 },16272 },
14265 },16273 },
14266 .{16274 .{
14267 .name = "Determinant",16275 .name = "Determinant",
14268 .opcode = 33,16276 .opcode = 33,
14269 .operands = &[_]Operand{16277 .operands = &.{
14270 .{ .kind = .IdRef, .quantifier = .required },16278 .{ .kind = .id_ref, .quantifier = .required },
14271 },16279 },
14272 },16280 },
14273 .{16281 .{
14274 .name = "MatrixInverse",16282 .name = "MatrixInverse",
14275 .opcode = 34,16283 .opcode = 34,
14276 .operands = &[_]Operand{16284 .operands = &.{
14277 .{ .kind = .IdRef, .quantifier = .required },16285 .{ .kind = .id_ref, .quantifier = .required },
14278 },16286 },
14279 },16287 },
14280 .{16288 .{
14281 .name = "Modf",16289 .name = "Modf",
14282 .opcode = 35,16290 .opcode = 35,
14283 .operands = &[_]Operand{16291 .operands = &.{
14284 .{ .kind = .IdRef, .quantifier = .required },16292 .{ .kind = .id_ref, .quantifier = .required },
14285 .{ .kind = .IdRef, .quantifier = .required },16293 .{ .kind = .id_ref, .quantifier = .required },
14286 },16294 },
14287 },16295 },
14288 .{16296 .{
14289 .name = "ModfStruct",16297 .name = "ModfStruct",
14290 .opcode = 36,16298 .opcode = 36,
14291 .operands = &[_]Operand{16299 .operands = &.{
14292 .{ .kind = .IdRef, .quantifier = .required },16300 .{ .kind = .id_ref, .quantifier = .required },
14293 },16301 },
14294 },16302 },
14295 .{16303 .{
14296 .name = "FMin",16304 .name = "FMin",
14297 .opcode = 37,16305 .opcode = 37,
14298 .operands = &[_]Operand{16306 .operands = &.{
14299 .{ .kind = .IdRef, .quantifier = .required },16307 .{ .kind = .id_ref, .quantifier = .required },
14300 .{ .kind = .IdRef, .quantifier = .required },16308 .{ .kind = .id_ref, .quantifier = .required },
14301 },16309 },
14302 },16310 },
14303 .{16311 .{
14304 .name = "UMin",16312 .name = "UMin",
14305 .opcode = 38,16313 .opcode = 38,
14306 .operands = &[_]Operand{16314 .operands = &.{
14307 .{ .kind = .IdRef, .quantifier = .required },16315 .{ .kind = .id_ref, .quantifier = .required },
14308 .{ .kind = .IdRef, .quantifier = .required },16316 .{ .kind = .id_ref, .quantifier = .required },
14309 },16317 },
14310 },16318 },
14311 .{16319 .{
14312 .name = "SMin",16320 .name = "SMin",
14313 .opcode = 39,16321 .opcode = 39,
14314 .operands = &[_]Operand{16322 .operands = &.{
14315 .{ .kind = .IdRef, .quantifier = .required },16323 .{ .kind = .id_ref, .quantifier = .required },
14316 .{ .kind = .IdRef, .quantifier = .required },16324 .{ .kind = .id_ref, .quantifier = .required },
14317 },16325 },
14318 },16326 },
14319 .{16327 .{
14320 .name = "FMax",16328 .name = "FMax",
14321 .opcode = 40,16329 .opcode = 40,
14322 .operands = &[_]Operand{16330 .operands = &.{
14323 .{ .kind = .IdRef, .quantifier = .required },16331 .{ .kind = .id_ref, .quantifier = .required },
14324 .{ .kind = .IdRef, .quantifier = .required },16332 .{ .kind = .id_ref, .quantifier = .required },
14325 },16333 },
14326 },16334 },
14327 .{16335 .{
14328 .name = "UMax",16336 .name = "UMax",
14329 .opcode = 41,16337 .opcode = 41,
14330 .operands = &[_]Operand{16338 .operands = &.{
14331 .{ .kind = .IdRef, .quantifier = .required },16339 .{ .kind = .id_ref, .quantifier = .required },
14332 .{ .kind = .IdRef, .quantifier = .required },16340 .{ .kind = .id_ref, .quantifier = .required },
14333 },16341 },
14334 },16342 },
14335 .{16343 .{
14336 .name = "SMax",16344 .name = "SMax",
14337 .opcode = 42,16345 .opcode = 42,
14338 .operands = &[_]Operand{16346 .operands = &.{
14339 .{ .kind = .IdRef, .quantifier = .required },16347 .{ .kind = .id_ref, .quantifier = .required },
14340 .{ .kind = .IdRef, .quantifier = .required },16348 .{ .kind = .id_ref, .quantifier = .required },
14341 },16349 },
14342 },16350 },
14343 .{16351 .{
14344 .name = "FClamp",16352 .name = "FClamp",
14345 .opcode = 43,16353 .opcode = 43,
14346 .operands = &[_]Operand{16354 .operands = &.{
14347 .{ .kind = .IdRef, .quantifier = .required },16355 .{ .kind = .id_ref, .quantifier = .required },
14348 .{ .kind = .IdRef, .quantifier = .required },16356 .{ .kind = .id_ref, .quantifier = .required },
14349 .{ .kind = .IdRef, .quantifier = .required },16357 .{ .kind = .id_ref, .quantifier = .required },
14350 },16358 },
14351 },16359 },
14352 .{16360 .{
14353 .name = "UClamp",16361 .name = "UClamp",
14354 .opcode = 44,16362 .opcode = 44,
14355 .operands = &[_]Operand{16363 .operands = &.{
14356 .{ .kind = .IdRef, .quantifier = .required },16364 .{ .kind = .id_ref, .quantifier = .required },
14357 .{ .kind = .IdRef, .quantifier = .required },16365 .{ .kind = .id_ref, .quantifier = .required },
14358 .{ .kind = .IdRef, .quantifier = .required },16366 .{ .kind = .id_ref, .quantifier = .required },
14359 },16367 },
14360 },16368 },
14361 .{16369 .{
14362 .name = "SClamp",16370 .name = "SClamp",
14363 .opcode = 45,16371 .opcode = 45,
14364 .operands = &[_]Operand{16372 .operands = &.{
14365 .{ .kind = .IdRef, .quantifier = .required },16373 .{ .kind = .id_ref, .quantifier = .required },
14366 .{ .kind = .IdRef, .quantifier = .required },16374 .{ .kind = .id_ref, .quantifier = .required },
14367 .{ .kind = .IdRef, .quantifier = .required },16375 .{ .kind = .id_ref, .quantifier = .required },
14368 },16376 },
14369 },16377 },
14370 .{16378 .{
14371 .name = "FMix",16379 .name = "FMix",
14372 .opcode = 46,16380 .opcode = 46,
14373 .operands = &[_]Operand{16381 .operands = &.{
14374 .{ .kind = .IdRef, .quantifier = .required },16382 .{ .kind = .id_ref, .quantifier = .required },
14375 .{ .kind = .IdRef, .quantifier = .required },16383 .{ .kind = .id_ref, .quantifier = .required },
14376 .{ .kind = .IdRef, .quantifier = .required },16384 .{ .kind = .id_ref, .quantifier = .required },
14377 },16385 },
14378 },16386 },
14379 .{16387 .{
14380 .name = "IMix",16388 .name = "IMix",
14381 .opcode = 47,16389 .opcode = 47,
14382 .operands = &[_]Operand{16390 .operands = &.{
14383 .{ .kind = .IdRef, .quantifier = .required },16391 .{ .kind = .id_ref, .quantifier = .required },
14384 .{ .kind = .IdRef, .quantifier = .required },16392 .{ .kind = .id_ref, .quantifier = .required },
14385 .{ .kind = .IdRef, .quantifier = .required },16393 .{ .kind = .id_ref, .quantifier = .required },
14386 },16394 },
14387 },16395 },
14388 .{16396 .{
14389 .name = "Step",16397 .name = "Step",
14390 .opcode = 48,16398 .opcode = 48,
14391 .operands = &[_]Operand{16399 .operands = &.{
14392 .{ .kind = .IdRef, .quantifier = .required },16400 .{ .kind = .id_ref, .quantifier = .required },
14393 .{ .kind = .IdRef, .quantifier = .required },16401 .{ .kind = .id_ref, .quantifier = .required },
14394 },16402 },
14395 },16403 },
14396 .{16404 .{
14397 .name = "SmoothStep",16405 .name = "SmoothStep",
14398 .opcode = 49,16406 .opcode = 49,
14399 .operands = &[_]Operand{16407 .operands = &.{
14400 .{ .kind = .IdRef, .quantifier = .required },16408 .{ .kind = .id_ref, .quantifier = .required },
14401 .{ .kind = .IdRef, .quantifier = .required },16409 .{ .kind = .id_ref, .quantifier = .required },
14402 .{ .kind = .IdRef, .quantifier = .required },16410 .{ .kind = .id_ref, .quantifier = .required },
14403 },16411 },
14404 },16412 },
14405 .{16413 .{
14406 .name = "Fma",16414 .name = "Fma",
14407 .opcode = 50,16415 .opcode = 50,
14408 .operands = &[_]Operand{16416 .operands = &.{
14409 .{ .kind = .IdRef, .quantifier = .required },16417 .{ .kind = .id_ref, .quantifier = .required },
14410 .{ .kind = .IdRef, .quantifier = .required },16418 .{ .kind = .id_ref, .quantifier = .required },
14411 .{ .kind = .IdRef, .quantifier = .required },16419 .{ .kind = .id_ref, .quantifier = .required },
14412 },16420 },
14413 },16421 },
14414 .{16422 .{
14415 .name = "Frexp",16423 .name = "Frexp",
14416 .opcode = 51,16424 .opcode = 51,
14417 .operands = &[_]Operand{16425 .operands = &.{
14418 .{ .kind = .IdRef, .quantifier = .required },16426 .{ .kind = .id_ref, .quantifier = .required },
14419 .{ .kind = .IdRef, .quantifier = .required },16427 .{ .kind = .id_ref, .quantifier = .required },
14420 },16428 },
14421 },16429 },
14422 .{16430 .{
14423 .name = "FrexpStruct",16431 .name = "FrexpStruct",
14424 .opcode = 52,16432 .opcode = 52,
14425 .operands = &[_]Operand{16433 .operands = &.{
14426 .{ .kind = .IdRef, .quantifier = .required },16434 .{ .kind = .id_ref, .quantifier = .required },
14427 },16435 },
14428 },16436 },
14429 .{16437 .{
14430 .name = "Ldexp",16438 .name = "Ldexp",
14431 .opcode = 53,16439 .opcode = 53,
14432 .operands = &[_]Operand{16440 .operands = &.{
14433 .{ .kind = .IdRef, .quantifier = .required },16441 .{ .kind = .id_ref, .quantifier = .required },
14434 .{ .kind = .IdRef, .quantifier = .required },16442 .{ .kind = .id_ref, .quantifier = .required },
14435 },16443 },
14436 },16444 },
14437 .{16445 .{
14438 .name = "PackSnorm4x8",16446 .name = "PackSnorm4x8",
14439 .opcode = 54,16447 .opcode = 54,
14440 .operands = &[_]Operand{16448 .operands = &.{
14441 .{ .kind = .IdRef, .quantifier = .required },16449 .{ .kind = .id_ref, .quantifier = .required },
14442 },16450 },
14443 },16451 },
14444 .{16452 .{
14445 .name = "PackUnorm4x8",16453 .name = "PackUnorm4x8",
14446 .opcode = 55,16454 .opcode = 55,
14447 .operands = &[_]Operand{16455 .operands = &.{
14448 .{ .kind = .IdRef, .quantifier = .required },16456 .{ .kind = .id_ref, .quantifier = .required },
14449 },16457 },
14450 },16458 },
14451 .{16459 .{
14452 .name = "PackSnorm2x16",16460 .name = "PackSnorm2x16",
14453 .opcode = 56,16461 .opcode = 56,
14454 .operands = &[_]Operand{16462 .operands = &.{
14455 .{ .kind = .IdRef, .quantifier = .required },16463 .{ .kind = .id_ref, .quantifier = .required },
14456 },16464 },
14457 },16465 },
14458 .{16466 .{
14459 .name = "PackUnorm2x16",16467 .name = "PackUnorm2x16",
14460 .opcode = 57,16468 .opcode = 57,
14461 .operands = &[_]Operand{16469 .operands = &.{
14462 .{ .kind = .IdRef, .quantifier = .required },16470 .{ .kind = .id_ref, .quantifier = .required },
14463 },16471 },
14464 },16472 },
14465 .{16473 .{
14466 .name = "PackHalf2x16",16474 .name = "PackHalf2x16",
14467 .opcode = 58,16475 .opcode = 58,
14468 .operands = &[_]Operand{16476 .operands = &.{
14469 .{ .kind = .IdRef, .quantifier = .required },16477 .{ .kind = .id_ref, .quantifier = .required },
14470 },16478 },
14471 },16479 },
14472 .{16480 .{
14473 .name = "PackDouble2x32",16481 .name = "PackDouble2x32",
14474 .opcode = 59,16482 .opcode = 59,
14475 .operands = &[_]Operand{16483 .operands = &.{
14476 .{ .kind = .IdRef, .quantifier = .required },16484 .{ .kind = .id_ref, .quantifier = .required },
14477 },16485 },
14478 },16486 },
14479 .{16487 .{
14480 .name = "UnpackSnorm2x16",16488 .name = "UnpackSnorm2x16",
14481 .opcode = 60,16489 .opcode = 60,
14482 .operands = &[_]Operand{16490 .operands = &.{
14483 .{ .kind = .IdRef, .quantifier = .required },16491 .{ .kind = .id_ref, .quantifier = .required },
14484 },16492 },
14485 },16493 },
14486 .{16494 .{
14487 .name = "UnpackUnorm2x16",16495 .name = "UnpackUnorm2x16",
14488 .opcode = 61,16496 .opcode = 61,
14489 .operands = &[_]Operand{16497 .operands = &.{
14490 .{ .kind = .IdRef, .quantifier = .required },16498 .{ .kind = .id_ref, .quantifier = .required },
14491 },16499 },
14492 },16500 },
14493 .{16501 .{
14494 .name = "UnpackHalf2x16",16502 .name = "UnpackHalf2x16",
14495 .opcode = 62,16503 .opcode = 62,
14496 .operands = &[_]Operand{16504 .operands = &.{
14497 .{ .kind = .IdRef, .quantifier = .required },16505 .{ .kind = .id_ref, .quantifier = .required },
14498 },16506 },
14499 },16507 },
14500 .{16508 .{
14501 .name = "UnpackSnorm4x8",16509 .name = "UnpackSnorm4x8",
14502 .opcode = 63,16510 .opcode = 63,
14503 .operands = &[_]Operand{16511 .operands = &.{
14504 .{ .kind = .IdRef, .quantifier = .required },16512 .{ .kind = .id_ref, .quantifier = .required },
14505 },16513 },
14506 },16514 },
14507 .{16515 .{
14508 .name = "UnpackUnorm4x8",16516 .name = "UnpackUnorm4x8",
14509 .opcode = 64,16517 .opcode = 64,
14510 .operands = &[_]Operand{16518 .operands = &.{
14511 .{ .kind = .IdRef, .quantifier = .required },16519 .{ .kind = .id_ref, .quantifier = .required },
14512 },16520 },
14513 },16521 },
14514 .{16522 .{
14515 .name = "UnpackDouble2x32",16523 .name = "UnpackDouble2x32",
14516 .opcode = 65,16524 .opcode = 65,
14517 .operands = &[_]Operand{16525 .operands = &.{
14518 .{ .kind = .IdRef, .quantifier = .required },16526 .{ .kind = .id_ref, .quantifier = .required },
14519 },16527 },
14520 },16528 },
14521 .{16529 .{
14522 .name = "Length",16530 .name = "Length",
14523 .opcode = 66,16531 .opcode = 66,
14524 .operands = &[_]Operand{16532 .operands = &.{
14525 .{ .kind = .IdRef, .quantifier = .required },16533 .{ .kind = .id_ref, .quantifier = .required },
14526 },16534 },
14527 },16535 },
14528 .{16536 .{
14529 .name = "Distance",16537 .name = "Distance",
14530 .opcode = 67,16538 .opcode = 67,
14531 .operands = &[_]Operand{16539 .operands = &.{
14532 .{ .kind = .IdRef, .quantifier = .required },16540 .{ .kind = .id_ref, .quantifier = .required },
14533 .{ .kind = .IdRef, .quantifier = .required },16541 .{ .kind = .id_ref, .quantifier = .required },
14534 },16542 },
14535 },16543 },
14536 .{16544 .{
14537 .name = "Cross",16545 .name = "Cross",
14538 .opcode = 68,16546 .opcode = 68,
14539 .operands = &[_]Operand{16547 .operands = &.{
14540 .{ .kind = .IdRef, .quantifier = .required },16548 .{ .kind = .id_ref, .quantifier = .required },
14541 .{ .kind = .IdRef, .quantifier = .required },16549 .{ .kind = .id_ref, .quantifier = .required },
14542 },16550 },
14543 },16551 },
14544 .{16552 .{
14545 .name = "Normalize",16553 .name = "Normalize",
14546 .opcode = 69,16554 .opcode = 69,
14547 .operands = &[_]Operand{16555 .operands = &.{
14548 .{ .kind = .IdRef, .quantifier = .required },16556 .{ .kind = .id_ref, .quantifier = .required },
14549 },16557 },
14550 },16558 },
14551 .{16559 .{
14552 .name = "FaceForward",16560 .name = "FaceForward",
14553 .opcode = 70,16561 .opcode = 70,
14554 .operands = &[_]Operand{16562 .operands = &.{
14555 .{ .kind = .IdRef, .quantifier = .required },16563 .{ .kind = .id_ref, .quantifier = .required },
14556 .{ .kind = .IdRef, .quantifier = .required },16564 .{ .kind = .id_ref, .quantifier = .required },
14557 .{ .kind = .IdRef, .quantifier = .required },16565 .{ .kind = .id_ref, .quantifier = .required },
14558 },16566 },
14559 },16567 },
14560 .{16568 .{
14561 .name = "Reflect",16569 .name = "Reflect",
14562 .opcode = 71,16570 .opcode = 71,
14563 .operands = &[_]Operand{16571 .operands = &.{
14564 .{ .kind = .IdRef, .quantifier = .required },16572 .{ .kind = .id_ref, .quantifier = .required },
14565 .{ .kind = .IdRef, .quantifier = .required },16573 .{ .kind = .id_ref, .quantifier = .required },
14566 },16574 },
14567 },16575 },
14568 .{16576 .{
14569 .name = "Refract",16577 .name = "Refract",
14570 .opcode = 72,16578 .opcode = 72,
14571 .operands = &[_]Operand{16579 .operands = &.{
14572 .{ .kind = .IdRef, .quantifier = .required },16580 .{ .kind = .id_ref, .quantifier = .required },
14573 .{ .kind = .IdRef, .quantifier = .required },16581 .{ .kind = .id_ref, .quantifier = .required },
14574 .{ .kind = .IdRef, .quantifier = .required },16582 .{ .kind = .id_ref, .quantifier = .required },
14575 },16583 },
14576 },16584 },
14577 .{16585 .{
14578 .name = "FindILsb",16586 .name = "FindILsb",
14579 .opcode = 73,16587 .opcode = 73,
14580 .operands = &[_]Operand{16588 .operands = &.{
14581 .{ .kind = .IdRef, .quantifier = .required },16589 .{ .kind = .id_ref, .quantifier = .required },
14582 },16590 },
14583 },16591 },
14584 .{16592 .{
14585 .name = "FindSMsb",16593 .name = "FindSMsb",
14586 .opcode = 74,16594 .opcode = 74,
14587 .operands = &[_]Operand{16595 .operands = &.{
14588 .{ .kind = .IdRef, .quantifier = .required },16596 .{ .kind = .id_ref, .quantifier = .required },
14589 },16597 },
14590 },16598 },
14591 .{16599 .{
14592 .name = "FindUMsb",16600 .name = "FindUMsb",
14593 .opcode = 75,16601 .opcode = 75,
14594 .operands = &[_]Operand{16602 .operands = &.{
14595 .{ .kind = .IdRef, .quantifier = .required },16603 .{ .kind = .id_ref, .quantifier = .required },
14596 },16604 },
14597 },16605 },
14598 .{16606 .{
14599 .name = "InterpolateAtCentroid",16607 .name = "InterpolateAtCentroid",
14600 .opcode = 76,16608 .opcode = 76,
14601 .operands = &[_]Operand{16609 .operands = &.{
14602 .{ .kind = .IdRef, .quantifier = .required },16610 .{ .kind = .id_ref, .quantifier = .required },
14603 },16611 },
14604 },16612 },
14605 .{16613 .{
14606 .name = "InterpolateAtSample",16614 .name = "InterpolateAtSample",
14607 .opcode = 77,16615 .opcode = 77,
14608 .operands = &[_]Operand{16616 .operands = &.{
14609 .{ .kind = .IdRef, .quantifier = .required },16617 .{ .kind = .id_ref, .quantifier = .required },
14610 .{ .kind = .IdRef, .quantifier = .required },16618 .{ .kind = .id_ref, .quantifier = .required },
14611 },16619 },
14612 },16620 },
14613 .{16621 .{
14614 .name = "InterpolateAtOffset",16622 .name = "InterpolateAtOffset",
14615 .opcode = 78,16623 .opcode = 78,
14616 .operands = &[_]Operand{16624 .operands = &.{
14617 .{ .kind = .IdRef, .quantifier = .required },16625 .{ .kind = .id_ref, .quantifier = .required },
14618 .{ .kind = .IdRef, .quantifier = .required },16626 .{ .kind = .id_ref, .quantifier = .required },
14619 },16627 },
14620 },16628 },
14621 .{16629 .{
14622 .name = "NMin",16630 .name = "NMin",
14623 .opcode = 79,16631 .opcode = 79,
14624 .operands = &[_]Operand{16632 .operands = &.{
14625 .{ .kind = .IdRef, .quantifier = .required },16633 .{ .kind = .id_ref, .quantifier = .required },
14626 .{ .kind = .IdRef, .quantifier = .required },16634 .{ .kind = .id_ref, .quantifier = .required },
14627 },16635 },
14628 },16636 },
14629 .{16637 .{
14630 .name = "NMax",16638 .name = "NMax",
14631 .opcode = 80,16639 .opcode = 80,
14632 .operands = &[_]Operand{16640 .operands = &.{
14633 .{ .kind = .IdRef, .quantifier = .required },16641 .{ .kind = .id_ref, .quantifier = .required },
14634 .{ .kind = .IdRef, .quantifier = .required },16642 .{ .kind = .id_ref, .quantifier = .required },
14635 },16643 },
14636 },16644 },
14637 .{16645 .{
14638 .name = "NClamp",16646 .name = "NClamp",
14639 .opcode = 81,16647 .opcode = 81,
14640 .operands = &[_]Operand{16648 .operands = &.{
14641 .{ .kind = .IdRef, .quantifier = .required },16649 .{ .kind = .id_ref, .quantifier = .required },
14642 .{ .kind = .IdRef, .quantifier = .required },16650 .{ .kind = .id_ref, .quantifier = .required },
14643 .{ .kind = .IdRef, .quantifier = .required },16651 .{ .kind = .id_ref, .quantifier = .required },
14644 },16652 },
14645 },16653 },
14646 },16654 },
14647 .@"OpenCL.DebugInfo.100" => &[_]Instruction{16655 .spv_amd_shader_ballot => &.{
14648 .{16656 .{
14649 .name = "DebugInfoNone",16657 .name = "SwizzleInvocationsAMD",
16658 .opcode = 1,
16659 .operands = &.{
16660 .{ .kind = .id_ref, .quantifier = .required },
16661 .{ .kind = .id_ref, .quantifier = .required },
16662 },
16663 },
16664 .{
16665 .name = "SwizzleInvocationsMaskedAMD",
16666 .opcode = 2,
16667 .operands = &.{
16668 .{ .kind = .id_ref, .quantifier = .required },
16669 .{ .kind = .id_ref, .quantifier = .required },
16670 },
16671 },
16672 .{
16673 .name = "WriteInvocationAMD",
16674 .opcode = 3,
16675 .operands = &.{
16676 .{ .kind = .id_ref, .quantifier = .required },
16677 .{ .kind = .id_ref, .quantifier = .required },
16678 .{ .kind = .id_ref, .quantifier = .required },
16679 },
16680 },
16681 .{
16682 .name = "MbcntAMD",
16683 .opcode = 4,
16684 .operands = &.{
16685 .{ .kind = .id_ref, .quantifier = .required },
16686 },
16687 },
16688 },
16689 .non_semantic_debug_printf => &.{
16690 .{
16691 .name = "DebugPrintf",
16692 .opcode = 1,
16693 .operands = &.{
16694 .{ .kind = .id_ref, .quantifier = .required },
16695 .{ .kind = .id_ref, .quantifier = .variadic },
16696 },
16697 },
16698 },
16699 .spv_amd_gcn_shader => &.{
16700 .{
16701 .name = "CubeFaceIndexAMD",
16702 .opcode = 1,
16703 .operands = &.{
16704 .{ .kind = .id_ref, .quantifier = .required },
16705 },
16706 },
16707 .{
16708 .name = "CubeFaceCoordAMD",
16709 .opcode = 2,
16710 .operands = &.{
16711 .{ .kind = .id_ref, .quantifier = .required },
16712 },
16713 },
16714 .{
16715 .name = "TimeAMD",
16716 .opcode = 3,
16717 .operands = &.{},
16718 },
16719 },
16720 .open_cl_std => &.{
16721 .{
16722 .name = "acos",
14650 .opcode = 0,16723 .opcode = 0,
14651 .operands = &[_]Operand{},16724 .operands = &.{
16725 .{ .kind = .id_ref, .quantifier = .required },
16726 },
14652 },16727 },
14653 .{16728 .{
14654 .name = "DebugCompilationUnit",16729 .name = "acosh",
14655 .opcode = 1,16730 .opcode = 1,
14656 .operands = &[_]Operand{16731 .operands = &.{
14657 .{ .kind = .LiteralInteger, .quantifier = .required },16732 .{ .kind = .id_ref, .quantifier = .required },
14658 .{ .kind = .LiteralInteger, .quantifier = .required },
14659 .{ .kind = .IdRef, .quantifier = .required },
14660 .{ .kind = .SourceLanguage, .quantifier = .required },
14661 },16733 },
14662 },16734 },
14663 .{16735 .{
14664 .name = "DebugTypeBasic",16736 .name = "acospi",
14665 .opcode = 2,16737 .opcode = 2,
14666 .operands = &[_]Operand{16738 .operands = &.{
14667 .{ .kind = .IdRef, .quantifier = .required },16739 .{ .kind = .id_ref, .quantifier = .required },
14668 .{ .kind = .IdRef, .quantifier = .required },
14669 .{ .kind = .@"OpenCL.DebugInfo.100.DebugBaseTypeAttributeEncoding", .quantifier = .required },
14670 },16740 },
14671 },16741 },
14672 .{16742 .{
14673 .name = "DebugTypePointer",16743 .name = "asin",
14674 .opcode = 3,16744 .opcode = 3,
14675 .operands = &[_]Operand{16745 .operands = &.{
14676 .{ .kind = .IdRef, .quantifier = .required },16746 .{ .kind = .id_ref, .quantifier = .required },
14677 .{ .kind = .StorageClass, .quantifier = .required },
14678 .{ .kind = .@"OpenCL.DebugInfo.100.DebugInfoFlags", .quantifier = .required },
14679 },16747 },
14680 },16748 },
14681 .{16749 .{
14682 .name = "DebugTypeQualifier",16750 .name = "asinh",
14683 .opcode = 4,16751 .opcode = 4,
14684 .operands = &[_]Operand{16752 .operands = &.{
14685 .{ .kind = .IdRef, .quantifier = .required },16753 .{ .kind = .id_ref, .quantifier = .required },
14686 .{ .kind = .@"OpenCL.DebugInfo.100.DebugTypeQualifier", .quantifier = .required },
14687 },16754 },
14688 },16755 },
14689 .{16756 .{
14690 .name = "DebugTypeArray",16757 .name = "asinpi",
14691 .opcode = 5,16758 .opcode = 5,
14692 .operands = &[_]Operand{16759 .operands = &.{
14693 .{ .kind = .IdRef, .quantifier = .required },16760 .{ .kind = .id_ref, .quantifier = .required },
14694 .{ .kind = .IdRef, .quantifier = .variadic },
14695 },16761 },
14696 },16762 },
14697 .{16763 .{
14698 .name = "DebugTypeVector",16764 .name = "atan",
14699 .opcode = 6,16765 .opcode = 6,
14700 .operands = &[_]Operand{16766 .operands = &.{
14701 .{ .kind = .IdRef, .quantifier = .required },16767 .{ .kind = .id_ref, .quantifier = .required },
14702 .{ .kind = .LiteralInteger, .quantifier = .required },
14703 },16768 },
14704 },16769 },
14705 .{16770 .{
14706 .name = "DebugTypedef",16771 .name = "atan2",
14707 .opcode = 7,16772 .opcode = 7,
14708 .operands = &[_]Operand{16773 .operands = &.{
14709 .{ .kind = .IdRef, .quantifier = .required },16774 .{ .kind = .id_ref, .quantifier = .required },
14710 .{ .kind = .IdRef, .quantifier = .required },16775 .{ .kind = .id_ref, .quantifier = .required },
14711 .{ .kind = .IdRef, .quantifier = .required },
14712 .{ .kind = .LiteralInteger, .quantifier = .required },
14713 .{ .kind = .LiteralInteger, .quantifier = .required },
14714 .{ .kind = .IdRef, .quantifier = .required },
14715 },16776 },
14716 },16777 },
14717 .{16778 .{
14718 .name = "DebugTypeFunction",16779 .name = "atanh",
14719 .opcode = 8,16780 .opcode = 8,
14720 .operands = &[_]Operand{16781 .operands = &.{
14721 .{ .kind = .@"OpenCL.DebugInfo.100.DebugInfoFlags", .quantifier = .required },16782 .{ .kind = .id_ref, .quantifier = .required },
14722 .{ .kind = .IdRef, .quantifier = .required },
14723 .{ .kind = .IdRef, .quantifier = .variadic },
14724 },16783 },
14725 },16784 },
14726 .{16785 .{
14727 .name = "DebugTypeEnum",16786 .name = "atanpi",
14728 .opcode = 9,16787 .opcode = 9,
14729 .operands = &[_]Operand{16788 .operands = &.{
14730 .{ .kind = .IdRef, .quantifier = .required },16789 .{ .kind = .id_ref, .quantifier = .required },
14731 .{ .kind = .IdRef, .quantifier = .required },
14732 .{ .kind = .IdRef, .quantifier = .required },
14733 .{ .kind = .LiteralInteger, .quantifier = .required },
14734 .{ .kind = .LiteralInteger, .quantifier = .required },
14735 .{ .kind = .IdRef, .quantifier = .required },
14736 .{ .kind = .IdRef, .quantifier = .required },
14737 .{ .kind = .@"OpenCL.DebugInfo.100.DebugInfoFlags", .quantifier = .required },
14738 .{ .kind = .PairIdRefIdRef, .quantifier = .variadic },
14739 },16790 },
14740 },16791 },
14741 .{16792 .{
14742 .name = "DebugTypeComposite",16793 .name = "atan2pi",
14743 .opcode = 10,16794 .opcode = 10,
14744 .operands = &[_]Operand{16795 .operands = &.{
14745 .{ .kind = .IdRef, .quantifier = .required },16796 .{ .kind = .id_ref, .quantifier = .required },
14746 .{ .kind = .@"OpenCL.DebugInfo.100.DebugCompositeType", .quantifier = .required },16797 .{ .kind = .id_ref, .quantifier = .required },
14747 .{ .kind = .IdRef, .quantifier = .required },
14748 .{ .kind = .LiteralInteger, .quantifier = .required },
14749 .{ .kind = .LiteralInteger, .quantifier = .required },
14750 .{ .kind = .IdRef, .quantifier = .required },
14751 .{ .kind = .IdRef, .quantifier = .required },
14752 .{ .kind = .IdRef, .quantifier = .required },
14753 .{ .kind = .@"OpenCL.DebugInfo.100.DebugInfoFlags", .quantifier = .required },
14754 .{ .kind = .IdRef, .quantifier = .variadic },
14755 },16798 },
14756 },16799 },
14757 .{16800 .{
14758 .name = "DebugTypeMember",16801 .name = "cbrt",
14759 .opcode = 11,16802 .opcode = 11,
14760 .operands = &[_]Operand{16803 .operands = &.{
14761 .{ .kind = .IdRef, .quantifier = .required },16804 .{ .kind = .id_ref, .quantifier = .required },
14762 .{ .kind = .IdRef, .quantifier = .required },
14763 .{ .kind = .IdRef, .quantifier = .required },
14764 .{ .kind = .LiteralInteger, .quantifier = .required },
14765 .{ .kind = .LiteralInteger, .quantifier = .required },
14766 .{ .kind = .IdRef, .quantifier = .required },
14767 .{ .kind = .IdRef, .quantifier = .required },
14768 .{ .kind = .IdRef, .quantifier = .required },
14769 .{ .kind = .@"OpenCL.DebugInfo.100.DebugInfoFlags", .quantifier = .required },
14770 .{ .kind = .IdRef, .quantifier = .optional },
14771 },16805 },
14772 },16806 },
14773 .{16807 .{
14774 .name = "DebugTypeInheritance",16808 .name = "ceil",
14775 .opcode = 12,16809 .opcode = 12,
14776 .operands = &[_]Operand{16810 .operands = &.{
14777 .{ .kind = .IdRef, .quantifier = .required },16811 .{ .kind = .id_ref, .quantifier = .required },
14778 .{ .kind = .IdRef, .quantifier = .required },
14779 .{ .kind = .IdRef, .quantifier = .required },
14780 .{ .kind = .IdRef, .quantifier = .required },
14781 .{ .kind = .@"OpenCL.DebugInfo.100.DebugInfoFlags", .quantifier = .required },
14782 },16812 },
14783 },16813 },
14784 .{16814 .{
14785 .name = "DebugTypePtrToMember",16815 .name = "copysign",
14786 .opcode = 13,16816 .opcode = 13,
14787 .operands = &[_]Operand{16817 .operands = &.{
14788 .{ .kind = .IdRef, .quantifier = .required },16818 .{ .kind = .id_ref, .quantifier = .required },
14789 .{ .kind = .IdRef, .quantifier = .required },16819 .{ .kind = .id_ref, .quantifier = .required },
14790 },16820 },
14791 },16821 },
14792 .{16822 .{
14793 .name = "DebugTypeTemplate",16823 .name = "cos",
14794 .opcode = 14,16824 .opcode = 14,
14795 .operands = &[_]Operand{16825 .operands = &.{
14796 .{ .kind = .IdRef, .quantifier = .required },16826 .{ .kind = .id_ref, .quantifier = .required },
14797 .{ .kind = .IdRef, .quantifier = .variadic },
14798 },16827 },
14799 },16828 },
14800 .{16829 .{
14801 .name = "DebugTypeTemplateParameter",16830 .name = "cosh",
14802 .opcode = 15,16831 .opcode = 15,
14803 .operands = &[_]Operand{16832 .operands = &.{
14804 .{ .kind = .IdRef, .quantifier = .required },16833 .{ .kind = .id_ref, .quantifier = .required },
14805 .{ .kind = .IdRef, .quantifier = .required },
14806 .{ .kind = .IdRef, .quantifier = .required },
14807 .{ .kind = .IdRef, .quantifier = .required },
14808 .{ .kind = .LiteralInteger, .quantifier = .required },
14809 .{ .kind = .LiteralInteger, .quantifier = .required },
14810 },16834 },
14811 },16835 },
14812 .{16836 .{
14813 .name = "DebugTypeTemplateTemplateParameter",16837 .name = "cospi",
14814 .opcode = 16,16838 .opcode = 16,
14815 .operands = &[_]Operand{16839 .operands = &.{
14816 .{ .kind = .IdRef, .quantifier = .required },16840 .{ .kind = .id_ref, .quantifier = .required },
14817 .{ .kind = .IdRef, .quantifier = .required },
14818 .{ .kind = .IdRef, .quantifier = .required },
14819 .{ .kind = .LiteralInteger, .quantifier = .required },
14820 .{ .kind = .LiteralInteger, .quantifier = .required },
14821 },16841 },
14822 },16842 },
14823 .{16843 .{
14824 .name = "DebugTypeTemplateParameterPack",16844 .name = "erfc",
14825 .opcode = 17,16845 .opcode = 17,
14826 .operands = &[_]Operand{16846 .operands = &.{
14827 .{ .kind = .IdRef, .quantifier = .required },16847 .{ .kind = .id_ref, .quantifier = .required },
14828 .{ .kind = .IdRef, .quantifier = .required },
14829 .{ .kind = .LiteralInteger, .quantifier = .required },
14830 .{ .kind = .LiteralInteger, .quantifier = .required },
14831 .{ .kind = .IdRef, .quantifier = .variadic },
14832 },16848 },
14833 },16849 },
14834 .{16850 .{
14835 .name = "DebugGlobalVariable",16851 .name = "erf",
14836 .opcode = 18,16852 .opcode = 18,
14837 .operands = &[_]Operand{16853 .operands = &.{
14838 .{ .kind = .IdRef, .quantifier = .required },16854 .{ .kind = .id_ref, .quantifier = .required },
14839 .{ .kind = .IdRef, .quantifier = .required },
14840 .{ .kind = .IdRef, .quantifier = .required },
14841 .{ .kind = .LiteralInteger, .quantifier = .required },
14842 .{ .kind = .LiteralInteger, .quantifier = .required },
14843 .{ .kind = .IdRef, .quantifier = .required },
14844 .{ .kind = .IdRef, .quantifier = .required },
14845 .{ .kind = .IdRef, .quantifier = .required },
14846 .{ .kind = .@"OpenCL.DebugInfo.100.DebugInfoFlags", .quantifier = .required },
14847 .{ .kind = .IdRef, .quantifier = .optional },
14848 },16855 },
14849 },16856 },
14850 .{16857 .{
14851 .name = "DebugFunctionDeclaration",16858 .name = "exp",
14852 .opcode = 19,16859 .opcode = 19,
14853 .operands = &[_]Operand{16860 .operands = &.{
14854 .{ .kind = .IdRef, .quantifier = .required },16861 .{ .kind = .id_ref, .quantifier = .required },
14855 .{ .kind = .IdRef, .quantifier = .required },
14856 .{ .kind = .IdRef, .quantifier = .required },
14857 .{ .kind = .LiteralInteger, .quantifier = .required },
14858 .{ .kind = .LiteralInteger, .quantifier = .required },
14859 .{ .kind = .IdRef, .quantifier = .required },
14860 .{ .kind = .IdRef, .quantifier = .required },
14861 .{ .kind = .@"OpenCL.DebugInfo.100.DebugInfoFlags", .quantifier = .required },
14862 },16862 },
14863 },16863 },
14864 .{16864 .{
14865 .name = "DebugFunction",16865 .name = "exp2",
14866 .opcode = 20,16866 .opcode = 20,
14867 .operands = &[_]Operand{16867 .operands = &.{
14868 .{ .kind = .IdRef, .quantifier = .required },16868 .{ .kind = .id_ref, .quantifier = .required },
14869 .{ .kind = .IdRef, .quantifier = .required },
14870 .{ .kind = .IdRef, .quantifier = .required },
14871 .{ .kind = .LiteralInteger, .quantifier = .required },
14872 .{ .kind = .LiteralInteger, .quantifier = .required },
14873 .{ .kind = .IdRef, .quantifier = .required },
14874 .{ .kind = .IdRef, .quantifier = .required },
14875 .{ .kind = .@"OpenCL.DebugInfo.100.DebugInfoFlags", .quantifier = .required },
14876 .{ .kind = .LiteralInteger, .quantifier = .required },
14877 .{ .kind = .IdRef, .quantifier = .required },
14878 .{ .kind = .IdRef, .quantifier = .optional },
14879 },16869 },
14880 },16870 },
14881 .{16871 .{
14882 .name = "DebugLexicalBlock",16872 .name = "exp10",
14883 .opcode = 21,16873 .opcode = 21,
14884 .operands = &[_]Operand{16874 .operands = &.{
14885 .{ .kind = .IdRef, .quantifier = .required },16875 .{ .kind = .id_ref, .quantifier = .required },
14886 .{ .kind = .LiteralInteger, .quantifier = .required },
14887 .{ .kind = .LiteralInteger, .quantifier = .required },
14888 .{ .kind = .IdRef, .quantifier = .required },
14889 .{ .kind = .IdRef, .quantifier = .optional },
14890 },16876 },
14891 },16877 },
14892 .{16878 .{
14893 .name = "DebugLexicalBlockDiscriminator",16879 .name = "expm1",
14894 .opcode = 22,16880 .opcode = 22,
14895 .operands = &[_]Operand{16881 .operands = &.{
14896 .{ .kind = .IdRef, .quantifier = .required },16882 .{ .kind = .id_ref, .quantifier = .required },
14897 .{ .kind = .LiteralInteger, .quantifier = .required },
14898 .{ .kind = .IdRef, .quantifier = .required },
14899 },16883 },
14900 },16884 },
14901 .{16885 .{
14902 .name = "DebugScope",16886 .name = "fabs",
14903 .opcode = 23,16887 .opcode = 23,
14904 .operands = &[_]Operand{16888 .operands = &.{
14905 .{ .kind = .IdRef, .quantifier = .required },16889 .{ .kind = .id_ref, .quantifier = .required },
14906 .{ .kind = .IdRef, .quantifier = .optional },
14907 },16890 },
14908 },16891 },
14909 .{16892 .{
14910 .name = "DebugNoScope",16893 .name = "fdim",
14911 .opcode = 24,16894 .opcode = 24,
14912 .operands = &[_]Operand{},16895 .operands = &.{
16896 .{ .kind = .id_ref, .quantifier = .required },
16897 .{ .kind = .id_ref, .quantifier = .required },
16898 },
14913 },16899 },
14914 .{16900 .{
14915 .name = "DebugInlinedAt",16901 .name = "floor",
14916 .opcode = 25,16902 .opcode = 25,
14917 .operands = &[_]Operand{16903 .operands = &.{
14918 .{ .kind = .LiteralInteger, .quantifier = .required },16904 .{ .kind = .id_ref, .quantifier = .required },
14919 .{ .kind = .IdRef, .quantifier = .required },
14920 .{ .kind = .IdRef, .quantifier = .optional },
14921 },16905 },
14922 },16906 },
14923 .{16907 .{
14924 .name = "DebugLocalVariable",16908 .name = "fma",
14925 .opcode = 26,16909 .opcode = 26,
14926 .operands = &[_]Operand{16910 .operands = &.{
14927 .{ .kind = .IdRef, .quantifier = .required },16911 .{ .kind = .id_ref, .quantifier = .required },
14928 .{ .kind = .IdRef, .quantifier = .required },16912 .{ .kind = .id_ref, .quantifier = .required },
14929 .{ .kind = .IdRef, .quantifier = .required },16913 .{ .kind = .id_ref, .quantifier = .required },
14930 .{ .kind = .LiteralInteger, .quantifier = .required },
14931 .{ .kind = .LiteralInteger, .quantifier = .required },
14932 .{ .kind = .IdRef, .quantifier = .required },
14933 .{ .kind = .@"OpenCL.DebugInfo.100.DebugInfoFlags", .quantifier = .required },
14934 .{ .kind = .LiteralInteger, .quantifier = .optional },
14935 },16914 },
14936 },16915 },
14937 .{16916 .{
14938 .name = "DebugInlinedVariable",16917 .name = "fmax",
14939 .opcode = 27,16918 .opcode = 27,
14940 .operands = &[_]Operand{16919 .operands = &.{
14941 .{ .kind = .IdRef, .quantifier = .required },16920 .{ .kind = .id_ref, .quantifier = .required },
14942 .{ .kind = .IdRef, .quantifier = .required },16921 .{ .kind = .id_ref, .quantifier = .required },
14943 },16922 },
14944 },16923 },
14945 .{16924 .{
14946 .name = "DebugDeclare",16925 .name = "fmin",
14947 .opcode = 28,16926 .opcode = 28,
14948 .operands = &[_]Operand{16927 .operands = &.{
14949 .{ .kind = .IdRef, .quantifier = .required },16928 .{ .kind = .id_ref, .quantifier = .required },
14950 .{ .kind = .IdRef, .quantifier = .required },16929 .{ .kind = .id_ref, .quantifier = .required },
14951 .{ .kind = .IdRef, .quantifier = .required },
14952 },16930 },
14953 },16931 },
14954 .{16932 .{
14955 .name = "DebugValue",16933 .name = "fmod",
14956 .opcode = 29,16934 .opcode = 29,
14957 .operands = &[_]Operand{16935 .operands = &.{
14958 .{ .kind = .IdRef, .quantifier = .required },16936 .{ .kind = .id_ref, .quantifier = .required },
14959 .{ .kind = .IdRef, .quantifier = .required },16937 .{ .kind = .id_ref, .quantifier = .required },
14960 .{ .kind = .IdRef, .quantifier = .required },
14961 .{ .kind = .IdRef, .quantifier = .variadic },
14962 },16938 },
14963 },16939 },
14964 .{16940 .{
14965 .name = "DebugOperation",16941 .name = "fract",
14966 .opcode = 30,16942 .opcode = 30,
14967 .operands = &[_]Operand{16943 .operands = &.{
14968 .{ .kind = .@"OpenCL.DebugInfo.100.DebugOperation", .quantifier = .required },16944 .{ .kind = .id_ref, .quantifier = .required },
14969 .{ .kind = .LiteralInteger, .quantifier = .variadic },16945 .{ .kind = .id_ref, .quantifier = .required },
14970 },16946 },
14971 },16947 },
14972 .{16948 .{
14973 .name = "DebugExpression",16949 .name = "frexp",
14974 .opcode = 31,16950 .opcode = 31,
14975 .operands = &[_]Operand{16951 .operands = &.{
14976 .{ .kind = .IdRef, .quantifier = .variadic },16952 .{ .kind = .id_ref, .quantifier = .required },
16953 .{ .kind = .id_ref, .quantifier = .required },
14977 },16954 },
14978 },16955 },
14979 .{16956 .{
14980 .name = "DebugMacroDef",16957 .name = "hypot",
14981 .opcode = 32,16958 .opcode = 32,
14982 .operands = &[_]Operand{16959 .operands = &.{
14983 .{ .kind = .IdRef, .quantifier = .required },16960 .{ .kind = .id_ref, .quantifier = .required },
14984 .{ .kind = .LiteralInteger, .quantifier = .required },16961 .{ .kind = .id_ref, .quantifier = .required },
14985 .{ .kind = .IdRef, .quantifier = .required },16962 },
14986 .{ .kind = .IdRef, .quantifier = .optional },16963 },
16964 .{
16965 .name = "ilogb",
16966 .opcode = 33,
16967 .operands = &.{
16968 .{ .kind = .id_ref, .quantifier = .required },
16969 },
16970 },
16971 .{
16972 .name = "ldexp",
16973 .opcode = 34,
16974 .operands = &.{
16975 .{ .kind = .id_ref, .quantifier = .required },
16976 .{ .kind = .id_ref, .quantifier = .required },
16977 },
16978 },
16979 .{
16980 .name = "lgamma",
16981 .opcode = 35,
16982 .operands = &.{
16983 .{ .kind = .id_ref, .quantifier = .required },
16984 },
16985 },
16986 .{
16987 .name = "lgamma_r",
16988 .opcode = 36,
16989 .operands = &.{
16990 .{ .kind = .id_ref, .quantifier = .required },
16991 .{ .kind = .id_ref, .quantifier = .required },
16992 },
16993 },
16994 .{
16995 .name = "log",
16996 .opcode = 37,
16997 .operands = &.{
16998 .{ .kind = .id_ref, .quantifier = .required },
16999 },
17000 },
17001 .{
17002 .name = "log2",
17003 .opcode = 38,
17004 .operands = &.{
17005 .{ .kind = .id_ref, .quantifier = .required },
17006 },
17007 },
17008 .{
17009 .name = "log10",
17010 .opcode = 39,
17011 .operands = &.{
17012 .{ .kind = .id_ref, .quantifier = .required },
17013 },
17014 },
17015 .{
17016 .name = "log1p",
17017 .opcode = 40,
17018 .operands = &.{
17019 .{ .kind = .id_ref, .quantifier = .required },
17020 },
17021 },
17022 .{
17023 .name = "logb",
17024 .opcode = 41,
17025 .operands = &.{
17026 .{ .kind = .id_ref, .quantifier = .required },
17027 },
17028 },
17029 .{
17030 .name = "mad",
17031 .opcode = 42,
17032 .operands = &.{
17033 .{ .kind = .id_ref, .quantifier = .required },
17034 .{ .kind = .id_ref, .quantifier = .required },
17035 .{ .kind = .id_ref, .quantifier = .required },
17036 },
17037 },
17038 .{
17039 .name = "maxmag",
17040 .opcode = 43,
17041 .operands = &.{
17042 .{ .kind = .id_ref, .quantifier = .required },
17043 .{ .kind = .id_ref, .quantifier = .required },
17044 },
17045 },
17046 .{
17047 .name = "minmag",
17048 .opcode = 44,
17049 .operands = &.{
17050 .{ .kind = .id_ref, .quantifier = .required },
17051 .{ .kind = .id_ref, .quantifier = .required },
17052 },
17053 },
17054 .{
17055 .name = "modf",
17056 .opcode = 45,
17057 .operands = &.{
17058 .{ .kind = .id_ref, .quantifier = .required },
17059 .{ .kind = .id_ref, .quantifier = .required },
17060 },
17061 },
17062 .{
17063 .name = "nan",
17064 .opcode = 46,
17065 .operands = &.{
17066 .{ .kind = .id_ref, .quantifier = .required },
17067 },
17068 },
17069 .{
17070 .name = "nextafter",
17071 .opcode = 47,
17072 .operands = &.{
17073 .{ .kind = .id_ref, .quantifier = .required },
17074 .{ .kind = .id_ref, .quantifier = .required },
17075 },
17076 },
17077 .{
17078 .name = "pow",
17079 .opcode = 48,
17080 .operands = &.{
17081 .{ .kind = .id_ref, .quantifier = .required },
17082 .{ .kind = .id_ref, .quantifier = .required },
17083 },
17084 },
17085 .{
17086 .name = "pown",
17087 .opcode = 49,
17088 .operands = &.{
17089 .{ .kind = .id_ref, .quantifier = .required },
17090 .{ .kind = .id_ref, .quantifier = .required },
14987 },17091 },
14988 },17092 },
14989 .{17093 .{
14990 .name = "DebugMacroUndef",17094 .name = "powr",
14991 .opcode = 33,17095 .opcode = 50,
14992 .operands = &[_]Operand{17096 .operands = &.{
14993 .{ .kind = .IdRef, .quantifier = .required },17097 .{ .kind = .id_ref, .quantifier = .required },
14994 .{ .kind = .LiteralInteger, .quantifier = .required },17098 .{ .kind = .id_ref, .quantifier = .required },
14995 .{ .kind = .IdRef, .quantifier = .required },
14996 },17099 },
14997 },17100 },
14998 .{17101 .{
14999 .name = "DebugImportedEntity",17102 .name = "remainder",
15000 .opcode = 34,17103 .opcode = 51,
15001 .operands = &[_]Operand{17104 .operands = &.{
15002 .{ .kind = .IdRef, .quantifier = .required },17105 .{ .kind = .id_ref, .quantifier = .required },
15003 .{ .kind = .@"OpenCL.DebugInfo.100.DebugImportedEntity", .quantifier = .required },17106 .{ .kind = .id_ref, .quantifier = .required },
15004 .{ .kind = .IdRef, .quantifier = .required },
15005 .{ .kind = .IdRef, .quantifier = .required },
15006 .{ .kind = .LiteralInteger, .quantifier = .required },
15007 .{ .kind = .LiteralInteger, .quantifier = .required },
15008 .{ .kind = .IdRef, .quantifier = .required },
15009 },17107 },
15010 },17108 },
15011 .{17109 .{
15012 .name = "DebugSource",17110 .name = "remquo",
15013 .opcode = 35,17111 .opcode = 52,
15014 .operands = &[_]Operand{17112 .operands = &.{
15015 .{ .kind = .IdRef, .quantifier = .required },17113 .{ .kind = .id_ref, .quantifier = .required },
15016 .{ .kind = .IdRef, .quantifier = .optional },17114 .{ .kind = .id_ref, .quantifier = .required },
17115 .{ .kind = .id_ref, .quantifier = .required },
15017 },17116 },
15018 },17117 },
15019 .{17118 .{
15020 .name = "DebugModuleINTEL",17119 .name = "rint",
15021 .opcode = 36,17120 .opcode = 53,
15022 .operands = &[_]Operand{17121 .operands = &.{
15023 .{ .kind = .IdRef, .quantifier = .required },17122 .{ .kind = .id_ref, .quantifier = .required },
15024 .{ .kind = .IdRef, .quantifier = .required },
15025 .{ .kind = .IdRef, .quantifier = .required },
15026 .{ .kind = .LiteralInteger, .quantifier = .required },
15027 .{ .kind = .IdRef, .quantifier = .required },
15028 .{ .kind = .IdRef, .quantifier = .required },
15029 .{ .kind = .IdRef, .quantifier = .required },
15030 .{ .kind = .LiteralInteger, .quantifier = .required },
15031 },17123 },
15032 },17124 },
15033 },
15034 .SPV_AMD_shader_ballot => &[_]Instruction{
15035 .{17125 .{
15036 .name = "SwizzleInvocationsAMD",17126 .name = "rootn",
15037 .opcode = 1,17127 .opcode = 54,
15038 .operands = &[_]Operand{17128 .operands = &.{
15039 .{ .kind = .IdRef, .quantifier = .required },17129 .{ .kind = .id_ref, .quantifier = .required },
15040 .{ .kind = .IdRef, .quantifier = .required },17130 .{ .kind = .id_ref, .quantifier = .required },
15041 },17131 },
15042 },17132 },
15043 .{17133 .{
15044 .name = "SwizzleInvocationsMaskedAMD",17134 .name = "round",
15045 .opcode = 2,17135 .opcode = 55,
15046 .operands = &[_]Operand{17136 .operands = &.{
15047 .{ .kind = .IdRef, .quantifier = .required },17137 .{ .kind = .id_ref, .quantifier = .required },
15048 .{ .kind = .IdRef, .quantifier = .required },
15049 },17138 },
15050 },17139 },
15051 .{17140 .{
15052 .name = "WriteInvocationAMD",17141 .name = "rsqrt",
15053 .opcode = 3,17142 .opcode = 56,
15054 .operands = &[_]Operand{17143 .operands = &.{
15055 .{ .kind = .IdRef, .quantifier = .required },17144 .{ .kind = .id_ref, .quantifier = .required },
15056 .{ .kind = .IdRef, .quantifier = .required },
15057 .{ .kind = .IdRef, .quantifier = .required },
15058 },17145 },
15059 },17146 },
15060 .{17147 .{
15061 .name = "MbcntAMD",17148 .name = "sin",
15062 .opcode = 4,17149 .opcode = 57,
15063 .operands = &[_]Operand{17150 .operands = &.{
15064 .{ .kind = .IdRef, .quantifier = .required },17151 .{ .kind = .id_ref, .quantifier = .required },
15065 },17152 },
15066 },17153 },
15067 },
15068 .@"NonSemantic.Shader.DebugInfo.100" => &[_]Instruction{
15069 .{17154 .{
15070 .name = "DebugInfoNone",17155 .name = "sincos",
15071 .opcode = 0,17156 .opcode = 58,
15072 .operands = &[_]Operand{},17157 .operands = &.{
17158 .{ .kind = .id_ref, .quantifier = .required },
17159 .{ .kind = .id_ref, .quantifier = .required },
17160 },
15073 },17161 },
15074 .{17162 .{
15075 .name = "DebugCompilationUnit",17163 .name = "sinh",
15076 .opcode = 1,17164 .opcode = 59,
15077 .operands = &[_]Operand{17165 .operands = &.{
15078 .{ .kind = .IdRef, .quantifier = .required },17166 .{ .kind = .id_ref, .quantifier = .required },
15079 .{ .kind = .IdRef, .quantifier = .required },
15080 .{ .kind = .IdRef, .quantifier = .required },
15081 .{ .kind = .IdRef, .quantifier = .required },
15082 },17167 },
15083 },17168 },
15084 .{17169 .{
15085 .name = "DebugTypeBasic",17170 .name = "sinpi",
15086 .opcode = 2,17171 .opcode = 60,
15087 .operands = &[_]Operand{17172 .operands = &.{
15088 .{ .kind = .IdRef, .quantifier = .required },17173 .{ .kind = .id_ref, .quantifier = .required },
15089 .{ .kind = .IdRef, .quantifier = .required },
15090 .{ .kind = .IdRef, .quantifier = .required },
15091 .{ .kind = .IdRef, .quantifier = .required },
15092 },17174 },
15093 },17175 },
15094 .{17176 .{
15095 .name = "DebugTypePointer",17177 .name = "sqrt",
15096 .opcode = 3,17178 .opcode = 61,
15097 .operands = &[_]Operand{17179 .operands = &.{
15098 .{ .kind = .IdRef, .quantifier = .required },17180 .{ .kind = .id_ref, .quantifier = .required },
15099 .{ .kind = .IdRef, .quantifier = .required },
15100 .{ .kind = .IdRef, .quantifier = .required },
15101 },17181 },
15102 },17182 },
15103 .{17183 .{
15104 .name = "DebugTypeQualifier",17184 .name = "tan",
15105 .opcode = 4,17185 .opcode = 62,
15106 .operands = &[_]Operand{17186 .operands = &.{
15107 .{ .kind = .IdRef, .quantifier = .required },17187 .{ .kind = .id_ref, .quantifier = .required },
15108 .{ .kind = .IdRef, .quantifier = .required },
15109 },17188 },
15110 },17189 },
15111 .{17190 .{
15112 .name = "DebugTypeArray",17191 .name = "tanh",
15113 .opcode = 5,17192 .opcode = 63,
15114 .operands = &[_]Operand{17193 .operands = &.{
15115 .{ .kind = .IdRef, .quantifier = .required },17194 .{ .kind = .id_ref, .quantifier = .required },
15116 .{ .kind = .IdRef, .quantifier = .variadic },
15117 },17195 },
15118 },17196 },
15119 .{17197 .{
15120 .name = "DebugTypeVector",17198 .name = "tanpi",
15121 .opcode = 6,17199 .opcode = 64,
15122 .operands = &[_]Operand{17200 .operands = &.{
15123 .{ .kind = .IdRef, .quantifier = .required },17201 .{ .kind = .id_ref, .quantifier = .required },
15124 .{ .kind = .IdRef, .quantifier = .required },
15125 },17202 },
15126 },17203 },
15127 .{17204 .{
15128 .name = "DebugTypedef",17205 .name = "tgamma",
15129 .opcode = 7,17206 .opcode = 65,
15130 .operands = &[_]Operand{17207 .operands = &.{
15131 .{ .kind = .IdRef, .quantifier = .required },17208 .{ .kind = .id_ref, .quantifier = .required },
15132 .{ .kind = .IdRef, .quantifier = .required },
15133 .{ .kind = .IdRef, .quantifier = .required },
15134 .{ .kind = .IdRef, .quantifier = .required },
15135 .{ .kind = .IdRef, .quantifier = .required },
15136 .{ .kind = .IdRef, .quantifier = .required },
15137 },17209 },
15138 },17210 },
15139 .{17211 .{
15140 .name = "DebugTypeFunction",17212 .name = "trunc",
15141 .opcode = 8,17213 .opcode = 66,
15142 .operands = &[_]Operand{17214 .operands = &.{
15143 .{ .kind = .IdRef, .quantifier = .required },17215 .{ .kind = .id_ref, .quantifier = .required },
15144 .{ .kind = .IdRef, .quantifier = .required },
15145 .{ .kind = .IdRef, .quantifier = .variadic },
15146 },17216 },
15147 },17217 },
15148 .{17218 .{
15149 .name = "DebugTypeEnum",17219 .name = "half_cos",
15150 .opcode = 9,17220 .opcode = 67,
15151 .operands = &[_]Operand{17221 .operands = &.{
15152 .{ .kind = .IdRef, .quantifier = .required },17222 .{ .kind = .id_ref, .quantifier = .required },
15153 .{ .kind = .IdRef, .quantifier = .required },
15154 .{ .kind = .IdRef, .quantifier = .required },
15155 .{ .kind = .IdRef, .quantifier = .required },
15156 .{ .kind = .IdRef, .quantifier = .required },
15157 .{ .kind = .IdRef, .quantifier = .required },
15158 .{ .kind = .IdRef, .quantifier = .required },
15159 .{ .kind = .IdRef, .quantifier = .required },
15160 .{ .kind = .PairIdRefIdRef, .quantifier = .variadic },
15161 },17223 },
15162 },17224 },
15163 .{17225 .{
15164 .name = "DebugTypeComposite",17226 .name = "half_divide",
15165 .opcode = 10,17227 .opcode = 68,
15166 .operands = &[_]Operand{17228 .operands = &.{
15167 .{ .kind = .IdRef, .quantifier = .required },17229 .{ .kind = .id_ref, .quantifier = .required },
15168 .{ .kind = .IdRef, .quantifier = .required },17230 .{ .kind = .id_ref, .quantifier = .required },
15169 .{ .kind = .IdRef, .quantifier = .required },
15170 .{ .kind = .IdRef, .quantifier = .required },
15171 .{ .kind = .IdRef, .quantifier = .required },
15172 .{ .kind = .IdRef, .quantifier = .required },
15173 .{ .kind = .IdRef, .quantifier = .required },
15174 .{ .kind = .IdRef, .quantifier = .required },
15175 .{ .kind = .IdRef, .quantifier = .required },
15176 .{ .kind = .IdRef, .quantifier = .variadic },
15177 },17231 },
15178 },17232 },
15179 .{17233 .{
15180 .name = "DebugTypeMember",17234 .name = "half_exp",
15181 .opcode = 11,17235 .opcode = 69,
15182 .operands = &[_]Operand{17236 .operands = &.{
15183 .{ .kind = .IdRef, .quantifier = .required },17237 .{ .kind = .id_ref, .quantifier = .required },
15184 .{ .kind = .IdRef, .quantifier = .required },
15185 .{ .kind = .IdRef, .quantifier = .required },
15186 .{ .kind = .IdRef, .quantifier = .required },
15187 .{ .kind = .IdRef, .quantifier = .required },
15188 .{ .kind = .IdRef, .quantifier = .required },
15189 .{ .kind = .IdRef, .quantifier = .required },
15190 .{ .kind = .IdRef, .quantifier = .required },
15191 .{ .kind = .IdRef, .quantifier = .optional },
15192 },17238 },
15193 },17239 },
15194 .{17240 .{
15195 .name = "DebugTypeInheritance",17241 .name = "half_exp2",
15196 .opcode = 12,17242 .opcode = 70,
15197 .operands = &[_]Operand{17243 .operands = &.{
15198 .{ .kind = .IdRef, .quantifier = .required },17244 .{ .kind = .id_ref, .quantifier = .required },
15199 .{ .kind = .IdRef, .quantifier = .required },
15200 .{ .kind = .IdRef, .quantifier = .required },
15201 .{ .kind = .IdRef, .quantifier = .required },
15202 },17245 },
15203 },17246 },
15204 .{17247 .{
15205 .name = "DebugTypePtrToMember",17248 .name = "half_exp10",
15206 .opcode = 13,17249 .opcode = 71,
15207 .operands = &[_]Operand{17250 .operands = &.{
15208 .{ .kind = .IdRef, .quantifier = .required },17251 .{ .kind = .id_ref, .quantifier = .required },
15209 .{ .kind = .IdRef, .quantifier = .required },
15210 },17252 },
15211 },17253 },
15212 .{17254 .{
15213 .name = "DebugTypeTemplate",17255 .name = "half_log",
15214 .opcode = 14,17256 .opcode = 72,
15215 .operands = &[_]Operand{17257 .operands = &.{
15216 .{ .kind = .IdRef, .quantifier = .required },17258 .{ .kind = .id_ref, .quantifier = .required },
15217 .{ .kind = .IdRef, .quantifier = .variadic },
15218 },17259 },
15219 },17260 },
15220 .{17261 .{
15221 .name = "DebugTypeTemplateParameter",17262 .name = "half_log2",
15222 .opcode = 15,17263 .opcode = 73,
15223 .operands = &[_]Operand{17264 .operands = &.{
15224 .{ .kind = .IdRef, .quantifier = .required },17265 .{ .kind = .id_ref, .quantifier = .required },
15225 .{ .kind = .IdRef, .quantifier = .required },
15226 .{ .kind = .IdRef, .quantifier = .required },
15227 .{ .kind = .IdRef, .quantifier = .required },
15228 .{ .kind = .IdRef, .quantifier = .required },
15229 .{ .kind = .IdRef, .quantifier = .required },
15230 },17266 },
15231 },17267 },
15232 .{17268 .{
15233 .name = "DebugTypeTemplateTemplateParameter",17269 .name = "half_log10",
15234 .opcode = 16,17270 .opcode = 74,
15235 .operands = &[_]Operand{17271 .operands = &.{
15236 .{ .kind = .IdRef, .quantifier = .required },17272 .{ .kind = .id_ref, .quantifier = .required },
15237 .{ .kind = .IdRef, .quantifier = .required },
15238 .{ .kind = .IdRef, .quantifier = .required },
15239 .{ .kind = .IdRef, .quantifier = .required },
15240 .{ .kind = .IdRef, .quantifier = .required },
15241 },17273 },
15242 },17274 },
15243 .{17275 .{
15244 .name = "DebugTypeTemplateParameterPack",17276 .name = "half_powr",
15245 .opcode = 17,17277 .opcode = 75,
15246 .operands = &[_]Operand{17278 .operands = &.{
15247 .{ .kind = .IdRef, .quantifier = .required },17279 .{ .kind = .id_ref, .quantifier = .required },
15248 .{ .kind = .IdRef, .quantifier = .required },17280 .{ .kind = .id_ref, .quantifier = .required },
15249 .{ .kind = .IdRef, .quantifier = .required },
15250 .{ .kind = .IdRef, .quantifier = .required },
15251 .{ .kind = .IdRef, .quantifier = .variadic },
15252 },17281 },
15253 },17282 },
15254 .{17283 .{
15255 .name = "DebugGlobalVariable",17284 .name = "half_recip",
15256 .opcode = 18,17285 .opcode = 76,
15257 .operands = &[_]Operand{17286 .operands = &.{
15258 .{ .kind = .IdRef, .quantifier = .required },17287 .{ .kind = .id_ref, .quantifier = .required },
15259 .{ .kind = .IdRef, .quantifier = .required },
15260 .{ .kind = .IdRef, .quantifier = .required },
15261 .{ .kind = .IdRef, .quantifier = .required },
15262 .{ .kind = .IdRef, .quantifier = .required },
15263 .{ .kind = .IdRef, .quantifier = .required },
15264 .{ .kind = .IdRef, .quantifier = .required },
15265 .{ .kind = .IdRef, .quantifier = .required },
15266 .{ .kind = .IdRef, .quantifier = .required },
15267 .{ .kind = .IdRef, .quantifier = .optional },
15268 },17288 },
15269 },17289 },
15270 .{17290 .{
15271 .name = "DebugFunctionDeclaration",17291 .name = "half_rsqrt",
15272 .opcode = 19,17292 .opcode = 77,
15273 .operands = &[_]Operand{17293 .operands = &.{
15274 .{ .kind = .IdRef, .quantifier = .required },17294 .{ .kind = .id_ref, .quantifier = .required },
15275 .{ .kind = .IdRef, .quantifier = .required },
15276 .{ .kind = .IdRef, .quantifier = .required },
15277 .{ .kind = .IdRef, .quantifier = .required },
15278 .{ .kind = .IdRef, .quantifier = .required },
15279 .{ .kind = .IdRef, .quantifier = .required },
15280 .{ .kind = .IdRef, .quantifier = .required },
15281 .{ .kind = .IdRef, .quantifier = .required },
15282 },17295 },
15283 },17296 },
15284 .{17297 .{
15285 .name = "DebugFunction",17298 .name = "half_sin",
15286 .opcode = 20,17299 .opcode = 78,
15287 .operands = &[_]Operand{17300 .operands = &.{
15288 .{ .kind = .IdRef, .quantifier = .required },17301 .{ .kind = .id_ref, .quantifier = .required },
15289 .{ .kind = .IdRef, .quantifier = .required },
15290 .{ .kind = .IdRef, .quantifier = .required },
15291 .{ .kind = .IdRef, .quantifier = .required },
15292 .{ .kind = .IdRef, .quantifier = .required },
15293 .{ .kind = .IdRef, .quantifier = .required },
15294 .{ .kind = .IdRef, .quantifier = .required },
15295 .{ .kind = .IdRef, .quantifier = .required },
15296 .{ .kind = .IdRef, .quantifier = .required },
15297 .{ .kind = .IdRef, .quantifier = .optional },
15298 },17302 },
15299 },17303 },
15300 .{17304 .{
15301 .name = "DebugLexicalBlock",17305 .name = "half_sqrt",
15302 .opcode = 21,17306 .opcode = 79,
15303 .operands = &[_]Operand{17307 .operands = &.{
15304 .{ .kind = .IdRef, .quantifier = .required },17308 .{ .kind = .id_ref, .quantifier = .required },
15305 .{ .kind = .IdRef, .quantifier = .required },
15306 .{ .kind = .IdRef, .quantifier = .required },
15307 .{ .kind = .IdRef, .quantifier = .required },
15308 .{ .kind = .IdRef, .quantifier = .optional },
15309 },17309 },
15310 },17310 },
15311 .{17311 .{
15312 .name = "DebugLexicalBlockDiscriminator",17312 .name = "half_tan",
15313 .opcode = 22,17313 .opcode = 80,
15314 .operands = &[_]Operand{17314 .operands = &.{
15315 .{ .kind = .IdRef, .quantifier = .required },17315 .{ .kind = .id_ref, .quantifier = .required },
15316 .{ .kind = .IdRef, .quantifier = .required },
15317 .{ .kind = .IdRef, .quantifier = .required },
15318 },17316 },
15319 },17317 },
15320 .{17318 .{
15321 .name = "DebugScope",17319 .name = "native_cos",
15322 .opcode = 23,17320 .opcode = 81,
15323 .operands = &[_]Operand{17321 .operands = &.{
15324 .{ .kind = .IdRef, .quantifier = .required },17322 .{ .kind = .id_ref, .quantifier = .required },
15325 .{ .kind = .IdRef, .quantifier = .optional },
15326 },17323 },
15327 },17324 },
15328 .{17325 .{
15329 .name = "DebugNoScope",17326 .name = "native_divide",
15330 .opcode = 24,17327 .opcode = 82,
15331 .operands = &[_]Operand{},17328 .operands = &.{
17329 .{ .kind = .id_ref, .quantifier = .required },
17330 .{ .kind = .id_ref, .quantifier = .required },
17331 },
15332 },17332 },
15333 .{17333 .{
15334 .name = "DebugInlinedAt",17334 .name = "native_exp",
15335 .opcode = 25,17335 .opcode = 83,
15336 .operands = &[_]Operand{17336 .operands = &.{
15337 .{ .kind = .IdRef, .quantifier = .required },17337 .{ .kind = .id_ref, .quantifier = .required },
15338 .{ .kind = .IdRef, .quantifier = .required },
15339 .{ .kind = .IdRef, .quantifier = .optional },
15340 },17338 },
15341 },17339 },
15342 .{17340 .{
15343 .name = "DebugLocalVariable",17341 .name = "native_exp2",
15344 .opcode = 26,17342 .opcode = 84,
15345 .operands = &[_]Operand{17343 .operands = &.{
15346 .{ .kind = .IdRef, .quantifier = .required },17344 .{ .kind = .id_ref, .quantifier = .required },
15347 .{ .kind = .IdRef, .quantifier = .required },
15348 .{ .kind = .IdRef, .quantifier = .required },
15349 .{ .kind = .IdRef, .quantifier = .required },
15350 .{ .kind = .IdRef, .quantifier = .required },
15351 .{ .kind = .IdRef, .quantifier = .required },
15352 .{ .kind = .IdRef, .quantifier = .required },
15353 .{ .kind = .IdRef, .quantifier = .optional },
15354 },17345 },
15355 },17346 },
15356 .{17347 .{
15357 .name = "DebugInlinedVariable",17348 .name = "native_exp10",
15358 .opcode = 27,17349 .opcode = 85,
15359 .operands = &[_]Operand{17350 .operands = &.{
15360 .{ .kind = .IdRef, .quantifier = .required },17351 .{ .kind = .id_ref, .quantifier = .required },
15361 .{ .kind = .IdRef, .quantifier = .required },
15362 },17352 },
15363 },17353 },
15364 .{17354 .{
15365 .name = "DebugDeclare",17355 .name = "native_log",
15366 .opcode = 28,17356 .opcode = 86,
15367 .operands = &[_]Operand{17357 .operands = &.{
15368 .{ .kind = .IdRef, .quantifier = .required },17358 .{ .kind = .id_ref, .quantifier = .required },
15369 .{ .kind = .IdRef, .quantifier = .required },
15370 .{ .kind = .IdRef, .quantifier = .required },
15371 .{ .kind = .IdRef, .quantifier = .variadic },
15372 },17359 },
15373 },17360 },
15374 .{17361 .{
15375 .name = "DebugValue",17362 .name = "native_log2",
15376 .opcode = 29,17363 .opcode = 87,
15377 .operands = &[_]Operand{17364 .operands = &.{
15378 .{ .kind = .IdRef, .quantifier = .required },17365 .{ .kind = .id_ref, .quantifier = .required },
15379 .{ .kind = .IdRef, .quantifier = .required },
15380 .{ .kind = .IdRef, .quantifier = .required },
15381 .{ .kind = .IdRef, .quantifier = .variadic },
15382 },17366 },
15383 },17367 },
15384 .{17368 .{
15385 .name = "DebugOperation",17369 .name = "native_log10",
15386 .opcode = 30,17370 .opcode = 88,
15387 .operands = &[_]Operand{17371 .operands = &.{
15388 .{ .kind = .IdRef, .quantifier = .required },17372 .{ .kind = .id_ref, .quantifier = .required },
15389 .{ .kind = .IdRef, .quantifier = .variadic },
15390 },17373 },
15391 },17374 },
15392 .{17375 .{
15393 .name = "DebugExpression",17376 .name = "native_powr",
15394 .opcode = 31,17377 .opcode = 89,
15395 .operands = &[_]Operand{17378 .operands = &.{
15396 .{ .kind = .IdRef, .quantifier = .variadic },17379 .{ .kind = .id_ref, .quantifier = .required },
17380 .{ .kind = .id_ref, .quantifier = .required },
15397 },17381 },
15398 },17382 },
15399 .{17383 .{
15400 .name = "DebugMacroDef",17384 .name = "native_recip",
15401 .opcode = 32,17385 .opcode = 90,
15402 .operands = &[_]Operand{17386 .operands = &.{
15403 .{ .kind = .IdRef, .quantifier = .required },17387 .{ .kind = .id_ref, .quantifier = .required },
15404 .{ .kind = .IdRef, .quantifier = .required },
15405 .{ .kind = .IdRef, .quantifier = .required },
15406 .{ .kind = .IdRef, .quantifier = .optional },
15407 },17388 },
15408 },17389 },
15409 .{17390 .{
15410 .name = "DebugMacroUndef",17391 .name = "native_rsqrt",
15411 .opcode = 33,17392 .opcode = 91,
15412 .operands = &[_]Operand{17393 .operands = &.{
15413 .{ .kind = .IdRef, .quantifier = .required },17394 .{ .kind = .id_ref, .quantifier = .required },
15414 .{ .kind = .IdRef, .quantifier = .required },
15415 .{ .kind = .IdRef, .quantifier = .required },
15416 },17395 },
15417 },17396 },
15418 .{17397 .{
15419 .name = "DebugImportedEntity",17398 .name = "native_sin",
15420 .opcode = 34,17399 .opcode = 92,
15421 .operands = &[_]Operand{17400 .operands = &.{
15422 .{ .kind = .IdRef, .quantifier = .required },17401 .{ .kind = .id_ref, .quantifier = .required },
15423 .{ .kind = .IdRef, .quantifier = .required },
15424 .{ .kind = .IdRef, .quantifier = .required },
15425 .{ .kind = .IdRef, .quantifier = .required },
15426 .{ .kind = .IdRef, .quantifier = .required },
15427 .{ .kind = .IdRef, .quantifier = .required },
15428 .{ .kind = .IdRef, .quantifier = .required },
15429 },17402 },
15430 },17403 },
15431 .{17404 .{
15432 .name = "DebugSource",17405 .name = "native_sqrt",
15433 .opcode = 35,17406 .opcode = 93,
15434 .operands = &[_]Operand{17407 .operands = &.{
15435 .{ .kind = .IdRef, .quantifier = .required },17408 .{ .kind = .id_ref, .quantifier = .required },
15436 .{ .kind = .IdRef, .quantifier = .optional },
15437 },17409 },
15438 },17410 },
15439 .{17411 .{
15440 .name = "DebugFunctionDefinition",17412 .name = "native_tan",
15441 .opcode = 101,17413 .opcode = 94,
15442 .operands = &[_]Operand{17414 .operands = &.{
15443 .{ .kind = .IdRef, .quantifier = .required },17415 .{ .kind = .id_ref, .quantifier = .required },
15444 .{ .kind = .IdRef, .quantifier = .required },
15445 },17416 },
15446 },17417 },
15447 .{17418 .{
15448 .name = "DebugSourceContinued",17419 .name = "fclamp",
15449 .opcode = 102,17420 .opcode = 95,
15450 .operands = &[_]Operand{17421 .operands = &.{
15451 .{ .kind = .IdRef, .quantifier = .required },17422 .{ .kind = .id_ref, .quantifier = .required },
17423 .{ .kind = .id_ref, .quantifier = .required },
17424 .{ .kind = .id_ref, .quantifier = .required },
15452 },17425 },
15453 },17426 },
15454 .{17427 .{
15455 .name = "DebugLine",17428 .name = "degrees",
15456 .opcode = 103,17429 .opcode = 96,
15457 .operands = &[_]Operand{17430 .operands = &.{
15458 .{ .kind = .IdRef, .quantifier = .required },17431 .{ .kind = .id_ref, .quantifier = .required },
15459 .{ .kind = .IdRef, .quantifier = .required },
15460 .{ .kind = .IdRef, .quantifier = .required },
15461 .{ .kind = .IdRef, .quantifier = .required },
15462 .{ .kind = .IdRef, .quantifier = .required },
15463 },17432 },
15464 },17433 },
15465 .{17434 .{
15466 .name = "DebugNoLine",17435 .name = "fmax_common",
15467 .opcode = 104,17436 .opcode = 97,
15468 .operands = &[_]Operand{},17437 .operands = &.{
17438 .{ .kind = .id_ref, .quantifier = .required },
17439 .{ .kind = .id_ref, .quantifier = .required },
17440 },
15469 },17441 },
15470 .{17442 .{
15471 .name = "DebugBuildIdentifier",17443 .name = "fmin_common",
15472 .opcode = 105,17444 .opcode = 98,
15473 .operands = &[_]Operand{17445 .operands = &.{
15474 .{ .kind = .IdRef, .quantifier = .required },17446 .{ .kind = .id_ref, .quantifier = .required },
15475 .{ .kind = .IdRef, .quantifier = .required },17447 .{ .kind = .id_ref, .quantifier = .required },
15476 },17448 },
15477 },17449 },
15478 .{17450 .{
15479 .name = "DebugStoragePath",17451 .name = "mix",
15480 .opcode = 106,17452 .opcode = 99,
15481 .operands = &[_]Operand{17453 .operands = &.{
15482 .{ .kind = .IdRef, .quantifier = .required },17454 .{ .kind = .id_ref, .quantifier = .required },
17455 .{ .kind = .id_ref, .quantifier = .required },
17456 .{ .kind = .id_ref, .quantifier = .required },
15483 },17457 },
15484 },17458 },
15485 .{17459 .{
15486 .name = "DebugEntryPoint",17460 .name = "radians",
15487 .opcode = 107,17461 .opcode = 100,
15488 .operands = &[_]Operand{17462 .operands = &.{
15489 .{ .kind = .IdRef, .quantifier = .required },17463 .{ .kind = .id_ref, .quantifier = .required },
15490 .{ .kind = .IdRef, .quantifier = .required },
15491 .{ .kind = .IdRef, .quantifier = .required },
15492 .{ .kind = .IdRef, .quantifier = .required },
15493 },17464 },
15494 },17465 },
15495 .{17466 .{
15496 .name = "DebugTypeMatrix",17467 .name = "step",
15497 .opcode = 108,17468 .opcode = 101,
15498 .operands = &[_]Operand{17469 .operands = &.{
15499 .{ .kind = .IdRef, .quantifier = .required },17470 .{ .kind = .id_ref, .quantifier = .required },
15500 .{ .kind = .IdRef, .quantifier = .required },17471 .{ .kind = .id_ref, .quantifier = .required },
15501 .{ .kind = .IdRef, .quantifier = .required },
15502 },17472 },
15503 },17473 },
15504 },
15505 .@"NonSemantic.VkspReflection" => &[_]Instruction{
15506 .{17474 .{
15507 .name = "Configuration",17475 .name = "smoothstep",
15508 .opcode = 1,17476 .opcode = 102,
15509 .operands = &[_]Operand{17477 .operands = &.{
15510 .{ .kind = .LiteralString, .quantifier = .required },17478 .{ .kind = .id_ref, .quantifier = .required },
15511 .{ .kind = .LiteralInteger, .quantifier = .required },17479 .{ .kind = .id_ref, .quantifier = .required },
15512 .{ .kind = .LiteralString, .quantifier = .required },17480 .{ .kind = .id_ref, .quantifier = .required },
15513 .{ .kind = .LiteralString, .quantifier = .required },
15514 .{ .kind = .LiteralString, .quantifier = .required },
15515 .{ .kind = .LiteralInteger, .quantifier = .required },
15516 .{ .kind = .LiteralInteger, .quantifier = .required },
15517 .{ .kind = .LiteralInteger, .quantifier = .required },
15518 },17481 },
15519 },17482 },
15520 .{17483 .{
15521 .name = "StartCounter",17484 .name = "sign",
15522 .opcode = 2,17485 .opcode = 103,
15523 .operands = &[_]Operand{17486 .operands = &.{
15524 .{ .kind = .LiteralString, .quantifier = .required },17487 .{ .kind = .id_ref, .quantifier = .required },
15525 },17488 },
15526 },17489 },
15527 .{17490 .{
15528 .name = "StopCounter",17491 .name = "cross",
15529 .opcode = 3,17492 .opcode = 104,
15530 .operands = &[_]Operand{17493 .operands = &.{
15531 .{ .kind = .IdRef, .quantifier = .required },17494 .{ .kind = .id_ref, .quantifier = .required },
17495 .{ .kind = .id_ref, .quantifier = .required },
15532 },17496 },
15533 },17497 },
15534 .{17498 .{
15535 .name = "PushConstants",17499 .name = "distance",
15536 .opcode = 4,17500 .opcode = 105,
15537 .operands = &[_]Operand{17501 .operands = &.{
15538 .{ .kind = .LiteralInteger, .quantifier = .required },17502 .{ .kind = .id_ref, .quantifier = .required },
15539 .{ .kind = .LiteralInteger, .quantifier = .required },17503 .{ .kind = .id_ref, .quantifier = .required },
15540 .{ .kind = .LiteralString, .quantifier = .required },
15541 .{ .kind = .LiteralInteger, .quantifier = .required },
15542 },17504 },
15543 },17505 },
15544 .{17506 .{
15545 .name = "SpecializationMapEntry",17507 .name = "length",
15546 .opcode = 5,17508 .opcode = 106,
15547 .operands = &[_]Operand{17509 .operands = &.{
15548 .{ .kind = .LiteralInteger, .quantifier = .required },17510 .{ .kind = .id_ref, .quantifier = .required },
15549 .{ .kind = .LiteralInteger, .quantifier = .required },
15550 .{ .kind = .LiteralInteger, .quantifier = .required },
15551 },17511 },
15552 },17512 },
15553 .{17513 .{
15554 .name = "DescriptorSetBuffer",17514 .name = "normalize",
15555 .opcode = 6,17515 .opcode = 107,
15556 .operands = &[_]Operand{17516 .operands = &.{
15557 .{ .kind = .LiteralInteger, .quantifier = .required },17517 .{ .kind = .id_ref, .quantifier = .required },
15558 .{ .kind = .LiteralInteger, .quantifier = .required },
15559 .{ .kind = .LiteralInteger, .quantifier = .required },
15560 .{ .kind = .LiteralInteger, .quantifier = .required },
15561 .{ .kind = .LiteralInteger, .quantifier = .required },
15562 .{ .kind = .LiteralInteger, .quantifier = .required },
15563 .{ .kind = .LiteralInteger, .quantifier = .required },
15564 .{ .kind = .LiteralInteger, .quantifier = .required },
15565 .{ .kind = .LiteralInteger, .quantifier = .required },
15566 .{ .kind = .LiteralInteger, .quantifier = .required },
15567 .{ .kind = .LiteralInteger, .quantifier = .required },
15568 .{ .kind = .LiteralInteger, .quantifier = .required },
15569 .{ .kind = .LiteralInteger, .quantifier = .required },
15570 },17518 },
15571 },17519 },
15572 .{17520 .{
15573 .name = "DescriptorSetImage",17521 .name = "fast_distance",
15574 .opcode = 7,17522 .opcode = 108,
15575 .operands = &[_]Operand{17523 .operands = &.{
15576 .{ .kind = .LiteralInteger, .quantifier = .required },17524 .{ .kind = .id_ref, .quantifier = .required },
15577 .{ .kind = .LiteralInteger, .quantifier = .required },17525 .{ .kind = .id_ref, .quantifier = .required },
15578 .{ .kind = .LiteralInteger, .quantifier = .required },
15579 .{ .kind = .LiteralInteger, .quantifier = .required },
15580 .{ .kind = .LiteralInteger, .quantifier = .required },
15581 .{ .kind = .LiteralInteger, .quantifier = .required },
15582 .{ .kind = .LiteralInteger, .quantifier = .required },
15583 .{ .kind = .LiteralInteger, .quantifier = .required },
15584 .{ .kind = .LiteralInteger, .quantifier = .required },
15585 .{ .kind = .LiteralInteger, .quantifier = .required },
15586 .{ .kind = .LiteralInteger, .quantifier = .required },
15587 .{ .kind = .LiteralInteger, .quantifier = .required },
15588 .{ .kind = .LiteralInteger, .quantifier = .required },
15589 .{ .kind = .LiteralInteger, .quantifier = .required },
15590 .{ .kind = .LiteralInteger, .quantifier = .required },
15591 .{ .kind = .LiteralInteger, .quantifier = .required },
15592 .{ .kind = .LiteralInteger, .quantifier = .required },
15593 .{ .kind = .LiteralInteger, .quantifier = .required },
15594 .{ .kind = .LiteralInteger, .quantifier = .required },
15595 .{ .kind = .LiteralInteger, .quantifier = .required },
15596 .{ .kind = .LiteralInteger, .quantifier = .required },
15597 .{ .kind = .LiteralInteger, .quantifier = .required },
15598 .{ .kind = .LiteralInteger, .quantifier = .required },
15599 .{ .kind = .LiteralInteger, .quantifier = .required },
15600 .{ .kind = .LiteralInteger, .quantifier = .required },
15601 .{ .kind = .LiteralInteger, .quantifier = .required },
15602 .{ .kind = .LiteralInteger, .quantifier = .required },
15603 .{ .kind = .LiteralInteger, .quantifier = .required },
15604 .{ .kind = .LiteralInteger, .quantifier = .required },
15605 .{ .kind = .LiteralInteger, .quantifier = .required },
15606 .{ .kind = .LiteralInteger, .quantifier = .required },
15607 .{ .kind = .LiteralInteger, .quantifier = .required },
15608 .{ .kind = .LiteralInteger, .quantifier = .required },
15609 },17526 },
15610 },17527 },
15611 .{17528 .{
15612 .name = "DescriptorSetSampler",17529 .name = "fast_length",
15613 .opcode = 8,17530 .opcode = 109,
15614 .operands = &[_]Operand{17531 .operands = &.{
15615 .{ .kind = .LiteralInteger, .quantifier = .required },17532 .{ .kind = .id_ref, .quantifier = .required },
15616 .{ .kind = .LiteralInteger, .quantifier = .required },
15617 .{ .kind = .LiteralInteger, .quantifier = .required },
15618 .{ .kind = .LiteralInteger, .quantifier = .required },
15619 .{ .kind = .LiteralInteger, .quantifier = .required },
15620 .{ .kind = .LiteralInteger, .quantifier = .required },
15621 .{ .kind = .LiteralInteger, .quantifier = .required },
15622 .{ .kind = .LiteralInteger, .quantifier = .required },
15623 .{ .kind = .LiteralInteger, .quantifier = .required },
15624 .{ .kind = .LiteralInteger, .quantifier = .required },
15625 .{ .kind = .LiteralFloat, .quantifier = .required },
15626 .{ .kind = .LiteralInteger, .quantifier = .required },
15627 .{ .kind = .LiteralFloat, .quantifier = .required },
15628 .{ .kind = .LiteralInteger, .quantifier = .required },
15629 .{ .kind = .LiteralInteger, .quantifier = .required },
15630 .{ .kind = .LiteralFloat, .quantifier = .required },
15631 .{ .kind = .LiteralFloat, .quantifier = .required },
15632 .{ .kind = .LiteralInteger, .quantifier = .required },
15633 .{ .kind = .LiteralInteger, .quantifier = .required },
15634 },17533 },
15635 },17534 },
15636 },
15637 .@"NonSemantic.ClspvReflection.6" => &[_]Instruction{
15638 .{17535 .{
15639 .name = "Kernel",17536 .name = "fast_normalize",
15640 .opcode = 1,17537 .opcode = 110,
15641 .operands = &[_]Operand{17538 .operands = &.{
15642 .{ .kind = .IdRef, .quantifier = .required },17539 .{ .kind = .id_ref, .quantifier = .required },
15643 .{ .kind = .IdRef, .quantifier = .required },
15644 .{ .kind = .IdRef, .quantifier = .optional },
15645 .{ .kind = .IdRef, .quantifier = .optional },
15646 .{ .kind = .IdRef, .quantifier = .optional },
15647 },17540 },
15648 },17541 },
15649 .{17542 .{
15650 .name = "ArgumentInfo",17543 .name = "s_abs",
15651 .opcode = 2,17544 .opcode = 141,
15652 .operands = &[_]Operand{17545 .operands = &.{
15653 .{ .kind = .IdRef, .quantifier = .required },17546 .{ .kind = .id_ref, .quantifier = .required },
15654 .{ .kind = .IdRef, .quantifier = .optional },
15655 .{ .kind = .IdRef, .quantifier = .optional },
15656 .{ .kind = .IdRef, .quantifier = .optional },
15657 .{ .kind = .IdRef, .quantifier = .optional },
15658 },17547 },
15659 },17548 },
15660 .{17549 .{
15661 .name = "ArgumentStorageBuffer",17550 .name = "s_abs_diff",
15662 .opcode = 3,17551 .opcode = 142,
15663 .operands = &[_]Operand{17552 .operands = &.{
15664 .{ .kind = .IdRef, .quantifier = .required },17553 .{ .kind = .id_ref, .quantifier = .required },
15665 .{ .kind = .IdRef, .quantifier = .required },17554 .{ .kind = .id_ref, .quantifier = .required },
15666 .{ .kind = .IdRef, .quantifier = .required },
15667 .{ .kind = .IdRef, .quantifier = .required },
15668 .{ .kind = .IdRef, .quantifier = .optional },
15669 },17555 },
15670 },17556 },
15671 .{17557 .{
15672 .name = "ArgumentUniform",17558 .name = "s_add_sat",
15673 .opcode = 4,17559 .opcode = 143,
15674 .operands = &[_]Operand{17560 .operands = &.{
15675 .{ .kind = .IdRef, .quantifier = .required },17561 .{ .kind = .id_ref, .quantifier = .required },
15676 .{ .kind = .IdRef, .quantifier = .required },17562 .{ .kind = .id_ref, .quantifier = .required },
15677 .{ .kind = .IdRef, .quantifier = .required },
15678 .{ .kind = .IdRef, .quantifier = .required },
15679 .{ .kind = .IdRef, .quantifier = .optional },
15680 },17563 },
15681 },17564 },
15682 .{17565 .{
15683 .name = "ArgumentPodStorageBuffer",17566 .name = "u_add_sat",
15684 .opcode = 5,17567 .opcode = 144,
15685 .operands = &[_]Operand{17568 .operands = &.{
15686 .{ .kind = .IdRef, .quantifier = .required },17569 .{ .kind = .id_ref, .quantifier = .required },
15687 .{ .kind = .IdRef, .quantifier = .required },17570 .{ .kind = .id_ref, .quantifier = .required },
15688 .{ .kind = .IdRef, .quantifier = .required },
15689 .{ .kind = .IdRef, .quantifier = .required },
15690 .{ .kind = .IdRef, .quantifier = .required },
15691 .{ .kind = .IdRef, .quantifier = .required },
15692 .{ .kind = .IdRef, .quantifier = .optional },
15693 },17571 },
15694 },17572 },
15695 .{17573 .{
15696 .name = "ArgumentPodUniform",17574 .name = "s_hadd",
15697 .opcode = 6,17575 .opcode = 145,
15698 .operands = &[_]Operand{17576 .operands = &.{
15699 .{ .kind = .IdRef, .quantifier = .required },17577 .{ .kind = .id_ref, .quantifier = .required },
15700 .{ .kind = .IdRef, .quantifier = .required },17578 .{ .kind = .id_ref, .quantifier = .required },
15701 .{ .kind = .IdRef, .quantifier = .required },
15702 .{ .kind = .IdRef, .quantifier = .required },
15703 .{ .kind = .IdRef, .quantifier = .required },
15704 .{ .kind = .IdRef, .quantifier = .required },
15705 .{ .kind = .IdRef, .quantifier = .optional },
15706 },17579 },
15707 },17580 },
15708 .{17581 .{
15709 .name = "ArgumentPodPushConstant",17582 .name = "u_hadd",
15710 .opcode = 7,17583 .opcode = 146,
15711 .operands = &[_]Operand{17584 .operands = &.{
15712 .{ .kind = .IdRef, .quantifier = .required },17585 .{ .kind = .id_ref, .quantifier = .required },
15713 .{ .kind = .IdRef, .quantifier = .required },17586 .{ .kind = .id_ref, .quantifier = .required },
15714 .{ .kind = .IdRef, .quantifier = .required },
15715 .{ .kind = .IdRef, .quantifier = .required },
15716 .{ .kind = .IdRef, .quantifier = .optional },
15717 },17587 },
15718 },17588 },
15719 .{17589 .{
15720 .name = "ArgumentSampledImage",17590 .name = "s_rhadd",
15721 .opcode = 8,17591 .opcode = 147,
15722 .operands = &[_]Operand{17592 .operands = &.{
15723 .{ .kind = .IdRef, .quantifier = .required },17593 .{ .kind = .id_ref, .quantifier = .required },
15724 .{ .kind = .IdRef, .quantifier = .required },17594 .{ .kind = .id_ref, .quantifier = .required },
15725 .{ .kind = .IdRef, .quantifier = .required },
15726 .{ .kind = .IdRef, .quantifier = .required },
15727 .{ .kind = .IdRef, .quantifier = .optional },
15728 },17595 },
15729 },17596 },
15730 .{17597 .{
15731 .name = "ArgumentStorageImage",17598 .name = "u_rhadd",
15732 .opcode = 9,17599 .opcode = 148,
15733 .operands = &[_]Operand{17600 .operands = &.{
15734 .{ .kind = .IdRef, .quantifier = .required },17601 .{ .kind = .id_ref, .quantifier = .required },
15735 .{ .kind = .IdRef, .quantifier = .required },17602 .{ .kind = .id_ref, .quantifier = .required },
15736 .{ .kind = .IdRef, .quantifier = .required },
15737 .{ .kind = .IdRef, .quantifier = .required },
15738 .{ .kind = .IdRef, .quantifier = .optional },
15739 },17603 },
15740 },17604 },
15741 .{17605 .{
15742 .name = "ArgumentSampler",17606 .name = "s_clamp",
15743 .opcode = 10,17607 .opcode = 149,
15744 .operands = &[_]Operand{17608 .operands = &.{
15745 .{ .kind = .IdRef, .quantifier = .required },17609 .{ .kind = .id_ref, .quantifier = .required },
15746 .{ .kind = .IdRef, .quantifier = .required },17610 .{ .kind = .id_ref, .quantifier = .required },
15747 .{ .kind = .IdRef, .quantifier = .required },17611 .{ .kind = .id_ref, .quantifier = .required },
15748 .{ .kind = .IdRef, .quantifier = .required },
15749 .{ .kind = .IdRef, .quantifier = .optional },
15750 },17612 },
15751 },17613 },
15752 .{17614 .{
15753 .name = "ArgumentWorkgroup",17615 .name = "u_clamp",
15754 .opcode = 11,17616 .opcode = 150,
15755 .operands = &[_]Operand{17617 .operands = &.{
15756 .{ .kind = .IdRef, .quantifier = .required },17618 .{ .kind = .id_ref, .quantifier = .required },
15757 .{ .kind = .IdRef, .quantifier = .required },17619 .{ .kind = .id_ref, .quantifier = .required },
15758 .{ .kind = .IdRef, .quantifier = .required },17620 .{ .kind = .id_ref, .quantifier = .required },
15759 .{ .kind = .IdRef, .quantifier = .required },
15760 .{ .kind = .IdRef, .quantifier = .optional },
15761 },17621 },
15762 },17622 },
15763 .{17623 .{
15764 .name = "SpecConstantWorkgroupSize",17624 .name = "clz",
15765 .opcode = 12,17625 .opcode = 151,
15766 .operands = &[_]Operand{17626 .operands = &.{
15767 .{ .kind = .IdRef, .quantifier = .required },17627 .{ .kind = .id_ref, .quantifier = .required },
15768 .{ .kind = .IdRef, .quantifier = .required },
15769 .{ .kind = .IdRef, .quantifier = .required },
15770 },17628 },
15771 },17629 },
15772 .{17630 .{
15773 .name = "SpecConstantGlobalOffset",17631 .name = "ctz",
15774 .opcode = 13,17632 .opcode = 152,
15775 .operands = &[_]Operand{17633 .operands = &.{
15776 .{ .kind = .IdRef, .quantifier = .required },17634 .{ .kind = .id_ref, .quantifier = .required },
15777 .{ .kind = .IdRef, .quantifier = .required },
15778 .{ .kind = .IdRef, .quantifier = .required },
15779 },17635 },
15780 },17636 },
15781 .{17637 .{
15782 .name = "SpecConstantWorkDim",17638 .name = "s_mad_hi",
15783 .opcode = 14,17639 .opcode = 153,
15784 .operands = &[_]Operand{17640 .operands = &.{
15785 .{ .kind = .IdRef, .quantifier = .required },17641 .{ .kind = .id_ref, .quantifier = .required },
17642 .{ .kind = .id_ref, .quantifier = .required },
17643 .{ .kind = .id_ref, .quantifier = .required },
15786 },17644 },
15787 },17645 },
15788 .{17646 .{
15789 .name = "PushConstantGlobalOffset",17647 .name = "u_mad_sat",
15790 .opcode = 15,17648 .opcode = 154,
15791 .operands = &[_]Operand{17649 .operands = &.{
15792 .{ .kind = .IdRef, .quantifier = .required },17650 .{ .kind = .id_ref, .quantifier = .required },
15793 .{ .kind = .IdRef, .quantifier = .required },17651 .{ .kind = .id_ref, .quantifier = .required },
17652 .{ .kind = .id_ref, .quantifier = .required },
15794 },17653 },
15795 },17654 },
15796 .{17655 .{
15797 .name = "PushConstantEnqueuedLocalSize",17656 .name = "s_mad_sat",
15798 .opcode = 16,17657 .opcode = 155,
15799 .operands = &[_]Operand{17658 .operands = &.{
15800 .{ .kind = .IdRef, .quantifier = .required },17659 .{ .kind = .id_ref, .quantifier = .required },
15801 .{ .kind = .IdRef, .quantifier = .required },17660 .{ .kind = .id_ref, .quantifier = .required },
17661 .{ .kind = .id_ref, .quantifier = .required },
15802 },17662 },
15803 },17663 },
15804 .{17664 .{
15805 .name = "PushConstantGlobalSize",17665 .name = "s_max",
15806 .opcode = 17,17666 .opcode = 156,
15807 .operands = &[_]Operand{17667 .operands = &.{
15808 .{ .kind = .IdRef, .quantifier = .required },17668 .{ .kind = .id_ref, .quantifier = .required },
15809 .{ .kind = .IdRef, .quantifier = .required },17669 .{ .kind = .id_ref, .quantifier = .required },
15810 },17670 },
15811 },17671 },
15812 .{17672 .{
15813 .name = "PushConstantRegionOffset",17673 .name = "u_max",
15814 .opcode = 18,17674 .opcode = 157,
15815 .operands = &[_]Operand{17675 .operands = &.{
15816 .{ .kind = .IdRef, .quantifier = .required },17676 .{ .kind = .id_ref, .quantifier = .required },
15817 .{ .kind = .IdRef, .quantifier = .required },17677 .{ .kind = .id_ref, .quantifier = .required },
15818 },17678 },
15819 },17679 },
15820 .{17680 .{
15821 .name = "PushConstantNumWorkgroups",17681 .name = "s_min",
15822 .opcode = 19,17682 .opcode = 158,
15823 .operands = &[_]Operand{17683 .operands = &.{
15824 .{ .kind = .IdRef, .quantifier = .required },17684 .{ .kind = .id_ref, .quantifier = .required },
15825 .{ .kind = .IdRef, .quantifier = .required },17685 .{ .kind = .id_ref, .quantifier = .required },
15826 },17686 },
15827 },17687 },
15828 .{17688 .{
15829 .name = "PushConstantRegionGroupOffset",17689 .name = "u_min",
15830 .opcode = 20,17690 .opcode = 159,
15831 .operands = &[_]Operand{17691 .operands = &.{
15832 .{ .kind = .IdRef, .quantifier = .required },17692 .{ .kind = .id_ref, .quantifier = .required },
15833 .{ .kind = .IdRef, .quantifier = .required },17693 .{ .kind = .id_ref, .quantifier = .required },
15834 },17694 },
15835 },17695 },
15836 .{17696 .{
15837 .name = "ConstantDataStorageBuffer",17697 .name = "s_mul_hi",
15838 .opcode = 21,17698 .opcode = 160,
15839 .operands = &[_]Operand{17699 .operands = &.{
15840 .{ .kind = .IdRef, .quantifier = .required },17700 .{ .kind = .id_ref, .quantifier = .required },
15841 .{ .kind = .IdRef, .quantifier = .required },17701 .{ .kind = .id_ref, .quantifier = .required },
15842 .{ .kind = .IdRef, .quantifier = .required },
15843 },17702 },
15844 },17703 },
15845 .{17704 .{
15846 .name = "ConstantDataUniform",17705 .name = "rotate",
15847 .opcode = 22,17706 .opcode = 161,
15848 .operands = &[_]Operand{17707 .operands = &.{
15849 .{ .kind = .IdRef, .quantifier = .required },17708 .{ .kind = .id_ref, .quantifier = .required },
15850 .{ .kind = .IdRef, .quantifier = .required },17709 .{ .kind = .id_ref, .quantifier = .required },
15851 .{ .kind = .IdRef, .quantifier = .required },
15852 },17710 },
15853 },17711 },
15854 .{17712 .{
15855 .name = "LiteralSampler",17713 .name = "s_sub_sat",
15856 .opcode = 23,17714 .opcode = 162,
15857 .operands = &[_]Operand{17715 .operands = &.{
15858 .{ .kind = .IdRef, .quantifier = .required },17716 .{ .kind = .id_ref, .quantifier = .required },
15859 .{ .kind = .IdRef, .quantifier = .required },17717 .{ .kind = .id_ref, .quantifier = .required },
15860 .{ .kind = .IdRef, .quantifier = .required },
15861 },17718 },
15862 },17719 },
15863 .{17720 .{
15864 .name = "PropertyRequiredWorkgroupSize",17721 .name = "u_sub_sat",
15865 .opcode = 24,17722 .opcode = 163,
15866 .operands = &[_]Operand{17723 .operands = &.{
15867 .{ .kind = .IdRef, .quantifier = .required },17724 .{ .kind = .id_ref, .quantifier = .required },
15868 .{ .kind = .IdRef, .quantifier = .required },17725 .{ .kind = .id_ref, .quantifier = .required },
15869 .{ .kind = .IdRef, .quantifier = .required },
15870 .{ .kind = .IdRef, .quantifier = .required },
15871 },17726 },
15872 },17727 },
15873 .{17728 .{
15874 .name = "SpecConstantSubgroupMaxSize",17729 .name = "u_upsample",
15875 .opcode = 25,17730 .opcode = 164,
15876 .operands = &[_]Operand{17731 .operands = &.{
15877 .{ .kind = .IdRef, .quantifier = .required },17732 .{ .kind = .id_ref, .quantifier = .required },
17733 .{ .kind = .id_ref, .quantifier = .required },
15878 },17734 },
15879 },17735 },
15880 .{17736 .{
15881 .name = "ArgumentPointerPushConstant",17737 .name = "s_upsample",
15882 .opcode = 26,17738 .opcode = 165,
15883 .operands = &[_]Operand{17739 .operands = &.{
15884 .{ .kind = .IdRef, .quantifier = .required },17740 .{ .kind = .id_ref, .quantifier = .required },
15885 .{ .kind = .IdRef, .quantifier = .required },17741 .{ .kind = .id_ref, .quantifier = .required },
15886 .{ .kind = .IdRef, .quantifier = .required },
15887 .{ .kind = .IdRef, .quantifier = .required },
15888 .{ .kind = .IdRef, .quantifier = .optional },
15889 },17742 },
15890 },17743 },
15891 .{17744 .{
15892 .name = "ArgumentPointerUniform",17745 .name = "popcount",
15893 .opcode = 27,17746 .opcode = 166,
15894 .operands = &[_]Operand{17747 .operands = &.{
15895 .{ .kind = .IdRef, .quantifier = .required },17748 .{ .kind = .id_ref, .quantifier = .required },
15896 .{ .kind = .IdRef, .quantifier = .required },
15897 .{ .kind = .IdRef, .quantifier = .required },
15898 .{ .kind = .IdRef, .quantifier = .required },
15899 .{ .kind = .IdRef, .quantifier = .required },
15900 .{ .kind = .IdRef, .quantifier = .required },
15901 .{ .kind = .IdRef, .quantifier = .optional },
15902 },17749 },
15903 },17750 },
15904 .{17751 .{
15905 .name = "ProgramScopeVariablesStorageBuffer",17752 .name = "s_mad24",
15906 .opcode = 28,17753 .opcode = 167,
15907 .operands = &[_]Operand{17754 .operands = &.{
15908 .{ .kind = .IdRef, .quantifier = .required },17755 .{ .kind = .id_ref, .quantifier = .required },
15909 .{ .kind = .IdRef, .quantifier = .required },17756 .{ .kind = .id_ref, .quantifier = .required },
15910 .{ .kind = .IdRef, .quantifier = .required },17757 .{ .kind = .id_ref, .quantifier = .required },
15911 },17758 },
15912 },17759 },
15913 .{17760 .{
15914 .name = "ProgramScopeVariablePointerRelocation",17761 .name = "u_mad24",
15915 .opcode = 29,17762 .opcode = 168,
15916 .operands = &[_]Operand{17763 .operands = &.{
15917 .{ .kind = .IdRef, .quantifier = .required },17764 .{ .kind = .id_ref, .quantifier = .required },
15918 .{ .kind = .IdRef, .quantifier = .required },17765 .{ .kind = .id_ref, .quantifier = .required },
15919 .{ .kind = .IdRef, .quantifier = .required },17766 .{ .kind = .id_ref, .quantifier = .required },
15920 },17767 },
15921 },17768 },
15922 .{17769 .{
15923 .name = "ImageArgumentInfoChannelOrderPushConstant",17770 .name = "s_mul24",
15924 .opcode = 30,17771 .opcode = 169,
15925 .operands = &[_]Operand{17772 .operands = &.{
15926 .{ .kind = .IdRef, .quantifier = .required },17773 .{ .kind = .id_ref, .quantifier = .required },
15927 .{ .kind = .IdRef, .quantifier = .required },17774 .{ .kind = .id_ref, .quantifier = .required },
15928 .{ .kind = .IdRef, .quantifier = .required },
15929 .{ .kind = .IdRef, .quantifier = .required },
15930 },17775 },
15931 },17776 },
15932 .{17777 .{
15933 .name = "ImageArgumentInfoChannelDataTypePushConstant",17778 .name = "u_mul24",
15934 .opcode = 31,17779 .opcode = 170,
15935 .operands = &[_]Operand{17780 .operands = &.{
15936 .{ .kind = .IdRef, .quantifier = .required },17781 .{ .kind = .id_ref, .quantifier = .required },
15937 .{ .kind = .IdRef, .quantifier = .required },17782 .{ .kind = .id_ref, .quantifier = .required },
15938 .{ .kind = .IdRef, .quantifier = .required },
15939 .{ .kind = .IdRef, .quantifier = .required },
15940 },17783 },
15941 },17784 },
15942 .{17785 .{
15943 .name = "ImageArgumentInfoChannelOrderUniform",17786 .name = "vloadn",
15944 .opcode = 32,17787 .opcode = 171,
15945 .operands = &[_]Operand{17788 .operands = &.{
15946 .{ .kind = .IdRef, .quantifier = .required },17789 .{ .kind = .id_ref, .quantifier = .required },
15947 .{ .kind = .IdRef, .quantifier = .required },17790 .{ .kind = .id_ref, .quantifier = .required },
15948 .{ .kind = .IdRef, .quantifier = .required },17791 .{ .kind = .literal_integer, .quantifier = .required },
15949 .{ .kind = .IdRef, .quantifier = .required },
15950 .{ .kind = .IdRef, .quantifier = .required },
15951 .{ .kind = .IdRef, .quantifier = .required },
15952 },17792 },
15953 },17793 },
15954 .{17794 .{
15955 .name = "ImageArgumentInfoChannelDataTypeUniform",17795 .name = "vstoren",
15956 .opcode = 33,17796 .opcode = 172,
15957 .operands = &[_]Operand{17797 .operands = &.{
15958 .{ .kind = .IdRef, .quantifier = .required },17798 .{ .kind = .id_ref, .quantifier = .required },
15959 .{ .kind = .IdRef, .quantifier = .required },17799 .{ .kind = .id_ref, .quantifier = .required },
15960 .{ .kind = .IdRef, .quantifier = .required },17800 .{ .kind = .id_ref, .quantifier = .required },
15961 .{ .kind = .IdRef, .quantifier = .required },
15962 .{ .kind = .IdRef, .quantifier = .required },
15963 .{ .kind = .IdRef, .quantifier = .required },
15964 },17801 },
15965 },17802 },
15966 .{17803 .{
15967 .name = "ArgumentStorageTexelBuffer",17804 .name = "vload_half",
15968 .opcode = 34,17805 .opcode = 173,
15969 .operands = &[_]Operand{17806 .operands = &.{
15970 .{ .kind = .IdRef, .quantifier = .required },17807 .{ .kind = .id_ref, .quantifier = .required },
15971 .{ .kind = .IdRef, .quantifier = .required },17808 .{ .kind = .id_ref, .quantifier = .required },
15972 .{ .kind = .IdRef, .quantifier = .required },
15973 .{ .kind = .IdRef, .quantifier = .required },
15974 .{ .kind = .IdRef, .quantifier = .optional },
15975 },17809 },
15976 },17810 },
15977 .{17811 .{
15978 .name = "ArgumentUniformTexelBuffer",17812 .name = "vload_halfn",
15979 .opcode = 35,17813 .opcode = 174,
15980 .operands = &[_]Operand{17814 .operands = &.{
15981 .{ .kind = .IdRef, .quantifier = .required },17815 .{ .kind = .id_ref, .quantifier = .required },
15982 .{ .kind = .IdRef, .quantifier = .required },17816 .{ .kind = .id_ref, .quantifier = .required },
15983 .{ .kind = .IdRef, .quantifier = .required },17817 .{ .kind = .literal_integer, .quantifier = .required },
15984 .{ .kind = .IdRef, .quantifier = .required },
15985 .{ .kind = .IdRef, .quantifier = .optional },
15986 },17818 },
15987 },17819 },
15988 .{17820 .{
15989 .name = "ConstantDataPointerPushConstant",17821 .name = "vstore_half",
15990 .opcode = 36,17822 .opcode = 175,
15991 .operands = &[_]Operand{17823 .operands = &.{
15992 .{ .kind = .IdRef, .quantifier = .required },17824 .{ .kind = .id_ref, .quantifier = .required },
15993 .{ .kind = .IdRef, .quantifier = .required },17825 .{ .kind = .id_ref, .quantifier = .required },
15994 .{ .kind = .IdRef, .quantifier = .required },17826 .{ .kind = .id_ref, .quantifier = .required },
15995 },17827 },
15996 },17828 },
15997 .{17829 .{
15998 .name = "ProgramScopeVariablePointerPushConstant",17830 .name = "vstore_half_r",
15999 .opcode = 37,17831 .opcode = 176,
16000 .operands = &[_]Operand{17832 .operands = &.{
16001 .{ .kind = .IdRef, .quantifier = .required },17833 .{ .kind = .id_ref, .quantifier = .required },
16002 .{ .kind = .IdRef, .quantifier = .required },17834 .{ .kind = .id_ref, .quantifier = .required },
16003 .{ .kind = .IdRef, .quantifier = .required },17835 .{ .kind = .id_ref, .quantifier = .required },
17836 .{ .kind = .fp_rounding_mode, .quantifier = .required },
16004 },17837 },
16005 },17838 },
16006 .{17839 .{
16007 .name = "PrintfInfo",17840 .name = "vstore_halfn",
16008 .opcode = 38,17841 .opcode = 177,
16009 .operands = &[_]Operand{17842 .operands = &.{
16010 .{ .kind = .IdRef, .quantifier = .required },17843 .{ .kind = .id_ref, .quantifier = .required },
16011 .{ .kind = .IdRef, .quantifier = .required },17844 .{ .kind = .id_ref, .quantifier = .required },
16012 .{ .kind = .IdRef, .quantifier = .variadic },17845 .{ .kind = .id_ref, .quantifier = .required },
16013 },17846 },
16014 },17847 },
16015 .{17848 .{
16016 .name = "PrintfBufferStorageBuffer",17849 .name = "vstore_halfn_r",
16017 .opcode = 39,17850 .opcode = 178,
16018 .operands = &[_]Operand{17851 .operands = &.{
16019 .{ .kind = .IdRef, .quantifier = .required },17852 .{ .kind = .id_ref, .quantifier = .required },
16020 .{ .kind = .IdRef, .quantifier = .required },17853 .{ .kind = .id_ref, .quantifier = .required },
16021 .{ .kind = .IdRef, .quantifier = .required },17854 .{ .kind = .id_ref, .quantifier = .required },
17855 .{ .kind = .fp_rounding_mode, .quantifier = .required },
16022 },17856 },
16023 },17857 },
16024 .{17858 .{
16025 .name = "PrintfBufferPointerPushConstant",17859 .name = "vloada_halfn",
16026 .opcode = 40,17860 .opcode = 179,
16027 .operands = &[_]Operand{17861 .operands = &.{
16028 .{ .kind = .IdRef, .quantifier = .required },17862 .{ .kind = .id_ref, .quantifier = .required },
16029 .{ .kind = .IdRef, .quantifier = .required },17863 .{ .kind = .id_ref, .quantifier = .required },
16030 .{ .kind = .IdRef, .quantifier = .required },17864 .{ .kind = .literal_integer, .quantifier = .required },
16031 },17865 },
16032 },17866 },
16033 .{17867 .{
16034 .name = "NormalizedSamplerMaskPushConstant",17868 .name = "vstorea_halfn",
16035 .opcode = 41,17869 .opcode = 180,
16036 .operands = &[_]Operand{17870 .operands = &.{
16037 .{ .kind = .IdRef, .quantifier = .required },17871 .{ .kind = .id_ref, .quantifier = .required },
16038 .{ .kind = .IdRef, .quantifier = .required },17872 .{ .kind = .id_ref, .quantifier = .required },
16039 .{ .kind = .IdRef, .quantifier = .required },17873 .{ .kind = .id_ref, .quantifier = .required },
16040 .{ .kind = .IdRef, .quantifier = .required },
16041 },17874 },
16042 },17875 },
16043 },
16044 .SPV_AMD_gcn_shader => &[_]Instruction{
16045 .{17876 .{
16046 .name = "CubeFaceIndexAMD",17877 .name = "vstorea_halfn_r",
16047 .opcode = 1,17878 .opcode = 181,
16048 .operands = &[_]Operand{17879 .operands = &.{
16049 .{ .kind = .IdRef, .quantifier = .required },17880 .{ .kind = .id_ref, .quantifier = .required },
17881 .{ .kind = .id_ref, .quantifier = .required },
17882 .{ .kind = .id_ref, .quantifier = .required },
17883 .{ .kind = .fp_rounding_mode, .quantifier = .required },
16050 },17884 },
16051 },17885 },
16052 .{17886 .{
16053 .name = "CubeFaceCoordAMD",17887 .name = "shuffle",
16054 .opcode = 2,17888 .opcode = 182,
16055 .operands = &[_]Operand{17889 .operands = &.{
16056 .{ .kind = .IdRef, .quantifier = .required },17890 .{ .kind = .id_ref, .quantifier = .required },
17891 .{ .kind = .id_ref, .quantifier = .required },
16057 },17892 },
16058 },17893 },
16059 .{17894 .{
16060 .name = "TimeAMD",17895 .name = "shuffle2",
16061 .opcode = 3,17896 .opcode = 183,
16062 .operands = &[_]Operand{},17897 .operands = &.{
16063 },17898 .{ .kind = .id_ref, .quantifier = .required },
16064 },17899 .{ .kind = .id_ref, .quantifier = .required },
16065 .SPV_AMD_shader_trinary_minmax => &[_]Instruction{17900 .{ .kind = .id_ref, .quantifier = .required },
16066 .{
16067 .name = "FMin3AMD",
16068 .opcode = 1,
16069 .operands = &[_]Operand{
16070 .{ .kind = .IdRef, .quantifier = .required },
16071 .{ .kind = .IdRef, .quantifier = .required },
16072 .{ .kind = .IdRef, .quantifier = .required },
16073 },17901 },
16074 },17902 },
16075 .{17903 .{
16076 .name = "UMin3AMD",17904 .name = "printf",
16077 .opcode = 2,17905 .opcode = 184,
16078 .operands = &[_]Operand{17906 .operands = &.{
16079 .{ .kind = .IdRef, .quantifier = .required },17907 .{ .kind = .id_ref, .quantifier = .required },
16080 .{ .kind = .IdRef, .quantifier = .required },17908 .{ .kind = .id_ref, .quantifier = .variadic },
16081 .{ .kind = .IdRef, .quantifier = .required },
16082 },17909 },
16083 },17910 },
16084 .{17911 .{
16085 .name = "SMin3AMD",17912 .name = "prefetch",
16086 .opcode = 3,17913 .opcode = 185,
16087 .operands = &[_]Operand{17914 .operands = &.{
16088 .{ .kind = .IdRef, .quantifier = .required },17915 .{ .kind = .id_ref, .quantifier = .required },
16089 .{ .kind = .IdRef, .quantifier = .required },17916 .{ .kind = .id_ref, .quantifier = .required },
16090 .{ .kind = .IdRef, .quantifier = .required },
16091 },17917 },
16092 },17918 },
16093 .{17919 .{
16094 .name = "FMax3AMD",17920 .name = "bitselect",
16095 .opcode = 4,17921 .opcode = 186,
16096 .operands = &[_]Operand{17922 .operands = &.{
16097 .{ .kind = .IdRef, .quantifier = .required },17923 .{ .kind = .id_ref, .quantifier = .required },
16098 .{ .kind = .IdRef, .quantifier = .required },17924 .{ .kind = .id_ref, .quantifier = .required },
16099 .{ .kind = .IdRef, .quantifier = .required },17925 .{ .kind = .id_ref, .quantifier = .required },
16100 },17926 },
16101 },17927 },
16102 .{17928 .{
16103 .name = "UMax3AMD",17929 .name = "select",
16104 .opcode = 5,17930 .opcode = 187,
16105 .operands = &[_]Operand{17931 .operands = &.{
16106 .{ .kind = .IdRef, .quantifier = .required },17932 .{ .kind = .id_ref, .quantifier = .required },
16107 .{ .kind = .IdRef, .quantifier = .required },17933 .{ .kind = .id_ref, .quantifier = .required },
16108 .{ .kind = .IdRef, .quantifier = .required },17934 .{ .kind = .id_ref, .quantifier = .required },
16109 },17935 },
16110 },17936 },
16111 .{17937 .{
16112 .name = "SMax3AMD",17938 .name = "u_abs",
16113 .opcode = 6,17939 .opcode = 201,
16114 .operands = &[_]Operand{17940 .operands = &.{
16115 .{ .kind = .IdRef, .quantifier = .required },17941 .{ .kind = .id_ref, .quantifier = .required },
16116 .{ .kind = .IdRef, .quantifier = .required },
16117 .{ .kind = .IdRef, .quantifier = .required },
16118 },17942 },
16119 },17943 },
16120 .{17944 .{
16121 .name = "FMid3AMD",17945 .name = "u_abs_diff",
16122 .opcode = 7,17946 .opcode = 202,
16123 .operands = &[_]Operand{17947 .operands = &.{
16124 .{ .kind = .IdRef, .quantifier = .required },17948 .{ .kind = .id_ref, .quantifier = .required },
16125 .{ .kind = .IdRef, .quantifier = .required },17949 .{ .kind = .id_ref, .quantifier = .required },
16126 .{ .kind = .IdRef, .quantifier = .required },
16127 },17950 },
16128 },17951 },
16129 .{17952 .{
16130 .name = "UMid3AMD",17953 .name = "u_mul_hi",
16131 .opcode = 8,17954 .opcode = 203,
16132 .operands = &[_]Operand{17955 .operands = &.{
16133 .{ .kind = .IdRef, .quantifier = .required },17956 .{ .kind = .id_ref, .quantifier = .required },
16134 .{ .kind = .IdRef, .quantifier = .required },17957 .{ .kind = .id_ref, .quantifier = .required },
16135 .{ .kind = .IdRef, .quantifier = .required },
16136 },17958 },
16137 },17959 },
16138 .{17960 .{
16139 .name = "SMid3AMD",17961 .name = "u_mad_hi",
16140 .opcode = 9,17962 .opcode = 204,
16141 .operands = &[_]Operand{17963 .operands = &.{
16142 .{ .kind = .IdRef, .quantifier = .required },17964 .{ .kind = .id_ref, .quantifier = .required },
16143 .{ .kind = .IdRef, .quantifier = .required },17965 .{ .kind = .id_ref, .quantifier = .required },
16144 .{ .kind = .IdRef, .quantifier = .required },17966 .{ .kind = .id_ref, .quantifier = .required },
16145 },17967 },
16146 },17968 },
16147 },17969 },
16148 .DebugInfo => &[_]Instruction{17970 .non_semantic_shader_debug_info_100 => &.{
16149 .{17971 .{
16150 .name = "DebugInfoNone",17972 .name = "DebugInfoNone",
16151 .opcode = 0,17973 .opcode = 0,
16152 .operands = &[_]Operand{},17974 .operands = &.{},
16153 },17975 },
16154 .{17976 .{
16155 .name = "DebugCompilationUnit",17977 .name = "DebugCompilationUnit",
16156 .opcode = 1,17978 .opcode = 1,
16157 .operands = &[_]Operand{17979 .operands = &.{
16158 .{ .kind = .IdRef, .quantifier = .required },17980 .{ .kind = .id_ref, .quantifier = .required },
16159 .{ .kind = .LiteralInteger, .quantifier = .required },17981 .{ .kind = .id_ref, .quantifier = .required },
16160 .{ .kind = .LiteralInteger, .quantifier = .required },17982 .{ .kind = .id_ref, .quantifier = .required },
17983 .{ .kind = .id_ref, .quantifier = .required },
16161 },17984 },
16162 },17985 },
16163 .{17986 .{
16164 .name = "DebugTypeBasic",17987 .name = "DebugTypeBasic",
16165 .opcode = 2,17988 .opcode = 2,
16166 .operands = &[_]Operand{17989 .operands = &.{
16167 .{ .kind = .IdRef, .quantifier = .required },17990 .{ .kind = .id_ref, .quantifier = .required },
16168 .{ .kind = .IdRef, .quantifier = .required },17991 .{ .kind = .id_ref, .quantifier = .required },
16169 .{ .kind = .@"DebugInfo.DebugBaseTypeAttributeEncoding", .quantifier = .required },17992 .{ .kind = .id_ref, .quantifier = .required },
17993 .{ .kind = .id_ref, .quantifier = .required },
16170 },17994 },
16171 },17995 },
16172 .{17996 .{
16173 .name = "DebugTypePointer",17997 .name = "DebugTypePointer",
16174 .opcode = 3,17998 .opcode = 3,
16175 .operands = &[_]Operand{17999 .operands = &.{
16176 .{ .kind = .IdRef, .quantifier = .required },18000 .{ .kind = .id_ref, .quantifier = .required },
16177 .{ .kind = .StorageClass, .quantifier = .required },18001 .{ .kind = .id_ref, .quantifier = .required },
16178 .{ .kind = .@"DebugInfo.DebugInfoFlags", .quantifier = .required },18002 .{ .kind = .id_ref, .quantifier = .required },
16179 },18003 },
16180 },18004 },
16181 .{18005 .{
16182 .name = "DebugTypeQualifier",18006 .name = "DebugTypeQualifier",
16183 .opcode = 4,18007 .opcode = 4,
16184 .operands = &[_]Operand{18008 .operands = &.{
16185 .{ .kind = .IdRef, .quantifier = .required },18009 .{ .kind = .id_ref, .quantifier = .required },
16186 .{ .kind = .@"DebugInfo.DebugTypeQualifier", .quantifier = .required },18010 .{ .kind = .id_ref, .quantifier = .required },
16187 },18011 },
16188 },18012 },
16189 .{18013 .{
16190 .name = "DebugTypeArray",18014 .name = "DebugTypeArray",
16191 .opcode = 5,18015 .opcode = 5,
16192 .operands = &[_]Operand{18016 .operands = &.{
16193 .{ .kind = .IdRef, .quantifier = .required },18017 .{ .kind = .id_ref, .quantifier = .required },
16194 .{ .kind = .IdRef, .quantifier = .variadic },18018 .{ .kind = .id_ref, .quantifier = .variadic },
16195 },18019 },
16196 },18020 },
16197 .{18021 .{
16198 .name = "DebugTypeVector",18022 .name = "DebugTypeVector",
16199 .opcode = 6,18023 .opcode = 6,
16200 .operands = &[_]Operand{18024 .operands = &.{
16201 .{ .kind = .IdRef, .quantifier = .required },18025 .{ .kind = .id_ref, .quantifier = .required },
16202 .{ .kind = .LiteralInteger, .quantifier = .required },18026 .{ .kind = .id_ref, .quantifier = .required },
16203 },18027 },
16204 },18028 },
16205 .{18029 .{
16206 .name = "DebugTypedef",18030 .name = "DebugTypedef",
16207 .opcode = 7,18031 .opcode = 7,
16208 .operands = &[_]Operand{18032 .operands = &.{
16209 .{ .kind = .IdRef, .quantifier = .required },18033 .{ .kind = .id_ref, .quantifier = .required },
16210 .{ .kind = .IdRef, .quantifier = .required },18034 .{ .kind = .id_ref, .quantifier = .required },
16211 .{ .kind = .IdRef, .quantifier = .required },18035 .{ .kind = .id_ref, .quantifier = .required },
16212 .{ .kind = .LiteralInteger, .quantifier = .required },18036 .{ .kind = .id_ref, .quantifier = .required },
16213 .{ .kind = .LiteralInteger, .quantifier = .required },18037 .{ .kind = .id_ref, .quantifier = .required },
16214 .{ .kind = .IdRef, .quantifier = .required },18038 .{ .kind = .id_ref, .quantifier = .required },
16215 },18039 },
16216 },18040 },
16217 .{18041 .{
16218 .name = "DebugTypeFunction",18042 .name = "DebugTypeFunction",
16219 .opcode = 8,18043 .opcode = 8,
16220 .operands = &[_]Operand{18044 .operands = &.{
16221 .{ .kind = .IdRef, .quantifier = .required },18045 .{ .kind = .id_ref, .quantifier = .required },
16222 .{ .kind = .IdRef, .quantifier = .variadic },18046 .{ .kind = .id_ref, .quantifier = .required },
18047 .{ .kind = .id_ref, .quantifier = .variadic },
16223 },18048 },
16224 },18049 },
16225 .{18050 .{
16226 .name = "DebugTypeEnum",18051 .name = "DebugTypeEnum",
16227 .opcode = 9,18052 .opcode = 9,
16228 .operands = &[_]Operand{18053 .operands = &.{
16229 .{ .kind = .IdRef, .quantifier = .required },18054 .{ .kind = .id_ref, .quantifier = .required },
16230 .{ .kind = .IdRef, .quantifier = .required },18055 .{ .kind = .id_ref, .quantifier = .required },
16231 .{ .kind = .IdRef, .quantifier = .required },18056 .{ .kind = .id_ref, .quantifier = .required },
16232 .{ .kind = .LiteralInteger, .quantifier = .required },18057 .{ .kind = .id_ref, .quantifier = .required },
16233 .{ .kind = .LiteralInteger, .quantifier = .required },18058 .{ .kind = .id_ref, .quantifier = .required },
16234 .{ .kind = .IdRef, .quantifier = .required },18059 .{ .kind = .id_ref, .quantifier = .required },
16235 .{ .kind = .IdRef, .quantifier = .required },18060 .{ .kind = .id_ref, .quantifier = .required },
16236 .{ .kind = .@"DebugInfo.DebugInfoFlags", .quantifier = .required },18061 .{ .kind = .id_ref, .quantifier = .required },
16237 .{ .kind = .PairIdRefIdRef, .quantifier = .variadic },18062 .{ .kind = .pair_id_ref_id_ref, .quantifier = .variadic },
16238 },18063 },
16239 },18064 },
16240 .{18065 .{
16241 .name = "DebugTypeComposite",18066 .name = "DebugTypeComposite",
16242 .opcode = 10,18067 .opcode = 10,
16243 .operands = &[_]Operand{18068 .operands = &.{
16244 .{ .kind = .IdRef, .quantifier = .required },18069 .{ .kind = .id_ref, .quantifier = .required },
16245 .{ .kind = .@"DebugInfo.DebugCompositeType", .quantifier = .required },18070 .{ .kind = .id_ref, .quantifier = .required },
16246 .{ .kind = .IdRef, .quantifier = .required },18071 .{ .kind = .id_ref, .quantifier = .required },
16247 .{ .kind = .LiteralInteger, .quantifier = .required },18072 .{ .kind = .id_ref, .quantifier = .required },
16248 .{ .kind = .LiteralInteger, .quantifier = .required },18073 .{ .kind = .id_ref, .quantifier = .required },
16249 .{ .kind = .IdRef, .quantifier = .required },18074 .{ .kind = .id_ref, .quantifier = .required },
16250 .{ .kind = .IdRef, .quantifier = .required },18075 .{ .kind = .id_ref, .quantifier = .required },
16251 .{ .kind = .@"DebugInfo.DebugInfoFlags", .quantifier = .required },18076 .{ .kind = .id_ref, .quantifier = .required },
16252 .{ .kind = .IdRef, .quantifier = .variadic },18077 .{ .kind = .id_ref, .quantifier = .required },
18078 .{ .kind = .id_ref, .quantifier = .variadic },
16253 },18079 },
16254 },18080 },
16255 .{18081 .{
16256 .name = "DebugTypeMember",18082 .name = "DebugTypeMember",
16257 .opcode = 11,18083 .opcode = 11,
16258 .operands = &[_]Operand{18084 .operands = &.{
16259 .{ .kind = .IdRef, .quantifier = .required },18085 .{ .kind = .id_ref, .quantifier = .required },
16260 .{ .kind = .IdRef, .quantifier = .required },18086 .{ .kind = .id_ref, .quantifier = .required },
16261 .{ .kind = .IdRef, .quantifier = .required },18087 .{ .kind = .id_ref, .quantifier = .required },
16262 .{ .kind = .LiteralInteger, .quantifier = .required },18088 .{ .kind = .id_ref, .quantifier = .required },
16263 .{ .kind = .LiteralInteger, .quantifier = .required },18089 .{ .kind = .id_ref, .quantifier = .required },
16264 .{ .kind = .IdRef, .quantifier = .required },18090 .{ .kind = .id_ref, .quantifier = .required },
16265 .{ .kind = .IdRef, .quantifier = .required },18091 .{ .kind = .id_ref, .quantifier = .required },
16266 .{ .kind = .IdRef, .quantifier = .required },18092 .{ .kind = .id_ref, .quantifier = .required },
16267 .{ .kind = .@"DebugInfo.DebugInfoFlags", .quantifier = .required },18093 .{ .kind = .id_ref, .quantifier = .optional },
16268 .{ .kind = .IdRef, .quantifier = .optional },
16269 },18094 },
16270 },18095 },
16271 .{18096 .{
16272 .name = "DebugTypeInheritance",18097 .name = "DebugTypeInheritance",
16273 .opcode = 12,18098 .opcode = 12,
16274 .operands = &[_]Operand{18099 .operands = &.{
16275 .{ .kind = .IdRef, .quantifier = .required },18100 .{ .kind = .id_ref, .quantifier = .required },
16276 .{ .kind = .IdRef, .quantifier = .required },18101 .{ .kind = .id_ref, .quantifier = .required },
16277 .{ .kind = .IdRef, .quantifier = .required },18102 .{ .kind = .id_ref, .quantifier = .required },
16278 .{ .kind = .IdRef, .quantifier = .required },18103 .{ .kind = .id_ref, .quantifier = .required },
16279 .{ .kind = .@"DebugInfo.DebugInfoFlags", .quantifier = .required },
16280 },18104 },
16281 },18105 },
16282 .{18106 .{
16283 .name = "DebugTypePtrToMember",18107 .name = "DebugTypePtrToMember",
16284 .opcode = 13,18108 .opcode = 13,
16285 .operands = &[_]Operand{18109 .operands = &.{
16286 .{ .kind = .IdRef, .quantifier = .required },18110 .{ .kind = .id_ref, .quantifier = .required },
16287 .{ .kind = .IdRef, .quantifier = .required },18111 .{ .kind = .id_ref, .quantifier = .required },
16288 },18112 },
16289 },18113 },
16290 .{18114 .{
16291 .name = "DebugTypeTemplate",18115 .name = "DebugTypeTemplate",
16292 .opcode = 14,18116 .opcode = 14,
16293 .operands = &[_]Operand{18117 .operands = &.{
16294 .{ .kind = .IdRef, .quantifier = .required },18118 .{ .kind = .id_ref, .quantifier = .required },
16295 .{ .kind = .IdRef, .quantifier = .variadic },18119 .{ .kind = .id_ref, .quantifier = .variadic },
16296 },18120 },
16297 },18121 },
16298 .{18122 .{
16299 .name = "DebugTypeTemplateParameter",18123 .name = "DebugTypeTemplateParameter",
16300 .opcode = 15,18124 .opcode = 15,
16301 .operands = &[_]Operand{18125 .operands = &.{
16302 .{ .kind = .IdRef, .quantifier = .required },18126 .{ .kind = .id_ref, .quantifier = .required },
16303 .{ .kind = .IdRef, .quantifier = .required },18127 .{ .kind = .id_ref, .quantifier = .required },
16304 .{ .kind = .IdRef, .quantifier = .required },18128 .{ .kind = .id_ref, .quantifier = .required },
16305 .{ .kind = .IdRef, .quantifier = .required },18129 .{ .kind = .id_ref, .quantifier = .required },
16306 .{ .kind = .LiteralInteger, .quantifier = .required },18130 .{ .kind = .id_ref, .quantifier = .required },
16307 .{ .kind = .LiteralInteger, .quantifier = .required },18131 .{ .kind = .id_ref, .quantifier = .required },
16308 },18132 },
16309 },18133 },
16310 .{18134 .{
16311 .name = "DebugTypeTemplateTemplateParameter",18135 .name = "DebugTypeTemplateTemplateParameter",
16312 .opcode = 16,18136 .opcode = 16,
16313 .operands = &[_]Operand{18137 .operands = &.{
16314 .{ .kind = .IdRef, .quantifier = .required },18138 .{ .kind = .id_ref, .quantifier = .required },
16315 .{ .kind = .IdRef, .quantifier = .required },18139 .{ .kind = .id_ref, .quantifier = .required },
16316 .{ .kind = .IdRef, .quantifier = .required },18140 .{ .kind = .id_ref, .quantifier = .required },
16317 .{ .kind = .LiteralInteger, .quantifier = .required },18141 .{ .kind = .id_ref, .quantifier = .required },
16318 .{ .kind = .LiteralInteger, .quantifier = .required },18142 .{ .kind = .id_ref, .quantifier = .required },
16319 },18143 },
16320 },18144 },
16321 .{18145 .{
16322 .name = "DebugTypeTemplateParameterPack",18146 .name = "DebugTypeTemplateParameterPack",
16323 .opcode = 17,18147 .opcode = 17,
16324 .operands = &[_]Operand{18148 .operands = &.{
16325 .{ .kind = .IdRef, .quantifier = .required },18149 .{ .kind = .id_ref, .quantifier = .required },
16326 .{ .kind = .IdRef, .quantifier = .required },18150 .{ .kind = .id_ref, .quantifier = .required },
16327 .{ .kind = .LiteralInteger, .quantifier = .required },18151 .{ .kind = .id_ref, .quantifier = .required },
16328 .{ .kind = .LiteralInteger, .quantifier = .required },18152 .{ .kind = .id_ref, .quantifier = .required },
16329 .{ .kind = .IdRef, .quantifier = .variadic },18153 .{ .kind = .id_ref, .quantifier = .variadic },
16330 },18154 },
16331 },18155 },
16332 .{18156 .{
16333 .name = "DebugGlobalVariable",18157 .name = "DebugGlobalVariable",
16334 .opcode = 18,18158 .opcode = 18,
16335 .operands = &[_]Operand{18159 .operands = &.{
16336 .{ .kind = .IdRef, .quantifier = .required },18160 .{ .kind = .id_ref, .quantifier = .required },
16337 .{ .kind = .IdRef, .quantifier = .required },18161 .{ .kind = .id_ref, .quantifier = .required },
16338 .{ .kind = .IdRef, .quantifier = .required },18162 .{ .kind = .id_ref, .quantifier = .required },
16339 .{ .kind = .LiteralInteger, .quantifier = .required },18163 .{ .kind = .id_ref, .quantifier = .required },
16340 .{ .kind = .LiteralInteger, .quantifier = .required },18164 .{ .kind = .id_ref, .quantifier = .required },
16341 .{ .kind = .IdRef, .quantifier = .required },18165 .{ .kind = .id_ref, .quantifier = .required },
16342 .{ .kind = .IdRef, .quantifier = .required },18166 .{ .kind = .id_ref, .quantifier = .required },
16343 .{ .kind = .IdRef, .quantifier = .required },18167 .{ .kind = .id_ref, .quantifier = .required },
16344 .{ .kind = .@"DebugInfo.DebugInfoFlags", .quantifier = .required },18168 .{ .kind = .id_ref, .quantifier = .required },
16345 .{ .kind = .IdRef, .quantifier = .optional },18169 .{ .kind = .id_ref, .quantifier = .optional },
16346 },18170 },
16347 },18171 },
16348 .{18172 .{
16349 .name = "DebugFunctionDeclaration",18173 .name = "DebugFunctionDeclaration",
16350 .opcode = 19,18174 .opcode = 19,
16351 .operands = &[_]Operand{18175 .operands = &.{
16352 .{ .kind = .IdRef, .quantifier = .required },18176 .{ .kind = .id_ref, .quantifier = .required },
16353 .{ .kind = .IdRef, .quantifier = .required },18177 .{ .kind = .id_ref, .quantifier = .required },
16354 .{ .kind = .IdRef, .quantifier = .required },18178 .{ .kind = .id_ref, .quantifier = .required },
16355 .{ .kind = .LiteralInteger, .quantifier = .required },18179 .{ .kind = .id_ref, .quantifier = .required },
16356 .{ .kind = .LiteralInteger, .quantifier = .required },18180 .{ .kind = .id_ref, .quantifier = .required },
16357 .{ .kind = .IdRef, .quantifier = .required },18181 .{ .kind = .id_ref, .quantifier = .required },
16358 .{ .kind = .IdRef, .quantifier = .required },18182 .{ .kind = .id_ref, .quantifier = .required },
16359 .{ .kind = .@"DebugInfo.DebugInfoFlags", .quantifier = .required },18183 .{ .kind = .id_ref, .quantifier = .required },
16360 },18184 },
16361 },18185 },
16362 .{18186 .{
16363 .name = "DebugFunction",18187 .name = "DebugFunction",
16364 .opcode = 20,18188 .opcode = 20,
16365 .operands = &[_]Operand{18189 .operands = &.{
16366 .{ .kind = .IdRef, .quantifier = .required },18190 .{ .kind = .id_ref, .quantifier = .required },
16367 .{ .kind = .IdRef, .quantifier = .required },18191 .{ .kind = .id_ref, .quantifier = .required },
16368 .{ .kind = .IdRef, .quantifier = .required },18192 .{ .kind = .id_ref, .quantifier = .required },
16369 .{ .kind = .LiteralInteger, .quantifier = .required },18193 .{ .kind = .id_ref, .quantifier = .required },
16370 .{ .kind = .LiteralInteger, .quantifier = .required },18194 .{ .kind = .id_ref, .quantifier = .required },
16371 .{ .kind = .IdRef, .quantifier = .required },18195 .{ .kind = .id_ref, .quantifier = .required },
16372 .{ .kind = .IdRef, .quantifier = .required },18196 .{ .kind = .id_ref, .quantifier = .required },
16373 .{ .kind = .@"DebugInfo.DebugInfoFlags", .quantifier = .required },18197 .{ .kind = .id_ref, .quantifier = .required },
16374 .{ .kind = .LiteralInteger, .quantifier = .required },18198 .{ .kind = .id_ref, .quantifier = .required },
16375 .{ .kind = .IdRef, .quantifier = .required },18199 .{ .kind = .id_ref, .quantifier = .optional },
16376 .{ .kind = .IdRef, .quantifier = .optional },
16377 },18200 },
16378 },18201 },
16379 .{18202 .{
16380 .name = "DebugLexicalBlock",18203 .name = "DebugLexicalBlock",
16381 .opcode = 21,18204 .opcode = 21,
16382 .operands = &[_]Operand{18205 .operands = &.{
16383 .{ .kind = .IdRef, .quantifier = .required },18206 .{ .kind = .id_ref, .quantifier = .required },
16384 .{ .kind = .LiteralInteger, .quantifier = .required },18207 .{ .kind = .id_ref, .quantifier = .required },
16385 .{ .kind = .LiteralInteger, .quantifier = .required },18208 .{ .kind = .id_ref, .quantifier = .required },
16386 .{ .kind = .IdRef, .quantifier = .required },18209 .{ .kind = .id_ref, .quantifier = .required },
16387 .{ .kind = .IdRef, .quantifier = .optional },18210 .{ .kind = .id_ref, .quantifier = .optional },
16388 },18211 },
16389 },18212 },
16390 .{18213 .{
16391 .name = "DebugLexicalBlockDiscriminator",18214 .name = "DebugLexicalBlockDiscriminator",
16392 .opcode = 22,18215 .opcode = 22,
16393 .operands = &[_]Operand{18216 .operands = &.{
16394 .{ .kind = .IdRef, .quantifier = .required },18217 .{ .kind = .id_ref, .quantifier = .required },
16395 .{ .kind = .LiteralInteger, .quantifier = .required },18218 .{ .kind = .id_ref, .quantifier = .required },
16396 .{ .kind = .IdRef, .quantifier = .required },18219 .{ .kind = .id_ref, .quantifier = .required },
16397 },18220 },
16398 },18221 },
16399 .{18222 .{
16400 .name = "DebugScope",18223 .name = "DebugScope",
16401 .opcode = 23,18224 .opcode = 23,
16402 .operands = &[_]Operand{18225 .operands = &.{
16403 .{ .kind = .IdRef, .quantifier = .required },18226 .{ .kind = .id_ref, .quantifier = .required },
16404 .{ .kind = .IdRef, .quantifier = .optional },18227 .{ .kind = .id_ref, .quantifier = .optional },
16405 },18228 },
16406 },18229 },
16407 .{18230 .{
16408 .name = "DebugNoScope",18231 .name = "DebugNoScope",
16409 .opcode = 24,18232 .opcode = 24,
16410 .operands = &[_]Operand{},18233 .operands = &.{},
16411 },18234 },
16412 .{18235 .{
16413 .name = "DebugInlinedAt",18236 .name = "DebugInlinedAt",
16414 .opcode = 25,18237 .opcode = 25,
16415 .operands = &[_]Operand{18238 .operands = &.{
16416 .{ .kind = .LiteralInteger, .quantifier = .required },18239 .{ .kind = .id_ref, .quantifier = .required },
16417 .{ .kind = .IdRef, .quantifier = .required },18240 .{ .kind = .id_ref, .quantifier = .required },
16418 .{ .kind = .IdRef, .quantifier = .optional },18241 .{ .kind = .id_ref, .quantifier = .optional },
16419 },18242 },
16420 },18243 },
16421 .{18244 .{
16422 .name = "DebugLocalVariable",18245 .name = "DebugLocalVariable",
16423 .opcode = 26,18246 .opcode = 26,
16424 .operands = &[_]Operand{18247 .operands = &.{
16425 .{ .kind = .IdRef, .quantifier = .required },18248 .{ .kind = .id_ref, .quantifier = .required },
16426 .{ .kind = .IdRef, .quantifier = .required },18249 .{ .kind = .id_ref, .quantifier = .required },
16427 .{ .kind = .IdRef, .quantifier = .required },18250 .{ .kind = .id_ref, .quantifier = .required },
16428 .{ .kind = .LiteralInteger, .quantifier = .required },18251 .{ .kind = .id_ref, .quantifier = .required },
16429 .{ .kind = .LiteralInteger, .quantifier = .required },18252 .{ .kind = .id_ref, .quantifier = .required },
16430 .{ .kind = .IdRef, .quantifier = .required },18253 .{ .kind = .id_ref, .quantifier = .required },
16431 .{ .kind = .LiteralInteger, .quantifier = .optional },18254 .{ .kind = .id_ref, .quantifier = .required },
18255 .{ .kind = .id_ref, .quantifier = .optional },
16432 },18256 },
16433 },18257 },
16434 .{18258 .{
16435 .name = "DebugInlinedVariable",18259 .name = "DebugInlinedVariable",
16436 .opcode = 27,18260 .opcode = 27,
16437 .operands = &[_]Operand{18261 .operands = &.{
16438 .{ .kind = .IdRef, .quantifier = .required },18262 .{ .kind = .id_ref, .quantifier = .required },
16439 .{ .kind = .IdRef, .quantifier = .required },18263 .{ .kind = .id_ref, .quantifier = .required },
16440 },18264 },
16441 },18265 },
16442 .{18266 .{
16443 .name = "DebugDeclare",18267 .name = "DebugDeclare",
16444 .opcode = 28,18268 .opcode = 28,
16445 .operands = &[_]Operand{18269 .operands = &.{
16446 .{ .kind = .IdRef, .quantifier = .required },18270 .{ .kind = .id_ref, .quantifier = .required },
16447 .{ .kind = .IdRef, .quantifier = .required },18271 .{ .kind = .id_ref, .quantifier = .required },
16448 .{ .kind = .IdRef, .quantifier = .required },18272 .{ .kind = .id_ref, .quantifier = .required },
18273 .{ .kind = .id_ref, .quantifier = .variadic },
16449 },18274 },
16450 },18275 },
16451 .{18276 .{
16452 .name = "DebugValue",18277 .name = "DebugValue",
16453 .opcode = 29,18278 .opcode = 29,
16454 .operands = &[_]Operand{18279 .operands = &.{
16455 .{ .kind = .IdRef, .quantifier = .required },18280 .{ .kind = .id_ref, .quantifier = .required },
16456 .{ .kind = .IdRef, .quantifier = .required },18281 .{ .kind = .id_ref, .quantifier = .required },
16457 .{ .kind = .IdRef, .quantifier = .variadic },18282 .{ .kind = .id_ref, .quantifier = .required },
18283 .{ .kind = .id_ref, .quantifier = .variadic },
16458 },18284 },
16459 },18285 },
16460 .{18286 .{
16461 .name = "DebugOperation",18287 .name = "DebugOperation",
16462 .opcode = 30,18288 .opcode = 30,
16463 .operands = &[_]Operand{18289 .operands = &.{
16464 .{ .kind = .@"DebugInfo.DebugOperation", .quantifier = .required },18290 .{ .kind = .id_ref, .quantifier = .required },
16465 .{ .kind = .LiteralInteger, .quantifier = .variadic },18291 .{ .kind = .id_ref, .quantifier = .variadic },
16466 },18292 },
16467 },18293 },
16468 .{18294 .{
16469 .name = "DebugExpression",18295 .name = "DebugExpression",
16470 .opcode = 31,18296 .opcode = 31,
16471 .operands = &[_]Operand{18297 .operands = &.{
16472 .{ .kind = .IdRef, .quantifier = .variadic },18298 .{ .kind = .id_ref, .quantifier = .variadic },
16473 },18299 },
16474 },18300 },
16475 .{18301 .{
16476 .name = "DebugMacroDef",18302 .name = "DebugMacroDef",
16477 .opcode = 32,18303 .opcode = 32,
16478 .operands = &[_]Operand{18304 .operands = &.{
16479 .{ .kind = .IdRef, .quantifier = .required },18305 .{ .kind = .id_ref, .quantifier = .required },
16480 .{ .kind = .LiteralInteger, .quantifier = .required },18306 .{ .kind = .id_ref, .quantifier = .required },
16481 .{ .kind = .IdRef, .quantifier = .required },18307 .{ .kind = .id_ref, .quantifier = .required },
16482 .{ .kind = .IdRef, .quantifier = .optional },18308 .{ .kind = .id_ref, .quantifier = .optional },
16483 },18309 },
16484 },18310 },
16485 .{18311 .{
16486 .name = "DebugMacroUndef",18312 .name = "DebugMacroUndef",
16487 .opcode = 33,18313 .opcode = 33,
16488 .operands = &[_]Operand{18314 .operands = &.{
16489 .{ .kind = .IdRef, .quantifier = .required },18315 .{ .kind = .id_ref, .quantifier = .required },
16490 .{ .kind = .LiteralInteger, .quantifier = .required },18316 .{ .kind = .id_ref, .quantifier = .required },
16491 .{ .kind = .IdRef, .quantifier = .required },18317 .{ .kind = .id_ref, .quantifier = .required },
16492 },18318 },
16493 },18319 },
16494 },
16495 .@"NonSemantic.DebugPrintf" => &[_]Instruction{
16496 .{18320 .{
16497 .name = "DebugPrintf",18321 .name = "DebugImportedEntity",
16498 .opcode = 1,18322 .opcode = 34,
16499 .operands = &[_]Operand{18323 .operands = &.{
16500 .{ .kind = .IdRef, .quantifier = .required },18324 .{ .kind = .id_ref, .quantifier = .required },
16501 .{ .kind = .IdRef, .quantifier = .variadic },18325 .{ .kind = .id_ref, .quantifier = .required },
18326 .{ .kind = .id_ref, .quantifier = .required },
18327 .{ .kind = .id_ref, .quantifier = .required },
18328 .{ .kind = .id_ref, .quantifier = .required },
18329 .{ .kind = .id_ref, .quantifier = .required },
18330 .{ .kind = .id_ref, .quantifier = .required },
16502 },18331 },
16503 },18332 },
16504 },
16505 .SPV_AMD_shader_explicit_vertex_parameter => &[_]Instruction{
16506 .{18333 .{
16507 .name = "InterpolateAtVertexAMD",18334 .name = "DebugSource",
16508 .opcode = 1,18335 .opcode = 35,
16509 .operands = &[_]Operand{18336 .operands = &.{
16510 .{ .kind = .IdRef, .quantifier = .required },18337 .{ .kind = .id_ref, .quantifier = .required },
16511 .{ .kind = .IdRef, .quantifier = .required },18338 .{ .kind = .id_ref, .quantifier = .optional },
16512 },18339 },
16513 },18340 },
16514 },
16515 .@"NonSemantic.DebugBreak" => &[_]Instruction{
16516 .{18341 .{
16517 .name = "DebugBreak",18342 .name = "DebugFunctionDefinition",
16518 .opcode = 1,18343 .opcode = 101,
16519 .operands = &[_]Operand{},18344 .operands = &.{
18345 .{ .kind = .id_ref, .quantifier = .required },
18346 .{ .kind = .id_ref, .quantifier = .required },
18347 },
18348 },
18349 .{
18350 .name = "DebugSourceContinued",
18351 .opcode = 102,
18352 .operands = &.{
18353 .{ .kind = .id_ref, .quantifier = .required },
18354 },
18355 },
18356 .{
18357 .name = "DebugLine",
18358 .opcode = 103,
18359 .operands = &.{
18360 .{ .kind = .id_ref, .quantifier = .required },
18361 .{ .kind = .id_ref, .quantifier = .required },
18362 .{ .kind = .id_ref, .quantifier = .required },
18363 .{ .kind = .id_ref, .quantifier = .required },
18364 .{ .kind = .id_ref, .quantifier = .required },
18365 },
18366 },
18367 .{
18368 .name = "DebugNoLine",
18369 .opcode = 104,
18370 .operands = &.{},
18371 },
18372 .{
18373 .name = "DebugBuildIdentifier",
18374 .opcode = 105,
18375 .operands = &.{
18376 .{ .kind = .id_ref, .quantifier = .required },
18377 .{ .kind = .id_ref, .quantifier = .required },
18378 },
18379 },
18380 .{
18381 .name = "DebugStoragePath",
18382 .opcode = 106,
18383 .operands = &.{
18384 .{ .kind = .id_ref, .quantifier = .required },
18385 },
18386 },
18387 .{
18388 .name = "DebugEntryPoint",
18389 .opcode = 107,
18390 .operands = &.{
18391 .{ .kind = .id_ref, .quantifier = .required },
18392 .{ .kind = .id_ref, .quantifier = .required },
18393 .{ .kind = .id_ref, .quantifier = .required },
18394 .{ .kind = .id_ref, .quantifier = .required },
18395 },
18396 },
18397 .{
18398 .name = "DebugTypeMatrix",
18399 .opcode = 108,
18400 .operands = &.{
18401 .{ .kind = .id_ref, .quantifier = .required },
18402 .{ .kind = .id_ref, .quantifier = .required },
18403 .{ .kind = .id_ref, .quantifier = .required },
18404 },
16520 },18405 },
16521 },18406 },
16522 .zig => &[_]Instruction{18407 .zig => &.{
16523 .{18408 .{
16524 .name = "InvocationGlobal",18409 .name = "InvocationGlobal",
16525 .opcode = 0,18410 .opcode = 0,
16526 .operands = &[_]Operand{18411 .operands = &.{
16527 .{ .kind = .IdRef, .quantifier = .required },18412 .{ .kind = .id_ref, .quantifier = .required },
16528 },18413 },
16529 },18414 },
16530 },18415 },
src/libs/libcxx.zig+11
...@@ -211,6 +211,10 @@ pub fn buildLibCxx(comp: *Compilation, prog_node: std.Progress.Node) BuildError!...@@ -211,6 +211,10 @@ pub fn buildLibCxx(comp: *Compilation, prog_node: std.Progress.Node) BuildError!
211 try cflags.append("-DLIBCXX_BUILDING_LIBCXXABI");211 try cflags.append("-DLIBCXX_BUILDING_LIBCXXABI");
212 try cflags.append("-D_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER");212 try cflags.append("-D_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER");
213213
214 if (target.os.tag == .wasi) {
215 try cflags.append("-fno-exceptions");
216 }
217
214 try cflags.append("-fvisibility=hidden");218 try cflags.append("-fvisibility=hidden");
215 try cflags.append("-fvisibility-inlines-hidden");219 try cflags.append("-fvisibility-inlines-hidden");
216220
...@@ -388,6 +392,9 @@ pub fn buildLibCxxAbi(comp: *Compilation, prog_node: std.Progress.Node) BuildErr...@@ -388,6 +392,9 @@ pub fn buildLibCxxAbi(comp: *Compilation, prog_node: std.Progress.Node) BuildErr
388 for (libcxxabi_files) |cxxabi_src| {392 for (libcxxabi_files) |cxxabi_src| {
389 if (!comp.config.any_non_single_threaded and std.mem.startsWith(u8, cxxabi_src, "src/cxa_thread_atexit.cpp"))393 if (!comp.config.any_non_single_threaded and std.mem.startsWith(u8, cxxabi_src, "src/cxa_thread_atexit.cpp"))
390 continue;394 continue;
395 if (target.os.tag == .wasi and
396 (std.mem.eql(u8, cxxabi_src, "src/cxa_exception.cpp") or std.mem.eql(u8, cxxabi_src, "src/cxa_personality.cpp")))
397 continue;
391398
392 var cflags = std.ArrayList([]const u8).init(arena);399 var cflags = std.ArrayList([]const u8).init(arena);
393400
...@@ -403,6 +410,10 @@ pub fn buildLibCxxAbi(comp: *Compilation, prog_node: std.Progress.Node) BuildErr...@@ -403,6 +410,10 @@ pub fn buildLibCxxAbi(comp: *Compilation, prog_node: std.Progress.Node) BuildErr
403 try cflags.append("-DHAVE___CXA_THREAD_ATEXIT_IMPL");410 try cflags.append("-DHAVE___CXA_THREAD_ATEXIT_IMPL");
404 }411 }
405412
413 if (target.os.tag == .wasi) {
414 try cflags.append("-fno-exceptions");
415 }
416
406 try cflags.append("-fvisibility=hidden");417 try cflags.append("-fvisibility=hidden");
407 try cflags.append("-fvisibility-inlines-hidden");418 try cflags.append("-fvisibility-inlines-hidden");
408419
src/link/Elf/Object.zig+3
...@@ -106,6 +106,9 @@ pub fn parseCommon(...@@ -106,6 +106,9 @@ pub fn parseCommon(
106 const header_buffer = try Elf.preadAllAlloc(gpa, handle, offset, @sizeOf(elf.Elf64_Ehdr));106 const header_buffer = try Elf.preadAllAlloc(gpa, handle, offset, @sizeOf(elf.Elf64_Ehdr));
107 defer gpa.free(header_buffer);107 defer gpa.free(header_buffer);
108 self.header = @as(*align(1) const elf.Elf64_Ehdr, @ptrCast(header_buffer)).*;108 self.header = @as(*align(1) const elf.Elf64_Ehdr, @ptrCast(header_buffer)).*;
109 if (!mem.eql(u8, self.header.?.e_ident[0..4], elf.MAGIC)) {
110 return diags.failParse(path, "not an ELF file", .{});
111 }
109112
110 const em = target.toElfMachine();113 const em = target.toElfMachine();
111 if (em != self.header.?.e_machine) {114 if (em != self.header.?.e_machine) {
src/link/SpirV.zig+5-5
...@@ -42,7 +42,7 @@ const Value = @import("../Value.zig");...@@ -42,7 +42,7 @@ const Value = @import("../Value.zig");
42const SpvModule = @import("../codegen/spirv/Module.zig");42const SpvModule = @import("../codegen/spirv/Module.zig");
43const Section = @import("../codegen/spirv/Section.zig");43const Section = @import("../codegen/spirv/Section.zig");
44const spec = @import("../codegen/spirv/spec.zig");44const spec = @import("../codegen/spirv/spec.zig");
45const IdResult = spec.IdResult;45const Id = spec.Id;
46const Word = spec.Word;46const Word = spec.Word;
4747
48const BinaryModule = @import("SpirV/BinaryModule.zig");48const BinaryModule = @import("SpirV/BinaryModule.zig");
...@@ -144,15 +144,15 @@ pub fn updateExports(...@@ -144,15 +144,15 @@ pub fn updateExports(
144 const cc = Type.fromInterned(nav_ty).fnCallingConvention(zcu);144 const cc = Type.fromInterned(nav_ty).fnCallingConvention(zcu);
145 const exec_model: spec.ExecutionModel = switch (target.os.tag) {145 const exec_model: spec.ExecutionModel = switch (target.os.tag) {
146 .vulkan, .opengl => switch (cc) {146 .vulkan, .opengl => switch (cc) {
147 .spirv_vertex => .Vertex,147 .spirv_vertex => .vertex,
148 .spirv_fragment => .Fragment,148 .spirv_fragment => .fragment,
149 .spirv_kernel => .GLCompute,149 .spirv_kernel => .gl_compute,
150 // TODO: We should integrate with the Linkage capability and export this function150 // TODO: We should integrate with the Linkage capability and export this function
151 .spirv_device => return,151 .spirv_device => return,
152 else => unreachable,152 else => unreachable,
153 },153 },
154 .opencl => switch (cc) {154 .opencl => switch (cc) {
155 .spirv_kernel => .Kernel,155 .spirv_kernel => .kernel,
156 // TODO: We should integrate with the Linkage capability and export this function156 // TODO: We should integrate with the Linkage capability and export this function
157 .spirv_device => return,157 .spirv_device => return,
158 else => unreachable,158 else => unreachable,
src/link/SpirV/BinaryModule.zig+17-17
...@@ -7,7 +7,7 @@ const spec = @import("../../codegen/spirv/spec.zig");...@@ -7,7 +7,7 @@ const spec = @import("../../codegen/spirv/spec.zig");
7const Opcode = spec.Opcode;7const Opcode = spec.Opcode;
8const Word = spec.Word;8const Word = spec.Word;
9const InstructionSet = spec.InstructionSet;9const InstructionSet = spec.InstructionSet;
10const ResultId = spec.IdResult;10const ResultId = spec.Id;
1111
12const BinaryModule = @This();12const BinaryModule = @This();
1313
...@@ -254,8 +254,8 @@ pub const Parser = struct {...@@ -254,8 +254,8 @@ pub const Parser = struct {
254 // with ALL operations that return an int or float.254 // with ALL operations that return an int or float.
255 const spec_operands = inst_spec.operands;255 const spec_operands = inst_spec.operands;
256 if (spec_operands.len >= 2 and256 if (spec_operands.len >= 2 and
257 spec_operands[0].kind == .IdResultType and257 spec_operands[0].kind == .id_result_type and
258 spec_operands[1].kind == .IdResult)258 spec_operands[1].kind == .id_result)
259 {259 {
260 if (operands.len < 2) return error.InvalidOperands;260 if (operands.len < 2) return error.InvalidOperands;
261 if (binary.arith_type_width.get(@enumFromInt(operands[0]))) |width| {261 if (binary.arith_type_width.get(@enumFromInt(operands[0]))) |width| {
...@@ -288,8 +288,8 @@ pub const Parser = struct {...@@ -288,8 +288,8 @@ pub const Parser = struct {
288 var offset: usize = 0;288 var offset: usize = 0;
289 switch (inst.opcode) {289 switch (inst.opcode) {
290 .OpSpecConstantOp => {290 .OpSpecConstantOp => {
291 assert(operands[0].kind == .IdResultType);291 assert(operands[0].kind == .id_result_type);
292 assert(operands[1].kind == .IdResult);292 assert(operands[1].kind == .id_result);
293 offset = try self.parseOperandsResultIds(binary, inst, operands[0..2], offset, offsets);293 offset = try self.parseOperandsResultIds(binary, inst, operands[0..2], offset, offsets);
294294
295 if (offset >= inst.operands.len) return error.InvalidPhysicalFormat;295 if (offset >= inst.operands.len) return error.InvalidPhysicalFormat;
...@@ -297,13 +297,13 @@ pub const Parser = struct {...@@ -297,13 +297,13 @@ pub const Parser = struct {
297 const spec_index = self.opcode_table.get(mapSetAndOpcode(.core, spec_opcode)) orelse297 const spec_index = self.opcode_table.get(mapSetAndOpcode(.core, spec_opcode)) orelse
298 return error.InvalidPhysicalFormat;298 return error.InvalidPhysicalFormat;
299 const spec_operands = InstructionSet.core.instructions()[spec_index].operands;299 const spec_operands = InstructionSet.core.instructions()[spec_index].operands;
300 assert(spec_operands[0].kind == .IdResultType);300 assert(spec_operands[0].kind == .id_result_type);
301 assert(spec_operands[1].kind == .IdResult);301 assert(spec_operands[1].kind == .id_result);
302 offset = try self.parseOperandsResultIds(binary, inst, spec_operands[2..], offset + 1, offsets);302 offset = try self.parseOperandsResultIds(binary, inst, spec_operands[2..], offset + 1, offsets);
303 },303 },
304 .OpExtInst => {304 .OpExtInst => {
305 assert(operands[0].kind == .IdResultType);305 assert(operands[0].kind == .id_result_type);
306 assert(operands[1].kind == .IdResult);306 assert(operands[1].kind == .id_result);
307 offset = try self.parseOperandsResultIds(binary, inst, operands[0..2], offset, offsets);307 offset = try self.parseOperandsResultIds(binary, inst, operands[0..2], offset, offsets);
308308
309 if (offset + 1 >= inst.operands.len) return error.InvalidPhysicalFormat;309 if (offset + 1 >= inst.operands.len) return error.InvalidPhysicalFormat;
...@@ -405,8 +405,8 @@ pub const Parser = struct {...@@ -405,8 +405,8 @@ pub const Parser = struct {
405 offset += 1;405 offset += 1;
406 },406 },
407 else => switch (kind) {407 else => switch (kind) {
408 .LiteralInteger, .LiteralFloat => offset += 1,408 .literal_integer, .literal_float => offset += 1,
409 .LiteralString => while (true) {409 .literal_string => while (true) {
410 if (offset >= inst.operands.len) return error.InvalidPhysicalFormat;410 if (offset >= inst.operands.len) return error.InvalidPhysicalFormat;
411 const word = inst.operands[offset];411 const word = inst.operands[offset];
412 offset += 1;412 offset += 1;
...@@ -419,7 +419,7 @@ pub const Parser = struct {...@@ -419,7 +419,7 @@ pub const Parser = struct {
419 break;419 break;
420 }420 }
421 },421 },
422 .LiteralContextDependentNumber => {422 .literal_context_dependent_number => {
423 assert(inst.opcode == .OpConstant or inst.opcode == .OpSpecConstantOp);423 assert(inst.opcode == .OpConstant or inst.opcode == .OpSpecConstantOp);
424 const bit_width = binary.arith_type_width.get(@enumFromInt(inst.operands[0])) orelse {424 const bit_width = binary.arith_type_width.get(@enumFromInt(inst.operands[0])) orelse {
425 log.err("invalid LiteralContextDependentNumber type {}", .{inst.operands[0]});425 log.err("invalid LiteralContextDependentNumber type {}", .{inst.operands[0]});
...@@ -431,9 +431,9 @@ pub const Parser = struct {...@@ -431,9 +431,9 @@ pub const Parser = struct {
431 else => unreachable,431 else => unreachable,
432 };432 };
433 },433 },
434 .LiteralExtInstInteger => unreachable,434 .literal_ext_inst_integer => unreachable,
435 .LiteralSpecConstantOpInteger => unreachable,435 .literal_spec_constant_op_integer => unreachable,
436 .PairLiteralIntegerIdRef => { // Switch case436 .pair_literal_integer_id_ref => { // Switch case
437 assert(inst.opcode == .OpSwitch);437 assert(inst.opcode == .OpSwitch);
438 const bit_width = binary.arith_type_width.get(@enumFromInt(inst.operands[0])) orelse {438 const bit_width = binary.arith_type_width.get(@enumFromInt(inst.operands[0])) orelse {
439 log.err("invalid OpSwitch type {}", .{inst.operands[0]});439 log.err("invalid OpSwitch type {}", .{inst.operands[0]});
...@@ -447,11 +447,11 @@ pub const Parser = struct {...@@ -447,11 +447,11 @@ pub const Parser = struct {
447 try offsets.append(@intCast(offset));447 try offsets.append(@intCast(offset));
448 offset += 1;448 offset += 1;
449 },449 },
450 .PairIdRefLiteralInteger => {450 .pair_id_ref_literal_integer => {
451 try offsets.append(@intCast(offset));451 try offsets.append(@intCast(offset));
452 offset += 2;452 offset += 2;
453 },453 },
454 .PairIdRefIdRef => {454 .pair_id_ref_id_ref => {
455 try offsets.append(@intCast(offset));455 try offsets.append(@intCast(offset));
456 try offsets.append(@intCast(offset + 1));456 try offsets.append(@intCast(offset + 1));
457 offset += 2;457 offset += 2;
src/link/SpirV/deduplicate.zig+11-11
...@@ -7,7 +7,7 @@ const BinaryModule = @import("BinaryModule.zig");...@@ -7,7 +7,7 @@ const BinaryModule = @import("BinaryModule.zig");
7const Section = @import("../../codegen/spirv/Section.zig");7const Section = @import("../../codegen/spirv/Section.zig");
8const spec = @import("../../codegen/spirv/spec.zig");8const spec = @import("../../codegen/spirv/spec.zig");
9const Opcode = spec.Opcode;9const Opcode = spec.Opcode;
10const ResultId = spec.IdResult;10const ResultId = spec.Id;
11const Word = spec.Word;11const Word = spec.Word;
1212
13fn canDeduplicate(opcode: Opcode) bool {13fn canDeduplicate(opcode: Opcode) bool {
...@@ -20,9 +20,9 @@ fn canDeduplicate(opcode: Opcode) bool {...@@ -20,9 +20,9 @@ fn canDeduplicate(opcode: Opcode) bool {
20 // Debug decoration-style instructions20 // Debug decoration-style instructions
21 .OpName, .OpMemberName => true,21 .OpName, .OpMemberName => true,
22 else => switch (opcode.class()) {22 else => switch (opcode.class()) {
23 .TypeDeclaration,23 .type_declaration,
24 .ConstantCreation,24 .constant_creation,
25 .Annotation,25 .annotation,
26 => true,26 => true,
27 else => false,27 else => false,
28 },28 },
...@@ -86,8 +86,8 @@ const ModuleInfo = struct {...@@ -86,8 +86,8 @@ const ModuleInfo = struct {
86 if (!canDeduplicate(inst.opcode)) continue;86 if (!canDeduplicate(inst.opcode)) continue;
8787
88 const result_id_index: u16 = switch (inst.opcode.class()) {88 const result_id_index: u16 = switch (inst.opcode.class()) {
89 .TypeDeclaration, .Annotation, .Debug => 0,89 .type_declaration, .annotation, .debug => 0,
90 .ConstantCreation => 1,90 .constant_creation => 1,
91 else => unreachable,91 else => unreachable,
92 };92 };
9393
...@@ -101,13 +101,13 @@ const ModuleInfo = struct {...@@ -101,13 +101,13 @@ const ModuleInfo = struct {
101 };101 };
102102
103 switch (inst.opcode.class()) {103 switch (inst.opcode.class()) {
104 .Annotation, .Debug => {104 .annotation, .debug => {
105 try decorations.append(arena, .{105 try decorations.append(arena, .{
106 .target_id = result_id,106 .target_id = result_id,
107 .entity = entity,107 .entity = entity,
108 });108 });
109 },109 },
110 .TypeDeclaration, .ConstantCreation => {110 .type_declaration, .constant_creation => {
111 const entry = try entities.getOrPut(result_id);111 const entry = try entities.getOrPut(result_id);
112 if (entry.found_existing) {112 if (entry.found_existing) {
113 log.err("type or constant {f} has duplicate definition", .{result_id});113 log.err("type or constant {f} has duplicate definition", .{result_id});
...@@ -469,7 +469,7 @@ pub fn run(parser: *BinaryModule.Parser, binary: *BinaryModule, progress: std.Pr...@@ -469,7 +469,7 @@ pub fn run(parser: *BinaryModule.Parser, binary: *BinaryModule, progress: std.Pr
469 const inst_spec = parser.getInstSpec(inst.opcode).?;469 const inst_spec = parser.getInstSpec(inst.opcode).?;
470470
471 const maybe_result_id_offset: ?u16 = for (0..2) |i| {471 const maybe_result_id_offset: ?u16 = for (0..2) |i| {
472 if (inst_spec.operands.len > i and inst_spec.operands[i].kind == .IdResult) {472 if (inst_spec.operands.len > i and inst_spec.operands[i].kind == .id_result) {
473 break @intCast(i);473 break @intCast(i);
474 }474 }
475 } else null;475 } else null;
...@@ -488,7 +488,7 @@ pub fn run(parser: *BinaryModule.Parser, binary: *BinaryModule, progress: std.Pr...@@ -488,7 +488,7 @@ pub fn run(parser: *BinaryModule.Parser, binary: *BinaryModule, progress: std.Pr
488 }488 }
489489
490 switch (inst.opcode.class()) {490 switch (inst.opcode.class()) {
491 .Annotation, .Debug => {491 .annotation, .debug => {
492 // For decoration-style instructions, only emit them492 // For decoration-style instructions, only emit them
493 // if the target is not removed.493 // if the target is not removed.
494 const target: ResultId = @enumFromInt(inst.operands[0]);494 const target: ResultId = @enumFromInt(inst.operands[0]);
...@@ -515,7 +515,7 @@ pub fn run(parser: *BinaryModule.Parser, binary: *BinaryModule, progress: std.Pr...@@ -515,7 +515,7 @@ pub fn run(parser: *BinaryModule.Parser, binary: *BinaryModule, progress: std.Pr
515 // Debug and Annotation instructions don't need the forward pointer, and it515 // Debug and Annotation instructions don't need the forward pointer, and it
516 // messes up the logical layout of the module.516 // messes up the logical layout of the module.
517 switch (inst.opcode.class()) {517 switch (inst.opcode.class()) {
518 .TypeDeclaration, .ConstantCreation, .Memory => {},518 .type_declaration, .constant_creation, .memory => {},
519 else => continue,519 else => continue,
520 }520 }
521521
src/link/SpirV/lower_invocation_globals.zig+2-2
...@@ -6,7 +6,7 @@ const log = std.log.scoped(.spirv_link);...@@ -6,7 +6,7 @@ const log = std.log.scoped(.spirv_link);
6const BinaryModule = @import("BinaryModule.zig");6const BinaryModule = @import("BinaryModule.zig");
7const Section = @import("../../codegen/spirv/Section.zig");7const Section = @import("../../codegen/spirv/Section.zig");
8const spec = @import("../../codegen/spirv/spec.zig");8const spec = @import("../../codegen/spirv/spec.zig");
9const ResultId = spec.IdResult;9const ResultId = spec.Id;
10const Word = spec.Word;10const Word = spec.Word;
1111
12/// This structure contains all the stuff that we need to parse from the module in12/// This structure contains all the stuff that we need to parse from the module in
...@@ -626,7 +626,7 @@ const ModuleBuilder = struct {...@@ -626,7 +626,7 @@ const ModuleBuilder = struct {
626 try self.section.emit(self.arena, .OpVariable, .{626 try self.section.emit(self.arena, .OpVariable, .{
627 .id_result_type = global_info.ty,627 .id_result_type = global_info.ty,
628 .id_result = id,628 .id_result = id,
629 .storage_class = .Function,629 .storage_class = .function,
630 .initializer = null,630 .initializer = null,
631 });631 });
632 }632 }
src/link/SpirV/prune_unused.zig+10-10
...@@ -15,14 +15,14 @@ const BinaryModule = @import("BinaryModule.zig");...@@ -15,14 +15,14 @@ const BinaryModule = @import("BinaryModule.zig");
15const Section = @import("../../codegen/spirv/Section.zig");15const Section = @import("../../codegen/spirv/Section.zig");
16const spec = @import("../../codegen/spirv/spec.zig");16const spec = @import("../../codegen/spirv/spec.zig");
17const Opcode = spec.Opcode;17const Opcode = spec.Opcode;
18const ResultId = spec.IdResult;18const ResultId = spec.Id;
19const Word = spec.Word;19const Word = spec.Word;
2020
21/// Return whether a particular opcode's instruction can be pruned.21/// Return whether a particular opcode's instruction can be pruned.
22/// These are idempotent instructions at globals scope and instructions22/// These are idempotent instructions at globals scope and instructions
23/// within functions that do not have any side effects.23/// within functions that do not have any side effects.
24/// The opcodes that return true here do not necessarily need to24/// The opcodes that return true here do not necessarily need to
25/// have an .IdResult. If they don't, then they are regarded25/// have an .Id. If they don't, then they are regarded
26/// as 'decoration'-style instructions that don't keep their26/// as 'decoration'-style instructions that don't keep their
27/// operands alive, but will be emitted if they are.27/// operands alive, but will be emitted if they are.
28fn canPrune(op: Opcode) bool {28fn canPrune(op: Opcode) bool {
...@@ -34,12 +34,12 @@ fn canPrune(op: Opcode) bool {...@@ -34,12 +34,12 @@ fn canPrune(op: Opcode) bool {
34 // instruction has any non-trivial side effects (like OpLoad34 // instruction has any non-trivial side effects (like OpLoad
35 // with the Volatile memory semantics).35 // with the Volatile memory semantics).
36 return switch (op.class()) {36 return switch (op.class()) {
37 .TypeDeclaration,37 .type_declaration,
38 .Conversion,38 .conversion,
39 .Arithmetic,39 .arithmetic,
40 .RelationalAndLogical,40 .relational_and_logical,
41 .Bit,41 .bit,
42 .Annotation,42 .annotation,
43 => true,43 => true,
44 else => switch (op) {44 else => switch (op) {
45 .OpFunction,45 .OpFunction,
...@@ -111,7 +111,7 @@ const ModuleInfo = struct {...@@ -111,7 +111,7 @@ const ModuleInfo = struct {
111111
112 // Result-id can only be the first or second operand112 // Result-id can only be the first or second operand
113 const maybe_result_id: ?ResultId = for (0..2) |i| {113 const maybe_result_id: ?ResultId = for (0..2) |i| {
114 if (inst_spec.operands.len > i and inst_spec.operands[i].kind == .IdResult) {114 if (inst_spec.operands.len > i and inst_spec.operands[i].kind == .id_result) {
115 break @enumFromInt(inst.operands[i]);115 break @enumFromInt(inst.operands[i]);
116 }116 }
117 } else null;117 } else null;
...@@ -305,7 +305,7 @@ pub fn run(parser: *BinaryModule.Parser, binary: *BinaryModule, progress: std.Pr...@@ -305,7 +305,7 @@ pub fn run(parser: *BinaryModule.Parser, binary: *BinaryModule, progress: std.Pr
305305
306 // Result-id can only be the first or second operand306 // Result-id can only be the first or second operand
307 const result_id: ResultId = for (0..2) |i| {307 const result_id: ResultId = for (0..2) |i| {
308 if (inst_spec.operands.len > i and inst_spec.operands[i].kind == .IdResult) {308 if (inst_spec.operands.len > i and inst_spec.operands[i].kind == .id_result) {
309 break @enumFromInt(inst.operands[i]);309 break @enumFromInt(inst.operands[i]);
310 }310 }
311 } else {311 } else {
src/link/Wasm/Flush.zig+1-1
...@@ -146,7 +146,7 @@ pub fn finish(f: *Flush, wasm: *Wasm) !void {...@@ -146,7 +146,7 @@ pub fn finish(f: *Flush, wasm: *Wasm) !void {
146 const int_tag_ty = Zcu.Type.fromInterned(data.ip_index).intTagType(zcu);146 const int_tag_ty = Zcu.Type.fromInterned(data.ip_index).intTagType(zcu);
147 gop.value_ptr.* = .{ .tag_name = .{147 gop.value_ptr.* = .{ .tag_name = .{
148 .symbol_name = try wasm.internStringFmt("__zig_tag_name_{d}", .{@intFromEnum(data.ip_index)}),148 .symbol_name = try wasm.internStringFmt("__zig_tag_name_{d}", .{@intFromEnum(data.ip_index)}),
149 .type_index = try wasm.internFunctionType(.Unspecified, &.{int_tag_ty.ip_index}, .slice_const_u8_sentinel_0, target),149 .type_index = try wasm.internFunctionType(.auto, &.{int_tag_ty.ip_index}, .slice_const_u8_sentinel_0, target),
150 .table_index = @intCast(wasm.tag_name_offs.items.len),150 .table_index = @intCast(wasm.tag_name_offs.items.len),
151 } };151 } };
152 try wasm.functions.put(gpa, .fromZcuFunc(wasm, @enumFromInt(gop.index)), {});152 try wasm.functions.put(gpa, .fromZcuFunc(wasm, @enumFromInt(gop.index)), {});
src/target.zig+9-3
...@@ -868,10 +868,16 @@ pub inline fn backendSupportsFeature(backend: std.builtin.CompilerBackend, compt...@@ -868,10 +868,16 @@ pub inline fn backendSupportsFeature(backend: std.builtin.CompilerBackend, compt
868 else => false,868 else => false,
869 },869 },
870 .separate_thread => switch (backend) {870 .separate_thread => switch (backend) {
871 // Supports a separate thread but does not support N separate
872 // threads because they would all just be locking the same mutex to
873 // protect Builder.
871 .stage2_llvm => false,874 .stage2_llvm => false,
872 .stage2_c, .stage2_wasm, .stage2_x86_64 => true,875 // Same problem. Frontend needs to allow this backend to run in the
873 // TODO: most self-hosted backends should be able to support this without too much work.876 // linker thread.
874 else => false,877 .stage2_spirv => false,
878 // Please do not make any more exceptions. Backends must support
879 // being run in a separate thread from now on.
880 else => true,
875 },881 },
876 };882 };
877}883}
test/behavior/fn.zig+4-4
...@@ -153,9 +153,9 @@ test "extern struct with stdcallcc fn pointer" {...@@ -153,9 +153,9 @@ test "extern struct with stdcallcc fn pointer" {
153 if (builtin.zig_backend == .stage2_spirv) return error.SkipZigTest;153 if (builtin.zig_backend == .stage2_spirv) return error.SkipZigTest;
154154
155 const S = extern struct {155 const S = extern struct {
156 ptr: *const fn () callconv(if (builtin.target.cpu.arch == .x86) .Stdcall else .c) i32,156 ptr: *const fn () callconv(if (builtin.target.cpu.arch == .x86) .{ .x86_stdcall = .{} } else .c) i32,
157157
158 fn foo() callconv(if (builtin.target.cpu.arch == .x86) .Stdcall else .c) i32 {158 fn foo() callconv(if (builtin.target.cpu.arch == .x86) .{ .x86_stdcall = .{} } else .c) i32 {
159 return 1234;159 return 1234;
160 }160 }
161 };161 };
...@@ -170,8 +170,8 @@ fn fComplexCallconvRet(x: u32) callconv(blk: {...@@ -170,8 +170,8 @@ fn fComplexCallconvRet(x: u32) callconv(blk: {
170 const s: struct { n: u32 } = .{ .n = nComplexCallconv };170 const s: struct { n: u32 } = .{ .n = nComplexCallconv };
171 break :blk switch (s.n) {171 break :blk switch (s.n) {
172 0 => .c,172 0 => .c,
173 1 => .Inline,173 1 => .@"inline",
174 else => .Unspecified,174 else => .auto,
175 };175 };
176}) struct { x: u32 } {176}) struct { x: u32 } {
177 return .{ .x = x * x };177 return .{ .x = x * x };
test/behavior/switch_loop.zig+10
...@@ -216,3 +216,13 @@ test "switch loop with pointer capture" {...@@ -216,3 +216,13 @@ test "switch loop with pointer capture" {
216 try S.doTheTest();216 try S.doTheTest();
217 try comptime S.doTheTest();217 try comptime S.doTheTest();
218}218}
219
220test "unanalyzed continue with operand" {
221 if (builtin.zig_backend == .stage2_aarch64) return error.SkipZigTest; // TODO
222
223 @setRuntimeSafety(false);
224 label: switch (false) {
225 false => if (false) continue :label true,
226 true => {},
227 }
228}
test/behavior/type.zig+1-1
...@@ -670,7 +670,7 @@ test "reified function type params initialized with field pointer" {...@@ -670,7 +670,7 @@ test "reified function type params initialized with field pointer" {
670 };670 };
671 const Bar = @Type(.{671 const Bar = @Type(.{
672 .@"fn" = .{672 .@"fn" = .{
673 .calling_convention = .Unspecified,673 .calling_convention = .auto,
674 .is_generic = false,674 .is_generic = false,
675 .is_var_args = false,675 .is_var_args = false,
676 .return_type = void,676 .return_type = void,
test/c_abi/main.zig+1-1
...@@ -5763,7 +5763,7 @@ test "f128 f128 struct" {...@@ -5763,7 +5763,7 @@ test "f128 f128 struct" {
5763}5763}
57645764
5765// The stdcall attribute on C functions is ignored when compiled on non-x865765// The stdcall attribute on C functions is ignored when compiled on non-x86
5766const stdcall_callconv: std.builtin.CallingConvention = if (builtin.cpu.arch == .x86) .Stdcall else .C;5766const stdcall_callconv: std.builtin.CallingConvention = if (builtin.cpu.arch == .x86) .{ .x86_stdcall = .{} } else .c;
57675767
5768extern fn stdcall_scalars(i8, i16, i32, f32, f64) callconv(stdcall_callconv) void;5768extern fn stdcall_scalars(i8, i16, i32, f32, f64) callconv(stdcall_callconv) void;
5769test "Stdcall ABI scalars" {5769test "Stdcall ABI scalars" {
test/cases/compile_errors/callconv_from_global_variable.zig+1-1
...@@ -1,4 +1,4 @@...@@ -1,4 +1,4 @@
1var cc: @import("std").builtin.CallingConvention = .C;1var cc: @import("std").builtin.CallingConvention = .c;
2export fn foo() callconv(cc) void {}2export fn foo() callconv(cc) void {}
33
4// error4// error
test/cases/compile_errors/implicit_cast_of_error_set_not_a_subset.zig+1-1
...@@ -12,5 +12,5 @@ fn foo(set1: Set1) void {...@@ -12,5 +12,5 @@ fn foo(set1: Set1) void {
12// backend=stage212// backend=stage2
13// target=native13// target=native
14//14//
15// :7:21: error: expected type 'error{C,A}', found 'error{A,B}'15// :7:21: error: expected type 'error{A,C}', found 'error{A,B}'
16// :7:21: note: 'error.B' not a member of destination error set16// :7:21: note: 'error.B' not a member of destination error set
test/cases/compile_errors/reify_type.Fn_with_is_generic_true.zig+1-1
...@@ -1,6 +1,6 @@...@@ -1,6 +1,6 @@
1const Foo = @Type(.{1const Foo = @Type(.{
2 .@"fn" = .{2 .@"fn" = .{
3 .calling_convention = .Unspecified,3 .calling_convention = .auto,
4 .is_generic = true,4 .is_generic = true,
5 .is_var_args = false,5 .is_var_args = false,
6 .return_type = u0,6 .return_type = u0,
test/cases/compile_errors/reify_type.Fn_with_is_var_args_true_and_non-C_callconv.zig+1-1
...@@ -1,6 +1,6 @@...@@ -1,6 +1,6 @@
1const Foo = @Type(.{1const Foo = @Type(.{
2 .@"fn" = .{2 .@"fn" = .{
3 .calling_convention = .Unspecified,3 .calling_convention = .auto,
4 .is_generic = false,4 .is_generic = false,
5 .is_var_args = true,5 .is_var_args = true,
6 .return_type = u0,6 .return_type = u0,
test/cases/compile_errors/reify_type.Fn_with_return_type_null.zig+1-1
...@@ -1,6 +1,6 @@...@@ -1,6 +1,6 @@
1const Foo = @Type(.{1const Foo = @Type(.{
2 .@"fn" = .{2 .@"fn" = .{
3 .calling_convention = .Unspecified,3 .calling_convention = .auto,
4 .is_generic = false,4 .is_generic = false,
5 .is_var_args = false,5 .is_var_args = false,
6 .return_type = null,6 .return_type = null,
test/src/LlvmIr.zig+14-12
...@@ -90,19 +90,21 @@ pub fn addCase(self: *LlvmIr, case: TestCase) void {...@@ -90,19 +90,21 @@ pub fn addCase(self: *LlvmIr, case: TestCase) void {
9090
91 const obj = self.b.addObject(.{91 const obj = self.b.addObject(.{
92 .name = "test",92 .name = "test",
93 .root_source_file = self.b.addWriteFiles().add("test.zig", case.source),93 .root_module = self.b.createModule(.{
94 .use_llvm = true,94 .root_source_file = self.b.addWriteFiles().add("test.zig", case.source),
9595
96 .code_model = case.params.code_model,96 .code_model = case.params.code_model,
97 .error_tracing = case.params.error_tracing,97 .error_tracing = case.params.error_tracing,
98 .omit_frame_pointer = case.params.omit_frame_pointer,98 .omit_frame_pointer = case.params.omit_frame_pointer,
99 .optimize = case.params.optimize,99 .optimize = case.params.optimize,
100 .pic = case.params.pic,100 .pic = case.params.pic,
101 .sanitize_thread = case.params.sanitize_thread,101 .sanitize_thread = case.params.sanitize_thread,
102 .single_threaded = case.params.single_threaded,102 .single_threaded = case.params.single_threaded,
103 .strip = case.params.strip,103 .strip = case.params.strip,
104 .target = target,104 .target = target,
105 .unwind_tables = case.params.unwind_tables,105 .unwind_tables = case.params.unwind_tables,
106 }),
107 .use_llvm = true,
106 });108 });
107109
108 obj.dll_export_fns = case.params.dll_export_fns;110 obj.dll_export_fns = case.params.dll_export_fns;
test/standalone/c_embed_path/build.zig+4-2
...@@ -8,8 +8,10 @@ pub fn build(b: *std.Build) void {...@@ -8,8 +8,10 @@ pub fn build(b: *std.Build) void {
88
9 const exe = b.addExecutable(.{9 const exe = b.addExecutable(.{
10 .name = "test",10 .name = "test",
11 .target = b.graph.host,11 .root_module = b.createModule(.{
12 .optimize = optimize,12 .target = b.graph.host,
13 .optimize = optimize,
14 }),
13 });15 });
14 exe.addCSourceFile(.{16 exe.addCSourceFile(.{
15 .file = b.path("test.c"),17 .file = b.path("test.c"),
test/standalone/config_header/build.zig+1-1
...@@ -2,7 +2,7 @@ const std = @import("std");...@@ -2,7 +2,7 @@ const std = @import("std");
22
3pub fn build(b: *std.Build) void {3pub fn build(b: *std.Build) void {
4 const config_header = b.addConfigHeader(4 const config_header = b.addConfigHeader(
5 .{ .style = .{ .autoconf = b.path("config.h.in") } },5 .{ .style = .{ .autoconf_undef = b.path("config.h.in") } },
6 .{6 .{
7 .SOME_NO = null,7 .SOME_NO = null,
8 .SOME_TRUE = true,8 .SOME_TRUE = true,
test/tests.zig+9-4
...@@ -438,7 +438,7 @@ const test_targets = blk: {...@@ -438,7 +438,7 @@ const test_targets = blk: {
438 .os_tag = .linux,438 .os_tag = .linux,
439 .abi = .none,439 .abi = .none,
440 },440 },
441 // https://github.com/ziglang/zig/issues/23696441 // https://github.com/ziglang/zig/issues/21646
442 .skip_modules = &.{"std"},442 .skip_modules = &.{"std"},
443 },443 },
444 .{444 .{
...@@ -448,7 +448,7 @@ const test_targets = blk: {...@@ -448,7 +448,7 @@ const test_targets = blk: {
448 .abi = .musl,448 .abi = .musl,
449 },449 },
450 .link_libc = true,450 .link_libc = true,
451 // https://github.com/ziglang/zig/issues/23696451 // https://github.com/ziglang/zig/issues/21646
452 .skip_modules = &.{"std"},452 .skip_modules = &.{"std"},
453 },453 },
454 .{454 .{
...@@ -459,7 +459,7 @@ const test_targets = blk: {...@@ -459,7 +459,7 @@ const test_targets = blk: {
459 },459 },
460 .linkage = .dynamic,460 .linkage = .dynamic,
461 .link_libc = true,461 .link_libc = true,
462 // https://github.com/ziglang/zig/issues/23696462 // https://github.com/ziglang/zig/issues/21646
463 .skip_modules = &.{"std"},463 .skip_modules = &.{"std"},
464 .extra_target = true,464 .extra_target = true,
465 },465 },
...@@ -470,7 +470,7 @@ const test_targets = blk: {...@@ -470,7 +470,7 @@ const test_targets = blk: {
470 .abi = .gnu,470 .abi = .gnu,
471 },471 },
472 .link_libc = true,472 .link_libc = true,
473 // https://github.com/ziglang/zig/issues/23696473 // https://github.com/ziglang/zig/issues/21646
474 .skip_modules = &.{"std"},474 .skip_modules = &.{"std"},
475 },475 },
476476
...@@ -2369,6 +2369,11 @@ pub fn addModuleTests(b: *std.Build, options: ModuleTestOptions) *Step {...@@ -2369,6 +2369,11 @@ pub fn addModuleTests(b: *std.Build, options: ModuleTestOptions) *Step {
2369 if (options.skip_single_threaded and test_target.single_threaded == true)2369 if (options.skip_single_threaded and test_target.single_threaded == true)
2370 continue;2370 continue;
23712371
2372 // https://github.com/ziglang/zig/issues/24405
2373 if (!builtin.cpu.arch.isLoongArch() and target.cpu.arch.isLoongArch() and
2374 (mem.eql(u8, options.name, "behavior") or mem.eql(u8, options.name, "std")))
2375 continue;
2376
2372 // TODO get compiler-rt tests passing for self-hosted backends.2377 // TODO get compiler-rt tests passing for self-hosted backends.
2373 if ((target.cpu.arch != .x86_64 or target.ofmt != .elf) and2378 if ((target.cpu.arch != .x86_64 or target.ofmt != .elf) and
2374 test_target.use_llvm == false and mem.eql(u8, options.name, "compiler-rt"))2379 test_target.use_llvm == false and mem.eql(u8, options.name, "compiler-rt"))
tools/docgen.zig+1-1
...@@ -10,7 +10,7 @@ const mem = std.mem;...@@ -10,7 +10,7 @@ const mem = std.mem;
10const testing = std.testing;10const testing = std.testing;
11const Allocator = std.mem.Allocator;11const Allocator = std.mem.Allocator;
12const getExternalExecutor = std.zig.system.getExternalExecutor;12const getExternalExecutor = std.zig.system.getExternalExecutor;
13const fatal = std.zig.fatal;13const fatal = std.process.fatal;
1414
15const max_doc_file_size = 10 * 1024 * 1024;15const max_doc_file_size = 10 * 1024 * 1024;
1616
tools/doctest.zig+1-1
...@@ -1,6 +1,6 @@...@@ -1,6 +1,6 @@
1const builtin = @import("builtin");1const builtin = @import("builtin");
2const std = @import("std");2const std = @import("std");
3const fatal = std.zig.fatal;3const fatal = std.process.fatal;
4const mem = std.mem;4const mem = std.mem;
5const fs = std.fs;5const fs = std.fs;
6const process = std.process;6const process = std.process;
tools/gen_spirv_spec.zig+155-145
...@@ -59,26 +59,28 @@ const set_names = std.StaticStringMap([]const u8).initComptime(.{...@@ -59,26 +59,28 @@ const set_names = std.StaticStringMap([]const u8).initComptime(.{
59 .{ "nonsemantic.debugprintf", "NonSemantic.DebugPrintf" },59 .{ "nonsemantic.debugprintf", "NonSemantic.DebugPrintf" },
60 .{ "spv-amd-shader-explicit-vertex-parameter", "SPV_AMD_shader_explicit_vertex_parameter" },60 .{ "spv-amd-shader-explicit-vertex-parameter", "SPV_AMD_shader_explicit_vertex_parameter" },
61 .{ "nonsemantic.debugbreak", "NonSemantic.DebugBreak" },61 .{ "nonsemantic.debugbreak", "NonSemantic.DebugBreak" },
62 .{ "tosa.001000.1", "SPV_EXT_INST_TYPE_TOSA_001000_1" },
62 .{ "zig", "zig" },63 .{ "zig", "zig" },
63});64});
6465
66var arena = std.heap.ArenaAllocator.init(std.heap.smp_allocator);
67const allocator = arena.allocator();
68
65pub fn main() !void {69pub fn main() !void {
66 var arena = std.heap.ArenaAllocator.init(std.heap.page_allocator);
67 defer arena.deinit();70 defer arena.deinit();
68 const a = arena.allocator();
6971
70 const args = try std.process.argsAlloc(a);72 const args = try std.process.argsAlloc(allocator);
71 if (args.len != 3) {73 if (args.len != 3) {
72 usageAndExit(args[0], 1);74 usageAndExit(args[0], 1);
73 }75 }
7476
75 const json_path = try std.fs.path.join(a, &.{ args[1], "include/spirv/unified1/" });77 const json_path = try std.fs.path.join(allocator, &.{ args[1], "include/spirv/unified1/" });
76 const dir = try std.fs.cwd().openDir(json_path, .{ .iterate = true });78 const dir = try std.fs.cwd().openDir(json_path, .{ .iterate = true });
7779
78 const core_spec = try readRegistry(CoreRegistry, a, dir, "spirv.core.grammar.json");80 const core_spec = try readRegistry(CoreRegistry, dir, "spirv.core.grammar.json");
79 std.sort.block(Instruction, core_spec.instructions, CmpInst{}, CmpInst.lt);81 std.sort.block(Instruction, core_spec.instructions, CmpInst{}, CmpInst.lt);
8082
81 var exts = std.ArrayList(Extension).init(a);83 var exts = std.ArrayList(Extension).init(allocator);
8284
83 var it = dir.iterate();85 var it = dir.iterate();
84 while (try it.next()) |entry| {86 while (try it.next()) |entry| {
...@@ -86,18 +88,43 @@ pub fn main() !void {...@@ -86,18 +88,43 @@ pub fn main() !void {
86 continue;88 continue;
87 }89 }
8890
89 try readExtRegistry(&exts, a, dir, entry.name);91 try readExtRegistry(&exts, dir, entry.name);
90 }92 }
9193
92 try readExtRegistry(&exts, a, std.fs.cwd(), args[2]);94 try readExtRegistry(&exts, std.fs.cwd(), args[2]);
95
96 const output_buf = try allocator.alloc(u8, 1024 * 1024);
97 var fbs = std.io.fixedBufferStream(output_buf);
98 var adapter = fbs.writer().adaptToNewApi();
99 const w = &adapter.new_interface;
100 try render(w, core_spec, exts.items);
101 var output: [:0]u8 = @ptrCast(fbs.getWritten());
102 output[output.len] = 0;
103
104 var tree = try std.zig.Ast.parse(allocator, output, .zig);
105 var color: std.zig.Color = .on;
93106
94 var buffer: [4000]u8 = undefined;107 if (tree.errors.len != 0) {
95 var w = std.fs.File.stdout().writerStreaming(&buffer);108 try std.zig.printAstErrorsToStderr(allocator, tree, "", color);
96 try render(&w, a, core_spec, exts.items);109 return;
97 try w.flush();110 }
111
112 var zir = try std.zig.AstGen.generate(allocator, tree);
113 if (zir.hasCompileErrors()) {
114 var wip_errors: std.zig.ErrorBundle.Wip = undefined;
115 try wip_errors.init(allocator);
116 defer wip_errors.deinit();
117 try wip_errors.addZirErrorMessages(zir, tree, output, "");
118 var error_bundle = try wip_errors.toOwnedBundle("");
119 defer error_bundle.deinit(allocator);
120 error_bundle.renderToStdErr(color.renderOptions());
121 }
122
123 const formatted_output = try tree.render(allocator);
124 _ = try std.fs.File.stdout().write(formatted_output);
98}125}
99126
100fn readExtRegistry(exts: *std.ArrayList(Extension), a: Allocator, dir: std.fs.Dir, sub_path: []const u8) !void {127fn readExtRegistry(exts: *std.ArrayList(Extension), dir: std.fs.Dir, sub_path: []const u8) !void {
101 const filename = std.fs.path.basename(sub_path);128 const filename = std.fs.path.basename(sub_path);
102 if (!std.mem.startsWith(u8, filename, "extinst.")) {129 if (!std.mem.startsWith(u8, filename, "extinst.")) {
103 return;130 return;
...@@ -105,22 +132,22 @@ fn readExtRegistry(exts: *std.ArrayList(Extension), a: Allocator, dir: std.fs.Di...@@ -105,22 +132,22 @@ fn readExtRegistry(exts: *std.ArrayList(Extension), a: Allocator, dir: std.fs.Di
105132
106 std.debug.assert(std.mem.endsWith(u8, filename, ".grammar.json"));133 std.debug.assert(std.mem.endsWith(u8, filename, ".grammar.json"));
107 const name = filename["extinst.".len .. filename.len - ".grammar.json".len];134 const name = filename["extinst.".len .. filename.len - ".grammar.json".len];
108 const spec = try readRegistry(ExtensionRegistry, a, dir, sub_path);135 const spec = try readRegistry(ExtensionRegistry, dir, sub_path);
109136
110 std.sort.block(Instruction, spec.instructions, CmpInst{}, CmpInst.lt);137 std.sort.block(Instruction, spec.instructions, CmpInst{}, CmpInst.lt);
111138
112 try exts.append(.{ .name = set_names.get(name).?, .spec = spec });139 try exts.append(.{ .name = set_names.get(name).?, .spec = spec });
113}140}
114141
115fn readRegistry(comptime RegistryType: type, a: Allocator, dir: std.fs.Dir, path: []const u8) !RegistryType {142fn readRegistry(comptime RegistryType: type, dir: std.fs.Dir, path: []const u8) !RegistryType {
116 const spec = try dir.readFileAlloc(a, path, std.math.maxInt(usize));143 const spec = try dir.readFileAlloc(allocator, path, std.math.maxInt(usize));
117 // Required for json parsing.144 // Required for json parsing.
118 @setEvalBranchQuota(10000);145 @setEvalBranchQuota(10000);
119146
120 var scanner = std.json.Scanner.initCompleteInput(a, spec);147 var scanner = std.json.Scanner.initCompleteInput(allocator, spec);
121 var diagnostics = std.json.Diagnostics{};148 var diagnostics = std.json.Diagnostics{};
122 scanner.enableDiagnostics(&diagnostics);149 scanner.enableDiagnostics(&diagnostics);
123 const parsed = std.json.parseFromTokenSource(RegistryType, a, &scanner, .{}) catch |err| {150 const parsed = std.json.parseFromTokenSource(RegistryType, allocator, &scanner, .{}) catch |err| {
124 std.debug.print("{s}:{}:{}:\n", .{ path, diagnostics.getLine(), diagnostics.getColumn() });151 std.debug.print("{s}:{}:{}:\n", .{ path, diagnostics.getLine(), diagnostics.getColumn() });
125 return err;152 return err;
126 };153 };
...@@ -129,11 +156,8 @@ fn readRegistry(comptime RegistryType: type, a: Allocator, dir: std.fs.Dir, path...@@ -129,11 +156,8 @@ fn readRegistry(comptime RegistryType: type, a: Allocator, dir: std.fs.Dir, path
129156
130/// Returns a set with types that require an extra struct for the `Instruction` interface157/// Returns a set with types that require an extra struct for the `Instruction` interface
131/// to the spir-v spec, or whether the original type can be used.158/// to the spir-v spec, or whether the original type can be used.
132fn extendedStructs(159fn extendedStructs(kinds: []const OperandKind) !ExtendedStructSet {
133 a: Allocator,160 var map = ExtendedStructSet.init(allocator);
134 kinds: []const OperandKind,
135) !ExtendedStructSet {
136 var map = ExtendedStructSet.init(a);
137 try map.ensureTotalCapacity(@as(u32, @intCast(kinds.len)));161 try map.ensureTotalCapacity(@as(u32, @intCast(kinds.len)));
138162
139 for (kinds) |kind| {163 for (kinds) |kind| {
...@@ -167,7 +191,7 @@ fn tagPriorityScore(tag: []const u8) usize {...@@ -167,7 +191,7 @@ fn tagPriorityScore(tag: []const u8) usize {
167 }191 }
168}192}
169193
170fn render(writer: *std.io.Writer, a: Allocator, registry: CoreRegistry, extensions: []const Extension) !void {194fn render(writer: *std.io.Writer, registry: CoreRegistry, extensions: []const Extension) !void {
171 try writer.writeAll(195 try writer.writeAll(
172 \\//! This file is auto-generated by tools/gen_spirv_spec.zig.196 \\//! This file is auto-generated by tools/gen_spirv_spec.zig.
173 \\197 \\
...@@ -185,22 +209,17 @@ fn render(writer: *std.io.Writer, a: Allocator, registry: CoreRegistry, extensio...@@ -185,22 +209,17 @@ fn render(writer: *std.io.Writer, a: Allocator, registry: CoreRegistry, extensio
185 \\};209 \\};
186 \\210 \\
187 \\pub const Word = u32;211 \\pub const Word = u32;
188 \\pub const IdResult = enum(Word) {212 \\pub const Id = enum(Word) {
189 \\ none,213 \\ none,
190 \\ _,214 \\ _,
191 \\215 \\
192 \\ pub fn format(self: IdResult, writer: *std.io.Writer) std.io.Writer.Error!void {216 \\ pub fn format(self: Id, writer: *std.io.Writer) std.io.Writer.Error!void {
193 \\ switch (self) {217 \\ switch (self) {
194 \\ .none => try writer.writeAll("(none)"),218 \\ .none => try writer.writeAll("(none)"),
195 \\ else => try writer.print("%{d}", .{@intFromEnum(self)}),219 \\ else => try writer.print("%{d}", .{@intFromEnum(self)}),
196 \\ }220 \\ }
197 \\ }221 \\ }
198 \\};222 \\};
199 \\pub const IdResultType = IdResult;
200 \\pub const IdRef = IdResult;
201 \\
202 \\pub const IdMemorySemantics = IdRef;
203 \\pub const IdScope = IdRef;
204 \\223 \\
205 \\pub const LiteralInteger = Word;224 \\pub const LiteralInteger = Word;
206 \\pub const LiteralFloat = Word;225 \\pub const LiteralFloat = Word;
...@@ -215,9 +234,9 @@ fn render(writer: *std.io.Writer, a: Allocator, registry: CoreRegistry, extensio...@@ -215,9 +234,9 @@ fn render(writer: *std.io.Writer, a: Allocator, registry: CoreRegistry, extensio
215 \\};234 \\};
216 \\pub const LiteralExtInstInteger = struct{ inst: Word };235 \\pub const LiteralExtInstInteger = struct{ inst: Word };
217 \\pub const LiteralSpecConstantOpInteger = struct { opcode: Opcode };236 \\pub const LiteralSpecConstantOpInteger = struct { opcode: Opcode };
218 \\pub const PairLiteralIntegerIdRef = struct { value: LiteralInteger, label: IdRef };237 \\pub const PairLiteralIntegerIdRef = struct { value: LiteralInteger, label: Id };
219 \\pub const PairIdRefLiteralInteger = struct { target: IdRef, member: LiteralInteger };238 \\pub const PairIdRefLiteralInteger = struct { target: Id, member: LiteralInteger };
220 \\pub const PairIdRefIdRef = [2]IdRef;239 \\pub const PairIdRefIdRef = [2]Id;
221 \\240 \\
222 \\pub const Quantifier = enum {241 \\pub const Quantifier = enum {
223 \\ required,242 \\ required,
...@@ -255,7 +274,7 @@ fn render(writer: *std.io.Writer, a: Allocator, registry: CoreRegistry, extensio...@@ -255,7 +274,7 @@ fn render(writer: *std.io.Writer, a: Allocator, registry: CoreRegistry, extensio
255 );274 );
256275
257 try writer.print(276 try writer.print(
258 \\pub const version = Version{{ .major = {}, .minor = {}, .patch = {} }};277 \\pub const version: Version = .{{ .major = {}, .minor = {}, .patch = {} }};
259 \\pub const magic_number: Word = {s};278 \\pub const magic_number: Word = {s};
260 \\279 \\
261 \\280 \\
...@@ -266,7 +285,7 @@ fn render(writer: *std.io.Writer, a: Allocator, registry: CoreRegistry, extensio...@@ -266,7 +285,7 @@ fn render(writer: *std.io.Writer, a: Allocator, registry: CoreRegistry, extensio
266 // Merge the operand kinds from all extensions together.285 // Merge the operand kinds from all extensions together.
267 // var all_operand_kinds = std.ArrayList(OperandKind).init(a);286 // var all_operand_kinds = std.ArrayList(OperandKind).init(a);
268 // try all_operand_kinds.appendSlice(registry.operand_kinds);287 // try all_operand_kinds.appendSlice(registry.operand_kinds);
269 var all_operand_kinds = OperandKindMap.init(a);288 var all_operand_kinds = OperandKindMap.init(allocator);
270 for (registry.operand_kinds) |kind| {289 for (registry.operand_kinds) |kind| {
271 try all_operand_kinds.putNoClobber(.{ "core", kind.kind }, kind);290 try all_operand_kinds.putNoClobber(.{ "core", kind.kind }, kind);
272 }291 }
...@@ -279,35 +298,33 @@ fn render(writer: *std.io.Writer, a: Allocator, registry: CoreRegistry, extensio...@@ -279,35 +298,33 @@ fn render(writer: *std.io.Writer, a: Allocator, registry: CoreRegistry, extensio
279 try all_operand_kinds.ensureUnusedCapacity(ext.spec.operand_kinds.len);298 try all_operand_kinds.ensureUnusedCapacity(ext.spec.operand_kinds.len);
280 for (ext.spec.operand_kinds) |kind| {299 for (ext.spec.operand_kinds) |kind| {
281 var new_kind = kind;300 var new_kind = kind;
282 new_kind.kind = try std.mem.join(a, ".", &.{ ext.name, kind.kind });301 new_kind.kind = try std.mem.join(allocator, ".", &.{ ext.name, kind.kind });
283 try all_operand_kinds.putNoClobber(.{ ext.name, kind.kind }, new_kind);302 try all_operand_kinds.putNoClobber(.{ ext.name, kind.kind }, new_kind);
284 }303 }
285 }304 }
286305
287 const extended_structs = try extendedStructs(a, all_operand_kinds.values());306 const extended_structs = try extendedStructs(all_operand_kinds.values());
288 // Note: extensions don't seem to have class.307 // Note: extensions don't seem to have class.
289 try renderClass(writer, a, registry.instructions);308 try renderClass(writer, registry.instructions);
290 try renderOperandKind(writer, all_operand_kinds.values());309 try renderOperandKind(writer, all_operand_kinds.values());
291 try renderOpcodes(writer, a, registry.instructions, extended_structs);310 try renderOpcodes(writer, registry.instructions, extended_structs);
292 try renderOperandKinds(writer, a, all_operand_kinds.values(), extended_structs);311 try renderOperandKinds(writer, all_operand_kinds.values(), extended_structs);
293 try renderInstructionSet(writer, a, registry, extensions, all_operand_kinds);312 try renderInstructionSet(writer, registry, extensions, all_operand_kinds);
294}313}
295314
296fn renderInstructionSet(315fn renderInstructionSet(
297 writer: anytype,316 writer: anytype,
298 a: Allocator,
299 core: CoreRegistry,317 core: CoreRegistry,
300 extensions: []const Extension,318 extensions: []const Extension,
301 all_operand_kinds: OperandKindMap,319 all_operand_kinds: OperandKindMap,
302) !void {320) !void {
303 _ = a;
304 try writer.writeAll(321 try writer.writeAll(
305 \\pub const InstructionSet = enum {322 \\pub const InstructionSet = enum {
306 \\ core,323 \\ core,
307 );324 );
308325
309 for (extensions) |ext| {326 for (extensions) |ext| {
310 try writer.print("{p},\n", .{std.zig.fmtId(ext.name)});327 try writer.print("{f},\n", .{formatId(ext.name)});
311 }328 }
312329
313 try writer.writeAll(330 try writer.writeAll(
...@@ -340,14 +357,14 @@ fn renderInstructionsCase(...@@ -340,14 +357,14 @@ fn renderInstructionsCase(
340 // but there aren't so many total aliases and that would add more overhead in total. We will357 // but there aren't so many total aliases and that would add more overhead in total. We will
341 // just filter those out when needed.358 // just filter those out when needed.
342359
343 try writer.print(".{p_} => &[_]Instruction{{\n", .{std.zig.fmtId(set_name)});360 try writer.print(".{f} => &.{{\n", .{formatId(set_name)});
344361
345 for (instructions) |inst| {362 for (instructions) |inst| {
346 try writer.print(363 try writer.print(
347 \\.{{364 \\.{{
348 \\ .name = "{s}",365 \\ .name = "{s}",
349 \\ .opcode = {},366 \\ .opcode = {},
350 \\ .operands = &[_]Operand{{367 \\ .operands = &.{{
351 \\368 \\
352 , .{ inst.opname, inst.opcode });369 , .{ inst.opname, inst.opcode });
353370
...@@ -362,7 +379,7 @@ fn renderInstructionsCase(...@@ -362,7 +379,7 @@ fn renderInstructionsCase(
362379
363 const kind = all_operand_kinds.get(.{ set_name, operand.kind }) orelse380 const kind = all_operand_kinds.get(.{ set_name, operand.kind }) orelse
364 all_operand_kinds.get(.{ "core", operand.kind }).?;381 all_operand_kinds.get(.{ "core", operand.kind }).?;
365 try writer.print(".{{.kind = .{p_}, .quantifier = .{s}}},\n", .{ std.zig.fmtId(kind.kind), quantifier });382 try writer.print(".{{.kind = .{f}, .quantifier = .{s}}},\n", .{ formatId(kind.kind), quantifier });
366 }383 }
367384
368 try writer.writeAll(385 try writer.writeAll(
...@@ -378,54 +395,69 @@ fn renderInstructionsCase(...@@ -378,54 +395,69 @@ fn renderInstructionsCase(
378 );395 );
379}396}
380397
381fn renderClass(writer: anytype, a: Allocator, instructions: []const Instruction) !void {398fn renderClass(writer: anytype, instructions: []const Instruction) !void {
382 var class_map = std.StringArrayHashMap(void).init(a);399 var class_map = std.StringArrayHashMap(void).init(allocator);
383400
384 for (instructions) |inst| {401 for (instructions) |inst| {
385 if (std.mem.eql(u8, inst.class.?, "@exclude")) {402 if (std.mem.eql(u8, inst.class.?, "@exclude")) continue;
386 continue;
387 }
388 try class_map.put(inst.class.?, {});403 try class_map.put(inst.class.?, {});
389 }404 }
390405
391 try writer.writeAll("pub const Class = enum {\n");406 try writer.writeAll("pub const Class = enum {\n");
392 for (class_map.keys()) |class| {407 for (class_map.keys()) |class| {
393 try renderInstructionClass(writer, class);408 try writer.print("{f},\n", .{formatId(class)});
394 try writer.writeAll(",\n");
395 }409 }
396 try writer.writeAll("};\n\n");410 try writer.writeAll("};\n\n");
397}411}
398412
399fn renderInstructionClass(writer: anytype, class: []const u8) !void {413const Formatter = struct {
400 // Just assume that these wont clobber zig builtin types.414 data: []const u8,
401 var prev_was_sep = true;415
402 for (class) |c| {416 fn format(f: Formatter, writer: *std.io.Writer) std.io.Writer.Error!void {
403 switch (c) {417 var id_buf: [128]u8 = undefined;
404 '-', '_' => prev_was_sep = true,418 var fbs = std.io.fixedBufferStream(&id_buf);
405 else => if (prev_was_sep) {419 const fw = fbs.writer();
406 try writer.writeByte(std.ascii.toUpper(c));420 for (f.data, 0..) |c, i| {
407 prev_was_sep = false;421 switch (c) {
408 } else {422 '-', '_', '.', '~', ' ' => fw.writeByte('_') catch return error.WriteFailed,
409 try writer.writeByte(std.ascii.toLower(c));423 'a'...'z', '0'...'9' => fw.writeByte(c) catch return error.WriteFailed,
410 },424 'A'...'Z' => {
425 if ((i > 0 and std.ascii.isLower(f.data[i - 1])) or
426 (i > 0 and std.ascii.isUpper(f.data[i - 1]) and
427 i + 1 < f.data.len and std.ascii.isLower(f.data[i + 1])))
428 {
429 _ = fw.write(&.{ '_', std.ascii.toLower(c) }) catch return error.WriteFailed;
430 } else {
431 fw.writeByte(std.ascii.toLower(c)) catch return error.WriteFailed;
432 }
433 },
434 else => unreachable,
435 }
411 }436 }
437
438 // make sure that this won't clobber with zig keywords
439 try writer.print("{f}", .{std.zig.fmtId(fbs.getWritten())});
412 }440 }
441};
442
443fn formatId(identifier: []const u8) std.fmt.Alt(Formatter, Formatter.format) {
444 return .{ .data = .{ .data = identifier } };
413}445}
414446
415fn renderOperandKind(writer: anytype, operands: []const OperandKind) !void {447fn renderOperandKind(writer: anytype, operands: []const OperandKind) !void {
416 try writer.writeAll(448 try writer.writeAll(
417 \\pub const OperandKind = enum {449 \\pub const OperandKind = enum {
418 \\ Opcode,450 \\ opcode,
419 \\451 \\
420 );452 );
421 for (operands) |operand| {453 for (operands) |operand| {
422 try writer.print("{p},\n", .{std.zig.fmtId(operand.kind)});454 try writer.print("{f},\n", .{formatId(operand.kind)});
423 }455 }
424 try writer.writeAll(456 try writer.writeAll(
425 \\457 \\
426 \\pub fn category(self: OperandKind) OperandCategory {458 \\pub fn category(self: OperandKind) OperandCategory {
427 \\ return switch (self) {459 \\ return switch (self) {
428 \\ .Opcode => .literal,460 \\ .opcode => .literal,
429 \\461 \\
430 );462 );
431 for (operands) |operand| {463 for (operands) |operand| {
...@@ -436,26 +468,26 @@ fn renderOperandKind(writer: anytype, operands: []const OperandKind) !void {...@@ -436,26 +468,26 @@ fn renderOperandKind(writer: anytype, operands: []const OperandKind) !void {
436 .Literal => "literal",468 .Literal => "literal",
437 .Composite => "composite",469 .Composite => "composite",
438 };470 };
439 try writer.print(".{p_} => .{s},\n", .{ std.zig.fmtId(operand.kind), cat });471 try writer.print(".{f} => .{s},\n", .{ formatId(operand.kind), cat });
440 }472 }
441 try writer.writeAll(473 try writer.writeAll(
442 \\ };474 \\ };
443 \\}475 \\}
444 \\pub fn enumerants(self: OperandKind) []const Enumerant {476 \\pub fn enumerants(self: OperandKind) []const Enumerant {
445 \\ return switch (self) {477 \\ return switch (self) {
446 \\ .Opcode => unreachable,478 \\ .opcode => unreachable,
447 \\479 \\
448 );480 );
449 for (operands) |operand| {481 for (operands) |operand| {
450 switch (operand.category) {482 switch (operand.category) {
451 .BitEnum, .ValueEnum => {},483 .BitEnum, .ValueEnum => {},
452 else => {484 else => {
453 try writer.print(".{p_} => unreachable,\n", .{std.zig.fmtId(operand.kind)});485 try writer.print(".{f} => unreachable,\n", .{formatId(operand.kind)});
454 continue;486 continue;
455 },487 },
456 }488 }
457489
458 try writer.print(".{p_} => &[_]Enumerant{{", .{std.zig.fmtId(operand.kind)});490 try writer.print(".{f} => &.{{", .{formatId(operand.kind)});
459 for (operand.enumerants.?) |enumerant| {491 for (operand.enumerants.?) |enumerant| {
460 if (enumerant.value == .bitflag and std.mem.eql(u8, enumerant.enumerant, "None")) {492 if (enumerant.value == .bitflag and std.mem.eql(u8, enumerant.enumerant, "None")) {
461 continue;493 continue;
...@@ -474,32 +506,30 @@ fn renderEnumerant(writer: anytype, enumerant: Enumerant) !void {...@@ -474,32 +506,30 @@ fn renderEnumerant(writer: anytype, enumerant: Enumerant) !void {
474 .bitflag => |flag| try writer.writeAll(flag),506 .bitflag => |flag| try writer.writeAll(flag),
475 .int => |int| try writer.print("{}", .{int}),507 .int => |int| try writer.print("{}", .{int}),
476 }508 }
477 try writer.writeAll(", .parameters = &[_]OperandKind{");509 try writer.writeAll(", .parameters = &.{");
478 for (enumerant.parameters, 0..) |param, i| {510 for (enumerant.parameters, 0..) |param, i| {
479 if (i != 0)511 if (i != 0)
480 try writer.writeAll(", ");512 try writer.writeAll(", ");
481 // Note, param.quantifier will always be one.513 // Note, param.quantifier will always be one.
482 try writer.print(".{p_}", .{std.zig.fmtId(param.kind)});514 try writer.print(".{f}", .{formatId(param.kind)});
483 }515 }
484 try writer.writeAll("}}");516 try writer.writeAll("}}");
485}517}
486518
487fn renderOpcodes(519fn renderOpcodes(
488 writer: anytype,520 writer: anytype,
489 a: Allocator,
490 instructions: []const Instruction,521 instructions: []const Instruction,
491 extended_structs: ExtendedStructSet,522 extended_structs: ExtendedStructSet,
492) !void {523) !void {
493 var inst_map = std.AutoArrayHashMap(u32, usize).init(a);524 var inst_map = std.AutoArrayHashMap(u32, usize).init(allocator);
494 try inst_map.ensureTotalCapacity(instructions.len);525 try inst_map.ensureTotalCapacity(instructions.len);
495526
496 var aliases = std.ArrayList(struct { inst: usize, alias: usize }).init(a);527 var aliases = std.ArrayList(struct { inst: usize, alias: usize }).init(allocator);
497 try aliases.ensureTotalCapacity(instructions.len);528 try aliases.ensureTotalCapacity(instructions.len);
498529
499 for (instructions, 0..) |inst, i| {530 for (instructions, 0..) |inst, i| {
500 if (std.mem.eql(u8, inst.class.?, "@exclude")) {531 if (std.mem.eql(u8, inst.class.?, "@exclude")) continue;
501 continue;532
502 }
503 const result = inst_map.getOrPutAssumeCapacity(inst.opcode);533 const result = inst_map.getOrPutAssumeCapacity(inst.opcode);
504 if (!result.found_existing) {534 if (!result.found_existing) {
505 result.value_ptr.* = i;535 result.value_ptr.* = i;
...@@ -525,7 +555,7 @@ fn renderOpcodes(...@@ -525,7 +555,7 @@ fn renderOpcodes(
525 try writer.writeAll("pub const Opcode = enum(u16) {\n");555 try writer.writeAll("pub const Opcode = enum(u16) {\n");
526 for (instructions_indices) |i| {556 for (instructions_indices) |i| {
527 const inst = instructions[i];557 const inst = instructions[i];
528 try writer.print("{p} = {},\n", .{ std.zig.fmtId(inst.opname), inst.opcode });558 try writer.print("{f} = {},\n", .{ std.zig.fmtId(inst.opname), inst.opcode });
529 }559 }
530560
531 try writer.writeAll(561 try writer.writeAll(
...@@ -533,9 +563,9 @@ fn renderOpcodes(...@@ -533,9 +563,9 @@ fn renderOpcodes(
533 );563 );
534564
535 for (aliases.items) |alias| {565 for (aliases.items) |alias| {
536 try writer.print("pub const {} = Opcode.{p_};\n", .{566 try writer.print("pub const {f} = Opcode.{f};\n", .{
537 std.zig.fmtId(instructions[alias.inst].opname),567 formatId(instructions[alias.inst].opname),
538 std.zig.fmtId(instructions[alias.alias].opname),568 formatId(instructions[alias.alias].opname),
539 });569 });
540 }570 }
541571
...@@ -548,7 +578,7 @@ fn renderOpcodes(...@@ -548,7 +578,7 @@ fn renderOpcodes(
548578
549 for (instructions_indices) |i| {579 for (instructions_indices) |i| {
550 const inst = instructions[i];580 const inst = instructions[i];
551 try renderOperand(writer, .instruction, inst.opname, inst.operands, extended_structs);581 try renderOperand(writer, .instruction, inst.opname, inst.operands, extended_structs, false);
552 }582 }
553583
554 try writer.writeAll(584 try writer.writeAll(
...@@ -561,9 +591,7 @@ fn renderOpcodes(...@@ -561,9 +591,7 @@ fn renderOpcodes(
561591
562 for (instructions_indices) |i| {592 for (instructions_indices) |i| {
563 const inst = instructions[i];593 const inst = instructions[i];
564 try writer.print(".{p_} => .", .{std.zig.fmtId(inst.opname)});594 try writer.print(".{f} => .{f},\n", .{ std.zig.fmtId(inst.opname), formatId(inst.class.?) });
565 try renderInstructionClass(writer, inst.class.?);
566 try writer.writeAll(",\n");
567 }595 }
568596
569 try writer.writeAll(597 try writer.writeAll(
...@@ -576,14 +604,13 @@ fn renderOpcodes(...@@ -576,14 +604,13 @@ fn renderOpcodes(
576604
577fn renderOperandKinds(605fn renderOperandKinds(
578 writer: anytype,606 writer: anytype,
579 a: Allocator,
580 kinds: []const OperandKind,607 kinds: []const OperandKind,
581 extended_structs: ExtendedStructSet,608 extended_structs: ExtendedStructSet,
582) !void {609) !void {
583 for (kinds) |kind| {610 for (kinds) |kind| {
584 switch (kind.category) {611 switch (kind.category) {
585 .ValueEnum => try renderValueEnum(writer, a, kind, extended_structs),612 .ValueEnum => try renderValueEnum(writer, kind, extended_structs),
586 .BitEnum => try renderBitEnum(writer, a, kind, extended_structs),613 .BitEnum => try renderBitEnum(writer, kind, extended_structs),
587 else => {},614 else => {},
588 }615 }
589 }616 }
...@@ -591,20 +618,18 @@ fn renderOperandKinds(...@@ -591,20 +618,18 @@ fn renderOperandKinds(
591618
592fn renderValueEnum(619fn renderValueEnum(
593 writer: anytype,620 writer: anytype,
594 a: Allocator,
595 enumeration: OperandKind,621 enumeration: OperandKind,
596 extended_structs: ExtendedStructSet,622 extended_structs: ExtendedStructSet,
597) !void {623) !void {
598 const enumerants = enumeration.enumerants orelse return error.InvalidRegistry;624 const enumerants = enumeration.enumerants orelse return error.InvalidRegistry;
599625
600 var enum_map = std.AutoArrayHashMap(u32, usize).init(a);626 var enum_map = std.AutoArrayHashMap(u32, usize).init(allocator);
601 try enum_map.ensureTotalCapacity(enumerants.len);627 try enum_map.ensureTotalCapacity(enumerants.len);
602628
603 var aliases = std.ArrayList(struct { enumerant: usize, alias: usize }).init(a);629 var aliases = std.ArrayList(struct { enumerant: usize, alias: usize }).init(allocator);
604 try aliases.ensureTotalCapacity(enumerants.len);630 try aliases.ensureTotalCapacity(enumerants.len);
605631
606 for (enumerants, 0..) |enumerant, i| {632 for (enumerants, 0..) |enumerant, i| {
607 try writer.context.flush();
608 const value: u31 = switch (enumerant.value) {633 const value: u31 = switch (enumerant.value) {
609 .int => |value| value,634 .int => |value| value,
610 // Some extensions declare ints as string635 // Some extensions declare ints as string
...@@ -632,25 +657,25 @@ fn renderValueEnum(...@@ -632,25 +657,25 @@ fn renderValueEnum(
632657
633 const enum_indices = enum_map.values();658 const enum_indices = enum_map.values();
634659
635 try writer.print("pub const {} = enum(u32) {{\n", .{std.zig.fmtId(enumeration.kind)});660 try writer.print("pub const {f} = enum(u32) {{\n", .{std.zig.fmtId(enumeration.kind)});
636661
637 for (enum_indices) |i| {662 for (enum_indices) |i| {
638 const enumerant = enumerants[i];663 const enumerant = enumerants[i];
639 // if (enumerant.value != .int) return error.InvalidRegistry;664 // if (enumerant.value != .int) return error.InvalidRegistry;
640665
641 switch (enumerant.value) {666 switch (enumerant.value) {
642 .int => |value| try writer.print("{p} = {},\n", .{ std.zig.fmtId(enumerant.enumerant), value }),667 .int => |value| try writer.print("{f} = {},\n", .{ formatId(enumerant.enumerant), value }),
643 .bitflag => |value| try writer.print("{p} = {s},\n", .{ std.zig.fmtId(enumerant.enumerant), value }),668 .bitflag => |value| try writer.print("{f} = {s},\n", .{ formatId(enumerant.enumerant), value }),
644 }669 }
645 }670 }
646671
647 try writer.writeByte('\n');672 try writer.writeByte('\n');
648673
649 for (aliases.items) |alias| {674 for (aliases.items) |alias| {
650 try writer.print("pub const {} = {}.{p_};\n", .{675 try writer.print("pub const {f} = {f}.{f};\n", .{
651 std.zig.fmtId(enumerants[alias.enumerant].enumerant),676 formatId(enumerants[alias.enumerant].enumerant),
652 std.zig.fmtId(enumeration.kind),677 std.zig.fmtId(enumeration.kind),
653 std.zig.fmtId(enumerants[alias.alias].enumerant),678 formatId(enumerants[alias.alias].enumerant),
654 });679 });
655 }680 }
656681
...@@ -659,11 +684,11 @@ fn renderValueEnum(...@@ -659,11 +684,11 @@ fn renderValueEnum(
659 return;684 return;
660 }685 }
661686
662 try writer.print("\npub const Extended = union({}) {{\n", .{std.zig.fmtId(enumeration.kind)});687 try writer.print("\npub const Extended = union({f}) {{\n", .{std.zig.fmtId(enumeration.kind)});
663688
664 for (enum_indices) |i| {689 for (enum_indices) |i| {
665 const enumerant = enumerants[i];690 const enumerant = enumerants[i];
666 try renderOperand(writer, .@"union", enumerant.enumerant, enumerant.parameters, extended_structs);691 try renderOperand(writer, .@"union", enumerant.enumerant, enumerant.parameters, extended_structs, true);
667 }692 }
668693
669 try writer.writeAll("};\n};\n");694 try writer.writeAll("};\n};\n");
...@@ -671,16 +696,15 @@ fn renderValueEnum(...@@ -671,16 +696,15 @@ fn renderValueEnum(
671696
672fn renderBitEnum(697fn renderBitEnum(
673 writer: anytype,698 writer: anytype,
674 a: Allocator,
675 enumeration: OperandKind,699 enumeration: OperandKind,
676 extended_structs: ExtendedStructSet,700 extended_structs: ExtendedStructSet,
677) !void {701) !void {
678 try writer.print("pub const {} = packed struct {{\n", .{std.zig.fmtId(enumeration.kind)});702 try writer.print("pub const {f} = packed struct {{\n", .{std.zig.fmtId(enumeration.kind)});
679703
680 var flags_by_bitpos = [_]?usize{null} ** 32;704 var flags_by_bitpos = [_]?usize{null} ** 32;
681 const enumerants = enumeration.enumerants orelse return error.InvalidRegistry;705 const enumerants = enumeration.enumerants orelse return error.InvalidRegistry;
682706
683 var aliases = std.ArrayList(struct { flag: usize, alias: u5 }).init(a);707 var aliases = std.ArrayList(struct { flag: usize, alias: u5 }).init(allocator);
684 try aliases.ensureTotalCapacity(enumerants.len);708 try aliases.ensureTotalCapacity(enumerants.len);
685709
686 for (enumerants, 0..) |enumerant, i| {710 for (enumerants, 0..) |enumerant, i| {
...@@ -715,7 +739,7 @@ fn renderBitEnum(...@@ -715,7 +739,7 @@ fn renderBitEnum(
715739
716 for (flags_by_bitpos, 0..) |maybe_flag_index, bitpos| {740 for (flags_by_bitpos, 0..) |maybe_flag_index, bitpos| {
717 if (maybe_flag_index) |flag_index| {741 if (maybe_flag_index) |flag_index| {
718 try writer.print("{p_}", .{std.zig.fmtId(enumerants[flag_index].enumerant)});742 try writer.print("{f}", .{formatId(enumerants[flag_index].enumerant)});
719 } else {743 } else {
720 try writer.print("_reserved_bit_{}", .{bitpos});744 try writer.print("_reserved_bit_{}", .{bitpos});
721 }745 }
...@@ -726,10 +750,10 @@ fn renderBitEnum(...@@ -726,10 +750,10 @@ fn renderBitEnum(
726 try writer.writeByte('\n');750 try writer.writeByte('\n');
727751
728 for (aliases.items) |alias| {752 for (aliases.items) |alias| {
729 try writer.print("pub const {}: {} = .{{.{p_} = true}};\n", .{753 try writer.print("pub const {f}: {f} = .{{.{f} = true}};\n", .{
730 std.zig.fmtId(enumerants[alias.flag].enumerant),754 formatId(enumerants[alias.flag].enumerant),
731 std.zig.fmtId(enumeration.kind),755 std.zig.fmtId(enumeration.kind),
732 std.zig.fmtId(enumerants[flags_by_bitpos[alias.alias].?].enumerant),756 formatId(enumerants[flags_by_bitpos[alias.alias].?].enumerant),
733 });757 });
734 }758 }
735759
...@@ -747,7 +771,7 @@ fn renderBitEnum(...@@ -747,7 +771,7 @@ fn renderBitEnum(
747 };771 };
748 const enumerant = enumerants[flag_index];772 const enumerant = enumerants[flag_index];
749773
750 try renderOperand(writer, .mask, enumerant.enumerant, enumerant.parameters, extended_structs);774 try renderOperand(writer, .mask, enumerant.enumerant, enumerant.parameters, extended_structs, true);
751 }775 }
752776
753 try writer.writeAll("};\n};\n");777 try writer.writeAll("};\n};\n");
...@@ -763,11 +787,18 @@ fn renderOperand(...@@ -763,11 +787,18 @@ fn renderOperand(
763 field_name: []const u8,787 field_name: []const u8,
764 parameters: []const Operand,788 parameters: []const Operand,
765 extended_structs: ExtendedStructSet,789 extended_structs: ExtendedStructSet,
790 snake_case: bool,
766) !void {791) !void {
767 if (kind == .instruction) {792 if (kind == .instruction) {
768 try writer.writeByte('.');793 try writer.writeByte('.');
769 }794 }
770 try writer.print("{}", .{std.zig.fmtId(field_name)});795
796 if (snake_case) {
797 try writer.print("{f}", .{formatId(field_name)});
798 } else {
799 try writer.print("{f}", .{std.zig.fmtId(field_name)});
800 }
801
771 if (parameters.len == 0) {802 if (parameters.len == 0) {
772 switch (kind) {803 switch (kind) {
773 .@"union" => try writer.writeAll(",\n"),804 .@"union" => try writer.writeAll(",\n"),
...@@ -787,7 +818,7 @@ fn renderOperand(...@@ -787,7 +818,7 @@ fn renderOperand(
787 try writer.writeByte('?');818 try writer.writeByte('?');
788 }819 }
789820
790 try writer.writeAll("struct{");821 try writer.writeAll("struct {");
791822
792 for (parameters, 0..) |param, j| {823 for (parameters, 0..) |param, j| {
793 if (j != 0) {824 if (j != 0) {
...@@ -804,7 +835,11 @@ fn renderOperand(...@@ -804,7 +835,11 @@ fn renderOperand(
804 }835 }
805 }836 }
806837
807 try writer.print("{}", .{std.zig.fmtId(param.kind)});838 if (std.mem.startsWith(u8, param.kind, "Id")) {
839 _ = try writer.write("Id");
840 } else {
841 try writer.print("{f}", .{std.zig.fmtId(param.kind)});
842 }
808843
809 if (extended_structs.contains(param.kind)) {844 if (extended_structs.contains(param.kind)) {
810 try writer.writeAll(".Extended");845 try writer.writeAll(".Extended");
...@@ -830,49 +865,24 @@ fn renderOperand(...@@ -830,49 +865,24 @@ fn renderOperand(
830fn renderFieldName(writer: anytype, operands: []const Operand, field_index: usize) !void {865fn renderFieldName(writer: anytype, operands: []const Operand, field_index: usize) !void {
831 const operand = operands[field_index];866 const operand = operands[field_index];
832867
833 // Should be enough for all names - adjust as needed.
834 var name_backing_buffer: [64]u8 = undefined;
835 var name_buffer = std.ArrayListUnmanaged(u8).initBuffer(&name_backing_buffer);
836
837 derive_from_kind: {868 derive_from_kind: {
838 // Operand names are often in the json encoded as "'Name'" (with two sets of quotes).869 // Operand names are often in the json encoded as "'Name'" (with two sets of quotes).
839 // Additionally, some operands have ~ in them at the end (D~ref~).870 // Additionally, some operands have ~ in them at the end (D~ref~).
840 const name = std.mem.trim(u8, operand.name, "'~");871 const name = std.mem.trim(u8, operand.name, "'~");
841 if (name.len == 0) {872 if (name.len == 0) break :derive_from_kind;
842 break :derive_from_kind;
843 }
844873
845 // Some names have weird characters in them (like newlines) - skip any such ones.
846 // Use the same loop to transform to snake-case.
847 for (name) |c| {874 for (name) |c| {
848 switch (c) {875 switch (c) {
849 'a'...'z', '0'...'9' => name_buffer.appendAssumeCapacity(c),876 'a'...'z', '0'...'9', 'A'...'Z', ' ', '~' => continue,
850 'A'...'Z' => name_buffer.appendAssumeCapacity(std.ascii.toLower(c)),
851 ' ', '~' => name_buffer.appendAssumeCapacity('_'),
852 else => break :derive_from_kind,877 else => break :derive_from_kind,
853 }878 }
854 }879 }
855880
856 // Assume there are no duplicate 'name' fields.881 try writer.print("{f}", .{formatId(name)});
857 try writer.print("{p_}", .{std.zig.fmtId(name_buffer.items)});
858 return;882 return;
859 }883 }
860884
861 // Translate to snake case.885 try writer.print("{f}", .{formatId(operand.kind)});
862 name_buffer.items.len = 0;
863 for (operand.kind, 0..) |c, i| {
864 switch (c) {
865 'a'...'z', '0'...'9' => name_buffer.appendAssumeCapacity(c),
866 'A'...'Z' => if (i > 0 and std.ascii.isLower(operand.kind[i - 1])) {
867 name_buffer.appendSliceAssumeCapacity(&[_]u8{ '_', std.ascii.toLower(c) });
868 } else {
869 name_buffer.appendAssumeCapacity(std.ascii.toLower(c));
870 },
871 else => unreachable, // Assume that the name is valid C-syntax (and contains no underscores).
872 }
873 }
874
875 try writer.print("{p_}", .{std.zig.fmtId(name_buffer.items)});
876886
877 // For fields derived from type name, there could be any amount.887 // For fields derived from type name, there could be any amount.
878 // Simply check against all other fields, and if another similar one exists, add a number.888 // Simply check against all other fields, and if another similar one exists, add a number.
tools/migrate_langref.zig+1-1
...@@ -7,7 +7,7 @@ const mem = std.mem;...@@ -7,7 +7,7 @@ const mem = std.mem;
7const testing = std.testing;7const testing = std.testing;
8const Allocator = std.mem.Allocator;8const Allocator = std.mem.Allocator;
9const max_doc_file_size = 10 * 1024 * 1024;9const max_doc_file_size = 10 * 1024 * 1024;
10const fatal = std.zig.fatal;10const fatal = std.process.fatal;
1111
12pub fn main() !void {12pub fn main() !void {
13 var arena_instance = std.heap.ArenaAllocator.init(std.heap.page_allocator);13 var arena_instance = std.heap.ArenaAllocator.init(std.heap.page_allocator);
tools/spirv/grammar.zig+4
...@@ -37,9 +37,11 @@ pub const InstructionPrintingClass = struct {...@@ -37,9 +37,11 @@ pub const InstructionPrintingClass = struct {
37pub const Instruction = struct {37pub const Instruction = struct {
38 opname: []const u8,38 opname: []const u8,
39 class: ?[]const u8 = null, // Note: Only available in the core registry.39 class: ?[]const u8 = null, // Note: Only available in the core registry.
40 aliases: [][]const u8 = &[_][]const u8{},
40 opcode: u32,41 opcode: u32,
41 operands: []Operand = &[_]Operand{},42 operands: []Operand = &[_]Operand{},
42 capabilities: [][]const u8 = &[_][]const u8{},43 capabilities: [][]const u8 = &[_][]const u8{},
44 provisional: bool = false,
43 // DebugModuleINTEL has this...45 // DebugModuleINTEL has this...
44 capability: ?[]const u8 = null,46 capability: ?[]const u8 = null,
45 extensions: [][]const u8 = &[_][]const u8{},47 extensions: [][]const u8 = &[_][]const u8{},
...@@ -81,6 +83,7 @@ pub const OperandKind = struct {...@@ -81,6 +83,7 @@ pub const OperandKind = struct {
8183
82pub const Enumerant = struct {84pub const Enumerant = struct {
83 enumerant: []const u8,85 enumerant: []const u8,
86 aliases: [][]const u8 = &[_][]const u8{},
84 value: union(enum) {87 value: union(enum) {
85 bitflag: []const u8, // Hexadecimal representation of the value88 bitflag: []const u8, // Hexadecimal representation of the value
86 int: u31,89 int: u31,
...@@ -100,6 +103,7 @@ pub const Enumerant = struct {...@@ -100,6 +103,7 @@ pub const Enumerant = struct {
100 pub const jsonStringify = @compileError("not supported");103 pub const jsonStringify = @compileError("not supported");
101 },104 },
102 capabilities: [][]const u8 = &[_][]const u8{},105 capabilities: [][]const u8 = &[_][]const u8{},
106 provisional: bool = false,
103 /// Valid for .ValueEnum and .BitEnum107 /// Valid for .ValueEnum and .BitEnum
104 extensions: [][]const u8 = &[_][]const u8{},108 extensions: [][]const u8 = &[_][]const u8{},
105 /// `quantifier` will always be `null`.109 /// `quantifier` will always be `null`.