[clang] [llvm] [WebAssembly] Implement all f16x8 binary instructions. (PR #93360)
Heejin Ahn via llvm-commits
llvm-commits at lists.llvm.org
Tue May 28 11:13:06 PDT 2024
================
@@ -1199,6 +1213,7 @@ def : Pat<(v2f64 (froundeven (v2f64 V128:$src))), (NEAREST_F64x2 V128:$src)>;
multiclass SIMDBinaryFP<SDPatternOperator node, string name, bits<32> baseInst> {
defm "" : SIMDBinary<F32x4, node, name, baseInst>;
defm "" : SIMDBinary<F64x2, node, name, !add(baseInst, 12)>;
+ defm "" : SIMDBinary<F16x8, node, name, !add(baseInst, 80), [HasHalfPrecision]>;
----------------
aheejin wrote:
I understand why it's added, and I wish we can multi-inherit from `SIMDBinary` and `HALF_PRECISION_I`, but I'm not sure if we can do it... (Can we?)
I'm not strongly opinionated about it and it's basically just a matter of preference, but how about adding a `multiclass` like `HalfPrecisionBinary` or something that inherits from `SIMDBinary`?
https://github.com/llvm/llvm-project/pull/93360
More information about the llvm-commits
mailing list