[PATCH] D116825: [GVN] MemorySSA for GVN: use MemorySSA for redundant loads elimination

Anna Thomas via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 24 07:29:53 PST 2022


anna added a comment.

Do we have any compile time measurements for this change with O3 <https://reviews.llvm.org/owners/package/3/>?

I have couple of high level comments/clarifications:

- Are all mini-transforms within GVN moving to MSSA in this case?
- Is the move to MemorySSA for performance of cases not caught through MDA?

@asbirlea, a question to clarify my understanding around enabling MSSA for a pass:

- We optimistically build memorySSA for passes that unconditionally require it. This building and preservation can be costly from compile time perspective. Also, we may have possible invalidation by later function passes which do not preserve GVN, thereby having different implications for pipelines depending on where GVN is present. For example, if we end up with something like:

  LPM {
   ...
   LICM <-- requires MSSA.
  
  }
  instcombine <-- invalidates MSSA
  GVNPass() <-- build MSSA again
  simplifyCFG <-- invalidates MSSA

is arguably much worse in compile time than:

  LPM {
   ...
   LICM <-- requires MSSA.
  
  }
  GVNPass() <-- use preserved MSSA
  instcombine <-- invalidates MSSA
  simplifyCFG


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

https://reviews.llvm.org/D116825



More information about the llvm-commits mailing list