[llvm] [ReachingDefAnalysis] Extend the analysis to stack objects. (PR #118097)
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Mon Jan 6 11:58:41 PST 2025
================
@@ -138,6 +141,13 @@ class ReachingDefAnalysis : public MachineFunctionPass {
DenseMap<MachineInstr *, int> InstIds;
MBBReachingDefsInfo MBBReachingDefs;
+ using MBBFrameObjsReachingDefsInfo =
+ std::vector<std::vector<std::vector<int>>>;
+ // MBBFrameObjsReachingDefs[i][j] is a list of instruction indicies (relative
+ // to begining of MBB) that define frame index (j +
+ // MF->getFrameInfo().getObjectIndexBegin()) in MBB i. This is used in
+ // answering reaching defenition queries.
+ MBBFrameObjsReachingDefsInfo MBBFrameObjsReachingDefs;
----------------
topperc wrote:
This data structure feels like it has the potential to be quite large, but also quite sparse. Have you measured this?
https://github.com/llvm/llvm-project/pull/118097
More information about the llvm-commits
mailing list