[PATCH] D16481: Split PrologEpilogInserter into 2 parts

Hal Finkel via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 3 06:41:31 PST 2016


hfinkel added a subscriber: hfinkel.

================
Comment at: lib/CodeGen/PrologEpilogInserter.cpp:264
@@ +263,3 @@
+
+bool PEIWithCSRs::runOnMachineFunction(MachineFunction &Fn) {
+  const TargetFrameLowering *TFI = Fn.getSubtarget().getFrameLowering();
----------------
Did we decide that we need to split the passes this way? It seems like the boilerplate from having two passes seems >= the difference between this runOnMachineFunction implementation and the simpler version.

================
Comment at: lib/CodeGen/PrologEpilogInserter.cpp:356
@@ -295,3 +355,3 @@
   // These are used to keep track the callee-save area. Initialize them.
-  MinCSFrameIndex = INT_MAX;
+  MinCSFrameIndex = std::numeric_limits<unsigned>::max();
   MaxCSFrameIndex = 0;
----------------
Does having > INT_MAX FIs really work with just these changes?


http://reviews.llvm.org/D16481





More information about the llvm-commits mailing list