[all-commits] [llvm/llvm-project] 27a62e: [LSR] Split the -lsr-term-fold transformation into...

Philip Reames via All-commits all-commits at lists.llvm.org
Sat Aug 17 18:34:45 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 27a62ec72aed3faf1388600f485552471b580e3b
      https://github.com/llvm/llvm-project/commit/27a62ec72aed3faf1388600f485552471b580e3b
  Author: Philip Reames <preames at rivosinc.com>
  Date:   2024-08-17 (Sat, 17 Aug 2024)

  Changed paths:
    M llvm/include/llvm/Analysis/TargetTransformInfo.h
    M llvm/include/llvm/Analysis/TargetTransformInfoImpl.h
    M llvm/include/llvm/CodeGen/BasicTTIImpl.h
    M llvm/include/llvm/CodeGen/TargetPassConfig.h
    M llvm/include/llvm/InitializePasses.h
    M llvm/include/llvm/LinkAllPasses.h
    M llvm/include/llvm/Passes/MachinePassRegistry.def
    M llvm/include/llvm/Transforms/Scalar.h
    A llvm/include/llvm/Transforms/Scalar/LoopTermFold.h
    M llvm/lib/Analysis/TargetTransformInfo.cpp
    M llvm/lib/CodeGen/TargetPassConfig.cpp
    M llvm/lib/Passes/PassBuilder.cpp
    M llvm/lib/Passes/PassRegistry.def
    M llvm/lib/Target/RISCV/RISCVTargetMachine.cpp
    M llvm/lib/Target/RISCV/RISCVTargetTransformInfo.h
    M llvm/lib/Transforms/Scalar/CMakeLists.txt
    M llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp
    A llvm/lib/Transforms/Scalar/LoopTermFold.cpp
    M llvm/lib/Transforms/Scalar/Scalar.cpp
    M llvm/test/CodeGen/RISCV/O3-pipeline.ll
    M llvm/test/Transforms/LoopStrengthReduce/RISCV/lsr-cost-compare.ll
    M llvm/test/Transforms/LoopStrengthReduce/RISCV/term-fold-crash.ll
    M llvm/test/Transforms/LoopStrengthReduce/lsr-term-fold-negative-testcase.ll
    M llvm/test/Transforms/LoopStrengthReduce/lsr-term-fold.ll
    M llvm/test/Transforms/LoopStrengthReduce/lsr-unreachable-bb-phi-node.ll

  Log Message:
  -----------
  [LSR] Split the -lsr-term-fold transformation into it's own pass (#104234)

This transformation doesn't actually use any of the internal state of
LSR and recomputes all information from SCEV.  Splitting it out makes
it easier to test.
    
Note that long term I would like to write a version of this transform
which *is* integrated with LSR's solver, but if that happens, we'll
just delete the extra pass.
    
Integration wise, I switched from using TTI to using a pass configuration
variable.  This seems slightly more idiomatic, and means we don't run
the extra logic on any target other than RISCV.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list