[PATCH] D118560: [AArch64][SVE] NFC: tidy up isel lowering

Cullen Rhodes via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 2 00:27:29 PST 2022


c-rhodes added inline comments.


================
Comment at: llvm/lib/Target/AArch64/AArch64ISelLowering.cpp:1179-1182
+      setOperationAction(ISD::SADDSAT, VT, Legal);
+      setOperationAction(ISD::UADDSAT, VT, Legal);
+      setOperationAction(ISD::SSUBSAT, VT, Legal);
+      setOperationAction(ISD::USUBSAT, VT, Legal);
----------------
sdesmalen wrote:
> nit: I thought the default was Legal, so maybe these 4 lines can be removed?
> nit: I thought the default was Legal, so maybe these 4 lines can be removed?

That crossed my mind as well, but these opcodes default to expand (set in TargetLoweringBase). A warning in `setOperationAction` when marking an operation that is legal by default legal might be nice, or even when setting it to the same operation, but I suspect there will be many such occurrences. 


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D118560



More information about the llvm-commits mailing list