[PATCH] D69578: [AIX] Add support for lowering int, float and double formal arguments.

Chris Bowler via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 18 08:00:16 PST 2019


cebowleratibm added inline comments.


================
Comment at: llvm/lib/Target/PowerPC/PPCISelLowering.cpp:6789
+                                                    bool IsPPC64) {
+  switch (SVT) {
+  default:
----------------
I'd rather see this switch written:
  assert((IsPPC64 || SVT != MVT::i64) && "i64 should have been split for 32-bit codegen.");

  switch (SVT) {
  ...
  case MVT::i1:
  case MVT::i32:
  case MVT::i64:    
    return IsPPC64 ? &PPC::G8RCRegClass : &PPC::GPRCRegClass;
  ...  
  }
It's easier for me to follow that all ints in PPC64 are G8RC and all ints in PPC32 are GPR and the complexity of the i64 in PPC32 assertion stays out of the switch.


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

https://reviews.llvm.org/D69578





More information about the llvm-commits mailing list