[PATCH] D123794: llvm-reduce: Handle cloning MachineFrameInfo and stack objects

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 14 10:00:39 PDT 2022


arsenm added a comment.

In D123794#3452038 <https://reviews.llvm.org/D123794#3452038>, @MatzeB wrote:

> I fear that having the cloning code in `tools/llvm-reduce` makes it easy for people to miss when they add new fields to `MachineFrameInfo`. Have you considered adding a `MachineFrameInfo::clone(...)` method instead so the code lives closer to the rest of `MachineFrameInfo`?

Yes. The ugly point on that is you still need something to map between the new and old function block references, which feels like an llvm-reduce specific piece you can't avoid. I guess it could use the original blocks and llvm-reduce can post-process them


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

https://reviews.llvm.org/D123794



More information about the llvm-commits mailing list