[AMDGPU] Scalarization of global uniform loads.
authorAlexander Timofeev <Alexander.Timofeev@amd.com>
Thu, 8 Dec 2016 17:28:47 +0000 (17:28 +0000)
committerAlexander Timofeev <Alexander.Timofeev@amd.com>
Thu, 8 Dec 2016 17:28:47 +0000 (17:28 +0000)
commit18009560c59deceb2be577e0182f7016d6ee1121
tree05c51c8ad3b3de4f579ea884037cded642bec1b2
parenteebed6229ad000a34959f4a9794b9e009eb0227d
[AMDGPU] Scalarization of global uniform loads.

Summary:
LC can currently select scalar load for uniform memory access
basing on readonly memory address space only. This restriction
originated from the fact that in HW prior to VI vector and scalar caches
are not coherent. With MemoryDependenceAnalysis we can check that the
memory location corresponding to the memory operand of the LOAD is not
clobbered along the all paths from the function entry.

Reviewers: rampitec, tstellarAMD, arsenm

Subscribers: wdng, arsenm, nhaehnle

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

llvm-svn: 289076
llvm/lib/Target/AMDGPU/AMDGPUAnnotateUniformValues.cpp
llvm/lib/Target/AMDGPU/AMDGPUSubtarget.cpp
llvm/lib/Target/AMDGPU/AMDGPUSubtarget.h
llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp
llvm/lib/Target/AMDGPU/SIISelLowering.cpp
llvm/lib/Target/AMDGPU/SIISelLowering.h
llvm/lib/Target/AMDGPU/SMInstructions.td
llvm/test/CodeGen/AMDGPU/global_smrd.ll [new file with mode: 0644]
llvm/test/CodeGen/AMDGPU/global_smrd_cfg.ll [new file with mode: 0644]