@@ -234,7 +234,7 @@ struct RayDispatchGlobalData
234234            } rt_data_info;
235235            //  In addition to the dword of padding to align `common`, we also
236236            //  add 8 dwords so Xe and Xe3 both have the same RTGlobals size.
237-             uint32_t  paddingBits[1 +6 ];          //  padding
237+             uint32_t  paddingBits[1 +8 ];          //  padding
238238
239239            //  HW doesn't read anything below this point.
240240            RayDispatchGlobalDataCommon common;
@@ -286,7 +286,7 @@ struct RayDispatchGlobalData
286286            uint32_t  pad_mbz : 31 ;
287287            uint64_t  hitGroupBasePtr;           //  base pointer of hit group shader record array (16-bytes alignment)
288288            uint64_t  missShaderBasePtr;         //  base pointer of miss shader record array (8-bytes alignment)
289-             uint32_t  _align_mbz[2 ];             //  pad hardware section to 64 bytes
289+             uint32_t  _align_mbz[4 ];             //  pad hardware section to 64 bytes
290290
291291            //  HW doesn't read anything below this point.
292292            RayDispatchGlobalDataCommon common;
@@ -303,7 +303,10 @@ constexpr uint32_t RTGlobalsAlign = 256;
303303constexpr  uint32_t  RTStackAlign = 128 ;
304304static_assert (RTStackAlign % RayDispatchGlobalData::StackChunkSize == 0 , " no?" 
305305
306- static_assert (sizeof (RayDispatchGlobalData) == 184 , " unexpected size?" 
306+ static_assert ((sizeof (RayDispatchGlobalData::RT::Xe) - sizeof (RayDispatchGlobalData::RayDispatchGlobalDataCommon)) % 64  == 0 , " Unexpected GlobalData alignment" 
307+ static_assert ((sizeof (RayDispatchGlobalData::RT::Xe3) - sizeof (RayDispatchGlobalData::RayDispatchGlobalDataCommon)) % 64  == 0 , " Unexpected GlobalData alignment" 
308+ 
309+ static_assert (sizeof (RayDispatchGlobalData) == 192 , " unexpected size?" 
307310static_assert (sizeof (RayDispatchGlobalData::RT::Xe) == sizeof (RayDispatchGlobalData), " unexpected size?" 
308311static_assert (sizeof (RayDispatchGlobalData::RT::Xe3) == sizeof (RayDispatchGlobalData), " unexpected size?" 
309312static_assert (offsetof(RayDispatchGlobalData::RT::Xe, common) == offsetof(RayDispatchGlobalData::RT::Xe3, common), " unexpected size?" 
0 commit comments