[PATCH] D104793: [ARM] Transform a floating-point to fixed-point conversion to a VCVT_fix
Sam Tebbs via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jun 25 09:02:51 PDT 2021
samtebbs marked 7 inline comments as done.
samtebbs added inline comments.
================
Comment at: llvm/lib/Target/ARM/ARMISelDAGToDAG.cpp:3173-3174
+ auto ImmNode = FMul->getOperand(1);
+ auto VecVal = FMul->getOperand(0);
+
----------------
dmgreen wrote:
> auto -> SDValue
>
> Should VecVal be different for the two cases? Otherwise below it uses the fmul->operand(0)->operand(0).
Well spotted. I need to check if it's an [S|U]INT_TO_FP and assign it to operand 0 of itself if so.
================
Comment at: llvm/lib/Target/ARM/ARMISelDAGToDAG.cpp:3176
+
+ if (VecVal.getValueType().getVectorElementType().getSizeInBits() !=
+ ScalarBits)
----------------
dmgreen wrote:
> Can this use getScalarSizeInBits?
It certainly can.
================
Comment at: llvm/test/CodeGen/Thumb2/mve-vcvt-float-to-fixed.ll:802
+
+define arm_aapcs_vfpcc <4 x float> @vcvt_u32_32(<4 x i32> %0) {
+; CHECK-LABEL: vcvt_u32_32:
----------------
dmgreen wrote:
> Does this need updating? and vcvt_u32_33 below.
Yes, well spotted. Looks like I fell foul of copy and paste complacency.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D104793/new/
https://reviews.llvm.org/D104793
More information about the llvm-commits
mailing list