[PATCH] D33562: MachineLICM: Add new condition for hoisting of caller preserved registers
Matthias Braun via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue May 30 11:28:18 PDT 2017
MatzeB added inline comments.
================
Comment at: include/llvm/CodeGen/MachineRegisterInfo.h:584-586
+ /// Returns true if PhysReg is always preserved by the caller.
+ bool isCallerPreservedPhysReg(unsigned PhysReg) const;
+
----------------
No need to add this to MachineRegisterInfo.
================
Comment at: include/llvm/Target/TargetRegisterInfo.h:500-501
+ /// Returns true if PhysReg is always caller saved.
+ /// Used by MachineRegisterInfo::isCallerPreservedPhysReg().
+ virtual bool isCallerPreservedPhysReg(unsigned PhysReg,
----------------
Please improve upon the description. Currently this sounds like a check where PhysReg is a CSR register, which you just explained to me in the review is not the case!
================
Comment at: test/CodeGen/PowerPC/licm-tocReg.ll:1
+; RUN: llc -verify-machineinstrs -mtriple=powerpc64le-unknown-linux-gnu < %s | FileCheck %s
+
----------------
- Can you write a .mir test that is better targetted at the problem?
- Please add a sentence or two to describe what you are testing.
https://reviews.llvm.org/D33562
More information about the llvm-commits
mailing list