[InstCombine] Make worklist check in memcpy from constant fold more precise
authorNikita Popov <npopov@redhat.com>
Mon, 23 Jan 2023 13:14:19 +0000 (14:14 +0100)
committerNikita Popov <npopov@redhat.com>
Mon, 23 Jan 2023 13:15:41 +0000 (14:15 +0100)
commited9806363beb1caf5265e75a64de904b60218093
tree66c417cf94bf0014a017268b0329a61889b8b609
parent08a19d76171ecb20821bd808efe84381a0581f3c
[InstCombine] Make worklist check in memcpy from constant fold more precise

The phi operands need to be either in the worklist or be the
alloca itself, because that one does not require replacement.
llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp
llvm/test/Transforms/InstCombine/ptr-replace-alloca.ll