[all-commits] [llvm/llvm-project] 87b63c: [MemCpyOpt] Avoid double invalidation (NFCI)

Nikita Popov via All-commits all-commits at lists.llvm.org
Fri Oct 2 12:51:12 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 87b63c1726e24214272cd6c04825c585635d1cdc
      https://github.com/llvm/llvm-project/commit/87b63c1726e24214272cd6c04825c585635d1cdc
  Author: Nikita Popov <nikita.ppv at gmail.com>
  Date:   2020-10-02 (Fri, 02 Oct 2020)

  Changed paths:
    M llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp

  Log Message:
  -----------
  [MemCpyOpt] Avoid double invalidation (NFCI)

The removal of the cpy instruction is left to the caller of
performCallSlotOptzn(), including the invalidation of MD. Both
call-sites already do this.

Also handle incrementation of NumMemCpyInstr consistently at the
call-site. One of the call-site was already doing this, which
ended up incrementing the statistic twice.

This fix was part of D26739.




More information about the All-commits mailing list