[all-commits] [llvm/llvm-project] 3a0c95: llvm-reduce: Fix introducing unreachable code in s...

Matt Arsenault via All-commits all-commits at lists.llvm.org
Mon Apr 7 18:51:41 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 3a0c95fb506301fdd083b6e5dff0a0c88da4a665
      https://github.com/llvm/llvm-project/commit/3a0c95fb506301fdd083b6e5dff0a0c88da4a665
  Author: Matt Arsenault <Matthew.Arsenault at amd.com>
  Date:   2025-04-08 (Tue, 08 Apr 2025)

  Changed paths:
    M llvm/test/tools/llvm-reduce/reduce-conditionals.ll
    M llvm/tools/llvm-reduce/deltas/ReduceUsingSimplifyCFG.cpp
    M llvm/tools/llvm-reduce/deltas/Utils.cpp
    M llvm/tools/llvm-reduce/deltas/Utils.h

  Log Message:
  -----------
  llvm-reduce: Fix introducing unreachable code in simplify conditionals (#133842)

After replacing the branch condition, this was calling simplifyCFG to
perform the cleanups of the branch. This is far too heavy of a hammer.
We do not want all of the extra optimizations in simplifyCFG, and
this could also leave behind dead code. Instead, minimally fold the
terminator and try to delete the newly dead code.

This is pretty much a direct copy of what bugpoint does.



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