@@ -2032,6 +2032,9 @@ pub const Inst = struct {
20322032 /// `operand` is payload index to `Reify`.
20332033 /// `small` contains `NameStrategy`.
20342034 reify ,
2035+ /// Implement builtin `@SpirvType`.
2036+ /// `operand` is payload index to `Reify`.
2037+ reify_spirv ,
20352038 /// Implements the `@asyncCall` builtin.
20362039 /// `operand` is payload index to `AsyncCall`.
20372040 builtin_async_call ,
@@ -3004,7 +3007,7 @@ pub const Inst = struct {
30043007 flags : Flags ,
30053008 callee : Ref ,
30063009
3007- pub const Flags = packed struct {
3010+ pub const Flags = packed struct ( u32 ) {
30083011 /// std.builtin.CallModifier in packed form
30093012 pub const PackedModifier = u3 ;
30103013 pub const PackedArgsLen = u27 ;
@@ -3015,8 +3018,6 @@ pub const Inst = struct {
30153018 args_len : PackedArgsLen ,
30163019
30173020 comptime {
3018- if (@sizeOf (Flags ) != 4 or @bitSizeOf (Flags ) != 32 )
3019- @compileError ("Layout of Call.Flags needs to be updated!" );
30203021 if (@bitSizeOf (std .builtin .CallModifier ) != @bitSizeOf (PackedModifier ))
30213022 @compileError ("Call.Flags.PackedModifier needs to be updated!" );
30223023 }
@@ -3053,15 +3054,10 @@ pub const Inst = struct {
30533054 callee : Ref ,
30543055 args : Ref ,
30553056
3056- pub const Flags = packed struct {
3057+ pub const Flags = packed struct ( u32 ) {
30573058 is_nosuspend : bool ,
30583059 ensure_result_used : bool ,
30593060 _ : 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- }
30653061 };
30663062 };
30673063
@@ -3471,6 +3467,7 @@ pub const Inst = struct {
34713467 export_options ,
34723468 extern_options ,
34733469 type_info ,
3470+ spirv_type_info ,
34743471 branch_hint ,
34753472 // Values
34763473 calling_convention_c ,
@@ -4379,8 +4376,8 @@ fn findTrackableInner(
43794376 try zir .findTrackableBody (gpa , contents , defers , body );
43804377 },
43814378
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 ),
43844381
43854382 // Struct declarations need tracking and have bodies.
43864383 .struct_decl = > {
@@ -5127,6 +5124,7 @@ pub fn assertTrackable(zir: Zir, inst_idx: Zir.Inst.Index) void {
51275124 .enum_decl ,
51285125 .opaque_decl ,
51295126 .reify ,
5127+ .reify_spirv ,
51305128 = > {}, // tracked in order, as the owner instructions of explicit container types
51315129 else = > unreachable , // assertion failure; not trackable
51325130 },
0 commit comments