This is an archive of the discontinued LLVM Phabricator instance.

AMDGPU: Select s_buffer_load_dword with a non-constant SGPR offset
ClosedPublic

Authored by mareko on Oct 13 2017, 5:50 PM.

Details

Summary

Apps that benefit:

  • alien isolation
  • bioshock infinite
  • civilization: beyond earth
  • company of heroes 2
  • dirt showdown
  • dota 2
  • F1 2015
  • grid autosport
  • hitman
  • legend of grimrock
  • serious sam 3: bfe
  • shadow warrior
  • talos principle
  • total war: warhammer
  • UE4 demos: effects cave, elemental, sun temple

Diff Detail

Repository
rL LLVM

Event Timeline

mareko created this revision.Oct 13 2017, 5:50 PM
arsenm added inline comments.Oct 16 2017, 2:45 PM
lib/Target/AMDGPU/SIInstrInfo.cpp
3720–3723 ↗(On Diff #119000)

Don't these need to be preserved from the input? Especially the offsets

mareko added inline comments.Oct 17 2017, 8:30 AM
lib/Target/AMDGPU/SIInstrInfo.cpp
3720–3723 ↗(On Diff #119000)

S_BUFFER_LOAD_DWORD_SGPR doesn't have soffset, offset, slc. It only has soff (which is now VGPR) and glc, but glc can't be 1 currently.

mareko updated this revision to Diff 119334.Oct 17 2017, 8:45 AM

Preserve GLC.

nhaehnle accepted this revision.Oct 23 2017, 8:05 AM

That should indeed help a lot :)
LGTM.

This revision is now accepted and ready to land.Oct 23 2017, 8:05 AM
This revision was automatically updated to reflect the committed changes.