@@ -2032,6 +2032,9 @@ pub const Inst = struct {
2032
2032
/// `operand` is payload index to `Reify`.
2033
2033
/// `small` contains `NameStrategy`.
2034
2034
reify ,
2035
+ /// Implement builtin `@SpirvType`.
2036
+ /// `operand` is payload index to `Reify`.
2037
+ reify_spirv ,
2035
2038
/// Implements the `@asyncCall` builtin.
2036
2039
/// `operand` is payload index to `AsyncCall`.
2037
2040
builtin_async_call ,
@@ -3004,7 +3007,7 @@ pub const Inst = struct {
3004
3007
flags : Flags ,
3005
3008
callee : Ref ,
3006
3009
3007
- pub const Flags = packed struct {
3010
+ pub const Flags = packed struct ( u32 ) {
3008
3011
/// std.builtin.CallModifier in packed form
3009
3012
pub const PackedModifier = u3 ;
3010
3013
pub const PackedArgsLen = u27 ;
@@ -3015,8 +3018,6 @@ pub const Inst = struct {
3015
3018
args_len : PackedArgsLen ,
3016
3019
3017
3020
comptime {
3018
- if (@sizeOf (Flags ) != 4 or @bitSizeOf (Flags ) != 32 )
3019
- @compileError ("Layout of Call.Flags needs to be updated!" );
3020
3021
if (@bitSizeOf (std .builtin .CallModifier ) != @bitSizeOf (PackedModifier ))
3021
3022
@compileError ("Call.Flags.PackedModifier needs to be updated!" );
3022
3023
}
@@ -3053,15 +3054,10 @@ pub const Inst = struct {
3053
3054
callee : Ref ,
3054
3055
args : Ref ,
3055
3056
3056
- pub const Flags = packed struct {
3057
+ pub const Flags = packed struct ( u32 ) {
3057
3058
is_nosuspend : bool ,
3058
3059
ensure_result_used : bool ,
3059
3060
_ : u30 = undefined ,
3060
-
3061
- comptime {
3062
- if (@sizeOf (Flags ) != 4 or @bitSizeOf (Flags ) != 32 )
3063
- @compileError ("Layout of BuiltinCall.Flags needs to be updated!" );
3064
- }
3065
3061
};
3066
3062
};
3067
3063
@@ -3471,6 +3467,7 @@ pub const Inst = struct {
3471
3467
export_options ,
3472
3468
extern_options ,
3473
3469
type_info ,
3470
+ spirv_type_info ,
3474
3471
branch_hint ,
3475
3472
// Values
3476
3473
calling_convention_c ,
@@ -4379,8 +4376,8 @@ fn findTrackableInner(
4379
4376
try zir .findTrackableBody (gpa , contents , defers , body );
4380
4377
},
4381
4378
4382
- // Reifications and opaque declarations need tracking, but have no body.
4383
- .reify , .opaque_decl = > return contents .other .append (gpa , inst ),
4379
+ // Reifications and opaque declarations need tracking, but have no body..
4380
+ .reify , .reify_spirv , . opaque_decl = > return contents .other .append (gpa , inst ),
4384
4381
4385
4382
// Struct declarations need tracking and have bodies.
4386
4383
.struct_decl = > {
@@ -5127,6 +5124,7 @@ pub fn assertTrackable(zir: Zir, inst_idx: Zir.Inst.Index) void {
5127
5124
.enum_decl ,
5128
5125
.opaque_decl ,
5129
5126
.reify ,
5127
+ .reify_spirv ,
5130
5128
= > {}, // tracked in order, as the owner instructions of explicit container types
5131
5129
else = > unreachable , // assertion failure; not trackable
5132
5130
},
0 commit comments