[EarlyCSE] Fix handling of target memory intrinsics for CSE'ing loads.
authorArnaud A. de Grandmaison <arnaud.degrandmaison@arm.com>
Wed, 7 Oct 2015 07:41:29 +0000 (07:41 +0000)
committerArnaud A. de Grandmaison <arnaud.degrandmaison@arm.com>
Wed, 7 Oct 2015 07:41:29 +0000 (07:41 +0000)
commitc87636435d2ae3ac674c81695ac9ae88b448e9e7
treee8fb8cfdf487fe73148a08c463f8af11609005a6
parent6d30abd62eb9c8993dc8104daf3036b8158090b5
[EarlyCSE] Fix handling of target memory intrinsics for CSE'ing loads.

Summary:
Some target intrinsics can access multiple elements, using the pointer as a
base address (e.g. AArch64 ld4). When trying to CSE such instructions,
it must be checked the available value comes from a compatible instruction
because the pointer is not enough to discriminate whether the value is
correct.

Reviewers: ssijaric

Subscribers: mcrosier, llvm-commits, aemerson

Differential Revision: http://reviews.llvm.org/D13475

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@249523 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/EarlyCSE.cpp
test/Transforms/EarlyCSE/AArch64/ldstN.ll [new file with mode: 0644]