[all-commits] [llvm/llvm-project] 97ad0f: [DAGCombiner][RISCV] Don't propagate the exact fla...

Craig Topper via All-commits all-commits at lists.llvm.org
Mon Jun 23 14:29:38 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 97ad0f4b3d3c94dc935fe6e0aee504220dd7e560
      https://github.com/llvm/llvm-project/commit/97ad0f4b3d3c94dc935fe6e0aee504220dd7e560
  Author: Craig Topper <craig.topper at sifive.com>
  Date:   2025-06-23 (Mon, 23 Jun 2025)

  Changed paths:
    M llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
    A llvm/test/CodeGen/RISCV/pr145360.ll

  Log Message:
  -----------
  [DAGCombiner][RISCV] Don't propagate the exact flag from udiv/sdiv to urem/srem. (#145387)

If we simplify a udiv/sdiv using the exact flag we shouldn't
propagate that simplifaction to any urem/srem that happens to
use the same operands. If the exact flag is wrong, the udiv/sdiv
will produce poison, but that doesn't mean we can make the urem/srem
simplify to 0.
    
Fixes #145360.



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