[PATCH] D121292: [VP] Add vp.fcmp comparison intrinsic and docs

Fraser Cormack via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 23 07:22:28 PDT 2022


frasercrmck marked an inline comment as done.
frasercrmck added inline comments.


================
Comment at: llvm/include/llvm/IR/Intrinsics.td:1568
+let IntrProperties = [IntrNoMem, IntrNoSync, IntrWillReturn] in {
+  def int_vp_fcmp : DefaultAttrsIntrinsic<[ LLVMScalarOrSameVectorWidth<0, llvm_i1_ty> ],
+                                [ llvm_anyvector_ty,
----------------
simoll wrote:
> Does `DefaultAttrsIntrinsic` imply `speculatable` ?
No, shouldn't do, anyway. It just adds those attributes marked as being applied by default, which is done through `IsDefault` in `IntrinsicProperty`:, e.g.,

```
class IntrinsicProperty<bit is_default = false> {
  bit IsDefault = is_default;
}

// Applied by default.
def IntrWillReturn : IntrinsicProperty<1>;

// This property indicates that the intrinsic is safe to speculate.
def IntrSpeculatable : IntrinsicProperty;
```

This does mean that `IntrNoSync` and `IntrWillReturn` are redundant, but since all other VP intrinsics (and even others like masked_load) explicitly list them, I thought I'd keep things consistent until we decide to clean things up.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D121292/new/

https://reviews.llvm.org/D121292



More information about the llvm-commits mailing list