authorgravatar for topolarity@tapscott.meCody Tapscott <topolarity@tapscott.me> 2022-10-21 20:16:00-07:00
committergravatar for topolarity@tapscott.meCody Tapscott <topolarity@tapscott.me> 2022-10-21 20:16:00-07:00
log94945864b9d8ffa7b707432fb877ae42e383db68
tree3bafa236b08b990e5911953e5ad7f023820dfea5
parentf0e66ac4d0e6347bf1b5a00b309fafb5da84191b

Type.zig: Add `nvcl`/`cuda` CType definitions


1 files changed, 12 insertions(+), 2 deletions(-)

src/type.zig+12-2
...@@ -6862,6 +6862,18 @@ pub const CType = enum {...@@ -6862,6 +6862,18 @@ pub const CType = enum {
6862 },6862 },
6863 },6863 },
68646864
6865 .nvcl, .cuda => switch (self) {
6866 .short, .ushort => return 16,
6867 .int, .uint, .float => return 32,
6868 .long, .ulong => switch (target.cpu.arch) {
6869 .nvptx => return 32,
6870 .nvptx64 => return 64,
6871 else => return 64,
6872 },
6873 .longlong, .ulonglong, .double => return 64,
6874 .longdouble => return 64,
6875 },
6876
6865 .amdhsa, .amdpal => switch (self) {6877 .amdhsa, .amdpal => switch (self) {
6866 .short, .ushort => return 16,6878 .short, .ushort => return 16,
6867 .int, .uint, .float => return 32,6879 .int, .uint, .float => return 32,
...@@ -6876,8 +6888,6 @@ pub const CType = enum {...@@ -6876,8 +6888,6 @@ pub const CType = enum {
6876 .rtems,6888 .rtems,
6877 .nacl,6889 .nacl,
6878 .aix,6890 .aix,
6879 .cuda,
6880 .nvcl,
6881 .ps4,6891 .ps4,
6882 .ps5,6892 .ps5,
6883 .elfiamcu,6893 .elfiamcu,