[all-commits] [llvm/llvm-project] 243acd: [BasicAA] Remove support for PhiValues analysis

Nikita Popov via All-commits all-commits at lists.llvm.org
Mon Dec 12 00:47:47 PST 2022

  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 243acd5dcbc637e477062877185ad76d8ff63d9d
  Author: Nikita Popov <npopov at redhat.com>
  Date:   2022-12-12 (Mon, 12 Dec 2022)

  Changed paths:
    M llvm/include/llvm/Analysis/BasicAliasAnalysis.h
    M llvm/include/llvm/Analysis/MemoryDependenceAnalysis.h
    M llvm/lib/Analysis/BasicAliasAnalysis.cpp
    M llvm/lib/Analysis/MemoryDependenceAnalysis.cpp
    M llvm/test/Analysis/BasicAA/invalidation.ll
    M llvm/test/Analysis/BasicAA/phi-aa.ll
    M llvm/test/Analysis/BasicAA/recphi.ll
    M llvm/test/CodeGen/AMDGPU/llc-pipeline.ll
    M llvm/test/Other/new-pm-defaults.ll
    M llvm/test/Other/new-pm-lto-defaults.ll
    M llvm/test/Other/new-pm-thinlto-defaults.ll
    M llvm/test/Other/new-pm-thinlto-postlink-pgo-defaults.ll
    M llvm/test/Other/new-pm-thinlto-postlink-samplepgo-defaults.ll
    M llvm/test/Other/new-pm-thinlto-prelink-pgo-defaults.ll
    M llvm/test/Other/new-pm-thinlto-prelink-samplepgo-defaults.ll

  Log Message:
  [BasicAA] Remove support for PhiValues analysis

BasicAA currently has an optional dependency on the PhiValues
analysis. However, at least with our current pipeline setup, we
never actually make use of it. It's possible that this used to work
with the legacy pass manager, but I'm not sure of that either.

Given that this analysis has not actually been in use for a long
time, and nobody noticed or complained, I think we should drop
support for it and focus on one code path. It is worth noting that
analysis quality for the non-PhiValues case has significantly
improved in the meantime.

If we really wanted to make use of PhiValues, the right way would
probably be to pass it in via AAQI in places we want to use it,
rather than using an optional pass manager dependency (which are
an unpredictable PITA and should really only ever be used for
analyses that are only preserved and not used).

Differential Revision: https://reviews.llvm.org/D139719

More information about the All-commits mailing list