[PATCH] D132942: [PowerPC][GISel]add support for float point arithmetic operations

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 27 12:37:28 PDT 2022


arsenm added inline comments.


================
Comment at: llvm/lib/Target/PowerPC/GISel/PPCInstructionSelector.cpp:114
+  //    class of the one inferred from the register bank.
+  if (!OldRC || !DstRC->hasSubClassEq(OldRC)) {
+    if (!RBI.constrainGenericRegister(DstReg, *DstRC, MRI)) {
----------------
Most of this function is repeating the work RBI.constrainGenericRegister already does. You just need to get the class implied by the bank with the type, and pass that to RBI.constrainGenericRegister. It figures out if there's a class set or not and handles subclass checks


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D132942



More information about the llvm-commits mailing list