[InstCombine] Properly combine metadata when replacing a load with another
authorBjorn Steinbrink <bsteinbr@gmail.com>
Fri, 10 Jul 2015 06:55:44 +0000 (06:55 +0000)
committerBjorn Steinbrink <bsteinbr@gmail.com>
Fri, 10 Jul 2015 06:55:44 +0000 (06:55 +0000)
commitad4d73941a5f46443f899d77758b6124a4cd219c
tree698dbfbc0118d6fc0745ae5626641de9398d0569
parentdde12814c74139bac8dfee3e75abc63c00ebe859
[InstCombine] Properly combine metadata when replacing a load with another

Not doing this can lead to misoptimizations down the line, e.g. because
of range metadata on the replacing load excluding values that are valid
for the load that is being replaced.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@241886 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp
test/Transforms/InstCombine/load-combine-metadata.ll [new file with mode: 0644]