This is an archive of the discontinued LLVM Phabricator instance.

AMDGPU: Fix not using scalar loads for global reads in shaders
ClosedPublic

Authored by arsenm on May 31 2020, 7:59 AM.

Details

Summary

The pass which infers when it's legal to load a global address space
as SMRD was only considering amdgpu_kernel, and ignoring the shader
entry type calling conventions.

Diff Detail

Event Timeline

arsenm created this revision.May 31 2020, 7:59 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 31 2020, 7:59 AM
foad added inline comments.Jun 1 2020, 2:18 AM
llvm/lib/Target/AMDGPU/AMDGPUAnnotateUniformValues.cpp
130–131

Does the comment need updating?

arsenm updated this revision to Diff 267592.Jun 1 2020, 6:09 AM

Improve comment

nhaehnle accepted this revision.Jun 2 2020, 3:52 AM

Best to keep things consistent between kernels and shaders, and this seems fine to me.

This revision is now accepted and ready to land.Jun 2 2020, 3:52 AM