[PATCH] D129989: [AArch64] Add f16 fpimm patterns

Dave Green via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 21 01:39:07 PDT 2022


dmgreen added a comment.

Yeah seems OK as far as I can tell.



================
Comment at: llvm/lib/Target/AArch64/AArch64InstrInfo.td:1629
+def : Pat<(f16 fpimm:$in),
+  (COPY_TO_REGCLASS (MOVi32imm (bitcast_fpimm_to_i32 f16:$in)), FPR16)>;
 def : Pat<(f32 fpimm:$in),
----------------
COPY's are quite loose in their definition, but it is probably best to keep them copying between values of the same size. I think this can use FMOVWHr directly, so long as the instruction has already been defined.
It should probably have a: `let Predicates = [HasFullFP16]` too.


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

https://reviews.llvm.org/D129989



More information about the llvm-commits mailing list