mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-01-28 13:05:02 -08:00
vkd3d-shader/spirv: Handle ITOI and UTOU in spirv_compiler_map_alu_instruction().
These instructions perform integer casts to/from 64 bits.
This commit is contained in:
parent
1eaa7d1dbe
commit
812f01c2e2
Notes:
Alexandre Julliard
2024-01-02 23:08:54 +01:00
Approved-by: Giovanni Mascellani (@giomasce) Approved-by: Henri Verbeet (@hverbeet) Approved-by: Alexandre Julliard (@julliard) Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/490
@ -6697,12 +6697,14 @@ static SpvOp spirv_compiler_map_alu_instruction(const struct vkd3d_shader_instru
|
||||
{VKD3DSIH_ISHR, SpvOpShiftRightArithmetic},
|
||||
{VKD3DSIH_ITOD, SpvOpConvertSToF},
|
||||
{VKD3DSIH_ITOF, SpvOpConvertSToF},
|
||||
{VKD3DSIH_ITOI, SpvOpSConvert},
|
||||
{VKD3DSIH_MUL, SpvOpFMul},
|
||||
{VKD3DSIH_NOT, SpvOpNot},
|
||||
{VKD3DSIH_OR, SpvOpBitwiseOr},
|
||||
{VKD3DSIH_USHR, SpvOpShiftRightLogical},
|
||||
{VKD3DSIH_UTOD, SpvOpConvertUToF},
|
||||
{VKD3DSIH_UTOF, SpvOpConvertUToF},
|
||||
{VKD3DSIH_UTOU, SpvOpUConvert},
|
||||
{VKD3DSIH_XOR, SpvOpBitwiseXor},
|
||||
};
|
||||
unsigned int i;
|
||||
|
@ -183,11 +183,11 @@ float4 main() : sv_target
|
||||
[test]
|
||||
uniform 0 int64_t2 9223372036854775807 -1
|
||||
uniform 4 int4 34 66 0 0
|
||||
todo draw quad
|
||||
draw quad
|
||||
probe all rgba (0.0, 4.611686018e18, 536870912.0, 2.305843009e18) 1
|
||||
uniform 0 int64_t2 -1 -1
|
||||
uniform 4 int4 34 66 0 0
|
||||
todo draw quad
|
||||
draw quad
|
||||
probe all rgba (-1.0, -1.0, -1.0, -1.0) 1
|
||||
|
||||
[pixel shader]
|
||||
@ -207,7 +207,7 @@ float4 main() : sv_target
|
||||
[test]
|
||||
uniform 0 uint64_t2 0xffffffffffffffff 1
|
||||
uniform 4 uint4 34 66 0 0
|
||||
todo draw quad
|
||||
draw quad
|
||||
probe all rgba (9.223372036e18, 1.0, 1073741823.0, 4.611686018e18) 1
|
||||
|
||||
[pixel shader]
|
||||
@ -227,7 +227,7 @@ float4 main() : sv_target
|
||||
[test]
|
||||
uniform 0 uint64_t2 0x83 1
|
||||
uniform 4 uint4 34 66 0 0
|
||||
todo draw quad
|
||||
draw quad
|
||||
probe all rgba (262.0, 9.223372036e18, 2250562863104.0, 524.0) 1
|
||||
|
||||
[pixel shader]
|
||||
|
@ -37,8 +37,8 @@ float4 main() : sv_target
|
||||
[test]
|
||||
uniform 0 uint64_t2 0x500000001 0x100000002
|
||||
uniform 4 uint4 10 4 0 0
|
||||
todo draw quad
|
||||
todo probe all rgba (1.0, 2.0, 2147483648.0, 1073741824.0)
|
||||
draw quad
|
||||
probe all rgba (1.0, 2.0, 2147483648.0, 1073741824.0)
|
||||
|
||||
|
||||
[pixel shader]
|
||||
@ -55,5 +55,5 @@ float4 main() : sv_target
|
||||
[test]
|
||||
uniform 0 int64_t2 -21474836481 0x100000002
|
||||
uniform 4 int4 -20 8 0 0
|
||||
todo draw quad
|
||||
todo probe all rgba (-1.0, 2.0, 1073741824.0, 536870912.0)
|
||||
draw quad
|
||||
probe all rgba (-1.0, 2.0, 1073741824.0, 536870912.0)
|
||||
|
Loading…
x
Reference in New Issue
Block a user