[llvm] [DirectX][NFC] Model precise overload type specification of DXIL Ops (PR #83917)
S. Bharadwaj Yadavalli via llvm-commits
llvm-commits at lists.llvm.org
Tue Mar 12 11:45:56 PDT 2024
================
@@ -90,6 +92,15 @@ static ParameterKind getParameterKind(MVT::SimpleValueType VT) {
case MVT::fAny:
case MVT::iAny:
return ParameterKind::OVERLOAD;
+ case MVT::Other:
+ // Handle DXIL-specific overload types
+ {
+ if ((R->getValueAsInt("isHalfOrFloat")) ||
+ (R->getValueAsInt("isI16OrI32"))) {
+ return ParameterKind::OVERLOAD;
+ }
+ }
----------------
bharadwajy wrote:
> The extra scope here isn't necessary, and we don't need parens around the `getValueAsInt` calls.
Fixed.
> Scope comment applies to the other switch as well.
The comment is specifically to highlight the `case` that refers to the DXIL-specific types `isHalforFloat` and `isI16OrI32` only, which are of `MVT::Other` type. The other cases handle normal LLVM `MVT`s.
https://github.com/llvm/llvm-project/pull/83917
More information about the llvm-commits
mailing list