[PATCH] D127199: [LoongArch 1/n] Add codegen support for the binary operations

WÁNG Xuěruì via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 8 23:02:31 PDT 2022


xen0n accepted this revision.
xen0n added a comment.

Seems good to me, thanks!



================
Comment at: llvm/lib/Target/LoongArch/LoongArchISelLowering.cpp:90-95
+  if (ValVT == MVT::f32)
+    Reg = State.AllocateReg(ArgFPR32s);
+  else if (ValVT == MVT::f64)
+    Reg = State.AllocateReg(ArgFPR64s);
+  else
+    Reg = State.AllocateReg(ArgGPRs);
----------------
I would probably use a switch here but this is only a minor nit and bikeshedding. No problem in the current form.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D127199



More information about the llvm-commits mailing list