[all-commits] [llvm/llvm-project] baa3b8: [MemCpyOpt] Don't shorten memset if memcpy operand...

Nikita Popov via All-commits all-commits at lists.llvm.org
Tue Oct 13 12:19:42 PDT 2020


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

  Changed paths:
    M llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
    M llvm/test/Transforms/MemCpyOpt/memset-memcpy-redundant-memset.ll
    M llvm/test/Transforms/MemCpyOpt/preserve-memssa.ll

  Log Message:
  -----------
  [MemCpyOpt] Don't shorten memset if memcpy operands may be the same

If the memcpy operands are the same (which is allowed since D86815)
then the memcpy is effectively a no-op and the partially overlapping
memset is not dead.

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




More information about the All-commits mailing list