[PATCH] D46315: [RegUsageInfoCollector] Fix handling of callee saved registers with CSR optimization.

Jonas Paulsson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 24 07:22:05 PDT 2018


jonpa updated this revision to Diff 148406.
jonpa added a comment.

Patch updated per previous discussion.

- New static method computeCalleeSavedRegs() that does the work of adding subregs and fully saved superregs, that we can reuse in e.g. MachineVerifier.

- When encountering a def of a reg, only call SetRegAsDefined after checking that *AI was not saved.

- There is no CoveredBySubRegs flag on the register, but only on the register class as far as I can see. Since getMinimalPhysRegClass() iterates over all register classes, I thought this method might as well do the same.


https://reviews.llvm.org/D46315

Files:
  lib/CodeGen/RegUsageInfoCollector.cpp
  test/CodeGen/SystemZ/ipra-04.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D46315.148406.patch
Type: text/x-patch
Size: 5338 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180524/64aec25a/attachment.bin>


More information about the llvm-commits mailing list