[all-commits] [llvm/llvm-project] 838d5d: AMDGPU/GlobalISel: Fix combine crash because LI is...

petar-avramovic via All-commits all-commits at lists.llvm.org
Tue Nov 8 03:47:07 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 838d5d371ac817538896b6a5505ee36341143a28
      https://github.com/llvm/llvm-project/commit/838d5d371ac817538896b6a5505ee36341143a28
  Author: Petar Avramovic <Petar.Avramovic at amd.com>
  Date:   2022-11-08 (Tue, 08 Nov 2022)

  Changed paths:
    M llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp
    M llvm/lib/Target/AMDGPU/AMDGPUPreLegalizerCombiner.cpp
    A llvm/test/CodeGen/AMDGPU/GlobalISel/select-to-fmin-fmax.ll

  Log Message:
  -----------
  AMDGPU/GlobalISel: Fix combine crash because LI is not set in prelegalizer

Caused by legacy min/max combines (select + cmp) asking for legalizer info
in prelegalizer (D135047 added combine to all_combines).
Combine still does not work for AMDGPU since destination opcode is custom,
not legal. Similar combine works on DAG since it asks for legal or custom.

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




More information about the All-commits mailing list