This is an archive of the discontinued LLVM Phabricator instance.

[AMDGPU] Skip debug instruction uses while optimizing live range of a reg in SIOptimizeVGPRLiveRange
ClosedPublic

Authored by yassingh on Aug 2 2023, 7:08 AM.

Details

Summary

This will prevent the assert(!O.readsReg()) from firing in
SIOptimizeVGPRLiveRange::optimizeLiveRange

Fix for #64163

Diff Detail

Event Timeline

yassingh created this revision.Aug 2 2023, 7:08 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 2 2023, 7:08 AM
yassingh requested review of this revision.Aug 2 2023, 7:08 AM
Herald added a project: Restricted Project. · View Herald Transcript
arsenm added inline comments.Aug 2 2023, 7:09 AM
llvm/test/CodeGen/AMDGPU/si-optimize-vgpr-live-range-dbg-instr.ll
46

run opt -p=instnamer on this to avoid anonymous values in tests

yassingh updated this revision to Diff 546458.Aug 2 2023, 7:21 AM
yassingh marked an inline comment as done.
arsenm accepted this revision.Aug 2 2023, 7:22 AM

Don't know where the debug info went, MIR or less deletable test may be useful

llvm/test/CodeGen/AMDGPU/si-optimize-vgpr-live-range-dbg-instr.ll
39–45

I don't know where the debug info went in the output

This revision is now accepted and ready to land.Aug 2 2023, 7:22 AM

Don't know where the debug info went, MIR or less deletable test may be useful

Will add a MIR test

yassingh updated this revision to Diff 546745.Aug 3 2023, 1:44 AM
yassingh retitled this revision from [AMDGPU] Skip debug instruction uses while optimizing live range of a reg in SIOptimizeVGPRLiveRange to [AMDGPU] Skip debug instruction uses while optimizing live range of a reg in SIOptimizeVGPRLiveRange.

Add MIR test

arsenm accepted this revision.Aug 4 2023, 5:53 PM
arsenm added inline comments.
llvm/test/CodeGen/AMDGPU/si-optimize-vgpr-live-range-dbg-instr.mir
95

should compact the register numbers with -run-pass=none

yassingh updated this revision to Diff 547647.Aug 6 2023, 11:03 PM
yassingh marked an inline comment as done.
  • Rebase, llc -run-pass=none
This revision was landed with ongoing or failed builds.Aug 6 2023, 11:06 PM
This revision was automatically updated to reflect the committed changes.