[all-commits] [llvm/llvm-project] 1e63f8: AMDGPU: Fix an assertion in SIOptimizeVGPRLiveRange

Nicolai Hähnle via All-commits all-commits at lists.llvm.org
Thu Apr 27 00:40:18 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 1e63f8272e8ad2b41f9c4d58250d7de264c4aa4b
      https://github.com/llvm/llvm-project/commit/1e63f8272e8ad2b41f9c4d58250d7de264c4aa4b
  Author: Nicolai Hähnle <nicolai.haehnle at amd.com>
  Date:   2023-04-27 (Thu, 27 Apr 2023)

  Changed paths:
    M llvm/lib/Target/AMDGPU/SIOptimizeVGPRLiveRange.cpp
    A llvm/test/CodeGen/AMDGPU/bug-deadlanes.ll
    A llvm/test/CodeGen/AMDGPU/si-opt-vgpr-liverange-bug-deadlanes.mir

  Log Message:
  -----------
  AMDGPU: Fix an assertion in SIOptimizeVGPRLiveRange

As the comment notes, the shader results in an INSERT_SUBREG with
"undef" (dead) operand in the Endif block. The same can happen with
REG_SEQUENCE. The register is considered dead from a liveness
analysis perspective. The correct thing to do seems to be nothing:
we keep the undef use of the register, the register allocator should
still be able to take the liveness into account correctly.

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




More information about the All-commits mailing list