]> granicus.if.org Git - llvm/commit
AMDGPU: Don't peel of the offset if the resulting base could possibly be negative...
authorChangpeng Fang <changpeng.fang@gmail.com>
Fri, 21 Dec 2018 20:57:34 +0000 (20:57 +0000)
committerChangpeng Fang <changpeng.fang@gmail.com>
Fri, 21 Dec 2018 20:57:34 +0000 (20:57 +0000)
commit44dd5040ee73a80cdab5ca44873044dc1faf5562
treeb0d681cc6d2676095a277d10a4bd3a1fda886b6d
parentec2e0f9305353cf28d1c2f6dd79bb6d76483e4ab
AMDGPU: Don't peel of the offset if the resulting base could possibly be negative in Indirect addressing.

Summary:
  Don't peel of the offset if the resulting base could possibly be negative in Indirect addressing.
This is because the M0 field is of unsigned.

This patch achieves the similar goal as https://reviews.llvm.org/D55241, but keeps the optimization
if the base is known unsigned.

Reviewers:
  arsemn

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@349951 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp
test/CodeGen/AMDGPU/indirect-addressing-si-gfx9.ll
test/CodeGen/AMDGPU/indirect-addressing-si-pregfx9.ll
test/CodeGen/AMDGPU/indirect-addressing-si.ll