//
// Generated by Microsoft (R) HLSL Shader Compiler 10.1
//
//
// Buffer Definitions: 
//
// cbuffer XeEDRAMLoadStoreConstants
// {
//
//   uint4 xe_edram_load_store_constants;// Offset:    0 Size:    16
//   uint xe_edram_base_samples_2x_depth_pitch;// Offset:   16 Size:     4
//
// }
//
//
// Resource Bindings:
//
// Name                                 Type  Format         Dim      ID      HLSL Bind  Count
// ------------------------------ ---------- ------- ----------- ------- -------------- ------
// xe_edram_load_store_source        texture    byte         r/o      T0             t0      1 
// xe_edram_load_store_dest              UAV    byte         r/w      U0             u0      1 
// XeEDRAMLoadStoreConstants         cbuffer      NA          NA     CB0            cb0      1 
//
//
//
// Input signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// no Input
//
// Output signature:
//
// Name                 Index   Mask Register SysValue  Format   Used
// -------------------- ----- ------ -------- -------- ------- ------
// no Output
cs_5_1
dcl_globalFlags refactoringAllowed
dcl_constantbuffer CB0[0:0][2], immediateIndexed, space=0
dcl_resource_raw T0[0:0], space=0
dcl_uav_raw U0[0:0], space=0
dcl_input vThreadGroupID.xy
dcl_input vThreadIDInGroup.xy
dcl_input vThreadID.xy
dcl_temps 13
dcl_thread_group 40, 16, 1
ishl r0.x, vThreadIDInGroup.x, l(1)
and r0.yz, CB0[0][1].xxxx, l(0, 0x00008000, 2047, 0)
if_nz r0.y
  ult r0.y, vThreadIDInGroup.x, l(20)
  uge r0.w, vThreadIDInGroup.x, l(20)
  and r0.yw, r0.yyyw, l(0, 40, 0, -40)
  iadd r0.y, r0.w, r0.y
  iadd r0.x, r0.y, r0.x
endif 
ushr r0.y, CB0[0][1].x, l(16)
imad r0.y, vThreadGroupID.y, r0.y, r0.z
iadd r0.y, r0.y, vThreadGroupID.x
imul null, r0.z, vThreadIDInGroup.y, l(320)
imad r0.y, r0.y, l(5120), r0.z
ishl r0.x, r0.x, l(2)
iadd r0.x, r0.x, r0.y
ubfe r0.yzw, l(0, 1, 1, 1), l(0, 13, 12, 11), CB0[0][1].xxxx
ishl r0.y, r0.y, l(1)
ishl r0.x, r0.x, r0.y
ld_raw r1.xyzw, r0.x, T0[0].wxyz
iadd r0.x, r0.x, l(16)
ld_raw r2.xyzw, r0.x, T0[0].yxzw
if_nz r0.z
  mov r3.x, r2.y
  mov r4.x, r2.z
  mov r5.x, r1.z
else 
  mov r3.x, r1.z
  mov r4.x, r1.x
  mov r5.x, r2.y
  mov r1.x, r2.z
endif 
not r0.x, r0.w
and r0.xy, r0.xwxx, vThreadID.yyyy
imad r0.x, r0.x, l(2), r0.y
ishl r0.y, vThreadID.x, l(5)
imad r0.x, r0.x, CB0[0][0].y, r0.y
ushr r6.xyzw, r1.yyyw, l(10, 20, 30, 30)
mov r7.x, r1.y
mov r7.yz, r6.xxyx
and r8.xyz, r7.xyzx, l(1023, 1023, 1023, 0)
and r9.xyz, r7.xyzx, l(127, 127, 127, 0)
ubfe r10.xyz, l(3, 3, 3, 0), l(7, 7, 7, 0), r7.xyzx
firstbit_hi r11.xyz, r9.xyzx
iadd r11.xyz, r11.xyzx, l(-24, -24, -24, 0)
movc r11.xyz, r9.xyzx, r11.xyzx, l(8,8,8,0)
iadd r12.xyz, -r11.xyzx, l(1, 1, 1, 0)
movc r12.xyz, r10.xyzx, r10.xyzx, r12.xyzx
bfi r7.xyz, l(7, 7, 7, 0), r11.xyzx, r7.xyzx, l(0, 0, 0, 0)
and r7.xyz, r7.xyzx, l(127, 127, 127, 0)
movc r7.xyz, r10.xyzx, r9.xyzx, r7.xyzx
ishl r9.xyz, r12.xyzx, l(23, 23, 23, 0)
iadd r9.xyz, r9.xyzx, l(0x3e000000, 0x3e000000, 0x3e000000, 0)
ishl r7.xyz, r7.xyzx, l(16, 16, 16, 0)
iadd r7.xyz, r9.xyzx, r7.xyzx
movc r7.xyz, r8.xyzx, r7.xyzx, l(0,0,0,0)
utof r0.yz, r6.zzwz
mul r0.yz, r0.yyzy, l(0.000000, 0.333333, 0.333333, 0.000000)
f32tof16 r6.xyz, r7.xyzx
f32tof16 r6.w, r0.y
ushr r3.yzw, r3.xxxx, l(0, 10, 20, 30)
and r7.xyz, r3.xyzx, l(1023, 1023, 1023, 0)
and r8.xyz, r3.xyzx, l(127, 127, 127, 0)
ubfe r9.xyz, l(3, 3, 3, 0), l(7, 7, 7, 0), r3.xyzx
firstbit_hi r10.xyz, r8.xyzx
iadd r10.xyz, r10.xyzx, l(-24, -24, -24, 0)
movc r10.xyz, r8.xyzx, r10.xyzx, l(8,8,8,0)
iadd r11.xyz, -r10.xyzx, l(1, 1, 1, 0)
movc r11.xyz, r9.xyzx, r9.xyzx, r11.xyzx
bfi r3.xyz, l(7, 7, 7, 0), r10.xyzx, r3.xyzx, l(0, 0, 0, 0)
and r3.xyz, r3.xyzx, l(127, 127, 127, 0)
movc r3.xyz, r9.xyzx, r8.xyzx, r3.xyzx
ishl r8.xyz, r11.xyzx, l(23, 23, 23, 0)
iadd r8.xyz, r8.xyzx, l(0x3e000000, 0x3e000000, 0x3e000000, 0)
ishl r3.xyz, r3.xyzx, l(16, 16, 16, 0)
iadd r3.xyz, r8.xyzx, r3.xyzx
movc r3.xyz, r7.xyzx, r3.xyzx, l(0,0,0,0)
utof r0.y, r3.w
mul r0.y, r0.y, l(0.333333)
f32tof16 r3.xzw, r3.yyxz
f32tof16 r3.y, r0.y
mov r7.xy, r6.ywyy
mov r7.zw, r3.xxxy
mov r3.xy, r6.xzxx
imad r3.xyzw, r7.xyzw, l(0x00010000, 0x00010000, 0x00010000, 0x00010000), r3.xyzw
store_raw U0[0].xyzw, r0.x, r3.xyzw
ushr r5.yzw, r5.xxxx, l(0, 10, 20, 30)
and r3.xyz, r5.xyzx, l(1023, 1023, 1023, 0)
and r6.xyz, r5.xyzx, l(127, 127, 127, 0)
ubfe r7.xyz, l(3, 3, 3, 0), l(7, 7, 7, 0), r5.xyzx
firstbit_hi r8.xyz, r6.xyzx
iadd r8.xyz, r8.xyzx, l(-24, -24, -24, 0)
movc r8.xyz, r6.xyzx, r8.xyzx, l(8,8,8,0)
iadd r9.xyz, -r8.xyzx, l(1, 1, 1, 0)
movc r9.xyz, r7.xyzx, r7.xyzx, r9.xyzx
bfi r5.xyz, l(7, 7, 7, 0), r8.xyzx, r5.xyzx, l(0, 0, 0, 0)
and r5.xyz, r5.xyzx, l(127, 127, 127, 0)
movc r5.xyz, r7.xyzx, r6.xyzx, r5.xyzx
ishl r6.xyz, r9.xyzx, l(23, 23, 23, 0)
iadd r6.xyz, r6.xyzx, l(0x3e000000, 0x3e000000, 0x3e000000, 0)
ishl r5.xyz, r5.xyzx, l(16, 16, 16, 0)
iadd r5.xyz, r6.xyzx, r5.xyzx
movc r3.xyz, r3.xyzx, r5.xyzx, l(0,0,0,0)
utof r0.y, r5.w
mul r0.y, r0.y, l(0.333333)
f32tof16 r3.xyz, r3.xyzx
f32tof16 r3.w, r0.y
ushr r5.xyzw, r2.xxxw, l(10, 20, 30, 30)
mov r2.yz, r5.xxyx
and r6.xyz, r2.xyzx, l(1023, 1023, 1023, 0)
and r7.xyz, r2.xyzx, l(127, 127, 127, 0)
ubfe r8.xyz, l(3, 3, 3, 0), l(7, 7, 7, 0), r2.xyzx
firstbit_hi r9.xyz, r7.xyzx
iadd r9.xyz, r9.xyzx, l(-24, -24, -24, 0)
movc r9.xyz, r7.xyzx, r9.xyzx, l(8,8,8,0)
iadd r10.xyz, -r9.xyzx, l(1, 1, 1, 0)
movc r10.xyz, r8.xyzx, r8.xyzx, r10.xyzx
bfi r9.xyz, l(7, 7, 7, 0), r9.xyzx, r2.xyzx, l(0, 0, 0, 0)
and r9.xyz, r9.xyzx, l(127, 127, 127, 0)
movc r7.xyz, r8.xyzx, r7.xyzx, r9.xyzx
ishl r8.xyz, r10.xyzx, l(23, 23, 23, 0)
iadd r8.xyz, r8.xyzx, l(0x3e000000, 0x3e000000, 0x3e000000, 0)
ishl r7.xyz, r7.xyzx, l(16, 16, 16, 0)
iadd r7.xyz, r8.xyzx, r7.xyzx
movc r6.xyz, r6.xyzx, r7.xyzx, l(0,0,0,0)
utof r5.xy, r5.zwzz
mul r5.xy, r5.xyxx, l(0.333333, 0.333333, 0.000000, 0.000000)
f32tof16 r6.xzw, r6.yyxz
f32tof16 r6.y, r5.x
mov r7.xy, r3.ywyy
mov r7.zw, r6.xxxy
mov r6.xy, r3.xzxx
imad r3.xyzw, r7.xyzw, l(0x00010000, 0x00010000, 0x00010000, 0x00010000), r6.xyzw
iadd r0.y, r0.x, l(16)
store_raw U0[0].xyzw, r0.y, r3.xyzw
ishl r0.y, l(1), r0.w
imad r0.x, r0.y, CB0[0][0].y, r0.x
ushr r1.yz, r1.wwww, l(0, 10, 20, 0)
and r3.xyz, r1.wyzw, l(1023, 1023, 1023, 0)
and r5.xzw, r1.wwyz, l(127, 0, 127, 127)
ubfe r6.xyz, l(3, 3, 3, 0), l(7, 7, 7, 0), r1.wyzw
firstbit_hi r7.xyz, r5.xzwx
iadd r7.xyz, r7.xyzx, l(-24, -24, -24, 0)
movc r7.xyz, r5.xzwx, r7.xyzx, l(8,8,8,0)
iadd r8.xyz, -r7.xyzx, l(1, 1, 1, 0)
movc r8.xyz, r6.xyzx, r6.xyzx, r8.xyzx
bfi r7.xyz, l(7, 7, 7, 0), r7.xyzx, r1.wyzw, l(0, 0, 0, 0)
and r7.xyz, r7.xyzx, l(127, 127, 127, 0)
movc r5.xzw, r6.xxyz, r5.xxzw, r7.xxyz
ishl r6.xyz, r8.xyzx, l(23, 23, 23, 0)
iadd r6.xyz, r6.xyzx, l(0x3e000000, 0x3e000000, 0x3e000000, 0)
ishl r5.xzw, r5.xxzw, l(16, 0, 16, 16)
iadd r5.xzw, r6.xxyz, r5.xxzw
movc r3.xyz, r3.xyzx, r5.xzwx, l(0,0,0,0)
f32tof16 r3.xyz, r3.xyzx
f32tof16 r3.w, r0.z
ushr r4.yzw, r4.xxxx, l(0, 10, 20, 30)
and r0.yzw, r4.xxyz, l(0, 1023, 1023, 1023)
and r5.xzw, r4.xxyz, l(127, 0, 127, 127)
ubfe r6.xyz, l(3, 3, 3, 0), l(7, 7, 7, 0), r4.xyzx
firstbit_hi r7.xyz, r5.xzwx
iadd r7.xyz, r7.xyzx, l(-24, -24, -24, 0)
movc r7.xyz, r5.xzwx, r7.xyzx, l(8,8,8,0)
iadd r8.xyz, -r7.xyzx, l(1, 1, 1, 0)
movc r8.xyz, r6.xyzx, r6.xyzx, r8.xyzx
bfi r4.xyz, l(7, 7, 7, 0), r7.xyzx, r4.xyzx, l(0, 0, 0, 0)
and r4.xyz, r4.xyzx, l(127, 127, 127, 0)
movc r4.xyz, r6.xyzx, r5.xzwx, r4.xyzx
ishl r5.xzw, r8.xxyz, l(23, 0, 23, 23)
iadd r5.xzw, r5.xxzw, l(0x3e000000, 0, 0x3e000000, 0x3e000000)
ishl r4.xyz, r4.xyzx, l(16, 16, 16, 0)
iadd r4.xyz, r5.xzwx, r4.xyzx
movc r0.yzw, r0.yyzw, r4.xxyz, l(0,0,0,0)
utof r2.z, r4.w
mul r2.z, r2.z, l(0.333333)
f32tof16 r4.xzw, r0.zzyw
f32tof16 r4.y, r2.z
mov r6.xy, r3.ywyy
mov r6.zw, r4.xxxy
mov r4.xy, r3.xzxx
imad r3.xyzw, r6.xyzw, l(0x00010000, 0x00010000, 0x00010000, 0x00010000), r4.xyzw
store_raw U0[0].xyzw, r0.x, r3.xyzw
ushr r1.yzw, r1.xxxx, l(0, 10, 20, 30)
and r0.yzw, r1.xxyz, l(0, 1023, 1023, 1023)
and r3.xyz, r1.xyzx, l(127, 127, 127, 0)
ubfe r4.xyz, l(3, 3, 3, 0), l(7, 7, 7, 0), r1.xyzx
firstbit_hi r5.xzw, r3.xxyz
iadd r5.xzw, r5.xxzw, l(-24, 0, -24, -24)
movc r5.xzw, r3.xxyz, r5.xxzw, l(8,0,8,8)
iadd r6.xyz, -r5.xzwx, l(1, 1, 1, 0)
movc r6.xyz, r4.xyzx, r4.xyzx, r6.xyzx
bfi r1.xyz, l(7, 7, 7, 0), r5.xzwx, r1.xyzx, l(0, 0, 0, 0)
and r1.xyz, r1.xyzx, l(127, 127, 127, 0)
movc r1.xyz, r4.xyzx, r3.xyzx, r1.xyzx
ishl r3.xyz, r6.xyzx, l(23, 23, 23, 0)
iadd r3.xyz, r3.xyzx, l(0x3e000000, 0x3e000000, 0x3e000000, 0)
ishl r1.xyz, r1.xyzx, l(16, 16, 16, 0)
iadd r1.xyz, r3.xyzx, r1.xyzx
movc r0.yzw, r0.yyzw, r1.xxyz, l(0,0,0,0)
utof r1.x, r1.w
mul r1.x, r1.x, l(0.333333)
f32tof16 r3.xyz, r0.yzwy
f32tof16 r3.w, r1.x
ushr r2.xy, r2.wwww, l(20, 10, 0, 0)
and r0.yzw, r2.wwyx, l(0, 1023, 1023, 1023)
and r1.xyz, r2.wyxw, l(127, 127, 127, 0)
ubfe r4.xyz, l(3, 3, 3, 0), l(7, 7, 7, 0), r2.wyxw
firstbit_hi r5.xzw, r1.xxyz
iadd r5.xzw, r5.xxzw, l(-24, 0, -24, -24)
movc r5.xzw, r1.xxyz, r5.xxzw, l(8,0,8,8)
iadd r6.xyz, -r5.xzwx, l(1, 1, 1, 0)
movc r6.xyz, r4.xyzx, r4.xyzx, r6.xyzx
bfi r2.xyz, l(7, 7, 7, 0), r5.xzwx, r2.wyxw, l(0, 0, 0, 0)
and r2.xyz, r2.xyzx, l(127, 127, 127, 0)
movc r1.xyz, r4.xyzx, r1.xyzx, r2.xyzx
ishl r2.xyz, r6.xyzx, l(23, 23, 23, 0)
iadd r2.xyz, r2.xyzx, l(0x3e000000, 0x3e000000, 0x3e000000, 0)
ishl r1.xyz, r1.xyzx, l(16, 16, 16, 0)
iadd r1.xyz, r2.xyzx, r1.xyzx
movc r0.yzw, r0.yyzw, r1.xxyz, l(0,0,0,0)
f32tof16 r1.xzw, r0.zzyw
f32tof16 r1.y, r5.y
mov r2.xy, r3.ywyy
mov r2.zw, r1.xxxy
mov r1.xy, r3.xzxx
imad r1.xyzw, r2.xyzw, l(0x00010000, 0x00010000, 0x00010000, 0x00010000), r1.xyzw
iadd r0.y, r0.x, l(16)
store_raw U0[0].xyzw, r0.y, r1.xyzw
ret 
// Approximately 229 instruction slots used
