[all-commits] [llvm/llvm-project] 70f013: [AMDGPU] Fix isReallyTriviallyReMaterializable for...

Jay Foad via All-commits all-commits at lists.llvm.org
Wed Mar 10 08:21:33 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 70f013fd3b48087e793be7dc8fd79820556876e5
      https://github.com/llvm/llvm-project/commit/70f013fd3b48087e793be7dc8fd79820556876e5
  Author: Jay Foad <jay.foad at amd.com>
  Date:   2021-03-10 (Wed, 10 Mar 2021)

  Changed paths:
    M llvm/lib/Target/AMDGPU/SIInstrInfo.cpp
    A llvm/test/CodeGen/AMDGPU/vgpr-remat.mir

  Log Message:
  -----------
  [AMDGPU] Fix isReallyTriviallyReMaterializable for V_MOV_*

D57708 changed SIInstrInfo::isReallyTriviallyReMaterializable to reject
V_MOVs with extra implicit operands, but it accidentally rejected all
V_MOVs because of their implicit use of exec. Fix it but avoid adding a
moderately expensive call to MI.getDesc().getNumImplicitUses().

In real graphics shaders this changes quite a few vgpr copies into move-
immediates, which is good for avoiding stalls on GFX10.

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




More information about the All-commits mailing list