[llvm] [PowerPC] Lower UCMP and SCMP directly to setb instead of matching the DAG shape (PR #206282)
zhijian lin via llvm-commits
llvm-commits at lists.llvm.org
Thu Sep 3 08:22:50 PDT 2026
================
@@ -10,6 +11,12 @@ define i8 @scmp_8_8(i8 signext %x, i8 signext %y) nounwind {
; CHECK-NEXT: rldicl 5, 5, 1, 63
; CHECK-NEXT: isellt 3, 3, 5
; CHECK-NEXT: blr
+;
+; P9-LABEL: scmp_8_8:
----------------
diggerlin wrote:
even without your patch , I think llvm already generate the asm
; CHECK-PWR9-LABEL: scmp_8_8:
; CHECK-PWR9: # %bb.0:
; CHECK-PWR9-NEXT: cmpw 3, 4
; CHECK-PWR9-NEXT: setb 3, 0
; CHECK-PWR9-NEXT: blr
can create a base commit having the command line
RUN: llc -mtriple=ppc64le-unknown-unknown %s -o - | FileCheck %s --check-prefix=CHECK
; RUN: llc -mtriple=ppc64le-unknown-unknown -mcpu=pwr9 %s -o - | FileCheck %s --check-prefix=P9
in your test case but without your fix,
so we compare what change after your fix
https://github.com/llvm/llvm-project/pull/206282
More information about the llvm-commits
mailing list