[AMDGPU] stop buffer_store being moved illegally
authorTim Renouf <tpr.llvm@botech.co.uk>
Tue, 20 Feb 2018 10:03:38 +0000 (10:03 +0000)
committerTim Renouf <tpr.llvm@botech.co.uk>
Tue, 20 Feb 2018 10:03:38 +0000 (10:03 +0000)
commit8234b4893ab6ca9e4f0f21d5ec73ae9d8cf5dc3d
treeb094bf0be5fcb9382a4d407b10305b3e5c53137f
parentb8bf5a6c858b9938865ce668081c559f87bb4051
[AMDGPU] stop buffer_store being moved illegally

Summary:
The machine instruction scheduler was illegally moving a buffer store
past a buffer load with the same descriptor and offset. Fixed by marking
buffer ops as mayAlias and isAliased. This may be overly conservative,
and we may need to revisit.

Subscribers: arsenm, kzhuravl, wdng, nhaehnle, yaxunl, dstuttard, t-tye, llvm-commits

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

Change-Id: Iff3173d9e0653e830474546276ab9d30318b8ef7
llvm-svn: 325567
llvm/lib/Target/AMDGPU/SIMachineFunctionInfo.h
llvm/test/CodeGen/AMDGPU/buffer-schedule.ll [new file with mode: 0644]