[HLSL] Explicit casts of 1x1 matrices to 1x1 matrices fail
Open
HLSL
- Dominant language
- LLVM
- Stars
- 40.5k
- Forks
- 18.7k
- PR merge metrics
- PR metrics pending
Description
https://hlsl.godbolt.org/z/adxb5brT8
Compile the following hlsl with `clang-dxc -T lib_6_8`
```hlsl
export float1x1 fn(double1x1 x) {
return (float1x1)x;
}
```
Result:
```llvm
define noundef nofpclass(nan inf) <1 x float> @_Z2fnu11matrix_typeILm1ELm1EdE(<1 x double> noundef nofpclass(nan inf) %x) local_unnamed_addr #0 {
entry:
ret <1 x float> undef
}
```
Expected output: the %x param should be cast to a <1 x float> and returned.
Contributor guide
Assessment
This issue has not been assessed yet.