[llvm] [DAG] Fold (umin (sub a b) a) -> (usubo a b); (select usubo.1 a usubo.0) (PR #161651)
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Fri Oct 31 13:19:24 PDT 2025
================
@@ -0,0 +1,53 @@
+; RUN: llc < %s -mtriple=aarch64 | FileCheck %s
+
+; GitHub issue #161036
+
+; Positive test : umin(sub(a,b),a) with scalar types should be folded
+define i64 @underflow_compare_fold(i64 %a, i64 %b) {
----------------
arsenm wrote:
Misses the case where the min is commuted?
https://github.com/llvm/llvm-project/pull/161651
More information about the llvm-commits
mailing list