[all-commits] [llvm/llvm-project] 4c48b3: [GISel][CombinerHelper] Push freeze through non-po...

Dhruv Chawla via All-commits all-commits at lists.llvm.org
Thu May 23 01:16:15 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 4c48b3cb5c681b34345e0dffe920649a5c26aaf4
      https://github.com/llvm/llvm-project/commit/4c48b3cb5c681b34345e0dffe920649a5c26aaf4
  Author: Dhruv Chawla <dhruvc at nvidia.com>
  Date:   2024-05-23 (Thu, 23 May 2024)

  Changed paths:
    M llvm/include/llvm/CodeGen/GlobalISel/CombinerHelper.h
    M llvm/include/llvm/CodeGen/GlobalISel/GenericMachineInstrs.h
    M llvm/include/llvm/CodeGen/MachineInstr.h
    M llvm/include/llvm/Target/GlobalISel/Combine.td
    M llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp
    M llvm/lib/CodeGen/GlobalISel/Utils.cpp
    M llvm/lib/Target/AArch64/AArch64Combine.td
    M llvm/test/CodeGen/AArch64/GlobalISel/combine-select.mir
    M llvm/test/CodeGen/AArch64/pr58431.ll

  Log Message:
  -----------
  [GISel][CombinerHelper] Push freeze through non-poison-producing operands (#90618)

This combine matches the existing fold in InstCombine, i.e.
InstCombinerImpl::pushFreezeToPreventPoisonFromPropagating.

It tries to push freeze through an operand if the operand has only one
maybe-poison operand and all other operands are guaranteed non-poison,
and if the operation itself cannot generate poison (eg. add with nsw can
generate poison, even with non-poison operands).

This is beneficial because it can potentially enable other optimizations
to occur that would otherwise be blocked because of the freeze.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list