[PATCH] D130028: [SelectionDAG] Fix fptoi.sat scalable vector lowering

Eli Friedman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 18 11:01:26 PDT 2022


efriedma added a comment.

> This also needed an adjustment to create SetCC+VSelect as opposed to SelectCC for vectors. These should either be combined into SelectCC or handled as needed by the target. (I went back and forth as to whether this should be used for scalar too, or if the selectcc should be handled differently. This way was at least simpler to get codegen not crashing).

This seems a bit weird to me... a couple questions:

1. For SelectCC with a vector result, are the compare operands supposed to be scalar or vector?  Can we add an appropriate assertion to SelectionDAG::getNode()?
2. Is legalization not correctly handling the case where SELECT_CC is marked "expand"?



================
Comment at: llvm/test/CodeGen/AArch64/fptosi-sat-vector.ll:1069
+; CHECK-NEXT:    mov x3, v0.d[1]
+; CHECK-NEXT:    fmov x2, d0
 ; CHECK-NEXT:    ret
----------------
This isn't an improvement.


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

https://reviews.llvm.org/D130028



More information about the llvm-commits mailing list