[PATCH] D153326: [CSKY] Optimize subtraction with SUBI32/SUBI16
Ben Shi via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 20 03:12:49 PDT 2023
benshi001 added inline comments.
================
Comment at: llvm/test/CodeGen/CSKY/base-i.ll:44
+define i32 @addRI_256(i32 %x) {
+; CHECK-LABEL: addRI_256:
+; CHECK: # %bb.0: # %entry
----------------
256 is the upper boundary of `ADDI16`.
================
Comment at: llvm/test/CodeGen/CSKY/base-i.ll:292
+define i32 @subRI_256(i32 %x) {
+; CHECK-LABEL: subRI_256:
+; CHECK: # %bb.0: # %entry
----------------
256 is the upper boundary of `SUBI16`.
================
Comment at: llvm/test/CodeGen/CSKY/base-i.ll:349
; CHECK: # %bb.0: # %entry
; CHECK-NEXT: movih32 a1, 65535
; CHECK-NEXT: ori32 a1, a1, 61439
----------------
4097 is not optimized to `SUBI32` due to out of range.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D153326/new/
https://reviews.llvm.org/D153326
More information about the llvm-commits
mailing list