[PATCH] D148089: [clang][CodeGen] Break up TargetInfo.cpp [1/8]

Sergei Barannikov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri May 19 13:55:49 PDT 2023


This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rGf2492f7cf0b1: [clang][CodeGen] Break up TargetInfo.cpp [1/8] (authored by barannikov88).

Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D148089

Files:
  clang/lib/CodeGen/TargetInfo.cpp


Index: clang/lib/CodeGen/TargetInfo.cpp
===================================================================
--- clang/lib/CodeGen/TargetInfo.cpp
+++ clang/lib/CodeGen/TargetInfo.cpp
@@ -9056,13 +9056,17 @@
 
 namespace {
 class LanaiABIInfo : public DefaultABIInfo {
+  struct CCState {
+    unsigned FreeRegs;
+  };
+
 public:
   LanaiABIInfo(CodeGen::CodeGenTypes &CGT) : DefaultABIInfo(CGT) {}
 
   bool shouldUseInReg(QualType Ty, CCState &State) const;
 
   void computeInfo(CGFunctionInfo &FI) const override {
-    CCState State(FI);
+    CCState State;
     // Lanai uses 4 registers to pass arguments unless the function has the
     // regparm attribute set.
     if (FI.getHasRegParm()) {
@@ -10074,6 +10078,10 @@
 namespace {
 
 class ARCABIInfo : public DefaultABIInfo {
+  struct CCState {
+    unsigned FreeRegs;
+  };
+
 public:
   using DefaultABIInfo::DefaultABIInfo;
 
@@ -10096,7 +10104,7 @@
   }
 
   void computeInfo(CGFunctionInfo &FI) const override {
-    CCState State(FI);
+    CCState State;
     // ARC uses 8 registers to pass arguments.
     State.FreeRegs = 8;
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D148089.523925.patch
Type: text/x-patch
Size: 1095 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230519/3757c320/attachment.bin>


More information about the cfe-commits mailing list